Skip to main content

Cooley-Tukey algorithm for Fast Fourier Transform (FFT)

 

Here's a step-by-step explanation of the Cooley-Tukey FFT algorithm:

1. Base Case: If the length of the input sequence x is 1, then the FFT of x is simply x itself. This is the stopping condition for the recursion.

2. Recursive Splitting: If the length of x is greater than 1, the algorithm splits the sequence into two parts: one containing the even-indexed elements and the other containing the odd-indexed elements.

3. FFT Computation: Recursively apply the FFT algorithm to both the even and odd subsequences obtained from the splitting step. This involves repeating steps 1-2 for each subsequence until reaching the base case.

4. Twiddle Factor: Calculate the twiddle factors, which are complex numbers that are applied to the odd-indexed elements before combining them with the even-indexed elements. These factors are calculated as e−2Ï€ik/N, where k ranges from 0 to N/2−1, and N is the length of the input sequence.

5. Combine Results: Combine the FFTs of the even and odd subsequences using the twiddle factors. Specifically, multiply the FFT of the odd subsequence by the twiddle factors element-wise, and then add the results to the FFT of the even subsequence. Similarly, subtract the same result from the FFT of the even subsequence.

6. Final Result: The combined results form the FFT of the original sequence xxx. This process continues recursively until the entire FFT is computed.

By recursively applying these steps, the Cooley-Tukey FFT algorithm efficiently computes the FFT of a given sequence.

 

MATLAB Function Code for Cooley-Tukey Fast Fourier Transform (FFT) algorithm

 

 

MATLAB Code for FFT of a Sine Function

 

 Output

 


MATLAB Code for FFT of a Cosine Function

 

 Output

 


MATLAB Code for FFT of a Gaussian Function

 

Output

People are good at skipping over material they already know!

View Related Topics to







Admin & Author: Salim

s

  Website: www.salimwireless.com
  Interests: Signal Processing, Telecommunication, 5G Technology, Present & Future Wireless Technologies, Digital Signal Processing, Computer Networks, Millimeter Wave Band Channel, Web Development
  Seeking an opportunity in the Teaching or Electronics & Telecommunication domains.
  Possess M.Tech in Electronic Communication Systems.


Contact Us

Name

Email *

Message *

Popular Posts

BER vs SNR for M-ary QAM, M-ary PSK, QPSK, BPSK, ...

📘 Overview of BER and SNR 🧮 Simulator for m-ary QAM and m-ary PSK 🧮 MATLAB Codes 📚 Further Reading Modulation Constellation Diagrams BER vs. SNR BER vs SNR for M-QAM, M-PSK, QPSk, BPSK, ... What is Bit Error Rate (BER)? The abbreviation BER stands for bit error rate, which indicates how many corrupted bits are received (after the demodulation process) compared to the total number of bits sent in a communication process. It is defined as,  In mathematics, BER = (number of bits received in error / total number of transmitted bits)  On the other hand, SNR refers to the signal-to-noise power ratio. For ease of calculation, we commonly convert it to dB or decibels.   What is Signal the signal-to-noise ratio (SNR)? SNR = signal power/noise power (SNR is a ratio of signal power to noise power) SNR (in dB) = 10*log(signal power / noise power) [base 10] For instance,...

UGC NET Electronic Science Previous Year Question Papers

Home / Engineering & Other Exams / UGC NET 2022: Previous Year Question Papers ...   NET | GATE | ESE | UGC-NET (Electronics Science, Subject code: 88 ) UGC Net Electronic Science Questions Paper With Answer Key Download Pdf [December 2024] UGC Net Electronic Science Questions Paper With Answer Key Download Pdf [June 2024] UGC Net Electronic Science Questions Paper With Answer Key Download Pdf [December 2023] UGC Net Electronic Science Questions Paper With Answer Key Download Pdf [June 2023] UGC Net Electronic Science Questions Paper With Answer Key Download Pdf [December 2022]  UGC Net Electronic Science Questions Paper With Answer Key Download Pdf [June 2022]   UGC Net Electronic Science Questions Paper With Answer Key Download Pdf [December 2021] UGC Net Electronic Science Questions With Answer Key Download Pdf [June 2020] UGC Net Electronic Science Questions With Answer Key Download Pdf [December 2019] UGC Net Electronic Science Questions With Answer...

Constellation Diagrams of ASK, PSK, and FSK

📘 Overview 🧮 Simulator for constellation diagrams of ASK, FSK, and PSK 🧮 Theory 🧮 MATLAB Codes 🧮 Simulator for constellation diagrams of m-ary PSK 🧮 Simulator for constellation diagrams of m-ary QAM 📚 Further Reading BASK (Binary ASK) Modulation: Transmits one of two signals: 0 or -√Eb, where Eb​ is the energy per bit. These signals represent binary 0 and 1.    BFSK (Binary FSK) Modulation: Transmits one of two signals: +√Eb​ ( On the y-axis, the phase shift of 90 degrees with respect to the x-axis, which is also termed phase offset ) or √Eb (on x-axis), where Eb​ is the energy per bit. These signals represent binary 0 and 1.  BPSK (Binary PSK) Modulation: Transmits one of two signals: +√Eb​ or -√Eb (they differ by 180 degree phase shift), where Eb​ is the energy per bit. These signals represent binary 0 and 1.    Simulator for BASK, BPSK, and BFSK Constellation Diagrams ...

Alamouti Scheme for 2x2 MIMO in MATLAB

📘 Overview & Theory 🧮 MATLAB Code for Alamouti Scheme 🧮 MATLAB Code for BER vs. SNR for Alamouti Scheme 🧮 Alamouti Scheme Transmission Table 📚 Further Reading    Read about the Alamouti Scheme first MATLAB Code for Alamouti's Precoding Matrix for 2 X 2 MIMO % Clear any existing data and figures clc; clear; close all; % Define system parameters transmitAntennas = 2; % Number of antennas at the transmitter receiveAntennas = 2; % Number of antennas at the receiver symbolCount = 1000000; % Number of symbols to transmit SNR_dB = 15; % Signal-to-Noise Ratio in decibels % Generate random binary data for transmission rng(10); % Set seed for reproducibility transmitData = randi([0, 1], transmitAntennas, symbolCount); % Perform Binary Phase Shift Keying (BPSK) modulation modulatedSymbols = 1 - 2 * transmitData; % Define Alamouti's Precoding Matrix precodingMatrix = [1 1; -1i 1i]; % Encode and transmit data using Alamouti scheme transmittedSym...

Comparisons among ASK, PSK, and FSK | And the definitions of each

📘 Overview 🧮 Simulator 🧮 Noise Sensitivity, Bandwidth, Complexity, etc. 🧮 MATLAB Codes 🧮 Some Questions and Answers 📚 Further Reading Modulation ASK, FSK & PSK Constellation MATLAB Simulink MATLAB Code Comparisons among ASK, PSK, and FSK    Comparisons among ASK, PSK, and FSK   Simulator for Calculating Bandwidth of ASK, FSK, and PSK The baud rate represents the number of symbols transmitted per second. Both baud rate and bit rate are same for binary ASK, FSK, and PSK. Select Modulation Type: ASK FSK PSK Baud Rate or Bit Rate (bps): Frequency Deviation (Hz) for FSK: Calculate Bandwidth Comparison among ASK,  FSK, and PSK Performance Comparison: 1. Noise Sensitivity:    - ASK is the most sensitive to noise due to its r...

MATLAB Code for Pulse Amplitude Modulation (PAM) and Demodulation

📘 Overview & Theory 🧮 MATLAB Code 1 🧮 MATLAB Code 2 🧮 MATLAB Code for Pulse Amplitude Modulation and Demodulation of Digital data 🧮 Other Pulse Modulation Techniques (e.g., PWM, PPM, DM, and PCM) 📚 Further Reading   Pulse Amplitude Modulation (PAM) & Demodulation MATLAB Script clc; clear all; close all; fm= 10; % frequency of the message signal fc= 100; % frequency of the carrier signal fs=1000*fm; % (=100KHz) sampling frequency (where 1000 is the upsampling factor) t=0:1/fs:1; % sampling rate of (1/fs = 100 kHz) m=1*cos(2*pi*fm*t); % Message signal with period 2*pi*fm (sinusoidal wave signal) c=0.5*square(2*pi*fc*t)+0.5; % square wave with period 2*pi*fc s=m.*c; % modulated signal (multiplication of element by element) subplot(4,1,1); plot(t,m); title('Message signal'); xlabel ('Time'); ylabel('Amplitude'); subplot(4,1,2); plot(t,c); title('Carrier signal'); xlabel('Time'); ylabel('Amplitu...

MATLAB code for Pulse Code Modulation (PCM) and Demodulation

📘 Overview & Theory 🧮 Quantization in Pulse Code Modulation (PCM) 🧮 MATLAB Code for Pulse Code Modulation (PCM) 🧮 MATLAB Code for Pulse Amplitude Modulation and Demodulation of Digital data 🧮 Other Pulse Modulation Techniques (e.g., PWM, PPM, DM, and PCM) 📚 Further Reading MATLAB Code for Pulse Code Modulation clc; close all; clear all; fm=input('Enter the message frequency (in Hz): '); fs=input('Enter the sampling frequency (in Hz): '); L=input('Enter the number of the quantization levels: '); n = log2(L); t=0:1/fs:1; % fs nuber of samples have tobe selected s=8*sin(2*pi*fm*t); subplot(3,1,1); t=0:1/(length(s)-1):1; plot(t,s); title('Analog Signal'); ylabel('Amplitude--->'); xlabel('Time--->'); subplot(3,1,2); stem(t,s);grid on; title('Sampled Sinal'); ylabel('Amplitude--->'); xlabel('Time--->'); % Quantization Process vmax=8; vmin=-vmax; %to quanti...