20 kHz is common for a variety of reasons.
1) The frequency is above the audible band.
2) Power devices have been optimized for this frequency.
3) The switching frequency is high enought to allow reasonably high current loop bandwidths-1-2 kHz.
4) Noise supression components are smaller.
I do not think the above is quite right. Sure, 20 KHz is above audible band but that is not the point. The point is that power devices have NOT been optimized for this frequency. In fact a 20 KHz carrier frequency would cause high losses resulting in severe heating of power lines - drastically reducing max. permissible length - and electric motors, and also to severe overload of Variable Frequency Drives. For that reason there is no commercially available VFD with a higher carrier frequency than 15 KHz (Fuji). For industrial applications where efficiency is far more important than - slight - noise levels, carrier frequencies of 1 - 4 KHz are normal. I hope this clarifies the issue.
Good question. Here's some info I stole from AC-Tech's web page. I believe the standard carrier frequency for the MC series drives (which we have since stopped using) was 4kHz, which is quite audible.
Why does the motor make a high-pitched squeal or whine when operated on the VFD?
The output waveform of the VFD is not a pure AC sinewave. It is a simulated waveform that is actually made up of pulses of DC voltage from the VFD's DC bus. These pulses cause vibrations in the motor that are heard as a high-pitched squeal or whine.
The pulses are generated by the switching of the VFD's output transistors. The switching rate of the output transistors is controlled by the VFD's Carrier Frequency parameter. Increasing the Carrier Frequency will reduce the audible noise from the motor. However, doing so may require derating of the VFD, as increasing the switching rate of the transistors causes the VFD to be less efficient. Please refer to the VFD's manual for more information on derating due to increased carrier frequency.
It can also cause resonance problems with other electrical components, which can be transmitted across poorly decoupled and filtered lines