Skip to content

Commit

Permalink
pathloss: fix#956 - Rayleigh pathloss computation was incorrect
Browse files Browse the repository at this point in the history
  • Loading branch information
rhornig committed Mar 11, 2024
1 parent 548f60f commit dca3dd3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ double RayleighFading::computePathLoss(mps propagationSpeed, Hz frequency, m dis
double freeSpacePathLoss = computeFreeSpacePathLoss(waveLength, distance, alpha, systemLoss);
double x = normal(0, 1);
double y = normal(0, 1);
return freeSpacePathLoss * 0.5 * (x * x + y * y);
return freeSpacePathLoss * sqrt(x * x + y * y);
}

} // namespace physicallayer
Expand Down

0 comments on commit dca3dd3

Please sign in to comment.