A Self-Tuning Fuzzy Logic Controller for Aircraft Roll Control System

In this paper, an aircraft roll control system based on autopilot operating conditions is modeled and simulated using Matlab/Simulink. The modeling phase begins with the derivation of required mathematical model to describe the lateral d irectional motion of an aircraft. Then, Linear Quadratic Regulator (LQR), Fuzzy Logic Controller (FLC) and Self-Tuning Fuzzy Logic Controller (STFLC) are applied for controlling the roll angle o f the modeled aircraft system. Simulation results of ro ll controllers are presented in time domain and the results obtained with STFLC are compared with the results of FLC and LQR. Finally, the performances of roll control systems are analysed in order to decide which control method gives better performance with respect to the desired roll angle. According to simulation results, it is shown that STFLC deliver better performance than FLC and LQR.


Introduction
The development of autopilots closely followed the successful development of powered man-carry ing airplane by the Wright brothers [1]. The first auto matic flight controller in the world is designed by the Sperry brothers in 1912. The Sperry brothers developed an autopilot that is sensitive to the movements of an aircraft. When an aircraft deviated fro m a part icular flight route, this autopilot adjusted the pitch, roll and heading angles of an aircraft. Then, in 1914, the Sperry brothers demonstrated this autopilot at the Paris air-show. To demonstrate the effectiveness of their design, Lawrence Sperry t rimmed his airplane for straight and level flight and then engaged the autopilot [1]. Since then, the fast advancement of high performance military, co mmercial and general aviation aircraft design has required the develop ment of many technologies; these are aerodynamics, structures, materials, propulsion and flight controls [2]. Currently, the aircraft design relies heavily on automatic control systems to monitor and control many of the aircraft subsystems [2]. Therefore, the development of auto matic control systems has played an important role in the growth of civil and military aviation [1]. Modern aircrafts are much mo re complex and includes a variety of automatic control system.
Generally, an aircraft is controlled by three main surfaces. These are elevator, rudder and ailerons. Pitch control can be achieved by changing the lift on either a forward or aft control surface. If a flap is used, the flapped portion of the tail surface is called an elevator. Yaw control is achieved by deflecting a flap on the vertical tail called the rudder and roll control can be achieved by deflecting small flaps located outboard toward the wing tips in a d ifferential manner [1]. These flaps are called ailerons. Elevator, rudder and ailerons are depicted in Figure 1. The two ailerons are typically interconnected and both ailerons usually move in opposition to each other. The ailerons are used to bank the aircraft. The banking creates an unbalanced side force co mponent of the large wing lift force which causes the aircraft's flight path to curve [3]. Thus, when the pilot applies right push force on the stick, as the aileron on the right wing is deflected upward, the aileron on the left wing is deflected downward. As a result of this, the lift on the left wing is increased, wh ile the lift on the right wing is decreased. So, the aircraft performs a rolling motion to the right as viewed fro m the rear of the aircraft.
The rolling motion of an aircraft is controlled by adjusting the roll angle. In this study, an autopilot is designed to control the roll angle of an aircraft. In aircraft modeling phase, the aerodynamic forces (lift and drug) as well as the aircraft's inert ia are taken into account [4]. The actual model is a third order nonlinear system, which is linearized about the operating point [4]. A modern linear quadrature regulator (LQR) and intelligent controllers (FLC and STFLC) are developed for the roll control of the modeled aircraft system. Performances of these controllers are analysed with respect to the desired roll angle. Co mparison of these control theory is presented and discussed in terms of performance analysis.

Modeling of A Roll Control System
The equations governing the motion of an aircraft are very complicated as a set of six nonlinear coupled differential equations. However, under certain assumptions, they can be decoupled and linearized into the longitudinal and lateral equations. Ro ll control is a lateral problem and this work is developed to control the roll angle of an aircraft for ro ll control in order to stabilize the system when an aircraft performs the ro lling motion. The ro ll control system is shown in Figure 2.  In this figure, Y b and Z b represent the aerodynamics force components,ϕ and δ a represent the orientation of aircraft (roll angle) in the earth-axis system and aileron deflection angle respectively. The forces, mo ments and velocity components in the body fixed frame of an aircraft system are shown in Figure 3 where L, M and N represent the aerodynamic mo ment components, the term p, q and rrepresent the angular rates components of roll, pitch and yaw axis and the term u, v and w represent the velocity components of roll, p itch and yaw axis.
Referring to Figure 2 and Figure 3, the rig id body equations of motion are obtained fro m Newton's second law, see [1]. But, a few assumption and approximation need to be considered before obtaining the equations of motion. Assume that the aircraft is in steady-cruise at constant altitude and velocity, thus, the thrust and drag cancel out and the lift and weight balance out each other. Also, assume that change in pitch angle does not change the speed of an aircraft under any circumstance [4]. Under these assumptions, the lateral directional motion of an aircraft is well described by the following kinematic and dynamic differential equations. (1) Equation (1), (2) and (3) are nonlinear and they can be linearized by using small-disturbance theory. According to small-d isturbance theory, all the variab les in the equation (1), (2) and (3) are replaced by a reference value plus a perturbation or disturbance, as given in equation (4).

(4)
For convenience, the reference flight condition is assumed to be symmetric and the propulsive forces are assumed to remain constant. This implies that, After linearization the follo wing equations are obtained, see [1].
The lateral d irect ional equations of motion consist of the side force, ro lling mo ment and yawing mo ment equations of motion. It is sometimes convenient to use the sideslip angle Δβinstead of the side velocityΔv. These two quantities are related to each other in the follo wing way; Using this relationship and if the product of inertia I xz =0, the lateral equations of motion can be rearranged and reduced into the state space form in the following manner. (10) For this system, the input will be the aileron deflection angle and the output will be the roll angle. In this study, the data from General Aviation Airplane: NA VION a [1] is used in system analysis and modeling. The lateral direct ional derivatives stability parameters for this airplane are given Table I. Before obtaining transfer function, let's plug in nu merical values given Table I by using equation (10). This work presents the roll control schemes for roll angle of an aircraft system. So, the rudder deflection g iven in equation (10) is not used.
(11) Transfer function fro m aileron deflect ion angle to roll angle is given by the follo wing equation. (12)

Design Process of The Proposed Controller
Fuzzy Logic Controller (FLC), Self-Tun ing Fuzzy Logic Controller (STFLC) and Linear Quadratic Regulator (LQR) are proposed for the roll control system and in this section; these controllers are described in detail.

Linear Quadratic Regul ator (LQR)
During last decades, a new approach to control system design has evolved. This approach is co mmonly called modern control theory. Linear Quadratic Regulator (LQR) is a method in modern control theory and it is an alternative and very powerful method for flight control system designing. The method is based on the manipulation of the equations of motion in state space form and makes full use of the appropriate computational tools in the analytical process [5]. LQR control system for the lateral direct ional control of an aircraft is shown in Figure 4.
The state and output matrix equations describing the lateral d irectional equations of motion can be written as the following equation.
And that all of the four states x are available for the controller. The feedback gain is a mat rix K of the optimal control vector.
(14) So as to minimize the perfo rmance index, Where Q is state-cost matrix and R is performance index matrix. For this study, R=1 and Q=C T xC where C is the matrix fro m state equation (13) and C T is the matrix transpose of C. For designing LQR controller, the value of the feedback gain matrix, K, must be determined. The following block is shown how to determine the values of K.

Modern Control Systems
Design Package MATLAB  Figure 5 as the weighting factor equals 75. To obtain the desired output in other words to reduce steady-state error, one must use a feed-forward scaling factor called N. Because, the full-state feedback system does not compare the output to the reference, it compares all states multip lied by the feedback gain matrix to the reference. These are shown in Figure 4. So, the reference must be scaled by scaling factor N. The scaling factor N is obtained from Mat lab function that is a designer-defined function in m-file code. In this case, N=-8.6603 is determined.

Fuzzy Logic Controller (FLC)
In most research literature, a fu zzy controller system is commonly defined as a system that emu lates a human expert. In this case, the knowledge of the human operator wou ld be put in the form of a set of fu zzy linguistic rules. These rules would produce an appro ximate decision in the same manner a human would do. The fu zzy controller is co mposed of four elements. These are fuzzificat ion, rule base, inference mechanis m and defu zzification. A block diagram o f a fu zzy control system is shown in Figure 6.
In Figure 6, the values of error (e(k)) and its change (Δe(k)) occurring during the operation of the system form the crisp inputs of the system. These two inputs defined as in (16) and (17).
(16) (17) r(k), y(k) and k are exp ressed as the reference input, the actual output of the system and the sampling step respectively. These crisp inputs e(k) and Δe(k) are converted to fuzzy membership value on the fu zzy subsets. There are three main fu zzy subsets defined as negative (N), zero (Z) and positive (P). Depending on these subsets the number of rules can be derived.
These fuzzy membership values are used in the rule base in order to execute the related rules so that an output can be generated. A rule base consists of a data table which includes informat ion related to the system. As an examp le, if a fu zzy logic controller with nine rules is desired to realize, these rules can be defined in Tab le II. An inference mechanism emu lates the expert's decision making in interpret ing and applying knowledge about how best to control the plant. Adefuzzification interface converts the conclusions of the inference mechanis m into the crisp inputs for the process. A general overlooked v iew of the FLC is given in Figure 7 where the processes fro m inputs e and Δe to output Δu are shown. The input data blocks to represent fuzzy membership functions for the error e, error change ∆e and the controlled output change ∆u are shown in Figure 7. The user is able to edit and change the parameters of the membership functions on this stage without going into the detail of the FLC.

Self-Tuning Fuzzy Logic Controller (STFLC)
STFLC is developed to improve the controller performance by tuning the range values of fuzzy subsets of error and its change used in direct fuzzy controller. The symbols of on-line changing fuzzy gains are G1 and G2 respectively for error (e) and change of error (Δe). In order to adjust the gain parameters G1 and G2, two d ifferent fu zzy logic controllers are used [8]. The inputs of gain-adjusting FLCs are system output and error signal which is the difference between system output and reference signal. Structure of self-tuning FLC is shown in Figure 8

Simulation and Results
An aircraft roll control system is simu lated using LQR, FLC and Self-Tuning FLC in order to present and discuss simu lation results. Simu link model of the system with these controllers is shown in Figure 9. For all simu lations, the reference value is selected as 0.15 radian wh ich is equal to 8.625 degrees. Firstly, the various membership functions of FLC are examined and the best membership function for this system is determined. Figure 10 shows the comparison of membership functions. It is observed that the triangle membership function gives the best response as compared to others. After determining the membership function, the various rule tables of FLC is examined to understand which fu zzy rule table gives better response. FLC with nine rules gives better response than others. It is shown in Figure 11. Obtained fu zzy ru le table and membership function which g ives the best response for this system is used with both FLC and Self-Tuning FLC. Then the system responses of LQR, FLC and Self-Tuning FLC are p lotted on the same graph for a better comparison. The system responses with these controllers are shown in Figure 12. It is observed that STFL controller gives faster response as compared to FLC and LQR in terms of rising time. But, the results clearly demonstrate that LQR controller is occurred overshoot more than FLC and STFLC.

Conclusions
In this paper, the model of an aircraft roll control system that is helpful in developing the control strategy for an actual aircraft system was designed for Matlab/Simulink environment and control methods were proposed for this system. LQR, FLC and Self-Tuning FLC are successfully designed and presented for this system. As a result, among these controllers, STFLC gives the best performance in terms of rising time, settling time, steady-state error and percent overshoot. According to the results from simu lation and analysis, STFLC has good and acceptable performances.