![]() |
5G-LENA nr-v3.3-120-gdac69c56
The 5G/NR module for the ns-3 simulator
|
An implementation of NrPmSearch that uses exhaustive search for 3GPP Type-I codebooks. This class creates a CQI/PMI/RI feedback message by looping over all ranks and selecting the rank that results in the largest achievable TB size. When a PMI update is requested, the optimal precoding matrices (PMI) are updated using exhaustive search over all possible precoding matrices specified in a codebook that is compatible to 3GPP TS 38.214 Type-I. More...
#include "nr-pm-search-full.h"
Classes | |
struct | RankParams |
Public Member Functions | |
PmCqiInfo | CreateCqiFeedbackMimo (const NrMimoSignal &rxSignalRb, PmiUpdate pmiUpdate) override |
Create CQI feedback with optimal rank, optimal PMI, and corresponding CQI values. Optimal rank is considered as the rank that maximizes the achievable TB size when using the optimal PMI. The optimal WB/SB PMI values are updated based on pmiUpdate. If there is no update to the PMI values, the previously found PMI values are used. | |
void | InitCodebooks () override |
Create and initialize the codebook for each rank. | |
void | SetCodebookAttribute (const std::string &attrName, const AttributeValue &attrVal) |
Set the ns-3 attribute of the codebook (NrCbTypeOne). | |
void | SetCodebookTypeId (const TypeId &typeId) |
Set the TypeId of the codebook (NrCbTypeOne) to be used. | |
![]() | |
NrPmSearch () | |
Default constructor. | |
int64_t | AssignStreams (int64_t stream) |
size_t | GetSubbandSize () const |
virtual uint8_t | SelectRank (NrIntfNormChanMat &channelMatrix) const |
Select the MIMO rank for a given channel matrix. | |
void | SetAmc (Ptr< const NrAmc > amc) |
Set the AMC object to be used for MCS and TB size calculation. | |
void | SetGnbParams (bool isDualPol, size_t numHPorts, size_t numVPorts) |
Set the antenna parameters of the gNB antenna. | |
void | SetSubbandSize (size_t subbandSize) |
Set the subband size (in number of RBs) | |
void | SetUeParams (size_t numTotalPorts) |
Set the antenna parameters of the UE antenna. | |
virtual NrIntfNormChanMat | SubbandDownsampling (const NrIntfNormChanMat &channelMatrix) |
Downsample the input channel matrix into bins of at most m_subbandSize PRBs. | |
virtual NrIntfNormChanMat | SubbandUpsampling (const NrIntfNormChanMat &precMat, size_t numPrbs) const |
Upsample the input per-subband precoding matrix into a per-PRB precoding matrix. | |
Static Public Member Functions | |
static TypeId | GetTypeId () |
Get TypeId. | |
![]() | |
static TypeId | GetTypeId () |
Get TypeId. | |
Protected Member Functions | |
DoubleMatrixArray | ComputeCapacityForPrecoders (const NrIntfNormChanMat &sbNormChanMat, std::vector< ComplexMatrixArray > allPrecMats) const |
Compute the Shannon capacity for each possible precoding matrix in each subband. | |
void | ConditionallyUpdatePrecoding (const NrIntfNormChanMat &rbNormChanMat, PmiUpdate pmiUpdate) |
Update the WB and/or SB PMI, or neither. | |
PmCqiInfo | CreateCqiForRank (uint8_t rank, const NrIntfNormChanMat &rbNormChanMat) const |
Create CQI feedback message for a particular rank. | |
std::vector< ComplexMatrixArray > | CreateSubbandPrecoders (size_t i1, uint8_t rank, size_t nSubbands) const |
Create the subband precoding matrices for the given wideband precoding. | |
virtual Ptr< PrecMatParams > | FindOptSubbandPrecoding (const NrIntfNormChanMat &sbNormChanMat, size_t i1, uint8_t rank) const |
Find the optimal subband precoding matrix for the given wideband precoding. | |
void | UpdateAllPrecoding (const NrIntfNormChanMat &rbNormChanMat) |
For all ranks, update the optimum precoding matrices (wideband and subband). | |
void | UpdateSubbandPrecoding (const NrIntfNormChanMat &rbNormChanMat) |
For all ranks, update the opt subband PMI assuming previous value of wideband PMI. | |
Static Protected Member Functions | |
static ComplexMatrixArray | ExpandPrecodingMatrix (ComplexMatrixArray basePrecMat, size_t nSubbands) |
Protected Attributes | |
ObjectFactory | m_cbFactory |
The factory used to create the codebooks. | |
std::vector< RankParams > | m_rankParams |
The parameters (PMI values, codebook) for each rank. | |
![]() | |
Ptr< const NrAmc > | m_amc {nullptr} |
The NrAmc to be used for computing TB size and MCS. | |
enum DownsamplingTechnique | m_downsamplingTechnique |
Technique used to downsample PRBs. | |
Ptr< UniformRandomVariable > | m_downsamplingUniRand |
Uniform variable stream used to downsample PRBs. | |
bool | m_isGnbDualPol {false} |
True when gNB has a dual-polarized antenna array. | |
size_t | m_nGnbHPorts {0} |
Number of horizontal ports in the gNB antenna array. | |
size_t | m_nGnbPorts {0} |
Total number of ports in the gNB antenna array. | |
size_t | m_nGnbVPorts {0} |
Number of vertical ports in the gNB antenna array. | |
size_t | m_nRxPorts {0} |
Number of receive ports at this UE. | |
uint8_t | m_rankLimit {UINT8_MAX} |
Limit the UE's maximum supported rank. | |
std::vector< uint8_t > | m_ranks {} |
The set of ranks for which to compute precoding matrices. | |
bool | m_subbandCqiClamping |
size_t | m_subbandSize {1} |
Size of each subband (in number of RBs) | |
Additional Inherited Members | |
![]() | |
enum | DownsamplingTechnique { FirstPRB , RandomPRB , AveragePRB } |
enum | RankTechnique { SVD , WaterFilling , Sasaoka } |
An implementation of NrPmSearch that uses exhaustive search for 3GPP Type-I codebooks. This class creates a CQI/PMI/RI feedback message by looping over all ranks and selecting the rank that results in the largest achievable TB size. When a PMI update is requested, the optimal precoding matrices (PMI) are updated using exhaustive search over all possible precoding matrices specified in a codebook that is compatible to 3GPP TS 38.214 Type-I.
Introspection did not find any typical Config paths.
No TraceSources are defined for this type.
Size of this type is 232 bytes (on a 64-bit architecture).
Definition at line 23 of file nr-pm-search-full.h.
|
protected |
Compute the Shannon capacity for each possible precoding matrix in each subband.
sbNormChanMat | the interference-normed channel matrix per subband |
allPrecMats | a vector of all possible subband precoding matrices for fixed i1 and rank |
Definition at line 297 of file nr-pm-search-full.cc.
References ns3::NrIntfNormChanMat::ComputeSinrForPrecoding().
Referenced by ns3::NrPmSearchMaleki::CreateCqiFeedbackMimo(), FindOptSubbandPrecoding(), and ns3::NrPmSearchFast::GetWidebandI1().
|
protected |
Update the WB and/or SB PMI, or neither.
rbNormChanMat | the interference-normed channel matrix per RB |
pmiUpdate | the struct defining if updates to SB or WB PMI are necessary |
Definition at line 108 of file nr-pm-search-full.cc.
References UpdateAllPrecoding(), ns3::NrPmSearch::PmiUpdate::updateSb, UpdateSubbandPrecoding(), and ns3::NrPmSearch::PmiUpdate::updateWb.
Referenced by CreateCqiFeedbackMimo().
|
overridevirtual |
Create CQI feedback with optimal rank, optimal PMI, and corresponding CQI values. Optimal rank is considered as the rank that maximizes the achievable TB size when using the optimal PMI. The optimal WB/SB PMI values are updated based on pmiUpdate. If there is no update to the PMI values, the previously found PMI values are used.
rxSignalRb | the receive signal parameters (channel and interference matrices) |
pmiUpdate | struct that defines if WB/SB PMIs need to be updated |
Implements ns3::NrPmSearch.
Reimplemented in ns3::NrPmSearchIdeal, ns3::NrPmSearchMaleki, and ns3::NrPmSearchSasaoka.
Definition at line 66 of file nr-pm-search-full.cc.
References ns3::NrCovMat::CalcIntfNormChannel(), ConditionallyUpdatePrecoding(), CreateCqiForRank(), ns3::NrMimoSignal::m_chanMat, ns3::NrMimoSignal::m_covMat, ns3::NrPmSearch::m_nGnbPorts, ns3::NrPmSearch::m_nRxPorts, and ns3::NrPmSearch::m_ranks.
|
protected |
Create CQI feedback message for a particular rank.
rank | the rank for which to create the CQI feedback |
rbNormChanMat | the interference-normed channel matrix per RB |
Definition at line 167 of file nr-pm-search-full.cc.
References ns3::NrIntfNormChanMat::ComputeSinrForPrecoding(), ns3::NrPmSearch::m_amc, ns3::PmCqiInfo::m_mcs, m_rankParams, ns3::NrPmSearch::m_subbandCqiClamping, ns3::NrPmSearch::m_subbandSize, and ns3::NrPmSearch::SubbandUpsampling().
Referenced by ns3::NrPmSearchFast::CreateCqiFeedbackMimo(), CreateCqiFeedbackMimo(), ns3::NrPmSearchIdeal::CreateCqiFeedbackMimo(), ns3::NrPmSearchMaleki::CreateCqiFeedbackMimo(), and ns3::NrPmSearchSasaoka::CreateCqiFeedbackMimo().
|
protected |
Create the subband precoding matrices for the given wideband precoding.
i1 | the index of the wideband precoding matrix W1 |
rank | the rank (number of MIMO layers) |
nSubbands | the number of subbands (desired number of pages in each precoding matrix) |
Definition at line 260 of file nr-pm-search-full.cc.
References m_rankParams.
Referenced by FindOptSubbandPrecoding().
|
staticprotected |
Definition at line 277 of file nr-pm-search-full.cc.
|
protectedvirtual |
Find the optimal subband precoding matrix for the given wideband precoding.
sbNormChanMat | the interference-normed channel matrix per subband |
i1 | the index of the wideband precoding matrix W1 |
rank | the rank (number of MIMO layers) |
Reimplemented in ns3::NrPmSearchSasaoka.
Definition at line 214 of file nr-pm-search-full.cc.
References ComputeCapacityForPrecoders(), and CreateSubbandPrecoders().
Referenced by ns3::NrPmSearchFast::CreateCqiFeedbackMimo(), ns3::NrPmSearchMaleki::CreateCqiFeedbackMimo(), UpdateAllPrecoding(), and UpdateSubbandPrecoding().
|
static |
Get TypeId.
Definition at line 20 of file nr-pm-search-full.cc.
References ns3::NrCbTwoPort::GetTypeId(), and SetCodebookTypeId().
Referenced by ns3::NrHelper::GetTypeId(), and ns3::NrHelper::SetupMimoPmi().
|
overridevirtual |
Create and initialize the codebook for each rank.
Implements ns3::NrPmSearch.
Definition at line 47 of file nr-pm-search-full.cc.
References ns3::NrCbTypeOne::Init(), m_cbFactory, ns3::NrPmSearch::m_isGnbDualPol, ns3::NrPmSearch::m_nGnbHPorts, ns3::NrPmSearch::m_nGnbPorts, ns3::NrPmSearch::m_nGnbVPorts, ns3::NrPmSearch::m_nRxPorts, ns3::NrPmSearch::m_rankLimit, m_rankParams, and ns3::NrPmSearch::m_ranks.
void ns3::NrPmSearchFull::SetCodebookAttribute | ( | const std::string & | attrName, |
const AttributeValue & | attrVal | ||
) |
Set the ns-3 attribute of the codebook (NrCbTypeOne).
attrName | the name of the attribute |
attrVal | the value of the attribute |
Definition at line 40 of file nr-pm-search-full.cc.
References m_cbFactory.
void ns3::NrPmSearchFull::SetCodebookTypeId | ( | const TypeId & | typeId | ) |
Set the TypeId of the codebook (NrCbTypeOne) to be used.
typeId | the TypeId of the codebook |
Definition at line 34 of file nr-pm-search-full.cc.
References m_cbFactory.
Referenced by GetTypeId().
|
protected |
For all ranks, update the optimum precoding matrices (wideband and subband).
rbNormChanMat | the interference-normed channel matrix per RB |
Definition at line 122 of file nr-pm-search-full.cc.
References FindOptSubbandPrecoding(), m_rankParams, ns3::NrPmSearch::m_ranks, and ns3::NrPmSearch::SubbandDownsampling().
Referenced by ConditionallyUpdatePrecoding().
|
protected |
For all ranks, update the opt subband PMI assuming previous value of wideband PMI.
rbNormChanMat | the interference-normed channel matrix per RB |
Definition at line 152 of file nr-pm-search-full.cc.
References FindOptSubbandPrecoding(), m_rankParams, ns3::NrPmSearch::m_ranks, and ns3::NrPmSearch::SubbandDownsampling().
Referenced by ConditionallyUpdatePrecoding().
|
protected |
The factory used to create the codebooks.
Definition at line 108 of file nr-pm-search-full.h.
Referenced by InitCodebooks(), SetCodebookAttribute(), and SetCodebookTypeId().
|
protected |
The parameters (PMI values, codebook) for each rank.
Definition at line 107 of file nr-pm-search-full.h.
Referenced by ns3::NrPmSearchFast::CreateCqiFeedbackMimo(), ns3::NrPmSearchIdeal::CreateCqiFeedbackMimo(), ns3::NrPmSearchMaleki::CreateCqiFeedbackMimo(), ns3::NrPmSearchSasaoka::CreateCqiFeedbackMimo(), CreateCqiForRank(), CreateSubbandPrecoders(), ns3::NrPmSearchSasaoka::FindOptSubbandPrecoding(), InitCodebooks(), UpdateAllPrecoding(), and UpdateSubbandPrecoding().