An investigation into the harmonic distortion in a four pole interior permanent magnet synchronous motor(IPMSM) having 24 slots stator with respect to permanent magnet shaping is described. It is shown by finite element analysis, by appropriately selecting the magnet shape, it is possible to achieve the minimum harmonic sequence of air gap magnetic flux density and cogging torque when stator configuration is invariable