An inverter device, comprising: a control circuit; a direct current power source including a positive side power source (Psp) and a negative side power source (Psn) connected in series at an intermediate potential point; first and second switching elements (Q1, Q2), to each of which a diode is connected in anti-parallel, and which are connected in series across the direct current power source; and a bidirectional switch, configured by connecting first and second switch elements (S1, S2) in anti-series or anti-parallel, one end of which is connected to the connection point connecting the first and second switching elements, (Q1, Q2) and the other end of which is connected to the intermediate potential point of the direct current power source, wherein the inverter device is configured to, when being in an operation mode, use the positive voltage of the direct current power source input via the first switching element, the negative voltage of the direct current power source input via the second switching element, and the intermediate voltage of the direct current power source input via the bidirectional switch to output an alternating current voltage, wherein the control circuit is configured to, in a portion of a cycle in which the polarity of an output voltage and the polarity of an output current are the same, alternately turn on and off predetermined two of the elements using a first PWM signal generated with a carrier signal of a first frequency, and wherein the inverter device is configured to, in a portion of a cycle in which the polarity of the output voltage and the polarity of the output current are different, alternately turn on and off predetermined two of the elements using a second PWM signal generated with a carrier signal of a second frequency lower than the first frequency to thereby output a predetermined alternating current voltage. a control circuit; a direct current power source including a positive side power source (Psp) and a negative side power source (Psn) connected in series at an intermediate potential point; first and second switching elements (Q1, Q2), to each of which a diode is connected in anti-parallel, and which are connected in series across the direct current power source; and a bidirectional switch, configured by connecting first and second switch elements (S1, S2) in anti-series or anti-parallel, one end of which is connected to the connection point connecting the first and second switching elements, (Q1, Q2) and the other end of which is connected to the intermediate potential point of the direct current power source, wherein the inverter device is configured to, when being in an operation mode, use the positive voltage of the direct current power source input via the first switching element, the negative voltage of the direct current power source input via the second switching element, and the intermediate voltage of the direct current power source input via the bidirectional switch to output an alternating current voltage, wherein the control circuit is configured to, in a portion of a cycle in which the polarity of an output voltage and the polarity of an output current are the same, alternately turn on and off predetermined two of the elements using a first PWM signal generated with a carrier signal of a first frequency, and wherein the inverter device is configured to, in a portion of a cycle in which the polarity of the output voltage and the polarity of the output current are different, alternately turn on and off predetermined two of the elements using a second PWM signal generated with a carrier signal of a second frequency lower than the first frequency to thereby output a predetermined alternating current voltage.