help-octave
[Top][All Lists]
Advanced

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

Re: Filter Implementation


From: Doug Stewart
Subject: Re: Filter Implementation
Date: Mon, 3 Jul 2017 20:36:06 -0400



On Mon, Jul 3, 2017 at 8:05 PM, shall689 <address@hidden> wrote:
Thanks Doug,


Your work is getting me going in the right direction.  I don't know why I
was ever used excel in the first place.

You used a(1) (=1) for the y(n-1) term.   I was thinking that a(2)
(=-0.985033202259162) should be used for that term, i.e. y(n) = b(1)*x(n) +
b(2)*x(n-1) + a(2)*y(n-1).  Is that correct?

If a(2) is used for the y(n-1) term, the plot look like my excel plot, so
there is something I am misunderstanding about implementing the filter
equation.

Also, the filtered output has an offset if a(1) is used with y(n-1).

Stephen



you have

y                   b0 *Z +b1
----      =    -----------------------
x                   a0*Z  - a1

y                   b0 *Z +b1                  z^-1
----      =    -----------------------    *    -------
x                   a0*Z  - a1                  z^-1


y                   b0  +b1* z^-1
----      =    -----------------------
x                   a0  - a1 *z^-1



z^-1  means 1 time ago

y*(a0  - a1 *z^-1)= x*( b0  +b1* z^-1)

a0*y=  x*( b0  +b1* z^-1)   + y*a1*z^-1

since octave cant index at 0 we rename them and get my program.



--
DAS


reply via email to

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