A vehicle comprising: a transaxle comprising a sliding section and a bearing section, and having a rotary electric machine (M) that is configured to have a torque higher than a first specified value and to have a rotational speed higher than a second specified value; an inverter configured to supply current to the rotary electric machine (M); and an electronic control unit configured to control the inverter , the electronic control unit is configured to determine whether there is a possibility of occurrence of electrolytic corrosion in at least one of the sliding section and the bearing section of the transaxle , the vehicle being characterized in that the electronic control unit being configured to set a control mode of the inverter to: - a first mode on a condition that the electronic control unit determines that there is no possibility of occurrence of the electrolytic corrosion, and to - a second mode and maintain output of the rotary electric machine (M) at user request output on a condition that the electronic control unit determines that there is a possibility of occurrence of the electrolytic corrosion, - the second mode being a mode in which a frequency of a carrier signal is set to a frequency that further suppresses resonance with a stray current circuit of the rotary electric machine (M) in order to suppress the occurrence of the electrolytic corrosion compared to the first mode and in which the output of the rotary electric machine (M) is maintained at the user request output, - the frequency of the carrier signal in the second mode being larger than the frequency of the carrier signal in the first mode when the torque is higher than the first specified value, and - the frequency of the carrier signal in the second mode being larger than the frequency of the carrier signal in the first mode when the rotational speed is higher than the second specified value. a transaxle comprising a sliding section and a bearing section, and having a rotary electric machine (M) that is configured to have a torque higher than a first specified value and to have a rotational speed higher than a second specified value; an inverter configured to supply current to the rotary electric machine (M); and an electronic control unit configured to control the inverter , the electronic control unit is configured to determine whether there is a possibility of occurrence of electrolytic corrosion in at least one of the sliding section and the bearing section of the transaxle , the vehicle being characterized in that the electronic - a first mode on a condition that the electronic control unit determines that there is no possibility of occurrence of the electrolytic corrosion, and to - a second mode and maintain output of the rotary electric machine (M) at user request output on a condition that the electronic control unit determines that there is a possibility of occurrence of the electrolytic corrosion, - the second mode being a mode in which a frequency of a carrier signal is set to a frequency that further suppresses resonance with a stray current circuit of the rotary electric machine (M) in order to suppress the occurrence of the electrolytic corrosion compared to the first mode and in which the output of the rotary electric machine (M) is maintained at the user request output, - the frequency of the carrier signal in the second mode being larger than the frequency of the carrier signal in the first mode when the torque is higher than the first specified value, and - the frequency of the carrier signal in the second mode being larger than the frequency of the carrier signal in the first mode when the rotational speed is higher than the second specified value. <EOS>