Cluster Formation and Cluster Head Selection approach for Vehicle Ad-Hoc Network ( VANETs ) using K-Means and Floyd-Warshall Technique

Vehicular Ad-hoc Network (VANETs) is the specific form of Mobile ad-hoc networking (MANETs) in which high dynamic nodes are utilized in carrying out the operations. They are mainly used in urban areas for safety traveling. Clustering algorithms are used for clustering the vehicles that are in the range of the network as VANET consists of a great amount of traffic. A clustering head node is used specified through a procedure to collect all information from the surroundings. This study introduced a new method for cluster head selection by using the K-Mean and Floyd-Warshall algorithms. The proposed technique first divided the points for vehicle groups while the Floyd-Warshall algorithm calculated all pairs of shortest distance for every vehicle within the defined cluster. A vehicle with the smallest average distance among a cluster is chosen as the cluster head. The Floyd-Warshall algorithm overall selects a centralized vehicle as a cluster head, hence its stability time will improve significantly. Keywords—Vehicular Ad-hoc Network (VANETs); Mobile adhoc networking (MANETs); K-Mean; clustering; cluster head selection; Floyd-Warshall


I. INTRODUCTION
The increase in traffic on a daily basis is a big challenge for the people of developing countries.Road traffic conditions directly affect the safety of the people, and many road accidents occur because of poor road traffic safety and management.Therefore, the authorities responsible should focus on road safety to make the road traffic as efficient as possible.Due to IT advancement, the communication among vehicles over large spaces has directed the attention of researchers towards efficient road traffic management.This management technique is called VANET.Nodes are intelligent vehicles which can intra-communicate as well as inter communicate with road side units (RSUs) in VANETs.In addition, they can transmit information on the existing traffic condition's trifling expectancy [1].
Because VANETs is relevant in multiple daily life applications, more and more research is conducted in this area.Some applications are safety, traffic information, and other commercial applications.VANETs consist of two fields: IVC, and RVC.IVC uses simple text messages and Video messages for communication.The latter has a lot of Potential, e.g., commercial advertisement can be done via VANETs video streaming.Other applications are highway safety and digital entertainment advertisement.The video advertising of road accidents can be better conveyed as compared with the textbased information.Furthermore, recreation in travelling systems is provided through chatting (video/voice) and online games in the travelling system [2].The dynamic nature of VANETs sets a lot of challenges for researchers such as network stability.The mobility of nodes is much higher in VANETs than in WSNs and other such networks.Due to the limited communication range, FLD happens very often, which further leads to packet loss and delay [3].Different approaches can be seen in [4]- [6] to solve and mitigate such issues; however the current study is focused on a clustering algorithm in which the stability cluster head is visibly an unbound issue.Nodes are partitioned into different areas called clusters, where the cluster head nodes are responsible for collecting and managing clusters' nodes.K-means is used to form the cluster.This method is a well-known method for cluster analysis [7].For the cluster head, each head node is analyzed by the Floyd-Warshall algorithm to find the centralized node for that particular cluster.For dynamic topology, the challenging task is the confirmation of head node stability.The clustering algorithm should consider these factors when proposing an optimal solution in the VANET cluster's minimum number, density, structure, and the cluster head's lifetime.The foremost refrain of every clustering algorithm is the maintenance of a cluster's status for long span [8].The Floyd-Warshall algorithm is most commonly used to compute all pairs of shortest paths for the whole vehicle and eventually to select the vehicle's head pertaining to minimum middling distance to the rest of the vehicles.This technique leads to the prolonged lifetime of the vehicle's head, and thus results in a less dynamic topological structure.

II. RELATED WORK
Clustering algorithms have been widely studied in relevant literature, and multiple approaches are suggested in selecting the cluster head in VANET.A new approach is proposed by [9] where the cluster formation criteria depend on the mobility of the vehicle.In this approach, high mobility vehicles are grouped together into one cluster, while low mobility vehicles are grouped in the other cluster.To select the cluster head for any particular cluster, different metrics are considered.On the other hand, a novel approach is introduced by using the Floyd-Warshall algorithm for the selection of the Cluster Head.The www.ijacsa.thesai.orgHELLO message is exchanged with the new vehicle in the network using the proposed cluster-based location routing (CBLR).All the joining vehicles air the HELLO message and wait for an instant of time in order to get a response.After receiving the message reply from the neighbor, it will join that cluster [10].If no message is received by this node, it will announce itself as the cluster head.To ensure proper functioning and to maintain the nodes' status, a table is used to list all the neighbor nodes, and this table is shared with other cluster heads for proper communication [11]-[14].
In [15] another clustering algorithm is proposed that uses MANETs lowest ID with modification.In the selection of CH, certain authors have proposed the Direction and Leadership Duration (LD) method in making the decision for a node to become the cluster head.The LD is the time span for a node to be the leader for that CH.For the highest LD the lowest ID will be selected to be the cluster head.The idea of [16] is presented in [17] by the authors with some alteration in the leadership duration (LD) and direction, and the introduction of projected distance (PD) variation.For the specific time slot, the probable distance is the difference among the nearby vehicles.Every node is linked to Utility Weight (UW) comprising of three diverse parameters (LD, PD, ID).ID denotes the node identification and the LD has the utmost degree among all three.A node with higher leadership duration must be preferred over any with a higher degree in selection of the cluster head [18], [19].The Aggregate Local Mobility (ALM) method incorporates the Received Signal Strength (RSS) as a metric in computing the distance between the sender and the receiver [20].But this method does not work well in computation of the distance in VANETs [21].

III. PROPOSED WORK
The proposed work focuses on cluster formation and cluster head selection.These Cluster algorithms are divided into two parts, Cluster's head Selection and Cluster's Formation.Cluster formation is performed by the K-Means algorithm, where an initial Vehicle is selected as the cluster division point.In the proposed work three division points are selected and vehicles are categorized into clusters on the basis of their nearest division points.Basically, the open issue in the cluster head selection is the high mobility of nodes.Each of the vehicles selects a cluster head to form a cluster group and calculates the pair of shortest paths by using the Floyd-Warshall Algorithm.It also calculates the average value and the vehicle having low average value will be the cluster head.For the cluster head selection in cluster routing the concept of graph theory is used and for the head node selection, different matrices are used.To achieve a stable head node a novel approach is introduced using the Floyd-Warshall algorithm because the one widely used algorithm in computing all pairs of shortest paths between all vertices is the Floyd-Warshall algorithm.In the suggested model the scenario of the highway vehicles is taken, in which each node is taken as a graph vertex and the distance between the vehicles is represented as Edges.Fig. 1 represents a simple scenario of VANET, in which five different vehicles (nodes) are connected, which shows the complete case study.Distance between two vehicles can be calculated by using the distance formula, i.e., The distance between each vehicle from its coordinate points is calculated (Fig. 2).
In given formula the "a" and "b" are the coordinates position of the vehicles and the "d" represents the distance between these vehicles.Distance between Red Vehicles (RV) and Yellow Vehicles (YV) is calculated as follows: d (RV) = ((12 -4) 2 + (5 -5) 2 ) 0.5 = 8 m d (YV) = ((12 4) 2 + (10 -10) 2 ) 0.5 = 8 m After the first phase, i.e., distance calculation to every vehicle (node), the Floyd-Warshall algorithm is applied which runs on each node within the cluster for the selection of the cluster head.Each vehicle in the Floyd-Warshall algorithm is selected as intermediate and using that node, all the distances to other vehicles are calculated.The minimum distance is selected by comparing the direct distance, while bypass distances are done in the Floyd-Warshall algorithm using the equation given below: Dxy (k) ← min(Dxy (k-1) ,Dxy (k-1) +Dxy (k-1) ) (2) The Floyd iteration ends when all vehicles are completely selected as intermediate vehicles.The minimum distance is computed by analyzing the average distance of each vehicle calculated as a result of the complete execution of Floyd-Warshall.This minimum value is selected as the Cluster Head.The Average Distance (AD) of all Vehicles (V) is calculated as follows by the Floyd-Warshall algorithm.The final average distance value of each vehicle is shown in Table II.From the table, we can analyze that Vehicle (V-E) has the lowest average distance value, and is therefore chosen as the Cluster Head.

IV. RESULTS AND DISCUSSION
In this section we examine the viability of our proposed scheme through extensive simulation in Network Simulation Version 2 (NS-2).The simulations were performed different traffic environment and densities including highway and dense urban environment.However, here we show the average results of all the environment unless explicitly mentioned.The numbers of vehicles were varied from 10 to 300.The position of vehicles is also randomly chosen.We compare our proposed cluster formation and cluster head selection technique by using K-Means and Floyd-Warshall algorithm (KMFW) algorithm with Cluster-based traffic information generalization (CTIG) [22] and clustering algorithm in vehicular ad hoc networks (VWCA) [23].Fig. 1 shows the mean Peak Signal to Noise Ratio (PSNR) with varying number of vehicles.Intuitively, greater the number of vehicles, the higher the signal quality.With greater number of vehicles, the signal would incur lesser path loss.The same trend is reflected in the bars shown in Fig. 3.In terms of mean PSNR, our proposed KMFW scheme has better performance in comparison with VWCA and CTIG.When the number of vehicles is 60, the mean PSNR for VWCA is 15 dB, it slightly over 15 for CTIG and almost 20 dB for proposed KMFW scheme.With the increase in number of vehicles, all the three scheme shows increase in mean PSNR.However, the interscheme mean PSNR difference of the three schemes gets decreased gradually.For example, at 250 vehicles the difference is extremely slight one.For VWCA and CTIG it's slightly below 40 dB while for KMFW, it's slightly above the 40 dB.The reason is that with greater density of vehicles, the vehicles are more likely to be closed to each other which leads to regeneration of the signal.Hence, the signal overall suffers lesser loss as compared to parse density of vehicles.After certain number of vehicles per kilometer, 250 in this case, the mean PSNR will remain the same.However, for lesser number of vehicles the proposed KMFW performs better than VWCA and CTIG.

Rests of the parameters are given in
Because of the regeneration of the signal, the PSNR does not fall.This is the reason that the signal travels much farther with the increase in the number of vehicles.In other words, with increase in number of vehicles, the transmission range of the signal increases.The same is reflected in Fig. 4.However, in comparison with CTIG and VWCA, the proposed KMFW has better transmission range.At 30 vehicles per kilometer, the transmission range for all three scheme is around 50 meters.When we increase the number of vehicles, the transmission range of all the schemes increases but that of KMFW increases with greater rate as compared to VWCA and CTIG.At 240 number of vehicles per kilometer, the transmission range of VWCA is slightly above 610 meters, transmission range of VWCA is around 700 meters while that of KMFW is over 800 meters.In Fig. 5, we have compared the percentage of time the vehicles are connected.With more number of vehicles per kilometer, the vehicles are more likely to be connected to each other.The same trend is reflected in the curve.However again, KMFW gives better connectivity performance as compared to CTIG and VWCA.In Fig. 5, we have kept the speed of the vehicles at 40 km/h.At 30 vehicles per kilometer, the percentage connectivity of VWCA is 62 %, CTIG is 63 percent while that of KMFW is over 65%.The Percentage connectivity follows the same trend as mean PSNR that is, after certain point the vehicles are almost always connected.In this case, after 240 vehicles per kilometer, the connectivity of all three is nearly 100% with connectivity of that of KMFW is exactly 100%.
In Fig. 6, we have taken 180 vehicles with varying velocity per hour and then checked the connectivity percentage.With the increase in the speed, the connection is more likely to break.However, KMFW is more resilient as compared to VWCA and CTIG.Starting with 40 kmph velocity, the percentage connectivity of VWCA is around 85%, CTIG is around 90% while percentage connectivity for KMFW is above 90%.Percentage connectivity of all the three schemes decreasing with the increase in the velocity, it gets below 55% for VWCA, 60% for CTIG while about 70% for KMFW.This shows that the proposed scheme is more resilient to the contemporary proposed algorithms.Fig. 7 shows the cluster head duration comparison of the three schemes for varying velocity per hour with 180 vehicles per kilometer.The proposed KMFW scheme is outperforming VWCA and CTIG in terms of cluster head duration.Cluster head duration of KMFW is consistently larger then VWCA and CTIG.For 40 km/h velocity, the cluster head duration of VWCA is about 100 seconds, for CTIG it is 120 seconds while for KMFW it is slightly below 140 seconds.As the velocity of the vehicles increases, the duration decreases.For 120 km/h, the cluster head duration for VWCA is below 20 seconds, for CTIG it is around 30 seconds while for KMFW, the cluster head duration is about 50 seconds.

V. CONCLUSION
We presented a novel Cluster formation and Cluster head Selection approach for Vehicle Ad-hoc Network (VANETs) using K-Means & Floyd-Warshall Algorithm.The proposed algorithms had two parts that is, providing divisions parts for vehicles group using K-Means and then in second part, calculating all pair shortest path for every vehicles within the cluster using Floyd-Warshall Algorithm.Criteria for Cluster Head (CH) selection in FW algorithm is, the node in the cluster having small average distance to all other vehicle in the cluster.We showed through simulations that our proposed scheme outperforms the contemporary algorithms in terms of mean PSNR, transmission range, average connectivity and average duration of cluster head.

Fig. 1 .
Fig. 1.Cluster form of vehicles on highway, a case study.