博客首页 注册 建议与交流 排行榜 加入友情链接
推荐 投诉 搜索: 帮助
隐藏
yexin218.cublog.cn
simulate 802.11b channel within NS2 解析(2)
1 计算SNR

1>  SNR的定义:signal to  noise and  interference  ratio.
     『又是一个关于ratio的英语表示法 。所以什么什么之比,可以说成  A  is the ratio of  B  to  C.这通常用于B和C都比较长的情况下。
     如果B和C比较的短,那么可以直接说  A means B to C Ratio.这里的B to C好像是一个noun group 用于修饰后面的radio。

    所以SNR是signal strength除以 (noise and interference)。要计算SNR,就要知道signal strength, noise, interference这三样。signal strength很容易,可以根据propagation model 公式计算出来。所以,问题集中在如何计算noise和interference.

2> noise的来源有2:1来自于环境
                   2产生于receiver。
    其中由receiver产生的noise也分为2种:1 thermal noise
                                        2 platform noise

    thermal noise之前讲过,热噪声,可以理解为机器发热产生的。如果data rate加快,显然机器的处理速度会变快,自然也会发热发的多,自然thermal noise会变大。所以thermal noise除了和机器本身有关以外,还和data rate有关系

   不同的产品有不同的receiver sensitivity 因为他们的platform noise是不同的。即使同一个产品的receiver sensitivity也不是固定的,因为不同的data rate造成不同的thermal noise。因此不同的data rate有不同的receiver sensitivity。(概括起来一句话:不同的产品有不同的receiver sensitivity,同一产品在不同的data rate时的receiver sensitivity也不相同

3> BER和SNR之间的关系

作者给的那幅图死活看不懂,也找不到platform noise的定义。不过据我的猜测,所谓的platform noise可能是一个noise的基本值。那幅图下面有句话说明了BER和SNR之间的关系:
Receiver sensitivity is the received signal power with which BER is less than 10e-5.To achieve this BER, SNR should be approximately 10.

就是说,要保BER小于这个10e-5,Signal/noise ratio要大致是10。 信号强度10倍于噪声才可以保证错误率在一个比较低的,可接受的值。所以SNR越高,BER越低,反比的关系

4> 什么是noise floor?(天啊,我把《信号与系统》自学了一遍!)
  The noise level below which signals cannot be detected under the same measurement conditions.
  A common way to lower the noise floor in electronics systems is to cool the system to reduce thermal noise, which is usually the major noise source. In special circumstances, the noise floor can also be artificially lowered with digital signal processing techniques.

5> 考虑了noise之后的CSThresh_和RxThresh_的计算
   CSThresh_应该和noise floor相同。(在PHY中计算)因为802.11b用BPSK传输一个frame的preamble,因此CSTresh_的计算应该计算BPSK的receiver sensitivity。
   RxThresh_应该小于receiver sensitivity 大于CSThresh_.从范围和传输模型计算。
   SNR在MAC层计算。(因为MAC层知道是否干扰)

6>当SNR和modulation method知道以后,BER可以理论上推出来(derived theoretically,怀疑是用公式)也可以从curve上看出来(curve是测量特别的产品的产物)。
 
7> 让我崩溃的一段话!天啊,理论把实际简化了多少!!!!
Because Preamble, PLCP header, data of one 802.11b frame may be transmitted with different modulation scheme and different modulation schemes have different receiver noise floor, we should calculated their SNR, BER separately. After that, we can calculate FER of that frame and determine whether the frame is received correctly. One module ErrorModel80211 is added into NS2 to calculate SNR and FER.

8> 加入BER SNR之后的ns2如何处理接受的过程。

 NS2 will use threshold and BER to determine whether one frame is received correctly. CSThresh_, RxThresh_, and CPThresh_ are still here. RxThresh_ may be calculated with large range in order to let frames suffer high BER.

receive procedure

PHY module:

如果信号力小于CSThresh_,这个frame会直接丢掉
如果信号力小于RxThresh_,frame 标记为corrupted,送给MAC
如果信号力>RxThresh_, 直接将这个frame送给MAC

MAC module:

如果在接受一个frame的时候有其他的frame来到,则将其他frames的signal加为noise.
计算SNR和BER
根据frame的长度计算FER
用随机数来判断是否这个frame被corrupt,如果是的话,将其标记为corrupted.然后丢掉。

9> 最后我终于明白N多网页里出现的4个 noise是什么意思

   ErrorModel80211 noise1_ -104 //Receiver noise floors for BPSK
   ErrorModel80211 noise2_ -101 //...for QPSK
   ErrorModel80211 noise55_ -97 //...for CCK5.5
   ErrorModel80211 noise11_ -92 //...for CCK11

______________________________________

天啊,是什么样的力量支持着我把这篇文章给读下来的??Rob,你夸我夸的真是时候,自从你夸完我后,我发现自己勤奋多了。

读后感:

作者似乎要让ns2十分精确的模拟MAC和PHY对信号的接受,cs问题,并且那个一个真实的网卡的参数作为对照。

他先列出ns2原先的3个threshold的计算方法,然后说出这些方法的问题。最后说如何将SNR和BER加入ns2。具体的coding没有,完全是他的设计思路。

我的收获:对propagation model已经noise 和interference的理解加深了。知道了我该如何选择propagation model在我的simulation里。是否要加入其他的noise,衰减之类。如果得到的模拟结果和我想的不一样,不要总是怀疑自己的coding 有问题,还有可能就是我的模拟太偏离现实,应该考虑的很多因素都没有考虑进去。这篇文章我还有很多不是很理解的地方,尤其是后来开始加入SNR和BER的部分。所以要反复阅读。

 原文地址 http://blog.sina.com.cn/s/blog_4df2b29b01000d2j.html
 TAG NS2
发表于: 2008-07-09,修改于: 2008-07-09 12:17,已浏览190次,有评论0条 推荐 投诉

给我留言
版权所有 ChinaUnix.net 页面生成时间:4.99193