Two-Dimensional Analytical Calculation of Magnetic Field and Electromagnetic Torque for Surface-Inset Permanent-Magnet Motors