# Optimised Tuning of a PID-Based Flight Controller for a Medium-Scale Rotorcraft
###### Abstract
In the aircraft industry, the selection of controller gains is conducted by a committee comprising the flight control designers and the test pilots making reference to the Cooper-Harper rating scale and/or the ADS-33E. This results in sub-optimal gains for the aircraft. [PERSON] et al. [20] presented an autopilot system based on optimised PID controllers to reduce the pilot workload. The performance criteria were derived from DEF-STAN 00-0970 and the ADS-33E version of settling time. Simulations were conducted on a linearised model and showed convergence back to trim condition in both roll and pitch. [PERSON] et al. [21] also presented a linear model of a rotorcraft and applied a two-loop PID control system. The controller was tested on a test rotorcraft platform and was found to correctly stabilise the aircraft attitude, which is the function of the inner loop. No outer-loop test results were presented. [PERSON] et al. [22] developed a three-loop PID control system containing the attitude, velocity and position loops. On a linearised model, the PID gains were optimised using PSO. The optimisation was only conducted on the outer loop and the other loops were tuned manually, thereby reducing the number of optimisation parameters. The methods for flight control of single-rotor helicopters presented in the literature do not include optimisation in general. If they do, they are based on linearised models. However, linearised models have explicit optimal points, which defeats the purpose of using optimisation algorithms. Nonlinear optimisation has been applied to quadrotors. [PERSON] et al. [23] presented a nonlinear quadrotor model and used PSO to optimise PID controllers for roll, pitch, yaw and height. The PID controllers were then able to stabilise the quadrotor. Moreso, the investigation revealed that the SAE fitness function gave the best aircraft performance. [PERSON] et al. [24] investigated the PID control of a nonlinear quadrotor tuned with nature-inspired algorithms. These were then compared in numerical simulations to show the differences between the algorithms. This study used the ISE perfomance function, which was proven to give an acceptable rise time and overshoot. In another similar study,Cedro et al. [25] used an SAE performance function including the input signals scaled by a penalty factor \(\rho\). However, single-rotor helicopters are highly coupled and more dynamically complex than quadrotors. This could be the reason that this type of optimisation has not been attempted so far. In this paper, we propose that the flying and control objectives of the aircraft be defined analytically in an objective function and then optimisation algorithms be used to minimise the cost to find the best PID controller parameters applied directly onto a nonlinear helicopter. Therefore, the contributions of this paper are: (1) to design a closed-loop flight control system for the rotorcraft that closely relates to the pilot control based on six concurrent PID controllers; (2) and to develop a comparative study of computational intelligence optimisation algorithms to find the best PID controller parameters for the given flight regimes, also showing robustness to external disturbances. Even though related work has been presented for other types of aircraft, to the best of the authors' knowledge, this has not been investigated for a single-rotor helicopter. The rest of the paper is arranged as follows: Section 2 provides an overview of the system and the development of the 6-DOF rotorcraft model. The proposed flight controller and the optimisation algorithms are presented in Section 3. Section 4 presents controller validation through simulations and monitoring of the model of the rotorcraft and comparison of the different optimisation algorithms. Section 5 concludes the paper and offers recommendations for possible future investigations.