22 #ifndef THREE_GPP_CHANNEL_H 23 #define THREE_GPP_CHANNEL_H 26 #include "ns3/angles.h" 27 #include <ns3/object.h> 28 #include <ns3/nstime.h> 29 #include <ns3/random-variable-stream.h> 30 #include <ns3/boolean.h> 31 #include <unordered_map> 32 #include <ns3/channel-condition-model.h> 33 #include <ns3/matrix-based-channel-model.h> 220 double dis2D,
double hBS,
double hUT)
const;
241 std::unordered_map<uint32_t, Ptr<ThreeGppChannelMatrix> >
m_channelMap;
This is an interface for a channel model that can be described by a channel matrix, e.g., the 3GPP Spatial Channel Models, which is generally used in combination with antenna arrays.
Simulation virtual time values and global simulation resolution.
std::unordered_map< uint32_t, Ptr< ThreeGppChannelMatrix > > m_channelMap
map containing the channel realizations
Smart pointer class similar to boost::intrusive_ptr.
Vector m_preLocUT
location of UT when generating the previous channel
~ThreeGppChannelModel()
Destructor.
void DoDispose() override
Destructor implementation.
static const uint8_t THETA_INDEX
index of the THETA value in the m_nonSelfBlocking array
Ptr< NormalRandomVariable > m_normalRv
normal random variable
std::string GetScenario(void) const
Returns the propagation scenario.
std::vector< double > DoubleVector
type definition for vectors of doubles
static const uint8_t R_INDEX
index of the R value in the m_nonSelfBlocking array
void SetChannelConditionModel(Ptr< ChannelConditionModel > model)
Set the channel condition model.
Ptr< ChannelConditionModel > m_channelConditionModel
the channel condition model
std::string m_scenario
the 3GPP scenario
bool m_los
true if LOS, false if NLOS
static const uint8_t X_INDEX
index of the X value in the m_nonSelfBlocking array
Ptr< const ParamsTable > GetThreeGppTable(bool los, bool o2i, double hBS, double hUT, double distance2D) const
Get the parameters needed to apply the channel generation procedure.
Vector m_locUT
location of UT
void SetFrequency(double f)
Sets the center frequency of the model.
double GetFrequency(void) const
Returns the center frequency.
ThreeGppChannelModel()
Constructor.
uint16_t m_numNonSelfBlocking
number of non-self-blocking regions
Time m_updatePeriod
the channel update period
MatrixBasedChannelModel::Double2DVector m_norRvAngles
stores the normal variable for random angles angle[cluster][id] generated for equation (7...
int64_t AssignStreams(int64_t stream)
Assign a fixed random variable stream number to the random variables used by this model...
Ptr< const ChannelMatrix > GetChannel(Ptr< const MobilityModel > aMob, Ptr< const MobilityModel > bMob, Ptr< const ThreeGppAntennaArrayModel > aAntenna, Ptr< const ThreeGppAntennaArrayModel > bAntenna) override
Looks for the channel matrix associated to the aMob and bMob pair in m_channelMap.
Channel Matrix Generation following 3GPP TR 38.901.
bool m_portraitMode
true if potrait mode, false if landscape
bool ChannelMatrixNeedsUpdate(Ptr< const ThreeGppChannelMatrix > channelMatrix, bool isLos) const
Check if the channel matrix has to be updated.
MatrixBasedChannelModel::Double3DVector m_clusterPhase
the initial random phases
double m_blockerSpeed
the blocker speed
Data structure that stores the parameters of 3GPP TR 38.901, Table 7.5-6, for a certain scenario...
double f(double x, void *params)
Every class exported by the ns3 library is enclosed in the ns3 namespace.
double m_dis3D
3D distance between tx and rx
Ptr< UniformRandomVariable > m_uniformRv
uniform random variable
std::vector< DoubleVector > Double2DVector
type definition for matrices of doubles
uint8_t m_numCluster
reduced cluster number;
std::vector< Double2DVector > Double3DVector
type definition for 3D matrices of doubles
void SetScenario(const std::string &scenario)
Sets the propagation scenario.
Extends the struct ChannelMatrix by including information that are used within the class ThreeGppChan...
double m_perClusterShadowingStd
static const uint8_t PHI_INDEX
index of the PHI value in the m_nonSelfBlocking array
bool m_blockage
enables the blockage model A
static TypeId GetTypeId()
Get the type ID.
MatrixBasedChannelModel::Double2DVector m_nonSelfBlocking
store the blockages
Data structure that stores a channel realization.
double m_dis2D
2D distance between tx and rx
struct holding the azimuth and inclination angles of spherical coordinates.
Ptr< ChannelConditionModel > GetChannelConditionModel() const
Get the associated channel condition model.
static const uint8_t Y_INDEX
index of the Y value in the m_nonSelfBlocking array
A template-based reference counting class.
a unique identifier for an interface.
Ptr< ThreeGppChannelMatrix > GetNewChannel(Vector locUT, bool los, bool o2i, Ptr< const ThreeGppAntennaArrayModel > sAntenna, Ptr< const ThreeGppAntennaArrayModel > uAntenna, Angles &uAngle, Angles &sAngle, double dis2D, double hBS, double hUT) const
Compute the channel matrix between two devices using the procedure described in 3GPP TR 38...
DoubleVector CalcAttenuationOfBlockage(Ptr< ThreeGppChannelMatrix > params, const DoubleVector &clusterAOA, const DoubleVector &clusterZOA) const
Applies the blockage model A described in 3GPP TR 38.901.
double m_frequency
the operating frequency