Main Content

lteNPRACH

Generate NPRACH FDD waveform

Since R2021a

Description

[waveform,info,resourceGrid] = lteNPRACH(ue,chs) generates waveform, a time-domain narrowband physical random access channel (NPRACH) frequency-division duplexing (FDD) waveform for user equipment (UE) settings ue and channel transmission configuration chs. The function also returns info, a structure containing NPRACH information, and resourceGrid, an NPRACH resource grid.

example

Examples

collapse all

Generate an NPRACH waveform for specified UE settings and channel transmission configuration.

Specify the narrowband physical layer cell identity and subcarrier spacing.

ue = struct('NNCellID',0,'NBULSubcarrierSpacing','15kHz');

Specify the NPRACH format, periodicity, subcarrier offset, number of subcarriers, and number of preamble repetitions.

chs = struct('NPRACHFormat','0','Periodicity',80, ...
    'SubcarrierOffset',0,'NumSubcarriers',12,'NRep',1);

Generate the NPRACH waveform, NPRACH information, and resource grid.

[waveform,info,grid] = lteNPRACH(ue,chs);

Input Arguments

collapse all

UE-specific settings, specified as a structure containing these fields.

FieldRequired or OptionalValuesDescriptionData Type
NNCellIDRequiredInteger in the interval [0, 503]Narrowband physical layer cell identity.double
NBULSubcarrierSpacingRequired'3.75kHz', '15kHz'Narrowband internet of things (NB-IoT) uplink subcarrier spacing. To set a subcarrier spacing of 3.75 kHz, specify this field as '3.75kHz'. To set a subcarrier spacing of 15 kHz, specify this field as '15kHz'.char, string
WindowingOptionalNonnegative integer, default value depends on NPRACH preamble format in accordance with section F.5.F of [1]

Number of time-domain samples over which the function applies windowing and overlapping of OFDM samples.

If you do not specify this field, this function returns the Windowing field of the info output as a function of the NBULSubcarrierSpacing field. This behavior compromises between the effective duration of the cyclic prefix (and therefore the channel delay spread tolerance) and the spectral characteristics of the transmitted signal (not considering any additional FIR filtering). For NPRACH preamble format 2, the function sets the default value such that the ratio of cyclic prefix length to windowing length is the same as that of NPRACH preamble format 1.

double

Data Types: struct

Channel transmission configuration, specified as a structure containing these fields.

FieldRequired or OptionalValuesDescriptionDependenciesData Types
NPRACHFormatRequired'0', '1', '2'NPRACH preamble formatNot applicablechar, string
PeriodicityRequired40, 80, 160, 240 (since R2024b), 320, 640, 1280, 2560, 5120NPRACH resource periodicity, in milliseconds

If you set the NPRACHFormat field to '0' or '1', you cannot set this field to 5120.

If you set the NPRACHFormat field to '2', you cannot set this field to 240.

double
SubcarrierOffsetRequired0, 2, 6, 12, 18, 24, 34, 36, 42, 48, 54, 60, 72, 78, 84, 90, 102, 108Frequency location of the first subcarrier allocated to NPRACH

If you set the NPRACHFormat field to '0' or '1', you cannot set this field to 6, 42, 48, 54, 60, 72, 78, 84, 90, 102, or 108.

If you set the NPRACHFormat field to '2', you cannot set this field to 2 or 34.

double
NumSubcarriersRequired12, 24, 36, 48, 72, 108, 144Number of subcarriers allocated to NPRACH

If you set the NPRACHFormat field to '0' or '1', you cannot set this field to 72, 108, or 144.

If you set the NPRACHFormat field to '2', you cannot set this field to 12, 24, or 48.

double
NRepRequired1, 2, 4, 8, 16, 32, 64, 128Number of NPRACH repetitionsNot applicabledouble
StartTimeOptional8 (default), 16, 32, 64, 128, 256, 512, 1024NPRACH starting time, in millisecondsNot applicabledouble
NInitOptional0 (default), integer in the interval [0, NumSubcarriers – 1]Initial subcarrier for NPRACHNot applicabledouble
NPRACHPowerOptional0 (default), real-valued scalarNPRACH power scaling, in decibelsNot applicabledouble

Data Types: struct

Output Arguments

collapse all

Time-domain NPRACH FDD waveform, returned as a complex-valued column vector of length (chs.Periodicity × info.SamplingRate ÷ 1000). The waveform consists of:

  1. A period of zeros corresponding to the time, chs.StartTime, between the start of the transmission and the first frame occupied by an NPRACH symbol.

  2. The NPRACH transmission, defined in section 10.1.6.1 of [2] as a repetition of chs.NRep NPRACH preambles. An NPRACH preamble is a set of info.P symbol groups. A symbol group is a sequence of info.N identical symbols preceded by a cyclic prefix. The duration of an NPRACH preamble is a function of the preamble format as described in Table 10.1.6.1-1 of [2].

  3. A period of zeros corresponding to the time between the end of the transmission and the value of the chs.Periodicity input.

The function samples the waveform at the same sampling rate as for a narrowband physical uplink shared channel (NPUSCH) waveform, defined by the NBULSubcarrierSpacing field of the ue input.

For preamble formats 0 and 1, the function adds an additional 40 ms gap every 64 preambles. For preamble format 2, the function adds an additional 40 ms gap every 16 preambles.

For more information about NPRACH waveform generation, see the NB-IoT PRACH Waveform Generation example.

Data Types: double
Complex Number Support: Yes

NPRACH resource information, returned as a structure containing these fields.

FieldValuesDescriptionData Type
NfftPositive integerNumber of fast Fourier transform (FFT) points.double
SamplingRatePositive scalarSampling rate, in Hz, of the time-domain waveform.double
WindowingNonnegative integerNumber of time-domain samples over which the function applies windowing and overlapping of OFDM symbols.double
FrequencyLocationRow vector of nonnegative integersFrequency location for all symbol groups in an NPRACH transmission. For more information about NPRACH symbol groups, see the NB-IoT PRACH Waveform Generation example. The kth element of this output represents the frequency location of the kth symbol group.double
KPositive integerRatio of uplink data to NPRACH subcarrier spacing.double
NULSCPositive integerNumber of subcarriers for the specified uplink bandwidth.double
PreambleParametersStructureRandom access preamble parameters for the specified preamble format and frame structure type 1, as specified in Table 10.1.6.1-1 of [2].struct

PreambleParameters Field

The PreambleParameters field of this output contains these fields.

FieldValuesDescriptionData Type
GPositive integerNumber of time-contiguous symbol groups.double
PPositive integerTotal number of symbol groups.double
NPositive integerNumber of symbols in a symbol group.double
T_CPPositive integerCyclic prefix length, in multiples of Ts, where Ts is the basic time unit, defined in section 4 of [2] as 1 ÷ (15000 × 2048) seconds.double
T_SEQPositive integerLength of symbols in a symbol group, in multiples of Ts.double

Data Types: struct

NPRACH resource grid, returned as a real-valued matrix of size K-by-L, where:

  • K is the number of subcarriers.

  • L is the number of NPRACH symbols that fit the value of chs.Periodicity.

Data Types: double

References

[1] 3GPP TS 36.101. “Evolved Universal Terrestrial Radio Access (E-UTRA); User Equipment (UE) radio transmission and reception.” 3rd Generation Partnership Project; Technical Specification Group Radio Access Network. https://www.3gpp.org.

[2] 3GPP TS 36.211. “Physical channels and modulation.” 3rd Generation Partnership Project; Technical Specification Group Radio Access Network; Evolved Universal Terrestrial Radio Access (E-UTRA). https://www.3gpp.org.

Version History

Introduced in R2021a

expand all