The Hilbert transform is a linear operator that takes a real-valued signal \( x(t) \) and produces another real-valued signal \( \hat{x}(t) \), often called its quadrature counterpart. In the time domain, it is defined as the convolution of \( x(t) \) with the kernel \( 1/(\pi t) \):
where p.v. denotes the Cauchy principal value, which handles the singularity at \( \tau = t \). In practice, the Hilbert transform is most easily understood in the frequency domain.
Frequency-Domain Interpretation
The Hilbert transform shifts the phase of every positive-frequency component by \( -90^\circ \) (i.e., \( -\pi/2 \) radians) and every negative-frequency component by \( +90^\circ \). The magnitude of each spectral component remains unchanged. The transfer function of the Hilbert transformer is:
where \( \operatorname{sgn}(f) \) is the sign function: \( +1 \) for \( f > 0 \), \( -1 \) for \( f < 0 \), and \( 0 \) for \( f = 0 \). This makes the Hilbert transform an ideal phase shifter – it preserves energy while rotating the phase by a quarter cycle.
The Analytic Signal
One of the most important applications of the Hilbert transform is the construction of the analytic signal:
The analytic signal has no negative-frequency components. Its magnitude is the envelope (instantaneous amplitude) of \( x(t) \), and its phase derivative gives the instantaneous frequency. This is the mathematical foundation for envelope detection, as discussed in the previous article.
Envelope and Instantaneous Frequency
Given the analytic signal \( x_a(t) \), we can extract:
- Envelope (instantaneous amplitude): \( e(t) = |x_a(t)| = \sqrt{x(t)^2 + \hat{x}(t)^2} \)
- Instantaneous phase: \( \phi(t) = \arg\{x_a(t)\} = \operatorname{atan2}\!\big(\hat{x}(t),\, x(t)\big) \)
- Instantaneous frequency: \( f_i(t) = \dfrac{1}{2\pi} \cdot \dfrac{d\phi(t)}{dt} \)
For a pure sinusoidal carrier modulated by a slowly varying envelope, the Hilbert transform provides a clean, delay-free way to recover the envelope – unlike rectification or RMS smoothing, which introduce distortion or lag.
Properties
The Hilbert transform has several remarkable properties:
- Orthogonality: \( x(t) \) and \( \hat{x}(t) \) are orthogonal over infinite time: \( \int x(t) \hat{x}(t) \, dt = 0 \).
- Double application: Applying the Hilbert transform twice negates the original signal: \( \mathcal{H}\{\mathcal{H}\{x(t)\}\} = -x(t) \).
- Energy preservation: The total energy of \( x(t) \) equals that of \( \hat{x}(t) \).
- Linearity and shift-invariance: The transform is linear and time-invariant.
Figure 1: An amplitude-modulated carrier (blue), its Hilbert transform (orange), and the resulting envelope (green). The envelope perfectly tracks the slow amplitude variations (the modulation), demonstrating the power of the analytic signal.
The plot above shows an amplitude-modulated (AM) signal: a 10 Hz carrier whose amplitude varies slowly as \( 1 + 0.5 \cdot \cos(2\pi \cdot 0.5 \cdot t) \). The Hilbert transform (orange) is a \( 90^\circ \) phase-shifted version of the carrier, with the same envelope. The green curve is the magnitude of the analytic signal – it cleanly recovers the modulating envelope without any lag or distortion.
Note that for narrowband signals (like the one shown), the Hilbert transform behaves intuitively. For broadband signals (like speech or music), the instantaneous frequency becomes noisy, and the envelope is often computed in sub-bands using filter banks.
Applications in DSP
The Hilbert transform is a cornerstone of modern signal processing and appears in numerous applications:
- AM demodulation: Extracting the message signal from an amplitude-modulated carrier.
- Instantaneous frequency estimation: Analysing frequency-modulated (FM) signals, chirps, and vibrato.
- Audio effects: Phase vocoders, pitch shifting, and time stretching rely on the analytic signal.
- Radar and sonar: Envelope detection and Doppler shift analysis.
- Seismology and geophysics: Analysing wave propagation and dispersion.
- Biomedical signal processing: Extracting the envelope of ECG, EEG, and respiratory signals.
- Communication systems: Generating single-sideband (SSB) modulation and I/Q demodulation.
Practical Considerations and Limitations
While the Hilbert transform is mathematically elegant, it has practical constraints:
- Finite-length signals: In practice, we can only approximate the Hilbert transform using FIR or IIR filters. The ideal \(-90^\circ\) phase shift is impossible to achieve exactly with finite delay.
- Narrowband assumption: The instantaneous frequency is physically meaningful only for monocomponent (narrowband) signals. For wideband signals, the instantaneous frequency can be ambiguous or noisy.
- Noise sensitivity: The Hilbert transform amplifies noise if the signal-to-noise ratio is poor, because the \( 1/t \) kernel acts as a differentiator.
- Edge effects: At the boundaries of a finite signal, the Hilbert transform produces artefacts due to the missing samples outside the interval.
Despite these limitations, the Hilbert transform remains one of the most versatile tools in the DSP toolbox. It bridges the time and frequency domains by providing a way to define instantaneous amplitude and frequency – concepts that are intuitive but mathematically subtle. From vintage analogue synthesizers to cutting‑edge 5G modems, the Hilbert transform quietly powers the systems that shape our modern world.