Rayleigh and Ricean Fading
Small-Scale Fading: The Wireless Channel's Signature
Small-scale fading causes rapid amplitude fluctuations as the receiver moves, due to constructive and destructive interference of multipath components. Understanding and simulating fading is essential for designing reliable wireless systems.
Definition: Rayleigh Fading Channel
Rayleigh Fading Channel
When there is no line-of-sight (LOS) path, the channel coefficient is:
The envelope PDF is for (unit power), and the power .
rng = np.random.default_rng(42)
N = 100000
h = (rng.standard_normal(N) + 1j*rng.standard_normal(N)) / np.sqrt(2)
# |h| is Rayleigh, |h|^2 is Exponential(1)
print(f"Mean |h|^2 = {np.mean(np.abs(h)**2):.4f}") # ~1.0
Definition: Ricean Fading Channel
Ricean Fading Channel
When a LOS component exists, the channel is Ricean:
where is the Ricean -factor (ratio of LOS to scattered power). gives Rayleigh; gives AWGN.
def ricean_channel(K, N, rng=None):
if rng is None:
rng = np.random.default_rng()
w = (rng.standard_normal(N) + 1j*rng.standard_normal(N)) / np.sqrt(2)
h = np.sqrt(K/(K+1)) + np.sqrt(1/(K+1)) * w
return h
The envelope follows a Rice distribution. As increases, the deep fades become less severe.
Definition: Nakagami-m Fading
Nakagami-m Fading
The Nakagami-m distribution generalizes Rayleigh () and approximates Ricean (). The power PDF is:
where . Useful when fitting measured data.
from scipy.stats import nakagami
m, Omega = 2.0, 1.0
samples = nakagami.rvs(m, scale=np.sqrt(Omega), size=10000)
Definition: Clarke-Jakes Doppler Spectrum
Clarke-Jakes Doppler Spectrum
For a mobile receiver moving at speed , the maximum Doppler frequency is . The Clarke-Jakes autocorrelation is:
and the Doppler power spectrum is:
from scipy.special import j0
fd = 100 # Hz (60 km/h at 1.8 GHz)
dt = np.linspace(0, 0.01, 200)
R_h = j0(2 * np.pi * fd * dt)
Definition: Coherence Time and Coherence Bandwidth
Coherence Time and Coherence Bandwidth
The coherence time is the time duration over which the channel remains approximately constant:
The coherence bandwidth is the frequency range over which the channel has approximately flat gain:
where is the RMS delay spread.
Theorem: BER of BPSK in Rayleigh Fading
The average BER of BPSK over a Rayleigh fading channel is:
where is the average SNR. At high SNR, , decaying as instead of exponentially.
Fading destroys the exponential BER improvement. The probability of a deep fade () dominates the average BER. This is why diversity is essential for reliable wireless communication.
Average over fading
where and .
Closed-form evaluation
Using the integral identity for with exponential PDF yields .
Theorem: Diversity Order and BER Slope
With -fold diversity (MRC combining), the average BER at high SNR scales as:
The diversity order equals the negative slope of the BER curve (in log-log scale) at high SNR.
Each independent diversity branch reduces the probability of a simultaneous deep fade. branches give a dB/decade slope instead of just 10 dB/decade for no diversity.
Theorem: Level Crossing Rate of Rayleigh Fading
The rate at which the Rayleigh fading envelope crosses a threshold from below is:
where is the normalized threshold. The average fade duration below is:
A mobile at 60 km/h at 2 GHz experiences about 50-100 fades per second below the RMS level.
Example: Generating Time-Correlated Rayleigh Fading
Generate a Rayleigh fading process with Jakes spectrum using the filter method (IFFT of shaped spectrum).
Spectral shaping
import numpy as np
def jakes_fading(N, fd, fs):
"""Generate Jakes-spectrum Rayleigh fading."""
f = np.fft.fftfreq(N, 1/fs)
S = np.zeros(N)
mask = np.abs(f) < fd
S[mask] = 1 / (np.pi * fd * np.sqrt(1 - (f[mask]/fd)**2 + 1e-10))
S /= np.sqrt(np.sum(S))
# Shape white Gaussian noise
rng = np.random.default_rng(42)
noise = rng.standard_normal(N) + 1j*rng.standard_normal(N)
H = np.fft.fft(noise) * np.sqrt(S)
h = np.fft.ifft(H)
h /= np.sqrt(np.mean(np.abs(h)**2)) # unit power
return h
Example: BER Simulation Over Rayleigh Fading
Simulate BPSK BER over Rayleigh fading and compare with the closed-form expression.
Simulation
def ber_bpsk_rayleigh_sim(EbN0_dB_range, N_bits=1000000):
rng = np.random.default_rng(42)
results = []
for EbN0_dB in EbN0_dB_range:
EbN0 = 10**(EbN0_dB/10)
bits = rng.integers(0, 2, N_bits)
s = 2*bits - 1
h = (rng.standard_normal(N_bits) + 1j*rng.standard_normal(N_bits)) / np.sqrt(2)
n = (rng.standard_normal(N_bits) + 1j*rng.standard_normal(N_bits)) / np.sqrt(2*EbN0)
r = h * s + n
# Coherent detection (perfect CSI)
s_hat = np.sign(np.real(np.conj(h) * r))
ber = np.mean((s_hat < 0) != (bits == 0))
results.append(ber)
return results
Example: Estimating the Ricean K-Factor
Given channel envelope samples, estimate the Ricean -factor using the moment-based method.
Moment estimator
def estimate_K(h_samples):
"""Estimate K-factor from channel samples (moment method)."""
r = np.abs(h_samples)
r2 = r**2
mean_r2 = np.mean(r2)
var_r2 = np.var(r2)
# K = sqrt(mean^2 - var) / (mean - sqrt(mean^2 - var))
# Simplified: K = (mean_r2^2 - var_r2) / var_r2 if available
ratio = mean_r2**2 / (mean_r2**2 - var_r2 + 1e-10)
K = ratio - 1
return max(K, 0)
Fading Channel Realizations
Generate and visualize Rayleigh and Ricean fading envelopes with adjustable K-factor and Doppler frequency.
Parameters
BER: AWGN vs Rayleigh vs Ricean
Compare BPSK BER over AWGN, Rayleigh, and Ricean channels.
Parameters
Fading Envelope Over Time
Watch the Rayleigh fading envelope evolve as time progresses, highlighting deep fades below a threshold.
Parameters
Quick Check
How does the BER of uncoded BPSK decrease with SNR over a Rayleigh fading channel at high SNR?
Exponentially (like AWGN)
As (diversity order 1)
As (diversity order 2)
Remains constant
Correct: without diversity, fading causes BER at high SNR.
Quick Check
What happens to a Ricean channel as ?
It becomes Rayleigh
It becomes an AWGN channel
The channel gain goes to zero
The Doppler spread increases
As , the LOS dominates and fading vanishes.
Common Mistake: Not Normalizing Channel Power
Mistake:
Generating Rayleigh fading with without the factor, giving instead of 1.
Correction:
Always use h = (randn + 1j*randn) / sqrt(2) for unit-power Rayleigh.
Verify with np.mean(np.abs(h)**2).
Key Takeaway
Rayleigh fading degrades BER from exponential (AWGN) to decay. Diversity (spatial, frequency, time) is the only way to restore steep BER curves. The Ricean -factor quantifies the LOS strength and interpolates between Rayleigh () and AWGN ().
Why This Matters: From Fading to OFDM
Frequency-selective fading (when bandwidth exceeds ) causes inter-symbol interference. OFDM solves this by dividing the wideband channel into many narrowband subcarriers, each experiencing flat fading. This is why OFDM is the waveform of choice in 4G, 5G, and Wi-Fi.
See full treatment in Chapter 22
Historical Note: William Jakes and Mobile Radio
1974William Jakes of Bell Labs published 'Microwave Mobile Communications' in 1974, establishing the theoretical framework for mobile radio channels. The Clarke-Jakes model with its autocorrelation and U-shaped Doppler spectrum remains the standard reference for mobile fading simulation.
Historical Note: Stephen O. Rice and the Rice Distribution
1944-1945Stephen O. Rice of Bell Labs derived the distribution of the envelope of a sinusoid plus Gaussian noise in 1944-1945. His work, published in the Bell System Technical Journal, laid the mathematical foundation for all subsequent fading channel analysis.
Rayleigh Fading
Fading model for channels without a line-of-sight path; the envelope of the complex Gaussian channel coefficient follows a Rayleigh distribution.
Related: Ricean Fading
Ricean Fading
Fading model with a dominant LOS component; characterized by the -factor. Reduces to Rayleigh when .
Related: Rayleigh Fading
Doppler Spread
The range of frequency shifts caused by relative motion between transmitter and receiver; .
Coherence Time
The time interval over which the channel fading coefficient remains approximately constant; inversely proportional to Doppler spread.
Fading Model Comparison
| Property | Rayleigh | Ricean | Nakagami-m |
|---|---|---|---|
| LOS component | No | Yes | Parametric |
| Envelope PDF | Rice distribution | Nakagami PDF | |
| -factor | |||
| BER slope at high SNR | Between and exp | Depends on | |
| Deep fade probability | High | Moderate | Tunable |
| Python (scipy) | rayleigh | rice | nakagami |