x = input('Enter the sequence'); n = input('Enter the length'); y = fft(x,n); stem(y); title('Discrete fourier transform'); xlabel('Real axis'); ylabel('Imaginary Axis');
Output
Enter the sequence[0.25 0.25 0.25 0] Enter the length4
x = input('Enter the sequence'); n = input('Enter the length'); y = fft(x,n); stem(y); title('Discrete fourier transform'); xlabel('Real axis'); ylabel('Imaginary Axis');
Output
Enter the sequence[0.25 0.25 0.25 0] Enter the length4