A rotary machine control device for controlling a rotary machine having a multi-group multiphase configuration, the rotary machine control device comprising: - a power converter formed by connecting a plurality of phase legs in parallel, each phase leg having an upper arm switching element and a lower arm switching element connected in series to each other; and - a control unit for generating switching signals for switching the upper arm switching elements and the lower arm switching elements, to control the rotary machine , wherein - a phase difference θcoil in a range of 150° ≤ θcoil < 180° or 180°< θcoil ≤ 210° is electrically provided between a winding for an odd-number group and a winding for an even-number group in the rotary machine , and characterised in that a phase difference between a voltage command for the odd-number group and a voltage command for the even-number group in the rotary machine is set to 180° when an effective value of the voltage command for either of the odd-number group or the even-number group is equal to or smaller than a voltage threshold, and the phase difference between the voltage command for the odd-number group and the voltage command for the even-number group in the rotary machine is set to θcoil when the effective value of the voltage command is larger than the voltage threshold, and when an output torque is greater than a torque threshold, the phase difference between the voltage command for the odd-number group and the voltage command for the even-number group in the rotary machine is set to θcoil. - a power converter formed by connecting a plurality of phase legs in parallel, each phase leg having an upper arm switching element and a lower arm switching element connected in series to each other; and - a control unit for generating switching signals for switching the upper arm switching elements and the lower arm switching elements, to control the rotary machine , wherein - a phase difference θcoil in a range of 150° ≤ θcoil < 180° or 180°< θcoil ≤ 210° is electrically provided between a winding for an odd-number group and a winding for an even-number group in the rotary machine , and characterised in that a phase difference between a voltage command for the odd-number group and a voltage command for the even-number group in the rotary machine is set to 180° when an effective value of the voltage command for either of the odd-number group or the even-number group is equal to or smaller than a voltage threshold, and the phase difference between the voltage command for the odd-number group and the voltage command for the even-number group in the rotary machine is set to θcoil when the effective value of the voltage command is larger than the voltage threshold, and when an output torque is greater than a torque threshold, the phase difference between the voltage command for the odd-number group and the voltage command for the even-number group in the rotary machine is set to θcoil. characterised in that a phase difference between a voltage command for the odd-number group and a voltage command for the even-number group in the rotary machine is set to 180° when an effective value of the voltage command for either of the odd-number group or the even-number group is equal to or smaller than a voltage threshold, and the phase difference between the voltage command for the odd-number group and the voltage command for the even-number group in the rotary machine is set to θcoil when the effective value of the voltage command is larger than the voltage threshold, and when an output torque is greater than a torque threshold, the phase difference between the voltage command for the odd-number group and the voltage command for the even-number group in the rotary machine is set to θcoil. <EOS>