LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

FFt variation

Hi ,
  I would appreciate some help regarding some fft analysis cauz I'm nto a specialist on it..

Got a Ni Pxi  5122 daqmx Digitizer & I use it to sample some sinewave I generate by myself. That Means I know exactly frequence & ampl
of those waveform.

Try to analyse them using a sample module, knows  as AdvancedMeasurement Library which's very intresting.

I use this application to get the "Vrms amplitude on the full spectrum" by prefroming an fft.
I mean I was expecting to sample and process a signal and compute a fft on it to know the rms amplitude of the fondamental.


I observe the fondamental value (Rms) change when you make an acquisition then stop it , then change the freq of the waveform.
As I change the frequency but not the amplitude I expect to move my fundamental position but not it's amplitude.

I try to change the sampling frequency to adapt it (10 times the frequency I expect to sample but result vary too).
Was I correct expecting to find with precision the fundamental rms value ?

My mind is if I sample a 10kHz signal at 1000KS/s by taking 8192 points , result should be stable.

Thanxs a lot
David




0 Kudos
Message 1 of 6
(3,837 Views)
David,

it seems to me that your question is more related to the fundamentals of FFT than to the way how to implement it.
Here is a link you would be interested in in that case.
i conclude the most importent things here:
a) FFT asumes that the signal you are currently containing in your array is continuous for always.
b) FFT does not need binary number of samples.
c) if your array does not contain a "fitting" curve meaning an unsigned integer times of periods, there will be disruptions in the analyzed signal which will create large noise to your analyses.
d) to reduce the noise, use windowing.

hope this helps,
Norbert B.
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 2 of 6
(3,824 Views)
Thanks alot for the links that's infos I need.

I assume I cannot sample a finite number of period each time.
So best way is to apply the adequate filter.

I know how to do it using the Autopower spectrum then how to convert it in fft rms back
using a compensation for the filter.

Is it possible to compensate the filter the same way using the niScope measurement ?
Because I try to add an intermediate measurement containing a filter and the result look more stable.
(5 mVrms max on the peak value).

I'm not far enough from goal, but I'm searching for a way to add some factor to compensate the loss of the filter.
Should I calculate the fft in a parallel way and then try by software to apply the compensation  ?
Or is it a better way using an niScope function.

Thanks in advance


0 Kudos
Message 3 of 6
(3,816 Views)
David,

first of all, if you want to filter the signal from unwanted noise, you have to do that BEFORE acquistion. so you will have to have some kind of hardwarefilter.
the next thing is, i believe that you are not quite familiar with windowing for FFT. so please take a look here.

Norbert B.
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 4 of 6
(3,813 Views)
Hi Norbert

Maybe I was wrong on my denomination. I was talking about filtering, when I should talk about windowing.

My acquisition doesn't contain an integer number of period, that mean non coherent mode.
I would like to sample to do it but I cannot in all cases.

My peak rms value vary because I do no quadratic summation. Ie: I should take in account energy in bins around
my fundamental.
Is it wrong ? Adding a windowing can allow to be more selective on my spectrum, but I know I'll have to quatratic sommate
some bins around my  fundamental to get a correct Rms value.... depending lot of thing (Window, number of point....).

The NiScope allow to add a window after sampling and to FFT after the windowing. But it cannot compensate the window attenuation
on the Rms values.
How can I make it ??
Just adding some multiplicative factor ??

I took those lines from the "Peakest.prj" sample

    ScaledWindow (SignalArray, NB_PTS, Win, &WinConst);
    AutoPowerSpectrum (SignalArray, NB_PTS, 1/FREQ, Auto_Spec, &df);
    SpectrumUnitConversion (Auto_Spec, NB_PTS/2, 0, Scaling, Display, df, WinConst, Converted_Spec, Unit);

Here The signal is windowed by the win type window. The corrective factor is stocked in the WinConst.
Then converting the power spectrum in Rms, the corrective factor is applied.

I'm lookin for a way to do it using an NiScope function.

Thanks David






0 Kudos
Message 5 of 6
(3,810 Views)
David,

sadly the forum deleted my last last answer therefore here the short type: take a look into the example windowng.prj delivered with LabWindows/CVI.

hope this helps,
Norbert
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 6 of 6
(3,779 Views)