# How do modified square and sine wave inverters work and which to use?

Today there are two kinds of inverters sold: modified square wave (sometimes erroneously marketed as "modified sine wave") and true sine wave. These allow converting low voltage direct current from solar panels or batteries to mains voltage alternating current.

How do these inverters work?

How to decide which inverter is the best option?

## 1 Answer

The simplest inverter is the modified square wave inverter. A typical schematic is here:

The battery is generally between 10 - 15 volts (assuming a 12 volt system, multiply by a suitable factor for 24 and 48 volt systems). The inverter has the input capacitor close to battery. Some cheaper models could theoretically omit the input capacitor. The direct current is chopped at very high frequency (maybe between 20 - 300 kHz) via a switch, typically MOSFET, into a transformer. The transformer has three windings: primary, secondary and reset winding. Because the frequency is high, the magnetization current is low and thus the transformer can be made very lightweight for the power going through it, but high-frequency materials (ferrite) must be used for the transformer core. For 12-to-230 volts, the turns ratio is about 1:23; for 12-to-120 volts it's about 1:12.

The transformer has a third reset winding used to return the magnetization energy back to the input capacitor. Without the reset winding, this energy would have nowhere to go after opening the primary switch since the diode on the secondary side prevents current from going into the secondary in the direction it wans to go. The reset winding has a diode which only allows this reset current but blocks current when the transformer primary is connected via the switch.

The secondary side has a diode and capacitor which work as a half-wave rectifier. Note there is no voltage control mechanism. So with 1:23 turns ratio, the secondary side has these voltages for different battery voltages:

• 15 volts (highest possible charging voltage): 345 volts, 6% over nominal peak voltage
• 12.7 volts (fully charged battery at rest): 292 volts, 10% below nominal peak voltage
• 12 volts (fully charged battery with high load): 276 volts, 15% below nominal peak voltage
• 11 volts (empty battery at rest): 253 volts, 22% below nominal peak voltage
• 10 volts (empty battery with high load): 230 volts, 29% below nominal peak voltage

Note the lack of any kind of voltage regulation in this design. If the battery voltage reduces due to end of charging, due to emptying battery, or due to high load, the peak voltage of the output reduces too.

The regulation in this modified square wave design is via the width of square wave pulses. The full H bridge consisting of 4 switches alternately switches the output to positive, unconnected and negative. When the battery is at 10 volts, the pulses are full width and create 230 V RMS. When the battery is at 15 volts, the pulses are 345 volts so their width are 44% of full width.

This pulse width regulation only works for resistive loads and loads having their own regulation. It does not work for loads dependent on the peak voltage of the waveform.

The output switches (MOSFETs usually) have diodes across them allowing inductive loads to return back their energy to the output capacitor.

Only for a battery under charge is the peak voltage of the waveform approximately equal to the peak voltage of a 230 volt sine wave (325 volts). Once charging ends, the output waveform no longer has the right peak voltage.

Since the output MOSFETs are switched at the mains frequency (50 or 60 Hz), the MOSFETs and the circuit driving them can be cheap and still not waste any significant amount of power.

However, where power is wasted is in the magnetization of the primary side of transformer. Every pulse creates an increasing magnetization current that is returned via the diode back to the input capacitor. However, part of this magnetic energy may be converted to heat in nearby metallic materials, part may be converted to heat in resistance of the transformer windings, and part may be converted to heat in the diode that supplies it back to the input capacitor.

A good design of this modified square wave inverter would vary the width and frequency of pulses to the transformer according to the load. If the load is low, it may create a narrow pulse only occasionally; if the load is high, the frequency of pulses is high and pulse width is the maximum it can be to still allow enough time to supply back the magnetization energy to the input capacitor inbetween pulses. This good design would waste minimal power at idle. So it's possible to create an inverter that wastes way less than 1 watt at idle, while at the same time having continuous 230 volt output and allowing connecting devices consuming thousands of watts anytime.

Unfortunately, if you today buy a modified square wave inverter, with more than 99% certainty it's a bad design. So it's very likely the idle energy usage is between 5-10 watts.

Also practically all modified square wave inverters have safety guards built in case where the charging voltage of the battery rises to such high levels the output peak voltage would be unacceptably high, or when the battery becomes so flat the output would have unacceptably low peak voltage and the correct RMS voltage can't be achieved with even 100% duty cycle.

A true sine wave inverter is only slightly different: it adds an LC filter between the full H bridge and the output load.

However, a true sine wave inverter would likely have better MOSFETs and better circuitry driving them, because a true sine wave inverter chops the output at very high frequency (maybe between 50 - 300 kHz). The idea is that the output is a pulse width modulated sine wave. It contains the sine wave of the right frequency and amplitude (50 or 60 Hz), and a truckload of very high frequency harmonics. The LC filter consisting of an inductor and capacitor filters away most of these high frequency harmonics, leaving the 50 or 60 Hz sine wave.

Note that pulse width modulation can be used to vary the amplitude of the output too, not just the frequency. So a true sine wave inverter would have a turns ratio that allow creating the desired 325 volt peak voltage also with a flat battery under high load (10 volts), so the turns ratio would probably be around 1:33 or maybe even higher for some safety margin.

A true sine wave inverter has to constantly charge and discharge the LC filter capacitor via the LC filter inductor. Although the energy isn't completely wasted, it's just ping-ponging between the transformer output capacitor and LC filter capacitor, nothing is 100% efficient. For example the inductor windings have resistance which wastes this energy as heat and the diodes providing a pathway for this current also waste energy as heat too. Additionally, since the MOSFETs are switched at high frequency, the switching losses are high. Every time a MOSFET is switched on or off, there is a slight transition event when it's neither fully on nor fully off, it behaves instead as a high resistance, which creates heat too.

So the characteristics of inveters are

1. Modified square wave:
• Lacks any kind of output voltage regulation, regulates instead via duty cycle
• Can have very low idle power waste, but usually has intermediate idle power waste
• Output waveform typically is lacking in peak voltage
• Output waveform doesn't at all resemble a sine wave even remotely
• Cheap since output MOSFETs are driven at lower frequency and high-current inductor in LC filter avoided, in fact this device doesn't have any inductor at all, just a transformer
2. True sine wave:
• Is able to regulate voltage perfectly
• Usually has high idle power waste
• Output waveform is true sine wave with correct peak voltage all the time, and usually the waveform is cleaner than you get via electricity grid (since the grid has lots of old devices connected without power factor correction that only draw power during the peak of the waveform, flattening the peaks)
• Expensive since output MOSFETs are driven at higher frequency and high-current inductor in LC filter needed, and inductors handling high current and storing significant amounts of energy in magnetic field are expensive

Also some true sine wave inverters, usually in cheap Chinese power stations, have an additional trick: if you connect a too high resistive load to them, they can artificially lower the output voltage. So with a 1000 watt inverter, you may be able to use a 1400 watt coffeemaker, but the output voltage is reduced so that the coffeemaker heating element is only heating water at a power level of 1000 watts. Whether the other devices connected to the output at the same time are affected by this varies from device to device.

As for what devices work with inverters:

1. True sine wave:
• Every device works, always, since the power is better than mains power
• However, some devices such as refrigerators, air conditioning compressors and power tools draw a high surge current during startup which may exceed the surge current rating of the inverter even though the inverter would be capable of supplying the continuous current used by the device; this can be avoided by choosing a big enough inverter
2. Modified square wave:
• Resistive loads such as toasters, coffeemakers and heaters work always with the correct amount of power, this includes any incandescent or halogen light bulb too
• Anything with a switched mode power supply such as computers, mobile phone chargers, most LED lamps, audio equipment, inverter microwaves, etc. work since the switched mode power supply doesn't really care about the waveform
• Anything that depends on the peak voltage of the waveform may not work perfectly. Example: traditional microwaves without inverter do not always create the right amount of power since the peak voltage of the waveform when the battery is not under charge is typically somewhat deficient; the flatter the battery is, the worse the problem; the longer the wires from the battery to the inverter, the worse the problem
• Devices that have a capacitor+resistor power supply lacking a Zener diode, typically low power very cheap power measurement/switching devices, may not work. Examples of such devices can be digital kilowatthour meters, or digital timer switches. The reason for this is that the manufacturer used a capacitor to create a known current directly from mains, and a resistor to convert the current to desired voltage, and then use a diode+capacitor to make that voltage DC. The simple addition of a Zener diode or replacing the resistor with a Zener diode would have solved the problem, but some manufacturers have cheaped out and used only a resistor where a Zener diode should have been used. Not all kilowatthour meters suffer from this problem: I have two brands, one suffers from it, another doesn't. The failure mode is that the device works for maybe a fraction of a second or few seconds, then it breaks, as every cycle leads to higher-and-higher voltage at the capacitor.
• Motors in refrigerators, fans and air conditioning units may buzz and/or create excess heat. Whether or not this is a problem depends on the circumstances.
• Fans that use a TRIAC to trigger the current into an induction motor at certain moment of the waveform do not work. This also affects some light dimming circuits (but those circuits only work for incandescent or halogen bulbs or for LED bulbs that have been specifically designed to work with such dimmers; normal LED bulbs don't work). I haven't tested corded drills but some may use a TRIAC based power control too.

It's a common myth that "sensitive electronics" such as computers would require true sine wave. This is completely false. Such "sensitive electronics" use a switched mode power supply that works well with just about any waveform, often including waveform that is DC and not AC at all assuming it has approximately the correct voltage!

However, cheap power handling electronics, typically digital kilowatthour meters and digital timers are more at risk; the cheaper the device the greater the likelihood that the manufacturer wanted to save the cost of a single Zener diode which would have solved the problem.

All grid tie inverters supplying solar power to the electricity grid have to be true sine wave for two reasons: (1) the waveform in the grid is a true sine wave, (2) the grid tie inverter has to be able to adjust the output voltage continuously according to conditions in the grid.

Inverter generators typically have a true sine wave output, but they do some simplification: an inverter generator would create the required direct current voltage, 325 volts at the lowest operating speed (let's say 3000 RPM). Then it can simply chop the output voltage at very high frequency and LC filter filters out the high-frequency harmonics. So the transformer, switch driving it, reset winding diode and half-bridge rectifier can be omitted. Typically inverter generators require higher operating speed at full load (let's say 4700 RPM); in this case the generator outputs a higher voltage but the pulse width modulation takes care of that and the amplitude of the sine wave after the LC filter is still the correct one. This is why inverter generators are surprisingly cheap for the power level they produce, since they can omit some components that regular battery / solar inverters have.