Update for calculation of speed paramented needed by JakesFadingLossModel new version

This commit is contained in:
Marco Miozzo
2011-09-07 12:36:56 +02:00
parent 1025df4c60
commit 2fb7094e1a

View File

@@ -83,6 +83,11 @@ LtePropagationLossModel::DoCalcRxPowerSpectralDensity (Ptr<const SpectrumValue>
Ptr<SpectrumValue> rxPsd = Copy<SpectrumValue> (txPsd);
Values::iterator vit = rxPsd->ValuesBegin ();
Vector aSpeedVector = a->GetVelocity ();
Vector bSpeedVector = b->GetVelocity ();
double speed = sqrt (pow (aSpeedVector.x-bSpeedVector.x,2) + pow (aSpeedVector.y-bSpeedVector.y,2));
NS_LOG_FUNCTION (this << *rxPsd);
@@ -92,7 +97,7 @@ LtePropagationLossModel::DoCalcRxPowerSpectralDensity (Ptr<const SpectrumValue>
NS_ASSERT (subChannel < 100);
if (*vit != 0.)
{
multipath = c->GetJakesFadingLossModel ()->GetValue (subChannel);
multipath = c->GetJakesFadingLossModel ()->GetValue (subChannel, speed);
// computei PROPRAGATION LOSS:
double loss = multipath - pathLoss - shadowind - penetration; // in dB