Research Journal of Applied Sciences, Engineering and Technology 7(7): 1116-1122, 2014 ISSN: 2040-7459; e-ISSN: 2040-7467 © Maxwell Scientific Organization, 2014 Submitted: April 16, 2013 Accepted: May 21, 2013 Published: February 20, 2014 Optimization of PID Controller for Brushless DC Motor by using Bio-inspired Algorithms 1 Sanjay Kr. Singh, 2Nitish Katal and 3S.G. Modani Anand International College of Engineering, Jaipur, Rajasthan, India 2 Department of Electronics and Communication Engineering, Amity University, Rajasthan, India 3 Malaviya National Institute of Technology, Jaipur, Rajasthan, India 1 Abstract: This study presents the use and comparison of various bio-inspired algorithms for optimizing the response of a PID controller for a Brushless DC Motor in contrast to the conventional methods of tuning. For the optimization of the PID controllers Genetic Algorithm, Multi-objective Genetic Algorithm and Simulated Annealing have been used. PID controller tuning with soft-computing algorithms comprises of obtaining the best possible outcome for the three PID parameters for improving the steady state characteristics and performance indices like overshoot percentage, rise time and settling time. For the calculation and simulation of the results the Brushless DC Motor model, Maxon EC 45 flat ф 45 mm with Hall Sensors Motor has been used. The results obtained the optimization using Genetic Algorithms, Multi-objective Genetic Algorithm and Simulated Annealing is compared with the ones derived from the Ziegler-Nichols method and the MATLAB SISO Tool. And it is observed that comparatively better results are obtained by optimization using Simulated Annealing offering better steady state response. Keywords: Brushless DC motor, controller tuning, genetic algorithm, PID controllers, PID optimization, simulated annealing, ziegler nichols INTRODUCTION The generic dc motors have high efficiency and have a high starting torque versus falling speed characteristics, which helps to counter the sudden rise in load and thus find their application in industries since ages (Katal et al., 2012). Since dc motors suffer from the deficiencies like: The lack of periodic maintenance Mechanical wear-outs Acoustic noise Sparkling Brushes effect, etc., so, the current focus has adapted the development of brushless direct current models The Brushless Direct Current (BLDC) motors are typically dc voltage driven permanent synchronous motors and are gaining grounds in aeronautics, medicine, consumer and industrial automation applications. The BLDC motors have better: Speed versus torque characteristics High efficiency High dynamic response Noiseless operation Low maintenance and many more (Padmaraja, 2003; Krause et al., 2002) and the best advantage in terms of higher ratio of torque obtained to the size of motor Proportional, Integral and Derivative-PID controllers are playing an imperative role in the industrial control applications. Because of their simplicity and wide acceptability, they are still the best solutions for the industrial control processes (Åström et al., 2001). Modern industrial controls are often required to regulate the closed-loop response of a system and PID controllers account for the 90% of the total controllers used in the industrial automation. The simple block level representation of the PID controller based system can be obtained as in Fig. 1. The general equation for a PID controller for the above figure can be given as Norman (2003): C ( s ) Kp .e ( s ) Ki e ( s ) dt Kd de ( s ) dt where, Kp, Ki and Kd = The controller gains C (s) = Output signal e (s) = The difference between the desired output and output obtained Corresponding Author: Sanjay Kr. Singh, Anand International College of Engineering, Jaipur, Rajasthan, India 1116 Res. J. Appl. Sci. Eng. Technol., 7(7): 1116-1122, 2014 Fig. 1: Block diagram of a PID control based system with unity feedback Fig. 2: Schematic diagram of a BLDC Motor In this study, the optimization of the PID controller gains has been carried out using Genetic Algorithms (GA), Multi-Objective Genetic Algorithm (MOGA) and Simulated Annealing (SA) in contrast to the ZieglerNichols (ZN) method and the automated tuning provided in MATLAB viz. SISO Tool. Then, these gain parameters can be optimally tuned with respect to the objective function, stated as “Sum of the integral of the squared error and the squared controller output deviated from its steady-state” (Goodwin et al., 2001). According to the results obtained in this paper, considerably better results have been obtained in the case of the Simulated Annealing (SA) when compared to those obtained by Genetic Algorithm, Multiobjective Genetic Algorithm, Ziegler-Nichols method and the MATLAB SISO Tool in respective the step response of the system. used. The schematic illustration of the considered system is shown in Fig. 2. Using Kirchhoff’s Voltage Law (KVL), the following equation is obtained: Vs Ri L. (1) where, Vs = The DC Source voltage i = Armature current Similarly while considering the mechanical properties, Newton’s second law of motion gives the relative dependence of torque of the system as the product of the inertial load, J and the rate of angular velocity, ωm, as: MATERIALS AND METHODS J Mathematical model of brushless DC motor: In this study the model of a BLDC motor has been considered, unlike the dc motor, the commutation of the BLDC can only be done by electronic control (Padmaraja, 2003). The operation of BLDC motor can be realized in many modes (phases), generally 3 phases. The main advantage of 3-Phase is better efficiency and quiet low torque and has best precision in control (Texas Instruments). In this study, the use of Maxon EC flat ф 45 mm, brushless, 30 Watt motor with Hall Sensors has been di e dt d m Ti dt Te k f m J (2) d m TL dt where, Te = Electric torque kf = Friction constant J = Rotor inertia ωn = The angular velocity TL = The supposed mechanical load 1117 (3) Res. J. Appl. A Sci. Eng. Technol., 7(7): 1116-1122, 2014 2 Table 1: Paraameters and units of o maxon motor Maxon motorr data Value at nom minal voltage Nominal voltage No load speedd No load curreent Nominal speeed Nominal torqque (max. continuo ous torque ) Nominal currrent (max. continuo ous current) Stall torque Starting curreent Maximum freequency Characteristiccs Terminal resistance phase to ph hase Terminal induuctance phase to phase p Toque constaant Speed constannt Speed/torque gradient Mechanical tiime constant Rotor inertia Number of phhases U Unit Valuue V R Rpm m mA R Rm m mNm A m mNm A % 12.0000 4370 151 2860 58.0000 2.1440 255 10.0000 77.0000 Ω m mH m mNm/A rppm/V rppm/mNm M Ms g 2 gcm - 1.2000 0.5660 25.5500 37.4400 17.6600 17.1100 92.5500 3.0000 P controller caalculated by zieglerTable 2: Paraameters of the PID nichhols method Valuue Ziegler nichools PID parameterss Kp 0.31660 Ki 31.30000 Kd 0.00008 Table 3: Paraameters of the PID D controller calcuulated by SISO baased autoomated designing SISO tuned parameters p Value Kp 0.2650000 Ki 17.8670000 Kd -0.0005886 where, ke = The T back emf kt = Torque T constannt Thhus the transferr function can be b obtained byy using the ratiio of the anguular velocity, ωm to source voltage v Vs, as: 1 ke G (s) Vs m . e .s 2 m .s 1 m (5) Sinnce the system m is symmetricaal and a three phase, thus coonstants used abbove in Eq. (5)) can be given as: Thhe Mechanicaal, τm (Tim me Constant) and Electriccal, τe (Time Constant): C m R.3 J ke kt andd e L 3 .R Thhe mathematiccal model of the Maxon BLDC B motor (Sabudin, 20012) can be modelled on the parameeters listed in Table T 1. Thhus by using the above lissted parameterrs, the value for fo Ke, τm and τn can be obtainned as: τe = 155.56 * 100 - 6 Kgm2; τm = 0.0171 andd Ke = 0.7763 v-sec/rad Therefoore, the transfeer function G (ss) becomes: G(s) 13.11 2.66 10 6 s 2 0.0171 s 1 (6) g us the open-loop trransfer Eqquation (6) gives function for the Brushhless DC Maxoon Motor. Design n of the PID coontrollers: Tuningg of PID gainss using zieglerr nichols: One of the most widely w used method m for thee tuning of the PID controlller gains is too use the opeen loop responnse as inferredd by Ziegler-N Nichols (ZN), yet y this methodd finds its in application a till the ratio of 4:1 4 for the first two peaks in the closed loop responsse (Goodwin et al., 2001), which leads to a oscillatoory response of o the system. Iniitially, the uniit step functioon (Fig. 3 andd 4) is derivedd and hence as suggested by the Ziegler-Niichols, the paraameters required can easily be b estimated ass given in Tablle 2. Fig. 3: Openn loop step respo onse of the systeem Fig. 4: Clossed loop step ressponse of the syystem with ZN-P PID conttrollers The electrical e torqu ue and the baack emf can be obtained ass: e k e m and Te k t m ( (4) MATL LAB SISO auttomated design ning: The SISO tool accelerrates the PID controller c desiggn by its GUI based interacttive compensattor tuning. Thee tuning can bee done interacttively by balanncing the poless and zeros onn Bode or root--locus plots, or can be optim mized by meetinng the pre-deffined time andd frequency domain d requireements by the system. The SISO S tuned PID D controllers for f the BLDC Motor can be seen in the Figg. 5 (Table 3). 1118 Res. J. Appl. A Sci. Eng. Technol., 7(7): 1116-1122, 2014 2 Table 4: Paraameters used in opttimization by geneetic algorithm Genetic algorrithm optimized paarameters Kp Ki Kd Vallue 5.00001 0.00039 5e-44 mplementation of the Thhe steps involvved in the im Geneticc Algorithms for f a control syystem are as folllows: s with SIS SOFig. 5: Clossed loop step reesponse of the system PID controllers Geenerating the initial, i random m population of the fixxed numbered individuals foor the declarattion of thee initial ranges for Kp, Ki andd Kd Foor the evaluaation of the fitness integgral it miinimizes the inntegral squaree error, follow wed by thee selection of the fittest individuals of o the poppulation Reeproduction am mong members of population Crossover of the reproduced chhromosome folllowed by the mutation operations andd the selection of the besst individuals i.e., i Survival of the Fittest Loooping the stepp 2 till the pre-ddefined converrgence is obtained o Thhe optimizationn of the system m has been dessigned and sim mulated in MATLAB M and Genetic Algoorithm toolboxx, with popuulation size of 100, scaattered crossovver and migratiion direction inn both sides. Table T 4 shows the GA optim mized PID parrameters and Fig. F 6 shows the t GA-PID sttep response off the system. PID controller opttimization usiing multi-objjective geneticc algorithm: Optimization O of PID’s using multiobjectivve genetic algoorithm aims at using the conttrolled elitist genetic algoriithm which boosts b obtaininng the better fitness f value of o the individuaals and if the fitness f value is i less, it still favors increassing the diverssity of the poppulation (Deb, 2001). Diverssity is controllled by the elite members of the poppulation; elitissm is controllled by Pareto fraction and at Pareto Fronnt also bound the number of individuals. Optimization of the PID controllers using u Multi-Objective Genetic G Algoritthm aims at im mproving the objective o functtion of the botth the objectivves used by obtaining o an opptimal Pareto solution. In thhis study, twoo objective funnctions have beeen used F1 (IT TSE) and F2 (O OS %): Fig. 6: Clossed loop step response of the sysstem with GA-PIID conttrollers s with MoobjFig. 7: Clossed loop step reesponse of the system GA--PID controllers ation using gen netic algorithm m: PID contrroller optimiza Since the designing d of the t PID controollers by ZieglerNichols methods, m gives an oscillatory response; hennce the controoller parameterrs obtained frrom ZN are not n optimum for f the directly y implementatiion for the plaant, so their orrganized optim mization must be b carried out, so that the better possible paarameters can be estimated and a implementted for the bestt performance of o the system. So, thee Genetic Algo orithms can bee used along with w the param meters obtain ned by the Ziegler-Nichools response, as a the parametter determinedd by ZN helps in the determ mination of the lower and uppper bound lim mits to be useed for the esttimation of parameters p usiing Genetic Allgorithms. where, ς = Thhe Damping rattio Firrst objective function f ITSE E i.e., Integral Time Square Error tries to minimize the larger l amplituddes by supresssing the persistent larger errors (Jean-P Pierre, 2004) while second objective function oveershoot percenttage; thus forciing the solution towards the global best sollution. Thhe system impplementation annd optimizatioon has been carried c out in MATLAB B and SIMU ULINK 1119 Res. J. Appl. A Sci. Eng. Technol., 7(7): 1116-1122, 2014 2 Fig. 8: (a) Average A distancee between indiviiduals of the gennerated populatioons and, (b) averrage pareto spreaad between indivviduals of thhe generated populations Table 5: Paraameters used in op ptimization by muulti-objective geneetic algorithm hm optimized paraameters Value Multi-objectivve genetic algorith Kp 5.2938 Ki 0.0042 4.5024ee-4 Kd Table 6: Paraameters used in opttimization by simuulated annealing Simulated annnealing optimized parameters Value Kp 5.0424 Ki 0.0040 3.0454ee-4 Kd bal Optimizatioon Toolbox. The T environmeent using Glob populationn size of 45 has been considered, c w with adaptive feeasible mutatio on function, heeuristic crossovver and the selection s of individuals on o the basis of tournamennt with a tourrnament size of 2. A hybrid function of o Fitness Goaal Attain (fgoaalattain) is ussed which furrther minimizzes the funcction after GA G terminates. After the op ptimization the PID parameteers ong with the coontroller responnse are shown in Table 5 alo in Fig. 7 annd 8. ntroller optiimization ussing simulatted PID con annealing: Simulated annealing is a globbal optimizatioon algorithm, as a the name suuggests, the muuse comes froom metallurgiic annealing, which involvves relation between b the relation r betweeen the staticcal mechanics and multivarriate optimizaation (Berrsim mas, f the technique involvving heating the t 1993). It follows material followed f by controlled coooling, fetchiing increased crystal c size and d reduced deforrmities. Fig. 9: C Closed loop stepp response of thee system with GA A-PID c controllers In Simulated Annnealing (SA), at each iterattion, a new pooint is randomlly generated and a its distancee from the cuurrent point is the functtion of probability distribuution with a scale s proportioonal to temperrature. The raandomly generrated points are a accepted iff they lower the t objective buut in order to help h the algoritthm to search for global sollution and to omit o the trapping of the alggorithm in loccal minima, some s points are a so chosen that they raisee the objectivee. With the advvent of algorithhm, the tempperature is deecreased leadiing in reduction of the exxtent of searcch to convergge the minimaa. Thhe optimizationn has been carried out in MAT TLAB and SIM MULINK envvironment withh the help of Global G Optimization Toolbox using Simulated Annnealing function. For simullated annealinng, the Boltzzmann w an exponenntially Annealling function has been used with updatinng temperaturee. The parameters obtainedd after optimizzation are in Table 6 and the response of thhe PID controlller with SA optimised o paraameters is shoown in 1120 Res. J. Appl. A Sci. Eng. Technol., 7(7): 1116-1122, 2014 2 Fig. 10: Plot for the best fun nction value of thhe simulated annnealing optimizaation Fig. 11: Com mpared closed lo oop step responsse of the ZN, SIS SO and GA-PID controllers Fig. 12: Com mpared variation n in rise and settlling times of thee ZN, SISO and GA-PID controlllers Table 7: Com mparison of the resu ults Methods of design d Overrshoot (%) Ziegler-nichools method 11.50 MATLAB SIISO tool 5.88 Genetic algorrithm 0.00 Multi-objectivve genetic 0.00 algorithm Simulated annnealing 0.00 Tr (sec) 0.0086690 0.0062230 0.0006643 0.0005560 Ts (secc) 0.0114400 0.0189900 0.001319 0.0010040 0.0005542 0.000888 Fig. 9. Figure 10 shoows the Plot for f the Best fuunction value of o the Simulated Annealing opptimization. TS AND DISCU USSION RESULT In this study, a dynamic d modell of a Maxon BLDC B Motor has been designed andd implementeed in 1121 Res. J. Appl. Sci. Eng. Technol., 7(7): 1116-1122, 2014 MATLAB along with the optimization using the various bio-inspired algorithms like Genetic Algorithm, Multi-objective Genetic Algorithm and Simulated Annealing. The value of parameters obtained using Ziegler-Nichols rules (Ziegler and Nichols, 1942) were used in the formation of the boundary limits for the intervals for the design parameters in soft-computing algorithms, to control the controller by minimizing the error and hence the determination of the optimum parameters for the plant. The computation of the PID parameters is done by the Ziegler-Nichols rules, SISO Design Tool, Genetic Algorithms, Multi-objective Genetic Algorithm and Simulated Annealing and their closed loop step responses are shown in Fig. 4 to 9. Figure 11 shows the comparative response of all the controllers over a single plot and Fig. 12 shows the comparative values of the various steady-state parameters. Table 7 shows the numeric comparison of the results of various steadystate parameters. From Table 7 and Fig. 11 and 12, it’s clearly evident that Simulated Annealing solutions present zero oscillatory response and reduced rise and settling times in contrast to the Ziegler-Nichols, SISO, Genetic Algorithm and Multi-objective Genetic Algorithm. Concluding, Simulated Annealing offers superior results in terms of system performance and controller output for the tuning of PID controllers. CONCLUSION The use of Simulated Annealing for optimizing the PID controller parameters as presented in this study offers advantages of decreased overshoot percentage, rise and settling times for the Maxon EC flat ф45 mm, brushless, 30 Watt motor. Results when compared with the other tuning mythologies as presented in this study, the Simulated Annealing has proved superior in achieving the steady-state response and performance indices. REFERENCES Åström, K.J., P. Albertos and J. Quevedo, 2001. PID control. Control Eng. Pract., 9: 159-1161. Berrsimas, D., 1993. Tsitsiklis: Simulated annealing. Stat. Sci., 8(1): 10-15. Deb, K., 2001. Multi-Objective Optimization Using Evolutionary Algorithms. John Wiley and Sons, Ltd., Chichester. Goodwin, G.C., S.F. Graebe and M.E. Salgado, 2001. Control System Design. Prentice Hall Inc., New Jersey. Jean-Pierre, C., 2004. Process Control: Theory and Applications. Springer, London, pp: 752. Katal, N., S.K. Singh and M. Agrawal, 2012. Optimizing response of PID controller for servo DC motor by genetic algorithm. Int. J. Appl. Eng. Res., 7(11). Krause, P.C., O. Wasynozuk and S.D. Sudhoff, 2002. Analysis of Electric Machinery and Drive Systems. 2nd Edn., IEEE Press, New York. Norman, S.N., 2003. Control Systems Engineering, JustAsk! Control Solutions Companion. 4th Edn., Wiley, Hoboken, N.J, pp: 96. Padmaraja, Y., 2003. Brushless DC Motor Fundamentals. Microchip Technology Incorporated. Retrieved from: www.microchip. com/stellent/idcplg?IdcService=SS_GET...1824... Sabudin, E.N.B., 2012. Development of position tracking of BLDC motor using adaptive fuzzy logic controller. M.A. Thesis. Faculty of Electrical and Electronic Engineering, Universiti Tun Hussein Onn, Malaysia. Ziegler, J.G. and N.B. Nichols, 1942. Optimum settings for automatic controllers. Trans. ASME, 64: 759-768. 1122