PDSCH Transmit Diversity Throughput Simulation
This example demonstrates how to measure the Physical Downlink Shared Channel (PDSCH) throughput of a transmit/receive chain using the LTE Toolbox™.
Introduction
The example uses the LTE Toolbox functions to generate a multi antenna downlink Reference Measurement Channel (RMC) R.12. Transmission is simulated using the Extended Pedestrian A (EPA) propagation channel model. Channel noise is added to the received waveform which is then OFDM demodulated, resulting in a received resource grid for each receive antenna. Channel estimation is performed to determine the channel between each transmit/receive antenna pair. The PDSCH data is then extracted and decoded from the received resource grid. Using the result of the block CRC the throughput performance of the transmit/receive chain is determined.
eNodeB Setup
% eNodeB Configuration enb = struct; % eNodeB config structure enb.RC = 'R.12'; % RMC number enb.NCellID = 10; % Cell ID % Total number of subframes lteRMCDLTool will generate per call. This % example generates 1 frame (10 subframes) worth of data each call within % the processing loop. lteRMCDLTool will be called 10 (NFrames) times. enb.TotSubframes = 10; enb.PDSCH.TxScheme = 'TxDiversity'; % Transmission scheme enb.PDSCH.RNTI = 1; % 16-bit UE specific mask enb.PDSCH.Rho = -3; % Downlink power allocation enb.PDSCH.CSI = 'On'; % CSI scaling of soft bits enb.PDSCH.RVSeq = 0; % Disable HARQ NFrames = 10; % Number of frames to simulate SNRIn = [1 7]; % SNR points to simulate
RMC Configuration
Generate the configuration for the specified RMC and obtain associated information: number of bits in a transport block for each subframe; number of OFDM symbols per subframe and number of transmit antennas.
% Generate RMC configuration for test model specified in enb structure rmc = lteRMCDL(enb); % Transport block sizes of each subframe within a frame trblksize = rmc.PDSCH.TrBlkSizes; ncw = size(trblksize,1); % no of codewords associated to RMC % dims is a three element vector [K; L; P]: where K = no of subcarriers, % L = no of OFDM symbols and P = no of transmit antennas dims = lteDLResourceGridSize(rmc); % Determine resource grid dimensions L = dims(2); % Number of OFDM symbols per subframe P = dims(3); % Number of transmit antennas
Propagation Channel Model Configuration
cfg = struct; % Channel config structure cfg.Seed = 13; % Channel seed cfg.NRxAnts = 2; % 2 receive antennas cfg.DelayProfile ='EPA'; % Delay profile cfg.DopplerFreq = 5; % Doppler frequency in Hz cfg.MIMOCorrelation = 'Medium'; % Multi-antenna correlation cfg.NTerms = 16; % Oscillators used in fading model cfg.ModelType = 'GMEDS'; % Rayleigh fading model type cfg.InitPhase = 'Random'; % Random initial phases cfg.NormalizePathGains = 'On'; % Normalize delay profile power cfg.NormalizeTxAnts = 'On'; % Normalize for transmit antennas
Channel Estimation Configuration
To reduce the impact of noise on pilot estimates, an averaging window of 15-by-13 Resource Elements (REs) is used. An EPA delay profile causes the channel response to change slowly over frequency. Therefore a large frequency averaging window of 15 REs is used. The Doppler frequency is 5 Hz, causing the channel to fade very slowly over time. Therefore a time averaging window of 13 REs is used.
cec = struct; % Channel estimation config structure cec.PilotAverage = 'UserDefined'; % Type of pilot symbol averaging cec.FreqWindow = 15; % Frequency window size in REs cec.TimeWindow = 13; % Time window size in REs
Interpolation is performed by the channel estimator between pilot estimates to create a channel estimate for all REs. To improve the estimate multiple subframes can be used when interpolating. An interpolation window of 3 subframes with a centered interpolation window uses pilot estimates from 3 consecutive subframes to estimate the center subframe.
cec.InterpType = 'Cubic'; % Cubic interpolation cec.InterpWinSize = 3; % Interpolate up to 3 subframes % simultaneously cec.InterpWindow = 'Centred'; % Interpolation windowing method
Processing Loop
For each SNR point the following operations are performed for each frame:
RMC Generation and OFDM Modulation: Generate the OFDM modulated waveform for RMC using random data.
Propagation Channel Model: The OFDM modulated waveform is transmitted through the propagation channel. The channel model is initialized appropriately to guarantee continuity of the fading waveforms between frames. The output of the channel
rxWaveform
has two columns, one per receive antenna.Add Channel Noise: The channel noise is modeled by AWGN.
Receiver Synchronization and OFDM Demodulation: Determine the delay suffered during propagation. This is calculated by calling
lteDLFrameOffset
, which uses the primary and secondary synchronization signals. If it has not been possible to detect the primary and secondary synchronization signals due to extreme channel conditions or noise, then the previously calculated frame offset value is used. OFDM demodulation is performed after synchronization.Channel Estimation: Provides an estimate of the channel response at each element of the resource grid for a transmit/receive antenna pair. This estimate is then used to remove the effect of the channel on the transmitted signal. The channel estimation also aims to reduce the channel noise experienced during transmission by averaging the reference signals (pilot symbols).
Throughput Measurement: PDSCH data is analyzed on a subframe by subframe basis. As specified by RMC R.12 no PDSCH data is transmitted on subframe 5. Therefore it is not decoded and does not count towards the throughput calculation. A specific subframe worth of data for all receive antennas is extracted from the array of received grids, the same defined subframe worth of information is extracted from the estimate of channel response for all transmit and receive antenna pairs. These, along with the noise estimate, are input into the function
ltePDSCHDecode
, which deprecodes the PDSCH data using an orthogonal space frequency block code (OSFBC) decoder. This returns a cell array of soft bit vectors (codewords) which are input to thelteDLSCHDecode
function; this decodes the codeword and returns the block CRC error which is used to determine the throughput of the system.
% Set the random number generator to default value rng('default'); % Initialize offset vector offsets = 0; % Array to store the maximum throughput for all SNR points maxThroughput = zeros(length(SNRIn),1); % Array to store the simulation throughput for all SNR points simThroughput = zeros(length(SNRIn),1); for snrIdx = 1:numel(SNRIn) SNRdB = SNRIn(snrIdx); fprintf('\nSimulating at %gdB SNR for a total %d Frame(s)\n',... SNRdB,NFrames); for FrameNo = 1:NFrames % Generate random bits for the frame. The number of bits to % generate for each subframe is specified by each element of % trblksize. For a full frame generate sum(trblksize) bits trdata = randi([0 1], sum(trblksize), 1); % Generate populated LTE resource grid using RMC generator and OFDM % modulate. info is a structure containing the sampling rate used % for OFDM modulation [txWaveform,txGrid,info] = lteRMCDLTool(rmc,trdata); % Set sampling rate of channel to that of OFDM modulation cfg.SamplingRate = info.SamplingRate; % Set channel offset to current frame (1 frame = 10ms) cfg.InitTime = (FrameNo-1)*(rmc.TotSubframes)/1000; % Pass data through the fading channel model. % An additional 25 samples are added to the end of the waveform. % These are to cover the range of delays expected from the channel % modeling (a combination of implementation delay and channel % delay spread). rxWaveform = lteFadingChannel(cfg,[txWaveform ; zeros(25,P)]); % Noise setup SNR = 10^(SNRdB/20); % Linear SNR % Normalize noise power to take account of sampling rate, which is % a function of the IFFT size used in OFDM modulation, and the % number of antennas N0 = 1/(sqrt(2.0*rmc.CellRefP*double(info.Nfft))*SNR); % Create additive white Gaussian noise noise = N0*complex(randn(size(rxWaveform)), ... randn(size(rxWaveform))); % Add AWGN to the received time domain waveform rxWaveform = rxWaveform + noise; % Perform receiver synchronization offset = lteDLFrameOffset(rmc,rxWaveform); % Determine if frame synchronization was successful if (offset > 25) offset = offsets(end); else offsets = [offsets offset]; %#ok end if (offset>0) rxWaveform = rxWaveform(1+offset:end,:); end % Perform OFDM demodulation on the received data to recreate the % resource grid rxGrid = lteOFDMDemodulate(rmc,rxWaveform); % Perform channel estimation [estChannelGrid, noiseest] = lteDLChannelEstimate(rmc,cec,rxGrid); % Process subframes 0 to 9 within received frame for sf = 0:rmc.TotSubframes-1 % Increment NSubframe for correct decoding of data rmc.NSubframe = mod(sf,10); % Extract one subframe for analyzing at a time from the % received grid rxSubframe = rxGrid(:,L*sf+1:L*(sf+1),:); % Extract the estimated channel response for the subframe % being analyzed chSubframe = estChannelGrid(:,L*sf+1:L*(sf+1),:,:); % Perform deprecoding, layer demapping, demodulation and % descrambling on the received data using the estimate of % the channel rxEncodedBits = ltePDSCHDecode(rmc,rmc.PDSCH,... rxSubframe*(10^(-rmc.PDSCH.Rho/20)),chSubframe,noiseest); % Transport block sizes outLen = ones(1,ncw)*trblksize(rmc.NSubframe+1); % Decode DownLink Shared Channel (DL-SCH) [decbits,blkcrc] = lteDLSCHDecode(rmc,rmc.PDSCH,outLen,... rxEncodedBits); % Skip empty transport blocks, this will be the case of % subframe 5, where no data is transmitted in RMC R.12 if(outLen ~= 0) simThroughput(snrIdx) = simThroughput(snrIdx) + sum(~blkcrc .* outLen); maxThroughput(snrIdx) = maxThroughput(snrIdx) + sum(outLen); end end rmc.NSubframe = 0; end offsets = 0; end
Simulating at 1dB SNR for a total 10 Frame(s) Simulating at 7dB SNR for a total 10 Frame(s)
Plot Results
First graph shows the throughput as total bits per second against the range of SNRs, second plots total throughput as a percentage of block CRC errors against SNR range.
figure plot(SNRIn,1e-3*simThroughput/(NFrames*10e-3),'-*',... SNRIn,1e-3*0.7*maxThroughput/(NFrames*10e-3),'--rs'); title(['Throughput for ', num2str(NFrames) ' frame(s)'] ) xlabel('SNRdB'); ylabel('Throughput (kbps)'); grid on; legend('Simulation Result','70 Percent Throughput','Location',... 'SouthEast')
figure plot(SNRIn,simThroughput*100./maxThroughput,'o-.',... SNRIn,70*ones(1,numel(SNRIn)),'--rs'); title(['Throughput for ', num2str(NFrames) ' frame(s)'] ) xlabel('SNRdB'); ylabel('Throughput (%)'); grid on; legend('Simulation Result','70 Percent Throughput','Location',... 'SouthEast') ylim([0 100])
Selected Bibliography
3GPP TS 36.101 "User Equipment (UE) radio transmission and reception"