## 2 Materials and Methods
### Stability Calculation  
A transport's stability is normally expressed by the \"tipping angle\". The tipping angle is the angle between the vertical and the maximum deviation of a trailer with load from the vertical without tipping over [29]. Calculation of that angle requires the coordinates of points \(O\), \(I\), C, and \(P\) in Figure 5 to be determined.  
Point \(O\) is represents center of gravity (CoG), which is calculated by Equation (13). The center of gravity's vertical projection over the plane \(\Pi\) (1-2-3) is represented by \(P\). The vertical line that intersects CoG can be expressed in parametric form as:  
\[\begin{array}{l}x=x_{CoG}+0\cdot t\\ y=y_{CoG}+0\cdot t\\ z=z_{CoG}-1\cdot t\end{array} \tag{13}\]  
By combining Equations (12) and (13), \(t\) can be obtained as follows:  
\[t=\frac{K_{0}-(a\cdot x_{CoG}+b\cdot y_{CoG}+c\cdot z_{CoG})}{-F_{z}} \tag{14}\]  
P, the intersection point is calculated replacing \(t\) by \(p\) in Equation (15). Point \(C\) is the point that is closest point \(I\) on the stability area at any edge. First, the plane that is perpendicular to edge \(i\) through point \(I\) is calculated by the following:  
\[\begin{array}{l}(x_{i+1}-x_{i})\cdot(x-x_{I})+(y_{i+1}-y_{i})\cdot(y-y_{I})+ (z_{i+1}-z_{i})\cdot(z-z_{I})=0\end{array} \tag{15}\]  
with \((x_{i},y_{i},z_{i})\) and \((x_{i+1},y_{i+1},z_{i+1})\) as coordinates for two consecutive corners. The equation for the plane \(\Omega\) is obtained by developing this expression:  
\[\begin{array}{l}\mathit{Plane}\ \Omega:\ +(x_{i+1}-x_{i})\cdot x\ +(y_{i+1}-y_{i})\cdot y\ +(z_{i+1}-z_{i})\cdot z-(x_{i+1}-x_{i})\cdot x_{I}+(y_{i+1}-y_{i})\cdot y_{I}+ (z_{i+1}-z_{i})\cdot z_{I}=0\end{array} \tag{16}\]  
Figure 5: Tipping angle calculation.  
The equation for the edge is the following:  
\[\begin{array}{l}x=x_{i}+(x_{i+1}-x_{i})\cdot t\\ y=y_{i}+(y_{i+1}-y_{i})\cdot t\\ z=z_{i}+(z_{i+1}-z_{i})\cdot t\end{array} \tag{17}\]  
Point C marks the intersection of this line with plane \(\Omega\):  
\[\begin{array}{l}(x_{i+1}-x_{i})\cdot(x_{i}+(x_{i+1}-x_{i})\cdot t)-(x_{i+1}- x_{i})\cdot x_{I}+\\ (y_{i+1}-y_{i})\cdot(y_{i}+(y_{i+1}-y_{i})\cdot t)-(y_{i+1}-y_{i})\cdot y_{I}+ \\ (z_{i+1}-z_{i})\cdot(z_{i}+(z_{i+1}-z_{i})\cdot t)\ -(z_{i+1}-z_{i})\cdot z_{I}=0 \end{array} \tag{18}\]  
By developing the preceding further, \(t\) can be obtained by:  
\[t=\frac{(x_{i+1}-x_{i})\cdot(x_{i}-x_{I})+(y_{i+1}-y_{i})\cdot(y_{i}-y_{I})+( z_{i+1}-z_{i})\cdot(z_{i}-z_{I})}{(x_{i+1}-x_{i})^{2}+(y_{i+1}-y_{i})^{2}+(z_{ i+1}-z_{i})^{2}} \tag{19}\]  
Point C's coordinates can be obtained by replacing \(t\) in equation. The tipping angle is determined by points \(O\), \(I\), and C. The tipping angle that is calculated by the following:  
\[\alpha_{tip}=acos\bigg{(}\frac{|V_{IO}\times V_{CO}|}{|V_{IO}|\cdot|V_{CO}|} \bigg{)} \tag{20}\]  
with \(v_{CD}\) and \(v_{ID}\) as the vectors between points (\(I\),\(O\)) and (\(C\),\(O\)), \(v_{IO}\)\(\times\)\(v_{CO}\) as the cross product, and \(\left\lfloor v_{IO}\right\rfloor\) and \(\left\lfloor v_{CO}\right\rfloor\) as the modulus of these vectors.  
\[\alpha_{tip}=acos\bigg{(}\frac{|\left(\begin{array}{cc}x_{I}-x_{O}&y_{I}-y_{ O}&z_{I}-z_{O}\\ \end{array}\right)\times\left(\begin{array}{cc}x_{C}-x_{O}&y_{C}-y_{O}&z_{C}- z_{O}\\ \end{array}\right)|}{|\left(\begin{array}{cc}x_{I}-x_{O}&y_{I}-y_{O}&z_{I}-z_{O} \\ \end{array}\right)|\cdot|}\bigg{)} \tag{21}\]