Which Wifi model should I use?

175 views
Skip to first unread message

Mohammed Alenazi

unread,
Jan 4, 2015, 2:37:44 PM1/4/15
to ns-3-...@googlegroups.com
I have about 50 nodes in 1500m x 300. The nodes are communicting using ad-hoc wifi. The problem is that when the transmission range is set to 250m the packet delivery rate is lower than 100m. I suspect that there are some collisions. 

How can I fix this problem? or which wifi model has a better algorithm for collision avoidance?

This is a snippet of my code where I declare the wifi module.  

  NqosWifiMacHelper wifiMac = NqosWifiMacHelper::Default ();
  wifiMac.SetType ("ns3::AdhocWifiMac");
  YansWifiPhyHelper wifiPhy = YansWifiPhyHelper::Default ();
  YansWifiChannelHelper wifiChannel = YansWifiChannelHelper::Default ();

  wifiChannel.AddPropagationLoss ("ns3::RangePropagationLossModel", "MaxRange", DoubleValue (txpDistance));
  wifiPhy.SetChannel (wifiChannel.Create ());
  WifiHelper wifi = WifiHelper::Default ();
  wifi.SetRemoteStationManager ("ns3::ConstantRateWifiManager", "DataMode", StringValue ("OfdmRate6Mbps"), "RtsCtsThreshold", UintegerValue (0));
  devices = wifi.Install (wifiPhy, wifiMac, nodeContainer);


Thank you

Konstantinos

unread,
Jan 4, 2015, 3:14:29 PM1/4/15
to ns-3-...@googlegroups.com
Hi,

This is expected and as you mention it is mainly due to the collisions. Also, you should expect lower data rates (throughput) due to the increase of contention (more nodes within your range). Search the relevant literature for more information.

Have you enabled RTS/CTS mechanism? That should reduce the number of collisions.
See the example in /examples/wireless/wifi-hidden-terminal.cc for information on how to enable/control RTS/CTS.

Regards,
K.

Mohammed Alenazi

unread,
Jan 5, 2015, 12:50:08 PM1/5/15
to ns-3-...@googlegroups.com
I tried enabling the RTS/CTS mechanism but I still have the same problem.
I also tried 

wifi.SetRemoteStationManager ("ns3::IdealWifiManager");

but It did not help. Is there a way to disable collisions. I know it's not realistic but I just want to see how increasing the transmission range improves packet delivery rate for a routeing protocol.  

Thank you

Sebastien Deronne

unread,
Jan 5, 2015, 1:06:16 PM1/5/15
to ns-3-...@googlegroups.com
If you want some further help, please provide your simulation script(s) and mention the ns-3 version you are using.
Could you also indicate which are the obtained results?

I am also not surprised you have low throughput, since you are using 50 stations transmitting at low bitrate (6 Mbit/s). 
Despite RTS/CTS may help to reduce collision impacts (since collisions in RTS/CTS involve smaller frames), the RTS/CTS mechanism also consumes a part of the bandwidth.

You cannot disable collisions, since collisions are due to the fact you simulate 50 stations.
If you want to get rid of collisions, you can only have one transmitting station in your network instead of 50!

wifi.SetRemoteStationManager ("ns3::IdealWifiManager") => it will only have an impact on how the bitrate is adapted. Note that in your previous example, your bitrate was fixed, while here your bitrate is not constant and may change during simulation.

Mohammed Alenazi

unread,
Jan 6, 2015, 10:41:45 PM1/6/15
to ns-3-...@googlegroups.com
Actually, I am using a script to test the epidemic routing protocol. 
in the file 
src/epidemic/examples/epidemic-benchmark.cc

Sebastien Deronne

unread,
Jan 8, 2015, 7:40:51 AM1/8/15
to ns-3-...@googlegroups.com
If something goes wrong, it is maybe not linked to Wifi, how can I be sure it is not due to epidemic routing?

Please clarify what is going wrong for you, what are your results, what you already tested, and so on.

Mohammed Alenazi

unread,
Jan 13, 2015, 1:23:45 PM1/13/15
to ns-3-...@googlegroups.com
I changed the beaconing interval and that solved the problem. 
Thank you.
Reply all
Reply to author
Forward
0 new messages