伊落丹矩阵_Radio

Trinity, log me out!

自由空间路损在ns2中的应用

Free Space Path-loss as in ns2

<伊落丹> illidan.modeler [at] gmail.com
Northern Capital, Republic of Pandaren

Of the Net, by the Net, for the Net


Free space path-loss is a major factor when considering the attenuation of EM signal strength. Basically it's defined by the following equation:

Pt/Pr = (4*Pi*d*f/c)^2

Pt: transmitted power
Pr: received power
d: the distance between transmitter and receiver
f: the signal frequency
c: light speed


Recast the equation in dB form, we get

FSPL (dB) = -147.56 + 20*log10(d) + 20*log10(f)

Take the FSPL of a IEEE 802.11 WLAN signal for example. The relation between FSPL and distance is depicted below:

where the transmission power is about 10 mW, without considering antenna gain and other attenuation.

In ns2, path loss, which is an effect of the physical layer, is handled by class WirelessPhy (mac/wirelss-phy.{h,cc}). WirelessPhy calculates the path loss in its method sendUp(), by calling FreeSpace::Pr(PacketStamp *t, PacketStamp *r, WirelessPhy *ifp). FreeSpace and its parent Propagation are defined in mobile/propagation.{h, cc}.

The code snipit carrying out the call to FreeSpace's method is given below (wireless-phy.cc):
 if(propagation_) {
        s.stamp((MobileNode*)node(), ant_, 0, lambda_);
        Pr = propagation_->Pr(&p->txinfo_, &s, this);
        if (Pr < CSThresh_) {
            pkt_recvd = 0;
            goto DONE;
        }

The real meat of the path loss calculation is Propagation's method Friis(), which not only deals with free-space path loss but also considers antenna gains. (Note: By my obervation, antenna gain is actually 0 dB by default, revealed in Antenna::getTxGain().)

For a description of path loss and link budget analysis, turn to sub-section 5.2 of [Sklar 2001].

References
1. [Book] [Sklar 2001]

  

posted on 2009-04-06 20:01 伊落丹 阅读(380) 评论(0)  编辑  收藏 所属分类: Digital Communicationsns2


只有注册用户登录后才能发表评论。


网站导航:
 

公告

<伊落丹> illidan.modeler [at] gmail.com
Northern Capital, Republic of Pandaren


Of the Net, by the Net, for the Net

导航

<2009年4月>
2930311234
567891011
12131415161718
19202122232425
262728293012
3456789

统计

常用链接

留言簿(2)

随笔分类(19)

随笔档案(13)

搜索

积分与排名

最新随笔

最新评论

阅读排行榜

评论排行榜