DSPRelated.com
Forums

linear phase fir filter design

Started by TobiasKurowski March 23, 2006
Hello,

I want to do some audio filtering using fast convolution. The target is a
adjustable/drawable frequency response and linear phase filtering. As far
as I know, I can create the impulse response for the convolution by doing
a fft over the desired frequency response. And now my question: Is there a
way to get the filter created by a fft over the frequency response become
linear phase?

I would be happy about any tips, links, paper references...

all the best,
Tobias Kurowski


TobiasKurowski wrote:
> Hello, > > I want to do some audio filtering using fast convolution. The target is a > adjustable/drawable frequency response and linear phase filtering. As far > as I know, I can create the impulse response for the convolution by doing > a fft over the desired frequency response. And now my question: Is there a > way to get the filter created by a fft over the frequency response become > linear phase? >
Roughly speaking, you would need to do an inverse Fourier Transform (of the desired continuous frequency response) to get the correct impulse response, evaluated at integer values, i.e.: h[n] = int { H(W) . exp {j . W . n} dW } An FIR filter is phase-linear if its impulse response is symmetric (i.e. in the time-domain). -- Oli

TobiasKurowski wrote:
> > Hello, > > I want to do some audio filtering using fast convolution. The target is a > adjustable/drawable frequency response and linear phase filtering.
I'm guessing that adjustable/drawable means some sort of interactive curve construction so that the user can create a frequency response and subsequently hear the result. Anyway, to answer your question about linear phase. All you need to know is a couple of time<->frequency dualities. In order to get a time domain response that is real and symmetrical (which is what you have said you want) you need to create frequency domain response that is real and symmetrical. -jim
> As far > as I know, I can create the impulse response for the convolution by doing > a fft over the desired frequency response. And now my question: Is there a > way to get the filter created by a fft over the frequency response become > linear phase? > > I would be happy about any tips, links, paper references... > > all the best, > Tobias Kurowski
----== Posted via Newsfeeds.Com - Unlimited-Unrestricted-Secure Usenet News==---- http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups ----= East and West-Coast Server Farms - Total Privacy via Encryption =----
>TobiasKurowski wrote: >> I want to do some audio filtering using fast convolution. >> The target is a adjustable/drawable frequency response >> and linear phase filtering. As far as I know, I can create >> the impulse response for the convolution by doing a fft over >> the desired frequency response. And now my question: Is there a >> way to get the filter created by a fft over the frequency >> response become linear phase? >> > >Roughly speaking, you would need to do an inverse Fourier Transform (of >the desired continuous frequency response) to get the correct impulse >response, evaluated at integer values, i.e.: > > h[n] = int { H(W) . exp {j . W . n} dW }
I think that's what I have done in my matlab script and what is working very well. I create a nice frequency response that I convert into an impulse response using an
>An FIR filter is phase-linear if its impulse response is symmetric >(i.e. in the time-domain).
that's exactly my problem. the resulting impulse response is not symmetric. is there a way/trick to get a symmetric impulse response? thank you, Tobias
jim wrote:
> In order to get a time domain response that is real and > symmetrical (which is what you have said you want) you need to create > frequency domain response that is real and symmetrical.
*Hermitian* symmetrical... -- Oli
TobiasKurowski wrote:
> Oli Filth wrote: > >Roughly speaking, you would need to do an inverse Fourier Transform (of > >the desired continuous frequency response) to get the correct impulse > >response, evaluated at integer values, i.e.: > > > > h[n] = int { H(W) . exp {j . W . n} dW } > > I think that's what I have done in my matlab script and what is working > very well. I create a nice frequency response that I convert into an > impulse response using an > > >An FIR filter is phase-linear if its impulse response is symmetric > >(i.e. in the time-domain). > > that's exactly my problem. the resulting impulse response is not > symmetric. is there a way/trick to get a symmetric impulse response?
What sort of frequency responses are you using/generating? Are they definitely real and (Hermitian/conjugate) symmetric? -- Oli
>TobiasKurowski wrote: >> Oli Filth wrote: >> >Roughly speaking, you would need to do an inverse Fourier Transform
(of
>> >the desired continuous frequency response) to get the correct impulse >> >response, evaluated at integer values, i.e.: >> > >> > h[n] = int { H(W) . exp {j . W . n} dW } >> >> I think that's what I have done in my matlab script and what is
working
>> very well. I create a nice frequency response that I convert into an >> impulse response using an >> >> >An FIR filter is phase-linear if its impulse response is symmetric >> >(i.e. in the time-domain). >> >> that's exactly my problem. the resulting impulse response is not >> symmetric. is there a way/trick to get a symmetric impulse response? > >What sort of frequency responses are you using/generating? Are they >definitely real and (Hermitian/conjugate) symmetric?
I used cascaded biquads (lp/hp/peak) and calculate a frequency response that I use for my impulse response. Probably nobody will use a fast convolution to simulate biquads, but I thouht if I get them linear phase I get a good eq. So, unfortunately it's more than just a sharp lopass.
>TobiasKurowski wrote: >> >> I want to do some audio filtering using fast convolution. The target is >> a adjustable/drawable frequency response and linear phase filtering. > >I'm guessing that adjustable/drawable means some sort of interactive >curve construction so that the user can create a frequency response and >subsequently hear the result.
that's what I wanted to do.
>Anyway, to answer your question about >linear phase. All you need to know is a couple of time<->frequency >dualities. In order to get a time domain response that is real and >symmetrical (which is what you have said you want) you need to create >frequency domain response that is real and symmetrical.
If I understand proper, the impulse response gets symmetric when the frequency response is symmetric, that was used to generate the impulse response? thank you, Tobias
TobiasKurowski wrote:

   ...

> I used cascaded biquads (lp/hp/peak) and calculate a frequency response > that I use for my impulse response. Probably nobody will use a fast > convolution to simulate biquads, but I thouht if I get them linear phase I > get a good eq. So, unfortunately it's more than just a sharp lopass.
Why is linear phase important for this application? jerry -- Engineering is the art of making what you want from things you can get. &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;

TobiasKurowski wrote:
> > >TobiasKurowski wrote: > >> > >> I want to do some audio filtering using fast convolution. The target is > >> a adjustable/drawable frequency response and linear phase filtering. > > > >I'm guessing that adjustable/drawable means some sort of interactive > >curve construction so that the user can create a frequency response and > >subsequently hear the result. > > that's what I wanted to do. > > >Anyway, to answer your question about > >linear phase. All you need to know is a couple of time<->frequency > >dualities. In order to get a time domain response that is real and > >symmetrical (which is what you have said you want) you need to create > >frequency domain response that is real and symmetrical. > > If I understand proper, the impulse response gets symmetric when the > frequency response is symmetric, that was used to generate the impulse > response?
No it's the making it real in the frequency domain that corresponds to the symmetry in the time domain. The symmetry part in the frequency domains is probably already taken care of. You should be using a FFT/IFFT implementation that assumes you are only interested real signals in the time domain, that means half the spectrum is redundant as far as your needs go. In the half you are interested in the frequency response of a symmetric time response will be only real. ----== Posted via Newsfeeds.Com - Unlimited-Unrestricted-Secure Usenet News==---- http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups ----= East and West-Coast Server Farms - Total Privacy via Encryption =----