help-octave
[Top][All Lists]
Advanced

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

Re: sosfit in filter function


From: Mike Miller
Subject: Re: sosfit in filter function
Date: Wed, 9 May 2018 10:31:04 -0700
User-agent: Mutt/1.9.5 (2018-04-13)

On Tue, May 08, 2018 at 23:21:33 -0700, yamane wrote:
> There is a numerical instability on butter function, as described in
> https://www.mathworks.com/help/signal/ref/butter.html (topic "Limitations").
> 
> Is recommend use [z, p, k] syntax and sosfilt function to apply a
> second-order section filter, as described in
> https://savannah.gnu.org/bugs/?53855
> 
> But, the documentation of SOSFILT is not clear:
> https://octave.sourceforge.io/signal/function/sosfilt.html
> 
> Someone have an idea about how to use ZPK Design instead a TF Design in this
> code below?

Instead of this

    [b, a] = butter (...
    output = filter (b, a, input);

you would use this

    [z, p, k] = butter (...
    sos = zp2sos (z, p, k);
    output = sosfilt (sos, input);

-- 
mike

Attachment: signature.asc
Description: PGP signature


reply via email to

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