Algorithmadvanced
Subspace blind channel identification
Also called Moulines subspace method.
Identifies a multichannel FIR channel, up to one scalar, from the noise subspace of the covariance of an oversampled output. It needs subchannels with no common zero and a known channel length.
- Solves
- Blind equalization
- Time
- O(K P^2 N^2 + P^3 N^4) worst
- Space
- O(P^2 N^2) extra
- Where
- K = the number of samples; L = the number of channel taps; N = the window length in symbols; P = the number of subchannels
- Model
- Real RAM
- Properties
- blinddeterministicneeds known orderofflinesecond order statistics
- Evidence
- Proof sketchCode in 1 languages
- Origin
- Eric Moulines, Pierre Duhamel, Jean Francois Cardoso, Sylvie Mayrargue, 1995
Subspace blind channel identification estimates a channel with one input and outputs, such as an oversampled or multi-antenna receiver, from the covariance of the received signal alone. It stacks consecutive output vectors into one long vector, whose covariance is for a block Toeplitz matrix built from the channel. The eigenvectors of the smallest eigenvalues, the noise subspace, are orthogonal to every column of . That orthogonality is a set of linear equations in the channel taps, and the solution is the eigenvector of the smallest eigenvalue of a small matrix . The result is exact, up to one complex scalar, when the subchannels have no common zero and the covariance is exact. It solves the blind equalization problem by identification, not by adapting an equalizer, and it uses only second-order statistics, unlike CMA. It differs from Tong-Xu-Kailath identification, which uses the correlations at lags 0 and 1, whitens the signal part and assumes a white input. The subspace method uses only the lag-0 covariance of a stacked window, needs no whitening, and works for any input covariance of full rank. Both need the channel length.
In plain words
When a receiver takes two or more samples per symbol, it sees the same symbols through two or more slightly different channels. The received vectors then lie close to a smaller set of directions that the channel fixes, and the directions left over contain only noise. The method finds these leftover directions from the measured correlations of the received signal. Every leftover direction must be at right angles to the channel's own directions, and this gives enough equations to find the channel, apart from one unknown factor. It fails when all the channels share a common zero, because then two different channels give the same correlations.
The problem
The received vectors are
with an unknown channel , independent symbols of unit power, and white noise of power on each output. The stacked channel is . Subchannel has the transfer function . The input is the samples , the number of subchannels, the channel length and a window length . The output is for an unknown scalar , with .
The stacked model. The window equals plus noise, where is the block Toeplitz matrix whose block is , and zero outside . So .
The algorithm
SUBSPACE-IDENTIFY(y, P, L, N)- 1
R ← (1/K') Σ_k Y[k] Y[k]^H ▷ sample covariance of the windows - 2
G ← eigenvectors of R for its PN - (N+L-1) smallest eigenvalues - 3
Q ← the PL × PL zero matrix - 4
for each g in G do - 5
build 𝒢(g): row m, for m = 0..N+L-2, is (g_m^H, g_{m-1}^H, ..., g_{m-L+1}^H), with g_i = 0 outside 0..N-1 - 6
Q ← Q + 𝒢(g)^H 𝒢(g) - 7
ĥ ← the unit eigenvector of Q for its smallest eigenvalue - 8
return ĥ
Line L1 estimates from the windows. Line L2 takes the noise subspace: has rank , so has eigenvalues equal to , and their eigenvectors are orthogonal to the columns of . Here is block of , a vector of length . Line L5 rewrites the condition as : entry of is . Lines L3 to L6 sum the squared residuals over the noise subspace, so , and line L7 minimizes it on the unit sphere. The code solves the two Hermitian eigenproblems with the Jacobi method on the real form of , which has every eigenvalue twice.
Example
A hand case. Two subchannels and , so , and . Their zeros are and : no common zero. With , the window has length 4 and
of rank 3. The noise subspace has dimension , spanned by : check . So and . With , the three rows of line L5 give
So , , and the middle equation gives : , the channel up to a scalar. The vector is the cross relation between the two outputs, scaled by .
From samples. For the complex channel , , with QPSK symbols and noise of power per output, the misalignment is for and for (seed 1, a measurement). With the exact covariance, it is zero to rounding.
A common zero. If both subchannels contain the factor , for example and , then has a null space of dimension 2, and line L7 can return any vector in it.
Correctness
Claim. Let , , , , and let the two subchannels have no common zero. With the exact covariance for any input covariance of full rank, the null space of is exactly , so line L7 returns up to a unit scalar. This is a theorem. For the same holds under the condition that the subchannels have no zero common to all of them; that case is the theorem of Moulines and others (1995) and is cited, not proved here.
Key steps. First, has full column rank: a vector in its null space gives polynomial identities that, by the coprimality of the subchannels, force it to be zero. So the noise subspace is the whole left null space of . Second, the cross-relation vector with blocks lies in that null space. For any candidate , the condition says as sequences. Since the subchannels are coprime, divides , and the degree bound forces . The proofs folder has the details.
What it needs. The channel length must be right. If is too large, the zero padding gives extra solutions, and has a null space of dimension more than 1. The noise must be white with equal power on all outputs, or prewhitened. With a sample covariance, the estimate is consistent as , because the noise subspace depends continuously on when the eigenvalue gap is positive; the error at finite is a measurement.
Proof: With exact statistics and two coprime subchannels, the null space of Q is the channel up to a scalarfull
Setting. . The subchannels are , each with taps , and . Assume and , so the channel has exactly taps. For each , let . Its roots are the zeros of , so "no common zero" means that and are coprime. The window length is . is the block Toeplitz matrix with block equal to . The exact covariance is , with positive definite. The case is the theorem of Moulines, Duhamel, Cardoso and Mayrargue (1995). It is cited and not proved here. The code tests only .
Lemma 1 (full column rank). If , then has rank .
Proof. Let and . Row of is , which is the coefficient of in . So, for each , the coefficients of degrees of vanish. Since , we can write with . Then
because both sides equal minus the same terms. The left side has degree at most . The right side is zero or has degree at least . So both sides are zero, and .
Because , some , say , has , so . Since divides and is coprime to , it divides . But , so . Then , so . Now for both . Because , some has . Then divides , but , so .
Lemma 2 (the noise subspace). The smallest eigenvalues of equal , and their eigenvectors span the left null space .
Proof. is positive semidefinite with range equal to the range of , which has dimension by Lemma 1. So has positive eigenvalues, with eigenvectors spanning that range, and the eigenvalue on its orthogonal complement, which is the left null space of . Adding shifts every eigenvalue by and keeps the eigenvectors.
So line L2, with the exact , returns a basis of the left null space. The code takes real eigenvectors of the real form, which give complex vectors spanning the same -dimensional complex space.
Lemma 3 (what Q measures). For any , . So if and only if for every in the span of .
Proof. Entry of is , which is row of (line L5) times . So , and line L6 sums these. is positive semidefinite, so if and only if . The map is conjugate linear, so it vanishes on a spanning set if and only if it vanishes on the span.
Theorem. Under the setting above, the null space of is . So line L7 returns times a unit scalar.
Proof. If , then for every in the left null space, so by Lemmas 2 and 3.
Conversely, let . Define the cross-relation vector by its blocks for and for . This fits because . Entry of is
which is coefficient of . So is in the left null space, and by Lemmas 2 and 3, . The same computation shows that entry of is coefficient of . The column index runs over , which covers every coefficient. So . In terms of the reversed polynomials, , where is formed from in the same way and has degree at most .
Take with , say . Then divides , and since it is coprime to , it divides . Because , we get for a constant . Then , so . So .
Remark (a common zero). If and share a root , write and let be the channel with for another . Then , so the cross relation no longer separates from . In fact no second-order method can separate them when and the input is white, since the two channels then differ by an allpass factor, up to a scale, and give the same covariance at every lag. The test test_a_common_zero_makes_the_channel_unidentifiable shows that then has a null space of dimension 2.
Remark (sample covariance). With the sample covariance from line L1, as for an ergodic input. The noise subspace is a continuous function of while the gap between and the next eigenvalue is positive, and the null vector of is a continuous function of while the null space has dimension 1. So converges to up to the scalar. The rate is not derived here.
Complexity
Line L1 costs . The eigenproblem of line L2 costs with a standard Hermitian solver (the Jacobi method in the code costs that per sweep). Lines L3 to L6 handle at most vectors, each with rows and a rank-one update of , so . Line L7 is an eigenproblem of size . The extra space is for . All counts are in the real RAM.
Properties
- Blind and second order. It needs only the covariance, not the alphabet, so it works for any input with a full-rank covariance.
- One scalar ambiguity. It returns up to a complex scalar, the least possible ambiguity for second-order statistics.
- Batch. It needs a block of samples long enough for a good covariance estimate.
- Exact with exact statistics. With the true covariance, it returns the true channel up to the scalar.
- Order sensitive. It needs the exact channel length .
Variants and improvements
- Cross-relation method. Xu, Liu, Tong and Kailath (1995) used the identities between every pair of outputs directly on the data, which avoids the eigenvectors of .
- Weighted subspace fitting. Weighting the noise vectors by their eigenvalues gives a smaller variance from finite samples.
- Order estimation. The number of eigenvalues of near gives , from which can be estimated before line L2.
- Equalization from the estimate. With , a zero-forcing or MMSE fractionally spaced equalizer can be designed directly; for and no common zero, an FIR zero-forcing equalizer exists.
- Related subspace methods. The idea of splitting the covariance into a signal subspace and a noise subspace is the same as in the MUSIC algorithm for direction finding.
When to use it
Use the subspace method when the receiver has samples or antennas per symbol, the channel is fixed over a block, and its length is known or can be estimated. In the example, 2000 symbols already give a small error, and there is no local minimum to get stuck in, as there is for CMA. Do not use it at one sample per symbol, where second-order statistics cannot identify the channel, or when the subchannels are nearly coprime only, such as with little excess bandwidth, where the estimate is poor.
Pitfalls
- The wrong channel length in lines L2 and L5. Overestimating leaves a null space of of dimension more than 1, and line L7 returns a mixture. Underestimating it leaves no exact solution.
- A small eigenvalue gap in line L2. If the subchannels nearly share a zero, the smallest signal eigenvalue is close to , and the noise subspace is badly estimated.
- Colored noise. The noise eigenvalues are equal only for white noise of equal power. Prewhiten with the known noise covariance first.
- Taking each eigenvalue once from the real form. The real form of a complex Hermitian matrix has each eigenvalue twice. Line L2 must take real eigenvectors, not .
- Expecting the scalar. The phase and gain of are arbitrary. A pilot, a decision-directed step or a carrier recovery stage must fix them.
Implementations
Each implementation follows the pseudocode above. A comment @line links a line of code to a line of the pseudocode. Point at a line of the pseudocode to see the matching code. The build runs the native tests of each language.
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/subspace-channel-identification/. The authors are listed in prov/8ZFGWM.jsonl.
"""Subspace blind identification of a single-input multiple-output FIR channel.
The channel has P outputs (P samples per symbol, or P antennas) and L taps:
y[k] = sum_l h(l) a[k-l] + w[k], with h(l) a vector of length P. The
stacked vector h = (h(0); h(1); ...; h(L-1)) has length P L, so h[l*P + p]
is tap l of subchannel p.
A window of N output vectors Y[k] = (y[k]; y[k-1]; ...; y[k-N+1]) is
H_N (a[k], ..., a[k-N-L+2]) + noise, where H_N is the P N by (N + L - 1)
block Toeplitz matrix whose block (i, m) is h(m - i). If the subchannels
have no common zero and N >= L, H_N has full column rank. Every vector g of
the noise subspace of R = E[Y Y^H] then satisfies g^H H_N = 0, which is a
set of linear equations in h. Their least squares solution with |h| = 1 is
the eigenvector of the smallest eigenvalue of Q = sum_g G(g)^H G(g).
The Hermitian eigenproblems are solved by the cyclic Jacobi method on the
real symmetric matrix [[B, -C], [C, B]] of A = B + j C.
"""
import math
def jacobi_eigh(a: list[list[float]], tol: float = 1e-14, sweeps: int = 100) -> tuple[list[float], list[list[float]]]:
"""Eigenvalues (ascending) and eigenvectors (as lists) of a real symmetric matrix, by cyclic Jacobi rotations."""
n = len(a)
m = [list(map(float, r)) for r in a]
v = [[1.0 if i == k else 0.0 for k in range(n)] for i in range(n)]
for _ in range(sweeps):
off = sum(m[i][k] ** 2 for i in range(n) for k in range(n) if i != k)
if off <= tol * tol * max(1.0, sum(m[i][i] ** 2 for i in range(n))):
break
for p in range(n - 1):
for q in range(p + 1, n):
if m[p][q] == 0.0:
continue
theta = (m[q][q] - m[p][p]) / (2.0 * m[p][q])
t = (1.0 if theta >= 0 else -1.0) / (abs(theta) + math.sqrt(theta * theta + 1.0))
c = 1.0 / math.sqrt(t * t + 1.0)
s = t * c
for r in range(n):
mrp, mrq = m[r][p], m[r][q]
m[r][p], m[r][q] = c * mrp - s * mrq, s * mrp + c * mrq
for r in range(n):
mpr, mqr = m[p][r], m[q][r]
m[p][r], m[q][r] = c * mpr - s * mqr, s * mpr + c * mqr
for r in range(n):
vrp, vrq = v[r][p], v[r][q]
v[r][p], v[r][q] = c * vrp - s * vrq, s * vrp + c * vrq
order = sorted(range(n), key=lambda i: m[i][i])
return [m[i][i] for i in order], [[v[r][i] for r in range(n)] for i in order]
def hermitian_eigh(a: list[list[complex]]) -> tuple[list[float], list[list[complex]]]:
"""Eigenvalues (ascending) and eigenvectors of a Hermitian matrix A = B + j C.
The real matrix [[B, -C], [C, B]] has each eigenvalue of A twice; an
eigenvector (x; y) of it gives the eigenvector x + j y of A. The result
has 2 n entries: each eigenvalue of A appears twice, with eigenvectors u
and j u (up to rotation within the pair).
"""
n = len(a)
big = [[0.0] * (2 * n) for _ in range(2 * n)]
for i in range(n):
for k in range(n):
b, c = complex(a[i][k]).real, complex(a[i][k]).imag
big[i][k] = b
big[i + n][k + n] = b
big[i][k + n] = -c
big[i + n][k] = c
vals, vecs = jacobi_eigh(big)
return vals, [[complex(v[i], v[i + n]) for i in range(n)] for v in vecs]
def block_toeplitz(h: list[complex], p: int, n: int) -> list[list[complex]]:
"""The P N by (N + L - 1) matrix H_N, with block (i, m) equal to h(m - i)."""
taps = len(h) // p
cols = n + taps - 1
out = [[0j] * cols for _ in range(p * n)]
for i in range(n):
for l in range(taps):
for q in range(p):
out[i * p + q][i + l] = complex(h[l * p + q])
return out
def stack(y: list[list[complex]], n: int) -> list[list[complex]]:
"""The windows Y[k] = (y[k]; y[k-1]; ...; y[k-N+1]) for k = N-1, ..., len(y)-1."""
return [[complex(v) for i in range(n) for v in y[k - i]] for k in range(n - 1, len(y))]
def sample_covariance(windows: list[list[complex]]) -> list[list[complex]]:
"""(1/K) sum of Y Y^H over the windows."""
d = len(windows[0])
r = [[0j] * d for _ in range(d)]
for w in windows:
wc = [v.conjugate() for v in w]
for i in range(d):
wi, ri = w[i], r[i]
for k in range(d):
ri[k] += wi * wc[k]
k = len(windows)
return [[v / k for v in row] for row in r]
def subspace_identify(r: list[list[complex]], p: int, taps: int, n: int) -> list[complex]:
"""Estimate h (length P L, unit norm, up to a complex scalar) from the covariance R of the windows of N outputs."""
if p < 2 or taps < 1 or n < taps or len(r) != p * n:
raise ValueError("need P >= 2, N >= L and R of size P N")
k_noise = p * n - (n + taps - 1)
if k_noise < 1:
raise ValueError("no noise subspace: need P N > N + L - 1")
vals, vecs = hermitian_eigh(r) # @line L2
noise = vecs[: 2 * k_noise] # @line L2
q = [[0j] * (p * taps) for _ in range(p * taps)] # @line L3
for g in noise: # @line L4
blocks = [g[i * p : (i + 1) * p] for i in range(n)]
for m in range(n + taps - 1): # @line L5
row = [0j] * (p * taps) # @line L5
for l in range(taps): # @line L5
if 0 <= m - l < n: # @line L5
for s in range(p): # @line L5
row[l * p + s] = blocks[m - l][s].conjugate() # @line L5
rc = [v.conjugate() for v in row] # @line L6
for i in range(p * taps): # @line L6
for k in range(p * taps): # @line L6
q[i][k] += rc[i] * row[k] # @line L6
qvals, qvecs = hermitian_eigh(q) # @line L7
h = qvecs[0] # @line L7
norm = math.sqrt(sum(abs(v) ** 2 for v in h)) # @line L7
return [v / norm for v in h] # @line L8
def identify_from_samples(y: list[list[complex]], p: int, taps: int, n: int) -> list[complex]:
"""Form the sample covariance of the windows (line L1) and run subspace_identify."""
r = sample_covariance(stack(y, n)) # @line L1
return subspace_identify(r, p, taps, n)
def q_eigenvalues(r: list[list[complex]], p: int, taps: int, n: int) -> list[float]:
"""The eigenvalues of Q (each twice, ascending), to test identifiability."""
k_noise = p * n - (n + taps - 1)
vals, vecs = hermitian_eigh(r)
q = [[0j] * (p * taps) for _ in range(p * taps)]
for g in vecs[: 2 * k_noise]:
blocks = [g[i * p : (i + 1) * p] for i in range(n)]
for m in range(n + taps - 1):
row = [0j] * (p * taps)
for l in range(taps):
if 0 <= m - l < n:
for s in range(p):
row[l * p + s] = blocks[m - l][s].conjugate()
for i in range(p * taps):
for k in range(p * taps):
q[i][k] += row[i].conjugate() * row[k]
return hermitian_eigh(q)[0]
test_subspace_channel_identification.py 109 lines
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/subspace-channel-identification/. The authors are listed in prov/8ZFGWM.jsonl.
import math
import random
import pytest
from subspace_channel_identification import (
block_toeplitz,
hermitian_eigh,
identify_from_samples,
q_eigenvalues,
subspace_identify,
)
def conv(a, b):
out = [0j] * (len(a) + len(b) - 1)
for i, x in enumerate(a):
for k, y in enumerate(b):
out[i + k] += x * y
return out
def stack_subchannels(subs):
# h[l * P + p] is tap l of subchannel p
return [complex(subs[p][l]) for l in range(len(subs[0])) for p in range(len(subs))]
def exact_covariance(h, p, n, s2):
hn = block_toeplitz(h, p, n)
d = len(hn)
return [[sum(hn[i][m] * hn[k][m].conjugate() for m in range(len(hn[0]))) + (s2 if i == k else 0) for k in range(d)] for i in range(d)]
def misalignment(he, h):
# 1 - |he^H h|^2 / (|he|^2 |h|^2): 0 when he is a scalar times h
ip = sum(a.conjugate() * b for a, b in zip(he, h))
return 1 - abs(ip) ** 2 / (sum(abs(v) ** 2 for v in he) * sum(abs(v) ** 2 for v in h))
H3 = stack_subchannels([[1, 0.5 + 0.2j, -0.3], [0.4j, 1, 0.6]])
def test_hermitian_eigensolver() -> None:
rng = random.Random(1)
n = 5
a = [[0j] * n for _ in range(n)]
for i in range(n):
a[i][i] = complex(rng.gauss(0, 1))
for k in range(i + 1, n):
a[i][k] = complex(rng.gauss(0, 1), rng.gauss(0, 1))
a[k][i] = a[i][k].conjugate()
vals, vecs = hermitian_eigh(a)
assert all(vals[i] <= vals[i + 1] for i in range(len(vals) - 1))
for lam, v in zip(vals, vecs):
av = [sum(a[i][k] * v[k] for k in range(n)) for i in range(n)]
assert max(abs(x - lam * y) for x, y in zip(av, v)) < 1e-10
def test_hand_example() -> None:
# subchannels (1, 0.5) and (0.5, 1), N = 2: the noise vector is (-1, 2, -2, 1) up to scale
h = stack_subchannels([[1, 0.5], [0.5, 1]])
r = exact_covariance(h, 2, 2, 0.3)
vals, vecs = hermitian_eigh(r)
g = vecs[0]
ref = [-1, 2, -2, 1]
assert misalignment(g, [complex(v) for v in ref]) < 1e-12
assert abs(vals[0] - 0.3) < 1e-10
he = subspace_identify(r, 2, 2, 2)
assert misalignment(he, h) < 1e-12
def test_exact_covariance_gives_the_channel_up_to_a_scalar() -> None:
for n in (3, 4):
he = subspace_identify(exact_covariance(H3, 2, n, 0.1), 2, 3, n)
assert misalignment(he, H3) < 1e-12
assert abs(sum(abs(v) ** 2 for v in he) - 1) < 1e-12
def test_sample_covariance_gives_a_small_error() -> None:
rng = random.Random(1)
k = 2000
s = math.sqrt(0.005)
a = [complex(rng.choice((-1, 1)), rng.choice((-1, 1))) / math.sqrt(2) for _ in range(k)]
y = [
[sum(H3[l * 2 + q] * a[t - l] for l in range(3) if t - l >= 0) + complex(rng.gauss(0, s), rng.gauss(0, s)) for q in range(2)]
for t in range(k)
]
for n in (3, 4):
assert misalignment(identify_from_samples(y, 2, 3, n), H3) < 0.005
def test_a_common_zero_makes_the_channel_unidentifiable() -> None:
common = stack_subchannels([conv([1, -0.5], [1, 0.3]), conv([1, -0.5], [0.2, 1])])
q_bad = q_eigenvalues(exact_covariance(common, 2, 3, 0.1), 2, 3, 3)
q_good = q_eigenvalues(exact_covariance(H3, 2, 3, 0.1), 2, 3, 3)
# each eigenvalue appears twice; entries 0, 1 are the null vector, entries 2, 3 the next one
assert abs(q_bad[2]) < 1e-10
assert q_good[2] > 1e-3
def test_bad_input() -> None:
r = exact_covariance(H3, 2, 3, 0.1)
with pytest.raises(ValueError):
subspace_identify(r, 2, 3, 2)
with pytest.raises(ValueError):
subspace_identify(r, 1, 3, 6)
History
Tong, Xu and Kailath showed in 1991 that the second-order statistics of a fractionally sampled output identify the channel, which started the second-order blind methods. Moulines, Duhamel, Cardoso and Mayrargue (1995) gave the subspace method, which uses the noise subspace of the stacked covariance, and Xu, Liu, Tong and Kailath (1995) gave the closely related cross-relation method.
References
- Eric Moulines, Pierre Duhamel, Jean-Francois Cardoso and Sylvie Mayrargue, Subspace methods for the blind identification of multichannel FIR filters, IEEE Transactions on Signal Processing 43(2), 1995, pages 516 to 525, the block Toeplitz model, its full column rank for a window at least as long as the channel, and the identification of the channel from the noise subspace
- Lang Tong, Guanghan Xu and Thomas Kailath, Blind identification and equalization based on second-order statistics: a time domain approach, IEEE Transactions on Information Theory 40(2), 1994, pages 340 to 349, identifiability from second-order statistics when the subchannels have no common zero
- Guanghan Xu, Hui Liu, Lang Tong and Thomas Kailath, A least-squares approach to blind channel identification, IEEE Transactions on Signal Processing 43(12), 1995, the cross-relation method, which uses the same identity between pairs of subchannels
About this page
The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.
| Ladder | Level | What the next level needs |
|---|---|---|
| Human proof | H1 sketch |
|
| Lean | L0 no Lean part |
|
| Code (python) | I0 not checked yet |
|
| Visual | V0 none |
|
| Writing | W2 basic |
|
Tag 8ZFGWM Edit this page History Report an error Markdown