The Type I codebook is used for CSI feedback in 5G NR. It is built from Discrete Fourier Transform (DFT) basis vectors that represent phase shifts across antenna ports. A single panel has N1xN2 ports in horizontal and vertical dimensions, with over-sampling factors O1, O2 (typically 4).
NOTE : To understand the details of this module, you would need to hack into quiet an intensive math process. For the details on those details, check out this note.
Parameters
N1, N2: Number of antenna ports in the two dimensions (e.g. 2x1, 2x2, 4x1, 4x2).
i1,1, i1,2: Beam indices selecting the base DFT beam direction.
i2: Co-phasing index for polarization; applies phase θp = ejπi2/2 between polarizations (range depends on table: Rank 1 Mode 1 uses 0–3; Rank 2 Mode 1 uses 0–1; Mode 2 uses 0–7 or 0–15).
i1,3: Spatial offset index for Rank 2 (Table 5.2.2.2.1-6 only). Maps to beam offsets k1, k2 via Table 5.2.2.2.1-3; selects separation between the two layers.
Rank: Rank 1 (single layer) or Rank 2 (two orthogonal layers for higher throughput). Tables 5.2.2.2.1-5 (Rank 1) and 5.2.2.2.1-6 (Rank 2) with Mode 1 / Mode 2 sub-tables.
Beamforming Vector
The precoder uses a Kronecker product of DFT vectors. The phase at port (n, m) for polarization p is:
Dual polarization doubles the number of ports (2xN1xN2). The array factor in direction (θ, φ) is the magnitude of the sum of weighted complex exponentials over all ports (half-wavelength spacing). The 3D view shows this gain as a deformed sphere: radius in each direction is proportional to gain, with a heatmap for intensity.
CSI Codebook Visualizer
• Layer 1• Layer 2
Azimuth slice (XY-plane)
Elevation slice (XZ-plane)
Precoder Matrix W
Usage
Use the controls to explore the 3GPP 38.214 Type I single-panel codebook radiation patterns.
Initial state: On load you see the 3D array-factor pattern for the default config (4x2, Rank 2). Layer 1 is blue, Layer 2 is red. The deformed sphere shows gain in each direction (θ, φ); radius and vertex color indicate magnitude (heatmap).
3D navigation: Left-drag to rotate, right-drag (or middle mouse) to pan, scroll to zoom. The scene has a grid (XZ plane), coordinate axes (X/Y/Z), and the pattern mesh(es).
CSI Codebook Visualizer: Choose Table (5.2.2.2.1-5 Rank 1 or 5.2.2.2.1-6 Rank 2) and Sub-table (Mode 1 / Mode 2, N2=1 or N2>1). Change Config (N1xN2) to set port counts. Use Rank 1 or 2. Adjust i1,1, i1,2 to steer the beam; i2 for co-phasing. For Rank 2, i1,3 (spatial offset) appears and controls layer separation via Table 5.2.2.2.1-3 (k1, k2); the k-table is shown below the W reference when Rank
2 is selected.
Camera: Use the overlay buttons (Iso, X+, Y+, Z+, +, -) for preset views and zoom. The 3D view also supports orbit/pan/zoom with the mouse.
Parameters
Config (N1xN2): Antenna port layout (e.g. 2x1 → 4 ports, 4x2 → 16 ports). Over-sampling O1, O2 are fixed (typically 4) per 38.214.
Rank: 1 = single beam (one layer); 2 = two layers with orthogonal co-phasing for higher throughput.
i1,1, i1,2: Beam indices selecting the DFT base beam. Max values depend on N1, N2 and O1, O2 (e.g. i1,1 ∈ [0, O1·N1-1], i1,2 ∈ [0, O2·N2-1] where applicable; for N2=1, i1,2 is 0).
i2 (co-phase): Range depends on table (e.g. 0–3 for Rank 1 Mode 1, 0–1 for Rank 2 Mode 1, 0–7 for Rank 2 Mode 2). Applies θp = ejπi2/2 between polarizations.
i1,3 (spatial offset): Shown only for Table 5.2.2.2.1-6 (Rank 2). Selects the row in Table 5.2.2.2.1-3 to get k1, k2 for the second layer beam offset.
Layer 1 / Layer 2: For Rank 2, Layer 1 (blue) and Layer 2 (red) are the two precoder columns. They are orthogonal; both patterns are shown in the 3D scene. The 2D polar slices show combined power (filled area), with dotted blue (Layer 1) and dotted red (Layer 2) outlines when Rank 2 is active.
Array factor: Gain in direction (θ, φ) is the magnitude of the weighted sum over 2xN1xN2 ports (half-wavelength spacing, dual polarization). The 3D mesh radius and color represent this gain.
Key concepts
DFT beamforming: The precoder is built from Kronecker-product DFT vectors; phases are φn,m,p = 2π(n·i1,1/(O1N1) + m·i1,2/(O2N2)) + p·π·i2/2.
Co-phasing: i2 controls the phase between polarizations; you can see phase cancellation/combining in the pattern as i2 changes.
Rank 2 orthogonality: The two layers use orthogonal co-phasing (+θp vs -θp on the second polarization). Table 5.2.2.2.1-3 maps i1,3 to spatial offsets (k1, k2) so the second layer can use a different beam (l′, m′) for spatial diversity.
Spatial steering: Changing i1,1 and i1,2 moves the main beam in 3D, analogous to how a 5G base station steers toward a UE.