Fuzzy Adaptive Repetitive Control for Periodic Disturbance with Its Application to High Performance Permanent Magnet Synchronous Motor Speed Servo Systems

For reducing the steady state speed ripple, especially in high performance speed servo system applications, the steady state precision is more and more important for real servo systems. This paper investigates the steady state speed ripple periodic disturbance problem for a permanent magnet synchronous motor (PMSM) servo system; a fuzzy adaptive repetitive controller is designed in the speed loop based on repetitive control and fuzzy information theory for reducing periodic disturbance. Firstly, the various sources of the PMSM speed ripple problem are described and analyzed. Then, the mathematical model of PMSM is given. Subsequently, a fuzzy adaptive repetitive controller based on repetitive control and fuzzy logic control is designed for the PMSM speed servo system. In addition, the system stability analysis is also deduced. Finally, the simulation and experiment implementation are respectively based on the MATLAB/Simulink and TMS320F2808 of Texas instrument company, DSP (digital signal processor) hardware platform. Comparing to the proportional integral (PI) controller, simulation and experimental results show that the proposed fuzzy adaptive repetitive controller has better periodic disturbance rejection ability and higher steady state precision.


Introduction
Over the past few decades, the permanent magnet synchronous motor (PMSM) has high performance industrial servo applications owing to its high performance, such as compact structure, high air-gap flux density, high power density, high torque to inertia ratio and high efficiency [1][2][3][4][5][6][7][8][9][10][11][12][13].Due to these advantages, PMSM has gained wide spread acceptance in numerical control machine tools, robotics, rolling mills, aviation, and so on.It is well known that linear control schemes, e.g., the conventional proportional-integral (PI) control scheme, are already widely used in PMSM systems due to their easy implementation.However, the PMSM system is a nonlinear system with unavoidable and unmeasured disturbances and parameter variations [14]; it is difficult to achieve a satisfactory servo performance in the entire operating range when only using such linear control methods.Hence, nonlinear control methods become natural improved solutions for the PMSM system [15][16][17].
To enhance the system performance, in recent years, many advanced information theories has been developed for the control system, such as input-output linearization control [15]; adaptive control [18]; robust control [19]; sliding mode control [20], which has been applied for a fractional order chaotic system [21,22]; fractional order theory is also novel and interesting for researchers [23]; nonlinear model predictive control has been proposed for hydropower system [24]; back-stepping control [25]; finite-time control [26]; neural network methods are used in motion control system and a fruit classification system [27,28]; fuzzy theory [29,30], etc.These information theories can improve system performance from different aspects.
Note that in real industrial applications, many high-performance PMSM servo systems require high steady state precision.However, the presence of magnetic saliency in the rotor, magnetic saturation and measurement errors deteriorates the steady state servo performance, especially at high speeds, where the currents, voltages and switching frequencies are toward the limiting conditions.PMSM servo systems always face the steady state speed ripple problem, which is introduced from the above causes.In recent years, more and more researchers have reported some study work on the speed ripple minimization for the PMSM servo system.In [31], the authors utilized a model predictive control (MPC) for speed ripple minimization.In [32], the authors utilized an iterative learning control (ILC) for torque/speed ripple minimization of a brushless surface-mounted PMSM.However, the ILC scheme has its own limitations for real-time applications, especially at high speeds.
Torque ripple minimization (TRM) information theory based on parameter adaption in the current loop is reported in [33], and the speed loop adopted a PI controller.The work in [34] reported a torque ripple minimization (TRM) method based on a second linear controller with parameter adaption, and the speed controller adopted a filter where the filter parameter can be adaptively regulated by fuzzy logic.The work in [35] reported a periodic signal tracking problem for a mechanical system based on an adaptive repetitive controller, which can adaptively obtain the information of the reference signal period.They all consider only one frequency component for the steady state speed ripple, but in real industry applications, the speed ripple is not the only frequency component.
In addition, none of the works reported a compound controller, which combined fuzzy adaptive repetitive control and PI control for speed ripple minimization purposes.Fuzzy information theory has been a good adaptive theory and verified in many industry system [29,30].The main focus of this paper is to design an information theory of a fuzzy adaptive repetitive controller for reducing speed ripple.Different from other methods, firstly, this paper considers two speed ripple frequencies, which in relation to speed by theoretically analysis and experimental verification, does not have only one speed ripple frequency.Secondly, it designs the fuzzy adaptive repetitive controller in the speed loop for reducing the speed ripple, for which the controller parameter can be adjusted based on the fuzzy logic relationship with speed and steady state speed ripple frequency.
For the speed-regulation problem, in this paper, we propose a compound controller, which combines the fuzzy adaptive repetitive control and PI control for reducing the speed ripple of the PMSM servo system.By utilizing the proposed fuzzy adaptive repetitive controller, the steady state speed ripple minimum is improved significantly.The repetitive controller parameter is adaptively regulated by fuzzy logic control.The proposed information theory is implemented in real time using the digital signal processor (DSP) board TMS320F2808 of Texas instrument company (Dallas, TX, USA); comparative analyses with PI methods are also carried out by simulations and experimental results.
The remainder of this paper is organized in the following structure.The mathematical model of PMSM is described in the next section.In Section 3, the source of the speed ripple is obtained by Fourier analysis from steady state speed experiment data.In Section 4, the design of the fuzzy adaptive repetitive controller is presented in detail.A rigorous analysis of the PMSM servo system stability is also deduced.Simulation and experiment results on a PMSM servo system are presented in Section 5. Finally, conclusions are given in Section 6.

The Mathematical Model of PMSM
Here, we consider a surface-mounted PMSM; suppose that the magnetic circuit is unsaturated; hysteresis and eddy current loss are ignored; and the distribution of the magnetic field is sine space.Under this condition, in d-q and α-β coordinates, the ideal model of the surface-mounted permanent magnet synchronous motor is expressed as follows: where R s is the stator resistance, u d , u q the input voltages, i d , i q the d-axis and q-axis stator currents, L d , L q the d-axis and q-axis stator inductances, with L d = L q = L s , n p the number of pole pairs of the PMSM, ω the rotor angular velocity of the motor, ψ the flux linkage, T l the load torque, B the viscous friction coefficient, J the rotor inertia and θ the rotor position.From Equations ( 2) and (3), we know that currents of i d and i q are coupled, for achieving the vector control; we adopt the i * d = 0 control scheme, then the d-axis current and the q-axis current could be decoupled approximately.

Source of Speed Ripple for the PMSM Servo System
There are mainly three types of sources bring about the speed ripple, which are mainly described respectively as follows.

Speed Ripple from the Construction of PMSM
Cogging speed ripple: The cogging speed ripple is produced by the magnetic attraction between the PMSM of the rotor and the stator teeth.It is the tangential component of the attractive force between the rotor magnet and the stator teeth.When this cogging speed ripple component is superimposed on the machine-developed speed, it causes a periodic disturbance with the rotor speed [34].
Air-gap-flux harmonic: In a practical PMSM, an ideal sinusoidal distribution of the air-gap flux is hard to achieve because of manufacturing tolerance.As a result, non-sinusoidal air-gap flux interacts with the sinusoidal stator currents and produces a periodic speed ripple.

Speed Ripple from System Control Hardware
The real-time implementation of PMSM involves current sensors, A/D converters, speed sensors, rectifiers, inverters and other interface circuits.Mainly, the inaccuracies of these hardware systems cause the speed ripple.
Current measurement error: In a digital controller, the actual currents are fed to a DSP through Hall effect current sensors and A/D converters.The performance of the Hall effect current sensor has a limitation in a frequency range.Therefore, there might be a DC offset in the motor currents coming out from the current sensor, which will result in speed ripple.The current sensors scale down the actual currents, and the A/D converter output needs to be rescaled to get back the actual currents in the software.The scaling error of the stator current is inevitable, so it causes a periodic speed ripple [31].
The idea of vector control is to transform the three phase AC currents i a , i b , i c into their representations i d and i q , respectively, in the rotor reference frame using: where: T park = sin(ω e t + π/2) sin(ω e t − π/6) sin(ω e t + 7π/6) cos(ω e t + π/2) cos(ω e t − π/6) cos(ω e t + 7π/6) ( After Park transformation, the i d and i q components are taken as DC values, and the d-axis and q-axis controllers are designed to make them track their reference signals.The values of the three phase currents are usually obtained by using two current transducers and then converted to digital signals by A/D converters, which produce a DC offset voltage superimposed on the measured current signals.
The DC offset varies unpredictably due to the thermal effects of analog hardware, so it is difficult to separate the unwanted DC offset from the signal measurement.Consequentially, the measured three phase currents have DC offsets, and the expression is: where i a , i b , i c are the actual three phase current values, i a , i b , i c are the measured three phase current values including the undesired DC offset errors and i a , i b , i c denote the DC offset errors.
Applying the Park transformation to the actual three phase current values by Equation ( 6), the actual d-q axis current can be expressed as follows: where i d and i q denote the actual d-q axis currents, i d and i q are the periodic disturbances due to the offset errors i a , i b and i c , where: From Equation ( 8), the frequency of the periodic disturbance frequency is the same as the electrical speed of PMSM.When the motor steady state speed is running at the desired speed, the periodic frequency is fixed.From the experiment testing of Figures 1-6 for the PI controller, the reference speed is given as the running of 50 rpm, 1000 rpm, 2500 rpm, respectively; the oscillation frequency due to the offset errors is 22 Hz, 418 Hz, 1046 Hz; so we can conclude that this periodic disturbance component is generated by current bias errors.
Speed measurement error: The rotor speed is measured by a digital encoder, which has a limitation on resolution.To get the actual rotor speed, the number of pulses, which is the output of the encoder interface, needs to be multiplied by a scaling factor.Therefore, a speed ripple that is caused by the speed measurement is also inevitable.In addition, if the frequency of the periodic disturbance is within the bandwidth of the speed loop, the steady state speed will oscillate at the same frequency as the periodic disturbance [34].
DC link voltage ripple: Another major cause of speed ripple is DC-link voltage ripple; the DC-link voltage of the inverter usually comes from three-phase diode rectifier and filter capacitor, which is almost impossible to be free from ripple.Therefore, it also leads to the periodic speed ripple with the ripple frequency.

Speed Ripple from the Control Input
Current control input: In a current controller, the actual motor currents are forced to follow the reference current signals within a limited bandwidth.Therefore, the actual motor currents are not really sinusoidal, although the command currents are purely sinusoidal.Thus, the current controller generates periodic speed disturbance for the PMSM servo system [34].

Fuzzy Adaptive Repetitive Controller Design and Stability Analysis
The general structure of the PMSM servo system is shown in Figure 7.The overall system consists of a PMSM with load, space vector pulse width modulation (SVPWM), a voltage-source inverter (VSI), a field-orientation mechanism and three controllers.The system controllers employ a structure of cascade control loops, including a speed loop and two current loops.Here, PI controllers, which are used to stabilize the d-axis and q-axis current errors of the vector-controlled drive, are adopted in the d-axis and q-axis current loops.For dealing with steady state periodic disturbances of speed, here, the fuzzy adaptive repetitive controller is designed in the q-axis speed loop.As can be seen from Figure 7, the rotor angular velocity can be obtained from the measurements.Currents i d and i q can be calculated from i a , i b and i c (which can be obtained from measurements) by Clarke and Park transformations.
Block diagram of the PMSM servo system based on Fuzzy Adaptive Repetitive Controller (FARC) .

Modified Repetitive Control Strategies
The basic information theory structure of the traditional repetitive controller is shown in Figure 8.The concept of repetitive control theory originates from the internal model principle [36], so that the controlled output can track the reference input signal without steady state errors if the internal model, which generates these reference signals, is included in the closed-loop control system.For example, if the control system is required to obtain a zero steady state error for tracking sinusoidal input, the model of the sinusoidal transfer function (i.e., ω 2 /(s 2 + ω 2 )) where ω is the corresponding angular frequency should be included in the closed-loop system.In order to implement a repetitive control system, a periodic reference signal must be generated, which is included in the system controller.Its digital implementation includes a delay periodic and positive feedback, which is equivalent to a periodic signal generator, where K rep is the controller gain, as shown in Figure 9.
However, in practical applications, this traditional repetitive control scheme usually leads the control system to instability because it amplifies many high frequency harmonics, so the closed-loop control system should have a limited bandwidth in order to avoid tracking the high frequency harmonics.Indeed, there is no need to take into account tracking the high frequency component.For example, in this PMSM servo system, the low frequency component is the main frequency in the steady state speed harmonics.In order to avoid tracking high frequency harmonics, some filters need to be introduced in the repetitive control scheme of Figure 9, either in the feedback path or in cascade to the repetitive control path, as shown in Figure 10.
In this paper, we consider first the main frequency component and second the main frequency component in the steady state speed disturbance; the G f (s), which regulates the control system phase margin, is to guarantee closed-loop system stability.The modified repetitive control scheme adopted in this paper is theoretically equivalent to the scheme of Figure 11, with

Fuzzy Adaptive Repetitive Controller Design
The block diagram of the proposed compound information theory structure is shown in Figure 11.A compound controller is combined with the fuzzy adaptive repetitive controller and the PI controller in parallel and the sum of their output form the actual q-axis current reference i * q .
i * q = i * q pi + i * q rep (11) Due to the reduced influence of speed ripple, a PI controller is adopted for the d-axis current loop.At steady state, the tracking speed error is zero; the output of the q-axis PI control part (i * q pi ) is constant; and the output of fuzzy adaptive repetitive controller part (i * q pi ) is a periodic signal.Several experiment results have verified that the proposed control structure is particularly suited for an effective digital implementation, as discussed here.While the PI control part guarantees the dynamic character of the control system, the repetitive controller part is only aimed at the reduction of periodic speed errors, which the PI control is not able to compensate for due to its limited bandwidth.The contribution of the repetitive control, while being essential for the speed ripple compensation, remains a few percent in the total current reference.Moreover, during transient conditions, the output of the repetitive control part does not change significantly.
The repetitive controller part has been obtained by adopting the structure in Figure 10, with a transfer function given by: where , Q 1 (s), Q 2 (s) includes a low-pass filter.The filter improves the stability margin, by reducing the repetitive control gain at high frequency.
M 1 , M 2 are the ratios between the periods T rep1 , T rep2 of the alternating component of the q-axis speed ripple and the sampling period T c .Since M 1 , M 2 must be and integer, the sampling time must be an exact sub-multiple of period T rep1 , T rep2 .The following relation links the mechanical speed ω m , T c and M 1 .
In this paper, we consider the dominant frequency ω rep1 and the second dominant frequency ω rep2 .
where ω rep1 , ω rep2 is the dominant harmonic component of the current reference with respect to the speed ω m .According to the relationship of speed and the two frequency components of steady state speed ripple, from the above experiments and analysis, we can conclude that the speed ripple frequency is variable when speed reference is changed.In practice, when speed ω m is variable, T rep1 , T rep2 are theoretically supposed to be linearly tuned with the change of speed ω m .Considering the controller parameter regulation problem and the parameter n 1 and n 2 may be not the linear in high and low speed range, this paper designs a fuzzy rule of one input and two outputs.Some appropriate experimental tests should be done to help to decide the tuning expression for the parameter.The membership functions of the two fuzzy sets are shown in Figures 12 and 13.We design a fuzzy logic method for adaptively regulating the parameter of the repetitive controller; the fuzzy logic relationship is designed as below.Then, the fuzzy inference engine is chosen to describe the auto-tuning function for the repetitive controller parameter.The fuzzy logic contains four components: fuzzifier, rule base, inference engine and defuzzifier.
• Fuzzy sets can be represented as membership function µ A that associates with ω m where µ A (x i ) = 1, for x = x i and µ A (x i ) = 0, for x = x i .
• The fuzzy rule base is a collection of IF-THEN rules.X i and Y i are input and output variables.
• The fuzzy inference engine is a key component in the fuzzy logic controller; it aggregates the IF-THEN rules stored in the knowledge base.It provides a mapping from the input fuzzy sets to the output ones and µ B (y) = minµ A (x i ).• Defuzzification is the last step to get the final output value; it adopts the centroid method and is expressed as y = ∑ y l µ B l(y) ∑ µ B l(y) .The PI controller is designed as Equation (18).

Stability Analysis of the Closed-Loop System
In order to understand the PMSM servo system stability of the proposed control scheme, because the current loop has a fast response, let us focus on the q-axis speed loop.Under the assumption of ideal decoupling between the d-axis and q-axis, the stability analysis will be first obtained on a case study, by assuming a reference speed, which will produce two frequency components and yield the M 1 and M 2 values respectively by fuzzy information theory.Then, the analysis will be extended to different speeds and M 1 , M 2 values.Actually, the analysis of the stability under varying motor speed is quite involved, since the fuzzy adaptive logic is equivalent to the functions of parameters M 1 , M 2 and T c and the motor speed, which is theoretically a function of the repetitive control.In practice, it is possible to neglect the contribution of repetitive control to the motor speed variations, so we do not consider the fuzzy logic control part, then simplify the stability analysis.
The transfer function of Equation ( 26) is closed-loop poles of the fuzzy adaptive repetitive control system; stability can be performed looking at the magnitude of the root of the system of Equation ( 26).If all of the roots have a magnitude less than one, then all poles lie within the unity circle and the control system is stable.The overall stability analysis of the closed loop system can be deduced by the controller of Equation (11), assuming that yields a stable control system; a sufficient condition for the closed loop servo system stability is given as follows.
satisfied, the closed-loop system stability of the proposed control scheme is ensured.
Proof .Q 1 (s) and Q 2 (s) denote the low-pass filter; G c (s) denote the PI controller; G R (s) denote the compound controller; G f (s) denote the repetitive controller compensator.
From the PMSM model, suppose the current can track the reference signal; the general model of PMSM is deduced as follows: where d(t) = − Bω J − T L J + k t (i q − i * q ); we do not consider the d(t).Therefore, the general model of PMSM is described as follows: The speed error equation is: where: ),

M(s) M(s) + A(s)B(s)
where: Denote: then it yields which yields: where the system stability of the proposed control scheme for the closed-loop PMSM servo system is ensured.
Remark 1.The proposed information theory can also be extended to the application of induction machines, reluctance machines, and so on.From the theory analysis, we also can know that the repetitive controller includes the part of s/(s 2 + w 2 ); this is the main cause for why it can deal with periodic disturbances, which is also originated from the internal model principle.The propose method is based on this basic ideal and because of the unknown ripple frequency in the PMSM servo system; so the fuzzy adaptive repetitive controller is proposed in this paper.Compared to the traditional repetitive control; the method has the advantage that it can reduce the ripple influence of the first and second frequency automatically.

Simulation Results
The parameters of the PMSM used in the simulation are given as: rated power P = 750 W, rated voltage U = 200 V, number of poles n p = 4, armature resistance Rs = 1.74 Ω, stator inductances L d = L q = 0.004 H, viscous damping B = 7.403 ×10 −5 N•m•s/rad, momentum of inertia J = 1.78 × 10 −4 kg•m 2 , rated speed n = 3000 rpm, rotor flux linkage ϕ = 0.1167 wb, rated torque Tn = 2.5 N•m.This PMSM system under these two control schemes, the fuzzy adaptive repetitive control method and the PI control method, are simulated by MATLAB/Simulink (Version 2010), which Equations ( 1)-(3) used to model the motor behavior.
The simulations of the result are given from Figures 14-16.From the result, the simulation shows us that when the speed reference is 50 r/min, 1000 r/min and 2500 r/min, the speed ripple may be reduced obviously.The simulation proves the effectiveness of the proposed fuzzy adaptive repetitive controller.

Experiment Results
To evaluate the performance of the proposed method, an experiment setup system for the speed control of a PMSM servo system is built.The configuration and experimental test setup are shown in Figure 17.All of the speed control algorithms, including the SVPWM technique, are implemented by the program of the DSP TMS320F2808 with a clock frequency of 100 MHz, using the C-program 2010.The speed and current loops sampling periods are 250 µs and 100 µs, respectively.The saturation limit of the q-axis reference current is ± 9.42 A. The PMSM is driven by a three-phase PWM inverter with an intelligent power module with a switching frequency of 10 kHz.The phase currents are measured by Hall effect devices and are converted through 12-bit A/D converters.An incremental position encoder of 2500 lines is used to measure the rotor speed and absolute rotor position.Because it has one input and two output fuzzy logic control, so the proposed method does not need much calculation; it need about 65 µs time and 0.02 K memory, but the speed loop has a 250 µs control period.The various speed reference is given respectively at 500 r/min, 1000 r/min and 1500 r/min, the fuzzy adaptive repetitive controller can adjust the parameter of the repetitive controller; then, we can verify the control scheme.From the experiment result of Figures 18-20, we can conclude that the speed period disturbance can be adaptively reduced after the implementation of the proposed control scheme.From Figures 21-23 for the frequency spectrum, the first frequency amplitude and the second frequency amplitude are decreased obviously.From Table 1, we also can obtain that the dynamic speed response and the steady state speed response are better than the PI controller, which does not consider the periodic disturbance.

Conclusions
A fuzzy adaptive repetitive information theory is presented for high performance permanent magnet synchronous motor (PMSM) speed servo system applications in this paper for reducing speed periodic disturbance.The various sources of the PMSM speed ripple problem are described and analyzed; the system stability analysis is also given.Then, the improved repetitive controller parameter can be adjusted by fuzzy logic rules when the reference speed is varying.The performance of the PMSM servo system based on the fuzzy adaptive repetitive controller has been tested both in simulation and experiment at different speed references.A performance comparison of the PI controller and the proposed fuzzy adaptive repetitive controller has been presented.Simulation and experiment results have shown that the fuzzy adaptive repetitive controller has a better period disturbance rejection ability and stability convergence performance, so the proposed information control theory satisfies the high precision permanent magnet synchronous motor (PMSM) speed servo system applications.

Figure 1 .
Figure 1.The speed response curve of the PMSM servo system based on the PI controller in the case of the reference speed as 50 rpm.

Figure 2 .
Figure 2. The frequency spectrum curve of the PMSM servo system based on the PI controller in the case of the reference speed as 50 rpm.

Figure 3 .
Figure 3.The speed response curve of the PMSM servo system based on the PI controller in the case of the reference speed as 1000 rpm.

Figure 4 .
Figure 4.The frequency spectrum curve of the PMSM servo system based on the PI controller in the case of the reference speed as 1000 rpm.

Figure 5 .
Figure 5.The speed response curve of the PMSM servo system based on the PI controller in the case of the reference speed as 2500 rpm.

Figure 6 .
Figure 6.The frequency spectrum curve of the PMSM servo system based on the PI controller in the case of the reference speed as 2500 rpm.

Figure 8 .
Figure 8. Basic diagram of the repetitive controller.

Figure 9 .
Figure 9. Basic diagram of the repetitive controller digital implementation.

Figure 10 .
Figure 10.Diagram of the modified repetitive controller.

Figure 11 .
Figure 11.The control structure of compound controller based on fuzzy adaptive repetitive control and PI control.

Figure 12 .
Figure 12.The membership function of the input speed signal for the PMSM servo system.

Figure 13 .
Figure 13.The membership function of the output frequency information for the PMSM servo system.

Figure 14 .
Figure 14.The simulation result of the 50 r/min q-axis speed response comparison of the PMSM servo system based on the two controllers.

Figure 15 .
Figure 15.The simulation result of the 1000 r/min q-axis speed response comparison of the PMSM servo system based on the two controllers.

Figure 16 .
Figure 16.The simulation result of the 2500 r/min q-axis speed response comparison of the PMSM servo system based on the two controllers.

Figure 18 .
Figure 18.The speed response comparison of the PMSM servo system based on the two controllers when the reference speed is 500 rpm.

Figure 19 .
Figure 19.The speed response comparison of the PMSM servo system based on the two controllers when the reference speed is 1000 rpm.

Figure 20 .
Figure 20.The speed response comparison of the PMSM servo system based on the two controllers when the reference speed is 1500 rpm.

Figure 21 .
Figure 21.(a) The frequency spectrum of PMSM servo system based on the fuzzy adaptive repetitive controller and the PI controller when the reference speed is 500 rpm; (b) the frequency spectrum comparison of the PMSM servo system based on the two controllers when the reference speed is 500 rpm.

Figure 23 .
Figure 23.(a) The frequency spectrum of the PMSM servo system based on the fuzzy adaptive repetitive controller and the PI controller when the reference speed is 1500 rpm; (b) the frequency spectrum comparison of the PMSM servo system based on the two controllers when the reference speed is 1500 rpm.

Table 1 .
The experiment data of the fuzzy adaptive repetitive controller.