Compensation of permanent magnet motors torque ripple by means of current supply waveshapes control determined by finite element method | Synapse