[SciPy-user] small error in documentation signal.py

Stef Mientki s.mientki at ru.nl
Fri Apr 13 17:24:14 EDT 2007


I don't know where to report bugs in scipy package,
and I don't know if errors in documentation are called bugs,
but anyway, here is the bug,


lfilter(b, a, x, axis=-1, zi=None)
<snip>
    Algorithm:
      The filter function is implemented as a direct II transposed 
structure.
      This means that the filter implements
      y[n] = b[0]*x[n] + b[1]*x[n-1] + ... + b[nb]*x[n-nb]
                       - a[1]*y[n-1] + ... + a[na]*y[n-na]

should be
      y[n] = b[0]*x[n] + b[1]*x[n-1] + ... + b[nb]*x[n-nb]
                       - a[1]*y[n-1] - ... - a[na]*y[n-na]

or this might even be better
      a[0]*y[n] = b[0]*x[n] + b[1]*x[n-1] + ... + b[nb]*x[n-nb]
                            - a[1]*y[n-1] + ... + a[na]*y[n-na]

cheers,
Stef Mientki



More information about the SciPy-User mailing list