Not a member?

# Discussion Groups | Comp.DSP | ADC SNR testing using tone

There are 18 messages in this thread.

You are currently looking at messages 1 to .

Is this discussion worth a thumbs up?

0

# ADC SNR testing using tone - kaz - 2012-08-01 04:35:00

```I have been looking at SNR of quantisation noise and was impressed by an
article titled:
Taking the Mystery out of the Infamous Formula, "SNR = 6.02N + 1.76dB," and
Why You Should Care by Walt Kester

The article first derives the equation based on sine tone as:
snr = 6.02n + 1.76   (n = bitwidth of ADC)

Then it further adds a term for tone bandwidth:
snr = 6.02n + 1.76 + 10log(Fs/(2*bw)

it then talks about a term due to fft resolution as
10log(fft_resolution/2)

What is not clear is the relation between above two log terms.

In a second article the same author confirms what we all do when we measure
SNR of an ADC using tone: we subtract the term 10log(fft_resolution/2) from
fft noise floor to get ADC SNR.

It seems to me there is overlap of above two log terms.
More specifically my question is:
is snr of tone = 6.02n + 1.76
or snr of tone 6.02n + 1.76 + 10log(Fs/(2*bw)

if the current test practice agrees with snr = 6.02n + 1.76 then is the
article wrong by adding bw term?

```
______________________________

# ADC SNR testing using tone - Robert Adams - 2012-08-01 08:53:00

```The first equation represents the snr over the bandwidth from dc to fs/2 and has nothing to
do with frequency domain analysis.

The 2nd equation is the ratio between the fft signal power and the average fft noise power you
would find in a non-signal fft bin. It makes an assumption that the quantization noise is
completely uncorrelated. It's not the true snr. If the fft noise bins do not show any obvious
spectral components you can eyeball the fft floor and add the correction factor and get an
approximate true snr. The assumption that the noise is uncorrelated is dangerous so be careful

Note one mistake people often make is to calculate the integrated noise floor by averaging the
abs of each fft bin. This is not correct, you need to add the powers not the magnitudes.

Note that if you use a window things are slightly more complicated as the signal power is spread
over a few bins. The correct way to deal with this is to add the power of the signal bins
together and call this this signal power, and then add the power of the noise bins together and
call that the noise power. There is a small error in doing this because there is some noise
power in the signal bins that you are excluding, but if the fft is large this is a very small
error.

A really good way to get accurate snr for short time records is to use a sine wave curve fit
algorithm. This is well covered in the literature.

Bob
```
______________________________

# Re: ADC SNR testing using tone - kaz - 2012-08-01 09:35:00

```>The first equation represents the snr over the bandwidth from dc to fs/2
an>d has nothing to do with frequency domain analysis.
>
>The 2nd equation is the ratio between the fft signal power and the average
>fft noise power you would find in a non-signal fft bin. It makes an
assumpt>ion that the quantization noise is completely uncorrelated. It's not the
tr>ue snr. If the fft noise bins do not show any obvious spectral components
y>ou can eyeball the fft floor and add the correction factor and get an
appro>ximate true snr. The assumption that the noise is uncorrelated is
>
>Note one mistake people often make is to calculate the integrated noise
flo>or by averaging the abs of each fft bin. This is not correct, you need to
a>dd the powers not the magnitudes.
>
>Note that if you use a window things are slightly more complicated as the
s>ignal power is spread over a few bins. The correct way to deal with this
is> to add the power of the signal bins together and call this this signal
pow>er, and then add the power of the noise bins together and call that the
noi>se power. There is a small error in doing this because there is some noise
>power in the signal bins that you are excluding, but if the fft is large
th>is is a very small error.
>
>A really good way to get accurate snr for short time records is to use a
si>ne wave curve fit algorithm. This is well covered in the literature.
>
>Bob
>

I don't have problems proving in the frequency analysis the formula of
snr(fullscale tone) =  6.02n+1.76

and I can see the effect of fft resolution and bitwidth in action agreeing
well with formula.

However, my question was about bandwidth term, and its relation to fft
term? Does it mean we include bandwidth term when we only are interested in
the tone section of frequency domain? as this explains the bandwidth term
effect but sounds strange to call it SNR.

I have yet another observation: The effect of fft resolution is obvious
with tone case but does not show for a bandlimited signal. Are the rules
different then between tone and bandlimited signal

```
______________________________

# Re: ADC SNR testing using tone - Robert Adams - 2012-08-01 21:57:00

```On Wednesday, August 1, 2012 4:35:27 AM UTC-4, kaz wrote:
> I have been looking at SNR of quantisation noise and was impressed by an
>
> article titled:
>
> Taking the Mystery out of the Infamous Formula, "SNR = 6.02N + 1.76dB," and
>
> Why You Should Care by Walt Kester
>
>
>
> The article first derives the equation based on sine tone as:
>
> snr = 6.02n + 1.76   (n = bitwidth of ADC)
>
>
>
> Then it further adds a term for tone bandwidth:
>
> snr = 6.02n + 1.76 + 10log(Fs/(2*bw)
>
>
>
> it then talks about a term due to fft resolution as
>
> 10log(fft_resolution/2)
>
>
>
> What is not clear is the relation between above two log terms.
>
>
>
> In a second article the same author confirms what we all do when we measure
>
> SNR of an ADC using tone: we subtract the term 10log(fft_resolution/2) from
>
> fft noise floor to get ADC SNR.
>
>
>
> It seems to me there is overlap of above two log terms.
>
> More specifically my question is:
>
> is snr of tone = 6.02n + 1.76
>
> or snr of tone 6.02n + 1.76 + 10log(Fs/(2*bw)
>
>
>
> if the current test practice agrees with snr = 6.02n + 1.76 then is the
>
> article wrong by adding bw term?
>
>
>
>
>
>
>
>

Now that I actually looked at the article, I think I understand your question better :)
If you have a signal that occupies a limited bandwidth, and outside this bandwidth you have ADC
quantization noise, you can get a higher snr by applying a bandpass filter that passes the
signal and rejects the bins that only contain noise. That following equation describes this
improvement in SNR

snr = 6.02n + 1.76 + 10log(Fs/(2*bw)

The second equation

6.02n + 1.76 + 10log(fft_resolution/2)

is the signal-to-noise ratio where you are measuring the noise in a single fft bin. This assumes
the noise added to the desired signal is purely white.

So if you are looking at an FFT output (actually hopefully you have power-averaged a bunch of
FFT's together so that the noise part of the spectrum is pretty much a flat line), and you want
to compute the ADC noise level, you can add 10log(fft_resolution/2) to the average FFT bin value
to get the noise over the full bandwidth from 0 to fs/2.

Bob
```
______________________________

# Re: ADC SNR testing using tone - kaz - 2012-08-02 03:41:00

```>On Wednesday, August 1, 2012 4:35:27 AM UTC-4, kaz wrote:
>> I have been looking at SNR of quantisation noise and was impressed by
an
>>
>> article titled:
>>
>> Taking the Mystery out of the Infamous Formula, "SNR = 6.02N +
1.76dB,"> and
>>
>> Why You Should Care by Walt Kester
>>
>>
>>
>> The article first derives the equation based on sine tone as:
>>
>> snr = 6.02n + 1.76   (n = bitwidth of ADC)
>>
>>
>>
>> Then it further adds a term for tone bandwidth:
>>
>> snr = 6.02n + 1.76 + 10log(Fs/(2*bw)
>>
>>
>>
>> it then talks about a term due to fft resolution as
>>
>> 10log(fft_resolution/2)
>>
>>
>>
>> What is not clear is the relation between above two log terms.
>>
>>
>>
>> In a second article the same author confirms what we all do when we
measu>re
>>
>> SNR of an ADC using tone: we subtract the term 10log(fft_resolution/2)
fr>om
>>
>> fft noise floor to get ADC SNR.
>>
>>
>>
>> It seems to me there is overlap of above two log terms.
>>
>> More specifically my question is:
>>
>> is snr of tone = 6.02n + 1.76
>>
>> or snr of tone 6.02n + 1.76 + 10log(Fs/(2*bw)
>>
>>
>>
>> if the current test practice agrees with snr = 6.02n + 1.76 then is
the
>>
>> article wrong by adding bw term?
>>
>>
>>
>>
>>
>>
>>
>>
>
>Now that I actually looked at the article, I think I understand your
questi>on better :)
>If you have a signal that occupies a limited bandwidth, and outside this
ba>ndwidth you have ADC quantization noise, you can get a higher snr by
applyi>ng a bandpass filter that passes the signal and rejects the bins that only
>contain noise. That following equation describes this improvement in SNR
>
>snr = 6.02n + 1.76 + 10log(Fs/(2*bw)
>
>The second equation
>
> 6.02n + 1.76 + 10log(fft_resolution/2)
>
>is the signal-to-noise ratio where you are measuring the noise in a single
>fft bin. This assumes the noise added to the desired signal is purely
white>.
>
>So if you are looking at an FFT output (actually hopefully you have
power-a>veraged a bunch of FFT's together so that the noise part of the spectrum
is> pretty much a flat line), and you want to compute the ADC noise level,
you> can add 10log(fft_resolution/2) to the average FFT bin value to get the
no>ise over the full bandwidth from 0 to fs/2.
>
>Bob
>

Thanks Bob,

The question that arises now is two fold:

1) Can we actually filter off quantisation noise. I thought we cannot
because it is inherent in the digits.

2)the effect of sampling frequency at ADC on SNR  is ignored in the
original equation of 6.02n + 1.76
if we sample a tone at Fs and then at 2Fs wouldn't we expect 3dB increase
of SNR. How do we fit that in the equation then.

Is the term 10log(Fs/2bw) applicable here as well as the case of
filtering?

```
______________________________

# Re: ADC SNR testing using tone - mnentwig - 2012-08-02 05:30:00

```Hi,

>> 2)the effect of sampling frequency at ADC on SNR  is ignored in the
original equation of 6.02n + 1.76

you can read this equation as follows:
For a full-scale sine wave signal, the predicted noise across the whole
bandwidth is 6.02n+1.76 dB below the power of the full-scale sine wave.
If you change the bandwidth, the noise spreads over a wider bandwidth, but
its integrated power remains the same. Therefore, the bandwidth is not
included in the equation.

In the lab, do a least-squares fit of the test tone to the output signal
and subtract it. What remains, is noise. If you use an integer number of
cycles in your observation window, it's trivially done by FFT. The power of
all other FFT bins combined should relate to the FFT bin of your test tone
via 6.02n+1.76 (ideally).

>> 1) Can we actually filter off quantisation noise. I thought we cannot
because it is inherent in the digits.
As above: Do a least-squares fit (i.e. via FFT) and subtract it (i.e. zero
the test tone FFT bin and IFFT back to time domain). What remains is
noise.
There is a very small error here, as you'll disregard noise that happens to
correlate with your signal. Use longer measurements (=> more FFT bins) to
make the error  arbitrarily small.

Real-world ADCs are not exactly ideal quantizers. Expect
"ballpark"-accuracy from the equation, not a match within a fraction of a
dB.

-markus
```
______________________________

# Re: ADC SNR testing using tone - Robert Adams - 2012-08-02 09:40:00

```If you double the sample rate and keep the same absolute bandwidth in hz, you gain 3 db. If
you double the sample rate but include the entire frequency range from dc to fs/2, then there is
no increase in snr.

Bob
```
______________________________

# Re: ADC SNR testing using tone - kaz - 2012-08-02 10:11:00

```>Hi,
>
>>> 2)the effect of sampling frequency at ADC on SNR  is ignored in the
>original equation of 6.02n + 1.76
>
>you can read this equation as follows:
>For a full-scale sine wave signal, the predicted noise across the whole
>bandwidth is 6.02n+1.76 dB below the power of the full-scale sine wave.
>If you change the bandwidth, the noise spreads over a wider bandwidth,
but
>its integrated power remains the same. Therefore, the bandwidth is not
>included in the equation.
>

Hi markus,

I don't think that is right. SNR is defined as ratio of mean powers so
spreading of noise implies mean power will go down. There is this equation
for oversampling effect on SNR: SNR(oversampling) = 10log(Fs_new/Fs)

Thus it is relative. The thing that I try to understand in the context of a
given tone how is oversampling defined. If my ADC speed is 100Msps and I
used tone test; one tone at 1MHz, a second at 10MHz wouldn't I get same
SNR?

```
______________________________

# Re: ADC SNR testing using tone - mnentwig - 2012-08-02 11:24:00

```Hello,

oversampling spreads the same, fixed quantization noise power of (6.02 +
1.76n dBc relative to a fullscale sine wave) over a wider bandwidth.
Thus, the noise power density (and therefore the noise over a fixed
observation bandwidth) reduces.
But the total amount of noise, integrated over all frequencies, remains the
same.

Cheers

Markus
```
______________________________

# Re: ADC SNR testing using tone - kaz - 2012-08-02 14:42:00

```>Hello,
>
>oversampling spreads the same, fixed quantization noise power of (6.02 +
>1.76n dBc relative to a fullscale sine wave) over a wider bandwidth.
>Thus, the noise power density (and therefore the noise over a fixed
>observation bandwidth) reduces.
>But the total amount of noise, integrated over all frequencies, remains
the
>same.
>
>Cheers
>
>Markus
>

your statement is ok in terms of total power, yes but I was referring to
SNR(Q).

In fact I found one other article clearing up the issue but just:
SNR(Q) = 6.02n + 1.76 + 10log(Fs_o/Fs)

Fs : sampling frequency, Fs_o : oversampling frequency
Thus it does include oversampling effect. However it does not define what
is regarded as Fs or as Fs_o especially so with regard to a single tone
test.