Thread Subject: Obtaining the frequency response from a digital filter

Subject: Obtaining the frequency response from a digital filter

From: Ana

Date: 8 Nov, 2009 10:18:01

Message: 1 of 4

Hi there,

I am converting from analog to digital filter, a butterworth using the bilinear transformation. I am obtaining the num and the den of the digital function, but when am plotting using freqz the response is not as desired. don t know if i am doing something wrong prior to freqz or that freqz is not the right command to plot for digital filters.

disp(' --------------------------------------------');
disp('| Design of a Digital 2nd order Butterworth Low-pass Filter |');
disp(' --------------------------------------------');
fs=input('Sampling frequency: ');% around 20e3;
s = tf('s'); % The analog form
num = 1;
den = [1 1.414 1 ];

%Converting to digital form
[numd,dend] = bilinear(num,den,fs)

zplane(dend,numd)
pause;
freqz(dend,numd,fs) % plotting the response.
pause;

Thankyou very much for any help . REally appreciate it.

Regards,
Ana

(ps. can i use this method to transform ANY other filter, like the chebyshev, elliptic, thompson etc.... THANKS ALOT!!!)

Subject: Obtaining the frequency response from a digital filter

From: Rune Allnor

Date: 8 Nov, 2009 11:07:12

Message: 2 of 4

On 8 Nov, 11:18, "Ana " <filter_wo...@yahoo.com> wrote:
> Hi there,
>
> I am converting from analog to digital filter, a butterworth using the bilinear transformation. I am obtaining the num and the den of the digital function, but when am plotting using freqz the response is not as desired. don t know if i am doing something wrong prior to freqz or that freqz is not the right command to plot for digital filters.
...

Designing discrete-time filters from analog prototypes
via the BLT is a somewhat involved algorithm, that requires
some 8-10 individual steps. Get any one of those steps wrong,
and you will be lost. Your code above only hints at a couple
of those steps, so there is no wonder why you don't get the
required result.

The algorithm for designing filters is beyond the scope of
USENET, so pick up a book on digital signal processin (or take
a class) to learn.

> (ps. can i use this method to transform ANY other filter, like the  chebyshev, elliptic, thompson etc.... THANKS ALOT!!!)

The BLT is the core of a design method that can use several
analog IIRs as prototype. I know it can be used for the
Butterworth, Chebychev types I and II, elliptic filters;
maybe it works with other types of analog filters as well.
I don't know.

But again: You need to know what you are doing - and get
every single detail right! - to get the method to work.

Rune

Subject: Obtaining the frequency response from a digital filter

From: Ana

Date: 8 Nov, 2009 12:19:01

Message: 3 of 4

Would you suggest any particular book? Thanks alot.

Regards,
Ana

Subject: Obtaining the frequency response from a digital filter

From: Rune Allnor

Date: 8 Nov, 2009 13:56:49

Message: 4 of 4

On 8 Nov, 13:19, "Ana " <filter_wo...@yahoo.com> wrote:
> Would you suggest any particular book? Thanks alot.

Filter design is fairly standard, but this one contains
a lot of details that are left out of most books:

http://www.amazon.com/Digital-Signal-Processing-Signals-Systems/dp/0071454241/ref=sr_1_1?ie=UTF8&s=books&qid=1257688535&sr=8-1

Rune

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
freqz Ana 8 Nov, 2009 05:19:04
bilinear transf... Ana 8 Nov, 2009 05:19:04
rssFeed for this Thread
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com