Beruflich Dokumente
Kultur Dokumente
Keywords: Stepper motor, Sensorless, Modelling, Extended Kalman Filter, Unscented Kalman Filter, Matlab.
1. INTRODUCTION
Stepper motors are in wide range of applications, including high and low propulsion technology, computer peripherals,
machine tools, robotics etc. The interest in this system has been steadily increasing requirements for accuracy and
repeatability while at the same time placing ever tighter demands on the maximum and constancy of speed as well as
position resolution. However it has a non-linear and coupled dynamic structure so we could use different control
schemes to make the stepper more competitive to use in different levels of application. Open loop control will provide a
satisfactory solution under limited conditions. But for high performance dynamic operation this will not give satisfactory
results. So we need to find more sophisticated control methods to make the performance of stepper motors much more
competitive. This work is mainly focused on state estimation of Stepper motor for finding optimized control techniques
using simulation.
Traditionally, DC motors have been chosen for industrial applications over stepper motors due to their linear
input/output relationship, which in turn, allows for the use of standard control strategies. Over the past few years, the use
of stepper motors has increased. The reasons for this include: better reliability due to the elimination of mechanical
brushes, better heat dissipation as the windings are located on the stator and not on the rotor, higher torque-to-inertia
ratio due to a lighter rotor, and lower prices [1].
Sensorless Control-In recent years there have been successful applications of different types of control theory in the
areas of robotics, aircraft control, and motor torque and speed control and estimation using powerful microcontrollers.
Complex applications can be implemented by the use of different control methods in standard practice. In conventional
methodologies, one has to use different kinds of sensors or transducers to make controllers more robust. But sensors cost
a lot, may not give enough resolution, and may have a high failure rate. Using some kind of observer or filter one can get
the information of non-measured states. So to achieve better solutions in low cost applications one can use the proper
model of the system, information of easily measured parameters and some kind of observer or filter to get the information
of non-measured parameters.
The Kalman filter technique is one of the good methods employed to identify the speed and rotor-flux based on
The filter is optimal when the process noise and the measurement noise can be modelized by white Gaussian noise.
Non-linear problems can be solved with the Extended Kalman filter (EKF) and Unscented Kalman Filter (UKF). EKF is
based upon the principle of linearizing the state transition matrix and the observation matrix with Taylor series
expansions, while the UKF is based on unscented transform (UT).
The UT is founded on intuition that “it is easier to approximate a probability distribution than it is to approximate an
arbitrary non linear function or transformation” [2]. Instead of using linearized equations to approximate the non linear
model as EKF method UKF intentionally generates a finite set of points known as sigma points. These sigma points are
transformed to a new set of points using nonlinear model. System states and associated error covariance matrices are
determined numerically based on the mean and covariance values of the transformed sigma points.
The dynamic equations, derived [4] in are cast in state-space form as follows:
(1)
(2)
Where;
is the output vector
R is the resistance of the coils
L is the inductance of the coils
λ is the motor torque constant depending on the design of the rotor
J is the inertia of the rotor and the load
θ(t ) is the actual rotor position
θ is the location of the coil a in the stator
ω is the rotational velocity of the rotor
ia is the current in the coil as function of time
The model described above conforms to the general state space model given by;
(3)
(4)
x, u and y are called the state, input and output vectors, respectively.
where;
In the mathematical point view, the KF is a set of equations that provides an efficient recursive computational
When applied to a physical system, the observer or filter will be under the influence of two noise sources:
1. Process noise - e.g., thermic noise in a resistor, which is a part of the system.
The extended Kalman filter extends the scope of Kalman filter to nonlinear optimal filtering problems by forming a
Gaussian approximation to the joint distribution of state x and measurements y using a Taylor series based
transformation. In EKF the Jacobians of f and h are calculated around the estimated state.
n
A nonlinear system with state vector x(k) є R is given by the nonlinear stochastic difference equation [6]
m
With a measurement z (k) є R
To estimate a process with non-linear difference and measurement relationship, we begin by writing new governing
equations that linearize an estimate about (5) and (6)
where, x(k 1) and z(k) are the actual state and measurement state, x̂ (k+1)and zˆ (k ) are the approximate and
measurement vectors, xˆ (k ) is an a posteriori estimate of the state at step k. the random variables w(k) and v(k)
represents the process and measurement noise.
f (i )
A[i , j ] ( xˆ (k ), u(k ),0) (9)
x( j )
f (i )
W[i , j ] ( xˆ (k ),0) (10)
w( j )
h(i )
H [i , j ] ( xˆ (k ), u (k ),0) (11)
x( j )
V is Jacobian matrix of partial derivatives of h(.) with respect to w,
f (i )
V[i , j ] ( xˆ (k ),0) (12)
v( j )
Note that for simplicity in the notation we do not use the time step subscript k with Jacobians F,W,H,V even thought they
are in fact different at each time step.
xˆ (k 1) f ( xˆ (k ), u (k ), 0) (13)
xˆ (k ) xˆ (k ) K (k )( z (k ) h( xˆ (k ), 0)) (15)
K (k ) P (k ) H T (k )( H (k ) P (k ) H T (k ) V (k ) R(k )V T (k )) 1 (16)
P(k ) ( I K (k ) H (k )) P (k ) (17)
where K is the Kalman gain matrix, used in the update observer, and is the covariance matrix for the estate estimation,
containing information about the accuracy of estimate.
The unscented Kalman filter (UKF), an extension of the Kalman filter that reduces the linearization errors of the EKF.
The use of the UKF can provide significant improvement over the EKF.
yk = h( xk ,tk ) + uk (19)
ωk (0,Qk) (20)
vk (0,Rk) (21)
Where Q and R are the covariance of the process noise ωk and the measurement noise vk, respectively.
x̂ 0+ = E( x0) (22)
III. The following time update equations are used to propagate the state estimate and covariance from one measurement
time to the next.
(a) To propagate from time step (k - 1) to k, first choose sigma points xk-1( i ), with appropriate changes since the current
best guess for the mean and covariance of xk are x̂ k-1+ and Pk-1+ :
x̂ k-1(i) = x̂ k-1+ + ~
x (i) i=1,…,2n (24)
~
x (i) = ( nP )iT i=1,……,n (25)
~
x (n+i) = -( nP )iT i=1,……,n (26)
(b) The known nonlinear system equation f ( xk ,uk ,tk ) is used to transform the sigma points into x̂ k(i) vectors with
appropriate changes since our nonlinear transformation is f ( xk ,uk ,tk ) rather than h( xk ,tk ) :
(c) Combine the x̂ k(i) vectors to obtain the priori state estimate at time k.
1 2n
x̂ k- = x̂ k(i)
2n i 1
(28)
(d) The a priori error covariance is estimated. However, one should add Qk-1 to the end of the equation to take the
process noise into account:
1 2n
P k- =
2n i 1
( x̂ k(i) - x̂ k- )( x̂ k(i) - x̂ k- )T + Qk-1 (29)
4. Now that the time update equations are done to implement the measurement update equations:
(a) Choose sigma points xk( i ), with the current best guess for the mean and covariance of xk are x̂ k- and Pk-, as above
mentioned. This step can be omitted if desired. That is, instead of generating new sigma points one can reuse the sigma
points that were obtained from the time update. This will save computational effort, but would sacrifice performance [26,
27].
(b) The known nonlinear measurement equation h( xk ,tk ) is used to transform the sigma points in ŷ k(i) vectors (predicted
measurements):
(c) Combine the ŷ k(i) vectors to obtain the predicted measurements at time k .
1 2n
ŷ k = ŷ k(i)
2n i 1
(31)
(d) The covariance of the predicted measurement is estimated. However, one should add Rk to the end of the equation to
take the measurement noise into account:
1 2n
Py = ( ŷ k(i) - ŷ k )( ŷ k(i) - ŷ k )T + Rk-1
2n i 1
(32)
1 2n
Pxy =
2n i 1
( x̂ k(i) - x̂ k- ) ( ŷ k(i) - ŷ k )T (33)
(f) The measurement update of the state estimate can be performed using the normal Kalman filter equations [12]:
x̂ k+ = x̂ k- + Kk (yk - ŷ k ) (35)
The simulation provides the computed (true) and the estimated winding currents, ia and ib, together with speed , and
position, . The state estimation covariance, P, is also computed. This is an indicator of the goodness of the estimate.
Fig.6 shows that the estimation covariance is high using EKF. This is an evidence of poor estimation. While on using
UKF its peak is small as compare to EKF Measurement noise, R, was found to be less significant in estimating the states.
Therefore, it is advisable to take a great care in choosing the elements of the matrix Q.
1.5
True
Estimated ekf
1 Estimated ukf
Winding A Current (Amps)
0.5
-0.5
-1
0 0.5 1 1.5 2
Time (Seconds)
Figure.2
1.5
True
Estimated ekf
1 Estimated ukf
Winding B Current (Amps)
0.5
-0.5
-1
0 0.5 1 1.5 2
Time (Seconds)
Figure.3
8
True
6 Estimated ekf
Estimated ukf
Rotor Speed (Radians / Sec) 4
-2
-4
-6
-8
0 0.5 1 1.5 2
Time (Seconds)
Figure.4
10
True
9
Estimated ekf
8 Estimated ukf
Rotor Position (Radians)
7
6
5
4
3
2
1
0
-1
0 0.5 1 1.5 2
Time (Seconds)
Figure.5
Trace(P)
60
ekf
ukf
50
40
30
20
10
0
0 0.5 1 1.5 2
Seconds
Figure.6
5. CONCLUSION
The focus of this work is the sensorless speed and position measurement of a two-phase stepper motor. A dynamic
mathematical model of the stepper motor is derived and formulated into state space model for easy analysis and
manipulation. The EKF and UKF are, then, applied to the developed motor model. The model, which is inherently
nonlinear, is linearized prior to the EKF application using Jacobian. Simulation results have shown good agreement
between true and estimated states.
To verify the state estimation performance of the UKF and the EKF, a number of simulations were carried out for
different operating conditions and parameter settings. The simulations were implemented using Matlab.
A crucial step in the design of the Kalman filters is the choice of the elements of the covariance matrices Q and R, as
they will affect the performance, convergence and stability. The use of large values in Q presumes high model noise
and/or parameter uncertainties. An increase in the values of the elements of Q will likewise increase the Kalman gain,
resulting in faster filter dynamics but poorer steady-state performance. Matrix R is related to the measurement noise.
Increasing the values of the elements of R will assume that the current measurements are more affected by noise and thus
less reliable. Consequently, the filter gain will decrease, yielding poorer transient response
References
[1] Azzeddine Ferrah, Jehad Al-Khalaf Bani-Younes, Mounir Bouzguenda, and Abdelkader Tami, “Sensorless Speed
and Position Estimation in a Stepper Motor”, IEEE 2007.
[2] Julier, S. J. and Uhlmann, J. K., “Unscented Filtering and Nonlinear Estimation”, Proceedings of The IEEE, Vol. 92,
No. 3, March 2004.
[3] Julier, S. J. and Uhlmann, J. K., “Unscented Filtering and Nonlinear Estimation”, Proceedings of The IEEE, Vol. 92,
No. 3, March 2004.
[4] A. Ferrah, K. Al-Bahrani, B. Al-Kindi, F. Al-Jaradi, A. Al-Blushi, “Sensorless Speed and Position Estimation in a
Two-Phase Stepper Motor,” BEng Thesis, Sohar University, June 2005
[5] R.E. Kalman “ A New Approach to Linear Filtering and Prediction Problem” Transaction of ASME, Journal of
Basic Engineering, pp.35-45, March 1960.
[6] Greg Welch and Gary Bishop, "An Introduction to the Kalman Filter," University of North Carolina, July 24, 2006.
[7] Dan Simon, “Using Nonlinear Kalman Filtering to Estimate Signals,” 2003, (d.j.simon @ccsuohio.edu).
[8] Dan Simon, “Kalman Filtering and Neural Networks” Johon Wiley and Sons, Inc.2001.
[9] Dan Simon, “Optimal State Estimation:Kalman, H∞ , and Nonlinear Approaches,”John Wiley & Sons Inc., 2006.
[10] Dr. Amjed J. Hamidi, Ahmed Alaa Ogla & Yaser Nabeel Ibrahem, “State Estimation of Two-Phase Permanent
Magnet Synchronous Motor”, Eng. & Tech. Journal, Vol.27, No.7,2009.
AUTHORS
Dr. (Mrs.) J. M. Nair received B.Sc. degree in Electrical Engineering university of Kerala, INDIA in 1984
with First Class with Distinction, the M. Tech. degree in Controls Systems from University of Kerala, INDIA
in 1986 with First Class with Distinction and the Ph.D. degree in Systems & Control Engineering with
research topic Robust Control of Singularly Perturbed System from IIT Bombay, INDIA in 1995.
She joined in V.E.S. Institute of Technology, University of Mumbai as Lecturer in 1986 and promoted as a
Principal in 2004.
Her current research interests include fractional control systems & error analysis.
Vandana N. Sharma received the B. Tech. degree in Electronics and Instrumentation Engineering from
M.P.E.C., Kanpur, INDIA, M.E. degree in Instrumentation & Control Engineering from VES Institute of
Technology, Mumbai, INDIA in 2006 and 2013, respectively. From 2006 to 2010 she has worked as lecturer
in R.K.G.I.T. Engineering College Ghaziabad. Her areas of interest are control system and basic Electronics.