1. Introduction
The permanent magnet synchronous motor (PMSM) has superior performance and advantages in terms of efficiency, power density, torque-to-inertia ratio, and reliability. However, factors such as cogging torque and harmonic flux in the motor can cause distortion in the control current, resulting in periodic fluctuations in the motor output torque. This fluctuation is known as torque ripple in the motor. This phenomenon can cause mechanical vibration, speed fluctuations [
1], and acoustic noise at high speeds in the motor [
2], which has a significant impact on the high-precision positioning in the speed control and position control systems at low speeds, greatly reducing the control performance of the servo system. Therefore, motor torque ripple suppression is extremely important in high-precision servo control systems.
The PMSM is a multi-variable, strong-coupled nonlinear system, whose periodic torque ripple involves various elements of the motor, such as harmonics, cogging torque, current identification error, phase imbalance, etc. [
3]. Currently, research on the PMSM periodic torque ripple suppression can be divided into two routes: one is based on the motor body, which eliminates vibration through the optimization of the mechanical structure of the motor body, such as using closed slots, but this will lead to large leakage flux, reduced electromotive force of the armature winding, and increased inductive resistance. These shortcomings can be compensated for by increasing the excitation magnet-motive force and using removable teeth [
4]. In addition to this, there are methods to optimize the motor structure by improving the winding distribution [
5], stator skew slot, or rotor skew pole [
6], optimizing magnetic pole shape, etc. [
7]. However, motors with different functions have different body structures; therefore, the strategy of optimizing the motor body to eliminate vibration has poor versatility. The other is based on the control strategy, which controls the electromagnetic parameters of the motor and compensates the motor control current or voltage without changing the structure of the motor body; thereby, suppressing the torque ripple [
8].
With the widespread application of the PMSM in industrial production in recent years, torque ripple suppression methods based on control strategies have been intensively studied. Chen et al. [
9] suppressed the torque ripple caused by flux harmonics with the injection of a 5th and a 7th high-frequency harmonic current into the control signal. However, the calculation formula is complex, and it is difficult to set the control parameters. Qu et al. [
10] derived the relationship between the amplitude of velocity harmonics and harmonic current based on the harmonic injection method, and proposed a new velocity harmonic controller considering the copper loss, which reduces the impact of velocity harmonic phase. Doo-Il et al. [
11] use the extended Kalman filter to predict the distorted output voltage and compensate for the dead-time effect of the inverter to improve control stability. However, this method has a limited effect on suppressing torque ripple caused by other causes. Zhang et al. [
12] implemented a zero steady-state error tracking control for the sinusoidal signal at the resonant frequency and connected the resonant controller in parallel with the current loop PI controller to improve the current waveform of the stator and control the torque ripple. Gao et al. [
13] proposed an online compensation control method using a hybrid torque distribution function to control current fluctuations and optimize torque distribution to reduce torque ripple. Song et al. [
14] defined the double rotor position angle to apply two different operating modes, thereby performing different torque lag control schemes, based on the ampere torque characteristics of the motor. However, this method is complex and difficult to apply in industrial production. Li B. et al. [
15] proposed a torque ripple suppression strategy of an ILC (iterative learning control) algorithm. By utilizing the obvious periodic characteristics of torque ripple, an online iterative approach is used to obtain an accurate torque tracking trajectory, and the deviation signal is compensated to the q-axis current to achieve torque ripple suppression. On this basis, Ji P. et al. [
16] used the improved particle swarm optimization (PSO) to optimize and tune the key PID parameters in the ILC, thereby improving the torque ripple suppression effect. However, in practical applications, when the PSO is optimized, the convergence speed is slow, and it is easy to fall into the local optimum [
17].
The slime mold algorithm (SMA) is a new meta-heuristic algorithm proposed by Li et al. [
18] in 2020, which mainly uses mathematical models to simulate the behavior and morphological changes of slime molds in the foraging process in nature. The weight coefficient of the SMA simulates the positive and negative feedback generated by the biological oscillator of the slime mold when encountering food of different concentrations: when high-quality food is found, the slime mold will approach quickly; when the food concentration is low, the slime mold will move slowly, thereby approaching the best food source with greater efficiency. SMA code has a simple structure, strong scalability, and excellent performance in function optimization and engineering design, with the advantages of fast response and strong anti-interference in parameter self-tuning [
19].
Therefore, this paper proposes a torque ripple suppression method with a forgetting factor for an open-closed-loop iterative learning control to address the periodic torque ripple generated during the operation of a PMSM. The electromagnetic torque output by the system is used as a feedback signal to track the output current of the speed loop. The difference between the reference signal and the output signal is compensated in real time to the q-axis current reference terminal through an iterative learning control algorithm, and the iteration is repeated continuously to reduce the error. The chaos-mapped SMA is used to optimize the PID control parameters and forgetting factors in the iterative learning controller, improving the tracking accuracy and convergence speed of the torque error. This method does not rely on the system’s prior knowledge and motor parameters, and can adapt to the target motor, reducing manual debugging of parameters. It improves the optimization speed, avoids local optima, achieves better suppression effects, and further improves the torque ripple suppression effect. Simulation experiments were performed in the MATLAB/Simulink platform. The reduction in the number of iterations required for adaptive iteration obtained from simulation, as well as the reduction in torque ripple coefficient and torque ripple, all indicate that this method can further improve the performance of iterative learning control and better suppress the amplitude of torque ripple.
Therefore, this paper proposes a torque ripple suppression method of an open-closed loop iterative learning control with forgetting factor for the periodic torque ripple generated when a PMSM is working, and optimizes and tunes the control parameters in the ILC using the SMA after chaos mapping to improve the optimal-searching speed and avoid local optimum, thereby further improving the torque ripple suppression effect. Relevant simulation experiments were conducted on the Simulink platform, and the simulation results showed that this method can further improve the performance of iterative learning control and suppress torque ripple amplitude.
2. Mathematical Model of Motor
In the vector control system, neglecting the saturation of the magnetic circuit and core loss, as well as the effect of leakage flux and eddy current effect, the voltage equation of a PMSM in the synchronous rotating coordinate system is:
In the equation,
represents the resistance of the stator winding;
represents the mechanical angular velocity;
and
stand for the voltage of
-axis and
-axis, respectively;
and
stand for the currents of
-axis and
-axis, respectively; while
and
represent the stator flux linkage of
-axis and
-axis, respectively. The equation is:
Among them, and stand for the inductances of -axis and -axis, respectively and represents the rotor flux linkage.
If further assumed that the PMSM used is a surface-mounted motor without salient poles and
and
are equal, then the electromagnetic torque equation of the motor is:
In Equation (3), p represents the number of pole pairs of the motor and represents the torque coefficient.
3. Factor Analysis of Torque Ripple
The main causes of torque ripple include cogging torque and flux harmonic distortion; among which, cogging torque is the circumferential torque generated by the interaction between the rotor permanent magnet magnetic field and the cogging of the stator core, achieving suppression through the optimized design of the motor body [
20], while magnetic flux harmonic distortion is the main source of periodic torque ripple, and is also the primary target of the control strategy to suppress torque ripple. The permanent magnet excitation magnetic field and the stator winding cannot achieve a completely sinusoidal distribution. As a result, the air-gap flux density distribution cannot achieve a completely sinusoidal waveform, which leads to harmonics in the flux linkage in the permanent magnet and stator current appearing in the 3rd, 5th, 7th, 11th harmonic, etc. [
21]. As there is no 3rd harmonic in the Y-shaped connected stator winding, the 5th and 7th harmonics have the greatest impact on the system. The mathematical model of harmonics in the PMSM stationary three-phase coordinates can be expressed as:
Among them,
,
, and
stand for three-phase voltages;
represents the electrical angle of the motor;
and
stand for the amplitude and initial phase of the fundamental voltage, respectively;
and
stand for the amplitude and initial phase of the 5th harmonic voltage, respectively; and
and
stand for the amplitude and initial phase of the 7th harmonic voltage, respectively. Under the action of the magnetic field of the permanent magnet, the 6th and 12th harmonic torque equations generated by the 5th and 7th harmonic voltages are:
In the equation, , , andrepresent the amplitude of DC torque, 6th and 12th harmonic torque, respectively; is the total harmonic torque. According to Equation (5), it can be seen that the electromagnetic torque of the motor is mainly composed of the fundamental wave component and the 6th and 12th harmonic components. The ultimate control goal is to suppress the periodic torque ripple caused by higher harmonics.
4. Iterative Learning Suppression Algorithm of Torque Ripple
An iterative learning control (ILC) is a control method for trajectory tracking systems that perform repeated movements [
22], which generates the desired input by applying the previous control information multiple times and continuously iterates the previous control information so that the deviation signal tends to zero within a limited time. For repeatable periodic motion or periodic interference, an ILC can achieve better control effects [
23].
In this paper, the author designs a PID iterative learning controller for the speed loop of the PMSM vector control system, which uses the electromagnetic torque output by the system as a feedback signal, tracks the output current of the speed loop, and compensates the q-axis current set end in real time with the difference between the reference signal and the output signal through the ILC algorithm, repeating the iteration to reduce the error. Through this method, the controller can adjust the current in real time to control the output torque of the motor, achieving the torque ripple suppression effect.
4.1. Mathematical Model of ILC
The ILC iteratively calculates the error
between the desired output
and the actual system output
, in a dynamic repeating system of duration
:
represents the system state variable,
represents the system input variable, and
represents the system output variable. The output-controlled quantity of the ILC
can be expressed as:
represents the error between the expected output value and the actual output value,
represents the controlled quantity of the previous period, and
is the control rate of iterative learning. Commonly used ILC laws include P type and PI type, PID type, etc., and it can be divided into open loop, closed loop, open-closed loop, etc. according to the feedback. The difference between open-loop iterative learning and closed-loop iterative learning is whether to use the signal stored in the previous moment or the current moment signal. To enhance the robustness of an ILC and accelerate the convergence speed of the algorithm, the forgetting factor α can be introduced, which represents the proportion of the controlled quantity of the previous cycle to the controlled quantity of the current cycle. Therefore, the PID open-closed loop ILC law with the forgetting factor in this paper can be expressed as:
The value of the forgetting factor α can be between 0 and 1. When the value of α is larger, the error of the system output decreases as the value increases. However, when the value of α approaches 1, the forgetting factor gradually fails. Therefore, the value of the forgetting factor needs to be determined based on actual engineering conditions to consider the convergence speed and robustness of iterative learning.
4.2. ILC Design
An open-closed loop PID type ILC algorithm with a forgetting factor is used to suppress the periodic torque ripple of the PMSM. From Equation (3), it can be seen that the electromagnetic torque of the motor is proportional to the
q-axis current
under ideal circumstances, and the expected electromagnetic torque value
is used as
the expected output value of the ILC and the torque signal feedback value
is used as the actual output value. The torque current compensation value
can be obtained through an ILC with the error between the two. Therefore, the mathematical description of the ILC law in the motor control system is shown in Equation (9), and the ILC block diagram is shown in
Figure 1.
Among them, and stand for the torque current compensation values of the current cycle and the previous cycle, respectively; and stand for the torque error signals of the current cycle and the previous cycle, respectively; , , and are the PID gains of the ILC; and α is the forgetting factor.
5. ILC Parameter Optimization with SMA
5.1. SMA
An SMA (slime mold algorithm) is a mathematical model that simulates the behavior and morphological changes of slime molds during their foraging process in nature. When the slime mold approaches a food source, the biological oscillator generates a propagation wave through the veins, increasing the cytoplasmic flow [
24]. The higher the food concentration, the stronger the propagation wave generated by the biological oscillator, and the faster the cytoplasmic flow. An SMA simulates the above-mentioned behavior through a mathematical model, which can be divided into three stages: the food-approaching stage, surrounding food stage, and grabbing food stage. The above process is detailed in Equation (11):
Among them,
and
are the positions of the slime mold in the
th and
th iterations, respectively;
represents the position with the highest food concentration at the
th iteration (the best position);
and
represent two slime mold individuals randomly selected in the
th iteration;
is a random number in the range [−a, a];
is the current iterations;
is the maximum iterations;
is a random number linearly decreasing from 1 to 0;
is a random number between 0 and 1;
represents the fitness value of the
th slime mold individual; and
represents the optimal fitness value in all iterations,
M represents the population size of slime mold, and
W represents the quality coefficient of slime mold, and its equation is:
Among them,
represents the individual whose fitness value ranks in the top half of the group;
and
represent the optimal fitness value and the worst fitness value in the current iteration, respectively; and
represents the sorted fitness value sequence. The algorithm updates individual positions based on changes in the optimal position
and fine-tuning of
,
, and
. The function of
is to form a search vector at any angle, that is, to search the solution space in any direction, thereby increasing the possibility of finding the optimal solution and better simulating the circular and fan-shaped structural motion of slime molds approaching food.
simulates the positive and negative feedback process between slime mold weight and food concentration (fitness value) and
is used to slow down the change rate of the value and stabilize the change in contraction frequency. This equation simulates the process of slime molds adjusting their positions according to food concentration; the higher the food concentration, the greater the weight of slime molds near the area. If the food concentration is low, slime molds will turn to search other areas [
25].
The search range of the SMA can be further expanded by using logistic chaotic mapping to initialize the population instead of random values. With a simple structure, logistic chaotic mapping can show balance in the phase space through a reasonable control parameters selection. By using logistic mapping during population initialization, the search range can be effectively expanded, and the efficiency of subsequent algorithms can be improved. Its iteration expression is:
and are the th and th chaotic variables, respectively, ; and is the control parameter of chaotic mapping, , which c determines the behavior and properties of the mapping. When takes a value of 4 and takes a random value within [0, 1], pseudo-random values distributed relatively evenly within the range of [0, 1] can be generated.
5.2. ILC Parameter Optimization by SMA
This paper selects four key parameters of iterative learning,
,
,
and forgetting factor α, as the optimization targets of the SMA to obtain better torque ripple suppression effect. The system block diagram is shown in
Figure 2. The green dotted box in the figure is the torque ripple suppression module, and the blue dotted box is the SMA-optimized parameter module. When the motor is running, the system collects the error signal
between the tracking variable
and the torque feedback value
in real time. The ILC after parameter optimization performed through the SMA calculates the compensation value
, and compensates it to the set end of the
q-axis current.
A periodic trigger is incorporated to this process, with the rotor rotating once as a period, and the rotor position signal collected by the system is used to replace the time signal to control the operation of the ILC, thus effectively preventing the deviation of the compensation position corresponding to the current compensation value.
In slime mold algorithms, fitness
is usually used as an evaluation index to judge the quality of individual positions and determine the optimal individual position. In the PMSM vector control system, the system error
is first selected as the primary performance index. At the same time, in order to prevent excessive fluctuations in input energy, the operating variance of the compensated q-axis current
is the secondary influencing factor included in the fitness function. The specific expression of the fitness function is:
In this equation, and are weight coefficients, and The value of the fitness function reflects the quality of the slime mold individual position. The smaller the value, the better the control effect of the corresponding individual position on the surface. The individual position corresponding to the minimum value of is the current optimal solution.
5.3. Steps of Algorithm Optimization
The specific steps for an ILC parameter optimization based on the SMA are as follows.
Step 1: Initialization. Use logistic chaotic mapping to initialize the slime mold population positions in the four dimensions of , , , and , given the maximum iterations N and the population size M.
Step 2: Assign the positions of , , , and α to the ILC, then run the system to calculate and evaluate the fitness f of the current position according to Equation (17).
Step 3: Update the current optimal individual and its fitness value.
Step 4: Calculate the slime mold mass coefficient W according to Equation (15).
Step 5: For each slime mold individual, update the parameters , , and according to Equations (13) and (14), and then update the slime mold individual position according to Equation (12).
Step 6: If the algorithm reaches the set maximum iterations, output the optimal PID control parameters (that is, the optimal position of the SMA); otherwise, return to Step 2.
Step 7: The algorithm ends.
6. Simulation Experiment
In Matlab, the function m is used to write the chaotic initialization SMA, and a PMSM double closed-loop vector control (foc) model based on iterative learning compensation torque ripple suppression is built in Simulink to control the four parameters in the ILC for iterative optimization, whose value ranges are
∈ [0, 10],
∈ [0, 10],
∈[0, 1],
∈ [0, 1], with the population size
M = 24, dimension
= 4, and maximum iterations
= 50. The configuration parameters of PMSM in Simulink are shown in
Table 1:
The target parameters are optimized through the SMA and compared with the optimization results of the PSO, to obtain the optimal parameters shown in
Table 2, and the fitness function convergence curve shown in
Figure 3.
In
Figure 3, the convergence speed of the SMA is faster than the PSO. The convergence interval is found in the third iteration, and it jumps out of the local optimum and finds the global optimal fitness value in the 19th iteration, while the PSO falls into a local optimum in the late iteration and has poor global search capabilities.
To further verify the effectiveness of this method, the data of torque suppression effect after ILC-SMA optimization is compared with the data from the system without a suppressor, and the data after being suppressed by the ILC and ILC-PSO methods:
The torque ripple coefficient
is used to evaluate the torque ripple size:
In this equation, and represent the maximum and minimum values of torque ripple, respectively, and is the average torque. The torque ripple coefficient and standard deviation of the original system and the three suppression methods are compared:
Combining the simulation results of several suppression methods in
Figure 4 and
Table 3, it can be seen that when the PMSM is at a constant speed and the load torque is stable, the torque ripple amplitude value output by the open-closed loop ILC-SMA method proposed in this paper is smaller than that of other methods, with standard deviation of torque ripple reduced to 0.0776 and torque ripple coefficient reduced to 3.47%. Compared with the PSO-ILC method, it is reduced by 19.1% and 26.3%, respectively, significantly reducing the intensity of torque ripple near a given load torque, which proves that the torque ripple suppression effect is better than that of the other two algorithms.
To further verify the above conclusion, the fast Fourier transform (FFT) is performed on the torque ripple in the above figure, and the following harmonic analysis comparison chart is obtained.
It can be seen from the harmonic analysis results in
Figure 5 and
Table 4 that both the ILC method and the PSO-ILC method can effectively reduce the higher harmonic components in the PMSM torque ripple. Compared with the PSO-ILC method, the SMA-ILC method proposed in this paper reduces the 6th harmonic component from 239.736% to 195.551% and the 12th harmonic component from 116.683% to 96.245%, which are reduced by 18.43% and 17.52%, respectively. It proves that this method has a good effect in suppressing the harmonic component of the output torque and can effectively suppress the periodic torque ripple of the PMSM.
7. Conclusions
In summary, this article discusses the suppression of torque ripple in permanent magnet synchronous motors and proposes a torque ripple suppression strategy based on SMA optimization iterative learning parameters. In traditional dual closed-loop FOC control systems, the iterative learning deviation value is used to compensate for the speed loop q-axis torque current to reduce periodic torque ripple.
The simulation results show that the SMA-ILC method has a better performance than the PSO-ILC method in terms of torque ripple suppression. Compared with the PSO-ILC method, the standard deviation and torque ripple coefficient of the SMA-ILC method are reduced by 19.1% and 26.3%, respectively, and the high-order harmonics after FFT analysis are reduced by 18.43% and 17.52%, respectively. The results show that the SMA-ILC method has a more effective torque ripple suppression effect for permanent magnet synchronous motors. This scheme can be used in industries with high requirements for low-speed stability of motors, such as the sports equipment industry. It can be used in treadmills to reduce speed fluctuations at low speeds and reduce the vibration felt by the foot. The SMA-ILC algorithm improves efficiency, but does not solve the dependence of this type of control method on torque sensors or torque observers. In future research, deep learning technology can be introduced to consider the non-electric factors affecting torque ripple, further improving the accuracy of torque ripple.