Fractional order PID controller adaptation for PMSM drive using hybrid grey wolf optimization

Received Feb 10, 2021 Revised Mar 16, 2021 Accepted Apr 14, 2021 In this paper, the closed loop speed controller parameters are optimized for the permanent magnet synchronous motor (PMSM) drive on the basis of the indirect field-oriented control (IFOC) technique. In this derive system under study, the speed and current controllers are implemented using the fractional order proportional, integral, and derivative (FOPID) controlling technique. FOPID is considered as efficient techniques for ripple minimization. The hybrid grey wolf optimizer (HGWO) is applied to obtain the optimal controllers in case of implementing conventional PID as well as FOPID controllers in the derive system. The optimal controller parameters tend to enhance the drive response as ripple content in speed and current, either during steady state time or transient time. The drive system is modeled and tested under various operating condition of load torque and speed. Finally, the performance for PID and FOPID are evaluated and compared within MATLAB/Simulink environment. The results attain the efficacy of the operating performance with the FOPID controller. The result shows a fast response and reduction of ripples in the torque and the current.


INTRODUCTION
Recently, a wide popularity of the applications of permanent magnet synchronous motor (PMSM) has been gained due to many advantages when compared with the other electric motors. These advantages are such as the significant increase of the machine efficiency, the power density, and the torque-current ratio for a wide speed range. These advantages make the PMSM more suitable for many applications such as electric vehicles and hybrid electric vehicles which require motor with light weight and occupying less space. Both the direct torque control (DTC) and the indirect field-oriented control (IFOC) are the most efficient controller techniques, which are used in the PMSM and voltage source inverter for many industrial applications. The IFOC theory depends on decoupling the current-torque component and flux-current component. In case of PMSM, it is equivalent to separately excited direct current motor which can be controlled easily. The main advantage of IFOC is the maximum torque which can be extracted from PMSM by controlling the direct current component to be zero. The IFOC with proportional-integral (PI) controller is easy to implement [1], [2].
It is commonly desired to ascertain the three-phase voltage source with variable voltage magnitude and frequency from direct current (DC) voltage source, in which the SVPWM is used in motor drive systems to enhance the required drive performance due to its advantageous as low harmonic content, fixed switching frequency, and 15% increase in utilization of the DC voltage source as compared to pulse width modulation (PWM) [3], [4].
For wide applications in the industry such as automotive applications, and home appliances control, the most popular control methodology in the control systems of industrial processes, the most applicable control approach is the proportional-integral-derivative controller. PID is simple configuration and easy implementation in the field. One of the disadvantages of PID controllers is the sensitivity to the variations in the system parameters and set point variations of speed and load. Therefore, the PID controllers are not completely efficient for nonlinear variable speed drive systems as electric vehicles and motor drive system [5].
Recently, the fractional order PID (FOPID) controllers, which are in the form PI^ʎ D^µ, have received widespread attention since there are many physical systems can be accurately modeled and represented using partial calculus [6]. The FOPID is distinguished over the conventional PID controller by less steady state error, less over-shot, less ripples, less affected by variations in the controlled plant parameters and system disturbances [7]. The FOPID controller is used in many applications such as induction motor, PMSM and direct current motor drives [8]- [10]. FOPID control system concept introduced by Oustaloup and Podlubny with integrator and differentiator of fractional order ʎ and µ, respectively [11]- [13]. The presence of additional control parameters (ʎ, µ) in fractional order controller (FOC) improves nonlinear system performances. However, the presence of these more control parameters in FOPID controller makes the selection of the optimal parameters more difficult. Therefore, the optimization techniques are required to obtain the optimal controller parameters.
The optimization algorithms are classified into rule-based group, numerical group, and analytical group. The numerical optimizations include particle swarm optimization (PSO), genetic algorithm (GA), and ant colonies (AC) [14]- [18]. These optimization algorithms are called heuristic optimization techniques. The ability of heuristic algorithms to search a random and wide region of the solution domain is the main advantageous that sets it apart from other methods, which leads to converge to the optimum solution and can be used in FOPID controller optimization process [19]. The FOC parameter optimization become an interesting point for research to enhance the operating performance of the derives [20]. The optimal FOC parameters using GA is introduced in [21], [22]. The results showed that the FOPID controller is superior when compared to the conventional one at the same conditions. A recent design and controller parameters tuning algorithms are reported in [23], the author shows that there are some difficulties in the conventional PID systems which still need to be solve. Control of heat diffusion system using FOC is appeared in [24], [25], the results showed that the FOC can handle a case of low temperature dynamic and superior system performance. DC rotor control in flight system based on fractional order (FO) system is proposed in [26], the controller parameters are tuned online using the stochastic multi-parameters divergence optimization. The response of the real non-linear system is comparable to the response of the FO reference model and PID controller with parameter optimization. The optimal FOPID controller parameters are obtained by using the chaotic atom search optimization for speed control in DC motor. The result shows that the system response in case of FOPID controller is better in transient as it performs with smaller settling time, overshoot, and rise time [27]. In [28], the FOPID controller and the conventional PID controller gains are optimized using four different objective functions. The optimization was processed using PSO algorithm. The results showed that PSO-FOPID attained better performance than PSO-PID controller. The optimal parameters of FOPID controller and conventional PID controller are obtained by using grey wolf optimizer (GWO). The performance shows that the FOPID controller is the best when compared to the performance of traditional PID in terms of settling time, rise time and overshoot [29]. The hybrid grey wolf optimizer (HGWO) is implemented as a hybrid algorithm from GWO, PSO and GA. HGWO is considered as accurate and fast optimization technique which takes the advantages of GWO ability for finding out the search space, memorization, experience exchange among particles from PSO, and mutation and crossover in GA [30].
In this paper, HGWO is used to obtain optimum parameters (k_p,k_i,k_d,ʎ and µ) for FOPID controller and (k_p,k_i,k_d ) for conventional PID controller in PMSM drive based IFOC technique and SVPWM inverter. The PMSM, IFOC, and FOPID equations are derived, then the drive system is implemented using MATLAB-SIMULINK for PID and FOPID. HGWO is used to generate the optimal controller parameters which minimize the speed error and reduce the ripples in torque and current. The optimization process is applied for both PID and FOPID under the same objective function and variables limit value. The system performance is tested with PID controller and FOPID controller under various operating conditions of setpoint speed and load torque.

MODEL OF PMSM AND FIELD-ORIENTED CONTROL SYSTEM
The surface mounted PMSM can be modeled in the rotating d-q reference frame as [31], [32]: = . (4) in the surface mounted PMSM = ,therefore: where , , and are the voltage and the current of stator in the d-q frame, respectively. , , , and are the stator resistance, stator flux, and flux in d-q frame, respectively. and are the d-q inductance, respectively.
is the motor speed. is the permanent magnet flux, is the electromagnetic torque, P is the pole pairs, is the stator flux, is the load torque, is the inertia of motor, and load and is the coefficient of friction.
The IFOC theory is based on regulating the stator current represented by the quadratic current iq and direct axis current id in the rotating reference frame. The electromagnetic torque is represented as a function in the current component, id and iq as included in (6). In the surface mounted PMSM, Ld equals to Lq, the electromagnetic torque equation can be reduced to (7) and the torque can be directly controlled by regulating the iq current component [33], [34]. The IFOC system shown in Figure 1, consists of two current controllers and one speed controller. The speed controller is designed concerning the torque (7) and (8), while the (1) and (2) represent current controllers in the d-q reference frame. Phases A and B of PMSM current are measured then accordingly phase C current is calculated. The Clarke and Parke transformations are used to transform the current , , and to current component and which represent the feedback to the current controllers. The speed controller input is considered the speed error (∆ ) which represents the difference between the setpoint ( * ) and measured mechanical ( ) speeds. The reference current * is created based on the regulated speed error using the speed controller. The current error signal ∆ is the difference between * and , while ∆ is the difference between * and . The error signals ∆ and ∆ are represent the input for the current controllers. These current error signals are regulated by the current controllers to produce the output voltage and . The signals , , and the rotor position θ are used to generate the SVPWM signals. The voltage vector is created using the SVPWM toward diminishing the speed error.
As the controller parameters selection is key performance of the drive system, HGWO is used to generate the optimum controller parameters that attain the minimum error. The GWO inputs are (∆ ), (∆ ), (∆ ), max( ) and the outputs are the optimal parameters of the speed and current controllers.

CONCEPT OF FRACTIONAL ORDER CALCULUS
The FO calculus is the general form of differentiation and integration with fractional differentialintegral order operator which can be defined as.
Where a, and t are real values that determines the fractional operator domain, the fractional order α is a non-integer real or complex number.
where ( ) is defined as.
The form of Riemann-Liouville definition is.
where h is the time interval, Г(.) is Gamma function [38] 4. FRACTIONAL PID CONTROLLER FOC ( ʎ µ ) is a general representation of the traditional PID controller, its differentiation order ʎ and integration order µ are real values which make the controlled system more robust [39], [40]. The FOPID transfer function is defined by (13).
where , , , and are proportional, differential, and integral coefficienta, respectively. ʎ and µ are the integration and differentiation degrees. Figure 2 introduces the general representation of the FOPID controller. The integral and derivative orders (ʎ and µ) are located on the x and y-axis, respectively. The transfer function represents a FOPID controller where the values of ʎ and µ are extended from integer values on the axis to a fractional value on the x-y plane as shown in Figure 3. The traditional PID controller is used as a specific case of a FOPID when the value of ʎ and the value of µ equal to one. The transfer function represents the PI controller if ʎ equals one and µ equals zero. The model represents a traditional PD controller when ʎ equals zero and µ equals one. Finally, if the value of ʎ and µ becomes zero the transfer function represents proportional (P) controller [41].

OBJECTIVE FUNCTION FORMULATION
The drive system quality depends on the value of controller parameters. Best adaptations of the controller parameters are the key to optimize the drive performance. The optimal parameters selection is attained using the optimization algorithms that ascertain the selected objective function at minimum values. The objective function in the current research is the root mean square error in the speed deviation ( (∆ )) from reference speed as in (14) considering the constraints in (15) to (18). The optimization algorithm proposes the parameters of the speed and current controller to attain the minimum error in speed within drive constrain limits as ripples in current and maximum current of the motor. where ∆ is the speed tracking error in rad/sec, ∆ is the error in q-component of the current, ∆ is the error in d-component of the current, rms is the root mean square, and abs is the absolute value.

HYBRID GREY WOLF OPTIMIZER (GWO)
GWO is an optimization algorithm on the basis of imitation of the gray wolves' social attitude toward searching and hunting of prey. Wolf hunting behavior can be simulated mathematically by (19) to (26). . GWO has been developed to enhance the performance for attaining optimum system parameters, several modifications are presented to improve the GWO performance [42], [43]. The optimization strategy of GA was added to obtain HGWO which improves the performance of the basic GWO algorithm [44]. PSO loop has been added to the hybrid algorithm of GWO and GA to save the best local and global positions. The local best positions of individuals ( ) and global best position of the swarm ( ) are used to adjust the location of individuals using velocity ( +1 ) depending on space between locations of individuals and best positions of the gray wolf as in (27) to (29). The fittest modified positions are saved for the use in the upcoming GA loop [45].
where the constants A and B belongs to the period [1.2, 2], the value of 3 and 4 belong to the period [0, 1], and is used to change the diversity. The loop of GA is used to update the individuals by selection, intersection, and mutation processes as in (30) and (31). GA algorithm is used to modify the best individuals which are obtained by the GWO and PSO loops, to preserve diversity and covering the search area in the best solution domain. The best individuals (parents) are chosen to produce new solutions (offspring). The best individuals survive and are the selected individuals for the upcoming iteration of GWO. The goal is to modify the values of , to enhance the algorithm effectiveness toward reaching an optimal solution [30]. The vector of the variables is presented in (32).
where γ is a random number ∈ [0,1], x is a vector of the controlled parameters, are the limits of the variable x, and ( , , , ʎ, µ) 1 is the speed controller parameters, ( , , , ʎ, µ) 2 and ( , , , ʎ, µ) 3 are the current controllers parameters. Figure 4 presents the main steps of the optimization procedure to minimize the error in the motor speed signal. The procedure starts with initialization of the GWO, PSO and GA parameters. Therefore, an iterative process is continued with three loops of GWO, PSO, and GA to optimize the control parameters. Table 1 presents the HGWO parameters that are used during optimization process.  Figure 4. HGWO procedure Table 2 shows the PMSM model parameters as presented in Figure 1. The drive system performance is assessed in case of convention PID and FOPID in terms of steady state error, rise time, over shot, torque ripples and current ripples. The system is represented and simulated in MATLAB/Simulink environment. The motor is considered to suddenly start at speed set point of 175rad/sec at fixed load 3.0N.m. The motor speed is suddenly decreased to 87.5rad/sec at t=1 sec and increased again to 175rad/sec at t=2 sec. HGWO is used to obtain the optimal controller parameters. The optimization procedures are done at the same operating conditions. Table 3 illustrates the limits of controller parameters, while the optimal controller parameters which obtained from HGWO algorithm are listed in Table 4 and Table 5 for conventional PID and FOPID, respectively.  The drive system speed response concerning the FOPID and PID controllers is depicted in Figure 5 (a). The motor starts from stationary at t=0 to track the reference speed. Figure 5 (b) shows the speed response at starting when the speed changed from zero to steady state value (175rad/sec). The FOPID generates a response which was able to reach the steady state faster with less rise time, less steady state time and less overshot when compared to PID response. The overshot is reduced form 4.8% in case of conventional PID controller to 0.6% in case of FOPID controller. The rise time is reduced from 0.0153 sec PID controller to 0.0061 sec in FPID controller as reported in Table 6. The torque variations for the FOPID and PID controllers are shown in Figure 6, the motor is loaded with constant torque of 3N.m from starting and remain unchanged during the simulation. The variation of the produced torque with the FOPID controller produces less ripples than torque variation when compared to the response with implementing the PID controller. The reduction was approximately 60% reductions in peakpeak torque ripples. Figure 7 (a) and Figure 7 (b) show the three-phase currents waveforms concerning both controllers in the time domain from 1.5 to 1.6 sec. The FOPID generates a current response with 60% less ripples content in the current signal as compared to PID response. Figure 8 shows the response of current component id when the drive is controlled with PID and FOPID. The results show that, the current id is controlled to be zero with ripples band. The ripples band in id current are less in case of FOPID than in case of PID.

CONCLUSION
FOPID controller and conventional PID controller for speed control in PMSM has been proposed in this paper. The controller parameters were obtained using hybrid grey wolf optimizer (HGWO) to minimize the speed error and generate fast response with less ripples in the drive response. The drive model, FPOID, and HGWO were modeled within MATLAB software. The optimization process was done under the same limits and constrains for FOPID and conventional PID controllers. The evaluated results proved the enhancement of drive system using the FOPID controller when compared to the traditional PID controller in terms of overshot, and response time. The overshot was reduced from 4.8% in case of PID controller response to 0.6% in FOPID response. The rise time is reduced from 0.0513 sec in PID-based controller performance to 0.0061 sec in FOPID performance. Furthermore, the drive response with FOPID controller was found competitive as attributed to less ripples in current and torque when compared to PID controller.