Main Content

Resource Grid Indexing

Overview

The LTE Toolbox™ provides facilities to generate sequences of symbols corresponding to the physical channels and signals. Indices for the mapping of these sequences to the resource grid are also generated. For convenience, the LTE Toolbox uses the MATLAB®linear indexing style to represent these indices.

Subframe Resource Grid Size

Before applying OFDM modulation (IFFT), the physical channels and signals in LTE are mapped to different portions of the subframe resource grid. The subframe resource grid is represented in the LTE Toolbox as a multidimensional array of the following size.

12 N R B × 2 N s y m b × P

In the preceding expression, N R B 是横跨avai资源块的数量吗lable bandwidth, N s y m b is the number of OFDM (or SC-FDMA in the uplink) symbols per slot, and P is the number of antenna ports. Therefore, the resource grid represents a subframe (two slots) and whole bandwidth, since there are 12 subcarriers per resource block. For the single antenna case, a resource grid can be a two-dimensional matrix of the following size.

12 N R B × 2 N s y m b

Create Empty Resource Array

Create an empty downlink resource array by using two different methods. You can create valid and equivalent subframe resource arrays by using thelteDLResourceGridfunction or thezerosfunction.

Initialize Required Parameters

Create a parameter structure for a normal cyclic prefix, nine downlink resource blocks, and one transmit antenna.

enb = struct('CyclicPrefix','Normal','NDLRB',9,'CellRefP',1);

Define seven symbols per slot for use in thezerosfunction.

symbolsPerSlot = 7;

Create Empty Resource Arrays

Create an empty subframe resource array using each method.

resourceGrid1 = lteDLResourceGrid(enb); resourceGrid2 = zeros(enb.NDLRB*12,symbolsPerSlot*2,enb.CellRefP);

Compare Resource Arrays

Compare the two resource arrays. Because both approaches generate the same result, you can use either to create an empty downlink resource array. Similarly, you can create an empty uplink, sidelink, or narrowband resource array by using thelteULResourceGrid,lteSLResourceGrid, orlteNBResourceGridfunction, respectively, or thezerosfunction.

isequal(resourceGrid1,resourceGrid2)
ans =logical1

Resource Grid Indexing

Generate a reference signal and map it to an empty resource grid for the single antenna case. The LTE Toolbox™ has been designed to facilitate the mapping of physical channels and signals in the resource grid.

计算单元范围的配置设置。创建一个结构nd specify the cell-wide settings as its fields.

enb.CyclicPrefix ='Normal'; enb.NDLRB = 6; enb.CellRefP = 1; enb.NCellID = 1; enb.NSubframe = 0; enb.DuplexMode ='FDD'; antPort = 0;

Create an empty subframe resource grid by using thelteDLResourceGrid函数,然后填充网格with reference symbolsby using thelteCellRSIndicesandlteCellRSfunctions.

resourceGrid = lteDLResourceGrid(enb); ind = lteCellRSIndices(enb,antPort); rs = lteCellRS(enb,antPort); resourceGrid(ind) = rs;

To generates a list of indices identifying where to map the reference signal use the functionlteCellRSIndices. To generate the reference signal symbols, use thelteCellRSfunction.

Linear Indices and Subscripts

Generate indices in linear and subscript form. All of the LTE Toolbox™ index generation functions can produce linear or subscript formats by setting the appropriate options. The default is linear indexing, which allows access to any element of a matrix with a single index value. Using subscripted indexing in a 2-D matrix, you can access each element with a set of two elements representing the row and column equivalents.

The linear indexing style allows you to conveniently map the reference sequence symbols to the appropriate location in the resource grid with just one line of code. Mapping reference symbols to the resource grid using subscripted indices would require more finesse.

Create a structure specifying the cell-wide settings as its fields. Assign zero as the antenna port number.

enb.CyclicPrefix ='Normal'; enb.NDLRB = 6; enb.CellRefP = 1; enb.NCellID = 1; enb.NSubframe = 0; enb.DuplexMode ='FDD'; antPort = 0;

Create an empty subframe resource grid by using thelteDLResourceGridfunction, then create reference signal symbols by using thelteCellRSfunction. View the empty resource grid.

resourceGrid = lteDLResourceGrid(enb); rs = lteCellRS(enb,antPort); mesh(abs(resourceGrid)) view(2)

Figure contains an axes object. The axes object contains an object of type surface.

Generate linear indices.

ind_lin = lteCellRSIndices(enb,antPort);

Map the reference signal symbols to the resource grid.

resourceGrid(ind_lin) = rs;

Show the reference symbols active for the cell-wide settings assigned inenbby plotting the updated resource grid.

figure mesh(abs(resourceGrid)) view(2)

Figure contains an axes object. The axes object contains an object of type surface.

Alternatively, generate indices in subscript form by providing the“子”option string forlteCellRSIndices. In this case, the output indices represent the resource grid in the form [subcarrier, OFDM symbol, antenna port].

ind_sub = lteCellRSIndices(enb,antPort,“子”);

Converting Between Linear Indices and Subscripts

Conversion between linear indices and subscripts can be achieved using the MATLABind2subandsub2indfunctions. Alternatively, all index generation functions in the LTE Toolbox can produce both formats.

Multi-Antenna Linear Indices

Generate indices in multi-antenna linear form. This form is a variant of the MATLAB® linear indexing style in which the indices corresponding for each antenna port are in a different column. However, all indices are still in linear form. Several toolbox functions return indices in multi-antenna linear form.

To illustrate this, call the functionltePDSCHfor the four antenna case.

enb.CellRefP = 4; enb.CFI = 1; enb.NCellID = 1; enb.NSubframe = 0; enb.NDLRB = 6; enb.CyclicPrefix ='Normal'; enb.DuplexMode ='FDD'; pdsch.TxScheme ='TxDiversity'; pdsch.Modulation ='QPSK'; pdsch.RNTI = 1; pdsch.PRBSet = (0:5).'; data = ones(768,1); symb = ltePDSCH(enb,pdsch,data); size(symb)
ans =1×2384 4
symb(1:10,:)
ans =10×4 complex-0.5000 - 0.5000i 0.0000 + 0.0000i -0.5000 - 0.5000i 0.0000 + 0.0000i 0.5000 - 0.5000i 0.0000 + 0.0000i -0.5000 + 0.5000i 0.0000 + 0.0000i 0.0000 + 0.0000i -0.5000 - 0.5000i 0.0000 + 0.0000i 0.5000 - 0.5000i 0.0000 + 0.0000i -0.5000 - 0.5000i 0.0000 + 0.0000i -0.5000 + 0.5000i 0.5000 - 0.5000i 0.0000 + 0.0000i 0.5000 + 0.5000i 0.0000 + 0.0000i -0.5000 + 0.5000i 0.0000 + 0.0000i 0.5000 + 0.5000i 0.0000 + 0.0000i 0.0000 + 0.0000i 0.5000 + 0.5000i 0.0000 + 0.0000i -0.5000 + 0.5000i 0.0000 + 0.0000i 0.5000 + 0.5000i 0.0000 + 0.0000i 0.5000 - 0.5000i -0.5000 - 0.5000i 0.0000 + 0.0000i 0.5000 + 0.5000i 0.0000 + 0.0000i -0.5000 + 0.5000i 0.0000 + 0.0000i -0.5000 + 0.5000i 0.0000 + 0.0000i

The output argument,symb, is a matrix with four columns, in which each column corresponds to each antenna port.

In a similar format, generate the indices for the PDSCH by callingltePDSCHIndices.

pdschIndices = ltePDSCHIndices(enb,pdsch,pdsch.PRBSet); size(pdschIndices)
ans =1×2384 4
pdschIndices(1:10,:)
ans =10x4 uint32 matrix145 1153 2161 3169 146 1154 2162 3170 147 1155 2163 3171 148 1156 2164 3172 149 1157 2165 3173 150 1158 2166 3174 151 1159 2167 3175 152 1160 2168 3176 153 1161 2169 3177 154 1162 2170 3178

Again, each column corresponds to each of the four antenna ports. The concatenation of all four columns produces a column vector of indices using the MATLAB linear indexing style.

Index Base

Generate either zero-based or one-based indices. All mapping operations in the LTE technical specification (TS) documents refer to zero-based indexing. However, MATLAB® indices must be one-based. LTE Toolbox™ generates one-based indices by default, but you can generate zero-based indices by setting the appropriate options string.

Create a cell-wide setting structure and assign an antenna port number.

enb.NDLRB = 6; enb.NCellID = 1; enb.CyclicPrefix ='Normal'; enb.DuplexMode ='FDD'; antPort = 0;

Since one-based indexing is the default, you can generate one-based indices by specifying the'1based'flag or leaving it out.

ind = lteCellRSIndices(enb,antPort); ind = lteCellRSIndices(enb,antPort,'1based');

Generate zero-based indices by specifying the'0based'flag.

ind = lteCellRSIndices(enb,antPort,'0based');

Resource Blocks

The 3GPP documents describes aresource blockto be a group of resource elements spanning 12 consecutive subcarriers in the frequency domain and one slot in the time domain. For processing efficiency, the LTE Toolbox™, operates on a subframe (two timeslot) basis and describes aresource block pairto represent 12 consecutive subcarriers spanning in the frequency domain and one subframe (two slots) in the time domain. For example, the commandltePDSCHIndicesuses the parameterPRBSetto define the set of physical resource block (PRB) indices for a subframe of data.

Create the cell-wide settings structure and define thePDSCHconfiguration.

enb.CellRefP = 4; enb.CFI = 1; enb.NCellID = 1; enb.NSubframe = 0; enb.NDLRB = 6; enb.CyclicPrefix ='Normal'; enb.DuplexMode ='FDD'; pdsch.TxScheme ='TxDiversity'; pdsch.Modulation ='QPSK'; pdsch.RNTI = 1; pdsch.PRBSet = (0:5).';

Create a set of PDSCH PRB indices for the initialized configuration.

pdschIndices = ltePDSCHIndices(enb,pdsch,pdsch.PRBSet); size(pdschIndices)
ans =1×2384 4
pdschIndices(1:10,:)
ans =10x4 uint32 matrix145 1153 2161 3169 146 1154 2162 3170 147 1155 2163 3171 148 1156 2164 3172 149 1157 2165 3173 150 1158 2166 3174 151 1159 2167 3175 152 1160 2168 3176 153 1161 2169 3177 154 1162 2170 3178
pdsch
pdsch =struct with fields:TxScheme: 'TxDiversity' Modulation: 'QPSK' RNTI: 1 PRBSet: [6x1 double]

pdsch.PRBSetcan be either a column vector or a two-column matrix. If you provide a column vector, the resource allocation is the same in both slots of the subframe, which means the set of resource indices applies to both subframe time slots. On the other hand, if you provide a two-column matrix, the PRB indices refer to each slot individually.

See Also

|||||

Related Topics