help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Trying to test analog filter


From: Arvid Rosén
Subject: Re: Trying to test analog filter
Date: Thu, 31 Mar 2005 16:46:48 +0200 (CEST)
User-agent: SquirrelMail/1.4.4

On To, 2005-03-31, 03:18, address@hidden skrev:
> Greetings to all,
>
> Just having a spot of bother trying to test out an analog filter. After
> generating the filter with the cheby1 command:
> [x,y]=cheby1(N,ripple_dB,wc,'s');
>
> I try to use the filter command to test it on an audio file:
>
> input = loadaudio('input','lin',16);
> output = filter(x,y,input);
> saveaudio('output',output,'lin',16);
>
> The output is garbage, I'm guessing because the filter command works with
> digital filters, not those in Laplace domain. My 2nd approach was this:
> aafilter = tf(x,y);
> aafilter_time = impulse(aafilter);
> output = conv(aafilter_time,input);
>
> For this approach the audio output is also garbage. I can't really
> understand why though, so if you're reading this and know, I'd be most
> grateful for any help you could give.
> Adrian.
>

You can try:

[B,A] = cheby1(N,ripple_dB,wc,'s');
T  = tf(B,A);
TD = c2d(T, 1/44100);

This will give you a discrete system TD to play around with. TD will
represent one of many ways descretize the continous system T.

Then, I am not sure how to proceed, but I believe that this is a good start.

/Arvid




-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]