## 4 Simulation Results  
Simulation studies were conducted in MATLAB considering a the formation of six UAVs. The DDS middleware, graph theory, LMI, and L1 adaptive controller are used. Table 1 shows the quadrotor parameters that were used [27]. Furthermore, the controller parameters are set to \(k_{d}=10\), \(k_{p}=10\) and \(\gamma=10^{6}\). Figure 1 shows the flowchart of multiple UAVs' formation control utilizing graph theory and LMI controllers. Figure 2 depicts the network topology between multiple UAVs, which is based on a set of QoS criteria (Table 2) that must be met before interaction between the subscribers and publishers may begin. The degree matrix \(D_{dir}\) and the adjacency matrix \(A_{dir}\) of the graph in Figure 2 are  
\[D_{dir}=\left[ \begin{array}{cccccc}1&0&0&0&0&0\\ 0&1&0&0&0&0\\ 0&0&1&0&0&0\\ 0&0&0&1&0&0\\ 0&0&0&0&1&0\\ 0&0&0&0&0&1\end{array} \right]\text{and }\ A_{dir}=\left[ \begin{array}{cccccc}0&1&0&0&0&0\\ 0&0&1&0&0&0\\ 0&0&0&1&0&0\\ 0&0&0&0&1&0\\ 0&0&0&0&0&1\\ 1&0&0&0&0&0\end{array} \right] \tag{23}\]  
The following cases were taken into account in the formation control's simulation:  
* **UAVs formation without DoS attacks**: In the first case, we considered six UAV models with communication delay only. The proposed LMI condition was used to find the formation feedback gain, which means without dropout packet produced by DoS attacks or \(\bar{\delta}=0\), \(h_{min}=0.01\), \(h_{max}=0.014\), \(\tau_{max}=100h_{max}\), and \(\tau_{min}=10h_{min}\) in the delay, as shown in Figure 3, with \(\gamma_{0}=0\) and \(h=1\), and the same initial values of the UAVs, shown in Figures 4-8. This demonstrates how a swarm of six unmanned aerial vehicles (UAVs) may establish a certain topology in 2D space without the effect of the DoS attacks. * **UAVs formation under DoS attacks**: In the second case, we considered six UAVs model with communication delay and dropout packet produced by DoS attacks for when we applied the effect of the DoS attacks, as in Figure 9 on the system, with the same parameters and same controller as in the first case and the same initial values of the UAVs. This is shown in Figures 10-14. The figures illustrate how a swarm of six unmanned aerial vehicles (UAVs) may establish a certain topology in 2D space under the effect of the DoS attacks. \begin{table}
\begin{tabular}{c c c} \hline
**Symbol** & **Value/Unit** & **Properties** \\ \hline g & 9.8 m/s\({}^{2}\) & Gravity Acceleration \\ m & 0.52 kg & Mass \\ \(k_{r}\) & 0.105 & Drag’s Rotational \\ \(L\) & 0.205 m & Arm Length \\ \(k_{t}\) & 0.95 & Drag’s Translational \\ \(d\) & \(7.5\times 10^{-7}\) & Ratio of Drag and Thrust \\ \(I_{z}\) & 0.0129 kg\(\cdot\)m\({}^{2}\) & Inertia of \(z\)-axis \\ \(I_{y}\) & 0.0069 kg\(\cdot\)m\({}^{2}\) & Inertia of \(y\)-axis \\ \(I_{x}\) & 0.0069 kg\(\cdot\)m\({}^{2}\) & Inertia of \(x\)-axis \\ \(I_{R}\) & 3.36 \(\times\) 10\({}^{-5}\) kg\(\cdot\)m\({}^{2}\) & Propeller Inertia \\ \hline \end{tabular}
\end{table} 
Table 1: The quadrotor parameters. Figure 1: Flowchart of multiple UAVs’ formation control. \begin{table}
\begin{tabular}{c c c} \hline
**QoS Policies** & **QoS Value** & \\ \hline  & **Subscriber** & **Publisher** \\ \hline Deadline & Infinite & Infinite \\ Durability & Volatile & Volatile \\ History & Keep Last & Keep All \\ Reliability & Reliable & Reliable \\ Ownership & Shared & Shared \\ \hline \end{tabular}
\end{table} 
Table 2: Quality of service (QoS) policies. Figure 4: UAVs formation at the first position without DoS attacks. Figure 3: The total delay on the system. Figure 2: DDS communication topology of multiple UAVs. Figures 4-7 show the formation control of six UAVs without the effect of DoS attacks. It can be seen that all of the UAVs were built in a hexagon shape. Figure 8 shows the full-view map of UAVs' formation without the effect of DoS attacks. It is clear that at each time, the six UAVs are constructed in a hexagon shape. The DDS middleware was used to share data between the six UAVs. Figure 5: UAVs formation at the second position without DoS attacks.