First I use Audacity to perform an FFT of an audio clip with a rectangular window. Then I sum all the FFT bin values. Since the FFT bins are expressed in dB, I perform the "decibel sum" like this:
sum = 10*log10(10(bin1/10) + 10(bin2/10) + 10(bin3/10)...).
The resulting value is always identical or extremely close to Adobe Audition's "Total RMS Amplitude".
My Audition settings are set to full-scale sine=0dBFS. (Audacity, however, considers a full-scale square to be 0dBFS. So summing the bins results in an expected 3dB discrepancy).
Error seems to be very minimal (a few hundredths of a dB). But it only works this accurately when I use a rectangular window and with larger FFT sizes (2048+). My questions is: Why does this work? Does it always work? Intuitively it kind of makes sense but I can't figure out how RMS relates to FFT. Is there an easier way to calculate RMS amplitude (besides trusting Adobe)?