## 3 Materials and Methods
### Computation with Distributed System Implementation  
The distributed system remains a single point of the working group, which consists of multiple machines working together. In the vehicle system, we consider each machine as a vehicular system with the implementation of the complete distributed system. Each vehicle is a part of the distributed system. Every vehicle in the distributed system communicates with each other to design and use the neural network (NN) model. We can call it a distributed neural network (DNN) model. The system effectively reduces the allocation of resources on each vehicle and speeds up the detection of malicious nodes. A high-level system implementation of this proposed system is implemented in Figure 4. One vehicle is selected as a monitor vehicle to monitor the safety of a specific location. The monitor vehicle contacts other vehicles to collect malicious information or misbehavior detection. \begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline
**S. No.** & **Author and Year** & **Algorithm Used** & **Real-Time** & **Dataset** & **Environment Setup** & **Tool Used** & **Malicious Attack** & **Accuracy** \\ \hline
1 & [PERSON] et al. [37] & ANN & No & NG-SIM & VANET & Matlab & Misbehavior & 97\% \\ \hline
2 & [PERSON] et al. [41] & \
\begin{tabular}{c} Deep belief \\ network \\ technique \\ \end{tabular} & No & Online & VANET & NS-2 &
\begin{tabular}{c} Trust En- \\ hancement \\ \end{tabular} & 96\% \\ \hline
3 & [PERSON] et al. [43] & SVM & Yes & KDD 1999 & VANET & Matlab & DDoS & 85\% \\ \hline
4 & [PERSON] et al. [44] & SVM & Yes & Self-generated & VANET & SloMoSIM & Misbehavior & 92\% \\ \hline
5 & [PERSON] et al. [45] &
\begin{tabular}{c} IBK, RF, BN, and Boost-I \\ \end{tabular} & No & Self-generated & VANET & Weka & Misbehavior & 93\% \\ \hline
6 & [PERSON] et al. [46] & SVM & No & Self-generated & SDVN & Flood-Light & DDoS & 97\% \\ \hline
7 & [PERSON] et al. [47] & K-Mean & Yes & Self-generated & VANET & NS-3 & DDoS & 95\% \\ \hline
8 & [PERSON] et al. [48] & \
\begin{tabular}{c} Graph-based \\ machine learning technique \\ \end{tabular} & Yes & DTRA & VANET & SUMO &
\begin{tabular}{c} Malicious \\ Node \\ \end{tabular} & 95\% \\ \hline
9 & [PERSON] et al. [49] & \
\begin{tabular}{c} Cluster \\ algorithm and \\ test classification \\ \end{tabular} & No & Online Kaggle & VANET & ML &
\begin{tabular}{c} Malicious \\ Node \\ \end{tabular} & 96.5\% \\ \hline
10 & \begin{tabular}{c} Proposed \\ techniques \\ \end{tabular} & \begin{tabular}{c} GRT, LR, MLPC, \\ RF and SVM \\ \end{tabular} & Yes & \
\begin{tabular}{c} Self-generated \\ + Kaggle \\ \end{tabular} & VANET & ML and NS-3 &
\begin{tabular}{c} Misbehavior \\ + DDoS \\ \end{tabular} & 99\% \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Comparison of different existing state-of-the-art techniques under multiple parameters. The worker vehicle is only used as a computational resource vehicle. Every new role in the network is circulated to neighboring nodes to add additional security. In the proposed system, we use Apache Spark to add the distributed nature to the proposed architecture. The main function of Spark is to split the dataset into distributed datasets that are resilient to the proposed methodology's distributed nature. Figure 5 shows the clustering operation in this scenario. The resilient distributed dataset architecture allows us to perform parallel operations on the dataset. The monitor vehicle's parallel ability to check the co-worker vehicles' ability speeds up the malicious node detection process. Driver programs are designed and run on monitoring vehicles. These programs help utilize the resources from other vehicles. The head nodes in each cluster are named cluster manager. In the monitoring vehicle's driver program, an object is named \"SparkContext\" that helps and connects the manager nodes in each cluster. In this research, we designed a cluster manager node that helps to determine the resource allocation for each node in the cluster programs.