Re: How is SNR computed?
cristian wrote:
> Maybe this is a very simple problem, but it troubles my mind.
>
> I consider a complex signal like
>
> x(n) = s(n) + w(n)
>
> Where
>
> s(n) = a*exp(-j*2*pi*f*t)
>
> and
>
> w(n) = Rew(n) + j*Imw(n)
>
> (uncorrelated) is a zero-mean complex Gaussian noise process with
variance
> 1.
>
> I want to compute the detection probability for different SNR, so I
compute
> the estimated power using FFT without any windowing (not been
necessary) and
> than compare it with the threshold, so no surprises. My trouble it
comes
> with computing the correct SNR, because I always considered the SNR
as been
> a^2/variance (considering a complex signal), but how is this related
to the
> estimated power? Through FFT I also have a power gain of 10*log10(n),
so is
> the SNR in fact 10*log10(a^2/variance) + 10*log10(n)? The local SNR
can be
> computed like 10*log10(1/P(f))? What is in fact my real SNR? If I
consider
> it only as function of the sinusoid amplitude and noise variance, it
doesn't
> sound realistic to me!
The way I use the SNR with sinusoidals in noise:
x[n] = a*exp(jwn) + v[n] = s[n] + v[n] [1]
where
a is complex-valued scalar
n is the running index
w is the angular frequency
v[n] is the zero mean, white noise sequence of variance sigma^2,
uncorrelated with the exp term.
Consider a time segment of N samples. The noise-free signal energy
becomes
N-1
E_s = sum a*exp(jwn)*conj(a)exp(-jwn) = N|a|^2 [2]
n=0
while the noise energy becomes
N-1
E_v = sum v[n]*conj(v[n]) = N E[|v[n]|^2] = N*sigma^2 [3]
n=0
The argument here is that the noise *power* is given by
E[|v[n]|^2] = sigma^2, so each noise sample contributes
to the *energy* with an amount sigma^2*T, given some
sampling period T.
We know that the SNR is defined in terms of powers, not
energy, so the SNR becomes
SNR = E_s*N*T /(E_v*N*T) = E_s/E_v = |a|^2/sigma^2 [4]
where, again, T is some physical sampling period that needs not
be specified since it does not appear in the end expression.
OK, bring all this over to the ferquency domain. It is not
obvious how to do that, since one can Fourier transform
the signal s[n] in equation [1] directly but needs to
transform the autocorrelation sequence of the noise u[n].
So compute first the autocorrelation of r_ss[k] of s[n]:
1 N
r_ss[k] = lim ---- sum s[n]conj(s[n+k]) [5.a]
N-> inf 2N+1 n=-N
= |a|^2*cos (wk) [5.b]
(I am in really deep water here, so be careful with what claims of
mine you accept...)
Whatever the correct argument might be in [5.a] and what scaling
factors are correct in [5.b] above, the key point is that when you
Fourier transform K samples of the cosine series in [5.b], you get
coherent summation:
1 K-1
R_ss[w_m] = --- sum |a|^2 cos(wk) exp(jw_m k) [6.a]
K k=0
= |a|^2 D(w-w_m) [6.b]
where D(y) is the Kronecker delta, and [6.b] is valid when w=w_m.
The transform of the autocorrelation of the noise, r_vv[k], on the
other hand, becomes
1 k-1
R_vv[w_m] = --- sum sigma^2 D(k) exp(jw_m k) [7.a]
K k=0
= sigma^2/K. [7.b]
[ Don't take my derivations for granted, I am sure there are plenty
of typos and wrong arguments around. I think the fact that you
specify the signal as complex-valued introduces some problems. ]
Still, the main outline of the argument is valid. In frequency
domain, the energy of the coherent signal remains unchanged while
adding more samples to the analysis, the 1/K factor is cancelled
by a K appearing in an intermediate form of the sum between [6.a]
and [6.b], while no such cancellation appears for the noise sequence.
One could say that introducing more samples to the data "dilutes"
the noise energy over the increasing number of Fourier coefficients,
while the coherent energy in the signal remains consentrated
in certain bins.
It does require some work to get through all the details, though.
And again, don't take any of my derivations above for granted.
Rune
|