In my final year project, I have to vary the transmission range value in order to study the protocol behaviour using simulation with NS-2.
This can be done using a separate C program that is provided at ~ns/indep-utils/propagation/threshold.cc to compute the receiving threshold. It can be used for all the propagation models as discussed in ns-manual 18.4.
In some applications, a user may want to specify the communication range of wireless nodes. This can be done by set an appropriate value of the receiving threshold in the network interface,
- Phy/WirelessPhy set RXThresh_ \
Compile threshold.cc using this command:
- g++ threshold.cc -o threshold
Assume you have compiled it and get the excutable named as threshold. You can use it to compute the threshold as follows:
- threshold -m \ [other-options] distance
- where propagation-model is either FreeSpace, TwoRayGround or Shadowing, and the distance is the communication range in meter.
- [other-options] are used to specify parameters other than their default values. For the shadowing model there is a necessary parameter, -r receive-rate, which specifies the rate of correct reception at thedistance.
- Because the communication range in the shadowing model is not an ideal circle, an inverse Q-function [29] is used to calculate the receiving threshold. For example, if you want 95% of packets can be correctly received at the distance of 50m, you can compute the threshold by
- threshold -m Shadowing -r 0.95 50
- Other available values of [other-options] are shown below
- -pl \ -std \ -Pt \ -fr \ -Gt \ -Gr \ -L \ -ht \ -hr \ -d0 \
Include new value in TCL file, example:
1:59 AM
Posted by
noor mohammed
Labels:
gnuplot
gnuplot -background white
options :
gnuplot*background: white
gnuplot*textColor: black
gnuplot*borderColor: black
gnuplot*axisColor: black
gnuplot*line1Color: red
gnuplot*line2Color: green
gnuplot*line3Color: blue
gnuplot*line4Color: magenta
gnuplot*line5Color: cyan
gnuplot*line6Color: sienna
gnuplot*line7Color: orange
gnuplot*line8Color: coral
1:58 AM
Posted by
noor mohammed
Labels:
gnuplot
,
ns2
Question: I wanted to know the procedure to get Xgraph or Gnuplot from trace file.
Answer (by Mubashir Husain Rehmani, Paris, France):
As far as gnuplot is concerned, its very easy and there is no need of any
language to learn it. what you have to do is:
1. Install gnuplot in your linux (ubuntu) distribution.
2. Once you are in the directory of gnuplot, just write gnuplot at the command prompt
3. Then once you are in gnuplot command prompt then write load "Graph.p"
4. and see the graph.
====================
Code for file Graph.p
====================
set title "Relationship between Two functions"
set xlabel "First function"
set ylabel "Second function"
set xrange [0.0:100]
set yrange [0.00:10]
set grid
set boxwidth 15
plot "Graph.tr" using 1:2 with lines lt 1 lw 2 title ''; replot
set term post eps enhan color
set out "Graph.eps"; replot
=====================
Data present in Graph.tr
=====================
0 0
10 3.16
20 4.47
30 5.48
40 6.32
50 7.07
60 7.75
70 8.37
80 8.94
90 9.49
100 10
Source
1:49 AM
Posted by
noor mohammed
Labels:
lyx
If you need to include "Table of Contents" to be listed in the Table of Contents section, use the following the in the preamble.
use tocbibind package
\usepackage {tocbibind}
Log in as root and type in terminal:
- yum install gcc -y
- yum install kernel sources -y
- yum install kernel-devel -y
Restart the system.
Mount the VboxGuestAdditions.iso.
Move to the following directory:
- cd /media/VBOXADDTIONS_2.2.4_47978
As root execute:
- sh ./VBoxLinuxAddtions-x86.run
Restart the system. Done.
as being mentioned
here.