Internal Model Control Tuned Proportional Integral Derivative for Quadrotor Unmanned Aerial Vehicle Dynamic Model

In recent times, there are has been growing substantive attention to the quadrotor Unmanned Aerial Vehicle (UAV) stability control. However, inherent nonlinearity is a major challenge with this control technique, this paper, therefore, developed a PID based Internal Model Control (IMC) method for the dynamic model of quadrotor UAV. The versatility and simplicity of the Proportional-Integral-Derivative (PID) controller enable it to enjoy wide usage and acceptability as stability control methods for the unmanned aerial vehicles. The aim of this paper is to use the PID controller with IMC to control a UAV. The proposed approach IMC-PID control method -was simulated using MATLAB software and X-plane flight simulator. Thereafter, a comparative analysis of the IMC-PID control method with Chien-Hrones-Reswick, Cohen-coon, and Ziegler Nichols based PID Controllers was done using pitch and altitude as performance metrics.


Introduction
Drone categorized as an unmanned aerial vehicle (UAV) is known to be no human pilot onboard aircraft (Gene, McCall John, and Corder, 1997). It can either be self-controlled by the computers in it or controlled remotely under the guidance of a pilot on the ground. UAV enjoyed wide adoption in various fields of applications such as military, cinematography and product delivery whereas it was majorly being developed for military purposes in the past. UAVs can either be rotary-wing or fixed-wing typed. Fixed-wing type is characterized by a simple control and better endurance. The fixed-wing type has the capability of sensing images at long distances, this justified its usage for wide-area surveillance and tracking applications. Fixed. The fixed-wing type suffers from sufficient time and space required to regains its progression after turning. The rotary-wing type is as wellreferred to as Vertical Takeoff and Landing (VTOL) vehicle. It has high maneuverability, minimum launching time and requires little space for landing (Anuj, 2012).
Emerging pieces of evidence have that UAV can still be adopted in several other areas such as environmental protection as in air pollution measurement and monitoring of forest; safety like airspace monitoring, management, and assessment of natural risk like volcano activities monitoring; large infrastructures management like dams, high-tension lines, and pipelines; intervention in hostile sites, agriculture and aerial shooting in film production. It may be used for field observations, to monitor a wide stretch of traffic in the cities (Astha and Amol 2012). Small UAVs are useful for automatic landscape photographing in cartography since they are less stressful and cost-efficient compared to the traditional aerial snapshotting. UAVs are capable of being used for flying laboratories in addition to its ability to serve as proving ground for many algorithms used for control (Ondrej, Stepan, and Zdenek, 2007).
The effectiveness of UAVs depends largely on the efficacy of the control scheme been adopted.
Consequently, there are has been an upsurge in quadrotor UAV control in recent times.Authors, Bora and Altuğ (2007) employed a quadrotor Euler-Newton techniqueto model vision-based stabilization and as well as for output tracking control. Similarly, the work of Suter,Hamel, and Mahony, (2002)established the application of quadrotor for image centered visual servo control. The research report by Dunfied, Tarbouchi, and Labonte, (2004) demonstrated the application of quadrotor for a neural network controller. Also, the quadrotor attitude was investigated with the aid of the Kalman filter by authors (Earl and Andrea, 2004). The work of Mohammad, Abbas, and Youmin (2012) revealed the usage of fault-tolerant adaptive PID-controller for a quadrotor helicopter system having actuator faults in presence, in their work, should a fault occur, the system response was improved with the aid of fuzzy scheduler for both tracking and change in tracking errors. The results obtained showed the proposed technique is very efficient and very adaptable for cases of uncertainties and external disturbances. Small UAV was proposed for attitude control with switching actuators in Hardware-In-the-loop (HIL) by BittarFiguereido, Guimaraes and Mendes (2014). The attitude control law was employed for fixed-wing small unmanned aircraft using two phases of a flight namely; stable and maneuvering flight. Switches were made between two phases of flight when the aircraft's altitude and the reference value is below the preset value (Suter,Hamel, and Mahony, 2002). Backstepping control technique was engaged for studying quadrotor UAV attitude stabilization while the quadrotor's attitude was represented using unit quaternion as against the usage of Euler angles, the author established that the system closed-loop attitude was asymptotically stable using Lyapunov stability analysis. It was that, when external disturbance torque is factored, the attitude and the angular velocity of the quadrotor are governed to be uniformly ultimately bounded while the aerodynamic effect was neglected (Xing, Mingyi and Hamid,2014). Figure 1 showed that the model of a quadrotor UAV comprises four input forces that are supplied at a constant angle by each propeller linked with each rotor. It consists of a rigid cross-frame furnished with quadrotor which stands for the four input forces. A rise in the rotor 4 angular velocities and a fall in rotor 2 angular velocity bring about roll movement. A rise in rotor 1 angular velocity and a fall in rotor 3 angular velocity bring about pitch movement. A rise in the angular velocities of rotor 1and rotor 3 together with a fall in the angular velocities of rotor 2 and rotor 4 bring about yaw movement. A complete increase in the angular velocities of all the four rotors leads to thrust movement. Figure 1: Quadrotor UAV body fixed frame, configuration and inertia (Abbasi, Mahjoob,and Yazdanpanah, 2013) Researchers have carried out considerable work on advanced multivariable controllers for both fixed-wing aircraft and rotary-wing UAV. The commonly used stability control methods for UAV are based on Proportional Integral Derivative (PID) controllers as a result of their simplicity and various application areas. PID controllers enjoyed a wide preference for most control application processes due to its outstanding performance, easy to comprehend the structure and acceptable failure tolerance (Palmor and Krasney, 1996).However, due to the Control Theory and Informatics www.iiste.org ISSN 2224-5774 (Paper) ISSN 2225-0492 (Online) Vol.9, 2020 complexity of quadrotor UAV together with its nonlinear dynamic characteristic, the PID controller cannot guarantee good stability unless its control parameters are properly tuned. Although PID controllers are generally accepted, it has a limited number of appropriate tuning techniques.Also,several of the available approaches to designing PID controllers are difficult in terms of computation. Therefore, they are less attractive to practitioners. Several PID's controllers tuning methods are identical to those in single loop tuning rules employed do not account for interactionsprocess consequently stability is maintained by detuning individual loops (Luyben, 1986)or became modified to adhere to performance specification (Palmor and Krasney, 1996). This creates a gap this research intends to fill, several tuning techniques were examined to determine the optimal tuning technique for PID controlled quadrotor.

2.Dynamic Modeling of Quadrotor UAV
The mathematical model of quadrotor UAV was examined with aid of Euler-Newton method, quadrotor orientation was obtained via roll angle pitch angle and yaw angle plus the rotation matrix R (sometimes called Directional Cosine matrix or Orientation matrix).
where, R = composite rotation of Rα, Rβ and R w Also, the thrust force generated by rotor i, is given as; The drag force FDcan be expressed as; where; -Kd= friction constant for each direction of motionx, y and z. The quadrotorlinear motion is defined by a set of differential equation which described acceleration of thequadrotor; where; g = acceleration due to gravity, m= quadrotor mass, R = rotation matrix, T = total trust on the quadrotor, FD = drag force If the rotor inertial matrix is given by (7), then the second set of rotor inertial matrix differential equation is defined by equation (8) where; I= rotor inertia matrix, Ix, Iy and Iz= diagonal matrix inertias,Vector M=torque applied to the body of the vehicle, vector MG= gyroscopic torques, Ω = angular velocity. Similarly, the Gyroscope torques are a function of the rotor's rotational velocity and hence on the vector U T =(u1, u2, u3, u4) of the transformed input variable. Assuming that The dynamic model is obtained by evaluating Equation (7) and (8) thus; The drag force terms in equations (9 to 12) are considered as small system disturbances this is due to the fact at low speeds the drag force is very small (Bora and Altuğ, 2007 x R w w w w w w I w w w w ae aw w w Equations (9) to (14) represents the quadrotor mathematical model.

3.Control System Architecture
The system model comprised of four input forces supplied by the individual propeller linked to each rotor at a fixed angle. It has a rigid cross-frame furnished with four rotors (quadrotor), the rotors are divided into front, rear, left, and right. The dynamic model of quadrotor UAV consisting of fully actuated and underactuated subsystems was obtained using the Euler-Newton approach. The dynamics of vertical position and the yaw angle are provided via the fully activated fully actuated subsystems while the underactuated subsystem is responsible for the dynamic relation of the horizontal position with the pitch and the roll angle. The developed quadrotor UAV model was used to design a PID based Internal Model Control (IMC-PID), controller. The IMC-PID controller was simulated using MATLAB/Simulink with X-Plane flight simulator. X-plane and MATLAB communicate and share data to and fro through the xPC Target Library. The performance of the simulated IMC-PID control method was evaluated and compared with Ziegler Nichols (ZN), Cohen-Coon (CC) and Chien-Hrones-Reswick (CHR) based PID Controller using pitch and altitude as performance metrics.

IMC-PID Control Design
There are various types of controllers such as conventional control, sliding mode control (SMC), adaptive control, state-dependent Riccati equation control, backstepping control, fuzzy logic control, H∞ control, and Control Theory and Informatics www.iiste.org ISSN 2224-5774 (Paper) ISSN 2225-0492 (Online) Vol.9, 2020 5 neural network control. The major conventional controller used in industrial process control is the PID controller. One of the major characteristics of this controller is that one has to know the plant's mathematical model to design it. Several industrial processes are nonlinear thus, the complex to model mathematically. Nevertheless, it is interesting that many of these nonlinear processes can be reasonably controlled using PID controllers if its parameters are well-tuned.Tuning parameters requires comprehensive knowledge of the system and an understanding of the conditions in which the PID controller will be used. Regulation of various gain parameters (KP, KI, and KD) to arrive at an optimal value of the desired output is referred to as PID-tuning.A PID controller can be modeled mathematically using equation (16) given thus; The IMC system is represented using the block diagram shown in Figure 2; Gm(s) = Nominal model, R(s) = Desired value, D(s) = Disturbance input, U(s) = Controlled input, Y(s) = Output, N(s) = Measurement noise andC(s) = Controller. PID controller tuning was achieved with the aid of IMC method to match the performance specifications.The purpose is to establish the parameters of a model with the structure based on an input signal and the system output. The control loop remains stable even if the process behaviour changes considerably from the ones used for tuning. An IMC-tuned control loop accepts more disturbances and passes less to the remaining parts of the process. Therefore, it is a very attractive feature for using IMC tuning in an interactive process.

Ziegler-Nichols Method
A very useful tuning technique for industrial and process control systems by approximately modeling the plants as (Abbasi, Mahjoob, and Yazdanpanah, 2013

Cohen-Coon Method
With this approach, the output is measured with reference to the time constant and time delay using an offline tuning technique and the initial parameters can be estimated via theresponse obtained (Dingyu, Yang and Derek,2007). Figure 3 denotesa = kL/T and t = L / (L +T), employing the usage of Table 1 gives the designed value for the controller parameters.

Chien-Hrones-Reswick
This technique is a modified form of the Ziegler-Nichols technique, with this technique plant time constant (T) is explicitly utilized (Satya and Omhari, 2012). Table 1 presented a tuning formula for set-point regulation of the CHR-PID controller. Comparing CHR_PID with the conventional Ziegler-Nichols tuning formula, CHR employed the usage of T, L, and k, with a = kL/T.

Simulation
UAVs flight testing in a real environment is quite expensive due to the high cost of aviation fuel in addition to extensive flight-testing requirements by the emerging technologies. Simulation-based flight testing was adopted as an alternative because it is economical. X-Plane flight simulator is an engineering tool used for testing and validating flight characteristics of UAVs. It has been widely used for UAVs modeling and control because it is capable of communicating the flight parameter. Figure 4, represents the interconnection between MATLAB/Simulink and X-plane. In this paper, the model of Unmanned Aerial Vehicle as previously modeled was provided by X-Plane to simulate its dynamics. The X-Plane aircraft models ensure the simulation has a high degree of accuracy as an actual flight before implementation for safety purposes.
The controller was first implementedand tested in MATLAB Simulink and validated with X-Plane. The Simulink model was designed to accept the exact control inputs sent to the X-Plane to determine the response. The control system was configured to allow for the maximum amount of movement and to monitor the movement of the UAV. The output was examinedby the altitude and pitch rate to observe the steady-state of the flight. The altitude response was used for the analysis of the aircraft's longitudinal response.

Result and Discussion
The pitch data from the controllers; Ziegler-Nichols-PID, Cohen-Coon-PID, Chien-Hrones-Reswick-PID, and IMC-PID extracted for the first fifteen (15) seconds to check the system behaviour over a short time interval is as shown in Figure 5; it was observed that all the controllers used were stable for the first 15 sec except for Cohen-Coon PID controller.  Figure 6 showed that ZN-PID controller was stable from 20 to 81 sec but crashed at 89.54sec. The CC-PID controller response was slightly stable from 11 to 13 sec and the UAV crashed at 27.36 sec. CHR-PID controller was stable between 22 to 80 sec, but later crashed at 85.82 sec. The pitch of UAV using IMC-PID controlled system showed that UAV was stable throughout the specified duration of 90 sec without wobbling. When ZN-, CC-, CHR-and IMC-PID control methods were used; altitudes of 791.2814, 87.9941, 791.0441 and 793.7952 ft. were reached respectively at a specified duration of 90 sec.
It can be deduced from the simulation result in Figure 7 that when IMC-PID was used, the UAV reached the highest desired altitude with acceptable stability as compared to Ziegler-Nichols PID, Cohen-Coon PID, and Control Theory and Informatics www.iiste.org ISSN 2224-5774 (Paper) ISSN 2225-0492 (Online) Vol.9, 2020 9 Chien-Hrones-Reswick-PID within the same duration of time. Ziegler Nichols(Light-Blue) and IMC (Blue) tuned PID controller

Conclusion
Thispaper presentsthe dynamic equations of quadrotor Unmanned Aerial Vehicle (UAV).An efficient method of controlling quadrotor UAV was employed and simulated in MATLAB and X-Plane environment and the result was evaluated. The pitch and altitude of the simulated system were analyzed and the results obtained from IMC-PID controlled quadrotor UAV gave better performance over ZN-, CC-and CHR-PID control methods in terms of pitch and altitude. This work will find application in aircraft production companies and aviation industries to further endure quality production and safety of lives and properties. Future workswould focus on implementing hybrid control technique for intense weather conditions.