DSPRelated.com
Forums

Adding noise given by Noise Factor

Started by Peter Mairhofer February 11, 2016
Hello,

For a system level simulation of an RF receiver in MATLAB I would like
to specify Noise Factor (NF) and IIP3 for a block (e.g. the complete
receiver).

My signals are represented as vectors of real numbers, heavily
oversampled. I am confused: Is it best to represent the signals as
voltages, currents or powers?

In terms of IIP3 this is rather straight forward: My signals are
voltages and I can model the system as a simple Taylor series:

x_out = c1*x_in + c3 * x_in.^3

where the third-order coefficient is given as (IIP3 given in dBm):

c3 = 4*c1/(3 * 2 * 50 * 10^(IIP3/10) * 1e-3)


However, for the Noise Figure I am unsure. Basically what I want is what
noise level (in terms of variance of an additive white Gaussian signal)
I need to add for a certain NF.

NF is either defined as SNRout/SNRin or "Total output noise"/"Output
noise due to source". However, if I start with a clean signal x (given
just as a vector in MATLAB) my SNR is infinity. So how could I calculate
which amount of noise (in terms of variance of a Gaussian distribution)
to add to yield a certain Noise Figure?

Alternatively, if I assume the input signal is a voltage, then the
source noise is 4kTBRs and the input referred noise (the same unit as my
input signal, "voltage") vn^2.

Then

f = G4kTBRs + Gvn^2/(G4kTBRs) = 1 + vn^2/(4kTBRs)

-> vn^2 = (f-1)*4kTBRs

Noise Figure is a spot noise so I wonder how to treat "B" here for a
simulated signal x. Furthermore, it is problematic since it contains
"arbitrary" values k, T, Rs.

If I assume NF=10dB, Rs=50: vn^2=(10-1)*4kT*50=7.45e-18.

[ Having y = x + 7.45e-18*randn(size(x)) clearly does not give an SNR of
10 between x and y.]

Hence I would assume I need to take my values as "power" (then at least
Rs falls out) but this is not "physical" (I measure either a voltage
signal or a current signal) and I still have kT in my equation.

I think I am just missing some assumptions.

Peter


On Thursday, February 11, 2016 at 4:36:46 AM UTC-5, Peter Mairhofer wrote:
> Hello, > > For a system level simulation of an RF receiver in MATLAB I would like > to specify Noise Factor (NF) and IIP3 for a block (e.g. the complete > receiver). > > My signals are represented as vectors of real numbers, heavily > oversampled. I am confused: Is it best to represent the signals as > voltages, currents or powers? > > In terms of IIP3 this is rather straight forward: My signals are > voltages and I can model the system as a simple Taylor series: > > x_out = c1*x_in + c3 * x_in.^3 > > where the third-order coefficient is given as (IIP3 given in dBm): > > c3 = 4*c1/(3 * 2 * 50 * 10^(IIP3/10) * 1e-3) > > > However, for the Noise Figure I am unsure. Basically what I want is what > noise level (in terms of variance of an additive white Gaussian signal) > I need to add for a certain NF. > > NF is either defined as SNRout/SNRin or "Total output noise"/"Output > noise due to source". However, if I start with a clean signal x (given > just as a vector in MATLAB) my SNR is infinity. So how could I calculate > which amount of noise (in terms of variance of a Gaussian distribution) > to add to yield a certain Noise Figure? > > Alternatively, if I assume the input signal is a voltage, then the > source noise is 4kTBRs and the input referred noise (the same unit as my > input signal, "voltage") vn^2. > > Then > > f = G4kTBRs + Gvn^2/(G4kTBRs) = 1 + vn^2/(4kTBRs) > > -> vn^2 = (f-1)*4kTBRs > > Noise Figure is a spot noise so I wonder how to treat "B" here for a > simulated signal x. Furthermore, it is problematic since it contains > "arbitrary" values k, T, Rs. > > If I assume NF=10dB, Rs=50: vn^2=(10-1)*4kT*50=7.45e-18. > > [ Having y = x + 7.45e-18*randn(size(x)) clearly does not give an SNR of > 10 between x and y.] > > Hence I would assume I need to take my values as "power" (then at least > Rs falls out) but this is not "physical" (I measure either a voltage > signal or a current signal) and I still have kT in my equation. > > I think I am just missing some assumptions. > > Peter
A few things. Noise FACTOR usually meas a numerical ratio, not in dB. Noise FIGURE usually is noise factor but expressed in dB. Noise figure is SNR out / SNR in (dB) ___ for the specific case____ where the SNR in is due to thernal noise = -174 dBm/Hz. You can work in voltages if you wish. Convert the thermal noise power KTB noise power to voltage depending on the Z of your system (often 50 Ohms). Convert your signal to a voltage and youare off to the races. M
On Thursday, February 11, 2016 at 8:47:54 AM UTC-5, mako...@yahoo.com wrote:
> On Thursday, February 11, 2016 at 4:36:46 AM UTC-5, Peter Mairhofer wrote: > > Hello, > > > > For a system level simulation of an RF receiver in MATLAB I would like > > to specify Noise Factor (NF) and IIP3 for a block (e.g. the complete > > receiver). > > > > My signals are represented as vectors of real numbers, heavily > > oversampled. I am confused: Is it best to represent the signals as > > voltages, currents or powers? > > > > In terms of IIP3 this is rather straight forward: My signals are > > voltages and I can model the system as a simple Taylor series: > > > > x_out = c1*x_in + c3 * x_in.^3 > > > > where the third-order coefficient is given as (IIP3 given in dBm): > > > > c3 = 4*c1/(3 * 2 * 50 * 10^(IIP3/10) * 1e-3) > > > > > > However, for the Noise Figure I am unsure. Basically what I want is what > > noise level (in terms of variance of an additive white Gaussian signal) > > I need to add for a certain NF. > > > > NF is either defined as SNRout/SNRin or "Total output noise"/"Output > > noise due to source". However, if I start with a clean signal x (given > > just as a vector in MATLAB) my SNR is infinity. So how could I calculate > > which amount of noise (in terms of variance of a Gaussian distribution) > > to add to yield a certain Noise Figure? > > > > Alternatively, if I assume the input signal is a voltage, then the > > source noise is 4kTBRs and the input referred noise (the same unit as my > > input signal, "voltage") vn^2. > > > > Then > > > > f = G4kTBRs + Gvn^2/(G4kTBRs) = 1 + vn^2/(4kTBRs) > > > > -> vn^2 = (f-1)*4kTBRs > > > > Noise Figure is a spot noise so I wonder how to treat "B" here for a > > simulated signal x. Furthermore, it is problematic since it contains > > "arbitrary" values k, T, Rs. > > > > If I assume NF=10dB, Rs=50: vn^2=(10-1)*4kT*50=7.45e-18. > > > > [ Having y = x + 7.45e-18*randn(size(x)) clearly does not give an SNR of > > 10 between x and y.] > > > > Hence I would assume I need to take my values as "power" (then at least > > Rs falls out) but this is not "physical" (I measure either a voltage > > signal or a current signal) and I still have kT in my equation. > > > > I think I am just missing some assumptions. > > > > Peter > > A few things. > > Noise FACTOR usually meas a numerical ratio, not in dB. > Noise FIGURE usually is noise factor but expressed in dB. > > Noise figure is SNR out / SNR in (dB) ___ for the specific case____ > > where the SNR in is due to thernal noise = -174 dBm/Hz. > > You can work in voltages if you wish. > Convert the thermal noise power KTB noise power to voltage depending on the Z of your system (often 50 Ohms). > Convert your signal to a voltage and youare off to the races. > > > M
Oh and B is the BW of your system at the detector or wherever you are interested in the SNR. M
Peter Mairhofer  <63832452@gmx.net> wrote:

>For a system level simulation of an RF receiver in MATLAB I would like >to specify Noise Factor (NF)
I think you mean Noise Figure
>and IIP3 for a block (e.g. the complete receiver).
>My signals are represented as vectors of real numbers, heavily >oversampled. I am confused: Is it best to represent the signals as >voltages, currents or powers?
Either voltages or currents will work, but in almost all cases voltage signals are the most convenient, and in the below I assume this.
>In terms of IIP3 this is rather straight forward: My signals are >voltages and I can model the system as a simple Taylor series:
[snip]
>However, for the Noise Figure I am unsure. Basically what I want is what >noise level (in terms of variance of an additive white Gaussian signal) >I need to add for a certain NF.
In the simplest case you have a single antenna of known impedance feeding a singla LNA. To say the noise figure is 0 dB means that the noise voltage referred to the LNA input equals the thermal noise of a resistor with that impedance: sqrt(4kTR) in units of volts per root hertz of bandwidth. You must pick meaningful values for the bandwidth in Hertz, the temperature in Kelvins, and the impedance in Ohms to obtain the noise voltage in Volts. Note that the bandwidth for this expression will often be your sample rate divided by two. For NF > 0 dB, the above voltage is scaled up by 10 ^ (NF / 20). Steve
On Thu, 11 Feb 2016 01:36:45 -0800, Peter Mairhofer <63832452@gmx.net>
wrote:

>Hello, > >For a system level simulation of an RF receiver in MATLAB I would like >to specify Noise Factor (NF) and IIP3 for a block (e.g. the complete >receiver). > >My signals are represented as vectors of real numbers, heavily >oversampled. I am confused: Is it best to represent the signals as >voltages, currents or powers? > >In terms of IIP3 this is rather straight forward: My signals are >voltages and I can model the system as a simple Taylor series: > >x_out = c1*x_in + c3 * x_in.^3 > >where the third-order coefficient is given as (IIP3 given in dBm): > >c3 = 4*c1/(3 * 2 * 50 * 10^(IIP3/10) * 1e-3) > > >However, for the Noise Figure I am unsure. Basically what I want is what >noise level (in terms of variance of an additive white Gaussian signal) >I need to add for a certain NF. > >NF is either defined as SNRout/SNRin or "Total output noise"/"Output >noise due to source". However, if I start with a clean signal x (given >just as a vector in MATLAB) my SNR is infinity. So how could I calculate >which amount of noise (in terms of variance of a Gaussian distribution) >to add to yield a certain Noise Figure? > >Alternatively, if I assume the input signal is a voltage, then the >source noise is 4kTBRs and the input referred noise (the same unit as my >input signal, "voltage") vn^2. > >Then > >f = G4kTBRs + Gvn^2/(G4kTBRs) = 1 + vn^2/(4kTBRs) > >-> vn^2 = (f-1)*4kTBRs > >Noise Figure is a spot noise so I wonder how to treat "B" here for a >simulated signal x. Furthermore, it is problematic since it contains >"arbitrary" values k, T, Rs. > >If I assume NF=10dB, Rs=50: vn^2=(10-1)*4kT*50=7.45e-18. > >[ Having y = x + 7.45e-18*randn(size(x)) clearly does not give an SNR of >10 between x and y.] > >Hence I would assume I need to take my values as "power" (then at least >Rs falls out) but this is not "physical" (I measure either a voltage >signal or a current signal) and I still have kT in my equation. > >I think I am just missing some assumptions. > >Peter
I suspect you're modelling an amplifier since you're interested in IP3, and if it's an LNA then there's a slight conceptual difference in how to treat it compare to other devices/functions, like a filter or something. For something like a filter or mixer, the Noise Figure is pretty easy to sort out as the ratio you've indicated, SNRout/SNRin, but that's because typically there is already significant thermal noise that is already there at the input. In typical receiver systems, the majority of the thermal noise comes from the LNA (that's actually its job, kinda), so if you're modelling an LNA, then you'll have the situation that you mentioned, where the input may be pristine but the output will have a finite SNR. In this case I find it easier to think of it as a noise source and use the usual GkTB process to model the appropriate output noise level. Eric Jacobsen Anchor Hill Communications http://www.anchorhill.com
On Thu, 11 Feb 2016 05:47:46 -0800, makolber wrote:

> On Thursday, February 11, 2016 at 4:36:46 AM UTC-5, Peter Mairhofer > wrote: >> Hello, >> >> For a system level simulation of an RF receiver in MATLAB I would like >> to specify Noise Factor (NF) and IIP3 for a block (e.g. the complete >> receiver). >> >> My signals are represented as vectors of real numbers, heavily >> oversampled. I am confused: Is it best to represent the signals as >> voltages, currents or powers? >> >> In terms of IIP3 this is rather straight forward: My signals are >> voltages and I can model the system as a simple Taylor series: >> >> x_out = c1*x_in + c3 * x_in.^3 >> >> where the third-order coefficient is given as (IIP3 given in dBm): >> >> c3 = 4*c1/(3 * 2 * 50 * 10^(IIP3/10) * 1e-3) >> >> >> However, for the Noise Figure I am unsure. Basically what I want is >> what noise level (in terms of variance of an additive white Gaussian >> signal) I need to add for a certain NF. >> >> NF is either defined as SNRout/SNRin or "Total output noise"/"Output >> noise due to source". However, if I start with a clean signal x (given >> just as a vector in MATLAB) my SNR is infinity. So how could I >> calculate which amount of noise (in terms of variance of a Gaussian >> distribution) to add to yield a certain Noise Figure? >> >> Alternatively, if I assume the input signal is a voltage, then the >> source noise is 4kTBRs and the input referred noise (the same unit as >> my input signal, "voltage") vn^2. >> >> Then >> >> f = G4kTBRs + Gvn^2/(G4kTBRs) = 1 + vn^2/(4kTBRs) >> >> -> vn^2 = (f-1)*4kTBRs >> >> Noise Figure is a spot noise so I wonder how to treat "B" here for a >> simulated signal x. Furthermore, it is problematic since it contains >> "arbitrary" values k, T, Rs. >> >> If I assume NF=10dB, Rs=50: vn^2=(10-1)*4kT*50=7.45e-18. >> >> [ Having y = x + 7.45e-18*randn(size(x)) clearly does not give an SNR >> of 10 between x and y.] >> >> Hence I would assume I need to take my values as "power" (then at least >> Rs falls out) but this is not "physical" (I measure either a voltage >> signal or a current signal) and I still have kT in my equation. >> >> I think I am just missing some assumptions. >> >> Peter > > A few things. > > Noise FACTOR usually meas a numerical ratio, not in dB. > Noise FIGURE usually is noise factor but expressed in dB. > > Noise figure is SNR out / SNR in (dB) ___ for the specific case____
SNR out (in dB) - SNR in (in dB).
> where the SNR in is due to thernal noise = -174 dBm/Hz.
Only at 300 Kelvin. If your antenna is pointed at something cold (e.g., the sky, if you're working in a wavelength where the sky is transparent), then thermal noise is NOT -174 dBm/Hz This is why the microwave folks use noise _temperature_ as a receiver rating.
> You can work in voltages if you wish. > Convert the thermal noise power KTB noise power to voltage depending on > the Z of your system (often 50 Ohms). > Convert your signal to a voltage and youare off to the races.
-- Tim Wescott Wescott Design Services http://www.wescottdesign.com
On Thu, 11 Feb 2016 01:36:45 -0800, Peter Mairhofer wrote:

> Hello, > > For a system level simulation of an RF receiver in MATLAB I would like > to specify Noise Factor (NF) and IIP3 for a block (e.g. the complete > receiver). > > My signals are represented as vectors of real numbers, heavily > oversampled. I am confused: Is it best to represent the signals as > voltages, currents or powers? > > In terms of IIP3 this is rather straight forward: My signals are > voltages and I can model the system as a simple Taylor series: > > x_out = c1*x_in + c3 * x_in.^3 > > where the third-order coefficient is given as (IIP3 given in dBm): > > c3 = 4*c1/(3 * 2 * 50 * 10^(IIP3/10) * 1e-3) > > > However, for the Noise Figure I am unsure. Basically what I want is what > noise level (in terms of variance of an additive white Gaussian signal) > I need to add for a certain NF. > > NF is either defined as SNRout/SNRin or "Total output noise"/"Output > noise due to source". However, if I start with a clean signal x (given > just as a vector in MATLAB) my SNR is infinity. So how could I calculate > which amount of noise (in terms of variance of a Gaussian distribution) > to add to yield a certain Noise Figure? > > Alternatively, if I assume the input signal is a voltage, then the > source noise is 4kTBRs and the input referred noise (the same unit as my > input signal, "voltage") vn^2. > > Then > > f = G4kTBRs + Gvn^2/(G4kTBRs) = 1 + vn^2/(4kTBRs) > > -> vn^2 = (f-1)*4kTBRs > > Noise Figure is a spot noise so I wonder how to treat "B" here for a > simulated signal x. Furthermore, it is problematic since it contains > "arbitrary" values k, T, Rs. > > If I assume NF=10dB, Rs=50: vn^2=(10-1)*4kT*50=7.45e-18. > > [ Having y = x + 7.45e-18*randn(size(x)) clearly does not give an SNR of > 10 between x and y.] > > Hence I would assume I need to take my values as "power" (then at least > Rs falls out) but this is not "physical" (I measure either a voltage > signal or a current signal) and I still have kT in my equation. > > I think I am just missing some assumptions. > > Peter
Just a couple of comments: Know what frequency you're at -- noise temperature may be a better measure. Yes, you just need to keep things in volts or amps, know your source impedance, and use the thermal noise equation. Reality bites, get used to it. Using a Taylor-series expansion may get you _A_ system that has a 3rd- order intercept point that matches, for the test you're using, but most system nonlinearities aren't just f(x) = x + A*x^3. For instance, a front end that hard limits at some voltage has a 3rd-order intercept point, but it'll respond to three signals significantly differently (worse) than the one you're proposing. I'm pretty sure that MOST real systems will be worse -- go dig for white papers to be sure. Have fun. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com
On 2016-02-11 11:44, Steve Pope wrote:
> Peter Mairhofer <63832452@gmx.net> wrote: > >> For a system level simulation of an RF receiver in MATLAB I would like >> to specify Noise Factor (NF) > > I think you mean Noise Figure
I think there is no clear definition but for me: Noise Figure = 10*log10(Noise Factor) Hence I don't care (Noise Factor might be easier for calculations)
> [...] > In the simplest case you have a single antenna of known impedance > feeding a singla LNA.
For me it is an LNA including the whole receiver. However, the receiver is integrated without decoupled stages (current mode passive mixer) hence the whole receiver up to the ADC.
> To say the noise figure is 0 dB means that > the noise voltage referred to the LNA input equals the thermal noise of > a resistor with that impedance: > > sqrt(4kTR) > > in units of volts per root hertz of bandwidth. > > You must pick meaningful values for the bandwidth in Hertz, > the temperature in Kelvins, and the impedance in Ohms to obtain the noise > voltage in Volts. Note that the bandwidth for this expression will often > be your sample rate divided by two. > > For NF > 0 dB, the above voltage is scaled up by 10 ^ (NF / 20).
Ok, thanks! What I seem to have forgotten: I can't use NF without knowing the source impedance. One question though: fs = 800e6; BW = fs/2; N = 2^16; x0 = randn(N,1); NF = 10; % 10 dB nf = 10^(NF/10); Rs = 50; kT = 300*1.38e-23; % signal after the antenna (the -174dBc/Hz noise) xn = x0 + sqrt(4*kT*BW*Rs)*randn(size(xn)); % add noise according to NF sigma2 = (nf-1)*4*kT*BW*Rs; yn = xn + sqrt(sigma2)*randn(size(xn)); % calculate SNR SNR1 = 20*log10(norm(x0-yn)/norm(x0)) This example gives -84.8450 dB. Now I could use the well known equation for sensitivity to obtain the SNR level (-30 converts dBm to volts): SNR2 = -174 - 30 - 10*log10(var(x0)/(2*Rs)) + 10*log10(BW) + NF which gives -87.9918 dB - off by 3dB from the first method. Turns out results match when I double the BW in this equation: SNR3 = -174 - 30 - 10*log10(var(x0)/100) + 10*log10(2*BW) + NF -84.9951 dB Why? Thanks Peter
On 2016-02-11 12:39, Tim Wescott wrote:
> On Thu, 11 Feb 2016 01:36:45 -0800, Peter Mairhofer wrote: > [...] > Using a Taylor-series expansion may get you _A_ system that has a 3rd- > order intercept point that matches, for the test you're using, but most > system nonlinearities aren't just f(x) = x + A*x^3. For instance, a > front end that hard limits at some voltage has a 3rd-order intercept > point, but it'll respond to three signals significantly differently > (worse) than the one you're proposing. I'm pretty sure that MOST real > systems will be worse -- go dig for white papers to be sure.
I know it's just a rough approximation if I assume the system is weakly nonlinear, the nonlinearity is memory less and the third-order term dominates. I need an easy model. I may add 2nd order term but this is (hopefully) significantly lower. P1dB compression point may be a better measure but I would not know how to model it. So I would use IIP3 as a first order estimate and add 10-20dB margin. If you have something special in mind please let me know. Thanks Peter
<makolber@yahoo.com> wrote:

>Oh and B is the BW of your system at the detector or wherever you are >interested in the SNR.
Not so fast. If the system being simulated includes a filter or filters that bandlimits the system, and this filtering occurs downstream from the point the thermal noise is being added, you do NOT want to use this bandwidth when computing the voltage level of the thermal noise from an expression such as vn^2 = 4kTBR * (noise figure expressed as power ratio) If you do, your simulation will be erroneously optimistic since you are both filtering the noise, and scaling it by the factor that would arise from filtering it. You really do want the simulated noise to be broadband, like thermal noise is in real life; and in discrete time this means the noise power goes from DC to 1/2 of the sample rate. So in the 4kTBR expression, it is correct to use Fs/2 for B. If instead your system does not include such filtering, but you wish to presume that a finite bandwidth less than Fs/2 is at work, you can kind-or sort-of use this bandwidth in the 4kTBR expression but you have now opened a can of worms -- there is likely implicit filtering in some systems elements such as your demodulator. Doing this may be suitable for a quick ballpark simulation but it is not correct and is still likely optimistic. Steve