From: Fred Marshall on
robert bristow-johnson wrote:
> On Jul 3, 6:21 pm, Fred Marshall <fmarshallx(a)remove_the_xacm.org>
> wrote:
>> robert bristow-johnson wrote:
>>> On Jul 1, 10:59 am, Fred Marshall <fmarshallx(a)remove_the_xacm.org>
>>> wrote:
>>>> r b-j,
>>>> Well, maybe I've had it wrong all these years but I'd say that the
>>>> windowing method starts with N frequency samples where N is the length
>>>> of the filter you want.
>>> so then, since the DFT and iDFT are bijective (i love using fancy-
>>> pants words), why window? if h[n] has N samples and N degrees of
>>> freedom, so does H[k]. you specify your N frequency samples and you
>>> can hit it perfectly with no windowing.
>>> so, that seems curious to me.
>>> r b-j
>> You window because the frequency response between those points can be
>> nasty. Either you don't window and convolve those samples with a
>> matching sinc er.. Dirichlet or you window and convolve those samples
>> with something else.
>
> you're always windowing it (unless your impulse response is an
> infinitely-repeating periodic function. you draw your N (or more)
> discrete points in the frequency domain, you iDFT it and what you have
> there is still a periodic sequence. if you use just one cycle of that
> (and zero the rest, as you would for an FIR), then you've applied the
> rectangular window.
>
>> The trade is that the Dirichlet matches all the samples exactly. Other
>> windows don't. Some match them all except the adjacent two as in the
>> 1/2 1 1/2 sum of adjacent Dirichlets. It still has zeros in the sum
>> at all the other sample points - so the convolution doesn't perturb
>> their values. And, the values between points are better behaved.
>
> the values between points exhibit less "high frequency" behavior or
> are less smooth. that's normally thought of as "better". and the
> reason is that in the other domain (where the window is applied),
> you've reduced the amplitude of the points further from h[0] (the
> "high frequency" points, but they're really the high time-displacement
> points that fuel the "high frequency" wiggling in the frequency
> domain.
>
>> And making N larger to begin with doesn't affect any of this in my way
>> of looking at it.
>
> it allows you to draw the frequency response more densely. so you can
> explicitly specify how "wiggly" you want it between the sparser points
> you have with your smaller "N". but to do so, the impulse response is
> very large, too large. so you have to shorten it and that is
> windowing. then, starting with the ideal (but too long) impulse
> response, you can try shortening it in a variety of different ways
> (using different windows) and see how well you do. you can also try
> shortening it to different lengths (using whatever window that looks
> best) to make a tradeoff decision on FIR length and its performance.
>
> it's very similar in philosophy to what we do with the windowed-sinc
> LPF design. start with the ideal (which is too long) and see what
> happens when you settle for something shorter.
>
> r b-j
>
>

r b-j,

OK. That interesting - the approaches have the same underlying
ingredients and are only different by virtue of how the starting points
are viewed.

In the "infinite-N" case you would be seeking N based on responses and,
I guess would decide on a non-rectangular window (or windows) to use in
the process. As soon as you do the first test case it's the same as the
"fixed-N" approach. It rather assumes that you don't know N very well,
right?

In the "fixed-N" case you would be seeking acceptable response by
choosing non-rectangular window functions of length N. And then, if you
aren't satisfied, iterate N. Just as the "infinite-N" case does in the end.

I think of both as the "windowing method". How you approach it depends
on how closely you figure you know N and your own preference. Either
way, just like using P-M, you have to choose an N at some point.

My way of roughly choosing N is to look at the minimum transition band
width W and spec N so that the temporal length of the filter is approx
1.5/W. And, for even rougher estimates just 1/W which is what I usually
use when discussing the "physics". You get to pick based on where you
put the break points in the transition - so that choice usually gets
mixed up with band ripple - particularly with minimax criterion. The
lower the ripple, the wider the transition and the longer the filter.
But, it's sure that the filter can't be any *shorter*!! :-)

And, then, if you like you can use one of those length-estimating formulas.

Fred