5G NR Interactive PHY Simulator

Full DL chain: DU TX → O-RAN Fronthaul → O-RU TX → OTA Channel → UE/O-RU RX → DU RX. Every block is interactive — sliders drive live canvas/chart updates in your browser.

System Configuration LIVE
32 TRX 16 max layers 30 kHz SCS 132 PRBs Array gain 15.05 dB λ/2 = 42.86 mm DDDSUUDDDD TDD EIRP ≈ 50 dBm

Complete DL Chain

22+ blocks added to the original description: TB → CRC → LDPC → Rate matching → Bit interleaving → eCPRI framing → CP addition → DAC → RF upconversion → PA → Shadow fading → Doppler → LNA → RF downconversion → CP removal → Channel estimation → MMSE equalization → Layer/RE demapping → Antenna array config → O-RU attenuators → RF link budget (RSRP/RSSI/SINR/CQI) → Inter-cell interference.

§1 — DU TX Encoding Chain

§1.1 — Transport Block & CRC-24A

The MAC layer delivers a MAC PDU to the PHY layer as a contiguous bit string. The PHY wraps this into a Transport Block (TB) and appends a 24-bit CRC (CRC-24A per TS 38.212 §5.1) before any further processing. The CRC remainder is computed by dividing the TB bit polynomial by the generator g(x) and appending the 24-bit remainder.

CRC-24A generator polynomial (TS 38.212 §5.1):
g(x) = x²⁴ + x²³ + x¹⁸ + x¹⁷ + x¹⁴ + x¹¹ + x¹⁰ + x⁷ + x⁶ + x⁵ + x⁴ + x³ + x + 1

Maximum TB size with Base Graph 1, Zc=384, and C=334 code blocks: 1,277,992 bits — sufficient for peak rates of ~7.7 Gb/s at 100 MHz × 16 layers × 256-QAM × R=948/1024.

Insight: CRC-24A detects all error patterns of weight ≤ 24 bits and all burst errors of length ≤ 24. The 24-bit overhead per TB is negligible — for a 1 MB TB it represents only 0.0029% overhead.

XOR CRC Concept — 8-bit Example

The CRC is computed by treating the message as a polynomial and performing polynomial long division (XOR arithmetic) by the generator. Below is a simplified 8-bit message with 8-bit CRC-8 illustration showing the XOR steps:

CRC XOR Visualization (CRC-8 simplified demo)

§1.2 — LDPC Encoding

5G NR uses LDPC (Low-Density Parity-Check) codes with two base graphs (TS 38.212 §5.3.2). The parity-check matrix H is constructed via quasi-cyclic lifting of a base matrix using a lifting factor Zc.

Parameter Base Graph 1 (BG1) Base Graph 2 (BG2)
Use caseLarge TBs, high code rate (R > 1/4, K_b ≥ 9)Small TBs or low code rate
Information columns K_b2210
Encoded length N66 × Z_c50 × Z_c
Max Z_c384256
Max CB size8448 bits3840 bits
Max N per CB25344 bits12800 bits

The 22 valid Z_c lifting factors are drawn from 8 sets (index iLS = 0..7):

Set 0: 2, 4, 8, 16, 32, 64, 128, 256
Set 1: 3, 6, 12, 24, 48, 96, 192, 384
Set 2: 5, 10, 20, 40, 80, 160, 320
Set 3: 7, 14, 28, 56, 112, 224
Set 4: 9, 18, 36, 72, 144, 288
Set 5: 11, 22, 44, 88, 176, 352
Set 6: 13, 26, 52, 104, 208
Set 7: 15, 30, 60, 120, 240

LDPC Rate Calculator

§1.3 — Rate Matching & HARQ

After LDPC encoding, the Ncb-bit circular buffer is rate-matched to produce exactly E bits for transmission. The start position k0 in the buffer depends on the Redundancy Version (RV), allowing HARQ incremental redundancy — each retransmission reveals a different segment of the codeword.

BG1 RV start positions (TS 38.212 §5.4.2.1):
RV0: k₀ = 0  |  RV1: k₀ = ⌊17·Z_c / 66⌋  |  RV2: k₀ = ⌊33·Z_c / 66⌋  |  RV3: k₀ = ⌊56·Z_c / 66⌋
Rate-matching output: E = N_RE × Q_m × νlayers / C
HARQ Chase Combining vs Incremental Redundancy: RV0 always contains systematic bits (self-decodable). RV1/2/3 shift into parity regions — the UE combines all received versions in the HARQ soft buffer for an effective coding gain without re-transmitting systematic bits.

HARQ Circular Buffer

§1.4 — Scrambling

The rate-matched bit sequence is XOR-scrambled with a pseudo-random Gold sequence before modulation mapping. This randomizes the bit pattern and makes inter-cell interference appear as uncorrelated noise (each cell/UE uses a different initialization).

The Gold sequence is generated by XORing two length-31 LFSR sequences (polynomials x28 + x3 + 1 and x28 + x9 + 1), initialized at position 1600 to ensure statistical independence between sequences.

$$c_{\text{init}} = n_{\text{RNTI}} \cdot 2^{15} + q \cdot 2^{14} + n_{\text{ID}}$$

where nRNTI is the UE's radio network temporary identifier (16-bit), q ∈ {0, 1} is the codeword index, and nID ∈ {0,…,1023} is the data scrambling identity (defaults to cell ID NIDcell).

Example — 16-bit before & after scrambling:

§2 — Modulation, Layer Mapping & Precoding

Following scrambling, coded bits are mapped to complex QAM symbols, distributed across ν transmission layers, and finally precoded through the 32-port antenna array (N1=8 azimuth × N2=4 elevation × 2-pol) using a Type I codebook matrix W = W1 × W2.

§2.1 — QAM Constellation Simulator

Modulation order is signalled via the MCS index in DCI (TS 38.214 Table 5.1.3.1-2). The system supports QPSK, 16-QAM, 64-QAM, and 256-QAM. Higher-order constellations deliver more bits per symbol but require higher SNR to maintain target BLER.

QAM Constellation — Live with AWGN

Insight — EVM requirements (TS 38.104): QPSK requires EVM ≤ 17.5%, 16-QAM ≤ 12.5%, 64-QAM ≤ 8%, 256-QAM ≤ 3.5%. Higher-order modulation demands tighter RF chain linearity and phase noise.

§2.2 — Layer Mapping

After modulation, QAM symbols are distributed across ν transmission layers (TS 38.211 §7.3.1.3). For the 32TRX DU with NT=32 antenna ports and NR=32 receive antennas (assumed), the maximum rank is νmax = min(NT, NR) up to 16 layers for PDSCH.

CodewordsLayer range νMapping rule
1 CW1 – 4d⁽⁰⁾_l(i) = x⁽⁰⁾(ν·i + l), l = 0,…,ν−1
2 CWs5 – 8CW0 → layers 0…⌈ν/2⌉−1; CW1 → layers ⌈ν/2⌉…ν−1
2 CWs9 – 16As above, extended per TS 38.211 Table 7.3.1.3-1

Layer Mapping — Symbol Distribution

§2.3 — Precoding (W = W1 × W2)

The layered symbols x ∈ ℂν×1 are precoded to 32 antenna ports via W ∈ ℂ32×ν. For the 32-port UPA (N1=8, N2=4, 2-pol), 5G NR uses Type I Single-Panel codebook (TS 38.214 §5.2.2.2).

The precoding matrix factorises as W = W1 · W2:

Beam steering vector (H-plane ULA):
a(θ) = [1, e^{j2πd/λ sin(θ)}, …, e^{j2π(N1-1)d/λ sin(θ)}]^T   where d/λ = 0.5 (half-wavelength spacing)

Precoding Beam Pattern — W = W1×W2

Note — Type I vs Type II codebooks: Type I codebooks (used above) target single-user MIMO with up to 8 layers using 2-level W1/W2 structure. Type II codebooks (TS 38.214 §5.2.2.2.3) use linear combinations of DFT beams with 2-bit amplitude quantization for enhanced MU-MIMO and support up to 4 layers per UE. The 32TRX system benefits from Type II for the 128-UE MU-MIMO scenario.

§2.4 — Summary: Key Equations

QAM symbol energy (normalised constellation, minimum distance δ):

$$E_s = \frac{M-1}{3} \cdot \delta^2$$

For normalised constellations (unit average energy), δ = √(3/(M−1)). E.g. 256-QAM: δ = √(3/255) ≈ 0.1085, confirming E_s = 1.

Layer mapping — single codeword, ν layers:

$$d^{(0)}_l(i) = x^{(0)}(\nu i + l), \quad l = 0, 1, \ldots, \nu - 1$$

Symbol x(0)(k) from codeword 0 is demultiplexed across ν layers in a round-robin fashion. Total symbols on layer l: ⌊Msymb/ν⌋ where Msymb is the total modulated symbols.

Precoded output:

$$\mathbf{y} = \mathbf{W} \cdot \mathbf{x}, \quad \mathbf{W} \in \mathbb{C}^{32 \times \nu}, \quad \mathbf{x} \in \mathbb{C}^{\nu \times 1}$$

y ∈ ℂ32×1 feeds the 32-port IFFT inputs (one per antenna port). Power normalisation: W is scaled so ‖W‖_F² = ν, preserving total transmit power regardless of rank.

Peak spectral efficiency — full system:

$$\eta_{\max} = \nu \cdot Q_m \cdot R \cdot \frac{N_{\text{PRB}} \cdot 12 \cdot N_{\text{sym}}}{T_{\text{slot}}}$$

For 16 layers, 256-QAM (Q_m=8), R=948/1024, 132 PRBs, 13 PDSCH symbols per slot, T_slot=0.5 ms (μ=1): η_max ≈ 16 × 8 × 0.926 × 132 × 12 × 13 / 0.5 ms ≈ 7.1 Gbps peak DL throughput.

End-to-end chain summary (§1→§2): MAC PDU → [CRC-24A] → [LDPC BG1/BG2] → [Rate Match / Circular Buffer] → [Scramble] → [QAM Map] → [Layer Map ×ν] → [Precoder W=W1·W2] → 32 IFFT inputs → CP-OFDM waveform on 100 MHz / 30 kHz / 132 PRBs.

§3 — Resource Grid & OFDM Signal Generation

TS 38.211 §4.4.4 The resource grid spans K_RB × 12 subcarriers in frequency and 14 OFDM symbols per slot in time. For 100 MHz / μ=1: K_RB = 132, active subcarriers = 1584, FFT size = 4096 (only 1584 of 4096 bins are populated; the remainder are guard-band zeros). One slot = 0.5 ms (μ=1), 10 slots per subframe, 20 slots per 10 ms radio frame.

Each resource element (RE) carries one complex symbol. RE types visible in the grid below: PDSCH (user data), DMRS (demodulation reference signal), CSI-RS (channel-state reference), PTRS (phase-tracking RS), Guard (DC + edge guard bins).

NRB = 132,   NSC = NRB × 12 = 1584,   NFFT = 4096,   fs = 122.88 Msps
Guard bins = NFFT − NSC − 1 (DC) = 4096 − 1584 − 1 = 2511

§3.2 — Resource Grid: 14 Symbols × PRBs

■ PDSCH ■ DMRS ■ CSI-RS ■ PTRS ■ Guard/DC

OFDM Signal Generation Each OFDM symbol is formed by mapping complex modulation symbols (QPSK/16QAM/256QAM) onto active subcarrier bins, filling all unused bins with zero, then applying an NFFT-point IFFT. A cyclic prefix (CP) copied from the tail is prepended to eliminate ISI.
s(t) = ∑k=0NFFT−1 Xk · ej2πkΔf·t
NCP,0 = 288 Ts   (first symbol per slot, μ=1)     NCP,l>0 = 144 Ts   (symbols 1–13, μ=1)
Δf = 2μ × 15 kHz = 30 kHz  |  Tsym = 1/Δf = 33.33 μs  |  TCP,normal = 144/122.88M = 1.172 μs

§3.3 — OFDM Waveform Visualizer

§3.4 — PAPR & PA Operating Point

OFDM signals are the sum of many independently-modulated subcarriers. By the central limit theorem the envelope amplitude follows a Rayleigh distribution, producing occasional high peaks. The Peak-to-Average Power Ratio (PAPR) for Nc = 1584 active subcarriers has a statistical distribution described by its Complementary CDF (CCDF). The chart below uses the Gaussian approximation Pr(PAPR>γ) ≈ 1 − (1 − e−γ)Nc.

PAPR = Ppeak / Pavg    SQNRDAC = 6.02 × 12 + 1.76 = 74 dBFS    PA back-off ≈ PAPR − 3 dB ≈ 7.5 dB
PA Operating Point For PAPR ≈ 10.5 dB at 0.3% clip rate, the PA operates ~7–8 dB below P1dB. Crest factor reduction (CFR) and digital pre-distortion (DPD) are applied upstream (in the DU baseband) to reduce PAPR by 2–4 dB before transmission, allowing a higher average output power without linearity degradation.

§4 — O-RAN Fronthaul & O-RU TX Processing

§4.1 — O-RAN Split 7-2x Architecture

O-RAN WG4 CUS v08.00 defines the 7-2x functional split. The DU performs all digital baseband processing up to and including precoding and RE mapping; the O-RU handles the remainder of the TX chain.

DU (gNB-DU side)
  1. CRC attachment
  2. LDPC encoding
  3. Rate matching & HARQ
  4. Scrambling
  5. Modulation (QPSK–256QAM)
  6. Layer mapping (up to 16)
  7. Precoding (W matrix)
  8. RE mapping to resource grid
  9. IQ serialisation → U-plane
C-plane
(BFW)
U-plane
(IQ data)
eCPRI / 25GbE
O-RU (Radio Unit side)
  1. BFP-9 decompression
  2. BFW weight application
  3. IFFT (NFFT=4096)
  4. CP insertion (288 / 144 samp)
  5. Digital-to-Analogue (DAC 12-bit)
  6. RF upconversion (3.5 GHz)
  7. Power amplifier + DPD
  8. 32-element UPA radiation
Key Split-Point Insight The precoding matrix W is computed at the DU (based on CSI feedback) and the resulting per-layer IQ samples are sent via U-plane. Alternatively, the DU sends the beamforming weights (BFW) via C-plane and the O-RU applies them. Either way, IFFT and CP are always at the O-RU — they are NOT done in the DU under split 7-2x. This minimises fronthaul bandwidth while keeping RF impairment correction (IQ imbalance, DC offset) close to the antenna.

§4.2 — eCPRI C-Plane Packet Anatomy

eCPRI C-Plane Section Type 1 — Beam-Steering

Byte(s)FieldWidth Value (example)Description
0ecpriVersion / ecpriReserved8b0x10Version=1, Reserved=0
1ecpriMessage8b0x020x00=IQ Data (U-plane), 0x02=RT Control (C-plane)
2–3ecpriPayloadSize16b0x0138Payload length in bytes (312 for 132 PRB section)
4–5eAxC_ID16b0x0010[duPortId:4b][bandSectorId:2b][ccId:2b][ruPortId:8b]
6seqId8b0x00Sequence number, increments per symbol
7subSeqId / E-bit8b0x80Sub-sequence ID; E=1 = last (or only) fragment
8dataDirection / payloadVersion4+4b0x11DL=1, UL=0; O-RAN payload version=1
9filterIndex / frameStructure4+4b0x00Filter=0 (no filtering), frameStruct=0 (FDD/TDD)
10frameId8b0x00Radio frame number 0–99
11subframeId / slotId[5:4]4+2b0x00Subframe 0–9; slot upper 2 bits (μ=1: 0–19)
12slotId[3:0] / symbolId4+6b0x00Slot lower 4 bits; OFDM symbol 0–13
13–14sectionId12b0x000Identifies section (PRB range) within this message
15rb / symInc / startPrbu[9:0]1+1+10b0x000rb=0 (every RB), symInc=0, startPrbu=0
16–17numPrbu16b0x0084132 = 0x84 PRBs in this section
18–19beamId16b0x0010Beam index for O-RU BFW table lookup (0–65535)

§4.3 — U-Plane IQ Data & BFP-9 Compression

The U-plane carries per-RE IQ samples for each eAxC (antenna port / carrier component). At full precision, each I or Q value is a 16-bit signed integer (32 bits per complex sample). O-RAN BFP-9 reduces this significantly:

BFP-9:   9-bit mantissa + 4-bit shared exponent per PRB (12 subcarriers)
Bits per I (or Q) component:   16b → 9b mantissa + 4b exp = 13b   ⇒ compression ratio = 13/16 = 81.25%
IQ pair:   32b → 13+13+4 = 30b*   (*exponent shared across PRB)   ⇒ effective ~26b per sample

BFP-9 Compression Demo — Single IQ Sample

§4.4 — Fronthaul Bandwidth Calculator

The raw fronthaul requirement before compression is enormous. For 32 ports at 122.88 Msps: 32 × 122.88M × 64b = 250.7 Gbps. BFP-9 and the 25 GbE link budget make this practical.

Fronthaul Bandwidth — Interactive Budget

§4.5 — BFW Weight Application at O-RU

After decompression, the O-RU applies beamforming weights to each active subcarrier for each antenna port. For a 32-port (N1=8, N2=4, dual-pol) UPA and ν DL layers:

yp[k] = ∑l=1ν wp,l · xl[k]     p = 1…32,   k = subcarrier index
wp,l = BFW for port p, layer l    (complex, stored in O-RU BFW table, updated per beam / periodicity)

The BFW for a planar array (UPA: N1×N2 elements per polarisation) steered to azimuth θ and elevation φ is: w[n1, n2] = exp(j·2π·d/λ·(n1·sinθ + n2·sinφ)) where d = λ/2 = 42.86 mm.

32-Port BFW Weights — Beam Steering Visualiser (8H × 4V UPA)

Bar height = amplitude (equal power per port = 1/√32). Bar colour = phase angle (HSL: 0°=red, 120°=green, 240°=blue). Phase gradient across columns = azimuth steering; across rows = elevation steering.

§4.6 — O-RU TX Chain: DAC, RF Upconversion, PA, Antenna

DAC & Baseband Output

12-bit DAC at fs=122.88 Msps converts digital OFDM samples to analogue.

SQNR = 6.02 × 12 + 1.76 = 74 dBFS

Output is a complex baseband signal (I and Q paths). Image rejection filter suppresses aliases at k·fs ± fsignal.

RF Upconversion — 3.5 GHz (n78)

Complex baseband is mixed with the 3.5 GHz LO to produce the RF signal:

yRF(t) = Re{ yBB(t) · ej2πfct }    fc = 3.5 GHz

λ = c/fc = 85.71 mm  |  λ/2 = 42.86 mm (element spacing). Phase noise: typically <−90 dBc/Hz @ 1 MHz offset (O-RU class C).

Power Amplifier (PA)

PA must accommodate PAPR without clipping. For PAPR ≈ 10.5 dB:

OBO = PAPR − 3 dB ≈ 7.5 dB below Psat

DPD (Digital Pre-Distortion) reduces effective PAPR by 2–4 dB, recovering PA efficiency. EVM target: <−30 dB for 256QAM. PTX per port ≈ 27 dBm for 32 ports (total 42 dBm radiated).

32-Element UPA & EIRP

32 elements (8H×4V, dual-pol) form a planar array beam:

EIRP = PTX + Gelem + Garray
= 27 dBm + 8 dBi + 10·log10(32) dB = 27 + 8 + 15.05 = 50.05 dBm

Half-power beamwidth (H-plane): ≈ 102°/N1 = 12.75°. Sidelobe level ≈ −13 dB for uniform weighting.

The OFDM modulated signal for symbol l in slot μ (TS 38.211 §5.3.1):

xl,μ(t) = ∑k=0NFFTu,μ−1 ak−NFFTu,μ/2, l, μ · ej2π(k−NFFTu,μ/2)Δfμ t
NFFTu,1 = 4096,   Δf1 = 30 kHz,   Tsym = 1/30k = 33.33 μs,   Tslot = 14 × (Tsym + TCP) = 0.5 ms
CP lengths (μ=1):   NCP,0 = 288 samples = 2.344 μs  |  NCP,l>0 = 144 samples = 1.172 μs
End-to-End TX Latency (O-RAN DL) T2a window (DU to O-RU): min 0 μs, max 196 μs (O-RAN spec). T12 transport (fiber): ~5 ns/m × 16 km = 80 μs one-way. O-RU processing (IFFT + CP + DAC): ≈ 10–30 μs. Total DL chain latency DU→air ≈ 120–310 μs depending on fronthaul distance.

§5 — OTA Channel: Path Loss, Fading & RF Impairments

UMa NLOS Path Loss — Live Calculator

UMa NLOS formula (3GPP TR 38.901 §7.4.1): PL = 13.54 + 39.08·log₁₀(d) + 20·log₁₀(fc) — valid 10 m ≤ d ≤ 5 km, 0.5–100 GHz. The 39.08 exponent (vs free-space 20) captures diffraction and scattering in dense urban environments.

§5.2 Channel Models — Impulse Response

3GPP TS 38.901 defines TDL (Tapped Delay Line) channel models for link-level simulation. TDL-A (DS≈30 ns) models urban micro; TDL-C (DS≈300 ns) models urban macro with richer multipath.

Coherence bandwidth Bc ≈ 1/(5·DS). TDL-A: Bc6.7 MHz — many PRBs experience correlated fading. TDL-C: Bc667 kHz — deep frequency-selective fading; MMSE per-subcarrier equalization is critical. 30 kHz SCS spacing (§1) is below both coherence bandwidths for TDL-A, making per-PRB channel estimation viable.

§5.3 Live Constellation Degradation — Channel + RF Impairments

Received Constellation — Channel + RF Impairments

EVM limits (3GPP TS 38.101-1): QPSK ≤17.5%, 16QAM ≤12.5%, 64QAM ≤8%, 256QAM ≤3.5%. Phase noise dominates at mmWave; IQ imbalance causes constellation rotation asymmetry; Doppler induces inter-carrier interference (ICI) degrading all subcarriers simultaneously. The 32TRX massive MIMO array's beamforming gain (~15 dB) compensates several dB of path loss, relaxing the per-element PA linearity requirement.

§6 — UE/O-RU Reception: ADC, FFT, Channel Estimation & MMSE

§6.1 ADC Quantization — SQNR vs Resolution

ADC Quantization — SQNR vs Resolution

SQNR rule of thumb: each additional ADC bit adds ~6 dB of dynamic range. O-RU fronthaul typically uses 16-bit I/Q samples (BFP compressed to 9 bits over eCPRI in 7-2x split). The 32TRX system streams 32 × 2 (I+Q) × 9 bits × 2 × 122.88 Msps ≈ 141 Gbps raw FH throughput, compressed via Block Floating Point (BFP) to ~25 Gbps per eCPRI link.

§6.2 CP Removal & FFT — de-OFDM

CP Removal & FFT — de-OFDM (μ=1, 30 kHz SCS)

CP design rule: CP length must exceed the maximum excess delay of the channel. For TDL-C (max delay ~2.5 μs normalized), normal CP = 144/122.88 MHz ≈ 1.17 μs at μ=1. In very dense multipath (outdoor urban), extended CP or PTRS may be needed. The 4096-pt FFT gives 30 kHz resolution; active bandwidth = 1584 × 30 kHz = 47.52 MHz (≤ 100 MHz occupied, per 3GPP guardband allocation for n78).

§6.3 Channel Estimation — DMRS-based LS + Interpolation

Channel Estimation — DMRS-based LS + Interpolation

LS estimator: Ĥ[k] = Y[k] / XDMRS[k] — unbiased but noise-sensitive at low SNR. MMSE estimator (used in gNB): ĤMMSE = RHH(RHH + σ²I)⁻¹ĤLS — requires channel statistics but achieves 3–6 dB SNR gain over LS. DMRS Type 1 (spacing=2) gives 66 pilots per 132 PRBs, sufficient for TDL-A coherence bandwidth.

§6.4 MMSE Equalization — Before vs After

$$\hat{x}[k] = \frac{\hat{H}^*[k]}{|\hat{H}[k]|^2 + \sigma_n^2} \cdot y[k] = W_{\text{MMSE}}[k] \cdot y[k]$$

The MMSE weight W[k] simultaneously suppresses noise and inverts the channel, trading some noise enhancement (ZF) for minimum mean-square error at each subcarrier.

MMSE Equalization — Before vs After

Before EQ (faded)

After MMSE EQ

MMSE vs ZF: At low SNR, ZF over-amplifies noise when |H[k]| ≈ 0 (deep fade nulls). MMSE regularises with σ²: when |H[k]|² ≫ σ², MMSE ≈ ZF; when |H[k]|² ≈ σ², MMSE provides graceful degradation. In massive MIMO (32TRX), the per-UE spatial MMSE combiner additionally suppresses inter-UE interference across the 128-UE MU-MIMO space.

§7 — BER, Throughput & End-to-End Performance

§7.1 BER vs SNR — Theoretical + Monte Carlo Simulation

BER vs SNR — Theoretical Curves + Live Monte Carlo

Coding gain: Raw BER curves above are for uncoded AWGN. 5G NR uses LDPC (data) and Polar (control) codes. Turbo/LDPC coding provides 5–9 dB SNR gain at BER 10⁻⁵, enabling reliable operation at MCS 28 (256QAM, R=0.925) at SNR ≈ 25–28 dB. The 10% BLER target for initial HARQ transmission maps to roughly: QPSK → 1 dB, 16QAM → 8 dB, 64QAM → 14 dB, 256QAM → 22 dB (AWGN, LDPC coded).

§7.2 DL Throughput Estimator — 5G NR PDSCH

DL Throughput Estimator — 5G NR PDSCH (3GPP TS 38.214)

TDD duty cycle impact: DDDSUUDDDD = 7 DL + 2 UL + 1 Special (S=6D+2G+6U). Net DL ≈ 70%, UL ≈ 20%, guard ≈ 10%. Actual 5G NR peak per 3GPP TS 38.306 uses Rmax = Σ νj·Qm,j·fj·Rmax·NPRB·12·(1−OH)·μ / Tμ. With 32TRX (N₁=8, N₂=4), gNB supports up to 16 spatial streams to 128 UEs simultaneously; each UE typically sees 1–4 layers depending on rank and channel conditions.

§7.3 End-to-End DL Latency Budget

End-to-End DL Latency Budget — O-RAN Split 7.2x

O-RAN timing requirements (O-RAN WG4 CUS-Plane spec): T12 (DL fronthaul window) must complete within T1a-max-cp-dl = 470 μs before TTI start. T34 (UL FH) must arrive within T2a-max-up = 196 μs after TTI boundary. At 5 km fiber: one-way propagation ≈ 25 μs — well within O-RAN Cat-A/B limits (≤25 km / 125 μs). HARQ RTT dominates: each additional retransmission costs ~8ms for 4G, ~3.5ms for 5G NR μ=1.

§7.4 Key Equations — System Performance Summary

DL Peak Throughput (TS 38.306 §4.1.2)
RDL = ν · Qm · R · NPRB · 12 · Nsym · (1−OH) · fTDD / Tslot
SNR at UE Receiver
SNR = EIRP − PL(d, fc) − (kTBNF) + Garray,Rx

Where kTBNF = −174 + 10·log₁₀(BHz) + NF [dBm] is the thermal noise floor per bandwidth B, and Garray,Rx is the UE receive antenna gain (typically 0 dBi for handheld).

MMSE Equalizer Weight per Subcarrier
WMMSE[k] = Ĥ*[k] / (|Ĥ[k]|² + σn²)
ADC SQNR
SQNR = 6.02·N + 1.76 dB
Parameter Value Comment
Bandwidth100 MHzn78 (3.3–3.8 GHz), 132 PRBs
SCS / μ30 kHz / μ=1Slot = 0.5 ms, 14 OFDM syms
FFT size4096 ptfs = 122.88 Msps, CP₀ = 288
TRX / Ant32TRX (N₁=8, N₂=4)λ/2 = 42.86 mm at 3.5 GHz
Max UEs128MU-MIMO spatial streams ≤ 16
Path Loss modelUMa NLOS 3GPP TR 38.901PL = 13.54 + 39.08·log₁₀(d) + 20·log₁₀(fc)
TDD patternDDDSUUDDDD70% DL / 20% UL / 10% guard
Peak DL (16L, MCS27)~8.5 GbpsTheoretical max, 132 PRBs, 16 layers
Practical DL (4L, MCS22)~1.8 GbpsTypical 256QAM, 4 layers, 70% OH
U-plane latency~4–7 msDU+FH+OTA+UE proc, no HARQ retx
Simulation limitations: All Monte Carlo simulations above use ideal AWGN + simplified flat fading. Real 5G NR performance additionally depends on: LDPC/Polar coding gain, rank adaptation, MCS link adaptation (outer loop), beamforming weight accuracy, timing/frequency synchronisation errors (CFO, STO), and inter-cell interference (not modelled here). For system-level evaluation, use full-stack simulators .

§8 — Antenna Array Configuration

§8.1 Array Geometry

3GPP TS 38.901 defines the Uniform Planar Array (UPA) as the reference antenna topology for 5G NR massive MIMO. The array is characterised by N1 columns, N2 rows and P polarisations per element site, giving N1 × N2 × P antenna ports in total. Standard element spacing is λ/2 in both horizontal and vertical directions. At 3.5 GHz: λ = 300/3.5 = 85.71 mm, so λ/2 = 42.86 mm.

Key relations: Array aperture width W = (N1−1)·dH, height Harr = (N2−1)·dV. Array gain (coherent) = 10·log10(N_ports). HPBWH ≈ 50.8° / (N1·d/λ), HPBWV ≈ 50.8° / (N2·d/λ).

UPA Layout — Configurable Antenna Array

Settings below read from the Global System Config at top of page. Adjust N1, N2, Pol there to update all sections.

§8.2 3GPP Element Radiation Pattern

Per 3GPP TR 38.901 §7.3 the single-element radiation patterns in azimuth and elevation are parameterised by half-power beamwidths and a sidelobe-attenuation limit:

AEH(φ) = −min[12(φ/φ3dB)², Amax] dB,  φ3dB = 65°, Amax = 30 dB
AEV(θ) = −min[12((θ−90°)/θ3dB)², SLAv] dB,  θ3dB = 65°, SLAv = 30 dB

Antenna Element Radiation Pattern (3GPP TR 38.901 §7.3)

§8.3 Combined Array Factor + Element Pattern

The total radiated pattern is the product (sum in dB) of the array factor and the single-element pattern. Beam steering shifts the AF peak while the element envelope acts as a natural envelope taper, suppressing gain at wide scan angles.

Total Array Gain = Array Factor × Element Pattern

Gtotal(φ,θ) = GE,max + AEH(φ) + AEV(θ) + AFH(φ) + AFV(θ)
HPBW = 0.886λ / (N·dH) rad  ≈  50.8° / (N·d/λ)
Insight: At ±60° scan the element pattern alone contributes roughly −10 dB taper, so the effective EIRP at wide angles is substantially lower than at broadside even before considering the array factor roll-off. This is why 5G NR beams are limited to ±60° in most deployments.

§9 — O-RU RF Chain, Attenuators & EIRP Variation

§9.1 O-RU TX Chain

The transmit chain of a 5G O-RU maps each antenna port through a fixed sequence of components. Understanding the gain and loss budget of every stage is essential for accurate EIRP prediction and regulatory compliance.

#BlockTypical valuePurpose
1IQ / eCPRI inputFronthaul baseband data per port
2Digital Pre-Distortion (DPD)−3 to −5 dB PAPRCompensates PA AM-AM / AM-PM nonlinearity; improves EVM & ACLR
3DAC12-bit, 122.88 MspsDigital → analogue conversion; sets noise floor
4RF Up-conversion3.5 GHz (n78)Mix to carrier frequency; local oscillator phase noise
5Digital Attenuator0 to −20 dB, 0.5 dB stepPer-port power calibration; EIRP adjustment; regulatory compliance
6Power Amplifier (PA)P1dB ≈ 33 dBm; Psat ≈ 36 dBmAmplify to transmit power level
7Band-pass filterIL ≈ 0.5 dBSuppress OOB emissions and harmonics
8Feeder / cable0.3–2 dB (length dependent)Route RF to antenna element
9Connector0.1–0.5 dB per mateMechanical interface
10Antenna elementGelem ≈ 8 dBi @ 3.5 GHzRadiates RF; dual-pol cross-dipole typical
Attenuator role: The digital attenuator (step attenuator or switched resistor network) allows per-port power calibration to flatten EIRP across the array (compensating PA gain spread, feeder length differences and temperature effects). It is also used for regulatory power back-off and beam calibration during self-test sequences.

§9.2 Interactive EIRP Calculator

Per-Port EIRP Calculator — O-RU TX Chain

§9.3 EIRP Variation Across Ports (Attenuator Sweep)

Real arrays exhibit port-to-port EIRP spread due to PA gain variation (±1–3 dB across a production batch), feeder length differences, connector mating losses and thermal gradients. Per-port digital attenuators can compensate these differences and bring uniformity to within ±0.2 dB after calibration.

Per-Port EIRP Distribution — Attenuator Settings

§9.4 TRP vs EIRP

EIRP (Effective Isotropic Radiated Power) is the power that would need to be fed into an isotropic radiator to produce the same field strength in the direction of maximum gain:

EIRPdBm = Pant,dBm + Gtotal,dBi

TRP (Total Radiated Power) integrates the radiated power over all directions. For a beam with array gain G:

TRPdBm ≈ EIRPdBm − Garray,dB

Example: with a 15 dB array gain, TRP = EIRP − 15 dB. A 75 dBm EIRP limit translates to TRP ≈ 60 dBm.

ParameterDefinitionTypical limit (n78 gNB)
EIRP P_ant × G_total — directional 58–75 dBm (deployment-class dependent)
TRP Omnidirectional integral ≤ 43–60 dBm (varies)
EVM (Tx) Distortion from PA, DPD residual, DAC ≤ 3.5% for 256QAM (TS 38.104 §6.5.2.2)
ACLR Adjacent channel leakage ratio ≥ 45 dBc (E-UTRA), ≥ 45 dBc (UTRA)
EIRPdBm = PTX,dBm − Latt,dB − Lfeeder,dB − Lconn,dB + Gelem,dBi + Garray,dB
Regulatory note: The attenuator range (0–20 dB) directly maps to a 20 dB EIRP control range. This is leveraged in O-RAN M-plane (Yang/NETCONF) to set per-port attenuation values during O&M, enabling dynamic power management and compliance with spectrum-sharing rules (e.g. 3.5 GHz CBRS PAL/GAA in the US).

§10 — RF Metrics: RSRP, RSSI, SINR & Complete Link Budget

§10.1 — RF Metric Definitions

RSRP — Reference Signal Received Power (TS 38.215 §5.1.1): Linear average power of resource elements carrying CSI-RS or SSB within the measurement bandwidth.

RSRP [dBm] = RSL [dBm] − 10·log₁₀(NRE,RS)

where NRE,RS is the number of REs in the reference signal bandwidth (e.g. NPRB × 12 for a wideband CSI-RS).

RSSI — Received Signal Strength Indicator: Total received power including signal, interference, and noise across the measurement bandwidth.

RSSI [dBm] = 10·log₁₀(Psignal + Pinterference + Pnoise)

The sum is linear (milliwatts) before the dB conversion.

SINR — Signal to Interference plus Noise Ratio:

SINR [dB] = 10·log₁₀( Psignal / (Pinterference + Pnoise) )

SNR (interference-free):

SNR [dB] = 10·log₁₀( Psignal / Pnoise ) = RSRP − Noise floor

CQI — Channel Quality Indicator: 4-bit value (0–15) reported by the UE and mapped from SINR per TS 38.214 Table 5.2.2.1-3. CQI 0 = "out of range".

CQI Table — TS 38.214 Table 5.2.2.1-3 (all 16 entries)

CQI Modulation Code Rate ×1024 Efficiency (b/s/Hz) Min SINR (approx, dB)
0Out of range
1QPSK780.1523−6.7
2QPSK1200.2344−4.7
3QPSK1930.3770−2.3
4QPSK3080.60160.2
5QPSK4490.87702.4
6QPSK6021.17584.3
716QAM3781.47665.9
816QAM4901.91418.1
916QAM6162.406310.3
1064QAM4662.730511.7
1164QAM5673.322314.1
1264QAM6663.902316.3
13256QAM7115.554718.7
14256QAM7976.226621.0
15256QAM9487.406325.1

§10.2 — Complete Interactive Link Budget

Complete Link Budget — All Parameters Configurable

§10.3 — RSRP vs Distance (Multiple TRX Configs)

RSRP plotted on a log-distance axis for 4 array sizes (32, 16, 8, 4 TRX). Dashed lines mark the standard quality thresholds. Computed with UMa NLOS path loss (fc = SYSCONF.fc_GHz), NF = 7 dB, SCS = 30 kHz, 132 PRBs.

§11 — E2E Scenarios: Single UE, 4-UE MU-MIMO & Cell Coverage

These scenarios wire together all prior building blocks — antenna array gain (§4), path loss (§6), beamforming weights (§7), MCS/throughput (§8), and the link budget (§10) — into complete end-to-end simulations. Canvas positions are to-scale within the cell radius.

§11.1 — Scenario A: Single UE, SU-MIMO

A single UE placed at configurable distance and azimuth. The gNB steers the main beam toward the UE. Coverage rings show RSRP quality zones. Throughput uses the selected MCS with the configured number of spatial layers.

Scenario A — Single UE, SU-MIMO

§11.2 — Scenario B: 4-UE MU-MIMO (Zero-Forcing)

Four UEs served simultaneously on the same time-frequency resource. The gNB applies Zero-Forcing precoding: WZF = H(HH)−1, which steers spatial nulls toward other UEs. SINR is determined by residual inter-beam leakage (modelled as ~30 dB ZF null depth) and thermal noise. Move UEs to see how angular separation affects isolation.
ZF null depth model is simplified: real-world suppression depends on channel rank, pilot contamination and hardware impairments. The 30 dB figure is a typical best-case target.

Scenario B — 4-UE MU-MIMO (Zero-Forcing Spatial Separation)

Each UE gets an independent beam. ZF precoding creates spatial nulls toward other UEs. SINR degrades when angular separation is less than the array HPBW.

§11.3 — MU-MIMO Sum Throughput vs Angular Separation

4 UEs symmetrically placed at ±Δ/2 and ±3Δ/2 (equal angular spacing Δ). As Δ increases beyond the HPBW, ZF isolation improves and per-UE SINR rises. The plot compares SU-MIMO (all resource to 1 UE) against 4-UE MU-MIMO sum throughput.

§11.4 — Key Takeaways

Scenario Config UEs served Typical SINR Peak Tput Key constraint
SU-MIMO 32 TRX, 8 layers 1 20–30 dB (nearby) ~2–3 Gbps (MCS27) Single-user link, no MU interference
MU-MIMO 4-UE ZF 32 TRX, 2 layers/UE 4 15–25 dB (well-separated) ~3–5 Gbps sum Angular separation ≥ HPBW for ZF isolation
MU-MIMO 4-UE ZF 32 TRX, 2 layers/UE 4 <5 dB (clustered) <1 Gbps sum UEs within HPBW — ZF nulls fail, high ICI
Edge UE 32 TRX, any 1 −5 to 5 dB (1500 m) QPSK, ~100 Mbps Path loss dominates; CQI 1–4 typical
Design rule of thumb: For reliable 4-UE MU-MIMO, schedule UEs with azimuth separation ≥ HPBWH = 50.8° / (N1 × 0.5). With N1=8 → HPBW ≈ 12.7°. For N1=16 (64T64R) → HPBW ≈ 6.4° → denser spatial reuse is possible. Below HPBW, the scheduler should fall back to SU-MIMO or reduce MU rank to avoid SINR collapse.

§12 — Inter-cell Interference: 10-Cell Hexagonal Network

§12.1 — Co-channel Interference Theory

In 5G NR, frequency reuse factor F=1 is standard: every cell transmits on the same carrier simultaneously. This maximises spectral efficiency but means every neighbour is a co-channel interferer. The dominant impairment at the cell edge is therefore co-channel interference (CCI), not thermal noise.

Key Parameters

  • Inter-site distance (ISD): centre-to-centre distance between adjacent gNBs. Typical urban n78 deployments: 200–500 m. Smaller ISD increases capacity density but raises interference for cell-edge UEs.
  • Co-channel interference (CCI): all cells share the same carrier frequency. Every gNB transmission is visible (attenuated by path loss and beamforming) at every UE in every other cell.
  • Frequency reuse F=1: 5G NR uses F=1 universally — interference is managed by beamforming null-steering rather than frequency planning. This is a key difference from 3G/4G fractional frequency reuse.
  • Cell edge challenge: at the Voronoi boundary between two cells the serving-cell signal and the strongest interferer are at nearly equal distances. SINR collapses to near 0 dB unless beamforming provides isolation.
  • Beam coordination: adjacent gNBs can coordinate beam directions so that the null of cell-A's beam points toward cell-B's UE, reducing inter-beam interference by 15–30 dB.

SINR Definition

$$\text{SINR}(x,y) = \frac{P_{S,0}(x,y)}{\displaystyle\sum_{i=1}^{N_{\text{cell}}-1} P_{S,i}(x,y) + N_0}$$

where \(P_{S,0}\) is the received power from the serving cell (nearest gNB), \(P_{S,i}\) is the power received from interferer \(i\) (attenuated by both path loss and beamforming isolation \(\Delta_{\text{BF}}\)), and \(N_0\) is the thermal noise power over the allocated bandwidth:

$$N_0 = k_B T \cdot \Delta f_{\text{SCS}} \cdot N_{\text{PRB}} \cdot F_{\text{NF}}$$

With SCS = 30 kHz and \(N_{\text{PRB}}\) = 132 (100 MHz n78), \(N_0 \approx -87\) dBm (7 dB NF). At typical EIRP = 50 dBm and ISD = 350 m, interferers dominate noise by >15 dB, confirming interference-limited operation.

Beamforming Isolation Model

Each interfering cell's beam is modelled with an isolation penalty \(\Delta_{\text{BF}}\) (dB):

$$P_{S,i}(x,y) = 10^{\,(\text{EIRP} - \text{PL}(d_i) + \sigma_s \cdot z_i - \Delta_{\text{BF}})/10}$$

where \(z_i \sim \mathcal{N}(0,1)\) models log-normal shadow fading with standard deviation \(\sigma_s\). Typical massive-MIMO null depth: \(\Delta_{\text{BF}}\) = 15–20 dB; ZF precoding can reach 25–30 dB.

§12.2 — SINR Coverage Map: 10-Cell Hexagonal Network

§12.3 — Average SINR vs Inter-Site Distance: Effect of Beamforming Isolation

§12.4 — Cell Edge SINR Analysis

The most challenging point in any cell is the Voronoi edge: equidistant between the serving gNB and the nearest interferer. At this point, signal and interference arrive at near-equal power, and SINR is entirely determined by the beamforming isolation \(\Delta_{\text{BF}}\).

Worst-case cell-edge budget (ISD = 350 m, n78 UMa, EIRP = 50 dBm)

  • Without beamforming (\(\Delta_{\text{BF}}\) = 0 dB): Signal and nearest interferer at d = 175 m. PL difference \(\approx\) 0 dB (same distance). Six first-ring interferers → aggregate interference ~8 dB above signal → SINR \(\approx\) −5 to 0 dB. Only BPSK/QPSK 1/5 rate possible at cell edge.
  • With 15 dB beamforming isolation (typical massive-MIMO): Each interferer is suppressed by 15 dB. Aggregate of 6 first-ring interferers ≈ 15 − 8 = +7 dB above thermal noise. Cell-edge SINR rises to ~15–18 dB → 64QAM 3/4 becomes feasible, 3–4× throughput improvement vs no-BF.
  • With 30 dB ZF null steering: Cell-edge SINR approaches 25–28 dB, approaching single-cell performance. Residual impairment is from 2nd-ring interferers and ZF nulling error due to imperfect CSI feedback.

Advanced Interference Mitigation

  • Carrier Aggregation (CA): not directly an interference mitigation technique, but combining 2–4 component carriers increases peak throughput 2–4× by exploiting unused spectrum. Interference from each CC must still be managed individually.
  • Coordinated Multi-Point (CoMP) — Joint Transmission (JT): Multiple gNBs simultaneously transmit to a single UE, coherently combining over the air. Inter-cell interference is converted into useful signal power. Requires tight phase synchronisation (<50 ns) and joint precoding across sites via X2/Xn interface. Can achieve SINR gains of 10–15 dB at cell edge, at the cost of fronthaul capacity and coordination overhead.
  • Coordinated Beamforming (CB): adjacent cells exchange beam-direction information and agree to steer nulls toward each other's served UEs. Simpler than CoMP-JT (no data sharing), practical with Type-II CSI feedback (3GPP Rel-16+).
  • Inter-cell interference coordination (ICIC) / eICIC: Time-domain resource partitioning — cells blank certain sub-frames (Almost Blank Sub-frames, ABS) to create quiet periods for cell-edge UEs of neighbour cells. Legacy LTE technique; superseded by beamforming in 5G NR mMIMO deployments.

§12.5 — Multi-cell SINR Summary

Scenario Avg SINR Cell-edge SINR Dominant impairment Mitigation
Single cell, SU-MIMO 25–35 dB 5–10 dB Path loss, thermal noise Higher EIRP; more spatial layers near cell centre
4-UE MU-MIMO, ZF precoding 18–28 dB 3–8 dB Residual ZF error; cross-beam leakage Angular UE separation ≥ HPBW ≈ 12.7° (64-ant panel)
10 cells, F=1, no BF 5–12 dB −5 to 0 dB Co-channel interference (6 first-ring nbrs) Frequency planning (F=3); beamforming isolation
10 cells, F=1, BF 15 dB 15–22 dB 8–13 dB Residual interference, shadow fading Beam coordination; power control; CoMP-CB
10 cells, F=1, ZF 30 dB null 20–28 dB 12–18 dB 2nd-ring interference; CSI feedback error CoMP-JT; interference-aware scheduling; Rel-16 Type-II CSI
Simulation notes: The heatmap uses a single random seed for reproducibility; shadow fading is independently sampled per cell-link using Box-Muller Gaussian draws. The beamforming isolation model is isotropic (constant dB penalty per interferer) — a real massive-MIMO beam has angle-dependent gain; actual isolation depends on the angular separation between serving-beam direction and interferer location, which is captured in §10 (array factor). The analytical SINR curve (§12.3) uses a statistical area-weighted average and matches simulation within ±1–2 dB for the plotted scenarios.
✓ subscribed
spotted an error? →
// available
PHY Consulting & Contract Work
Available for 5G/6G PHY design, O-RAN integration, beamforming, ML+PHY research, and contract engineering work.
5G NR PHY O-RAN Beamforming ML+PHY 6G
get in touch →