A device for estimating inductances (L d, L q) of an electric machine when a rotor of the electric machine is stationary, the device comprising a processing system configured to: - control stator voltages (u u, u v, u w) of the electric machine to constitute a balanced multi-phase alternating voltage, and estimate rotational position (θr) of the rotor based on a negative sequence component of stator currents (iu, iv, iw) of the electric machine, the negative sequence component being caused by saliency of the rotor, - control direct-axis current of the electric machine to be direct current and quadrature-axis voltage of the electric machine to be alternating voltage, - estimate quadrature-axis inductance (L q) of the electric machine based on the quadrature-axis alternating voltage and on quadrature-axis alternating current caused by the quadrature-axis alternating voltage, - control direct-axis voltage of the electric machine to be alternating voltage and the quadrature-axis voltage of the electric machine to be substantially zero, and - estimate direct-axis inductance (L d) of the electric machine based on the direct-axis alternating voltage and on direct-axis alternating current caused by the direct-axis alternating voltage wherein the processing system is further configured to: - set a ratio of amplitude of phase-voltages of the balanced multi-phase alternating voltage and frequency of the balanced multi-phase alternating voltage to be in a range from 5% to 15% of a ratio of amplitude of a nominal phase voltage of the electric machine and a nominal supply frequency of the electric machine so as to produce a rotating magnetic flux whose amplitude is in a range from 5% to 15% of a nominal magnetic flux of the electric machine. - control stator voltages (u u, u v, u w) of the electric machine to constitute a balanced multi-phase alternating voltage, and estimate rotational position (θr) of the rotor based on a negative sequence component of stator currents (iu, iv, iw) of the electric machine, the negative sequence component being caused by saliency of the rotor, - control direct-axis current of the electric machine to be direct current and quadrature-axis voltage of the electric machine to be alternating voltage, - estimate quadrature-axis inductance (L q) of the electric machine based on the quadrature-axis alternating voltage and on quadrature-axis alternating current caused by the quadrature-axis alternating voltage, - control direct-axis voltage of the electric machine to be alternating voltage and the quadrature-axis voltage of the electric machine to be substantially zero, and - estimate direct-axis inductance (L d) of the electric machine based on the direct-axis alternating voltage and on direct-axis alternating current caused by the direct-axis alternating voltage - set a ratio of amplitude of phase-voltages of the balanced multi-phase alternating voltage and frequency of the balanced multi-phase alternating voltage to be in a range from 5% to 15% of a ratio of amplitude of a nominal phase voltage of the electric machine and a nominal supply frequency of the electric machine so as to produce a rotating magnetic flux whose amplitude is in a range from 5% to 15% of a nominal magnetic flux of the electric machine.