Main Content

ltePCFICHPRBS

PCFICH pseudorandom scrambling sequence

Description

[seq,cinit] = ltePCFICHPRBS(enb,n) returns a vector containing the first n outputs of the physical control format indicator channel (PCFICH) scrambling sequence when initialized according to cell-wide settings structure, enb. It also returns an initialization value cinit for the pseudorandom binary sequence (PRBS) generator.

example

[seq,cinit] = ltePCFICHPRBS(enb,n,mapping) allows control over the format of the returned sequence, seq, with the input mapping.

example

[subseq,cinit] = ltePCFICHPRBS(enb,pn) returns a subsequence of a full PRBS sequence, specified by pn.

[subseq,cinit] = ltePCFICHPRBS(enb,pn,mapping) allows additional control over the format of the returned subsequence, subseq, with the input mapping.

Examples

collapse all

Scramble the CFI codeword.

Create cell-wide configuration structure, initialized to RMC R.14. Generate a CFI codeword and a pseudorandom scrambling sequence for the PCFICH the same length as the codeword.

enb = lteRMCDL('R.14');
cw = lteCFI(struct('CFI',2));
pcfichPrbsSeq = ltePCFICHPRBS(enb,length(cw));
size(pcfichPrbsSeq)
ans = 1×2

    32     1

Scramble the CFI codeword using the generated scrambling sequence.

scrambled = xor(pcfichPrbsSeq,cw);

Generate a signed pseudorandom scrambling sequence for the PCFICH. Each resource element (RE) in the PCFICH is QPSK-modulated, resulting in two bits-per-symbol mapping on each resource element.

Create cell-wide configuration structure, initialized to RMC R.14.

enb = lteRMCDL('R.14');
info = ltePCFICHInfo
info = struct with fields:
    NREG: 4
     NRE: 16

pcfichPrbsSeq = ltePCFICHPRBS(enb,info.NRE*2,'signed');
size(pcfichPrbsSeq)
ans = 1×2

    32     1

pcfichPrbsSeq(1:10)
ans = 10×1

     1
    -1
     1
     1
     1
     1
     1
    -1
    -1
     1

The scrambling sequence contains a vector of 32 signed ones.

Input Arguments

collapse all

Cell-wide settings, specified as a scalar structure. enb contains the following fields.

Physical layer cell identity, specified as a nonnegative scalar integer in the range of 0 to 503.

Data Types: double

Subframe number, specified as a positive scalar integer greater than 0.

Data Types: double

Data Types: struct

Length of scrambling sequence, specified as a positive scalar integer. This argument determines the number of elements in the output vector, seq.

Data Types: double

Range of scrambling subsequence, subseq, specified as a row vector of [p n]. The subsequence returns n values of the PRBS generator, starting at position p (0-based).

Data Types: double

Output sequence formatting, specified as 'binary' or 'signed'. mapping controls the format of the returned sequence.

  • 'binary' maps true to 1 and false to 0.

  • 'signed' maps true to –1 and false to 1.

Data Types: char | string

Output Arguments

collapse all

PCFICH pseudorandom scrambling sequence, returned as a logical column vector or a numeric column vector. seq contains the first n outputs of the PCFICH scrambling sequence when initialized according to cell-wide settings structure, enb. If you set mapping to 'signed', the output data type is double. Otherwise, the output data type is logical.

Data Types: logical | double

PCFICH pseudorandom scrambling subsequence, returned as a logical column vector or a numeric column vector. subseq contains the values of the PRBS generator specified by pn. If you set mapping to 'signed', the output data type is double. Otherwise, the output data type is logical.

Data Types: logical | double

Initialization value for PRBS generator, returned as a numeric scalar.

Data Types: uint32

Version History

Introduced in R2014a