On Oct 31, 4:04 pm, Mark Borgerding <
[email protected]> wrote:
> Fred Marshall wrote:
> > "Mark Borgerding" <
[email protected]> wrote in message
> >news:
[email protected]...
> >> Rune Allnor wrote:
> >>> On 28 Okt, 14:37, Richard Owlett <
[email protected]> wrote:
> >>>> I'm looking at comparing FFT's of a batch of signals.
> >>>> Right now I'm choosing how to window the input data.
> >>>> I noticed that none of the _common_ windows have flat top except for the
> >>>> "rectangular window".
>
> >>>> Is there a reason other than the simplicity of calculating the window
> >>>> function? I was thinking about piecewise continuous with continuous
> >>>> first derivative.
> >>> There is the Tukey window, which I think has a "flat" top.
>
> >>> FIR filter design by window functions is all but obsolete
> >>> after methods like Parks-McClellan were developed. So the
> >>> detailed analysis of window functions is not all that
> >>> interesting these days...
>
> >>> Rune
>
> >> AFAIK, Parks-McClellan, AKA Remez Exchange filters must be verified before
> >> use since it may not not converge to a solution.
>
> > Maybe but you verify by running it - not before. Not a huge cost.
>
> If you are writing a program that designs a filter and then runs it,
> what should the program do if it fails verification?
>
>
>
> >> Windowed design is still needed where predictability and stability is more
> >> important than squeezing the utmost out of every coefficient.
>
> > What predicability and stability do you refer to here? It appears you mean
> > the predictability of being able to achieve a design. P-M is so easy to try
> > that it's always a first step for me. If it fails, then I've only wasted a
> > couple of minutes.
>
> Fine, but for a system that autonomously generates and executes a
> filter, I'll stick with window design.
yeah, i think, even if source code exists for P-McC or similar, if
someone draws a target frequency response (magnitude only, or
magnitude and phase) for positive frequency (and assuming Hermitian
symmetry or real h[n]), that an automated process that iterates the
remez exchange algorithm and checks for convergence, might be a little
icky. i would expect to do it by inverse DFT (with a lot more points
than length of h[n]), and windowing it (probably with Kaiser) to your
length limit. as an automated filter that you draw on the screen, hit
some soft button, and viola - an FIR that hopefully closely follows
your spec to within some constant delay necessary for causality.
but if it's not some rack-mounted real-time box or similar computer
program or plug-in, but an engineering procedure, if the tools are
quick and cheap to run, i see no reason *not* to compare, for a given
FIR length, what you will get from a variety of methods: various
windowed h[n], Least Square fit, Parks-McClellan, possibly an LMS
filter with repeated input having output convergerging to an optimal
solution, something else that hasn't been dreamt up yet.
r b-j