A matrix converter that directly converts input three-phase AC power into three-phase AC power and outputs the converted three-phase AC power to a load, the matrix converter comprising: - a bidirectional switch circuit that switches on and off a supply of the input three-phase AC power to the load; and - a controller that -- generates switching patterns of the bidirectional switch circuit so as to perform different virtual AC/DC conversion processes according to a plurality of modes which are divided depending on magnitude correlation between respective phase voltages in the input three-phase AC power, with respect to the input three-phase AC power, to select two phases from the input three-phase AC power, and to perform different virtual DC/AC conversion processes according to the plurality of modes with respect to line voltages of the two selected phases, -- generates the switching patters of the bidirectional switch circuit so as to perform the virtual AC/DC conversion processes with respect to the input three-phases AC power using different first carrier waveform patterns according to the plurality of modes, to select two phases from the input three-phase AC power, and to perform the virtual DC/AC conversion processes with respect to the line voltages of the two selected phases using different second carrier waveform patterns according to the plurality of modes, -- calculates, wherein in each of the plurality of modes, as the virtual AC/DC conversion processes, a plurality of line voltage generating sections from the first carrier waveform patterns and first control signals corresponding to input side phases, and as the virtual DC/AC conversion processes, generates the second carrier waveform patterns corresponding to the plurality of line voltage generating sections, and generates the switching patterns (ΦSRU to ΦSTW) of the bidirectional switch circuit from the generated second carrier waveform patterns and second control signals corresponding to output side phases. - a bidirectional switch circuit that switches on and off a supply of the input three-phase AC power to the load; and - a controller that -- generates switching patterns of the bidirectional switch circuit so as to perform different virtual AC/DC conversion processes according to a plurality of modes which are divided depending on magnitude correlation between respective phase voltages in the input three-phase AC power, with respect to the input three-phase AC power, to select two phases from the input three-phase AC power, and to perform different virtual DC/AC conversion processes according to the plurality of modes with respect to line voltages of the two selected phases, -- generates the switching patters of the bidirectional switch circuit so as to perform the virtual AC/DC conversion processes with respect to the input three-phases AC power using different first carrier waveform patterns according to the plurality of modes, to select two phases from the input three-phase AC power, and to perform the virtual DC/AC conversion processes with respect to the line voltages of the two selected phases using different second carrier waveform patterns according to the plurality of modes, -- calculates, wherein in each of the plurality of modes, as the virtual AC/DC conversion processes, a plurality of line voltage generating sections from the first carrier waveform patterns and first control signals corresponding to input side phases, and as the virtual DC/AC conversion processes, generates the second carrier waveform patterns corresponding to the plurality of line voltage generating sections, and generates the switching patterns (ΦSRU to ΦSTW) of the bidirectional switch circuit from the generated second carrier waveform patterns and second control signals corresponding to output side phases. -- generates switching patterns of the bidirectional switch circuit so as to perform different virtual AC/DC conversion processes according to a plurality of modes which are divided depending on magnitude correlation between respective phase voltages in the input three-phase AC power, with respect to the input three-phase AC power, to select two phases from the input three-phase AC power, and to perform different virtual DC/AC conversion processes according to the plurality of modes with respect to line voltages of the two selected phases, -- generates the switching patters of the bidirectional switch circuit so as to perform the virtual AC/DC conversion processes with respect to the input three-phases AC power using different first carrier waveform patterns according to the plurality of modes, to select two phases from the input three-phase AC power, and to perform the virtual DC/AC conversion processes with respect to the line voltages of the two selected phases using different second carrier waveform patterns according to the plurality of modes, -- calculates, wherein in each of the plurality of modes, as the virtual AC/DC conversion processes, a plurality of line voltage generating sections from the first carrier waveform patterns and first control signals corresponding to input side phases, and as the virtual DC/AC conversion processes, generates the second carrier waveform patterns corresponding to the plurality of line voltage generating sections, and generates the switching patterns (ΦSRU to ΦSTW) of the bidirectional switch circuit from the generated second carrier waveform patterns and second control signals corresponding to output side phases.