On Tue, Dec 30, 2014 at 13:58:49 -0500, Doug Stewart wrote:

>

>

> On Tue, Dec 30, 2014 at 12:48 PM, Doug Stewart <

[hidden email]>

> wrote:

>>

>> Rik asked me to start a discussion here about how to fix this bug.

>>

>> The real question is: Should we do as Matlab did or should we make the

>> default

>> be the more mathematically correct method.

>>

>> I am arguing for the mathematically correct method as the default.

>> ( I will be happy even if I loose the argument)

>>

>> I will post my argument in the next chapter :-)

>>

>> Comment are welcome.

>>

>>

>

> The technical reason that our window functions are wrong was

> given by the original poster, Oscar Ruitt.

>

> The Wikipedia page down at

> Filter design:

>

http://en.wikipedia.org/wiki/Window_function> Shows 3 different methods

> -- Matlab symmetric

> -- Matlab Periodic

> -- DFT-even

>

> DFT-even is what I have been thinking as the "correct"

> way to go.

I think the most important criterion for this specific case of the

window functions is to be compatible with Matlab. The law of least

surprise says the default should return a symmetric window with

properties equivalent to Matlab, this is correct and useful for

digital filter design. The "periodic" option should be accepted, at

least for those functions where it is accepted in Matlab, and return

the truncated n+1 window, useful for windowing with DFTs.

--

mike