## 2 Background of the System Modeling and FOPID Controller  
A quadcopter has six degrees of freedom (DOF) movement capability that is provided by its four rotors. Quadcopters involve three rotational and three translational movements. Six DOF movements of a quadcopter are provided by varying the direction and angular velocities of the rotors. The structure and movements of the quadcopter are as shown in Figure 2.  
As shown in Figure 2, the vectors of x, y, and z represent the position of the center of the quadcopter. Angles of \(\varphi\), \(\theta\), and \(\psi\), are Euler angles which denote the roll, pitch, and yaw angles, respectively. The dynamic model of a quadcopter can be described by the nonlinear Equations (1)-(6):  
\[\ddot{x}\ =\ (cos\psi sin\theta cos\varphi+sin\psi sin\varphi)\frac{u1}{m} \tag{1}\]  
\[\ddot{y}\ =\ (cos\psi sin\theta sin\varphi-cos\psi sin\varphi)\frac{u1}{m} \tag{2}\]  
\[\ddot{z}\ =\ -g+cos\theta cos\varphi\frac{u1}{m} \tag{3}\]  
\[\ddot{\varphi}\ =\ \dot{\theta}\dot{\psi}\left(\frac{I_{y}-I_{z}}{I_{x}} \right)+\frac{I_{x}}{I_{x}}u2-\frac{1}{I_{x}}J\ \dot{\theta}\Omega \tag{4}\]  
\[\ddot{\theta}\ =\ \dot{\varphi}\dot{\psi}\left(\frac{I_{z}-I_{x}}{I_{y}} \right)+\frac{I_{y}}{I_{y}}u3-\frac{1}{I_{y}}J\ \dot{\psi}\Omega \tag{5}\]  
\[\ddot{\psi}\ =\ \dot{\theta}\dot{\varphi}\left(\frac{I_{x}-I_{y}}{I_{z}} \right)+\frac{d}{I_{z}}u4 \tag{6}\]  
In Equations (1)-(6), I\({}_{x}\), I\({}_{y}\), and I\({}_{x}\) represent the moment of inertia of the quadcopter, m represents the mass of the quadcopter, and J\({}_{x}\) represents the rotor inertia. L is the length of the rotor arm. The relation between the force, moment, and velocity of the rotor can be described as given in Equations (7)-(11). \[u_{1}\ =\ b\left({\Omega_{1}}^{2}+{\Omega_{2}}^{2}+{\Omega_{3}}^{2}+{ \Omega_{4}}^{2}\right) \tag{7}\]  
Figure 2: 6 DOF movements of the quadcopter on free-body diagram [46]. \[u_{2} = b\left({{\Omega_{1}}^{2}-{\Omega_{3}}^{2}}\right) \tag{8}\] \[\ddot{x}\ =\ (cos\psi sin\theta cos\varphi+sin\psi sin\varphi)\frac{u1}{m} \tag{1}\]0 (9) \[\ddot{x}\ =\ (cos\psi sin\theta cos\varphi+sin\psi sin\varphi)\frac{u1}{m} \tag{1}\]1 (10) \[\ddot{x}\ =\ (cos\psi sin\theta cos\varphi+sin\psi sin\varphi)\frac{u1}{m} \tag{1}\]2  
Equations (7)-(11) represent the system's input variables of movement, \(\Omega_{i}\) represents the speed of the propeller i, and \(F_{i}=b\Omega_{i}\) represents the thrust force of the rotor i. The parameters of b and d, respectively, represent the thrust and drag coefficients. In the literature, there are several studies that are based on obtaining the dynamic parameters of the quadcopters. The results of an experimental study in the literature were used to define the parameters of the nonlinear quadcopter model that was used in this study [47]. Dynamic system modeling and control algorithm evaluation were conducted as part of the project. The Newton-Euler formalism was employed to model the dynamic system, with particular emphasis placed on the subsystem consisting of the DC motor, gearbox, and propeller. The developed subsystem also required the estimation of aerodynamic lift and torque to achieve enhanced accuracy. A comparative analysis of PID control algorithms was performed to assess their effectiveness. To validate the results, both a simulator and a real platform were developed and utilized. The initial phase of testing involved a simulated model, which facilitated performance evaluation through a mathematical approach. Subsequent tests were conducted on a quadrotor platform to assess the real system's behavior. A MATLAB/Simulink-based simulator was developed, enabling the evaluation of model accuracy and control algorithm robustness. This simulation environment featured a 3D graphical output and a joystick interface, which enhanced both the testability and observability of the system.