Simulation and Model
12.3 Simulation and Model
When designing a PMSM drive, it is useful to compose a computer simulation before building a prototype. Such a model can also be used to develop the control. A suitable model of the PMSM is set forth in this section. Much of the detail of development is omitted because it is not the purpose of this chapter to provide derivations, but simply to provide the reader with useful formulas for designing the electronics for PMSM drive systems. Full development of PMSM drive models is available from a number of references [1, 2].
If there are N phases, then there are N stator voltages, currents, and flux linkages. Let the set of stator voltages be represented compactly as
(12.1) where v x is the voltage across the x th phase. The same relationship holds for the vectors of current ( i ),
1 v 2 …v N ]
and flux linkage ( λ ). For the special and common case of three-phase machines, the letters a , b , and c are used in place of 1, 2, and 3, respectively, in Eq. (12.1). Since eddy current and hysteresis losses are generally small, it will suffice to attribute all stator losses to the winding resistance, r . Then, applying Faraday’s and Ohm’s laws, the stator voltage equation may and flux linkage ( λ ). For the special and common case of three-phase machines, the letters a , b , and c are used in place of 1, 2, and 3, respectively, in Eq. (12.1). Since eddy current and hysteresis losses are generally small, it will suffice to attribute all stator losses to the winding resistance, r . Then, applying Faraday’s and Ohm’s laws, the stator voltage equation may
d v = ri + ----- l
dt
Regarding the machine as balanced, symmetrical, and magnetically linear, the flux linkage equation may be written as
(12.3) where L is a symmetric N × N matrix of the appropriate self- and mutual inductances and λ pm is an
l = Li + l pm
N × 1 vector of stator flux linkages due to the permanent magnet. The inductance matrix is constant for machines with surface-mounted magnets, but has rotor position–dependent terms for machines with buried magnets.
The torque equation can be derived from coenergy relationships:
T -- i Li + i l
T e = --- ------- ∂ 1 T
pm T
2 ∂q 2 cog
where θ r is the electrical rotor position in radians, and P is the number of poles. Mechanical rotor position is θ rm = 2 θ r / P . The cogging torque is represented as T cog . Equations (12.2) to (12.4) represent a simulation model of the machine, provided that the resistance, r , the inductance matrix, L , the cogging torque, T cog , and the permanent magnet flux linkage vector, λ pm , are known. The parameters can be determined from direct measurement or by calculation from motor geometry (i.e., finite-element analysis). The mechanical dynamics of the system, which are not discussed here since they can widely vary, must be simulated to determine position and speed.
The model set forth is general for any number of phases and for the buried or surface-mounted magnet cases. For a surface-mounted magnet machine, the air gap is effectively very wide and uniform since the magnet material has a relative permeability near 1. This results in stator inductance, which is generally not dependent upon rotor position. In both the surface-mount and buried magnet cases, λ pm is a function of rotor position. Therefore, the torque equation for the surface-mounted case is
P T ∂ T ( e SM ) = --- i ------- l pm + T
2 ∂q
cog
and the torque equation for a machine with buried magnets is
= T --- i P -- 1 ∂
2 2 ------- L i∂ + ------- l
pm T + cog
T ( e BM )
∂q r ∂q r
where it is noted that the current, i , is not explicitly dependent on rotor position. The cogging torque may be represented as
cog =
∑ q T q cos ( zN t r )T + d sin ( zN t q r )
z ∈Z
where z Z is the set of natural numbers such that the Fourier series constants T q and T d are negligible and the constant, N t , is the number of stator teeth. The cogging torque is frequently ignored in designing the motor drive electronics or it is sufficiently negligible because of special machine design efforts. If
cogging torque is neglected, then the constants z T
q and T d are zero.
The power into the machine is simply the sum of the power into each phase:
(12.8) and the power output of the machine is
in = v i
(12.9) where ω rm is the mechanical rotor speed. In Eq. (12.9), the frictional and windage dynamics are assumed
P out = T e w rm
to be negligible or to be accounted for in the mechanical system model.
As a common special case of the model in Eq. (12.9), the analysis is restricted to three-phase machines
( N = 3). Frequently, the back emf of the machine has negligible harmonics, and thus it can be treated as if it is purely sinusoidal. As is common in buried magnet machine analysis, the rotor position variance of the stator inductance can be taken as sinusoidal. Furthermore, the cogging torque can be made small by utilizing certain design techniques. With these assumptions, a transformation of machine variables into the rotor reference frame can be made that facilitates vector control of the PMSM.
If the back emf is sinusoidal, then the flux linkage due the permanent magnets is as well. That is, λ pm
may be expressed as 2p T
l pm = l m sin () q r sin q r – ------ 2p sin q r + ------
(12.10) where λ m is a constant equal to the peak strength of the flux linkage due to the magnets. Note that
Eq. (12.10) implies a certain interpretation of the measured rotor position. Specifically, it implies that the magnet flux linking the first phase is zero when θ r = 0. Then, the back emf due to the permanent magnets may be stated as
w r l m cos () q r cos q r – ------ cos q r + ------ (12.11)
2p
2p T
pm
where ω r is the electrical rotor speed and equals P /2 times its mechanical counterpart, ω rm . Equation (12.11) is a useful expression for determining the constant λ m experimentally.
The rotor position–dependent terms can be eliminated by transforming the variables into a reference frame fixed in the rotor. Only the results of this long process are given here. The transformation is applied as
(12.12) where
v qd0 = Kv
(12.13) and [Ref. 1]
qd0 = [ v q v d v 0 ]
cos () q cos r – ------ 2p r q cos
2p ------
2 K = -- sin () q r sin q 2p r – ------ sin
q 2p r + ------
1 --
1 --
1 --
FIGURE 12.3 Diagram of simulation model. Similar relationships hold for flux linkage and current by replacing v with λ and i, respectively.
After transforming the equations into the rotor reference frame with Eq. (12.14), the following relationships hold:
v q = ri q + w r l d + -----l d q dt
v d = ri d – w r l q -----l d + d (12.15)
dt
d v 0 = ri 0 + -----l 0
dt l q = L q i q
T e = -- P ---l m i q + ( L d – L q )i d i q
where L q , L d , and L 0 are constant inductances, which are obtainable from measurement from finite- element analysis. In general, the inductance values are not very high, since the flux due to stator current is predominantly leakage, due to the effectively wide air gap.
It is important to note that for the surface-mounted machine, L d =L q because the stator inductances are independent of rotor position. This eliminates the second term in Eq. (12.17). For buried magnet motors, by the convention given L q >L d in general because the high-permeability paths are aligned with the q-axis. Also, it is common to wye-connect the three phases. In that case, i 0 = 0 and therefore both λ 0 = 0 and v 0 = 0 thereby eliminating the zero-sequence components completely. Under constant torque and speed conditions, each current, flux linkage, and voltage are also constant in Eqs. (12.15) to (12.17). Equations (12.15) to (12.17) represent a standard model for a PMSM with sinusoidal flux linkages for either the surface-mounted or buried magnet cases. A diagram of the simulation structure is shown in Fig. 12.3 , where numbers in parentheses refer to equation numbers.