Main Content

ltePSSCHDRSIndices

PSSCH DM-RS resource element indices

Description

ind = ltePSSCHDRSIndices(ue) returns a column vector of PSSCH demodulation reference signal (DM-RS) resource element indices for the specified UE settings structure. For more information, see PSSCH Demodulation Reference Signal Indexing.

example

ind = ltePSSCHDRSIndices(ue,opts) formats the returned indices using options specified by opts.

example

Examples

collapse all

Write the complex PSSCH DM-RS values into the PSSCH DM-RS resource elements in a PSSCH subframe both for D2D normal cyclic prefix and V2X. Display an image of their locations to compare both sidelink modes.

Create a user equipment settings structure and an empty resource grid subframe for 10 MHz bandwidth and normal cyclic prefix. Define a PRB allocation, ue.PRBSet, with RB values from 30 to 39.

ue = struct('NSLRB',50,'CyclicPrefixSL','Normal');
ue.NSAID = 1;
ue.NSubframePSSCH = 1;
ue.PRBSet = [30:39]';
subframe_D2D = lteSLResourceGrid(ue);

Generate PSSCH DM-RS indices and load PSSCH DM-RS values into the subframe.

psschdrs_indices = ltePSSCHDRSIndices(ue);
subframe_D2D(psschdrs_indices) = ltePSSCHDRS(ue);

Change user equipment settings to V2X sidelink mode. Set the V2X scrambling identity to 5334.

ue.SidelinkMode = 'V2X';
ue.NXID = 5334;
subframe_V2X = lteSLResourceGrid(ue);
psschdrs_indices = ltePSSCHDRSIndices(ue);
subframe_V2X(psschdrs_indices) = ltePSSCHDRS(ue);

Display the PSCCH DM-RS locations for both sidelink modes.

subplot(2,1,1);
imagesc(100*abs(subframe_D2D))
axis xy; title('D2D');
subplot(2,1,2);
imagesc(100*abs(subframe_V2X)); 
axis xy; title(ue.SidelinkMode);

Figure contains 2 axes objects. Axes object 1 with title D2D contains an object of type image. Axes object 2 with title V2X contains an object of type image.

Compare PSSCH DM-RS resource element indexing formats.

Create a UE settings structure.

ue = struct('NSLRB',15,'CyclicPrefixSL','Normal','PRBSet',5);

Generate PSSCH DM-RS indices using one-based linear indexing (default), zero-based linear indexing, and one-based subscript row style.

One-based linear indexing

psschdmrs_indices = ltePSSCHDRSIndices(ue);
psschdmrs_indices(1)
ans = uint32

601

Zero-based linear indexing

opts = '0based';
psschdmrs_indices_0based = ltePSSCHDRSIndices(ue,opts);
psschdmrs_indices_0based(1)
ans = uint32

600

For zero-based indexing, the first assigned index is one lower than the one-based indexing.

One-based indexing in [subcarrier,symbol,port] subscript row style

Inspect the unique symbol values to see which symbols are occupied by the PSSCH DM-RS.

opts = {'sub' '1based'};
psschdmrs_indices_sub = ltePSSCHDRSIndices(ue,opts);
unique(psschdmrs_indices_sub(:,2,:))
ans = 2×1 uint32 column vector

    4
   11

Only symbols 4 and 11 are occupied. For one-based indexing, these two PSSCH subframe symbols are always reserved for transmission of the PSSCH DM-RS.

Input Arguments

collapse all

User equipment settings, specified as a parameter structure containing these fields:

Sidelink mode, specified as 'D2D' or 'V2X'.

Data Types: char | string

Number of sidelink resource blocks, specified as an integer scalar from 6 to 110.

Example: 6, which corresponds to a channel bandwidth of 1.4 MHz.

Data Types: double

Cyclic prefix length, specified as 'Normal' or 'Extended'.

Data Types: char | string

Zero-based physical resource block (PRB) indices, specified as an integer column vector or a two-column integer matrix.

The PSSCH is intended to be transmitted in the same PRB in each slot of a subframe. Therefore, specifying PRBSet as a single column of PRB indices is recommended. However, for a nonstandard slot-hopping PRB allocation, PRBSet can be specified as a two-column matrix of indices corresponding to slot-wise resource allocations for PSSCH.

Data Types: double

Data Types: struct

Output format options for resource element indices, specified as a character vector, cell array of character vectors, or string array. For convenience, you can specify several options as a single character vector or string scalar by a space-separated list of values placed inside the quotes. Values for opts when specified as a character vector include (use double quotes for string) :

Category Options Description

Indexing style

'ind' (default)

The returned indices are in linear index style.

'sub'

The returned indices are in [subcarrier,symbol,port] subscript row style.

Index base

'1based' (default)

The returned indices are one-based.

'0based'

The returned indices are zero-based.

Example: 'ind 1based', "ind 1based", {'ind','1based'}, or ["ind","1based"] specify the same formatting options.

Data Types: char | string | cell

Output Arguments

collapse all

PSSCH DM-RS resource element indices, returned as an integer column vector or a three-column integer matrix. The returned vector or matrix has 24 × NPRB PSSCH DM-RS resource element indices. where NPRB is the number of PRBs associated with the PSSCH. For more information, see PSSCH Demodulation Reference Signal Indexing.

More About

collapse all

Version History

Introduced in R2016b