Design FIR filter using cot off frequency

조회 수: 20 (최근 30일)
BOGIREDDY SIVAPRASADREDDY
BOGIREDDY SIVAPRASADREDDY 2020년 4월 11일
답변: BOGIREDDY SIVAPRASADREDDY 2020년 4월 11일
Design a low pass digital FIR filter using Hamming window with length of the filter, N = 9 and a cut off frequency of 1.2 rad/sec. Further plot the magnitude and phase response of the designed filter

채택된 답변

BOGIREDDY SIVAPRASADREDDY
BOGIREDDY SIVAPRASADREDDY 2020년 4월 11일
Clc;
Clear all;
Close all;
N=9; %number of samples
wc=1.2; %cut of frequncy wc=(2*fc/fs); f=corner freq., fs=sampling freq.
b=fir1(N,wc/pi,hamming(N+1));
w=0:0.01:1.2*pi;
h=freqz(b,1,w);
subplot(211);
plot(w/pi,20*log(abs(h)));
title('Magnitude response(dB)');
xlabel('Frequency(*pi rad/sample)');
ylabel('magnitude in dB');
subplot(212);
plot(w/pi,phase(h));
title('Phase response');
xlabel('Frequency(*pi rad/sec)');
ylabel('Phase in radians');

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Filter Design에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by