Research Article

EtHgSC: Eigen Trick-Based Hypergraph Stable Clustering Algorithm in VANET

Algorithm 2

The pseudocode for CH selection using the GRA model.
Input: number of clusters, number of vehicles in each cluster at each instant of time, vehicles coordinators (), current lane length (L), current direction
For t = 1: instant of time
 For i = 1: clusters
  For j = 1: vehicles in cluster
   Calculate the CH parameters: , , and
   Predicted the next vehicle’s coordinators (X′, Y′)
   Find the new vehicle’s direction from predicted coordinators
   Calculate using predicted vehicle’s position
  End for
  Input the four matrices to GRA model with their weights, where
  Generate a matrix of
  Normalize the matrix
    For
(a)     For
     Calculate the grey relational coefficient
(b)     end for
    end for
  Generate a graph object from grey relational coefficient
  Calculate the Vehicle’s grade with the help of
   Highest-grade vehicle is selected as a CH
 End for
End for
Output: CH vehicle