This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.
The wireless environment, communications across the globe wireless technologies was used to help large number of end users. The progression of wireless network infrastructure applications, invention of wireless devices such as portable devices, cell phones were giving flexibleness in communication system. In wireless networks, the wireless sensor network was responsible for nodes transmit information through electromagnetic propagation over the air and this transmission range depends upon on power level and also depends upon the terrain obstacles and the specific scheme used for the transmitting information. Today's wireless communication systems designed to provide cost efficient wide area coverage to users with moderate bandwidth demands. And these wireless networks were integrated into various types such as wireless LAN (Local Area Network), PAN networks (Personal Area Network) and newly emerging wireless networks 3G and 4G. In 3G system, the maximum data speed supported is 2 Mbit/s including with multimedia services. Mobile Ad hoc networks were envisioned to become key components in the 4G architecture with ultra high transmission range up to 100 Mbps.
Mobile ad hoc networks dynamically organized by an autonomous system of mobile nodes that were connected through wireless networks links without using an existing network infrastructure or centralized administration. The nodes arbitrarily organize among themselves and free to move randomly. Ad hoc networking initiates independent wireless node, each limited transmission and processing power, to chained together to enable wider networking coverage and processing capabilities. Mobility of ad hoc networks, provide to nodes to move free while communicating with other nodes. The topology of the ad hoc networks network is dynamic in nature due to constant movement of participating of the nodes causing the intercommunication flow among nodes to change continuously. The characteristic of MANET multi-hop routing, information was shared among the nodes by using desired routing protocol of MANET. A good routing protocol should minimize the computing load host as the network traffic .
1.1 Aim and Objectives:-
The main aim of the project to optimise the performance of TCP traffic against VBR traffic with DSR routing protocol of MANET with fixed parameters 100 nodes and 1000* 1000 topology area using NS-2 Simulator.
Optimisation of TCP and VBR by using DSR routing protocol in terms of mobility and traffic by Ad-hoc Mobile Networks
Obtain the throughput of receiving bits, end to end delay, packet delivery ratio, normalized routing load and routing over head the network with maximum utilisation of bandwidth.
Maintaining the quality of service (QoS) of network connections
1.1.1 Deliverables of the Project:-
New mechanism should be proposed to estimate the resources on mobile network.
Designing of Ad-hoc mobile networks for fast reliable and self organizing wireless nodes.
The obtained estimation will be compared transport layer protocols of TCP and VBR with mobility, traffic, throughput, end to end delay and pause time etc.
The performance properties are derived to provide guidelines for network design by gate way of DSR routing protocol.
1.2 Description of the Project
The areas in which there were no communication infrastructure or inconvenient to use, there wireless user might able to communicate through the formation of Ad hoc networks Mobile networks were categorized as self organized networks and it need not required central base station or a fixed network infrastructure. Every node in MANET was act as a host and router. And each node was in Ad hoc networks allow routing protocol to discover multi-hop paths through the network to other nodes. Many research's had done on the performance of the MANET protocols and various traffics. This Project was done to optimise the performance of the Transmission Control Protocol (TCP) against the Variable Bit Rate (VBR) using Dynamic Source Routing (DSR) protocol. Simulations were carried out on MANET for minimisation of end-to-end delay, optimisation of routing over head, and throughput of the network. Quantitative analysis was done by the physical layer including radio propagation model and with the Medium Access Control layer (MAC).
A simulation environment was evaluated by the Network Simulator for optimisation of TCP and VBR using DSR routing protocol of MANET. Based on the simulation results, the graphs were plotted for various scenarios for analysis of desired end to end delay, throughput and routing over head.
1.3 Project Justification
Now a day's wireless communications have become very pervasive. As the increasing number of mobile phones and wireless internet users had increased significantly in recent years. In first generation of wireless networks were targeted mainly on voice and data communications at slow data rate. But in second and third generation of wireless networks were based on broadband. And there were mainly concentrating on mobility and multimedia traffic with quality of service (QoS). The next generation wireless network came with better utilisation of bandwidth. With the efficient use of bandwidth, reduces the power consumption mobile devices and fewer errors. The bidirectional and unidirectional bandwidth constrained, variable capacity links wireless links have lower capacity compared to wired ones. Due to the typical behaviours of the actual throughput of wireless communications, moderate link capacities were low. So there must be approach or exceed network capacity frequently.
In MANET main advantage was efficient utilisation routing technique. The high mobility was occurred due to topology changes in MANET leads to unpredictable link breaks and these changes had direct on overall performance of the network. In order to improve link capacities of all the nodes in a MANET may rely on batteries or other exhaustible energy. This could be the most important design criteria for optimization for energy conversation. As it utilize routing algorithms to avoid intensive computations. Performance of the DSR was evaluated by using traffic TCP and VBR to analyse the average end to end delay, throughput with the efficient use of bandwidth.
1.3.1 Contribution of project
MANET provides environment better utilisation of wireless networks with the efficient bandwidth for mobile nodes to transmit the information over the overall network. DSR routing protocol was used in this project to analyze various traffic like TCP and VBR. These traffics were operated using DSR routing protocol. MANET provides high mobility in terms of node density. Network Simulator was used for simulation environment to derive the desired output.
1.4 Mobile Ad Hoc Networks
Wireless ad hoc networks collection of Mobile Nodes. Mobile Ad hoc networks were self configuring network of mobile nodes connected to each other the wireless links. Wirelesses MANET were established by devices through physical medium without resort for a pre-existing network infrastructure. The mobile nodes move freely without need of backbone network. The mobile nodes provide robust communication in hostile environments such as these were used in military communication or disaster recovery situations when infrastructure was down. As shown in Figure we can observe the formation of mobile nodes without any network infrastructure. A peer to peer network infrastructure of MANET allow direct communication between two nodes, when adequate radio propagation circumstances were enable between two nodes. Suppose if there was no direction connection then multi-hop routing was established between source and destination nodes.
Figure 1: Mobile Ad Hoc Network without Infrastructure (18)
1.4.1 Uses of MANET
For fast establishment of military communication during the deployment of forces in unknown ad hostile terrain environment
In rescue missions while communications of areas where there was no adequate wireless coverage.
National security for communication in national crisis, where the existing communication infrastructure was non operational due to a natural disaster or a global war.
For fast establishment of communication infrastructure during the law enforcement operation .
1.4.2 Classification of routing protocols of MANET
Classification of protocols
Figure 2: Classification of Ad Hoc routing protocols (5)
As shown from the Figure 2 the Ad Hoc routing protocols were categorically divided into proactive, reactive and hybrid protocols. Proactive protocols responsible for exchanging of topological information among network nodes. Such as where there was a need for a route to a destination then that route information would be available immediately. On the other hand reactive protocols do not attempt to continuously maintain the update topology of the network information. Rather when need arises, a reactive protocol invoked the procedure to find the route to the destination. Finally third type of protocol was combination of proactive and reactive protocols. The hybrid protocol extracts behaviour of both proactive and reactive protocols. In contrast to the methods of other routing protocols, on-demand protocols were not concerned with identifying and maintaining routes that were not currently in use. In an effort to reduce routing overhead, these techniques had a reactive nature that would create no route before it's time. And discovering routes only when needed and result in higher packet latencies on average, many researchers believed that on-demand protocols inherently have lower overhead and higher throughput than proactive methods, and were hence superior .
1.4.3 Dynamic Source Routing Protocol (DSR)
Dynamic resource protocol was an on demand protocol designed to restrict the bandwidth consumed by control packets in ad hoc wireless networks by eliminating the periodic table update messages required in the table driven approach. In DSR each node kept a route cache that contains the full paths to known destinations. If a source did not have route to destination, then it broadcast a route request packet to its neighbours. If any node receiving the route request packet without route to the destination, then append its own ID to the packet and re broadcast the packet. If a node receiving the route packet had route to destination, the node replies to source with a concatenation of the path from the source to itself and path from itself to the destination. Basically DSR operations were handled by the two mechanisms were route discovery and route maintenance.
18.104.22.168 Route Discovery
When any node originated a new packet addressed to particular destination node, then the source node place in the header of the packet known as a 'source node' assigned the sequence of hops that the packet was to follow on its way to destination. In general, the sender would obtain a suitable previously assigned or if no route found in its cache, then it would initiate the route discovery protocol dynamically find a new route to this destination node. In process DSR, the source node called as 'initiator' and destination node called as 'target' of the route discovery mechanism. By the following Figure 3, the processing of route discovery operation performed.
"A", Id=2 "A, B", Id=2 "A, B, C", Id=2 "A, B, C, D", Id=2
Figure 3: Route Discovery process flow diagram [by author]
Nodes A transmit Route Request for initiation of Route Discovery to the node B. Each node had its own identification number as 2 and each node contains record of addresses of intermediate nodes. This route record initialized to an empty list by the initiator of the route discovery. When route request received by the B then it send back the Route reply to the initiator of route Discovery and kept one copy of the Route Request and sent it to initiator. If node initiate the Route request to the node C first it would check route information and send, if the route information was lost, then it create its route information send it to node C. This would continue up to node E and then node E must reply that the packet was received.
22.214.171.124 Route Maintenance
Originating or forwarding packet using source route, then each node should responsible for the packet confirming that packet had received. Every node must send the acknowledgement to Route Request node. From Figure 4: the process of maintenance route would be done by the following way.
Figure 4: Route maintenance flow diagram [by author]
If node A was responsible for link from A to B then it must also responsible for link to B to C, C to D and D was responsible for D to E. When packet was sending from node A to B, then it must send the acknowledgement. Route Reply was sent by B along with acknowledgement. For different protocols acknowledgment would be different .
Presently the methodology which was proposed project was to optimise the performance of the given traffic with suitable protocol. The total project was covered design implementation, inserting new traffic into network simulator, analysis of results, and discussion on results, future scope and conclusion of the project.
1.7 Project work plan
Work plan of the project was scheduled in Gantt chart of appendix C. This work plan had three phases.
Phase I: Literature review
In this phase, searching references, researching for previous projects, understanding of research projects and writing of report was mentioned.
Phase II: Progress report
In this phase network simulator setup, searching for the references, implementation of VBR and TCP traffic with DSR routing protocol, analysis of results and discussion of results was done and then submission of progress report.
Phase III: Thesis report
In this report all results of simulations and writing report with collected information.
1.7.1 Risk of the project and Resources of the project
Previous research of this project was very less compare to other CBR and TCP traffics. This project was optimising the TCP traffic against VBR traffic. There was no VBR type of traffic in the current network simulator. And lack of time and limited resources to carry out the work.
Network simulator was open source software. It can be downloaded from the internet without any cost. Network simulator was installed on Linux operating system environment.
1.8 Outline of thesis
Chapter 1: Introduction, the aims and objectives, project description, contribution of the project, mobile ad hoc networks, methodology, work plan, resources required, and project risk.
Chapter 2: Introduction and background of literature review. Communication of model of MANET, major challenges in MANET and finally routing issues.
Chapter 3: Simulation setup and Description, introduction of network simulator, node movement, traffic generation, trace analysis and finally insertion of VBR into NS2.
Chapter 4: Simulation and Results and Discussion on results.
Chapter 5: Conclusion and future work were given here.
This chapter one was covered by the Introduction of wireless technologies and review of the Mobile Ad Hoc networks. Then it covered by the project description, justification and aim of the project. And then next come, brief description of the MANET and routing protocols. Methodology of the project was explained.
2.0 Introduction of literature review
From the previous chapter, author mentioned that research was previously done regarding performance of the ad hoc routing protocols using various traffics. Now in this chapter, description of previously done research by the various researchers's and background of the performance of the routing protocols.
Performance of the ad hoc networks was sensitive in mobility, scalability and in traffic load. Actual examination was done on DSR routing protocol, the performance of protocol, amount of traffic and speed nodes varies and this needs to create a crucial role in efficient routing in various traffics. While analysis of protocol was done, the important aspect was to varying the network size, node speed and pause time to improve the performance of the given routing protocol. Many researchers done lots of experiments on various traffics, like file transfer protocol (FTP), constant bit rate (CBR), variable bit rate (VBR) and transmission control traffic(TCP), user datagram protocol (UDP) and they had distinct results based on the different network conditions indeed of traffic type network size parameters by various simulators. But this project was done using different parameters of network to improve the performance and optimisation of given DSR protocol using VBR and TCP traffic with Network Simulator.
2.1 Background of the literature view
Ad Hoc networks were multi-hop wireless networks that can operate without established backbone infrastructure. The mobile-stations that form the ad-hoc network perform the additional role of routers. Since each station in the network was potentially mobile, the topology of an ad-hoc network can be highly dynamic. Now these days, internet traffic was carried using the Transmission Control Protocol (TCP) and consequently there had been a significant amount of research toward modelling and understanding the impact that this protocol has on transmission times and network utilization. TCP continue to be an evolving protocol and as one important task of these models was to facilitate comparisons between the different variants of TCP. It was a well known that MANET being one of the most usable and reliable network for communication with distinct applications. However, the distributed nature of the network and their link stability posed critical challenges in the design of routing protocols for them. Finally, this also impose the necessary to investigate the performance of chosen MANET routing protocols over HTTP traffic as this plays a key role in MANET applications . The main idea of TCP was to investigate the network in order to determine the availability of resources and it injects packets at an increasing rate into the network until a packet lost was detected, thereby it infers the network was faced congestion problem .
The IEEE 802.11 multiple access protocol was primarily used as medium access control (MAC) layer, robust was gave performance in TCP. MAC layer impact on TCP was stated by some researchers that same as the transport layer, the MAC layer also relies on error control mechanisms in order to improve the transmission efficiency. While the former deals with end-to-end recovery the latter concentrates on link (one hop) recovery. Hence, unless a well defined synchronism between these both protocols is put in place, interference can arise deteriorating substantially the end-to-end throughput provided by TCP and the IEEE 802.11 "Distributed Foundation Wireless Medium Access Control" (DFWMAC) was the standard Medium Access Control (MAC) layer protocol, adopted for wireless mobile ad hoc networks. This MAC protocol, which defines both physical and link layer mechanisms, is intended for providing an efficient shared broadcast channel through which the involved mobile nodes can communicate. The main novelty of this protocol refers to the inclusion of acknowledgment for data frames of link layer's ACKs in addition to request-to-send/clear-to-send (RTS/CTS) control frames to make it possible link layer retransmissions, as well as a virtual carrier sense mechanism to detect when the medium was busy
Performance in ad-hoc networks with TCP being the primary transport protocol in use in the current Internet, had investigated the impact of ad-hoc network characteristics on TCP's performance, such as random wireless loss, packet loss, link failure and late acknowledgement. Mobility involves sending an explicit link failure notification (ELFN) to the source from the link failure point. The source, upon receiving the ELFN freezes TCP's timers and state, re configure a new route to the destination, and either releases the timers and state or re-starts them from their respective points by using DSR routing protocol  . The protocol was distributed highly adaptive and flexible. Multicast affiliation was receiver initiated. The messaging was localized to the neighbourhood of the receiving multicast member and thus the overhead consumed was low. The protocol enables spatial bandwidth reuse along a multicast mesh was a connected structure of multicast group members. The real-time connection was guaranteed quality of service (QoS) in terms of bandwidth. Rendering Qos was challenging area of future research in wireless ad hoc networks. The ability to provide QoS depends on the characteristics of all the network components form transmission links to the MAC and network layers. This type of networks, links had a relatively low, highly variable capacity and high loss rates. Likewise, mobility stimulates frequent link breakages. At last, link layer generally use unlicensed spectral band and making it harder to provide strong QoS guarantees. Qos aware MAC protocols figured out the problems of medium contention, support reliable unicast communications and provide resource reservation for real time traffics in a distributed wireless environment. For VBR traffic, the trade-off between reserved and random-access bandwidth for a specific packet loss rate is studied. The protocol is self healing in the sense that the mesh structure has the ability to repair itself when members either move or relays fail .
VBR video traffic was difficult to model because of the complexity of the video bandwidth trace as a framework and the problem of getting empirical data and for generation of the present trace required 6 weeks of CPU time of late 1990, which was arguably on the edge of practical computability. Video coding algorithms have been designed and tested using short video sequences of 5-20 seconds that represent difficult scenes. When processor speed improves, the use of long test sequences become standard practice for all video work . There were two types of applications of VBR; they were real time and non real time applications of traffics. Non real time applications, such as ftp and telnet, the packets received had to put in order by the upper layer protocols of ad hoc networks. And delay jitter did not affect the application adversely as the application could wait random amount of time for the data to be kept together. The variations in delay impact on the performance of the packets. The real time application such as audio and video had to faithfully recreate the original data stream at receive by playing back the data after fixed delay offset from the original departure time, when some packets arrived earlier then the delay at buffer was more. And delay jitter in such applications tends to unaccepted presentation quality 
The comparative evaluation within mobile ad-hoc networks' routing protocols from reactive, proactive and hybrid, analyzed the results of simulation for mobile ad hoc routing protocols for quality of services of end to end delay, media access delay, throughput and packet delivery ratio for optimized link state routing. The simulation results of proactive over reactive and hybrid protocols in routing traffic for dynamic changing topology, the proactive protocol, and optimized link state routing, a protocol for building link tables for ad-hoc networks, can transmit traffic more rapidly though involve less processing speed in packet forwarding .
2.2 The communication Environment and the MANET model
The following were assumptions about the communication parameters about the network infrastructure and the traffic in the MANET
Nodes in the MNAET modelled with portable communication devices with light weight batteries. Both transmitting and receiving medium battery life could impose restrict the transmission range and communication activity.
Direct connection between source and destination nodes was not transitive relation, because when a node can communicate directly with node B and B could communicate with node then there was a problem to node A to communicate with node C, this leads to hidden terminal problem while connecting.
Mobility management procedures and hierarchy of network routing could improve the network performance measurement of latency of locating a mobile.
Network nodes of MANET designed with equal capabilities and identical communication devices were capable of performing functions from the set of network services. However, all nodes need not perform same kind of operations in same time. Every node had different functions
2.2.1 Challenges in the design and operation of the MANET
The challenges in the design and operations of the MANET were stem from the lack of a centralized entity, the potential for rapid node movement and communications was carried over the wireless medium compared to traditional wireless networks. Number of centralized entities such as base stations, Mobile Switching Register Centres (MSGs), Home location register (HLR) and Visitor Location Register (VLR) in the cellular wireless networks but in MANET there were no pre-existing infrastructure and centralized did not exist. The cellular networks of centralized entities perform the coordination function while in Ad hoc networks lack of these entities and required distributed algorithms to perform these functions.
All communication between all networks entities of Ad hoc networks were carried over the wireless medium due to radio communication being vulnerable to propagation impairments but connectivity was not guaranteed between network nodes. The sporadic connectivity and intermittent might be quite common, as the wireless bandwidth was limited then the utilisation was minimized. Finally, when some of the mobile devices were expected maintain with limited power resources then the required transmission power should be minimized as well. Therefore it limits the transmission of each node and channels assigned to mobiles were typically reused. Consequently, since the transmission radius was much smaller than the network span, communication between two nodes often needs to be relayed through intermediate nodes when multi-hop routing was used. Frequent network reconfiguration might trigger frequent exchanges of control information to reflect the current state of the network. Indeed the short lifetime of this information means that a large portion of this information may never be used and the bandwidth utilised for distribution of the routing update information was wasted. In spite of these attributes, the design of the MANET s still needs to allow for a high degree of reliability, survivability, availability and manageability of the network. Based on the above discussion, we require the following features for the MANETs:
Robust routing and mobility management algorithms were used to increase the network's reliability and availability such as to reduce the chances that any network component is isolated from the rest of the network.
Adaptive algorithms and protocols to adjust to frequently changing radio propagation, network, and traffic conditions.
Low-overhead algorithms and protocols to preserve the radio communication resource.
Multiple (distinct) routes between a source and a destination - to reduce congestion in the vicinity of certain nodes, and to increase reliability and survivability.
Robust network architecture to avoid susceptibility to network failures, congestion around high-level nodes, and the penalty due to inefficient routing
2.3 Major challenges in routing protocols of MANET
Routing issues Providing Qos was challenging area of future research in wireless ad hoc networks. The ability to provide QoS depends on the characteristics of all the network components form transmission links to the MAC and network layers. This type of networks, links had a relatively low, highly variable capacity and high loss rates. Likewise, mobility stimulates frequent link breakages. At last, link layer generally use unlicensed spectral band and making it harder to provide strong QoS guarantees. QoS aware MAC protocols figured out the problems of medium contention, support reliable unicast communications and provide resource reservation for real time traffics in a distributed wireless environment .
Mobility: In ad hoc wireless networks, the topology was highly dynamic due to movement of the node
Bandwidth constraints: The capacity in wireless networks of radio band was limited and data rates were much lesser than the wired network. Because of this only routing protocol should use the bandwidth optimally to keep the overhead as low as possible.
Error-prone channel state: wireless links had time varying characteristics in terms of link capacity and link probability. But in ad hoc wireless networks routing protocol should interact with MAC layer.
Hidden terminal problem: when sender and receiver did not known about their transmission range each other then this problem would occurred. If sender transmitting packets within transmission region, and the receiver not in the transmission region then there would be collision occur at sender transmission region.
Exposed terminal problem: happened when the inability of a node to transmit to another node, where there was wireless channel not free because of transmission by the nearby transmitting node .
3.0 Network Simulator- ns-2 setup and Description
This chapter was consists of network simulator selection and the plot form of the operating system to install and the software and hard ware selection was also described. Then general characteristics of network simulator like NS and NAM. The different types of trace files, routing protocol flow chart of analysis and plotting of graphs were discussed. Finally the main objective of the project was to insert the VBR traffic into network simulator like CBR traffic.
3.1 Hardware Requirements:-
System : Pentium IV 2.4 GHz.
Hard disk : 20 GB.
Monitor : 15 VGA colour.
Ram : 256 Mb.
3.1.1 Software Requirements:-
Operating system : Linux UBUNTU 10.10.
Simulator : Network Simulator-NS2 (ns-allinone-2.34).
Coding Language : C++, Tcl and Otcl.
Based on the above requirements network simulator 2.34 was downloaded and installed on Linux version of UBUNTU 10.10 with given path environment variables.
3.2.0 Introduction to Network Simulator
NS2 was created by the Virtual internetwork test bed (VINT) project funded by defence advanced research projects (DARPA. The VINT project was a collaborative project the University of California at Berkeley (UCB), university southern California (USC)/Information sciences institute (ISI), Xerox Palo Alto research canter (PARC) and the Lawrence Berkeley national Laboratory (LBNL) . The local and satellite wireless networks of unicast and multicast routing protocols were works in the ns-2. In ns-2 there were different type of traffics such as TCP with UDP traffics were used in CBR, VBR, FTP and Telnet. Basically NS2 was a combination of two languages; they were C++ and object Tool Command Language (OTcL). These scripts were used in network simulator and allowing inputs with routing protocols of ad hoc perform the optimisation 
From the Figure simulator script was interpreted by the Tcl interpreter, which had a simulator environment scheduler. Tcl interpreter had two types of simulation results, they were text based and graphical based. Every packet in ns -2 had unique ID and the event scheduler would handle the events and initiates the appropriate C++ network applications in given time . Text based results would be called as trace file. In this file, the simulation results of network traffic using routing protocol. These trace file had different type of traces such as agent trace, router trace, MAC trace and movement trace. Based on these traces, calculation of various statistics like average delay, network load and throughput would be evaluated. And in graphical based results were used in network animator (NAM). NAM presents the graphical creation of nodes and resource utilisation and this file was created by the Tcl script of ns. From the following figure, node movement, various traffic analysis and many more would be observed.
Figure: Network Animator (23)
3.2.1 Generating node movement wireless scenario
The random traffic connections of NS2 of mobile nodes were created by using traffic scenario generator scripts. The script was available in the ns/indept-utils/cmu-scen-gen/setdest. By the following single command number of nodes could be created. While creating the nodes, the path should be followed.
Path = ns-allinone-2.34/ns-2.34/indep-utils/cmu-scen-gen/setdest
There were two versions while creating node movement
./setdest [-n num of nodes] [-p pause time] [ -s maxspeed] [-t simtime] [ -x maxx] [-y maxy] . [outdir/movement-file]
./setdest [-n num of nodes] [-s speed type ] [-m minspeed] [-M maxspeed] [-t simtime] [-P pausetype] [-p pausetime] [ -x maxx] [-y maxy] . [outdir/movement-file]
3.2.2 Generating random traffic for wireless scenario
The random traffic pattern was created by the traffic scenario generator script. This script was present in the location of ns/indep-utils/cmu-scen-gen. In that folder using cbgren.tcl file was used for various traffics like CBR, TCP and VBR. In order to create the traffic, a suitable pattern was mentioned. In the following way traffic could be created.
ns cbrgentcl.tcl [-type cbr|tcp|vbr] [-nn nodes] [-seed seed] [-mc conections] [-rate rate] > [file name] 
Pause time: Time in which mobile nodes pause between their movements. The less time was described as more active the mobile nodes were in moving. And there were two types of pause time. One was constant pause (p=1) and second was uniform pause (p=2).
Speed: The speed at which mobile nodes were allowed to roam around in the simulation area. There were two types of speed. One was uniform speed from min to max (s=1) and second was normal speed clipped from min to max (s=2)
Simulation time: This simulation was defined as time at which scenario would complete its execution in given time.
Topology: This topology area was defined by the x and y axis. Number of nodes could be created in within the topology area.
Seed: This was used as random variable generation, which was used to create random number of source destination pair.
Maximum connections: The numbers of connections were taking place at the time of simulations.
Rate: Packet transmission rate of the packet from source to destination. (genindea).
3.2.3 Configuration of Tcl script simulations
The simulations of nodes with desired traffic were configured by selecting important parameters. The total file was shown in the Appendix A. The following important parameters were used in the tcl script for generation of results and NAM visualisations.
The main part of the Tcl script were defind as follows
The following table configuration of above mentioned network options.
Node address always same and name was ID =flat
Was a data link layer: functionalities: link level retransmission and queuing =
Medium access protocol between the link layer and physical layer. It may content carrier sense or collision avoidance depending on the physical layer=
It was used for the interface queue between routing protocols and traffics and defined as
Network interface type for wireless and it serve as hardware interface=
Propagation model attached when the physical layer was defined=
Propagation model instance=
An omni-directional antenna was used to gain unity by mobile nodes=
The channel object simulates apportioned medium and support the medium access mechanism of the MAC objects to the sending side of the transmission medium of wireless networks=
This was used to allow for the node to move in topographical area=
Agent level tracing was enabled and visualization of agents events in trace file=
Routing level tracing was enabled and visualization of events of the trace file =
MAC level tracing was enabled and visualization of MAC events of the trace file=
Mobile node movement tracing was enabled=
Table configuration of Tcl script simulation 
3.2.4 Generated Trace analysis
From the above simulation trace file was generated and it had different types of trace formats. Form the god book NS2, trace format was explained and also from the site in the following way.
ïƒ The normal wireless event trace
Source Node ID
Node X coordinate
Node Y coordinate
Node Z coordinate
Node Energy level
Network trace level( AGT, RTR, MAC)
Hop source node ID
Hop destination ID
Source Ethernet address
Destination Ethernet address
Packet type( ARP, DSR, et)
Packet type (CBR, VBR and TCP)
Table: normal trace wireless event 
ïƒ Address Resolution Protocol trace (ARP)
Request or reply
Source MAC address
Destination Mac address
Table: normal trace wireless event 
Table: Address Resolution Protocol trace (ARP)
ïƒ DSR trace
Number of nodes traversed
Routing request flag
Route request sequence number
Routing reply flag
Route request sequence number
Source of source routing
Destination of source routing
Error report flag
Number of errors
Report to whom
Link error from
Link error to
Table: TCP trace 
ïƒ TCP, CBR and VBR trace
Number of times packet was forwarded
Optimal number of forwarded
CBR and VBR trace
Number of times packet was forwarded
Optimal number of forwards
Table: CBR and VBR trace 
3.2.5 Trace graph:
Trace graph was used to plot the graphs of generated trace file of NS2. This trace graph was the MATLAB feature. The trace graph was installed on the Linux operating system from the website. From this trace graph software, end to end delay, throughputs of receiving bits, jitter and so could be measured
3.3 Modelling and Insertion of variable bit rate (VBR) into NS2
In general VBR traffic was not part of the NS2. But User Datagram Protocol (UDP) had the features of variable bit rate. These were defined by the exponential traffic in UDP. Normally for utilisation of UDP, the exponential back off mechanism was used. VBR video traffic modelling was important because it allow video coders and network designer were estimated the parameters of networks such as loss probabilities and end to end delay. Video coding performance was modelled by the coding process and it consists of data from different types frames. There were different types of traffics such as unconstrained -VBR, shaped-VBR, and constrained-VBR traffic and feedback-VBR. These traffics were selected based on the encoder traffic of network or buffer state during the information about video coding  However, here VBR traffic was encoded with basic characteristics of VBR as shown in the Appendix B. The encoding of VBR traffic was done by the following steps.
First save the vbr_traffic_cc file as shown in Appendix B into the directory of NS2 as follows ns-allinone-2.34/ns-2.34/tools/vbr_traffic_cc.
Then place the tools/vbr_traffic_o into makefile.in at 183 line of folder ns-allinone-2.34/ns-2.34/makefile.in.
And from the same folder of makefile.in replace by following way
Makefile.in line 36 CC=gcc-4.3
Makefile.in line 37 CPP=g++-4.3
Finally from the directory ns-234 configuration was done as follows
ns-allinone-2.34/ns-2.34/$ sudo ./configure
ns-allinone-2.34/ns-2.34/$ sudo mv ns ns234
Here old ns were deleted and new ns were created.
ns-allinone-2.34/ns-2.34$ sudo make.
After successfully installing of VBR traffic, the VBR traffic can be created as same CBR traffic. This VBR traffic was created under cmu-scen-gen of ns-2.34. VBR generation traffic created by the following way under the
ns234 cbrgen.tcl [-type vbr] [-nn nodes] [-seed seed] [-mc maxconnetion] [-rate rate] > file name.
In this chapter,
4.0 Results and Simulation analysis
SIMULATIONS AND RESULTS
Number of Nodes
Speed type (Uniform speed)
Min Speed (m/sec)
Max Speed (m/sec)
Pause type ( Constant pause)
Pause times (sec)
0, 20, 50, 100, 200, 300, 500
Seed ( Random variable)
Average Delay (Seconds)
Packer Delivery Ratio (PDR) %
Normalized Routing Load(NRL)
Routing Over Head
Number of Nodes
Speed type (Uniform speed)
Min Speed (m/sec)
Max Speed (m/sec)
Pause type ( Constant pause)
Pause times (sec)
0, 20, 50, 100, 200, 300, 500
Seed ( Random variable)
Average Delay (Seconds)
Packer Delivery Ratio (PDR) %
Normalized Routing Load(NRL)
Routing Over Head