## 4 Control
### Angle Change  
When a surface slope changes, the elevations under a conventional UAV landing gear changes, which will in turn change the slope of the airframe. This can also occur when the UAV's legs land in between multiple surfaces and the surfaces height or slope changes randomly. When the UAV slope changes, it may lead to a rolling accident.  
A rolling accident, as mentioned in [13], can occur when the projection of the center of mass of the airframe on the surface moves out of the stability polygon formed at the ground contact points. This can happen if the angle of the airframe exceeds a certain angle. The angle can be determined with the help of a diagram in Figure 7 and the following equations:  
\[l_{r} =l_{a}\sin 60 \tag{8}\] \[=\frac{\sqrt{3}}{2}l_{a}\] \[l_{p} =l_{a}\cos 60\] \[=\frac{l_{a}}{2}\]  
where \(l_{a}\) is the manipulator base mount distance from the center of the UAV, \(l_{r}\) is the horizontal distance from the center of the UAV to the manipulator tip \(A_{2}\) or \(A_{3}\) as seen from top view, and \(l_{p}\) is the vertical distance from the center of the UAV to the manipulator tips \(A_{2}\) and \(A_{3}\) when seen from top view, as shown in Figure 7.  
Figure 6: Relationship between airframe diameter, propeller length and distance between the propellers to pass the manipulators through.  
The UAV becomes unstable and will roll over if its projection of center of gravity (COG) goes out of the support polygon formed by the manipulator tips. To determine the maximum possible roll and pitch angles, the COG will be at the border of the polygon. Keeping this in mind, as depicted in Figure 7, for pitch and roll case, the angles formed this way are calculated as:  
\[\theta_{a} =180-\sin^{-1}(\frac{l_{h}}{\sqrt{l_{a}^{2}+l_{h}^{2}}}) \tag{9}\] \[\theta_{p} =180-\sin^{-1}(\frac{l_{h}}{\sqrt{l_{p}^{2}+l_{h}^{2}}})\] \[\theta_{r} =180-\sin^{-1}(\frac{l_{h}}{\sqrt{l_{r}^{2}+l_{h}^{2}}})\]  
where \(l_{h}\) is the height of the manipulator and is variable, \(\theta_{r}\) is the roll angle of the airframe. \(\theta_{a}\) and \(\theta_{p}\) are the pitch angles of the airframe from its center to the manipulator tips \(A_{1}\) and \(A_{2}-A_{3}\) respectively. As seen in Figure 7, the relationship between \(l_{a}\), \(l_{r}\), \(l_{p}\) is:  
\[l_{a}>l_{r}>l_{p} \tag{10}\]  
Therefore, we can write the angle relations as:  
\[\theta_{a}>\theta_{r}>\theta_{p} \tag{11}\]  
Figure 7: Maximum angles in roll and pitch axes of the airframe before it loses ground stability. (**a**) Roll and pitch axes of the UAV, its support polygon and manipulator labels. (**b**) Side view of COG reaching the boundary for the roll angle. (**c**,**d**) Side view of COG reaching the boundary for the pitch angles, when \(Arm2\) (**c**) or \(Arm1\) (**d**) side of the UAV is pointing down.  
In this study, the manipulator base mount distance from the center of the airframe \(l_{a}\) is 110 [mm]. Therefore, \(l_{r}\) and \(l_{p}\) will be 95.37 [mm] and 55 [mm] respectively from Equation (8). For the arm design in this design, the \(l_{h}\) is set between 282 [mm] to 417 [mm]. When it comes to the smallest \(l_{h}\) value (282 [mm]), using Equation (9), the maximum roll and pitch angles \(\theta_{a}\), \(\theta_{p}\), \(\theta_{r}\) exceeding the angle in which the UAV will roll over is 111.31[\({}^{\circ}\)], 101.04[\({}^{\circ}\)], 108.69[\({}^{\circ}\)] respectively. Similarly, for \(l_{h}\) value of 417 [mm], the maximum roll over angles \(\theta_{a}\), \(\theta_{p}\) and \(\theta_{r}\) are 104.78[\({}^{\circ}\)], 97.51[\({}^{\circ}\)] and 102.88[\({}^{\circ}\)] respectively.