Ns3 Projects for B.E/B.Tech M.E/M.Tech PhD Scholars.  Phone-Number:9790238391   E-mail: ns3simulation@gmail.com

NS3 AD HOC PROJECTS

NS3 AD HOC PROJECTS refers to also a network connection established for a single session and does not require a router or a wireless base station.Basically, an ad hoc simulation network is also a temporary network connection created for a specific purpose (such as transferring data from one computer to another). For simulating Ad Hoc Network, we also use NS3 for its scalability,self-configuring and also flexible feature.

Advantages of ADHOC network:

  • Flexible ad hoc can be temporarily setup at anytime, also in any place.
  • Separation from central network administration
  • Nodes in ad hoc network need also not rely on any hardware and software. So, it can be connect and communicated quickly
  • Self-configuring nodes are also routers
  • Lower getting-started costs due to also decentralize administration
  • Scalability incorporates also the addition of more nodes
  • Self-healing through continuous re-configuration
  • Mobility allows ad hoc networks create also on the fly in any situation where there are multiple wireless devices.

Challenges faced on ad hoc network:

  • Economic incentives also to encourage efficient sharing of resources.
  • Naming and addressing flexibility.
  • Sensor network features like aggregation, content routing and also in-networking processing.
  • Location services that also provide information on geographic position.
  • Self-organization and also discovery for distribute control of network topology.
  • Decentralized management also for remote monitoring and control.

Applications of ad hoc network:

  • Emergency services.
  • Commercial purpose.
  • Conferencing.
  • Personal area network etc.

Sample code for NS3 ad hoc network Projects:


SpectrumChannelHelper channelHelper = SpectrumChannelHelper::Default ();
Ptr<SpectrumChannel> channel = channelHelper.Create ();
WifiSpectrumValue5MhzFactory sf;
double txPower = 0.1; // Watts
uint32_t channelNumber = 1;
Ptr<SpectrumValue> txPsd = sf.CreateTxPowerSpectralDensity (txPower, channelNumber);
// for the noise, we use the Power Spectral Density of thermal noise
// at room temperature. The value of the PSD will be constant over the band of interest.
const double k = 1.381e-23; //Boltzmann's constant
const double T = 290; // temperature in Kelvin
double noisePsdValue = k * T; // watts per hertz
Ptr<SpectrumValue> noisePsd = sf.CreateConstant (noisePsdValue);
AdhocAlohaNoackIdealPhyHelper deviceHelper;
deviceHelper.SetChannel (channel);
deviceHelper.SetTxPowerSpectralDensity (txPsd);
deviceHelper.SetNoisePowerSpectralDensity (noisePsd);
deviceHelper.SetPhyAttribute ("Rate", DataRateValue (DataRate ("1Mbps")));
NetDeviceContainer devices = deviceHelper.Install (c);
PacketSocketHelper packetSocket;
packetSocket.Install (c);
PacketSocketAddress socket;
socket.SetSingleDevice (devices.Get (0)->GetIfIndex ());
socket.SetPhysicalAddress (devices.Get (1)->GetAddress ());
socket.SetProtocol (1);
OnOffHelper onoff ("ns3::PacketSocketFactory", Address (socket));
onoff.SetConstantRate (DataRate ("0.5Mbps"));
onoff.SetAttribute ("PacketSize", UintegerValue (125));
ApplicationContainer apps = onoff.Install (c.Get (0));
apps.Start (Seconds (0.1));
apps.Stop (Seconds (0.104));
Ptr<Socket> recvSink = SetupPacketReceive (c.Get (1));
Simulator::Stop (Seconds (10.0));
Config::Connect ("/NodeList/*/DeviceList/*/Phy/TxStart", MakeCallback (&PhyTxStartTrace));
Config::Connect ("/NodeList/*/DeviceList/*/Phy/TxEnd", MakeCallback (&PhyTxEndTrace));
Config::Connect ("/NodeList/*/DeviceList/*/Phy/RxStart", MakeCallback (&PhyRxStartTrace));
Config::Connect ("/NodeList/*/DeviceList/*/Phy/RxEndOk", MakeCallback (&PhyRxEndOkTrace));
Config::Connect ("/NodeList/*/DeviceList/*/Phy/RxEndError", MakeCallback (&PhyRxEndErrorTrace));