Synthesis of cogging torque in permanent magnet machines by superposition