LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

band rms

Hi all, I am trying to determine the RMS in a specific band, in my case 50Hz. I compare this value with the overall RMS to determine the signal deformation. To determine the 50Hz RMS I now just make an FFT with a df of 1Hz and retreive the 50th bin value. Unfortunately this value regularly exceeds the total signal RMS (all be it  marginally). Therefore I am lloking to find another approach to determine the in band power. Anybody have a suggestion on what VI(s) to use. Maybe one of the many toolkits available from NI?
Thanks!
0 Kudos
Message 1 of 7
(3,513 Views)
Aart-Jan,

How are you doing your calculations? I built the attached VI (LV 8.20) which simulates a signal with variable frequency and signal to noise ratio (SNR). I calculated the RMS voltage of the peak bin by calculating RMS of the total FFT and the FFT with the peak bin removed. Signal(RMS) = sqrt(Total FFT^2 - peak removed FFT^2). By this method the signal component seems more reasonable.

Lynn
0 Kudos
Message 2 of 7
(3,503 Views)
Lynn, I understand your explanation, but I don't quite know how to correctly implement that. Furthermore, the attached VI didn't seem to implement it either.
Attached picture shows how I determine the power at 50 Hz. The flat top window should account for slight variations and a good approximation of the 50 Hz amplitude. However, this windowed FFT supposedly is not a good FFT to compute the total RMS with. So I use the simple DC/RMS function for that (No FFT needed, after all).
This approach thus results in some cases to a higher 50Hz RMS than a complete signal RMS.
I am sorry to say this kind of physics is really not my cup of tea, so this is about as much as I can comprehend myself.
I have toolkits like the Sound & Vibration toolkit that I think may have suitable VIs for this type of analysis.

0 Kudos
Message 3 of 7
(3,492 Views)
Aart-Jan,

Some of the DC/RMS VIs also use windowing (Hanning). If your signal has significant energy in the windowed portions at the beginning or end, that may account for some of the differences.

What kind of signal are you measuring? Minimum and maximum frequency components? Sampling rate? Number of samples? Expected 50 Hz to everything else ratios? Is there any other signal (or high noise levels) very close to the 50 Hz component you are trying to measure?

I am thinking that perhaps a different approach may be better than trying to sort out what is going on. Sometimes I find with signal processing issues that the nice packaged VIs are not exactly what I want or I cannot determine exactly what they are doing. In such cases using the fundamental functions (base FFT) and doing my own scaling, separating, or extracting seems to get to the desired result sooner. It may seem like more work, but the time spent trying to debug the higher level functions can also add up.

Lynn
Message 4 of 7
(3,486 Views)
First of all, thanks for all the help, Lynn. I am sampling one channel at 400 KHz after it has passed a low pass filter at 100 KHz. The signal should only contain 50 Hz and I am trying to monitor if other currents pollute the signal. These other frequencies will be comparatively small compared to the 50 Hz component. I use the "Basic Averaged DC-RMS for 1 Chan" vi for the RMS caculation, with no windowing applied. This vi is part of the advanced signal processing toolkit if I am not mistaken).

Message Edited by aartjan on 03-13-2007 03:16 PM

0 Kudos
Message 5 of 7
(3,478 Views)
Aart-Jan,

That seems like a reasonable setup. I don't have the toolkit, so I cannot say anything about that VI. Have you tried staying in the time domain? Set up a Band Reject filter or Notch filter tuned to 50 Hz. Measure the filtered and unfiltered signals. With a 100 kHz bandwidth you may have significant total noise even if the noise density is low. Be careful to make sure that your comparisons account for that.

Lynn
0 Kudos
Message 6 of 7
(3,462 Views)
I solved the problem pretty much. See attached picture for the solution. It is still possile to get an RMS that exceeds the complete signal RMS, but I categorize those events as due to transients and the fact that every filter has it own peculiar behaviours.

Thanks!
0 Kudos
Message 7 of 7
(3,390 Views)