How to Design a lowpass filter by cascading 10 sections of the first-order IIR lowpass filter

13 views (last 30 days)
I design all of this filter but i can't understand how to make filter cascading 10 section.
out teacher said you can conv the transfer function 10 time but it didn't work. any idea?
%% low-pass IIR cascade K = 10 and compare with first-order low pass
clc; clear all; close all;
w = 0:pi/255:pi;
% For Tenth-Order Low-Pass IIR | Transfer Function
num1 = [1 1];
den1 = [1 0.31];
y = (num1) / (den1) ;
for i=1:9
y = conv (y,y)
end
h1 = freqz(y, 1, w);
g1 = 20*log10(abs(h1));
% PLOT CODE For Tenth-Order
figure (2);
plot(w/pi,g1);grid minor; axis ([0 1 -100 5]);
xlabel("\omega /\pi");ylabel("Gain in dB");
title("LOW-PASS Cascade K=10 IIR Filter");
i had problem in conv part that its result is incorrect.

Accepted Answer

Mathieu NOE
Mathieu NOE on 2 Dec 2020
hello
yes , conv is doing what your professor is asking , but this is the right way to use it (on the num and den part of your IIR filter)
%% low-pass IIR cascade K = 10 and compare with first-order low pass
clc; clear all; close all;
w = 0:pi/255:pi;
% For Tenth-Order Low-Pass IIR | Transfer Function
num1 = [1 1]/1.5267; % the /1.5267 is to make static gain = 1 (0 dB) (my suggestion)
den1 = [1 0.31];
% y = (num1) / (den1) ;
num = num1; % init
den = den1; % init
h1 = freqz(num, den, w);
g1 = 20*log10(abs(h1));
% PLOT CODE For first-Order
figure (1);
plot(w/pi,g1);grid minor; axis ([0 1 -100 5]);
xlabel("\omega /\pi");ylabel("Gain in dB");
title("LOW-PASS Cascade K=1 IIR Filter");
for i=1:9
num = conv (num,num1);
den = conv (den,den1);
end
h1 = freqz(num, den, w);
g1 = 20*log10(abs(h1));
% PLOT CODE For Tenth-Order
figure (2);
plot(w/pi,g1);grid minor; axis ([0 1 -100 5]);
xlabel("\omega /\pi");ylabel("Gain in dB");
title("LOW-PASS Cascade K=10 IIR Filter");

More Answers (0)

Categories

Find more on Digital and Analog Filters in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!