Signals and DSP · Sinusoids, spectra and decibels
Engineers use decibels to compare signals that differ by factors of thousands, and the formula depends on whether you compare power or voltage.