## 1 Introduction
The Maxwell stress method needs to use large-scale matrix and integration, which is normally used in the case of using the iron core. The Lorentz force equation method is the easiest way to calculate the electromagnetic force, and the conditions of using this method are met for the surface mount permanent magnet array and coreless winding structure. Thus, the Lorenz force equation method [24; 25; 26] is widely adopted to calculate the electromagnetic force for the maglev planar motor. However, this method can not be directly used to calculate the electromagnetic force on the corner segment of the winding, therefore, the shape of the real winding needs to be simplified. In the paper [27], they have simplified it into either four straight filaments or four rectangular surfaces. The paper [28] treats the winding as four straight current carrying volumes. The above methods have the disadvantage of overlapping the corner segment of the winding. The paper [29] treats the winding as four trapezoids, which does not overlap the corner segment of the winding and does not take the real shape of the corner segment into account either. For all the above methods, the real electromagnetic force on the corner segment has been simplified and does not reflect the real force, thus leading to the inaccurate computation model of the electromagnetic force and torque. The paper [30] proposes a magnetically levitated positioner using square coils and 1-D Halbach array, in which the electromagnetic force and torque modeling of the corner windings are converted to the polar coordination system. This method can improve the accuracy of the electromagnetic force and torque of the corner windings, however it is obvious that converting coordination is needed both before and after the computation. The paper [31] proposes the parallel computation of a wrench model for the maglev planar motor moving magnets. Normally the maglev planar motor moving magnetshas more windings than moving coils, and needs a coil switch and other algorithms during control process. To make the established model, a program running on CPU and GPU respectively can achieve better real-time control ability. However, the program for the maglev planar motor moving coils has less computation, thus, it is more concise and effective to program that portion once good real-time performance is obtained. To reduce the modeling error and, in the meantime, maintain the simplicity of the program and the real-time performance during operation, this paper proposes a new method to accurately calculate the electromagnetic force and torque based on a real-time computation model. The coil is divided into the straight coil segment and the corner coil segment based on its structure. For the straight coil segment, the traditional Lorenz force method can be used to compute its electromagnetic force and torque, which is a function of the mover position. For the corner coil segment, however, the numerical computation method can be used to get its respective electromagnetic force and torque. Based on the above separate analysis, an electromagnetic model can be derived that is suitable for practical real-time application, and the model decoupling computation can be achieved on NI PXI platform concisely and effectively.