iMac strange sound from speakers


My iMac was making a continuous "modulating" high pitched sound. It would even pan from left to right and back. This sound was coming THROUGH my speakers. I disconnected my audio interface, switched inputs and outputs to internal speakers/mic... and it still happened. Did a hardware test and it was clean. Reset SCM and PRAM and now it is gone, but it may have been as simple as a restart. I am running Mojave 10.14.4. I have an internal 1 TB SSD. My Mac runs perfectly.

Any ideas? Hardware problem? I'm not so sure. Can a iMac pick up radio frequency or other electronic interference, similar to a stereo or guitar amp?
Not sure what you mean by "modulating"? Do you mean a changing pitch, or did it change intensity (loudness)?
You said you disconnected an audio interface. Exactly what kind of device did you have connected?
The PRAM/NVRAM reset would set volume levels to hardware defaults.
Which iMac do you have?
Both. Modulating with change in pitch slightly and more slow change in volume (and it even panned left and right too). USB audio interface is a Focusrite 18i8. I isolated it and believe I demonstrated my USB audio interface has nothing to do with this - sound continued with interface, using internal input and output and interface completely disconnected. Computer info here:

You can hear it here:

Model Name: iMac
Model Identifier: iMac17,1
Processor Name: Intel Core i7
Processor Speed: 4 GHz
Number of Processors: 1
Total Number of Cores: 4
L2 Cache (per Core): 256 KB
L3 Cache: 8 MB
Memory: 32 GB
Boot ROM Version:
SMC Version (system): 2.34f2
Last edited: