An electric power steering apparatus for assisting steering of a motor vehicle by conferring torque generated by an electric motor to a steering mechanism by a rotation of a rotor of the motor in relation to a stator, the apparatus comprising: - a steering controller which receives signals representative of at least the torque (T TS) applied to a steering wheel and determining a target motor torque (T d), - a motor controller comprising a first control portion which receives the target motor torque (T d) from the steering controller and an electrical angular frequency (ω) of the rotor and transfers the target motor torque (T d) into target currents (id,d, iq,d) expressed in a coordinate system fixed to the electrical angular frequency (ω) of the rotating rotor, the motor controller comprising a coordinate transformation portion to transfer the target currents (id,d, iq,d) into target voltages (u α,d, u β,d) expressed in a coordinate system fixed to the stator and - an inverter which transforms the target voltages (u α,d, u β,d) into motor currents (i U,i V,i W), and - at least one ripple compensation unit (15, 150, 1500, 15000, 150000), characterized in that the ripple compensation unit (15, 150, 1500, 15000, 150000) which determines compensation voltages (u α,d comp, u β,dcomp) and the apparatus further comprises an adder to add the compensation voltages (u α,d comp, u β,dcomp) to the target voltages (u α,d, u β,d), wherein - the ripple compensation unit (15, 150, 1500, 15000, 150000) comprises a first ripple control portion which receives the target motor torque (T d) from the steering controller and an angular frequency (ω) of the rotor to transfer the target motor torque (T d) into compensation currents (idn,d, iqn,d) expressed in a coordinate systeme fixed to a rotating part, which rotates n-times higher than the electrical angular frequency (ω) of the rotating rotor, - the ripple compensation unit (15, 150, 1500, 15000, 150000) comprises a ripple coordinate transfer portion to transfer the compensation currents (idn,d, iqn,d) into compensation voltages (u α,dcomp, u β,dcomp) expressed in a coordinate system fixed to the stator and output the compensation voltages to the adder. - a steering controller which receives signals representative of at least the torque (T TS) applied to a steering wheel and determining a target motor torque (T d), - a motor controller comprising a first control portion which receives the target motor torque (T d) from the steering controller and an electrical angular frequency (ω) of the rotor and transfers the target motor torque (T d) into target currents (id,d, iq,d) expressed in a coordinate system fixed to the electrical angular frequency (ω) of the rotating rotor, the motor controller comprising a coordinate transformation portion to transfer the target currents (id,d, iq,d) into target voltages (u α,d, u β,d) expressed in a coordinate system fixed to the stator and - an inverter which transforms the target voltages (u α,d, u β,d) into motor currents (i U,i V,i W), and - at least one ripple compensation unit (15, 150, 1500, 15000, 150000), - the ripple compensation unit (15, 150, 1500, 15000, 150000) comprises a first ripple control portion which receives the target motor torque (T d) from the steering controller and an angular frequency (ω) of the rotor to transfer the target motor torque (T d) into compensation currents (idn,d, iqn,d) expressed in a coordinate systeme fixed to a rotating part, which rotates n-times higher than the electrical angular frequency (ω) of the rotating rotor, - the ripple compensation unit (15, 150, 1500, 15000, 150000) comprises a ripple coordinate transfer portion to transfer the compensation currents (idn,d, iqn,d) into compensation voltages (u α,dcomp, u β,dcomp) expressed in a coordinate system fixed to the stator and output the compensation voltages to the adder.