JimCzek
JimCzek

Reputation: 335

Most efficient method for measuring the transfer function of a digital filter

I have to determine (actually verify) the transfer function of a digital audio EQ filter bank. (I have been told phase is not important and am working under that assumption, for now.)

I will be using an APx515 audio analyzer, but it appears that I will neither have the ability to inject in an analog signal at the input nor stream in a signal via SPDIF/TOSlink or any other serial link. The input signal will have to be stored in the head unit or brought via a USB memory stick. From that point it will be read into the audio processing stage which will be the EQ filters. Then the signal will be sent to the DAC stage including the amplifier. The analog output stage is already characterized in terms of gain.

I've worked on system identification problems some years ago for inverse identification. We had a rather computationally intensive system that utilized LMS filters and also one that minimized the error which required a matrix inversion.

Since the AP device will give an FFT of the output signal, what I am thinking is that a chirp signal would be the best digital stimulus to use. I know this are rather open ended questions but:

Will the chirp signal suffice for determining the magnitude of the EQ filters' transfer function?

What are the characteristics of the chirp signal that should be used?

A signal duration on the order of seconds is acceptable. I guess to be sure the fft of the chirp signal could have to be examined to make sure it is flat in the frequencies (band) of interest.

Any insight you can provide would be greatly appreciated. Thanks Jim

Upvotes: 1

Views: 464

Answers (2)

JimCzek
JimCzek

Reputation: 335

It turned out the solution was straightforward. The fact that a clean stimulus was used helped.

I used a chirp signal as the stimulus. A logarithmic chirp signal gave better low frequency characterization (e.g. within 0.001 dB agreement with a known DUT) while the linear chirp gave better agreement at the high frequency end (same range of agreement). The DUTs can be classified along the lines of low mid and high frequency devices (20 Hz to 20 kHz total range). The length of the the chirps was adjustable for either 2 seconds or 4 seconds.

The cross spectral density ( Sxy using Welch's, and a Hann window) and the spectral density, Sxx was computed. This gave: H=Sxy/Sxx With the first half of the magnitude values of H used for reporting the results. As I mentioned earlier, phase measurement was not required.

If anyone wants me to, I can post a Scilab simulation of these steps with DUTs simulated by Butterworth and elliptic filters. Thanks.

Upvotes: 0

PicnicTripper
PicnicTripper

Reputation: 305

Sounds interesting. I've only ever used chirp signals when capturing impulse responses for reverb in rooms. In that case I remember that the chirp signal being used was not linear, so I guess the characteristics of the signal depends on what the system is being used for.

It's tough to say, but if you can, definitely bring along a couple of signals. Say, one linear chirp signal, one logarithmic, and then maybe just a regular impulse response with a single one followed by a tail of zeros. Then you should be able to work out the transfer function using z-transforms on your input and output signals. The amplifier at the end of your chain though may make this a bit more difficult, since you'll have to account on the effect that that has on your signal.

You may have already seen it, but Julius O. Smith has a great book on digital filter analysis. This is probably the best book on digital audio filter analysis I've ever come across. It should answer any questions you have.

https://ccrma.stanford.edu/~jos/filters/

Upvotes: 0

Related Questions