Sensorless Control of PM Synchronous Motors Based on LKF Estimation of Rotor Position S. Stasi
L. Salvatore
F. Cupertino
[email protected] o liba.it
salvatore@,poliba.it
cupertino@,ieee.orx
Politecnico di Bari - Dipartimento di Elettrotecnica ed Elettronica via E. Orabona 4, 70125 Bari, Italy
Abstract - This paper presents a novel PMSM sensorless control scheme based on a linear Kalman filter (LKF) observer. The LKF algorithm is able to estimate rotor position and current components in the stator reference frame by measuring stator currents, and using a mathematical model based on the voltage equations of motor. The proposed observer is linear but timevarying because the rotor speed is treated as a model parameter to be on-line updated. Estimation of rotor speed is performed in two steps: firstly a rough speed estimation is obtained by processing the estimates of rotor position; then a simple speed observer is used to improve the accuracy of speed estimates. The observer output, i.e. the final speed estimate, is fed back to both the speed control loop and LKF algorithm. Sensitivity to strong stator resistance variations makes this sensorless algorithm unsuitable for operation at very low speed; good performances are obtained in the speed range from 10% of rated speed to full speed.
I. INTRODUCTION Elimination of electromechanical sensors and cabling for the measurements of position, speed, and flux in ac machines leads to great advantages in term of cost reduction, reliability, and noise immunity, because the sensor performance degrades due to vibration or humidity. Thus sensorless control strategies of ac machines have received much attention in industrial applications in the last years [I]. The main goal of such methods is to estimate the rotor position or flux angle using the power leads of the machine, without separate position, speed, or flux transducers. Sensorless methods that depend on the fundamental excitation of the machine and speed-dependent phenomenon are generally not suitable for zero or very-low-speed operation [2-4], but efficient in applications where torque and speed controls are requested over a medium to high-speed range. These position detection schemes for PM synchronous motors can be divided into three main classes. In the first one the motor equations are manipulated to express rotor speed and position as functions of terminal quantities (stator voltages and/or currents). This approach is very sensitive to motor parameter variations. In the second class the speed and position estimates are performed by non-linear observers that generally do not guarantee the overall stability due to linearization of observer equations along the nominal state trajectory. In the third class the extended Kalman filter is used to estimate rotor position, speed, and model parameters [5-61. The EKF-based approach is well suited to obtain high-
0-7803-7474-6/02/$17 .0Q02002 IEEE
accuracy estimates of state variables and model parameters in presence of strong measurement noise, but it is characterised by the following drawbacks: 0 high computational efforts, when full-order EKF algorithms are used; sensitivity of the estimates to parameter variations (that cause a degradation of the estimation accuracy), when reduced-order EKF algorithms are used; 0 convergence and stability problems that may arise when unsuitable initial conditions are selected. To overcome the first and third problem mentioned above, the Authors propose in this paper a new sensorless algorithm to estimate rotor position and speed of a PMSM with surface mounted magnets. The new algorithm is based on the Linear Kalman Filter theory (LKF) and estimates directly the sine and cosine functions of electrical rotor position, and the current components in the stationary reference frame, from the measured stator currents and the reference voltage vector that controls the pulsewidth modulator, using the voltage equations as mathematical model of the LKF algorithm. The estimates of rotor position allow one to obtain an estimate of rotor speed that is used as input to a simple speed observer. Its output is fed back to both the speed control loop and LKF algorithm. In fact the LKF estimator is linear but time variant, since the rotor speed enters as a time-varying parameter in its mathematical model. To verify the feasibility of the proposed algorithm, many computer simulations have been performed. Main features of the proposed method can be summarised as follows: mechanical parameters are not used in the LKF algorithm, so that problem of parameter sensitivity is reduced; speed and position estimates track the actual values very fast at start-up, even when initial position estimate error is large; the LKF algorithm is stable and the estimates converge when the speed estimates are correctly performed. The main drawback of the proposed LKF estimator is its sensitivity to stator resistance variations. This fact makes the method unsuitable to accurately estimate rotor position at low speed, in presence of strong stator resistance variations. 11. MATHEMATICAL BACKGROUNDS The stator voltage equation of a synchronous motor with permanent magnets mounted on the rotor surface is:
686
where
vsdq
frame d-q,
is the stator voltage vector in the rotor reference isd4
is the stator current vector, R, is the stator
resistance, Ls is the stator inductance, w, is the electrical rotor speed, h. is the stator magnet flux linkage, and p is the derivative operator. Independent control of the stator current components i,d and is4 requires compensation of the coupling terms between d- and q-axis through the injection of the decoupling voltage vector
discrete measurements and obtaining high-accuracy estimates of system states and unknown parameters. In fact, the LKF is the optimal estimator within a class of all estimators, linear and non-linear, because it minimises the variances of the estimation errors of the variables being estimated [7-81. In the sensorless control scheme proposed in this paper the rotor position detection is then realised by using a LKF observer, able to estimate directly the sine and cosine functions of the rotor position, and the stator current components in the stationary reference frame a-p. The mathematical model of this stochastic observer is derived from the motor voltage equations in a-p coordinates. Two hrther equations relevant to sine, and cos 9, have been added to the voltage model. It results:
The following voltage vector V‘,dq then indirectly controls
(5)
the d- and q-axis stator current components: I
_
vsdq
-
= vsdq
- ‘sdq, cornp = (Rs
+ Ls
P >isdq .
The mathematical model of PMSM is completed by the mechanical equation:
J
-pa,
=T,-T, =
(4)
p (sine, ) = a,cos e,.
(7)
p (coser)= - w, s i n e , .
(8)
nP
Then the discretised state-space model of LKF is: where J is the motor and load inertia, np is the number of pole pairs, TL is the load torque, and T, is the electromagnetic torque. In sensorless PMSM drives rotor position and speed have to be estimated somehow to perform the necessary coordinate transformations and make the control feedback signals available. Errors in rotor position estimation cause wrong variable transformations and, consequently, the drive performance deteriorates. Figure 1 shows the block scheme of the proposed sensorless drive. Since the maximum torque/current control is achieved when the d-axis current is null, the d-axis current reference iid has been set equal to zero. The Kalman stochastic observer (“LKF” block) and speed estimator provide rotor position and speed information. The “Decoupling Network” block gives the d- and q-axis decoupling-voltage signals that allow an independent current control along the two axes. The PI current regulators are then designed according to the zero-pole cancellation method (the integral time-constant of the controller is chosen equal to the stator time-constant) and imposing the desired time-constant (1 ms) to the current control loop. The outer PI speed controller is then designed by applying the symmetric optimum criterion.
111.ROTOR POSITION ESTIMATION ALGORITHM The linear Kalman filter (LKF) observer has been shown to be the best computer algorithm for processing noisy
+
+ L u ( n )+ E ( n ),
x ( n 1) = F(n) x (n)
(9)
where
T
L = - , U (n)= [v,, (n) vsp( n )
o
OIT,
L S
RZ is the nominal value of stator resistance, T is the sampling time, and the terms E represent the model errors, assumed to be white and Gaussian uncorrelated noises, with zero mean values and covariance matrix Q.The system noise takes into account system disturbances and model inaccuracies.
687
* 'sd
-
controlle
'
L
speed observer
'peed estimator c
a:
Fig. 1 : Block diagram of the sensorless vector-controlled PMSM drive.
It has to be noted that the rotor speed W: is not a state variable, but is treated as a time-varying parameter to be online updated after it has been estimated somehow. The LKF recursive algorithm requires also an observation model that relates the observed quantities to the state variables. In our case, the observed variables are the a-p current components, and the observation model is Z
(n+ 1) = H x ( n + l ) + q (n + 1) ,
state prediction (1 1)
computation of covariance matrix of prediction errors P - ( n + 1) = F(n) P(n) F(n)
+Q(n) ;
computation of the Kalman gain matrix
i ( n + 1) = i - ( n + 1)+ G(n + l ) [ (n ~ + 1) - H i - ( n + I)] ; (14) where
n
1
= [isa i,p
sin- 0, cos- 0, ]
update of the covariance matrix of estimation errors
P(n + 1) = [ I -G(n+ 1) HI P - ( n + 1) .
The vector q contains the measurement errors, assumed to be white and Gaussian uncorrelated noises, with zero mean values and covariance matrix R. Beginning from an initial state estimate (0) and covariance matrix of estimation errors P (0) ,the recursive LKF algorithm is as follows:
(12)
+ R(n+l)] -'; (13)
state estimation
(10)
where z ( n ) =[i,",(n) i,"p(n)IT,
i - ( n +1) = F(n) i (n)+ L U (n) ;
G(n+l) = P - ( n + l ) H T [ HP - ( n + l ) H
(15)
When the hypothesis about model and measurement errors are satisfied, and parameters are perfectly known, the Kalman filter stochastic observer is the optimal estimator, since it minimises the estimation errors of its state variables. Parameter detuning, such as stator resistance variations, causes the LKF to become sub-optimal. As a consequence the estimation errors of sine and cosine functions increase as much as the rotor speed decreases. Furthermore field oriented control and maximum torque/current operation deteriorate when these estimated fbnctions are used for coordinate transformations. This fact limits the algorithm application to a speed range from 10% to 100%of the rated speed. It has to be noted that the estimated functions sin- 0, and cosAO, in the LKF are treated as independent state variables, then their evolution during the estimation process can not be constrained by the condition (sina0,)' +(cos^0,)' = 1 . However it is possible to show that, if the estimation process is stable, the variables sinA0,
688
and cos 0, converge towards quantities that are proportional to the true values of sine, and cos€),, and the rotor position is correctly estimated. In fact, let’s consider the following estimate-error equations A
--M
S
zsa .
+-(or hf
L S
sin e, - w: sin^e,)
L S
obtained as the difference between the true voltage equations (5)-(6) and the “estimated” ones (see (14) in its continuoustime version), neglecting measurement errors. The terms gjk are elements of the Kalman gain matrix. The estimates of the stator a-p current components rapidly converge to the true values, independently on stator resistance variation ARs, because the LKF uses these measured currents as observed variables. After convergence is reached we can assume is, = is, , isP = isP,and (16)-( 17) become
ARsisa =hfw,sinO,
ARs i,p = -1
f
0,
[
1-
sin^0, w, sine,
0:
[
cos 0, 1-
]
w‘, cos-0, wrcos0r
Equation (22) implies that the estimated quantities sinA8 , and cosAO, are almost proportional to the true values of sin 0, and cos0, . Rotor position estimates can be then obtained as
Normalised sine and cosine hnctions sin 6, and cos 6, will be used in place of LKF estimates sin^0, and cos”0, to perform the necessary coordinate transformations, once the convergence is reached. The estimates can converge only if the LKF algorithm is asymptotically stable. This requires complete observability and controllability of the system and bounded Q,R, and F matrices as sufficient condition [7-81. Therefore, the estimation algorithm proposed in this paper will be stable as long as the estimated rotor speed will be bounded. Other remarks can be done by looking through (1 8) and (19): if the estimated speed is equal to the actual one, then the estimates of sine and cosine hnctions differ from the true values as much as stator resistance variation increases; when the estimates of rotor speed are performed by using the estimates sin^9, and cos e,, then stator resistance variation causes both wrong estimates of speed and sine and cosine functions. IV. ROTOR SPEED ESTIMATION
j
(19)
From (18) and (1 9) one obtains
Operation of LKF observer needs the rotor speed to be estimated, because it is treated as a time-varying parameter in the LKF model. Speed estimation, however, cannot be performed by only using the normalised functions sin 6,. and cos 6, at times (n) and (n+l) as follows:
0,(n + 1) = cos 6, (n+ 1) -isa =‘SP
w, sin 0,
tan 0,
-si&, (n + 1)
cos-0, 10 , COS0, 0:
When the maximum torquekurrent control is imposed the daxis current is null, and therefore it results
Comparison of (20) and (21) leads to the following sin^@, cos-0, =sin 0, cos 0,
si&, (n + 1) -sine, (n) T cos 6, (n + 1) -cos 6, (n)
(24)
T
This is because the above speed estimates, fed back into LKF algorithm, cause the third and fourth model equations to become pure identities, so that position estimation does not evolve, i.e. maintains to zero. To overcome this problem the speed estimate obtained from (24) is fed to the speed observer shown in fig. 2. The electromagnetic torque, fed in the speed observer, is estimated by using its expression in d-q reference frame fe = (3 / 2)n,h is, . The PI controller parameters of the speed observer are tuned according to the absolute value optimum criterion, setting the time constant of the observer equal to 4 ms.
689
VI. CONCLUSIONS
Fig. 2: Block scheme of the speed observer.
V. SIMULATION TESTS Simulation tests have been performed both at high and low speed by using SIMULINK program of MATLAB. The parameters of the PMSM used in the tests are as follows: stator resistance R, = 1 R, stator inductance L, = 5 mH, magnet flux linkage A,, = 0.1 Wb rated torque T,, = 5 Nm, system inertia J = 0,001 kg m2, rated current I,, = 5.9 A, DC link voltage V ~ =C 300 V, rated electrical speed W, = 1250 rads, pole pairs np = 4. The phase voltages are reconstructed from DC-bus voltage and duty cycle, and motor currents are filtered by a first-order low pass filter with cut-off frequency of 4 kHz, and then sampled at 10 kHz. In the LKF mathematical model the rated motor parameters are used. In all the simulations shown in the following the motor has been started at full load; at the same time the LKF has been started assigning the initial state-estimate vector i (0) =[0 0 0 11 , and initial estimate-error covariance matrix P(0) = 1 . Taking into account the uncertainties on the observed speed, the covariance matrix of the model errors has been chosen as Q = I . White noise sequences with normal distribution have also been added to the current inputs to simulate measurement errors. The noise variances are selected as follows: R11=R22=104 [A2]. Until convergence of the estimates is reached (only few ms), i.e. the estimation-error variances reach steady-state values, the estimated and not normalised functions sin^6, and cos^ 0, have to be used to realise coordinate transformations and speed estimation. Then normalised functions sin Gr and cos hr are employed. Figures 3 and 4 show the test results in the cases of high (1000 rad/s) and low (100 rads) speed reference, respectively, when the stator resistance is 30% higher than rated value in PMSM model, and initial position estimateerror is 30 electrical degrees. It is evident that the high convergence rate and accuracy of the position estimates, at both motor start-up and speed inversion, guarantees a correct field orientation and good speed estimation in the range from 10% of rated speed to full speed. It is also possible to stop the motor, but the LKF has to be deactivated when zero speed is approached. From the analysis of figure 4d it is possible to notice that the d-axis stator current is not zero even at steady state. Currents errors are increased by the delay introduced by the anti-alias current filters and LKF algorithm, but small enough to be tolerated.
The paper has presented a sensorless technique for PMSM drives consisting on rotor position estimation from a linear Kalman filter-based algorithm. The proposed observer is linear but time-varying because the rotor speed is treated as a model parameter to be on-line updated. Processing the estimates of rotor position and using a simple speed observer one can perform accurate speed estimation. The proposed technique guarantees good performance of the drive over a wide speed range, from 10% of rated speed to full speed, and also an effective maximum torque/current control of the drive because the field orientation is achieved. The algorithm needs low computational efforts and, consequently, is suitable for implementation on low cost pp. VII. ACKNOWLEDGEMENT The authors gratefully acknowledge the contributions of the reviewers whose comments have been very useful in refining this work. VIII. REFERENCES [I] K. Rajashekara, A. Kawamura, K. Matsuse, Sensorless control of AC motor drives, The IEEE, Inc., New York: 1996. [2] S . Ogasawara, H. Akagi, “An approach to position
sensorless drive for brushless DC motors,” IEEE Trans. on Industry Applications, vol. 27 5 , Sept.-Oct. 1991, pp. 928 - 933. [3] P.L. Jansen and R.D. Lorenz, “A Phisically insightful
approach to the design and accuracy assessment of flux observers for field oriented induction machine drives,” IEEE Trans. on Ind. Appl., vol. 30, no.1, 1994, pp. 101 110. [4] S. Stasi, L. Salvatore, F. Cupertino, “Improved rotor position estimation for maximum torque/current control of PMSM drives,” Proc. EPE 2001, 9th European Conference on Power Electronics and Applications, CD-rom. [ 5 ] Y.H. Kim and Y.S. Kook, “High performance IPMSM drives without rotational position sensors using reducedorder EKF,” IEEE Trans. On Energy Conversion, vol. 14, no. 4, Dec. 1999, pp. 868 - 873. [6] L. Salvatore, S . Stasi, F. Cupertino, “Improved rotor speed estimation using two Kalman filter-based algorithms,” Proc. IEEE-IAS 2001 Annual Meeting, CD-rom.
[7] R. G . Brown and P. Y . C . Hwang, Introduction to Random Signals and Applied Kalman Filtering, Wiley & Sons, New York: 1992. [8] A. Gelb, Applied Optimal Estimation, MIT Press, Cambridge, MA: 1988.
690
150-
---
estimated speed
F
actual speed
Fe
-500
-50-
-100. -1500:
0.1
I
0.2
0.3
0.4
-1501
0.5
I 0.1
0.2
time.
times. s
0.03
0.04
0.01
0.05
0.02
0.04
0.05
@)
@)
I
-1
I
-3
I
0.03
rime. s
B
-1
-4 0.25
0.5
I
I 0.02 rime,
0.4
(a)
(a)
0.01
0.3 8
-3 0.26
0.27
0.28
time.
0.29
I
0.3
8
(c) 4
3
< rF
2 .
I
E
*E
estimated d-current
1-
-
01
1actual d-surrent
I 0.1
0.2
0.3 time,
0.4
4
0.5
0.1
0.2
I
0.3
0.4
0.5
0.3
0.4
0.5
time. s
8
(d)
(4
$10. -15 .
0.1
0.2
rime.
*
0.3
0.4
I
-20
0.5
0.1
0.2
time. *
(e)
(e)
Fig. 3: High-speed performance of PMSM drive with Rs detuning: (a) rotor speed, @)-(c) rotor position at start-up and speed inversion, (d) d-axis current, (e) q-axis current.
Fig. 4: Low-speed performance of PMSM drive with Rs detuning: (a) rotor speed, @)-(c) rotor position at start-up and speed inversion, (d) daxis current, (e) q-axis current.
69 1