Inverter uses a unidirectional DC power to mimic an alternating current (AC) power source. Electronic inverters are essentially oscillators that rapidly switch the polarity of the DC power source, which effectively creates a square wave.
Since most consumer electronics require something closer to a true sine wave, most inverters include additional components that create either a modified or pure sine wave.