LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Amplitude of Sum of Sine Waves after FFT

Just like my previous post, i dont know why is the amplitude of the Sine Waves after FFT is decreasing, when it's supposed to be having a constant amplitude of 1. decrease.JPG

0 Kudos
Message 1 of 5
(3,339 Views)

Did you read the replies in your other thread? http://forums.ni.com/t5/LabVIEW/FFT-Amplitude-is-not-constant-for-Different-Sine-Signals/m-p/3042227...

 


@johnsold wrote:

Henrik is exactly right. You are experiencing spectral leakage. If you expand the spectral graph to show just one peak, you will see that there are several non-zero values on both sides of the peak. Some of the energy is in those bins resulting in a decrease of the amplitude of the largest peak.

 

If you run Extract Single Tone Information.vi on each of your frequencies, you will find that it reports the amplitudes of all of the signals as equal. Internally this VI uses FFT but also compensates for spectral leakage and includes the energy in the adjacent bins.  The very slight discrepancy in the 20 Hz values are due to the fact that there are not enough points below 20 Hz to completely resolve the leakage there.

 

Zwired1,

 

There is no need to convert to 2D arrays to matrix and back to 1D array to array of waveforms.  The Ramp pattern VI and one for loop cna generate the same signals.

 

Lynn


So, read what johnsold offered.  There are several non-zero values on both sides of the peak.  Let's see if that is a plausible explanation.  We look at the graph you just provided and we can see the peaks are not straight lights.  In fact, they have several non-zero values on both sides of the peak.  If we look at each of the peaks you've provided, the shortest peaks have the largest amount of leakage near them.

0 Kudos
Message 2 of 5
(3,330 Views)

So what do I do next?

0 Kudos
Message 3 of 5
(3,325 Views)

@jamison.suade wrote:

So what do I do next?



Well that depends on what you want.  

  1. Do you want an exact representation of pi in an 64 bit IEEE 754 floating point number? (How many digits are in pi? - Little Jack Horner got positive results with one digit in pie your results may vary)
  2. Do you want a "Fourier Transform" to express complex numbers as scalar vector magnitudes?  (Use Polar coordiates DeCartese wasn't always right either but, thought well of himself for justifyable reasons )
  3. do you want the graphs peaks to look the same level to a human eyeball?  Turn off autoscaling on the y-axis ans set the range to 0-50.

Basically, you have a limitation in applying machine computational theory and machine limits. There is nothing wrong with being unfamiliar with some concepts!  But "Help us Help You" to by explaining why you think the peak should be unity (1) and not near it (with some spurious noise in the sidebands)


"Should be" isn't "Is" -Jay
Message 4 of 5
(3,305 Views)

Well said, Jeff.

 

Lynn

0 Kudos
Message 5 of 5
(3,266 Views)