Research Article
Trustworthy Event-Information Dissemination in Vehicular Ad Hoc Networks
Algorithm 2
Proposed modified clustering algorithm.
Input: | Output: | Initialize: Calculate unique centroid as initial cluster center, | | (1) for each do | (2) | (3) | (4) | (5) end | (6) While two centroids are not converged, do | (7) for each do | (8) Assign to nearest centroid, | (9) | (10) end | (11) Update cluster centroid; | (12) Calculate new centroid as | (13) for each do | (14) , | (15) end | (16) end |
|