Analysis of TCP streaming over VANETs

—In this article is considered Vehicular Ad-Hoc Networks (VANETs) as a technology aimed at the exchange of information between vehicles, where the nodes/vehicles of origin and destination, do not have a direct communication. Also is emphasized and analized the use interest of a TCP (Transition Control Protocol) trafﬁc ﬂow, since it is one of the fundamental protocols for Internet of things (IoT). Most Internet applications use TCP to create “connections” with each other, in order to maintain applications with a continuous data ﬂow, it is, TCP over Internet guarantees the integrity and delivery of the data to its destination without errors and in the same order in which they were originally transmitted. At the end of the article, it is discussed how the mobility in VANET networks, impacts a continuous ﬂow of data on TCP, performing this analysis by modeling a scenario in NetLogo and its simulation with NS2.


I. INTRODUCTION
Network Simulator (NS2) software provides models to simulate wireless network environments, allowing the reading and trace generation to estimate data traffic behavior in general or particular case studies.
NS2 integrates with tools such as Traffic and Network Simulation Environment (TraNS) based on the vehicle traffic simulator SUMO, to generate realistic simulations in VANETs networks.TraNS allows the information exchanged in VANETs to influence the behavior of the vehicle in the mobility model, such is the case, that a vehicle transmits information from an accident to neighbors vehicles, so that vehicles in the velocity model can slow down.
Alternative, NetLogo allows to make more complex models capable to characterize particular behaviors, that is, to characterize vehicles of load, of particular use, of public transport and elements that interact in the roadways like traffic lights, pedestrian crossings, and vehicular roundabouts, among others [1]- [4].In NetLogo you can also incorporate the behavior of people and other objects, assigning them as agents that act with rules, with or without intelligence, depending on the complexity that is wanted to be given to them.
This article analyzes the impact of a TCP communication in End-to-End streaming on VANETs, with the characterization of a wireless communication using USB adapters that support IEEE802.11b on a raspberry pi 2, in Ad-Hoc mode, simulated in NS2.
In a first approach to NetLogo as an alternative tool to SUMO, a VANETs simulation is performed in the city of Oviedo -Asturias Spain, with the interaction of 40 mobile agents (vehicular nodes) and two static ones corresponding to the source and destination nodes.In this simulation, the normal, binomial, geometric and exponential distributions were evaluated on the velocities of the remaining 40 mobile agents/nodes, analyzing performance metrics: one-way delay, normalized routing load, normalized packet delivery ratio and throughput.

A. NetLogo
It is a multiagent environment that allows simulating natural and social phenomena, used in the modeling of complex systems.The models created in NetLogo allow creating rules of behavior for hundreds of agents/nodes that operate independently or according to the interactions with their surroundings.This makes it possible to explore the relationship between the individual behaviors of the agents/nodes and observe patterns of emergent behavior arising from individual interactions.This feature highlights NetLogo over SUMO, since SUMO is the most widespread simulation tool in VANETs networks [5]- [7].By its multi-agent behavior, NetLogo approaches the edge of the video game engines, obtaining more realistic results than with the simulation tools used so far.

B. NS2
It's one of the most widespread mobile wireless simulators accepted by researchers and developers.It is an open source tool, which supports the simulation schemes shown in Table I[8]- [16].
NS2 allows reading in its main script an external file, which contains the mobility information that is required to evaluate, according to the requirements of the VANETs simulation scenario and the communication protocol, as shown in Figure 1.Table II shows some wireless terminals that allow a configuration for raspberry pi 2 Chipset in ad-hoc network, with the option to place antennas with gains of 3 to 5 dB, obtaining coverage ranges of 100 to 300 meters.

IV. METHODOLOGY
Based on Figure 2, for the creation of the scenario and case study, we selected the science faculty as the origin node and the gymnasium of the University of Oviedo -Spain as destination node, separated by a distance in a straight line of 800m.The area selected in Google maps is 900m x 500m.
Each mobile node was configured with an omnidirectional coverage radius of 150m, to obtain approximately 38 vehicles, which can guarantee a dense topology with an end-to-end connectivity probability greater than 0.95 [21].The vehicles in NetLogo were distributed on the main streets and avenues, in most of the cases were realized cyclical trajectories.The type of network traffic to be evaluated corresponds to TCP traffic in streaming to a transfer rate of 1Kbps, since for bandwidths greater than 20Kbps with a uniform speed of 16m/s distributed between vehicles, more than 55% of the Data transmitted is lost [22], [23].As vehicles in a city do not have uniform speed and behavior, it is decided to evaluate speeds with different distributions and to analyze the impact they have on a VANETs.As it is analyzed TCP traffic in streaming between the Faculty of Sciences and the Gym of the University, UDP/CBR traffic is configured as traffic background or traffic that can generate other vehicles.Then, the performance metrics are analyzed in the modeling scenario (see Figure 2), for which the most important simulation parameters are summarized in Table III.
A. Metrics 1) One-Way Delay (OWD): The OWD measure is complex to obtain in relation to the Round-Trip Delay Time (RTT) measure, since the source node must send a packet with a timestamp, and this must be compared with the timestamp of 40 PROCEEDINGS OF RICE.GOPESHWAR, 2017 the destination node, making it necessary for the clocks of both end nodes to be synchronized.In an actual implementation it is required that each raspberry pi contain a GPS (Global Positioning System) module that provides a clock reference signal to each of the end network cards, or synchronize with the internal clocks of each card.For the case dealt with in this article, the synchronization is performed by the host where the simulation is executed in NS2 and by means of an awk script applied to the trace of the simulation; this measurement can be obtained [24].The expression to evaluate the OWD is: that is, the test packet k as it moves from the i − th transmitting node to the j − th receiving node is represented by the plus the time difference between the two clocks is τ .This time offset can be estimated as the difference of time zero time T ime 0 (t 0 ) (reference time) and the time of sending of the package i (T ime i (t 0 )), that is: 2) Normalized Routing Load (NRL): The NRL can be defined as the total number of routing packages transmitted per packet of data.This measure estimates the overhead of the routing protocol; That is, how many routing or control packets need to be added to a data packet to discover, transport and maintain a route that can successfully transport the data packets to their destination [25].The NRL is determined as: where p rc is the total number of routing and control packets sent, p d is the total number of data packets sent.
3) Packet Delivery Ratio Normalized (PDR): The PDR is the traffic ratio between the number of packets transmitted by a source node and the number of packets received by a destination node.It measures the packet loss rate in the User Datagram Protocol (UDP) and Transmission Control Protocol (TCP) transport protocols [26].The PDR is given by: Where p r is the total number of packets received at the destination node and p d is the total number of data packets sent.
4) Throughput: Throughput is the number of packets successfully delivered per unit of time, controlled by the available bandwidth.For the purpose of this article it will be understood as the measurement from the arrival of the first data packet on the receiving node, during a time window, in this way is also interpreted as the satisfactory rate of transmissions [27].It is defined as follows: where p r is the total number of packets received at the destination node and T ts is the total time it takes the packets to be transmitted.

B. Speed distributions
The vehicle movement dealt with in this article was made by 40 vehicles with the following distributions of speed:

V. RESULTS
The experiment was characterized by 42 nodes/agents, to which an independent speed was assigned to each one.The assigned speeds did not depend on any speed of another vehicle, therefore, in NetLogo, no rules were assigned for the safety distance, reaction distance and braking distance between the nodes/agents.For the delay (See Figure 4), it is observed that the results obtained with the normal distribution are higher regarding the other distributions, since the average speed of this distribution is greater than the others.In contrast, with the exponential distribution, the average velocity was the lowest of all distributions.In networks it is generally characterized by the Quality of Service (QoS) and the delay is one of the metrics that help to characterize it, however, this metric is not decisive within the realized experiment.
The obtained results are in accordance with the average speed obtained, for the normal distribution, an average speed of 15.31m/s, binomial of 11.97m/s, geometric of 5.32m/s and exponential of 3.61m/s, values which are proportional to the delay and results obtained.The TCP data traffic in VANETs is sensitive to packet loss by mobility; again, in Figure 6, it is observed how speed affects packet loss.Data traffic in TCP is characterized by ensuring the integrity of information in networks with infrastructure, such as the Internet, but in the case of VANETs and topological dynamics, TCP cannot guarantee the total integrity of the streaming data flow, for the obtained results was obtained for all distributions, the "guarantee" of 85% of the data in destination node, losing 15% of data in streaming, noting a proportion of data loss according to the velocity distribution evaluated.
In the experiment proposed in VANETs networks, we observe how the data are grouped according to the distributions, we observe similar behavior trends between the Normal and Binomial distributions, and between the geometric and exponential distribution.The NRL presents for a flow streaming of data in TCP of 1kps, a behavior proportional to the background routing increased by the traffic sources, such is the case, that for 14 traffic sources a maximum value is found in the metric of the NRL, while That for this same value of traffic sources, there is a notorious minimum in the Throughput metric.Related to these graphs the bandwidth is affected by very high NRL values, finding that the NRL is inversely proportional to the Throughput.

VI. CONCLUSIONS
In a TCP streaming, the data flow in VANETs for lowhop transmissions the information is lost, and although TCP mechanisms are related to retrieve the transmitted data, the dynamic topology of the VANETs prevents this retrieval of information.This generates an increase of control and routing packets of the network protocol that is being used and is reflected in the increment of the NRL.
Respect to the Background traffic, which corresponds to traffic sources, it is observed in the results of the VANETs networks proposed experiment, which is stable for the first four traffic sources, for the results of the following traffic sources, there is an increase in the NRL that is also reflected in the decrease in Throughput.
As for the PDR and OWD, their behavior is a little varied; we do not note points that characterize the flow of TCP data streaming in the experiment.Due to the results obtained it is not advisable to carry out data transmission from end to 42 PROCEEDINGS OF RICE.GOPESHWAR, 2017

TABLE II CHIPSET
/DRIVER IN AD-HOC NETWORK RASPBERRY PI 2