Home Theater Forum and Systems banner

1 - 4 of 4 Posts

·
Registered
Joined
·
14 Posts
Discussion Starter #1
I've exported a set of measurements as text so that I can analyze them using Matlab. I'm running into trouble extracting an impulse response from the magnitude and phase data that are exported.

To be sure I had my ducks in a row I first simulated an impulse in Matlab and added a bit of noise. I used an fft to compute a two-sided complex spectrum, extracted a single-sided spectrum, and then calculated magnitude and phase from that. I was able to reverse those steps and start with the magnitude and phase, recreate a two-sided complex spectrum, and use the inverse fourier transform to compute the impulse response. It matched perfectly with the starting point.

If I use the same reversed steps when starting with exported magnitude and phase data from REW, the impulse response is unrecognizable. I can post a graph if it would be useful; it amounts to lots of positive and negative spikes near t=0 and at the end of the time sequence, with a bit of a quiet period in between. Certainly nothing close to an impulse.

Am I missing something about the data exported by REW? Could someone please give me a very brief description of the way REW computes an impulse response from the magnitude and phase data?

Many thanks.

Few
 

·
Premium Member
Joined
·
6,711 Posts
REW calculates the amplitude and phase from the impulse response rather than the other way around. Did you remember to convert the dB amplitudes back to linear scalings? In any event, easiest would be to export the impulse response as WAV (I recommend you use the normalise option) then import that to Matlab using AudioRead.
 

·
Registered
Joined
·
14 Posts
Discussion Starter #3
Thanks very much. Funny, as I was waking up this morning it occurred to me I need to take that log into account!

I'll also check into the impulse export. Does it retain timing info from a loop back timing reference?

Few
 

·
Premium Member
Joined
·
6,711 Posts
A WAV file doesn't really have any concept of where t=0 is. REW places the exported IR peak 1 second into the file.
 
1 - 4 of 4 Posts
Top