Matched Filter and Correlator Receiver

Why the Matched Filter Is Fundamental

The matched filter is the optimal linear receiver for detecting a known signal in AWGN. It maximizes the output SNR and is the basis of every receiver from BPSK detectors to radar pulse compressors. Understanding the matched filter connects modulation theory to practical implementation.

Definition:

Matched Filter

The matched filter for a known signal s(t)s(t) of duration TT has impulse response:

h(t)=sβˆ—(Tβˆ’t)h(t) = s^*(T - t)

The output at time TT is:

y(T)=∫0Tr(Ο„)sβˆ—(Ο„) dΟ„y(T) = \int_0^T r(\tau) s^*(\tau)\,d\tau

which is the correlation of the received signal with the template. In discrete time:

y[n]=βˆ‘k=0Lβˆ’1r[k]β‹…sβˆ—[k]y[n] = \sum_{k=0}^{L-1} r[k] \cdot s^*[k]

def matched_filter(received, template):
    """Correlator receiver: inner product with template."""
    return np.sum(received * np.conj(template))

Definition:

Bank of Correlators

For MM-ary detection, the receiver computes MM correlations and picks the largest:

m^=arg⁑max⁑mβ€…β€ŠRe ⁣[βˆ‘kr[k]β‹…smβˆ—[k]]\hat{m} = \arg\max_{m} \; \text{Re}\!\left[\sum_{k} r[k] \cdot s_m^*[k]\right]

This is equivalent to ML detection when all symbols have equal energy.

def correlator_bank(received_block, templates):
    """Correlator bank: returns detected symbol index."""
    correlations = np.array([
        np.real(np.sum(received_block * np.conj(t)))
        for t in templates
    ])
    return np.argmax(correlations)

Definition:

Output SNR of the Matched Filter

The matched filter output SNR is:

SNRout=∣ysignal(T)∣2E[∣ynoise(T)∣2]=2EsN0\text{SNR}_{\text{out}} = \frac{|y_{\text{signal}}(T)|^2}{E[|y_{\text{noise}}(T)|^2]} = \frac{2E_s}{N_0}

where Es=∫0T∣s(t)∣2 dtE_s = \int_0^T |s(t)|^2\,dt is the signal energy. This depends only on the signal energy, not its shape.

Theorem: Matched Filter Maximizes Output SNR

Among all linear filters h(t)h(t), the matched filter h(t)=sβˆ—(Tβˆ’t)h(t) = s^*(T-t) maximizes the output signal-to-noise ratio. By the Cauchy-Schwarz inequality:

SNRout=∣⟨r,s⟩∣2Οƒ2βˆ₯hβˆ₯2≀βˆ₯sβˆ₯2Οƒ2=2EsN0\text{SNR}_{\text{out}} = \frac{|\langle r, s \rangle|^2}{\sigma^2 \|h\|^2} \le \frac{\|s\|^2}{\sigma^2} = \frac{2E_s}{N_0}

with equality when h(t)=Ξ±β‹…sβˆ—(Tβˆ’t)h(t) = \alpha \cdot s^*(T-t) for any Ξ±β‰ 0\alpha \neq 0.

The matched filter "collects" all the signal energy while weighting the noise optimally. It is the time-domain analog of the water-filling solution.

Theorem: Matched Filter and Correlator Equivalence

The matched filter output sampled at t=Tt = T equals the correlator output:

yMF(T)=(rβˆ—h)(T)=∫0Tr(Ο„)sβˆ—(Ο„) dΟ„=ycorry_{\text{MF}}(T) = (r * h)(T) = \int_0^T r(\tau) s^*(\tau)\,d\tau = y_{\text{corr}}

Both implementations produce identical decisions. The matched filter is an LTI system (filter then sample); the correlator multiplies then integrates (no filtering).

Convolution with a time-reversed conjugate is the same as correlation. The matched filter is better for continuous-time hardware; the correlator is natural in DSP where you have the samples in memory.

Theorem: Sufficient Statistic for AWGN Detection

The matched filter outputs {ym}m=1M\{y_m\}_{m=1}^{M} form a sufficient statistic for detection: no other processing of r(t)r(t) can improve the error probability. The noise in the matched filter output orthogonal to the signal subspace carries no information about which symbol was sent.

The matched filter projects r(t)r(t) onto the signal subspace, discarding the noise component orthogonal to all signals.

Example: BPSK Matched Filter Implementation

Implement a matched filter receiver for BPSK with raised-cosine pulse shaping. Show that the matched filter output SNR matches 2Eb/N02E_b/N_0.

Example: Eye Diagram from Matched Filter Output

Generate an eye diagram from the matched filter output to visualize inter-symbol interference and noise margin.

Matched Filter Output Visualization

Visualize the matched filter operation: input signal, filter, and output with sampling instants marked.

Parameters

Common Mistake: Not Normalizing the Matched Filter

Mistake:

Using np.correlate(rx, pulse) without normalizing the pulse energy, leading to incorrect SNR measurements.

Correction:

Normalize the pulse to unit energy: pulse /= np.sqrt(np.sum(pulse**2)). The matched filter output then directly gives the sufficient statistic.

Why This Matters: Matched Filtering in RAKE Receivers

In CDMA systems, the RAKE receiver applies matched filtering independently to each multipath component, then combines the outputs. Each RAKE finger is a correlator matched to the spreading code, time-aligned to a different path delay. This extracts the multipath diversity that a single correlator would miss.

See full treatment in Chapter 21

Matched Filter

A linear filter whose impulse response is the time-reversed conjugate of the target signal, h(t)=sβˆ—(Tβˆ’t)h(t) = s^*(T-t). Maximizes output SNR in AWGN.

Correlator Receiver

A receiver that multiplies the received signal by each possible template and integrates, selecting the template with largest output.

Eye Diagram

A visualization of overlaid symbol-period segments of a signal, showing the noise margin, timing jitter, and ISI at a glance.