Prev: Problem using the /r and -nojvm options together
Next: how to reproduce the M.file? (Neural network) PLZ..
From: Pete Fraser on 30 Jun 2010 21:21 I'm new to Matlab, so this is probably a really dumb question. I'm trying to design an FIR where I can set the points. I want a symmetric FIR. I'm assuming that an N tap FIR gives me N/2 degrees of freedom for an even number of taps, and (N + 1)/2 degrees of freedom for an odd number of taps. This should allow me to set the frequency response at a number of points equal to the degrees of freedom, and have the frequency response travel through these points exactly. If I don't specify transitions that are too sharp relative to the number of taps, then the frequency response should be reasonably well controlled between the set points. I had assumed that I could use the filter toolbox's freqsamp method to do this, but it doesn't seem to work as I expected. What am I doing wrong? I'd normally do this in Mathematica or C, but I'm trying to get into the spirit of Matlab. I would want to solve the point setting problem anyway, but perhaps there's an easier way to do the immediate task that I wanted it for. I want to implement a Butterworth amplitude response in an FIR filter (to emulate some legacy equipment) but I can't find an easy way of doing that in Matlab (hence the point setting experiments). Thanks Pete
From: Vladimir Vassilevsky on 30 Jun 2010 21:35 Pete Fraser wrote: > I'm new to Matlab, so this is probably a really dumb question. > I'm trying to design an FIR where I can set the points. > I want a symmetric FIR. > I'm assuming that an N tap FIR gives me N/2 degrees of freedom > for an even number of taps, and (N + 1)/2 degrees of freedom > for an odd number of taps. > This should allow me to set the frequency response at a > number of points equal to the degrees of freedom, and > have the frequency response travel through these points > exactly. If I don't specify transitions that are too sharp > relative to the number of taps, then the frequency response > should be reasonably well controlled between the set points. > > I had assumed that I could use the filter toolbox's freqsamp > method to do this, but it doesn't seem to work as I expected. > What am I doing wrong? I'd normally do this in Mathematica > or C, but I'm trying to get into the spirit of Matlab. > > I would want to solve the point setting problem anyway, but > perhaps there's an easier way to do the immediate task that > I wanted it for. I want to implement a Butterworth amplitude > response in an FIR filter (to emulate some legacy equipment) > but I can't find an easy way of doing that in Matlab (hence the > point setting experiments). But why would anyone want to emulate Butterworth magnitude response in a linear phase FIR filter whereas it is very straightforward to do the (**exact) Butterworth as IIR filter? ** frequency warping Vladimir Vassilevsky DSP and Mixed Signal Design Consultant http://www.abvolt.com
From: Pete Fraser on 30 Jun 2010 22:06 "Vladimir Vassilevsky" <nospam(a)nowhere.com> wrote in message news:0Jidnc3knONVbbbRnZ2dnUVZ_oSdnZ2d(a)giganews.com... > But why would anyone want to emulate Butterworth magnitude response in a > linear phase FIR filter whereas it is very straightforward to do the > (**exact) Butterworth as IIR filter? Butterworth will be one of several possible responses from the same hardware. I'd rather not deal with Butterworth's phase issues. Pete
From: Jerry Avins on 30 Jun 2010 22:39 On 6/30/2010 10:06 PM, Pete Fraser wrote: > "Vladimir Vassilevsky"<nospam(a)nowhere.com> wrote in message > news:0Jidnc3knONVbbbRnZ2dnUVZ_oSdnZ2d(a)giganews.com... > >> But why would anyone want to emulate Butterworth magnitude response in a >> linear phase FIR filter whereas it is very straightforward to do the >> (**exact) Butterworth as IIR filter? > > Butterworth will be one of several possible responses > from the same hardware. > > I'd rather not deal with Butterworth's phase issues. What is so good about a Butterworth amplitude response that you want to imitate it? Jerry -- Engineering is the art of making what you want from things you can get. �����������������������������������������������������������������������
From: Tim Wescott on 30 Jun 2010 22:39 On 06/30/2010 06:21 PM, Pete Fraser wrote: > I'm new to Matlab, so this is probably a really dumb question. > I'm trying to design an FIR where I can set the points. > I want a symmetric FIR. > I'm assuming that an N tap FIR gives me N/2 degrees of freedom > for an even number of taps, and (N + 1)/2 degrees of freedom > for an odd number of taps. > This should allow me to set the frequency response at a > number of points equal to the degrees of freedom, and > have the frequency response travel through these points > exactly. If I don't specify transitions that are too sharp > relative to the number of taps, then the frequency response > should be reasonably well controlled between the set points. > > I had assumed that I could use the filter toolbox's freqsamp > method to do this, but it doesn't seem to work as I expected. > What am I doing wrong? I'd normally do this in Mathematica > or C, but I'm trying to get into the spirit of Matlab. > > I would want to solve the point setting problem anyway, but > perhaps there's an easier way to do the immediate task that > I wanted it for. I want to implement a Butterworth amplitude > response in an FIR filter (to emulate some legacy equipment) > but I can't find an easy way of doing that in Matlab (hence the > point setting experiments). Make a vector that "draws" the frequency response that you want, then take its FFT. It may not be the entirely kosher way to do it, but it certainly works. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com Do you need to implement control loops in software? "Applied Control Theory for Embedded Systems" was written for you. See details at http://www.wescottdesign.com/actfes/actfes.html
|
Next
|
Last
Pages: 1 2 3 4 5 Prev: Problem using the /r and -nojvm options together Next: how to reproduce the M.file? (Neural network) PLZ.. |