I've been in power generation my entire career and no generator I know produces a square wave. The physics of how power is produced just won't allow that to happen. There are many things that can affect harmonic distortion as the article states. One thing not mentioned in the article is other loads on the line affecting harmonics. If your power needs are that particular then I'd stick with an inverter generator. I know some ambulances run PSW Xanatrex inverters because they produce very clean power for their sensative medical electronics
The two descriptions above of how inverter generators work are both incorrect. They have an altenator (producing alternating current) at a high voltage that is converted to DC and is then inverted back to AC. Typically they use quality inverters that clean up the power very nicely. Good luck finding one bigger than 3.5KW.