## 3 Modeling and Design Optimization  
### Magnetic Field and Electromagnetic Force Expression  
For the planar motors to be applied in high-precision positioning systems, it is critical to build an accurate mathematical model. Through the model, the main motor parameters can be further optimized. Additionally, excellent control is based on an accurate model. Therefore, modeling is the basis for the motor analysis and optimization. According to the equivalent magnetic charge method [25; 26], a cubic permanent magnet can be represented by two charge surfaces, and the surface density of the magnetic charge is  
\[\sigma_{\mu}=\mu_{0}M_{r} \tag{4}\]  
Figure 3: Working principle of the Lorentz-force-driven planar motor. (**a**) Moving in the \(x\) axis; (**b**) Moving in the \(y\) axis; (**c**) Rotating about the \(z\) axis. where \(\mu_{0}\) is the vacuum permeability and \(M_{r}\) is the magnetization intensity. The expression of the magnetic field intensity can be written as  
\[\mathrm{d}\mathbf{H}=\frac{\sigma_{m}\mathrm{d}s}{4\pi\mu_{0}r^{2}}\mathbf{a}_{r} \tag{5}\]  
where \(\mathbf{a}_{r}\) is the unit vector from the field source point to the observation point and \(r\) is the distance from the field source point to the observation point, as shown in Figure 4.  
The \(z\)-axis component of the magnetic field intensity for one charge surface can be expressed as  
\[H_{z}=\int_{-b}^{b}\int_{-a}^{a}\frac{M_{r}}{4\pi}\frac{z}{\left[\left(x-x_{0} \right)^{2}+\left(y-y_{0}\right)^{2}+z^{2}\right]^{3/2}}dx_{0}dy_{0} \tag{6}\]  
where \(x_{0}\), \(y_{0}\) are the coordinates of the field source point and \(2a\), \(2b\) are the length and width of the permanent magnet, respectively. The final magnetic flux density expression of one cubic magnet can be derived as  
\[B_{z}=\frac{\mu_{0}M_{r}}{4\pi}\Bigg{\{} \begin{array}{c}\zeta(a-x,b-y,z-h_{M })+\zeta(a-x,b+y,z-h_{M})-\zeta(a-x,b-y,z)-\zeta(a-x,b+y,z)+\\ \zeta(a+x,b-y,z-h_{M})+\zeta(a+x,b+y,z-h_{M})-\zeta(a+x,b-y,z)-\zeta(a+x,b+y,z )\end{array} \Bigg{\}} \tag{7}\]  
\[\zeta(\zeta_{1},\zeta_{2},\zeta_{3})=arctg\frac{\zeta_{1}\zeta_{2}}{\zeta_{3 }\sqrt{{\xi_{1}}^{2}+{\xi_{2}}^{2}+{\xi_{3}}^{2}}} \tag{8}\]  
where \(h_{M}\) is the thickness of permanent magnet. Due to the existence of double-sided ferromagnetic boundaries, the air-gap magnetic field is not entirely decided by the permanent magnets. Using the image method, superposition principle, and coordinates transformation, the magnetic field expression generated by a couple of magnets under two parallel ferromagnetic boundaries can be derived as  
\[B_{z}=B_{z,original}+B_{z,image} \tag{9}\]  
where \(B_{z,\;original}\) is the magnetic field of original charge and \(B_{z,\;image}\) is the magnetic field of image charge. The proposed planar motor is a short-stroke motor, and the working range is about \(\pm 2\) mm. To simplify the model, the complex magnetic flux density expression can be represented by the amplitude of the magnetic flux density due to the short stroke. The expression of the magnetic flux density amplitude can be derived as  
\[B_{zm}=\frac{2\mu_{0}M_{r}}{\pi}X(\lambda,\gamma) \tag{10}\]  
Figure 4: Coordinate system. \[ \begin{array}{ll}X(\lambda,\gamma)&=arctg\frac{\lambda^{2}}{4\sqrt{\frac{1}{2} \lambda^{2}+1}}+arctg\frac{\lambda^{2}}{4\left|1\pm 2(1+2\gamma)\right|\sqrt{ \frac{1}{2}\lambda^{2}+\left|1\pm 2(1+2\gamma)\right|^{2}}}\\ &+arctg\frac{\lambda^{2}}{4\left|1\pm 4(1+2\gamma)\right|\sqrt{\frac{1}{2} \lambda^{2}+\left|1\pm 4(1+2\gamma)\right|^{2}}}\end{array}  \tag{11}\]  
where \(\lambda\) and \(\gamma\) are two main parameters relating to the motor size, the expressions of \(\lambda\) and \(\gamma\) are as follows,  
\[\lambda=\frac{\tau}{h} \tag{12}\]  
\[\gamma=\frac{h_{M}}{h} \tag{13}\]  
where \(\tau\) is the pole pitch of the planar motor, as shown is Figure 2, and \(h\) is the distance between the upper and lower magnet (i.e., the total thickness of the primary plus two mechanical air gaps).