Decoupling Control of Permanent Magnet Synchronous Motor With Support Vector Regression Inverse System Method

Inverse system method is effective for controlling permanent magnet synchronous motor (PMSM). A novel support vector regression(SVR) inverse system method is proposed to realize decoupling control of PMSM in the article. Firstly, kernel space feature of the inverse model is optimized by using the prior information provided by the mathematical model of analytical inverse system to build two accurate SVR inverse models, which can solve the unreasonable kernel space feature when conventional SVR algorithm is employed to model PMSM inverse system. Then, the inverse system composing of two inverse models is cascaded with the original system to decouple PMSM system into two pseudo-linear subsystems. Finally, PID controller is employed to form a closed-loop control system. The simulation and experiment results show that the proposed method improves the generalization ability of inverse model and achieves high-performance control of PMSM.


I. INTRODUCTION
Permanent magnet synchronous motor (PMSM) has been widely used in electric vehicles, robots, compressors and other automation equipments because of its high power density, high efficiency, simple structure and good reliability [1]- [3]. PMSM, a strong nonlinear system, is multi-variable and strongly coupled. Additionally, its parameters are variable and its load disturbances are unavoidable. Thus, it is very difficult for classical decoupling control schemes such as field-oriented control (FOC) and direct torque control (DTC) to realize high-performance control of PMSM [4]- [6].
Inverse system, an inversion of the controlled original system, is an effective method for the linearization and decoupling control of nonlinear systems [7]. Cascading the inversion with the original system, the nonlinear and coupled system is decoupled into a pseudo-linear system, which is controlled by linear control strategy. The application of inverse system requires two preconditions: one is that the The associate editor coordinating the review of this manuscript and approving it for publication was Zhuang Xu .
original system can be represented by an accurate or approximate mathematical model, and the other is that it can be proved to be reversible.
PMSM is a complex nonlinear system. However, if some unimportant factors are ignored, an approximate mathematical model can represent it and the original system based on the model is reversible. There are two main methods for PMSM inverse system modeling: one is the analytical inverse method [8], [9], and the other is based on machine learning algorithms (MLAs) [7], [10]- [12].
Analytical inverse system model, a mathematical model based on inverse system theory and derived from the original PMSM system, cascades the original system to build a new pseudo-linear system, which is a fast way to set up a composite system. However, the mathematical model of PMSM is an ideal model with some unimportant factors such as the hysteresis in the iron core, eddy current and core magnetic saturation ignored. Moreover, stator inductance, resistance and other parameters are considered to be accurately measured and stable in any different operation condition. Therefore, the mathematical model can not fully VOLUME 8, 2020 This work is licensed under a Creative Commons Attribution 4.0 License. For more information, see https://creativecommons.org/licenses/by/4.0/ represent the actual motor and the analytical inverse model derived from it is also inaccurate.
The inverse system based on MLAs uses intelligent algorithms to build the inverse model. The training data including the factors such as hysteresis in the iron core, eddy current and core magnetic saturation ignored used in the process comes from the sampling of the original PMSM system, which is regarded as a black-box. Therefore, the dependence on the accurate mathematical model of PMSM is overcome. Liu et al. [10] used (Support Vector Machine)SVM to replace Neural Network to construct a PMSM inverse system and trained the SVM inverse model offline. The input features of SVM models were all normalized in order to avoid the dimension disaster. He and Wang et al. [11] developed an online LS-SVM (modified algorithm of the standard SVM) to construct an inverse model for pseudo-linear system. In literature [12], the BP neural network was employed to obtain the inversion of the bearingless PMSM system.
The inverse system based on MLAs overcomes the defect of analytical inverse system.However, it sets a higher demand for the inverse models. An extended closed-loop controller can be added to ensure the motor's normal operation although PMSM mathematical model of the analytical inverse system is not quite accurate, while the inverse model based on MLAs will probably affect its normal operation because of under-fitting and over-fitting that are caused by unreasonable training process of the model. Therefore, the generalization ability of inverse model is the key to the success of inverse system method.
SVR, an effective kernel-based algorithm for modeling nonlinear system [13]- [15], can balance the fitting ability of training sample data and the generalization ability of inverse models. Compared with the empirical risk minimization methods such as artificial neural network and least squares algorithm, SVR modeling based on the principle of structural risk minimization is not constrained by sample quantity and quality, thus avoiding local minimization [16]- [18].
This article proposes a SVR inverse system method for PMSM control based on kernel space feature. Firstly, the influence of input features of inverse model on the kernel space feature is analyzed and the values of feature weights are given according to the mathematical model of the original PMSM system. Then, two SVR inverse models are built to compose an inverse system. Finally, a new pseudo-linear system built by cascading the inverse system and the original system is combined with two extended PID controllers to realize high-performance closed-loop control.
The contribution of this article mainly includes two aspects. Firstly, as a PMSM inverse model is built by adopting SVR algorithm, a reasonable kernel space is constructed and the generalization ability of PMSM inverse model is also improved. Secondly, two PMSM inverse system methods based on mathematical model and on MLAs respectively are combined. The mathematical model of analytical inverse system provides important information for SVR modeling, which makes the feature of target kernel space clearer. It is of positive significance to use the model's prior information in SVR modeling for the transformation of kernel function and the construction of kernel space.
This article is organized as follows: In Section 2 ''Preliminaries'', analytical inverse system of PMSM and modeling of nonlinear system using SVR are briefly described. In Section 3 ''Decoupling Control of PMSM with SVR Inverse System Method'', the necessity of the feature weighting of inverse model is analyzed in theory, and then the realization of decoupling control of PMSM with feature weighting SVR inverse system method is introduced in detail. Simulation results and discussion are shown in Section 4 ''Simulation and Experiment Results''. In Section 5 ''Conclusions'', we come to a conclusion.

A. ANALYTIC INVERSE SYSTEM OF PMSM
PMSMs are classified into two typical types: surfacemounted PMSM and interior PMSM [19]. This article takes surface-mounted PMSM as the research object. The mathematical model for the original PMSM system based on the d − q axis can be expressed as where u d and u q are the stator voltage of d-axis and q-axis respectively, i d and i q are the stator current of d-axis and q-axis respectively. R is the stator resistance, L = L d = L q in which L d and L q are the inductance of d-axis and q-axis respectively, ω r is the rotor electrical speed, ψ f is the permanent magnet flux, P n is the number of pole pairs, J is the moment of inertia of the rotor, and T L is the load torque.
Based on the theory of inverse system and Interactor, output y 1 and output y 2 are differentiated until the results obviously contain input u 1 and input u 2 respectively.
The inverse system will be cascaded with the original system. Therefore, the output of the inverse system is u = which is the input of the original system. y 1 and y 2 are chosen as the input Consequently, the analytical inverse system derived from the mathematical model of PMSM can be expressed as Eq.(3) can be rewritten as Eq.(4) is equivalent to Eq.(5).
A new pseudo-linear system can be obtained by cascading the analytical inverse system with the original system. It is shown in Figure 1.

B. MODELING OF NONLINEAR SYSTEM BY USING SVR
The training dataset is given as where x i ∈ R n is the i-th input sample containing n features and y i ∈ R is the output. The model function determined by SVR method is expressed as follows: where w ∈ R n is a weight vector of hyperplane,φ (x) maps the samples of input features to a high-dimensional kernel space, and b is a bias term. The model function Eq.(6) can be further developed as follows: where K is the kernel matrix. K can be expressed as follows when Gaussian kernel is selected.

III. DECOUPLING CONTROL OF PMSM WITH SVR INVERSE SYSTEM METHOD A. MODELING OF INVERSE SYSTEM USING SVR
The training set of inverse model U d is given as T is the input sample containing five features and y q j = u q (j) is the output sample. The training samples i d , ω r , T L , u d , u q are sampled from the closed-loop control system of PMSM based on the analytical inversion, and i d , ω r , ω r are calculated by using the five-point numerical differential method.
The inverse model U q is used as an example to analyze the influence of input features on kernel space feature as follows. It won't hurt to assume that T L = 0. (9) can be rewritten as The similarity between x q i and x q j in kernel space can be obtained by calculating the distance d jk between the maps of two samples in kernel space.
In steady operation condition, u q is mainly determined by ω r because ω r , ω r and i d are all tend to zero. The approximations of u q and d jk can be expressed as It can be seen from Eq.(12) that the rotor electrical speed ω r has the greatest influence on the output of inverse model U q and the similarity of samples in kernel space.
In transient operation condition, the value of ω r may be 10 7 level, the value of ω r may be 10 4 level, and the value of ω r may be 10 3 level. According to Eq.(10), the coefficients of input features ω r and ω r are 5.7129e -7 and 6.5545e -04 respectively; the third item and fourth can be combined and written as (0.1827 + (8.3500e -04)i d ) ω r , so the coefficient of ω r can be approximately taken as 0.1827 and i d has slight effect on the output u q . For the similarity of samples in kernel space, input feature ω r has the greatest influence on the similarity of kernel space because of its great advantage in magnitude. Therefore, the approximation of u q and d jk in transient operation conditions can be expressed as u q ≈ (5.7129e -7)ω r +(6.5545e-04)ω r +0.1827ω r It can be seen from Eq. (13) that the contribution of input features to the construction of kernel space does not match their contribution to output u q . Therefore, it is unreasonable to use the raw data of input features to construct the kernel space of inverse model. Similarly, feature normalization also can not solve it.
Feature weighting can make the contribution of input features to the construction of kernel space match their contribution to the output.The conventional SVR model Eq. (6) can be further developed to feature weighting SVR(FW-SVR) as follows: where K is the weighted kernel matrix and K can be expressed as where k is the weight value of k-th input feature.
After the feature weights q = q 1 , T are introduced into the calculation of kernel elements, d jk can be expressed as follows: The feature weights can be adjusted to a reasonable value so that the influence of input features on sample similarity in kernel space matches with that on output u q , which makes the kernel space feature of SVR inverse model more reasonable.
Therefore, the inverse model U q based on FW-SVR can be expressed as Similarly, the inverse model U d based on FW-SVR can be expressed as According to the coefficients of each item in Eq.(4) and considering the operation condition of PMSM, the value of d and q are given as follows: where ξ 1 , ξ 2 and ξ 3 are empirical parameters which are specified on operation conditions of PMSM in analytical inverse system.

B. CONTROL SYSTEM OF PMSM BASED ON FW-SVR INVERSE SYSTEM METHOD
As the size of sample is limited, the training sample can not contain all operation conditions and the PMSM parameters will change under the influence of various factors. Therefore, the open-loop pseudo-linear system by cascading the inverse system with the original system can not achieve high performance. In this article, PID controller is used to overcome the disturbances from both internal and external. The diagram of PID control system is shown in Figure 2.

C. STEPS OF INVERSE SYSTEM METHOD BASED ON FW-SVR
1. Design a sampling system for training dataset. The pseudo-linear system shown in Figure 1 is combined with PID controller to form a closed-loop control system and the parameters of PID are adjusted to make the analytical inverse control system run normally.
2. Obtain the training samples. i d , ω r , T L , u d , u q are sampled and i d , ω r , ω r are calculated by five-point numerical differentiation method to form training sets T d and T q .
3. Select the optimal combination of feature weights, which are based on operation conditions and PMSM parameters.
4. Build a inverse system based on FW-SVR. Select parameters (C, γ , ε) for model U d and U q and train two FW-SVR inverse models by utilizing the obtained optimal model parameters.
5.Design a control system. When the inverse system cascades with the original system, the PMSM system is decoupled into two pseudo-linear subsystems. The control system shown in Figure 2 is established.
6.Adjust the PID controller parameters in Figure 2 to realize high-performance closed-loop control of PMSM.

IV. SIMULATION AND EXPERIMENT RESULTS
Comparative simulation between the proposed FW-SVR and the traditional SVR is carried out to prove the feasibility of the FW-SVR inverse system.Root mean square error (RMSE) is employed to evaluate the feasibility of FW-SVR.
where u i is the output sample and f (x i ) is its predicted value.
The smaller the value of RMSE, the better the generalization ability of the model. The datasets T 1 and T 2 generated under different excitation signals are sampled for convenient comparision.The training set of the two models are both composing of 501 samples taken at equal intervals from T 1 . For model U d and model U q , the training set is T d and T q respectively.The input feature ω r , ω r , ω r ,i d , i d in T d and T q is shown in Figure 3. The output u d in T d and the output u q in T q are shown in Figure 4.

A. KERNEL SPACE FEATURE
The kernel matrix can fully reflect the similarity between samples in kernel space. The inverse model U q is taken as an example and the kernel parameter γ is set to 1 × 10 −10 for convenient observation. The influence of input features such as ω r , ω r , ω r , i d on kernel space similarity is shown in Figure 5.
As can be seen from Figure 5, Figure 5(a) and Figure 5(b) are the closest, indicating that the kernel space similarity is mainly affected by input feature ω r unreasonably. First of all, although the amplitude of input feature ω r is large, it doesn't contribute a lot to the output of the model. When working on the output, ω r is multiplied by the coefficient 2JL/3p 2 n ψ f which is a small value of 5.7129e-07 in this article. On the contrary, although the amplitude of ω r is smaller than that of ω r , its contribution is larger than that of ω r after it multiplies the coefficient ψ f + Li d = (0.1827 + (8.35e − 4) i d ) ≈ 0.1827. Therefore, kernel space feature represented by the similarity of samples are unreasonable when the contribution of input features to the output is not considered and raw data or normalized data is used for model training.

B. GENERALIZATION ABILITY OF FW-SVR INVERSE MODEL
There are two kinds of model test sets: one comes from the same sample set as the training set does, and the other from different sample set. For model U d , the test sets are S d1 from T 1 and S d2 from T 2 . For model U q , the test sets are S q1 from T 1 and S q2 from T 2 .
As can be seen from Figure 6, the generalization ability of inverse model U q is obviously affected by the feature weights. For feature q 1 , the generalization ability is very poor when its coefficient is less than 2 −5 or greater than 2 5 . For feature q 4 , the generalization ability is very poor when its coefficient is greater than 2 6 while RMSE does not increase significantly when the coefficient gradually decreases to 2 −10 . The feature  1 of model U q is ω r which has an important contribution to output according to Eq. 5. Therefore, the influence of input features on the sample similarity in kernel space will not match with that on output u q , which makes the kernel space feature of inverse model U q is not reasonable until q 1 is adjusted to a reasonable value. Feature 4 is i d which corresponds to Lω r i d of the fourth term of U q . Even if ω r is the maximum value in training sample, i d has slight effect on output. Therefore, RMSE does not increase greatly with the decrease of the coefficient of q 4 . In addition, it can be seen from Figure 6 that the selection range of feature weights is large, and the generalization ability of the inverse model U q can be guaranteed as long as it is within a reasonable range.
The proposed FW-SVR is compared with feature normalization SVR(FN-SVR) and raw dataset SVR(RD-SVR) to observe the generalization difference of U d and U q .
Firstly, test sets S d1 and S q1 from the same sampling dataset T 1 as training sets T d and T q are used to test U d and U q models respectively. The predicted output of the models is shown in Figure 7.
Then, training dataset and test dataset are taken from different sample sets. For model U d , training dataset is T d and test dataset S d2 ; for model U q , training dataset T q and test dataset S q2 .The predicted output of the model is shown in Figure 8.
RMSEs of the test set S d1 , S d2 , S q1 and S q2 in Figure 7 and Figure 8 are given in Table 1.
As can be seen from Table 1, the performance of FW-SVR is the best; that of RD-SVR is the worst on all test sets; that of FN-SVR is good when the training set and test set are from the same sampling dataset, but it becomes worse for test samples from the new sampling dataset. For example, in U d model, RMSE is 0.0160 when test set is S d1 , but it is 1.5394 when test set is S d2 . In U q model, when the test set is S q1 and S q2 , RMSE is 0.1012 and 8.1999 respectively. 20 different test datasets are used to test U d and U q in order to further verify the performance of FW-SVR and FN-SVR on different test sets. The mean values and standard deviations of RMSEs are given in Table 2.  Finally, the Wilcoxon signed rank test [20] at the 0.05 significance level is implemented to further explain the indications in Table 2. The test results are presented in Table 3. It can be seen from Table 2-3 that there is statistically significant difference between FW-SVR and FN-SVR and the performance of FW-SVR is better than that of FN-SVR in U d and U q test.

C. DECOUPLING CONTROL OF PMSM
In order to verify the effectiveness of the proposed FW-SVR inverse system method, analytical inverse system method and FN-SVR inverse method are compared with it.
As the analytical inverse method greatly depends on motor parameters, two sets of parameters are used to test the method. One is the correct parameters which is completely consistent with that in the original system, which can verify the effectiveness of the inverse system theory in PMSM control; the other that is not completely consistent with the parameters of the original system is used to observe the influence of inaccurate parameter measurement or parameter change during motor operation on control performance, which can explain the necessity of using SVR algorithm that is independent of parameters. The FW-SVR inverse system method and FN-SVR inverse system method are based on the structure of Figure 2. The initial reference speed is set to 400 rpm, rising to 800 rpm at 0.3 s and decreasing to 600 rpm at 0.6 s.   It can be seen from Figure 9-11 that FW-SVR inverse system method proposed in this article achieves the best control performance. As shown in Figure 9(a), when the motor parameters are completely consistent with the actual parameters, the analytical inverse system method achieves the same control performance as the FW-SVR inverse system method. However, in Figure 9(b), when motor parameters used in analytical inverse system are different from the actual ones, its performance is shown as follows: the overshoot is 78.5 rpm when the motor starts, it is 72.6 when the speed increases from 400 rpm to 800 rpm and it is 35.6 when the speed decreases from 800 rpm to 600 rpm; the speed decreases from 600 rpm to 586.2 rpm when the load jumps from 5 Nm to 7 Nm and it returns to a steady state 0.06 second later. In general, the inverse system method is feasible in   PMSM control on condition that the inverse model is accurate enough to ensure the decoupling control performance after overcoming the dependence on parameters.
As shown in Figure 10, although FN-SVR does not rely on motor parameters, its decoupling control performance is not good because the model is not accurate enough. As shown in Figure 11, the maximum overshoot is 11.5 rpm and the motor speed only decreases 3.7 rpm when the load is disturbed. As the FW-SVR inverse system method does not only overcome the dependence on motor parameters, but also build an accurate inverse model by optimizing the kernel space features, its decoupling control performance is the best.

2) EXPERIMENT RESULTS
The experiments which are based on YXSPACE-10 rapid controller prototyping are performed for further verification. The experiment platform is designed as Figure 12.
The parameters of the motor are R = 0.900 , L = L d = L q = 6.25 × 10 −4 H , Pn = 4, J = 6.30 × 10 −4 kg · m 2 and ψ f = 0.01585Wb. The load is 0.2Nm. The fast response of the speed is taken as the evaluation indexes of control performance. The control performance is shown in Figure 13.
It can be seen from Figure 13 that the speed response of FW-SVR inverse system method proposed in this article achieves the best performance. In Figure 13(a), the performance of analytical inverse system method is shown as follows: the overshoot is 86.4 rpm when the motor starts, it is 74.2 when the speed increases from 400 rpm to 800 rpm and it is 43.9 when the speed decreases from 800 rpm to 600 rpm. As shown in Figure 13(b), the performance of FN-SVR inverse system method is similar to that of analytical inverse system method. As shown in Figure 13(c), the maximum overshoot is 27.5 rpm.

V. CONCLUSION
In this article, a novel FW-SVR inverse system method is proposed for decoupling control of PMSM. The contribution of input features to the construction of kernel space is estimated based on the mathematical model of analytical inverse system. Therefore, the feature weights of FW-SVR can be adjusted to a reasonable value which makes the kernel space feature of SVR inverse model more reasonable.The comparative simulation and experiment results demonstrate that: (1) The generalization ability of SVR inverse model is obviously affected by the feature weights while it can be improved by FW-SVR; (2) The FW-SVR inverse system method is feasible in decoupling control of PMSM because it does not only overcome the dependence on motor parameters, but also build an accurate inverse model.