Matlab

To Plot FFT (Fast Fourier Transform Algorithms) For the Given Sequence

Theory:

FFT is a most efficient algorithm used in speech processing, frequency estimation and communication. FFT utilizes full advantage of two symmetry properties in order to provide efficient algorithm for DFT. while considering a divide and conquer approach, a computationally efficient algorithm can be developed. This methods depends on the decomposition of an N-point DFT into successively smaller size then DFTs. While in the N-point sequence, the term N can be expressed as N = r1r2r3, …, rm, then N = r m, can be decimated into r-point sequences For each r point sequence, r-point DFT are often computed. Hence the DFT is of size r. if the number r is called the radix of the FFT algorithm while the number m indicates the number of stages in computation. If the value of r = 2, it is called radix-2 FFT.

Steps involved in finding the FFT of the given sequence:

  • Let’s consider an input sequence as x[n].
  • Let’s find the length for the input sequence using length command.
  • In order to find FFT and IFFT by using the matlab commands fft and ifft.
  • Let’s plot the magnitude and phase response for the given sequence.
  • And finally display the results.

Program:

clc;

clear all;

close all;

x=input(‘Enter the sequence : ‘)

N=length(x)

xK=fft(x,N)

xn=ifft(xK)

n=0:N-1;

subplot (2,2,1);

stem(n,x);

xlabel(‘n—->’);

ylabel(‘amplitude’);

title(‘input sequence’);

subplot (2,2,2);

stem(n,abs(xK));

xlabel(‘n—->’);

ylabel(‘magnitude’);

title(‘magnitude response’);

subplot (2,2,3);

stem(n,angle(xK));

xlabel(‘n—->’);

ylabel(‘phase’);

title(‘Phase response’);

subplot (2,2,4);

stem(n,xn);

xlabel(‘n—->’);

ylabel(‘amplitude’);

title(‘IFFT’);

Output:

Enter the sequence: [3 2 4 5 1]

x = 3     2     4     5     1

N =5

xK =15.0000 + 0.0000i  -3.3541 – 0.3633i   3.3541 – 1.5388i   3.3541 + 1.5388i  -3.3541 + 0.3633i

xn =3.0000    2.0000    4.0000    5.0000    1.0000

Rajeshwari Chiluveru

Rajeshwari (M.Tech) is the Technical Education Director at WebVidyalayam. She focuses on translating high-level systems engineering into accessible technology courses.

Share
Published by
Rajeshwari Chiluveru

Recent Posts

Samsung TV Red Light Blinking? 4 Fixes (2026 Power Logic Hub)

User Problem Scenario: The Red Light "Panic" You press the power button on your Samsung…

5 days ago

Samsung TV Not Connecting to WiFi: 2026 Easy Fix Guide

Introduction: I Know the Feeling "We’ve all been there. You sit down to watch your…

6 days ago

Samsung TV Restarting During Diagnosis? Fix the Reboot Loop Fast

User Problem Scenario: The "Diagnosis Loop" Paradox Imagine you notice your apps are slow. You…

6 days ago

Samsung TV Optimize Now Not Working? (2026 Fix: Greyed Out, Stuck or Not Responding)

🎓 Technical Module: Memory Maintenance Logic Module: WV-OS-307 Verified 2026 👨‍🏫 Instructor: Vangari Divya (M.Tech)…

1 week ago

Samsung Smart Hub Test Failed? (2026 Fix: DNS, ISP Block & Authentication Error)

 Introduction: The Setup Paradox "There is a specific moment of frustration for every Samsung Smart…

2 weeks ago

Samsung TV Picture Test Not Working? 4 Technical Recovery Fixes

Introduction: Lab Diary & Experience "When your Samsung TV screen begins to flicker or show…

2 weeks ago