This is for those of you who, listen back to a recording and find a horrific electrical hum ruining your work.
That very thing happened to a friend recently. In a last ditch effort, he asked if there was anything I could do to save his masterpiece.
Chances are if you used a USB microphone plugged into a computer, the issue is caused by a ground loop [1]. You can test if this is the case by running your computer on battery, if possible. If the hum dissapears, then it was probably a ground loop issue.
But of course knowing that you should have unplugged your laptop while recording doesn't salvage your already-recorded work. My friend had tried a couple of fairly solid general approaches for removing noise from audio: a noise gate, and a fancy noise reduction plugin provided by his expensive recording software. Both approaches failed.
A noise gate mutes any audio below a certain volume, which is great when the human behind the offending microphone isn't speaking, but is useless when they are. Noise reduction is designed specifically for dynamic, non-verbal audio and is surprisingly ineffective at filtering out a constant, periodic sound.
What ended up doing the trick was a simple notch filter to remove the unwanted frequencies generated by the ground loop hum. As I said, the hum is constant in frequency, and periodic. A notch filter allows for a very narrow frequency band, say within 1Hz, to be filtered out. Because you're removing such a narrow part of the spectrum, it has essentially no negative effect on the quality of the audio recording.
In this case, I identified from the audio's frequency spectrum that the hum had a base frequency of exactly 1khz, with some smaller harmonics, at 2kHz-6kHz. Here is what my finished notch filter looked like:
I used Adobe Audition's notch filter, but pretty much any audio editing software will have one. Audacity, a fantastic free DAW even has a guide on its wiki on how to use a notch to remove mains hum. The notch removed the hum entirely; you'd never know it was ever there.
Sometimes a simple tool will outperform state-of-the-art solutions, as long as you know the tool exists in the first place.
[1] Your power supply is connected to earth—literally, somewhere. Sometimes, the ground connected to your computer and the microphone can have different potentials, creating an unpleasant hum. Someone more qualified in high-powered electronics can tell you more about why.