# A Low Torque Ripple Direct Torque Control Method for Interior Permanent Magnet Motor
## 2 Torque Analysis and Proposed DTC
### Mathematical Model of PMSM and Relationship between Voltage Vector and Torque  
The PMSM voltage and current equations in the \(d\)-\(q\) frame can be respectively expressed as [14]  
\[\left\{ \begin{array}{l}V_{d}=R_{s}i_{d}+\frac{dV_{d}}{dt}-\omega_{e}W_{q}\\ V_{q}=R_{s}i_{q}+\frac{dV_{q}}{dt}+\omega_{e}W_{d}\end{array} \right. \tag{2}\]  
and  
\[\left\{ \begin{array}{l}i_{d}=\frac{\psi_{d}-\psi_{f}}{\psi_{d}^{L_{d}}}\\ i_{q}=\frac{1}{L_{q}}\end{array} \right. \tag{3}\]  
where \(V_{d},~{}V_{q}\) are \(d\)-\(q\)-axis voltage, \(i_{d},~{}i_{q}\) are \(d\)-\(q\)-axis current, \(\psi_{d},~{}\psi_{q}\) are \(d\)-\(q\)-axis flux linkage, \(\psi_{f}\) is flux linkage due to permanent magnet (PM), \(\omega_{e}\) is electric angular speed, \(L_{d},~{}L_{q}\) are \(d\)-\(q\)-axis inductance, and \(R_{s}\) is stator resistance. Substituting Equation (3) into (2) with a rearrangement yields  
\[\left[ \begin{array}{c}\frac{dV_{d}}{dt}\\ \frac{dV_{d}}{dt}\\ \frac{dV_{d}}{dt}\\ \end{array} \right]=\left[ \begin{array}{ccc}-\frac{R_{s}}{L_{d}}&\omega_{e} &\frac{R_{s}}{L_{d}}\\ -\omega_{e}&-\frac{R_{s}}{L_{q}}&0\\ 0&0&0\end{array} \right]\left[ \begin{array}{c}\psi_{d}\\ \Psi_{q}\\ \psi_{f}\end{array} \right]+\left[ \begin{array}{ccc}1&0\\ 0&1\\ 0&0\end{array} \right]\left[ \begin{array}{c}V_{d}\\ V_{q}\end{array} \right] \tag{4}\]  
Base on Equation (4), for digital implementation of the DTC, the discrete flux linkages of the motor in the \(d\)-\(q\) frame at time increment \(t_{k+1}\) can be calculated by  
\[\psi_{d(k+1)}=\psi_{dk}+\left(-\frac{R_{s}}{L_{d}}\psi_{dk}+\frac{R_{s}}{L_{d} }\psi_{f}+V_{dk}+\omega_{ek}\psi_{qk}\right)\!T_{s} \tag{5}\]  
\[\psi_{q(k+1)}=\psi_{qk}+\left(-\frac{R_{s}}{L_{q}}\psi_{qk}+V_{qk}-\omega_{ek} \psi_{dk}\right)\!T_{s} \tag{6}\]  
where \(T_{s}\) is the period of one control action or sampling, and all the symbols with subscript \"\(k\)\" or \"\((k+1)\)\" indicate the physical quantities that are obtained at time increment \(t_{k}\) or \(t_{k+1}\), respectively. By substituting Equations (5) and (6) into (3), the \(d\)-\(q\) axis current at \(t_{k+1}\) can be obtained as  
\[i_{d(k+1)}=\frac{\psi_{dk}-\psi_{f}+\left(-\frac{R_{s}}{L_{d}}\psi_{dk}+\frac {R_{s}}{L_{d}}\psi_{f}+V_{dk}+\omega_{ek}\psi_{qk}\right)\!T_{s}}{L_{d}} \tag{7}\]  
\[i_{q(k+1)}=\frac{\psi_{qk}+\left(-\frac{R_{s}}{L_{q}}\psi_{qk}+V_{qk}+\omega_{ ck}\psi_{qk}\right)\!T_{s}}{L_{q}} \tag{8}\]  
The electromagnetic torque \(T_{e}\) of the PMSM can obtained as [15; 16]  
Figure 1: The \(f\)-\(t\) frame and \(d\)-\(q\) frame [12; 13]. \[T_{\epsilon}=\frac{3}{2}p(\Psi_{s}\times i_{s}) \tag{9}\]  
where \(p\) is number of pole pairs, \(i_{s}\) is armature current and \(\Psi_{s}\) is stator flux linkage vector whose \(d\)- and \(q\)-axis components are, respectively, \(\Psi_{d}\) and \(\Psi_{q}\). By substituting Equations (5)-(8) into (9), the torque at \(t_{k+1}\) can be calculated and expressed as  
\[T_{\epsilon(k+1)}=T_{ak}+T_{ik}+\Delta T_{1k}+\Delta T_{2k}+\Delta T_{3k}+ \Delta T_{4k} \tag{10}\]  
where  
\[T_{ak}=\frac{3p}{2L_{q}}\Psi_{qk}\Psi_{dk}, \tag{11}\]  
\[T_{lk}=\frac{3p}{2L_{d}}\big{(}\Psi_{f}-\Psi_{dk}\big{)}\Psi_{qk}, \tag{12}\]  
\[\Delta T_{1k}=-\frac{R_{s}}{L_{q}}T_{ak}T_{s}, \tag{13}\]  
\[\psi_{q(k+1)}=\psi_{qk}+\left(-\frac{R_{s}}{L_{q}}\psi_{qk}+V_{qk}-\omega_{ek} \psi_{dk}\right)\!T_{s} \tag{6}\]0  
\[\psi_{q(k+1)}=\psi_{qk}+\left(-\frac{R_{s}}{L_{q}}\psi_{qk}+V_{qk}-\omega_{ek} \psi_{dk}\right)\!T_{s} \tag{6}\]1  
\[\psi_{q(k+1)}=\psi_{qk}+\left(-\frac{R_{s}}{L_{q}}\psi_{qk}+V_{qk}-\omega_{ek} \psi_{dk}\right)\!T_{s} \tag{6}\]2  
where \(T_{ak}\) and \(T_{kk}\) are the torque components at \(t_{k}\), and \(\Delta T_{1k}\) to \(\Delta T_{4k}\) are the four terms that cause torque variations affecting the torque at \(t_{k+1}\). The physical meaning of these four terms, namely \(\Delta T_{1k}\) to \(\Delta T_{4k}\), are explained as follows:  
1.