21 #include "ns3/boolean.h"
22 #include "ns3/channel-condition-model.h"
23 #include "ns3/double.h"
25 #include "ns3/mobility-model.h"
27 #include "ns3/pointer.h"
28 #include "ns3/simulator.h"
37 static const double M_C = 3.0e8;
47 TypeId(
"ns3::ThreeGppPropagationLossModel")
49 .SetGroupName(
"Propagation")
50 .AddAttribute(
"Frequency",
51 "The centre frequency in Hz.",
55 MakeDoubleChecker<double>())
56 .AddAttribute(
"ShadowingEnabled",
57 "Enable/disable shadowing.",
62 "ChannelConditionModel",
63 "Pointer to the channel condition model.",
67 MakePointerChecker<ChannelConditionModel>())
68 .AddAttribute(
"EnforceParameterRanges",
69 "Whether to strictly enforce TR38.901 applicability ranges",
74 "BuildingPenetrationLossesEnabled",
75 "Enable/disable Building Penetration Losses.",
136 "Frequency should be between 0.5 and 100 GHz but is " <<
f);
170 double rxPow = txPowerDbm;
171 rxPow -=
GetLoss(cond, distance2d, distance3d, heights.first, heights.second);
179 if (cond->GetO2iCondition() == ChannelCondition::O2iConditionValue::O2I &&
182 if (cond->GetO2iLowHighCondition() == ChannelCondition::O2iLowHighConditionValue::LOW)
186 else if (cond->GetO2iLowHighCondition() == ChannelCondition::O2iLowHighConditionValue::HIGH)
192 NS_ABORT_MSG(
"If we have set the O2I condition, we shouldn't be here");
209 if (cond->GetLosCondition() == ChannelCondition::LosConditionValue::LOS)
211 loss =
GetLossLos(distance2d, distance3d, hUt, hBs);
213 else if (cond->GetLosCondition() == ChannelCondition::LosConditionValue::NLOSv)
217 else if (cond->GetLosCondition() == ChannelCondition::LosConditionValue::NLOS)
219 loss =
GetLossNlos(distance2d, distance3d, hUt, hBs);
237 double o2iLossValue = 0;
238 double lowLossTw = 0;
240 double lowlossNormalVariate = 0;
242 double lConcrete = 0;
245 uint32_t key =
GetKey(a, b);
247 bool notFound =
false;
248 bool newCondition =
false;
255 newCondition = (it->second.m_condition != cond);
262 it =
m_o2iLossMap.insert(it, std::make_pair(key, newItem));
265 if (notFound || newCondition)
277 5 - 10 * log10(0.3 * std::pow(10, -lGlass / 10) + 0.7 * std::pow(10, -lConcrete / 10));
280 lossIn = 0.5 * distance2dIn;
285 o2iLossValue = lowLossTw + lossIn + lowlossNormalVariate;
289 o2iLossValue = it->second.m_o2iLoss;
293 it->second.m_o2iLoss = o2iLossValue;
294 it->second.m_condition = cond;
307 double o2iLossValue = 0;
308 double highLossTw = 0;
310 double highlossNormalVariate = 0;
311 double lIIRGlass = 0;
312 double lConcrete = 0;
315 uint32_t key =
GetKey(a, b);
317 bool notFound =
false;
318 bool newCondition =
false;
325 newCondition = (it->second.m_condition != cond);
332 it =
m_o2iLossMap.insert(it, std::make_pair(key, newItem));
335 if (notFound || newCondition)
348 highLossTw = 5 - 10 * log10(0.7 * std::pow(10, -lIIRGlass / 10) +
349 0.3 * std::pow(10, -lConcrete / 10));
352 lossIn = 0.5 * distance2dIn;
357 o2iLossValue = highLossTw + lossIn + highlossNormalVariate;
361 o2iLossValue = it->second.m_o2iLoss;
365 it->second.m_o2iLoss = o2iLossValue;
366 it->second.m_condition = cond;
389 double shadowingValue;
392 uint32_t key =
GetKey(a, b);
394 bool notFound =
false;
395 bool newCondition =
false;
403 newCondition = (it->second.m_condition != cond);
414 if (notFound || newCondition)
422 Vector2D displacement(newDistance.x - it->second.m_distance.x,
423 newDistance.y - it->second.m_distance.y);
425 shadowingValue = R * it->second.m_shadowing + sqrt(1 - R * R) *
431 it->second.m_shadowing = shadowingValue;
432 it->second.m_distance = newDistance;
434 it->second.m_condition = cond;
436 return shadowingValue;
439 std::pair<double, double>
447 return std::pair<double, double>(hUt, hBs);
467 double x = a.x - b.x;
468 double y = a.y - b.y;
469 double distance2D = sqrt(
x *
x + y * y);
483 uint32_t key = (((x1 + x2) * (x1 + x2 + 1)) / 2) + x2;
511 static TypeId tid =
TypeId(
"ns3::ThreeGppRmaPropagationLossModel")
513 .SetGroupName(
"Propagation")
515 .AddAttribute(
"AvgBuildingHeight",
516 "The average building height in meters.",
519 MakeDoubleChecker<double>(5.0, 50.0))
520 .AddAttribute(
"AvgStreetWidth",
521 "The average street width in meters.",
524 MakeDoubleChecker<double>(5.0, 50.0));
558 "RMa scenario is valid for frequencies between 0.5 and 30 GHz.");
561 if (hUt < 1.0 || hUt > 10.0)
565 "The height of the UT should be between 1 and 10 m (see TR 38.901, Table 7.4.1-1)");
568 if (hBs < 10.0 || hBs > 150.0)
572 "The height of the BS should be between 10 and 150 m (see TR 38.901, Table 7.4.1-1)");
586 "Breakpoint distance is zero (divide-by-zero below); are either hBs or hUt = 0?");
589 if (distance2D < 10.0 || distance2D > 10.0e3)
592 NS_LOG_WARN(
"The 2D distance is outside the validity range, the pathloss value may not be "
598 if (distance2D <= distanceBp)
622 "RMa scenario is valid for frequencies between 0.5 and 30 GHz.");
625 if (hUt < 1.0 || hUt > 10.0)
629 "The height of the UT should be between 1 and 10 m (see TR 38.901, Table 7.4.1-1)");
632 if (hBs < 10.0 || hBs > 150.0)
636 "The height of the BS should be between 10 and 150 m (see TR 38.901, Table 7.4.1-1)");
647 if (distance2D < 10.0 || distance2D > 5.0e3)
650 NS_LOG_WARN(
"The 2D distance is outside the validity range, the pathloss value may not be "
655 double plNlos = 161.04 - 7.1 * log10(
m_w) + 7.5 * log10(
m_h) -
656 (24.37 - 3.7 * pow((
m_h / hBs), 2)) * log10(hBs) +
657 (43.42 - 3.1 * log10(hBs)) * (log10(distance3D) - 3.0) +
658 20.0 * log10(
m_frequency / 1e9) - (3.2 * pow(log10(11.75 * hUt), 2) - 4.97);
675 if (cond == ChannelCondition::LosConditionValue::LOS)
683 if (distance2d <= distanceBp)
692 else if (cond == ChannelCondition::LosConditionValue::NLOS)
709 double correlationDistance;
712 if (cond == ChannelCondition::LosConditionValue::LOS)
714 correlationDistance = 37;
716 else if (cond == ChannelCondition::LosConditionValue::NLOS)
718 correlationDistance = 120;
725 return correlationDistance;
731 double loss = 20.0 * log10(40.0 * M_PI * distance3D * frequency / 1e9 / 3.0) +
732 std::min(0.03 * pow(h, 1.72), 10.0) * log10(distance3D) -
733 std::min(0.044 * pow(h, 1.72), 14.77) + 0.002 * log10(h) * distance3D;
740 double distanceBp = 2.0 * M_PI * hA * hB * frequency /
M_C;
751 static TypeId tid =
TypeId(
"ns3::ThreeGppUmaPropagationLossModel")
753 .SetGroupName(
"Propagation")
779 if (distance2D > 18.0)
781 g = 5.0 / 4.0 * pow(distance2D / 100.0, 3) * exp(-distance2D / 150.0);
788 c = pow((hUt - 13.0) / 10.0, 1.5) * g;
792 double prob = 1.0 / (1.0 + c);
801 hE = (double)floor(random / 3.0) * 3.0;
805 double distanceBp = 4 * (hBs - hE) * (hUt - hE) *
m_frequency /
M_C;
819 if (hUt < 1.5 || hUt > 22.5)
823 "The height of the UT should be between 1.5 and 22.5 m (see TR 38.901, Table 7.4.1-1)");
829 NS_LOG_WARN(
"The height of the BS should be equal to 25 m (see TR 38.901, Table 7.4.1-1)");
844 if (distance2D < 10.0 || distance2D > 5.0e3)
847 NS_LOG_WARN(
"The 2D distance is outside the validity range, the pathloss value may not be "
853 if (distance2D <= distanceBp)
856 loss = 28.0 + 22.0 * log10(distance3D) + 20.0 * log10(
m_frequency / 1e9);
861 loss = 28.0 + 40.0 * log10(distance3D) + 20.0 * log10(
m_frequency / 1e9) -
862 9.0 * log10(pow(distanceBp, 2) + pow(hBs - hUt, 2));
887 if (hUt < 1.5 || hUt > 22.5)
891 "The height of the UT should be between 1.5 and 22.5 m (see TR 38.901, Table 7.4.1-1)");
897 NS_LOG_WARN(
"The height of the BS should be equal to 25 m (see TR 38.901, Table 7.4.1-1)");
908 if (distance2D < 10.0 || distance2D > 5.0e3)
911 NS_LOG_WARN(
"The 2D distance is outside the validity range, the pathloss value may not be "
917 13.54 + 39.08 * log10(distance3D) + 20.0 * log10(
m_frequency / 1e9) - 0.6 * (hUt - 1.5);
932 if (cond == ChannelCondition::LosConditionValue::LOS)
936 else if (cond == ChannelCondition::LosConditionValue::NLOS)
953 double correlationDistance;
956 if (cond == ChannelCondition::LosConditionValue::LOS)
958 correlationDistance = 37;
960 else if (cond == ChannelCondition::LosConditionValue::NLOS)
962 correlationDistance = 50;
969 return correlationDistance;
989 static TypeId tid =
TypeId(
"ns3::ThreeGppUmiStreetCanyonPropagationLossModel")
991 .SetGroupName(
"Propagation")
1021 double distanceBp = 4 * (hBs - hE) * (hUt - hE) *
m_frequency /
M_C;
1043 if (hUt < 1.5 || hUt >= 10.0)
1047 "The height of the UT should be between 1.5 and 22.5 m (see TR 38.901, Table 7.4.1-1). "
1048 "We further assume hUT < hBS, then hUT is upper bounded by hBS, which should be 10 m");
1054 NS_LOG_WARN(
"The height of the BS should be equal to 10 m (see TR 38.901, Table 7.4.1-1)");
1069 if (distance2D < 10.0 || distance2D > 5.0e3)
1072 NS_LOG_WARN(
"The 2D distance is outside the validity range, the pathloss value may not be "
1078 if (distance2D <= distanceBp)
1081 loss = 32.4 + 21.0 * log10(distance3D) + 20.0 * log10(
m_frequency / 1e9);
1086 loss = 32.4 + 40.0 * log10(distance3D) + 20.0 * log10(
m_frequency / 1e9) -
1087 9.5 * log10(pow(distanceBp, 2) + pow(hBs - hUt, 2));
1104 if (hUt < 1.5 || hUt >= 10.0)
1108 "The height of the UT should be between 1.5 and 22.5 m (see TR 38.901, Table 7.4.1-1). "
1109 "We further assume hUT < hBS, then hUT is upper bounded by hBS, which should be 10 m");
1115 NS_LOG_WARN(
"The height of the BS should be equal to 10 m (see TR 38.901, Table 7.4.1-1)");
1126 if (distance2D < 10.0 || distance2D > 5.0e3)
1129 NS_LOG_WARN(
"The 2D distance is outside the validity range, the pathloss value may not be "
1135 22.4 + 35.3 * log10(distance3D) + 21.3 * log10(
m_frequency / 1e9) - 0.3 * (hUt - 1.5);
1142 std::pair<double, double>
1155 else if (zb == 10.0)
1169 return std::pair<double, double>(hUt, hBs);
1179 double shadowingStd;
1181 if (cond == ChannelCondition::LosConditionValue::LOS)
1185 else if (cond == ChannelCondition::LosConditionValue::NLOS)
1187 shadowingStd = 7.82;
1194 return shadowingStd;
1202 double correlationDistance;
1205 if (cond == ChannelCondition::LosConditionValue::LOS)
1207 correlationDistance = 10;
1209 else if (cond == ChannelCondition::LosConditionValue::NLOS)
1211 correlationDistance = 13;
1218 return correlationDistance;
1228 static TypeId tid =
TypeId(
"ns3::ThreeGppIndoorOfficePropagationLossModel")
1230 .SetGroupName(
"Propagation")
1264 if (distance3D < 1.0 || distance3D > 150.0)
1267 NS_LOG_WARN(
"The 3D distance is outside the validity range, the pathloss value may not be "
1272 double loss = 32.4 + 17.3 * log10(distance3D) + 20.0 * log10(
m_frequency / 1e9);
1288 if (distance3D < 1.0 || distance3D > 150.0)
1291 NS_LOG_WARN(
"The 3D distance is outside the validity range, the pathloss value may not be "
1296 double plNlos = 17.3 + 38.3 * log10(distance3D) + 24.9 * log10(
m_frequency / 1e9);
1311 double shadowingStd;
1313 if (cond == ChannelCondition::LosConditionValue::LOS)
1317 else if (cond == ChannelCondition::LosConditionValue::NLOS)
1319 shadowingStd = 8.03;
1326 return shadowingStd;
1336 double correlationDistance;
1338 if (cond == ChannelCondition::LosConditionValue::LOS)
1340 correlationDistance = 10;
1342 else if (cond == ChannelCondition::LosConditionValue::NLOS)
1344 correlationDistance = 6;
1351 return correlationDistance;
double f(double x, void *params)
AttributeValue implementation for Boolean.
LosConditionValue
Possible values for Line-of-Sight condition.
This class can be used to hold variables of floating point type such as 'double' or 'float'.
Vector GetPosition() const
Ptr< T > GetObject() const
Get a pointer to the requested aggregated Object.
Hold objects of type Ptr<T>.
Models the propagation loss through a transmission medium.
Smart pointer class similar to boost::intrusive_ptr.
void SetStream(int64_t stream)
Specifies the stream number for the RngStream.
Implements the pathloss model defined in 3GPP TR 38.901, Table 7.4.1-1 for the Indoor Office scenario...
static TypeId GetTypeId()
Get the type ID.
double GetShadowingCorrelationDistance(ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading correlation distance.
double GetShadowingStd(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading standard deviation.
double GetO2iDistance2dIn() const override
Returns the minimum of the two independently generated distances according to the uniform distributio...
~ThreeGppIndoorOfficePropagationLossModel() override
Destructor.
double GetLossNlos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is obstructed.
ThreeGppIndoorOfficePropagationLossModel()
Constructor.
double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is not obstructed.
Base class for the 3GPP propagation models.
Ptr< ChannelConditionModel > GetChannelConditionModel() const
Returns the associated channel condition model.
virtual double GetO2iLowPenetrationLoss(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const
Retrieves the o2i building penetration loss value by looking at m_o2iLossMap.
double GetLoss(Ptr< ChannelCondition > cond, double distance2D, double distance3D, double hUt, double hBs) const
Computes the pathloss between a and b.
Ptr< UniformRandomVariable > m_randomO2iVar2
a uniform random variable for the calculation of the indoor loss, see TR38.901 Table 7....
double GetFrequency() const
Return the current central frequency.
Ptr< UniformRandomVariable > m_randomO2iVar1
a uniform random variable for the calculation of the indoor loss, see TR38.901 Table 7....
virtual double GetLossNlos(double distance2D, double distance3D, double hUt, double hBs) const =0
Computes the pathloss between a and b considering that the line of sight is obstructed.
double GetShadowing(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const
Retrieves the shadowing value by looking at m_shadowingMap.
static double Calculate2dDistance(Vector a, Vector b)
Computes the 2D distance between two 3D vectors.
void SetChannelConditionModel(Ptr< ChannelConditionModel > model)
Set the channel condition model used to determine the channel state (e.g., the LOS/NLOS condition)
std::unordered_map< uint32_t, ShadowingMapItem > m_shadowingMap
map to store the shadowing values
virtual double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const =0
Computes the pathloss between a and b considering that the line of sight is not obstructed.
int64_t DoAssignStreams(int64_t stream) override
Assign a fixed random variable stream number to the random variables used by this model.
virtual double GetShadowingCorrelationDistance(ChannelCondition::LosConditionValue cond) const =0
Returns the shadow fading correlation distance.
ThreeGppPropagationLossModel()
Constructor.
Ptr< NormalRandomVariable > m_normRandomVariable
normal random variable
static TypeId GetTypeId()
Get the type ID.
Ptr< ChannelConditionModel > m_channelConditionModel
pointer to the channel condition model
~ThreeGppPropagationLossModel() override
Destructor.
std::unordered_map< uint32_t, O2iLossMapItem > m_o2iLossMap
map to store the o2i Loss values
virtual double GetO2iDistance2dIn() const =0
Returns the minimum of the two independently generated distances according to the uniform distributio...
virtual double GetO2iHighPenetrationLoss(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const
Retrieves the o2i building penetration loss value by looking at m_o2iLossMap.
void SetFrequency(double f)
Set the central frequency of the model.
void DoDispose() override
Destructor implementation.
static uint32_t GetKey(Ptr< MobilityModel > a, Ptr< MobilityModel > b)
Returns an unique key for the channel between a and b.
Ptr< NormalRandomVariable > m_normalO2iLowLossVar
a normal random variable for the calculation of 02i low loss, see TR38.901 Table 7....
double m_frequency
operating frequency in Hz
bool m_enforceRanges
strictly enforce TR 38.901 parameter ranges
virtual double GetShadowingStd(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const =0
Returns the shadow fading standard deviation.
virtual double GetLossNlosv(double distance2D, double distance3D, double hUt, double hBs) const
Computes the pathloss between a and b considering that the line of sight is obstructed by a vehicle.
Ptr< NormalRandomVariable > m_normalO2iHighLossVar
a normal random variable for the calculation of 02i high loss, see TR38.901 Table 7....
virtual std::pair< double, double > GetUtAndBsHeights(double za, double zb) const
Determines hUT and hBS.
double DoCalcRxPower(double txPowerDbm, Ptr< MobilityModel > a, Ptr< MobilityModel > b) const override
Computes the received power by applying the pathloss model described in 3GPP TR 38....
bool m_shadowingEnabled
enable/disable shadowing
static Vector GetVectorDifference(Ptr< MobilityModel > a, Ptr< MobilityModel > b)
Get the difference between the node position.
bool m_buildingPenLossesEnabled
enable/disable building penetration losses
Implements the pathloss model defined in 3GPP TR 38.901, Table 7.4.1-1 for the RMa scenario.
double GetShadowingStd(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading standard deviation.
static double Pl1(double frequency, double distance3D, double h, double w)
Computes the PL1 formula for the RMa scenario.
double GetO2iDistance2dIn() const override
Returns the minimum of the two independently generated distances according to the uniform distributio...
ThreeGppRmaPropagationLossModel()
Constructor.
double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is not obstructed.
double GetLossNlos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is obstructed.
~ThreeGppRmaPropagationLossModel() override
Destructor.
double GetShadowingCorrelationDistance(ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading correlation distance.
double m_h
average building height in meters
static TypeId GetTypeId()
Get the type ID.
static double GetBpDistance(double frequency, double hA, double hB)
Computes the breakpoint distance for the RMa scenario.
double m_w
average street width in meters
Implements the pathloss model defined in 3GPP TR 38.901, Table 7.4.1-1 for the UMa scenario.
static TypeId GetTypeId()
Get the type ID.
double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is not obstructed.
double GetBpDistance(double hUt, double hBs, double distance2D) const
Computes the breakpoint distance.
~ThreeGppUmaPropagationLossModel() override
Destructor.
ThreeGppUmaPropagationLossModel()
Constructor.
int64_t DoAssignStreams(int64_t stream) override
Assign a fixed random variable stream number to the random variables used by this model.
double GetLossNlos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is obstructed.
double GetO2iDistance2dIn() const override
Returns the minimum of the two independently generated distances according to the uniform distributio...
Ptr< UniformRandomVariable > m_uniformVar
a uniform random variable used for the computation of the breakpoint distance
double GetShadowingStd(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading standard deviation.
double GetShadowingCorrelationDistance(ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading correlation distance.
Implements the pathloss model defined in 3GPP TR 38.901, Table 7.4.1-1 for the UMi-Street Canyon scen...
std::pair< double, double > GetUtAndBsHeights(double za, double zb) const override
Determines hUT and hBS.
~ThreeGppUmiStreetCanyonPropagationLossModel() override
Destructor.
double GetLossNlos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is obstructed.
double GetShadowingStd(Ptr< MobilityModel > a, Ptr< MobilityModel > b, ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading standard deviation.
double GetBpDistance(double hUt, double hBs, double distance2D) const
Computes the breakpoint distance.
double GetO2iDistance2dIn() const override
Returns the minimum of the two independently generated distances according to the uniform distributio...
ThreeGppUmiStreetCanyonPropagationLossModel()
Constructor.
double GetLossLos(double distance2D, double distance3D, double hUt, double hBs) const override
Computes the pathloss between a and b considering that the line of sight is not obstructed.
static TypeId GetTypeId()
Get the type ID.
double GetShadowingCorrelationDistance(ChannelCondition::LosConditionValue cond) const override
Returns the shadow fading correlation distance.
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
Set the parent TypeId.
double GetLength() const
Compute the length (magnitude) of the vector.
#define NS_ASSERT_MSG(condition, message)
At runtime, in debugging builds, if this condition is not true, the program prints the message to out...
Ptr< const AttributeAccessor > MakeBooleanAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method.
Ptr< const AttributeChecker > MakeBooleanChecker()
Ptr< const AttributeAccessor > MakeDoubleAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method.
Ptr< const AttributeAccessor > MakePointerAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method.
#define NS_ABORT_MSG_UNLESS(cond, msg)
Abnormal program termination if a condition is false, with a message.
#define NS_FATAL_ERROR(msg)
Report a fatal error with a message and terminate.
#define NS_ABORT_MSG(msg)
Unconditional abnormal program termination with a message.
#define NS_ABORT_MSG_IF(cond, msg)
Abnormal program termination if a condition is true, with a message.
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
#define NS_LOG_DEBUG(msg)
Use NS_LOG to output a message of level LOG_DEBUG.
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by ",...
#define NS_LOG_WARN(msg)
Use NS_LOG to output a message of level LOG_WARN.
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
static const double M_C
propagation velocity in free space
double CalculateDistance(const Vector3D &a, const Vector3D &b)
Define a struct for the m_o2iLossMap entries.
Define a struct for the m_shadowingMap entries.