Transform Precoding for 5G

This module implements the OFDM demodulator to recover the resource Grid back from the received samples.

class toolkit5G.OFDM.TransformPrecoding5G(numRB, nGroupPTRS=None, nSampGroup=None)[source]

This module implements transform precoding to reduce the effect of PAPR in 5G systems for three cases: 1. MIMO precoding in the PUSCH with single-layer transmission. 2. After symbol modulation in the PUCCH format 3 transmission. 3. After block-wise spreading in the PUCCH format 4 transmission.

Parameters:
  • numRB (int) – Defines the number of resource block allocated for transmission.

  • nGroupPTRS (int) – Defines the numbers of PTRS group. For PUSCH only.

  • nSampGroup (int) – Defines the numbers of samples in each PTRS group. For PUSCH only.

Input:

inputs ([…, numSubcarriers*numSets], np.complex) – Defines the streams of symbols to be tranform precoded. The numSets must be positive integer (>0). In 5G DFT-s-OFDM numSets is generally equal to number of OFDM symbols.

Output:

[…,numSubcarriers*numSets], np.complex – Transform precoded symbols. These symbols are mapped into the resource grid before OFDM.

Note

The length of input (inputs.shape[-1]) must be an integer multiple of numRB*12 - nGroupPTRS*nSampGroup.

Raises:
  • ValueError – “[Error-TransformPrecoding5G]: ‘inputs’ must be numpy array and complex!”

  • ValueError – “[Error-TransformPrecoding5G]: ‘Numbers of inputs must be multiple of numbers of subcarriers so that numbers of set is integer”

  • ValueError – “[Error-TransformPrecoding5G]: Numbers of sets (inputs.shape[-1]/(12*numRB)) cannot be greater than 14 since numbers of set is equal to numbers of OFDM symbols in a slot in 5G!”

  • ValueError – “[Error-TransformPrecoding5G]: ‘numRB’ must be positive (>0)!”

  • ValueError – “[Error-TransformPrecoding5G]: ‘numRB’ must be an integer!”

  • ValueError – “[Error-TransformPrecoding5G]: ‘nGroupPTRS’ in release-17 can take one of the 3 values [2,4,8]!”

  • ValueError – “[Error-TransformPrecoding5G]: ‘nGroupPTRS’ must be an integer!”

  • ValueError – “[Error-TransformPrecoding5G]: ‘nSampGroup’ must can take values only from the set “+str(possValues[ self.__nGroupPTRS])+” when ‘nGroupPTRS’ is “+str(self.__nGroupPTRS)+”!”

  • ValueError – “[Error-TransformPrecoding5G]: ‘nSampGroup’ must be an integer!”