Script vanet-routing-compare

601 views
Skip to first unread message

Guilherme Santos

unread,
Sep 30, 2016, 1:58:50 PM9/30/16
to ns-3-users
Hello,

I'm new to the NS-3 and I'am studying VANET's networks.
So I started doing some testing with Vanet-routing-compare script, but I'm getting confused with the results. I think there may be an error in the script.

I did not make any changes to the script for my test, only I changed some parameters through the command line.

I ran these two command lines:

Protocol: AODV, Loss Model: Two-Ray Ground

./waf --run "vanet-routing compare --totaltime=10 --nodes=40 --sinks=40 --txp=20 --traceMobility=0  --protocol=2 --lossModel=3 --fading=0 --mobility=2 --speed=20 --pause=0 --scenario=1 --CSVfileName AODV-TwoRay.csv "

Protocol: AODV, Loss Model: FreeSpace

./waf --run "vanet-routing-compare --totaltime=10 --nodes=40 --sinks=10 --txp=20 --traceMobility=0 --protocol=2 --lossModel=1 --fading=0 --mobility=2 --speed=20 --pause=0 --scenario=1 --CSVfileName=AODV-FreeSpace.csv"

And when I went to check the output files (
attached), the results are the same. The change in loss model made no effect.
So I want to know if anyone has got the same results before, or it could be a bug.

Other question is about to change the trace mobility. I want to run using a ManhattanGrid mobility that I created in the BonnMotion, with the similar characterists of scenario 1.

Other question, it's about change the mobility. I want to run using a ManhattanGrid mobility that I created in the BonnMotion, with the similar features of the scenario 1. I took a look in the script ns2-mobility-trace and I followed the same processes: created the scenario, did the trace in ns2 and move to the file scratch where is my script.

But when I run the script vanet-routing-compare, giving the command lines to the new trace, the simulation performed the second scenario (the Unterstrass section of Zurich Switzerland) instead of scenario I created..

The command line that I put:

./waf --run "vanet-routing-compare --totaltime=10 --nodes=40 --sinks=10 --txp=20 --traceMobility=1 --protocol=2 --lossModel=3 --fading=0 --traceFile=scratch/cenario-ManhattanGrid.ns_movements --logFile=ns2-mobility-trace.log --mobility=1 --speed=20 --pause=0 --scenario=2 --CSVfileName=AODV-TwoRay-MH.csv "

I appreciate who can help me understand why this is happening.

Regards,
Guilherme dos Santos.
AODV-FreeSpace.csv
AODV-TwoRay.csv
Message has been deleted

Guilherme Santos

unread,
Oct 1, 2016, 10:09:59 AM10/1/16
to ns-3-users
I solved the problem with mobility. I just modified directly in the script the traceFiles logFile file.

But I found a new problem when I ran the script from the command line to simulate the loss model ItuR1411Los, I got this error:

assert failed. cond="a->GetPosition ().z > 0 && b->GetPosition ().z > 0", msg="nodes' height must be greater than 0", file=../src/propagation/model/itu-r-1411-los-propagation-loss-model.cc, line=68

For other loss models this running ok.

Tommaso Pecorella

unread,
Oct 1, 2016, 7:10:12 PM10/1/16
to ns-3-users
Hi,

the fist question (why the traces are the same) can not be answered. The line:
./waf --run "vanet-routing compare --totaltime=10 --nodes=40 --sinks=40 --txp=20 --traceMobility=0  --protocol=2 --lossModel=3 --fading=0 --mobility=2 --speed=20 --pause=0 --scenario=1 --CSVfileName AODV-TwoRay.csv "
is wrong (number of nodes can not be equal to the number of sinks) and there is a space in the last option.
If we don't know the exact command it's hard to tell where the problem is.

The second question too seems a problem of typos:
scratch/cenario-ManhattanGrid.ns_movements

It seems like you missed a "s": "cenario" instead of "scenario".

The third issue (in the next post) can be fixed by giving a Z component to your nodes. By default the movement files skip this an put all the nodes on the ground (and the propagation model complains).
This can be fixed manually by adding a line like:
$node_(0) set Z_ 1.25
in the movement file (one for each node, of course). This will place the node's antenna at 1.25 meters above the ground.

Cheers,

T.

Guilherme Santos

unread,
Oct 3, 2016, 2:47:59 PM10/3/16
to ns-3-users
Thank Tommaso your answer was very helpful.

Shuja Ansari

unread,
Mar 24, 2017, 1:20:39 PM3/24/17
to ns-3-users
Hi there,

I got a similar complain from the ITUR NLOS propagation model, however, I am using the WaypointMobilityModel, so is there any way I could change the z component with that?

I am using the mobility model with RoutesMobilityHelper and chooses routes based on longitudes and latitudes defined in the ChooseRoute function. I've tried changing the altitude but it doesn't help. 

Any help will be much appreciated. Many thanks.

Regards,
Shuja

Tommaso Pecorella

unread,
Mar 25, 2017, 10:10:20 PM3/25/17
to ns-3-users
Hi,

no idea, RoutesMobilityHelper is not part of ns-3 (not the part we maintain). As a consequence, we can't help - simply because we don't have the code.

T.
Reply all
Reply to author
Forward
0 new messages