Understanding N-Stages of FFT & DFT Formula for Frequency Domain

Click For Summary
SUMMARY

The discussion centers on the N-stages of the Fast Fourier Transform (FFT) and the Discrete Fourier Transform (DFT) formula for converting signals from the time domain to the frequency domain. It is established that a radix-2 FFT of N=2^M points has M stages, while other algorithms may apply to different N values. The DFT formula is confirmed as X_k = ∑(n=0 to N-1) x_n e^{-j 2 π k n / N}, representing the sequence as a sum of complex exponentials, which serve as orthogonal basis functions. The butterfly diagram's bottom line being -1 remains unclear to some participants.

PREREQUISITES
  • Understanding of FFT algorithms, specifically radix-2 FFT.
  • Familiarity with the DFT formula and its mathematical representation.
  • Knowledge of complex exponentials and orthogonal functions.
  • Basic concepts of signal processing and frequency domain analysis.
NEXT STEPS
  • Study the implementation of radix-2 FFT and its efficiency in various applications.
  • Explore alternative FFT algorithms for non-power-of-two inputs.
  • Learn about the mathematical properties of orthogonal functions in signal processing.
  • Investigate the role of butterfly diagrams in FFT implementations and their significance.
USEFUL FOR

Signal processing engineers, software developers working with FFT algorithms, and students studying digital signal processing will benefit from this discussion.

btb4198
Messages
570
Reaction score
10
1) How many stages are in N numbers for a FFT? I know N=8 has 3 stages and N=4 has 2 stages ?
2) The DFT formula converts a signal from the time domain into the frequency domain. Is this done by comparing x[n] against signals known as sinusoidal basis functions? are e-j2 pi kn/N sinusoidal basis functions ? I know it uses Correlation and that mean it compares the variables together but I am not 100% sure how this work ?

3) In a butterfly diagram the bottom line is alway -1, but why?

PS, I have been reading and watch videos on the DFT and the FFT and I have learned a lot, but I am just not sure about this questions.
 
Engineering news on Phys.org
anyone ?
 
btb4198 said:
1) How many stages are in N numbers for a FFT? I know N=8 has 3 stages and N=4 has 2 stages ?
It depends ... perhaps that is why no one has replied. If you are doing a radix 2 FFT of N=2^M points then sure, you have M stages. But at the end of the day we all want software that is efficient, and radix 2 isn't always the answer. It doesn't even apply to something like a 100 point FFT. There are a number of different algorithms. Some use prime factors, some don't.

btb4198 said:
2) The DFT formula converts a signal from the time domain into the frequency domain. Is this done by comparing x[n] against signals known as sinusoidal basis functions? are e-j2 pi kn/N sinusoidal basis functions ? I know it uses Correlation and that mean it compares the variables together but I am not 100% sure how this work ?
First, the built-in assumption is that the sequence x[n] of N numbers is one period of a periodic sequence. So it is reasonable to try and represent the sequence as a sum of complex exponentials that are consistent with the assumed periodicity of the given sequence. Now look at the formula for the DFT ,
<br /> X_k = \sum_{n=0}^{N-1} x_n e^{-j 2 \pi k n / N}<br />
and the inverse,
<br /> x_n = \frac{1}{N}\sum_{k=0}^{N-1} X_k e^{j 2 \pi k n / N}<br />
I think of this as projecting the sequence x_n onto a set of orthogonal basis functions e^{j 2 \pi k n /N}, and the X_k are just the inner product (or dot product) of the sequence and the k^{th} basis function. By orthogonal, I just mean,
<br /> \sum_{k=0}^{N-1} e^{j 2 \pi k_1 n / N} e^{-j 2 \pi k_2 n / N} = N \delta_{k_1,k_2}<br /> &lt;br /&gt; where \delta_{k_1,k_2} is 1 if k_1\neqk_2 and 0 if k_1\neq k_2. &lt;br /&gt; &lt;br /&gt; The math is the same as representing a vector v in terms of a set of orthogonal basis vectors w_k. The only thing different from what you probably did in basic vector algebra is that our sequence and the complex sinusoids can all be complex, so for the inner product one of the items is conjugated. &lt;blockquote data-attributes=&quot;member: 483696&quot; data-quote=&quot;btb4198&quot; data-source=&quot;post: 5623051&quot; class=&quot;bbCodeBlock bbCodeBlock--expandable bbCodeBlock--quote js-expandWatch&quot;&gt; &lt;div class=&quot;bbCodeBlock-title&quot;&gt; btb4198 said: &lt;/div&gt; &lt;div class=&quot;bbCodeBlock-content&quot;&gt; &lt;div class=&quot;bbCodeBlock-expandContent js-expandContent &quot;&gt; 3) In a butterfly diagram the bottom line is alway -1, but why? &lt;/div&gt; &lt;/div&gt; &lt;/blockquote&gt;Sorry, I can&amp;#039;t help you here. I haven&amp;#039;t looked at a butterfly diagram in 20+ years! I do work with folks that implement FFTs in FPGAs and other hardware, and if I had such a job then I would know the butterfly inside and out. Hopefully someone else can help.&lt;br /&gt; &lt;br /&gt; jason
 
jasonRF said:
It depends ... perhaps that is why no one has replied. If you are doing a radix 2 FFT of N=2^M points then sure, you have M stages. But at the end of the day we all want software that is efficient, and radix 2 isn't always the answer. It doesn't even apply to something like a 100 point FFT. There are a number of different algorithms. Some use prime factors, some don't.First, the built-in assumption is that the sequence x[n] of N numbers is one period of a periodic sequence. So it is reasonable to try and represent the sequence as a sum of complex exponentials that are consistent with the assumed periodicity of the given sequence. Now look at the formula for the DFT ,
<br /> X_k = \sum_{n=0}^{N-1} x_n e^{-j 2 \pi k n / N}<br />
and the inverse,
<br /> x_n = \frac{1}{N}\sum_{k=0}^{N-1} X_k e^{j 2 \pi k n / N}<br />
I think of this as projecting the sequence x_n onto a set of orthogonal basis functions e^{j 2 \pi k n /N}, and the X_k are just the inner product (or dot product) of the sequence and the k^{th} basis function. By orthogonal, I just mean,
<br /> \sum_{k=0}^{N-1} e^{j 2 \pi k_1 n / N} e^{-j 2 \pi k_2 n / N} = N \delta_{k_1,k_2}<br /> &lt;br /&gt; where \delta_{k_1,k_2} is 1 if k_1\neqk_2 and 0 if k_1\neq k_2.&lt;br /&gt; &lt;br /&gt; The math is the same as representing a vector v in terms of a set of orthogonal basis vectors w_k. The only thing different from what you probably did in basic vector algebra is that our sequence and the complex sinusoids can all be complex, so for the inner product one of the items is conjugated.&lt;br /&gt; Sorry, I can&amp;#039;t help you here. I haven&amp;#039;t looked at a butterfly diagram in 20+ years! I do work with folks that implement FFTs in FPGAs and other hardware, and if I had such a job then I would know the butterfly inside and out. Hopefully someone else can help.&lt;br /&gt; &lt;br /&gt; jason
&lt;br /&gt; &lt;br /&gt; sorry but I am not really understanding your second answer. Why is it &amp;quot;represent the sequence as a sum of complex exponential &amp;quot;?
 
The IFFT is
<br /> x_n = \frac{1}{N}\sum_{k=0}^{N-1} X_k e^{j 2 \pi k n / N}<br />
The left hand side is the original sequence; the right side is a sum of complex exponentials.
 

Similar threads

  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
Replies
3
Views
2K
Replies
8
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
3
Views
5K
  • · Replies 2 ·
Replies
2
Views
7K
  • · Replies 5 ·
Replies
5
Views
2K