A log distance path loss propagation model with three distance fields. This model is the same as ns3::LogDistancePropagationLossModel except that it has three distance fields: near, middle and far with different exponents. More...
#include <propagation-loss-model.h>
Public Member Functions | |
ThreeLogDistancePropagationLossModel () | |
Static Public Member Functions | |
static TypeId | GetTypeId (void) |
This method returns the TypeId associated to ns3::ThreeLogDistancePropagationLossModel. | |
Private Member Functions | |
ThreeLogDistancePropagationLossModel (const ThreeLogDistancePropagationLossModel &o) | |
ThreeLogDistancePropagationLossModel & | operator= (const ThreeLogDistancePropagationLossModel &o) |
virtual double | DoCalcRxPower (double txPowerDbm, Ptr< MobilityModel > a, Ptr< MobilityModel > b) const |
Private Attributes | |
double | m_distance0 |
double | m_distance1 |
double | m_distance2 |
double | m_exponent0 |
double | m_exponent1 |
double | m_exponent2 |
double | m_referenceLoss |
A log distance path loss propagation model with three distance fields. This model is the same as ns3::LogDistancePropagationLossModel except that it has three distance fields: near, middle and far with different exponents.
Within each field the reception power is calculated using the log-distance propagation equation:
Each field begins where the previous ends and all together form a continuous function.
There are three valid distance fields: near, middle, far. Actually four: the first from 0 to the reference distance is invalid and returns txPowerDbm.
Complete formula for the path loss in dB:
where:
When the path loss is requested at a distance smaller than the reference distance , the tx power (with no path loss) is returned. The reference distance defaults to 1m and reference loss defaults to ns3::FriisPropagationLossModel with 5.15 GHz and is thus
= 46.67 dB.
Definition at line 272 of file propagation-loss-model.h.
ns3::ThreeLogDistancePropagationLossModel::ThreeLogDistancePropagationLossModel | ( | ) |
Definition at line 367 of file propagation-loss-model.cc.
ns3::ThreeLogDistancePropagationLossModel::ThreeLogDistancePropagationLossModel | ( | const ThreeLogDistancePropagationLossModel & | o | ) | [private] |
double ns3::ThreeLogDistancePropagationLossModel::DoCalcRxPower | ( | double | txPowerDbm, | |
Ptr< MobilityModel > | a, | |||
Ptr< MobilityModel > | b | |||
) | const [private, virtual] |
Implements ns3::PropagationLossModel.
Definition at line 372 of file propagation-loss-model.cc.
References m_distance0, m_distance1, m_distance2, m_exponent0, m_exponent1, m_exponent2, m_referenceLoss, NS_ASSERT, and NS_LOG_DEBUG.
TypeId ns3::ThreeLogDistancePropagationLossModel::GetTypeId | ( | void | ) | [static] |
This method returns the TypeId associated to ns3::ThreeLogDistancePropagationLossModel.
Attributes defined for this type:
No TraceSources defined for this type.
Reimplemented from ns3::PropagationLossModel.
Definition at line 322 of file propagation-loss-model.cc.
References ns3::TypeId::AddAttribute(), m_distance0, m_distance1, m_distance2, m_exponent0, m_exponent1, m_exponent2, m_referenceLoss, and ns3::TypeId::SetParent().
ThreeLogDistancePropagationLossModel& ns3::ThreeLogDistancePropagationLossModel::operator= | ( | const ThreeLogDistancePropagationLossModel & | o | ) | [private] |
double ns3::ThreeLogDistancePropagationLossModel::m_distance0 [private] |
Definition at line 288 of file propagation-loss-model.h.
Referenced by DoCalcRxPower(), and GetTypeId().
double ns3::ThreeLogDistancePropagationLossModel::m_distance1 [private] |
Definition at line 289 of file propagation-loss-model.h.
Referenced by DoCalcRxPower(), and GetTypeId().
double ns3::ThreeLogDistancePropagationLossModel::m_distance2 [private] |
Definition at line 290 of file propagation-loss-model.h.
Referenced by DoCalcRxPower(), and GetTypeId().
double ns3::ThreeLogDistancePropagationLossModel::m_exponent0 [private] |
Definition at line 292 of file propagation-loss-model.h.
Referenced by DoCalcRxPower(), and GetTypeId().
double ns3::ThreeLogDistancePropagationLossModel::m_exponent1 [private] |
Definition at line 293 of file propagation-loss-model.h.
Referenced by DoCalcRxPower(), and GetTypeId().
double ns3::ThreeLogDistancePropagationLossModel::m_exponent2 [private] |
Definition at line 294 of file propagation-loss-model.h.
Referenced by DoCalcRxPower(), and GetTypeId().
double ns3::ThreeLogDistancePropagationLossModel::m_referenceLoss [private] |
Definition at line 296 of file propagation-loss-model.h.
Referenced by DoCalcRxPower(), and GetTypeId().