1. A control system for a rotary machine, the control system driving a switching element of a power converter to control a difference between a current actually flowing in the rotary machine and a command value therefor within an allowable range, the control system comprising: a calculating means that calculate a direction of change in the difference during an operating condition of the power converter being set to a zero vector; and a drive means comprising a reverse control means that switches, based on the calculated direction of change and the difference as inputs, a switching mode of the power converter phase by phase to drive the switching element in accordance with a switching pattern in which the operating condition of the power converter is shifted from a specified non-zero vector to the specified non-zero vector via the zero vector, thus controlling the difference such that the difference is shifted in a direction opposite to the direction of change in the difference, wherein a plurality of voltage vectors express the operating condition, the plurality of voltage vectors define a plurality of regions around a point at which the difference is zero, and when a steady-state condition in that: one voltage vector whose starting point is the point at which the difference is zero defines one boundary of one of the plurality of regions, and the difference is located out of the allowable range is met, the reverse control means: sets the one voltage vector to a first switching vector, the one voltage vector being the closest to a subtraction of the actually flowing current from the command value in the plurality of voltage vectors, the one of the plurality of regions containing a vector in the direction of change; sets, to a second switching vector, an alternative one voltage vector in some of the plurality of voltage vectors except for the one voltage vector, the some of the plurality of voltage vectors defining the boundary of the one of the plurality of regions; and controls the difference based on a switching pattern in which a switching vector is shifted in a order of the first switching vector, the second switching vector, and the first switching vector.