Home |
Search |
Today's Posts |
#1
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Hi,
I'm fooling around with a simple audio analyzer program I wrote for my PC. It basically does a sine sweep and measures phase & mag difference between input channels of the sound card and then dumps the measured response to a text file. I'm using the tools Gnuplot and Scilab for the rest of my analysis. My goal is to measure the response of individual drivers to aid the design and optimization of a crossover. I know that most people use 'gated' sampling of impulse/MLS excitation signal. I'm hopping to stay with sine waves and slow sweeps for its brilliant S/N ratio (over 60dB range). Below is link to a plot I made of the drivers I'm testing. http://members.optusnet.com.au/~eseychell/bode.png As I expected at 1 meter microphone distance ,the response is very much effected by room reflections. (room size 10 x 3 x 5 meters) . At 30mm, the response curve is significantly smoother. I'd like to know if this "near field" data can be used to extrapolate the response for 1 meter ? Can I assume that only overall gain will be changed between a measurement at microphone distance of 1 meter vs 30mm ? Adam |
#2
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Adam S" not.valid@nosuchaddress wrote in message u... Hi, I'm fooling around with a simple audio analyzer program I wrote for my PC. It basically does a sine sweep and measures phase & mag difference between input channels of the sound card and then dumps the measured response to a text file. I'm using the tools Gnuplot and Scilab for the rest of my analysis. My goal is to measure the response of individual drivers to aid the design and optimization of a crossover. I know that most people use 'gated' sampling of impulse/MLS excitation signal. I'm hopping to stay with sine waves and slow sweeps for its brilliant S/N ratio (over 60dB range). Below is link to a plot I made of the drivers I'm testing. http://members.optusnet.com.au/~eseychell/bode.png As I expected at 1 meter microphone distance ,the response is very much effected by room reflections. (room size 10 x 3 x 5 meters) . At 30mm, the response curve is significantly smoother. I'd like to know if this "near field" data can be used to extrapolate the response for 1 meter ? Can I assume that only overall gain will be changed between a measurement at microphone distance of 1 meter vs 30mm ? Adam Adam, I read your post with considerable interest, and have these comments. "Close mic'ing" is often done with LF drivers, and I think generally valid, At the lower end of the plot, the cone is pretty much a piston, the wavelengths long, so the pressure generated is pretty much the same anywhere. There is virtually no wavefront, as the wavelength is very large compared to the size of the cone. I wouldn't trust it at the higher end of plot. Wavefront is important, and you're only sampling one part of it. You'd expect a big diffraction peak, unless the inner part of the cone is starting to operate independently, and if that's the case, all bets are off as to the wavefront that it's creating. That appears to be the case with the quite-smooth on-axis response of your driver in the 1-4 KHz range. To increase your confidence there, you might want to run several close-mic'ed plots with the mic moved to various places near the center of the woofer and see what kind of correlation there is. Probably a better test would be to do this part outdoors, not close-mic'ed, with the woofer aimed upwards, and away from anything reflective. You'll get all kinds of comb effects in the 100-500 Hz range from ground reflection, and you might want to position the cabinet the same distance as it is from the wall when it's in use indoors to get an idea of the back-wall reflection effects there -- the're usually not insignificant, though often overlooked. There won't be any significant diffraction in the 1-4 KHz range to go around to the back and bounce back, so the results in that range should be quite valid. You can still move the mic around and look for variances. You'll also want to know generally how much the off-axis response sags as the frequency goes up, and look at the crossover frequency to see if that is of concern. In any event, you'll also want in-room, not close-mic'ed, both-woofer measurements. There is back wall reflection comb-filter effects that I mentioned earlier that can be substantial, at least the first null. There is "coupling" where the pressure from one woofer actually changes the radiation resistance (favorably) seen by the other woofer. And and there is room effect at very low frequencies where the long wavelengths make the room essentially a pressure container, also causing a rise in output. I'm not at all sure how much I'd trust close mic'ed tweeter measurements, but the outdoor test can be done there quite readily. Also, do some off-axis plots too. I'd love to try your program. My email address is at my web site, www.smokeylake.com/excel at the bottom of the page, if you'd be willing. -- Regards from Virginia Beach, Earl Kiosterud |
#3
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Hi Adam:
One approach is to calculate the pattern in the near field to determine how it varies with distance. If you have Matlab, I can send you a program to do this. The program is described he http://www.silcom.com/~aludwig/Physi..._multipole.htm an example of a near-field amplitude plot is shown he http://www.silcom.com/~aludwig/Physi...near_field.gif Regards, Art Ludwig the response curve is significantly smoother. I'd like to know if this "near field" data can be used to extrapolate the response for 1 meter ? Can I assume that only overall gain will be changed between a measurement at microphone distance of 1 meter vs 30mm ? Adam |
#4
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Earl Kiosterud wrote:
"Adam S" not.valid@nosuchaddress wrote in message u... Hi, I'm fooling around with a simple audio analyzer program I wrote for my PC. It basically does a sine sweep and measures phase & mag difference between input channels of the sound card and then dumps the measured response to a text file. I'm using the tools Gnuplot and Scilab for the rest of my analysis. My goal is to measure the response of individual drivers to aid the design and optimization of a crossover. I know that most people use 'gated' sampling of impulse/MLS excitation signal. I'm hopping to stay with sine waves and slow sweeps for its brilliant S/N ratio (over 60dB range). Below is link to a plot I made of the drivers I'm testing. http://members.optusnet.com.au/~eseychell/bode.png As I expected at 1 meter microphone distance ,the response is very much effected by room reflections. (room size 10 x 3 x 5 meters) . At 30mm, the response curve is significantly smoother. I'd like to know if this "near field" data can be used to extrapolate the response for 1 meter ? Can I assume that only overall gain will be changed between a measurement at microphone distance of 1 meter vs 30mm ? Adam Adam, I read your post with considerable interest, and have these comments. "Close mic'ing" is often done with LF drivers, and I think generally valid, At the lower end of the plot, the cone is pretty much a piston, the wavelengths long, so the pressure generated is pretty much the same anywhere. There is virtually no wavefront, as the wavelength is very large compared to the size of the cone. I wouldn't trust it at the higher end of plot. Wavefront is important, and you're only sampling one part of it. You'd expect a big diffraction peak, unless the inner part of the cone is starting to operate independently, and if that's the case, all bets are off as to the wavefront that it's creating. That appears to be the case with the quite-smooth on-axis response of your driver in the 1-4 KHz range. To increase your confidence there, you might want to run several close-mic'ed plots with the mic moved to various places near the center of the woofer and see what kind of correlation there is. Probably a better test would be to do this part outdoors, not close-mic'ed, with the woofer aimed upwards, and away from anything reflective. You'll get all kinds of comb effects in the 100-500 Hz range from ground reflection, and you might want to position the cabinet the same distance as it is from the wall when it's in use indoors to get an idea of the back-wall reflection effects there -- the're usually not insignificant, though often overlooked. There won't be any significant diffraction in the 1-4 KHz range to go around to the back and bounce back, so the results in that range should be quite valid. You can still move the mic around and look for variances. You'll also want to know generally how much the off-axis response sags as the frequency goes up, and look at the crossover frequency to see if that is of concern. In any event, you'll also want in-room, not close-mic'ed, both-woofer measurements. There is back wall reflection comb-filter effects that I mentioned earlier that can be substantial, at least the first null. There is "coupling" where the pressure from one woofer actually changes the radiation resistance (favorably) seen by the other woofer. And and there is room effect at very low frequencies where the long wavelengths make the room essentially a pressure container, also causing a rise in output. I'm not at all sure how much I'd trust close mic'ed tweeter measurements, but the outdoor test can be done there quite readily. Also, do some off-axis plots too. I'd love to try your program. My email address is at my web site, www.smokeylake.com/excel at the bottom of the page, if you'd be willing. Thanks Earl for showing an interest in my project and your informative reply. Its nice to hear that I'm not completely going off track with this idea of near field measurement across full audio range for all drivers in the system. I will definitely do as you suggested and try various positions on a parallel plane a short distance from the woofer and tweeter. You have given me plenty of ideas to experiment with. I'm not sure what you mean about the "diffraction peak". If your referring to diffraction around the speaker box, the isn't this energy normally not contributing in standard anechoic measurement techniques ? I am still setting up my homemade measurement jig and plan to buy some long lengths of cable to run the measurements outdoors. The beauty of sine sweep is its inherent selectivity to the signal source. The bandwidth can be low as few hertz or less if your prepared to wait longer for the sweep, about 1 minute or so. This allows outdoor measurements with minimal affect from ambient noise. As you also mentioned, outdoor measurement will confirm any differences between near field and far field plots. To avoid ground reflections, will it help laying the speaker horizontal facing up, and raised 1 or 2 meters above the ground covered with tall grass ? I basically wrote this little program because I couldn't find anything that would do arbitrary sine sweep vector plots using the PC soundcard. It actually started it few years back, but never got anywhere. Since then I've had more practice at C++ and had some drivers gathering dust ready to be put into speaker boxes I built some time ago. I should warn you its quite in its early stages and only has command line interface. This suits me as it integrates well with most of the other scripting and/or command line based software tools I use. A GUI might be useful but I don't have time to devote to aesthetics. It first accurately calibrates soundcard latency, then monitors input levels to allow pre-adjustment of the soundcard volume controls before commencing the sweep(s). I'll be happy to clean it up and make it GNU free software, thats assuming of course if anyone else out there would find such a tool useful. Currently only raw results are produced. Math tools like Scilab, Octave or Mathcad can easily read the resulting text file for further processing. Adam |
#5
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Earl Kiosterud" wrote in message news:vLPii.7935$7k7.2347@trnddc01... "Close mic'ing" is often done with LF drivers, and I think generally valid, At the lower end of the plot, the cone is pretty much a piston, the wavelengths long, so the pressure generated is pretty much the same anywhere. snip In any event, you'll also want in-room, not close-mic'ed, both-woofer measurements. There is back wall reflection comb-filter effects that I mentioned earlier that can be substantial, at least the first null. There is "coupling" where the pressure from one woofer actually changes the radiation resistance (favorably) seen by the other woofer. And and there is room effect at very low frequencies where the long wavelengths make the room essentially a pressure container, also causing a rise in output. And something you failed to mention is the problems involved with measuring vented enclosures that way. MrT. |
#6
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Mr.T wrote:
"Earl Kiosterud" wrote in message news:vLPii.7935$7k7.2347@trnddc01... "Close mic'ing" is often done with LF drivers, and I think generally valid, At the lower end of the plot, the cone is pretty much a piston, the wavelengths long, so the pressure generated is pretty much the same anywhere. And something you failed to mention is the problems involved with measuring vented enclosures that way. Its fortunate that the low frequencies can be modeled reasonably accurately mitigating the need any measurements. I'm interested in woofer and tweeter interaction and so 500 to 10kHz is all I need to consider. Adam Seychell |
#7
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Those simulations look impressive. Unfortunately I do not have Matlab to
run this programs. I'm more curious in theory of the simulation but the maths behind it brings back horrid memories of my audio engineering classes. Art Ludwig wrote: Hi Adam: One approach is to calculate the pattern in the near field to determine how it varies with distance. If you have Matlab, I can send you a program to do this. The program is described he http://www.silcom.com/~aludwig/Physi..._multipole.htm an example of a near-field amplitude plot is shown he http://www.silcom.com/~aludwig/Physi...near_field.gif Regards, Art Ludwig the response curve is significantly smoother. I'd like to know if this "near field" data can be used to extrapolate the response for 1 meter ? Can I assume that only overall gain will be changed between a measurement at microphone distance of 1 meter vs 30mm ? Adam |
#8
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Mr.T" MrT@home wrote in message u... "Earl Kiosterud" wrote in message news:vLPii.7935$7k7.2347@trnddc01... "Close mic'ing" is often done with LF drivers, and I think generally valid, At the lower end of the plot, the cone is pretty much a piston, the wavelengths long, so the pressure generated is pretty much the same anywhere. snip In any event, you'll also want in-room, not close-mic'ed, both-woofer measurements. There is back wall reflection comb-filter effects that I mentioned earlier that can be substantial, at least the first null. There is "coupling" where the pressure from one woofer actually changes the radiation resistance (favorably) seen by the other woofer. And and there is room effect at very low frequencies where the long wavelengths make the room essentially a pressure container, also causing a rise in output. And something you failed to mention is the problems involved with measuring vented enclosures that way. MrT. Mr T, Yeah. I thought about that later. I think you just combine the results, weighing the areas of the cone and the port. Adam didn't say if it's a tuned cabinet, and his sweep didn't go below 100 Hz. -- Regards from Virginia Beach, Earl Kiosterud www.smokeylake.com ----------------------------------------------------------------------- |
#9
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Adam S" not.valid@nosuchaddress wrote in message u... Earl Kiosterud wrote: "Adam S" not.valid@nosuchaddress wrote in message u... Hi, I'm fooling around with a simple audio analyzer program I wrote for my PC. It basically does a sine sweep and measures phase & mag difference between input channels of the sound card and then dumps the measured response to a text file. I'm using the tools Gnuplot and Scilab for the rest of my analysis. My goal is to measure the response of individual drivers to aid the design and optimization of a crossover. I know that most people use 'gated' sampling of impulse/MLS excitation signal. I'm hopping to stay with sine waves and slow sweeps for its brilliant S/N ratio (over 60dB range). Below is link to a plot I made of the drivers I'm testing. http://members.optusnet.com.au/~eseychell/bode.png As I expected at 1 meter microphone distance ,the response is very much effected by room reflections. (room size 10 x 3 x 5 meters) . At 30mm, the response curve is significantly smoother. I'd like to know if this "near field" data can be used to extrapolate the response for 1 meter ? Can I assume that only overall gain will be changed between a measurement at microphone distance of 1 meter vs 30mm ? Adam Adam, I read your post with considerable interest, and have these comments. "Close mic'ing" is often done with LF drivers, and I think generally valid, At the lower end of the plot, the cone is pretty much a piston, the wavelengths long, so the pressure generated is pretty much the same anywhere. There is virtually no wavefront, as the wavelength is very large compared to the size of the cone. I wouldn't trust it at the higher end of plot. Wavefront is important, and you're only sampling one part of it. You'd expect a big diffraction peak, unless the inner part of the cone is starting to operate independently, and if that's the case, all bets are off as to the wavefront that it's creating. That appears to be the case with the quite-smooth on-axis response of your driver in the 1-4 KHz range. To increase your confidence there, you might want to run several close-mic'ed plots with the mic moved to various places near the center of the woofer and see what kind of correlation there is. Probably a better test would be to do this part outdoors, not close-mic'ed, with the woofer aimed upwards, and away from anything reflective. You'll get all kinds of comb effects in the 100-500 Hz range from ground reflection, and you might want to position the cabinet the same distance as it is from the wall when it's in use indoors to get an idea of the back-wall reflection effects there -- the're usually not insignificant, though often overlooked. There won't be any significant diffraction in the 1-4 KHz range to go around to the back and bounce back, so the results in that range should be quite valid. You can still move the mic around and look for variances. You'll also want to know generally how much the off-axis response sags as the frequency goes up, and look at the crossover frequency to see if that is of concern. In any event, you'll also want in-room, not close-mic'ed, both-woofer measurements. There is back wall reflection comb-filter effects that I mentioned earlier that can be substantial, at least the first null. There is "coupling" where the pressure from one woofer actually changes the radiation resistance (favorably) seen by the other woofer. And and there is room effect at very low frequencies where the long wavelengths make the room essentially a pressure container, also causing a rise in output. I'm not at all sure how much I'd trust close mic'ed tweeter measurements, but the outdoor test can be done there quite readily. Also, do some off-axis plots too. I'd love to try your program. My email address is at my web site, www.smokeylake.com/excel at the bottom of the page, if you'd be willing. Thanks Earl for showing an interest in my project and your informative reply. Its nice to hear that I'm not completely going off track with this idea of near field measurement across full audio range for all drivers in the system. I will definitely do as you suggested and try various positions on a parallel plane a short distance from the woofer and tweeter. You have given me plenty of ideas to experiment with. I'm not sure what you mean about the "diffraction peak". If your referring to diffraction around the speaker box, the isn't this energy normally not contributing in standard anechoic measurement techniques ? I am still setting up my homemade measurement jig and plan to buy some long lengths of cable to run the measurements outdoors. The beauty of sine sweep is its inherent selectivity to the signal source. The bandwidth can be low as few hertz or less if your prepared to wait longer for the sweep, about 1 minute or so. This allows outdoor measurements with minimal affect from ambient noise. As you also mentioned, outdoor measurement will confirm any differences between near field and far field plots. To avoid ground reflections, will it help laying the speaker horizontal facing up, and raised 1 or 2 meters above the ground covered with tall grass ? I basically wrote this little program because I couldn't find anything that would do arbitrary sine sweep vector plots using the PC soundcard. It actually started it few years back, but never got anywhere. Since then I've had more practice at C++ and had some drivers gathering dust ready to be put into speaker boxes I built some time ago. I should warn you its quite in its early stages and only has command line interface. This suits me as it integrates well with most of the other scripting and/or command line based software tools I use. A GUI might be useful but I don't have time to devote to aesthetics. It first accurately calibrates soundcard latency, then monitors input levels to allow pre-adjustment of the soundcard volume controls before commencing the sweep(s). I'll be happy to clean it up and make it GNU free software, thats assuming of course if anyone else out there would find such a tool useful. Currently only raw results are produced. Math tools like Scilab, Octave or Mathcad can easily read the resulting text file for further processing. Adam Adam, With the speaker on the ground facing up, there will be sound bouncing off the ground and back upwards again. I visualize it as a virtual speaker, the same distance under the ground as the speaker is above ground. Moving the speaker up does of course make that virtual speaker farther away, reducing the comb filter effect you get, as well as moving the peaks and dips downward in frequency, the first null being the frequency whose half wavelength is equal to the effective distance from the virtual speaker to the real speaker. I think you'd have to get it pretty high off the ground before the effect could be disregarded. I wouldn't expect grass to absorb much of these relatively long wavelengths, but I'm not real sure. More important, though, are the back-wall nulls and lobes you get when the speaker is indoors -- I've always believed that anechoic tests are of use for the speaker itself, but when the cabinet will be near a back wall, it's a whole new ball game, and that can't be discounted -- that's the way it's gonna sound. Most importantly, I think the most meaningful results of the outdoor test will be for the upper range of the woofer, which won't be affected by this ground reflection at all. Blending this with the close-mic'ed low-end plot should be meaningful. I'm not confident about close-mic'ed results at the high end, no matter how it's performed. Don't forget the off-axis measurements for the upper end of the woofer. Off-axis response is often a pretty big deal, forcing you to use a lower crossover frequency and then keeping you up nights worrying that you'll blow out the tweeters! I think that would be even more difficult to predict from close-mic'ed tests. Keep in mind that overall flatness isn't the ultimate goal, unless you won't be using an equalizer for the final installation. It's those peaks and steep slopes in the response that you want to keep out. The ear hates those. Well, not all ears -- some actually LIKE it. WOuld running your program on a laptop be a way to not have to worry about cables to the outdoors? I think even the cheap soundcards on them are quite adequate, as long as non of those stupid audio effects are turned on. I had quite a run around some years ago with a SoundBlaster sound card in this respect. Unfortunately, the cheap soundcards, I think, don't let you set a smaller buffer, so the latency is substantial, slowing down the test, I'm sure. I have a Delta sound card in my system that can be set to 64 bytes, for 1.5 ms latency at 44.1 KHz. I'm a believer in swept-sine tests too. Back in the 80's, I built half of a piece of hardware to do just that. It was a computer-controlled sine wave oscillator, a state-variable loop that produced a good sine over two decades. Did a good job. It could change frequency on a dime -- no ringing or instabilities of any kind. It was attached to an ISA card, and I Ran it with a BASIC program. I never got around to making the other half, the part that would take in the test mic signal and log the results. Sound cards came along and I dropped the project, but never did get a swept-sine test capability. That's why I'm interested in your program. Regards from Virginia Beach, Earl Kiosterud |
#10
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Earl Kiosterud wrote: Adam, With the speaker on the ground facing up, there will be sound bouncing off the ground and back upwards again. I visualize it as a virtual speaker, the same distance under the ground as the speaker is above ground. Moving the speaker up does of course make that virtual speaker farther away, reducing the comb filter effect you get, as well as moving the peaks and dips downward in frequency, the first null being the frequency whose half wavelength is equal to the effective distance from the virtual speaker to the real speaker. I think you'd have to get it pretty high off the ground before the effect could be disregarded. I wouldn't expect grass to absorb much of these relatively long wavelengths, but I'm not real sure. More important, though, are the back-wall nulls and lobes you get when the speaker is indoors -- I've always believed that anechoic tests are of use for the speaker itself, but when the cabinet will be near a back wall, it's a whole new ball game, and that can't be discounted -- that's the way it's gonna sound. Most importantly, I think the most meaningful results of the outdoor test will be for the upper range of the woofer, which won't be affected by this ground reflection at all. Blending this with the close-mic'ed low-end plot should be meaningful. I'm not confident about close-mic'ed results at the high end, no matter how it's performed. Don't forget the off-axis measurements for the upper end of the woofer. Off-axis response is often a pretty big deal, forcing you to use a lower crossover frequency and then keeping you up nights worrying that you'll blow out the tweeters! I think that would be even more difficult to predict from close-mic'ed tests. Keep in mind that overall flatness isn't the ultimate goal, unless you won't be using an equalizer for the final installation. It's those peaks and steep slopes in the response that you want to keep out. The ear hates those. Well, not all ears -- some actually LIKE it. WOuld running your program on a laptop be a way to not have to worry about cables to the outdoors? I think even the cheap soundcards on them are quite adequate, as long as non of those stupid audio effects are turned on. I had quite a run around some years ago with a SoundBlaster sound card in this respect. Unfortunately, the cheap soundcards, I think, don't let you set a smaller buffer, so the latency is substantial, slowing down the test, I'm sure. I have a Delta sound card in my system that can be set to 64 bytes, for 1.5 ms latency at 44.1 KHz. I'm a believer in swept-sine tests too. Back in the 80's, I built half of a piece of hardware to do just that. It was a computer-controlled sine wave oscillator, a state-variable loop that produced a good sine over two decades. Did a good job. It could change frequency on a dime -- no ringing or instabilities of any kind. It was attached to an ISA card, and I Ran it with a BASIC program. I never got around to making the other half, the part that would take in the test mic signal and log the results. Sound cards came along and I dropped the project, but never did get a swept-sine test capability. That's why I'm interested in your program. Regards from Virginia Beach, Earl Kiosterud Thanks for the insight to the ground reflection effect. I see there is no escape unless your hanging from a crane hook. I haven't yet started to worry about the low frequencies of the woofer and to be honest, the box isn't even tuned. At the moment I am concentrating on getting my software up and running and setting up the amplifier jig I built for it. I'm impressed with your earlier effort of PC controlled sine sweeper. But things have changed a lot sine 80's and a soundcard can replace all of that hardware. The specs for even a 'low end' modern soundcard are very adequate these days, 24bit 96kHz 90dB+ S/N are common place. The latency is a problem for sine sweep because the incoming signal is lagging in frequency shift from the digital source generated in software. My program gets around it by performing a latency test to a precision of 1 or 2 sample periods (i.e +-20uS at 96kHz). The incoming L+R signals (normally from microphone and speaker terminals) therefore have precise coherence to the sine/cosine generator. Its then just a matter of quadrature mixing followed by low pass filtering of the products to remove the high frequency component. You just take the phase and magnitude between the two L+R channels. take two captured incoming signals Ax and Bx. then multiply with digital generated quadrature signal. Are = cos(w*t) * Ax Aim = sin(w*t) * Ax Bre = cos(w*t) * Bx Bim = sin(w*t) * Bx low pass filter Are, Aim, Bre, Bim. complex ratio H, H =((Are*Bre + Aim*Bim) + i(Aim*Bre - Are*Bim)) / (Bre^2 + Bim^2) phase = arg(H) magnitude = abs(H) A soundcard with 64 sample size buffer is damn small. I cannot get Windows Direct X to go below 4000 samples at 96kHz or 41mS on my Realtek Audio device, but what can I expect for on-board sound. however there is an extra delay for real time full duplexing applications. I found DirectSound actually lags at least 2 buffers behind and so the application sees about 3 times buffer periods behind. Again this isn't a problem with sweeping if the lag period is predetermined. Even a 1 second latency showed to make made no difference. Soon as I get my program a little more presentable I'll send you a copy. Let me know what features you like, since I plan to make if freely available when I get around to it. I'm sure to have a questions or two on driver measurement later. Mean while I did that plot of microphone at different positions around the woofer. See http://members.optusnet.com.au/~eseychell/bode2.png You right that higher frequencies 2kHz do show large shift in the spectrum. Adam |
#11
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Adam S" not.valid@nosuchaddress wrote in message u... Its fortunate that the low frequencies can be modeled reasonably accurately mitigating the need any measurements. Yes, if you prefer not to know any deviations from the predicted response. MrT. |
#12
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Adam S" not.valid@nosuchaddress wrote in message
u... Thanks for the insight to the ground reflection effect. I see there is no escape unless your hanging from a crane hook. I haven't yet started to worry about the low frequencies of the woofer and to be honest, the box isn't even tuned. At the moment I am concentrating on getting my software up and running and setting up the amplifier jig I built for it. I'm impressed with your earlier effort of PC controlled sine sweeper. But things have changed a lot sine 80's and a soundcard can replace all of that hardware. The specs for even a 'low end' modern soundcard are very adequate these days, 24bit 96kHz 90dB+ S/N are common place. The latency is a problem for sine sweep because the incoming signal is lagging in frequency shift from the digital source generated in software. My program gets around it by performing a latency test to a precision of 1 or 2 sample periods (i.e +-20uS at 96kHz). The incoming L+R signals (normally from microphone and speaker terminals) therefore have precise coherence to the sine/cosine generator. Its then just a matter of quadrature mixing followed by low pass filtering of the products to remove the high frequency component. You just take the phase and magnitude between the two L+R channels. take two captured incoming signals Ax and Bx. then multiply with digital generated quadrature signal. Are = cos(w*t) * Ax Aim = sin(w*t) * Ax Bre = cos(w*t) * Bx Bim = sin(w*t) * Bx low pass filter Are, Aim, Bre, Bim. complex ratio H, H =((Are*Bre + Aim*Bim) + i(Aim*Bre - Are*Bim)) / (Bre^2 + Bim^2) phase = arg(H) magnitude = abs(H) A soundcard with 64 sample size buffer is damn small. I cannot get Windows Direct X to go below 4000 samples at 96kHz or 41mS on my Realtek Audio device, but what can I expect for on-board sound. however there is an extra delay for real time full duplexing applications. I found DirectSound actually lags at least 2 buffers behind and so the application sees about 3 times buffer periods behind. Again this isn't a problem with sweeping if the lag period is predetermined. Even a 1 second latency showed to make made no difference. Soon as I get my program a little more presentable I'll send you a copy. Let me know what features you like, since I plan to make if freely available when I get around to it. I'm sure to have a questions or two on driver measurement later. Mean while I did that plot of microphone at different positions around the woofer. See http://members.optusnet.com.au/~eseychell/bode2.png You right that higher frequencies 2kHz do show large shift in the spectrum. Adam Adam, Slick. I see now that the soundcard latency doesn't slow down this continuous process. This process gives phase as well as amplitude data. Excellent. What about latency between the A and B inputs? Is that why you want to do only close-mic'ing, to keep that minimized? Or can the program handle that OK? I couldn't tell, because I don't know how you're handling t and f. I think the close-mic'ing will be problematic for the upper range of the woofer, and also for the tweeter. And you will definitely want off-axis plots of both, which will be difficult to get from close mic'ing. I think if you do off-axis measurements in the upper range of the woofer, not close mic'ed, you'll get very different results from those you did at the front plane of the woofer. That information is important, one reason being that as F goes up the tweeter needs to be brought into play before the woofer's off-axis level has dropped much. And the general output at various directions and frequencies is important. I think the cos(w*t) * Ax expression yields a sin-squared function, consisting of sum and difference frequency components, 2f and 0 Hz in this case. You do the low-pass filtering to remove the 2f component, leaving the (nearly) 0 Hz component as the vector magnitude. It that correct? Some thoughts: Although low-frequency performance can indeed be modeled, it depends on having driver parameters and box data. This data isn't always available or reliable (although driver manufacturers NEVER lie, and production tolerances are VERY tight. We know that!!!). I'd want to do the low part of the woofer, all the way down to where it just gives up. Probably close mic'ed. Proof of performance! Also, it's useful to have an additional woofer-only sweep at high power for vented enclosures, which can start to choke up at high power -- the velocity in the port gets too great, and the box starts acting more like a sealed box. This sweep must not extend into the range of the tweeter, or one could read by its light until it burns out! It would be useful to plot this along with the other woofer plots. It appears that amplitude changes at the speaker terminals (from the amplifier) as the frequency changes will affect the result ( abs(H) ). Is that correct? Most amplifiers are pretty darn flat, but changes in the output impedance at high frequencies in combination with some tweeters can produce noteworthy deviations. It would be useful in some plots exclude it (adjust for it) when the constant-voltage performance of only the speaker is desired, and in others, to include the amplifier, where it's known to be the amplifier that will be used. If one was, for example, sweeping the entire system, speakers in place, for a final check of all the components of the system, one would not want the amplifier and other components excluded from the result. One thing about ground reflections is that unless you're on a hard reflecting surface, you don't know how much is being reflected, and how much is soaking in. As for my 1.5 ms soundcard, I think audio apps talk directly to the driver. My 4-year-old IBM 1.8 GHz NetVista can run an audio production app, with it's handling of both the soundcard input (being recorded), and it's mixer mixing a dozen or so audio tracks with several plugins here and there (equalizers, compressors, etc.) and keep stuffing that little playback buffer 667 times/second. It doesn't complain. I don't really run the buffer that small in use -- no real need. You mentioned Windows, but also mentioned Linux. Which OS are you developing it for? Really looking forward to getting a copy of your program. -- Regards from Virginia Beach, Earl Kiosterud www.smokeylake.com |
#13
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Earl Kiosterud wrote:
"Adam S" not.valid@nosuchaddress wrote in message u... Thanks for the insight to the ground reflection effect. I see there is no escape unless your hanging from a crane hook. I haven't yet started to worry about the low frequencies of the woofer and to be honest, the box isn't even tuned. At the moment I am concentrating on getting my software up and running and setting up the amplifier jig I built for it. I'm impressed with your earlier effort of PC controlled sine sweeper. But things have changed a lot sine 80's and a soundcard can replace all of that hardware. The specs for even a 'low end' modern soundcard are very adequate these days, 24bit 96kHz 90dB+ S/N are common place. The latency is a problem for sine sweep because the incoming signal is lagging in frequency shift from the digital source generated in software. My program gets around it by performing a latency test to a precision of 1 or 2 sample periods (i.e +-20uS at 96kHz). The incoming L+R signals (normally from microphone and speaker terminals) therefore have precise coherence to the sine/cosine generator. Its then just a matter of quadrature mixing followed by low pass filtering of the products to remove the high frequency component. You just take the phase and magnitude between the two L+R channels. take two captured incoming signals Ax and Bx. then multiply with digital generated quadrature signal. Are = cos(w*t) * Ax Aim = sin(w*t) * Ax Bre = cos(w*t) * Bx Bim = sin(w*t) * Bx low pass filter Are, Aim, Bre, Bim. complex ratio H, H =((Are*Bre + Aim*Bim) + i(Aim*Bre - Are*Bim)) / (Bre^2 + Bim^2) phase = arg(H) magnitude = abs(H) A soundcard with 64 sample size buffer is damn small. I cannot get Windows Direct X to go below 4000 samples at 96kHz or 41mS on my Realtek Audio device, but what can I expect for on-board sound. however there is an extra delay for real time full duplexing applications. I found DirectSound actually lags at least 2 buffers behind and so the application sees about 3 times buffer periods behind. Again this isn't a problem with sweeping if the lag period is predetermined. Even a 1 second latency showed to make made no difference. Soon as I get my program a little more presentable I'll send you a copy. Let me know what features you like, since I plan to make if freely available when I get around to it. I'm sure to have a questions or two on driver measurement later. Mean while I did that plot of microphone at different positions around the woofer. See http://members.optusnet.com.au/~eseychell/bode2.png You right that higher frequencies 2kHz do show large shift in the spectrum. Adam Adam, Slick. I see now that the soundcard latency doesn't slow down this continuous process. This process gives phase as well as amplitude data. Excellent. What about latency between the A and B inputs? Is that why you want to do only close-mic'ing, to keep that minimized? Or can the program handle that OK? I couldn't tell, because I don't know how you're handling t and f. I think the close-mic'ing will be problematic for the upper range of the woofer, and also for the tweeter. And you will definitely want off-axis plots of both, which will be difficult to get from close mic'ing. I think if you do off-axis measurements in the upper range of the woofer, not close mic'ed, you'll get very different results from those you did at the front plane of the woofer. That information is important, one reason being that as F goes up the tweeter needs to be brought into play before the woofer's off-axis level has dropped much. And the general output at various directions and frequencies is important. I think the cos(w*t) * Ax expression yields a sin-squared function, consisting of sum and difference frequency components, 2f and 0 Hz in this case. You do the low-pass filtering to remove the 2f component, leaving the (nearly) 0 Hz component as the vector magnitude. It that correct? Some thoughts: Although low-frequency performance can indeed be modeled, it depends on having driver parameters and box data. This data isn't always available or reliable (although driver manufacturers NEVER lie, and production tolerances are VERY tight. We know that!!!). I'd want to do the low part of the woofer, all the way down to where it just gives up. Probably close mic'ed. Proof of performance! Also, it's useful to have an additional woofer-only sweep at high power for vented enclosures, which can start to choke up at high power -- the velocity in the port gets too great, and the box starts acting more like a sealed box. This sweep must not extend into the range of the tweeter, or one could read by its light until it burns out! It would be useful to plot this along with the other woofer plots. It appears that amplitude changes at the speaker terminals (from the amplifier) as the frequency changes will affect the result ( abs(H) ). Is that correct? Most amplifiers are pretty darn flat, but changes in the output impedance at high frequencies in combination with some tweeters can produce noteworthy deviations. It would be useful in some plots exclude it (adjust for it) when the constant-voltage performance of only the speaker is desired, and in others, to include the amplifier, where it's known to be the amplifier that will be used. If one was, for example, sweeping the entire system, speakers in place, for a final check of all the components of the system, one would not want the amplifier and other components excluded from the result. One thing about ground reflections is that unless you're on a hard reflecting surface, you don't know how much is being reflected, and how much is soaking in. As for my 1.5 ms soundcard, I think audio apps talk directly to the driver. My 4-year-old IBM 1.8 GHz NetVista can run an audio production app, with it's handling of both the soundcard input (being recorded), and it's mixer mixing a dozen or so audio tracks with several plugins here and there (equalizers, compressors, etc.) and keep stuffing that little playback buffer 667 times/second. It doesn't complain. I don't really run the buffer that small in use -- no real need. You mentioned Windows, but also mentioned Linux. Which OS are you developing it for? Really looking forward to getting a copy of your program. The latency due to sound waves traveling to the microphone isn't compensated for, although it wouldn't be difficult to add. I'd just have to measure individual latency measurements for channels A and B. 1 meter corresponds to 3 millisecond delay. If sweeping at rate of 1kHz/second then 1000*0.003 = 3Hz offset. I haven't considered this! At the moment I just measure latency for the channel connecting to the speaker terminals. My program merely takes complex ratio between two input channels A/B. If you want to include the power amplifier as part of the overall loop, then you'd just connect channel A directly the amplifier input and channel B to the microphone preamplifier output. I made a general purpose 2 channel differential input pre-amplifier for my soundcard. It has switchable gains (-20dB,-10dB,0dB,+10dB,+20dB,+30dB,+40dB or +50dB) which allows me to measure across speaker terminals, line levels or microphone levels. To do an impedance plot, I just have to connect channel A to a driver, and channel B across a known resistor in series, 8.2 ohm for example. If you wanted to calibrate the soundcard itself , then a simple loop back could achieve this. It'll be interesting to try. There would also be a certain amount of cross talk between the soundcard outputs to inputs. I guess this could be measured by doing a sweep with shorted inputs. I had the idea of using Scilab to manipulate all the different H(f) plots that I generated. I think there are already audio applications out there that can read in response plots and perform analysis. There is an infinite number of things to do with the frequency measurements so I figured just get the data accurately measured with a general purpose tool and worry about what to do with the results later. You are correct about the multiplication of two sine waves. The 2f component is removed by low pass filtering. If any 2f component feeds through then it shows up as oscillating value of H (I think form memory). There is a big advantage taking complex ratios of two input channels. As you know, if the signal source is not exactly equal to the quadrature signal being multiplied then there is no longer a DC component, but a (f1-f2) difference. When you later complex divide two channels each having a (f1-f2) component then the (f1-f2) disappears and your back to DC value of H. It works out that the cutoff frequency of the low pass filter is actually 1/2 the bandwidth of the sweep measurement. For example a 1Hz filter cutoff is used with a 10kHz signal source, then the input is effectively bandpassed with upper and lower frequencies of 10001.0Hz and 9999.0Hz respectively. In theory you could measure down to millihertz resolutions. I have written the program under windows, but I use the cygwin environment. Since it uses DirectX for the soundcard API it wont compile under Linux. It has been written with the intention of someday being ported to Linux using the ALSA API. Hopefully in a few more days I'll be ready to send you the program. Adam |
#14
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Adam S" not.valid@nosuchaddress wrote in message
u... Earl Kiosterud wrote: The latency due to sound waves traveling to the microphone isn't compensated for, although it wouldn't be difficult to add. I'd just have to measure individual latency measurements for channels A and B. 1 meter corresponds to 3 millisecond delay. If sweeping at rate of 1kHz/second then 1000*0.003 = 3Hz offset. I haven't considered this! At the moment I just measure latency for the channel connecting to the speaker terminals. My program merely takes complex ratio between two input channels A/B. If you want to include the power amplifier as part of the overall loop, then you'd just connect channel A directly the amplifier input and channel B to the microphone preamplifier output. I made a general purpose 2 channel differential input pre-amplifier for my soundcard. It has switchable gains (-20dB,-10dB,0dB,+10dB,+20dB,+30dB,+40dB or +50dB) which allows me to measure across speaker terminals, line levels or microphone levels. To do an impedance plot, I just have to connect channel A to a driver, and channel B across a known resistor in series, 8.2 ohm for example. If you wanted to calibrate the soundcard itself , then a simple loop back could achieve this. It'll be interesting to try. There would also be a certain amount of cross talk between the soundcard outputs to inputs. I guess this could be measured by doing a sweep with shorted inputs. I had the idea of using Scilab to manipulate all the different H(f) plots that I generated. I think there are already audio applications out there that can read in response plots and perform analysis. There is an infinite number of things to do with the frequency measurements so I figured just get the data accurately measured with a general purpose tool and worry about what to do with the results later. You are correct about the multiplication of two sine waves. The 2f component is removed by low pass filtering. If any 2f component feeds through then it shows up as oscillating value of H (I think form memory). There is a big advantage taking complex ratios of two input channels. As you know, if the signal source is not exactly equal to the quadrature signal being multiplied then there is no longer a DC component, but a (f1-f2) difference. When you later complex divide two channels each having a (f1-f2) component then the (f1-f2) disappears and your back to DC value of H. It works out that the cutoff frequency of the low pass filter is actually 1/2 the bandwidth of the sweep measurement. For example a 1Hz filter cutoff is used with a 10kHz signal source, then the input is effectively bandpassed with upper and lower frequencies of 10001.0Hz and 9999.0Hz respectively. In theory you could measure down to millihertz resolutions. I have written the program under windows, but I use the cygwin environment. Since it uses DirectX for the soundcard API it wont compile under Linux. It has been written with the intention of someday being ported to Linux using the ALSA API. Hopefully in a few more days I'll be ready to send you the program. Adam Adam, Well, doh! It takes the RATIO. I think I've been standing too close to the forest. So the amplifier is indeed out of the loop, so to speak, when channel A is connected to the amplifier output. It's interesting that it's in the loop, but out of the loop. And irregularities in phase or amplitude introduced by the amplifier won't be seen in the results. Cool. And why the hell else would you have two inputs anyway? OK. I'm awake now. You said "if the signal source is not exactly equal to the quadrature signal being multiplied then there is no longer a DC component, but a (f1-f2) difference." I presume you mean the signal source is different in frequency from the quadrature signal. That would be the result of an error in the latency correction -- I can't think of any other reason for the production of f1-f2. You also said that this f1-f2 component didn't show up in the output. But it WOULD result in being logged incorrectly on the frequency scale of the results, correct? The program dutifully multiplies the time-shifted sine/cosine stuff by the A and B inputs, gets an almost 0 Hz output after low-pass filtering, but thinks it's dealing with the latency-corrected frequency of the sine-cosine generator, but the speaker is actually dealing with a different frequency because the latency correction is incorrect. If I'm on the right track, it might seem that the result of the low-pass filters could be examined for non-zero frequency, and even figure out which way the quadrature vectors are spinning, and from that figure out which way to correct the latency correction. You mentioned a 1 Hz low-pass filter. Hoo-eey! With a resulting 2 Hz bandpass at 10 KHz, you have an awfully high Q. It would seem that unless the sweep rate is sufficiently low, any sudden changes in phase or amplitude of the device under test wouldn't be seen -- the frequency components of such a change as it's swept wouldn't make it through the filter. I'm thinking of the high rate of change in something like a deep null in the plot. Can you comment on the sweep rate, and its issues? Good idea on the differential input front end. That way, you can connect it to pretty much anything, like the series resistor on a speaker, and the other across the speaker. Ground-induced junk won't be a problem in other hookups too. Only way to travel. -- Regards from Virginia Beach, Earl Kiosterud www.smokeylake.com |
#15
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Earl Kiosterud" wrote in message news:xkNji.153$YH3.134@trnddc08... "Adam S" not.valid@nosuchaddress wrote in message u... Earl Kiosterud wrote: The latency due to sound waves traveling to the microphone isn't compensated for, although it wouldn't be difficult to add. I'd just have to measure individual latency measurements for channels A and B. 1 meter corresponds to 3 millisecond delay. If sweeping at rate of 1kHz/second then 1000*0.003 = 3Hz offset. I haven't considered this! At the moment I just measure latency for the channel connecting to the speaker terminals. My program merely takes complex ratio between two input channels A/B. If you want to include the power amplifier as part of the overall loop, then you'd just connect channel A directly the amplifier input and channel B to the microphone preamplifier output. I made a general purpose 2 channel differential input pre-amplifier for my soundcard. It has switchable gains (-20dB,-10dB,0dB,+10dB,+20dB,+30dB,+40dB or +50dB) which allows me to measure across speaker terminals, line levels or microphone levels. To do an impedance plot, I just have to connect channel A to a driver, and channel B across a known resistor in series, 8.2 ohm for example. If you wanted to calibrate the soundcard itself , then a simple loop back could achieve this. It'll be interesting to try. There would also be a certain amount of cross talk between the soundcard outputs to inputs. I guess this could be measured by doing a sweep with shorted inputs. I had the idea of using Scilab to manipulate all the different H(f) plots that I generated. I think there are already audio applications out there that can read in response plots and perform analysis. There is an infinite number of things to do with the frequency measurements so I figured just get the data accurately measured with a general purpose tool and worry about what to do with the results later. You are correct about the multiplication of two sine waves. The 2f component is removed by low pass filtering. If any 2f component feeds through then it shows up as oscillating value of H (I think form memory). There is a big advantage taking complex ratios of two input channels. As you know, if the signal source is not exactly equal to the quadrature signal being multiplied then there is no longer a DC component, but a (f1-f2) difference. When you later complex divide two channels each having a (f1-f2) component then the (f1-f2) disappears and your back to DC value of H. It works out that the cutoff frequency of the low pass filter is actually 1/2 the bandwidth of the sweep measurement. For example a 1Hz filter cutoff is used with a 10kHz signal source, then the input is effectively bandpassed with upper and lower frequencies of 10001.0Hz and 9999.0Hz respectively. In theory you could measure down to millihertz resolutions. I have written the program under windows, but I use the cygwin environment. Since it uses DirectX for the soundcard API it wont compile under Linux. It has been written with the intention of someday being ported to Linux using the ALSA API. Hopefully in a few more days I'll be ready to send you the program. Adam Adam, Well, doh! It takes the RATIO. I think I've been standing too close to the forest. So the amplifier is indeed out of the loop, so to speak, when channel A is connected to the amplifier output. It's interesting that it's in the loop, but out of the loop. And irregularities in phase or amplitude introduced by the amplifier won't be seen in the results. Cool. And why the hell else would you have two inputs anyway? OK. I'm awake now. You said "if the signal source is not exactly equal to the quadrature signal being multiplied then there is no longer a DC component, but a (f1-f2) difference." I presume you mean the signal source is different in frequency from the quadrature signal. That would be the result of an error in the latency correction -- I can't think of any other reason for the production of f1-f2. You also said that this f1-f2 component didn't show up in the output. But it WOULD result in being logged incorrectly on the frequency scale of the results, correct? The program dutifully multiplies the time-shifted sine/cosine stuff by the A and B inputs, gets an almost 0 Hz output after low-pass filtering, but thinks it's dealing with the latency-corrected frequency of the sine-cosine generator, but the speaker is actually dealing with a different frequency because the latency correction is incorrect. If I'm on the right track, it might seem that the result of the low-pass filters could be examined for non-zero frequency, and even figure out which way the quadrature vectors are spinning, and from that figure out which way to correct the latency correction. You mentioned a 1 Hz low-pass filter. Hoo-eey! With a resulting 2 Hz bandpass at 10 KHz, you have an awfully high Q. It would seem that unless the sweep rate is sufficiently low, any sudden changes in phase or amplitude of the device under test wouldn't be seen -- the frequency components of such a change as it's swept wouldn't make it through the filter. I'm thinking of the high rate of change in something like a deep null in the plot. Can you comment on the sweep rate, and its issues? Good idea on the differential input front end. That way, you can connect it to pretty much anything, like the series resistor on a speaker, and the other across the speaker. Ground-induced junk won't be a problem in other hookups too. Only way to travel. -- Regards from Virginia Beach, Earl Kiosterud www.smokeylake.com OK, OK. I just realized my mistake. Before the newsgroup hurls an avalanch of epithets, let me say that I didn't mean to say that the quadrature vectors were spinning. How could they? But the resultant vector of a pair of them would in this case, and that's what I meant. I get it right sometimes -- it just takes a while sometimes. -- Regards from Virginia Beach, Earl Kiosterud |
#16
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Earl Kiosterud wrote:
"Adam S" not.valid@nosuchaddress wrote in message u... Earl Kiosterud wrote: The latency due to sound waves traveling to the microphone isn't compensated for, although it wouldn't be difficult to add. I'd just have to measure individual latency measurements for channels A and B. 1 meter corresponds to 3 millisecond delay. If sweeping at rate of 1kHz/second then 1000*0.003 = 3Hz offset. I haven't considered this! At the moment I just measure latency for the channel connecting to the speaker terminals. My program merely takes complex ratio between two input channels A/B. If you want to include the power amplifier as part of the overall loop, then you'd just connect channel A directly the amplifier input and channel B to the microphone preamplifier output. I made a general purpose 2 channel differential input pre-amplifier for my soundcard. It has switchable gains (-20dB,-10dB,0dB,+10dB,+20dB,+30dB,+40dB or +50dB) which allows me to measure across speaker terminals, line levels or microphone levels. To do an impedance plot, I just have to connect channel A to a driver, and channel B across a known resistor in series, 8.2 ohm for example. If you wanted to calibrate the soundcard itself , then a simple loop back could achieve this. It'll be interesting to try. There would also be a certain amount of cross talk between the soundcard outputs to inputs. I guess this could be measured by doing a sweep with shorted inputs. I had the idea of using Scilab to manipulate all the different H(f) plots that I generated. I think there are already audio applications out there that can read in response plots and perform analysis. There is an infinite number of things to do with the frequency measurements so I figured just get the data accurately measured with a general purpose tool and worry about what to do with the results later. You are correct about the multiplication of two sine waves. The 2f component is removed by low pass filtering. If any 2f component feeds through then it shows up as oscillating value of H (I think form memory). There is a big advantage taking complex ratios of two input channels. As you know, if the signal source is not exactly equal to the quadrature signal being multiplied then there is no longer a DC component, but a (f1-f2) difference. When you later complex divide two channels each having a (f1-f2) component then the (f1-f2) disappears and your back to DC value of H. It works out that the cutoff frequency of the low pass filter is actually 1/2 the bandwidth of the sweep measurement. For example a 1Hz filter cutoff is used with a 10kHz signal source, then the input is effectively bandpassed with upper and lower frequencies of 10001.0Hz and 9999.0Hz respectively. In theory you could measure down to millihertz resolutions. I have written the program under windows, but I use the cygwin environment. Since it uses DirectX for the soundcard API it wont compile under Linux. It has been written with the intention of someday being ported to Linux using the ALSA API. Hopefully in a few more days I'll be ready to send you the program. Adam Adam, Well, doh! It takes the RATIO. I think I've been standing too close to the forest. So the amplifier is indeed out of the loop, so to speak, when channel A is connected to the amplifier output. It's interesting that it's in the loop, but out of the loop. And irregularities in phase or amplitude introduced by the amplifier won't be seen in the results. Cool. And why the hell else would you have two inputs anyway? OK. I'm awake now. You said "if the signal source is not exactly equal to the quadrature signal being multiplied then there is no longer a DC component, but a (f1-f2) difference." I presume you mean the signal source is different in frequency from the quadrature signal. That would be the result of an error in the latency correction -- I can't think of any other reason for the production of f1-f2. You also said that this f1-f2 component didn't show up in the output. But it WOULD result in being logged incorrectly on the frequency scale of the results, correct? The program dutifully multiplies the time-shifted sine/cosine stuff by the A and B inputs, gets an almost 0 Hz output after low-pass filtering, but thinks it's dealing with the latency-corrected frequency of the sine-cosine generator, but the speaker is actually dealing with a different frequency because the latency correction is incorrect. If I'm on the right track, it might seem that the result of the low-pass filters could be examined for non-zero frequency, and even figure out which way the quadrature vectors are spinning, and from that figure out which way to correct the latency correction. Well, looks like there is much I didn't think about. Thanks for pointing it out, but the maths is starting to get worse. I'd agree with the microphone having a delay relative to the speaker. I'd have to go back to first principles to work out what happens to H, the complex ratio of channel A and B. You now introduce three frequencies. The quadrature reference signal, that of the speaker and that of the microphone. let f0 = frequency of quadrature signal f1 = frequency of speaker signal f2 = frequency of microphone signal so you have (f0-f1) and (f0-f2) . I'll have to have a think about this some more. You mentioned a 1 Hz low-pass filter. Hoo-eey! With a resulting 2 Hz bandpass at 10 KHz, you have an awfully high Q. It would seem that unless the sweep rate is sufficiently low, any sudden changes in phase or amplitude of the device under test wouldn't be seen -- the frequency components of such a change as it's swept wouldn't make it through the filter. I'm thinking of the high rate of change in something like a deep null in the plot. Can you comment on the sweep rate, and its issues? You absolutely right. Filtering effectively results in smoothing of the response and you loose much of the sharp nulls and peaks. But from what I've experimented with so far, a logarithmic sweep from 20 to 20k in 60 seconds looks almost the same as a plot in 30 seconds. So going by this , a 60 second sweep your not going to loose any precious information. The only way to know of steep gradients is to run slower and slower sweeps until you don't see any increase is these peaks. Even 15 seconds sweep on my woofer looked fairly unchanged. However ,a 5 second 20 to 20kHz sweep was just hopeless. The problem with increase the filter cutoff frequency (increase bandwidth) is the 2f component leaks through and it corrupts the low end frequency measurements. |
#17
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
Adam S wrote:
Earl Kiosterud wrote: If I'm on the right track, it might seem that the result of the low-pass filters could be examined for non-zero frequency, and even figure out which way the quadrature vectors are spinning, and from that figure out which way to correct the latency correction. Well, looks like there is much I didn't think about. Thanks for pointing it out, but the maths is starting to get worse. I'd agree with the microphone having a delay relative to the speaker. I'd have to go back to first principles to work out what happens to H, the complex ratio of channel A and B. You now introduce three frequencies. The quadrature reference signal, that of the speaker and that of the microphone. let f0 = frequency of quadrature signal f1 = frequency of speaker signal f2 = frequency of microphone signal so you have (f0-f1) and (f0-f2) . I'll have to have a think about this some more. I turns out that a delay on one channel will indeed effect the H vector, but only its phase vs frequency relationship while the magnitude of H is always the ratio of magnitudes of channels A and B. Using exponent representation of vectors. Let channel A signal be A = |A|*exp(i*Wa*(t-Ta) + ¥a) where |A| = magnitude of channel A Wa = frequency of channel A (rad/sec) t = time (sec) Ta = time delay of channel A (sec) ¥a = phase shift of channel A (rad) channel B is similarly B = |B|*exp(i*Wb*(t-Tb) + ¥b) ratio of A/B is then H = |A|/|B|*exp( i*Wa*(t-Ta) + ¥a - i*Wb*(t-Tb) + ¥b) = |A|/|B|*exp( i*( t*(Wa - Wb + Tb - Ta) + ¥a - ¥b ) ) So you can see from the term (Wa - Wb + Tb - Ta), that if Wa-Wb are not non zero then it has same effect as adding extra time delay difference. The magnitude of H stays constant. This is not to say everything is nice and dandy, especially for log frequency sweeps. The (Wa-Wb) term will not be constant in log sweeps and therefore won't appear as humble group delay, messing up the true phase information (¥a - ¥b). I think errors become insignificant with practical delays times and sweep rates. Hope I'm on the right track saying this. I theory both (Tb-Ta) and (Wa-Wb) could be predicted and compensated. Adam |
#18
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Adam S" not.valid@nosuchaddress wrote in message ... Adam S wrote: Earl Kiosterud wrote: If I'm on the right track, it might seem that the result of the low-pass filters could be examined for non-zero frequency, and even figure out which way the quadrature vectors are spinning, and from that figure out which way to correct the latency correction. Well, looks like there is much I didn't think about. Thanks for pointing it out, but the maths is starting to get worse. I'd agree with the microphone having a delay relative to the speaker. I'd have to go back to first principles to work out what happens to H, the complex ratio of channel A and B. You now introduce three frequencies. The quadrature reference signal, that of the speaker and that of the microphone. let f0 = frequency of quadrature signal f1 = frequency of speaker signal f2 = frequency of microphone signal so you have (f0-f1) and (f0-f2) . I'll have to have a think about this some more. I turns out that a delay on one channel will indeed effect the H vector, but only its phase vs frequency relationship while the magnitude of H is always the ratio of magnitudes of channels A and B. Using exponent representation of vectors. Let channel A signal be A = |A|*exp(i*Wa*(t-Ta) + ¥a) where |A| = magnitude of channel A Wa = frequency of channel A (rad/sec) t = time (sec) Ta = time delay of channel A (sec) ¥a = phase shift of channel A (rad) channel B is similarly B = |B|*exp(i*Wb*(t-Tb) + ¥b) ratio of A/B is then H = |A|/|B|*exp( i*Wa*(t-Ta) + ¥a - i*Wb*(t-Tb) + ¥b) = |A|/|B|*exp( i*( t*(Wa - Wb + Tb - Ta) + ¥a - ¥b ) ) So you can see from the term (Wa - Wb + Tb - Ta), that if Wa-Wb are not non zero then it has same effect as adding extra time delay difference. The magnitude of H stays constant. This is not to say everything is nice and dandy, especially for log frequency sweeps. The (Wa-Wb) term will not be constant in log sweeps and therefore won't appear as humble group delay, messing up the true phase information (¥a - ¥b). I think errors become insignificant with practical delays times and sweep rates. Hope I'm on the right track saying this. I theory both (Tb-Ta) and (Wa-Wb) could be predicted and compensated. Adam Adam, My neurons are beginning to complain. Stretched thin! Some questions: It seems to me that accurate phase data depends on accurately calculating cos(w*t)*A, etc. If t isn't accurately known, (if there's a latency error), then all bets are off, it would seem, for phase data. It also seems to me that low-pass filtering should not be necessary if the latency is accurately known. Can you comment on that? I don't understand how cos(w*t) can ba used to get a quadrature vector, since w is changing all the time (linearly, logarithmically, etc.). For constant w, I'm OK with w*t, but not where w is a function of time. Would it not be necessary to integrate w*t for the time involved to get the total angular displacement during the latency period? (Or cheat and use a software buffer!) I wasn't sure what Ta and Tb are. Are they the latency of the input of the sound card? Onward. -- Regards from Virginia Beach, Earl Kiosterud www.smokeylake.com |
#19
Posted to rec.audio.tech
|
|||
|
|||
"near field" speaker measurement
"Earl Kiosterud" wrote in message news:mcNki.12025$g44.9074@trnddc02... "Adam S" not.valid@nosuchaddress wrote in message ... Adam S wrote: Earl Kiosterud wrote: If I'm on the right track, it might seem that the result of the low-pass filters could be examined for non-zero frequency, and even figure out which way the quadrature vectors are spinning, and from that figure out which way to correct the latency correction. Well, looks like there is much I didn't think about. Thanks for pointing it out, but the maths is starting to get worse. I'd agree with the microphone having a delay relative to the speaker. I'd have to go back to first principles to work out what happens to H, the complex ratio of channel A and B. You now introduce three frequencies. The quadrature reference signal, that of the speaker and that of the microphone. let f0 = frequency of quadrature signal f1 = frequency of speaker signal f2 = frequency of microphone signal so you have (f0-f1) and (f0-f2) . I'll have to have a think about this some more. I turns out that a delay on one channel will indeed effect the H vector, but only its phase vs frequency relationship while the magnitude of H is always the ratio of magnitudes of channels A and B. Using exponent representation of vectors. Let channel A signal be A = |A|*exp(i*Wa*(t-Ta) + ¥a) where |A| = magnitude of channel A Wa = frequency of channel A (rad/sec) t = time (sec) Ta = time delay of channel A (sec) ¥a = phase shift of channel A (rad) channel B is similarly B = |B|*exp(i*Wb*(t-Tb) + ¥b) ratio of A/B is then H = |A|/|B|*exp( i*Wa*(t-Ta) + ¥a - i*Wb*(t-Tb) + ¥b) = |A|/|B|*exp( i*( t*(Wa - Wb + Tb - Ta) + ¥a - ¥b ) ) So you can see from the term (Wa - Wb + Tb - Ta), that if Wa-Wb are not non zero then it has same effect as adding extra time delay difference. The magnitude of H stays constant. This is not to say everything is nice and dandy, especially for log frequency sweeps. The (Wa-Wb) term will not be constant in log sweeps and therefore won't appear as humble group delay, messing up the true phase information (¥a - ¥b). I think errors become insignificant with practical delays times and sweep rates. Hope I'm on the right track saying this. I theory both (Tb-Ta) and (Wa-Wb) could be predicted and compensated. Adam Adam, My neurons are beginning to complain. Stretched thin! Some questions: It seems to me that accurate phase data depends on accurately calculating cos(w*t)*A, etc. If t isn't accurately known, (if there's a latency error), then all bets are off, it would seem, for phase data. It also seems to me that low-pass filtering should not be necessary if the latency is accurately known. Can you comment on that? I don't understand how cos(w*t) can ba used to get a quadrature vector, since w is changing all the time (linearly, logarithmically, etc.). For constant w, I'm OK with w*t, but not where w is a function of time. Would it not be necessary to integrate w*t for the time involved to get the total angular displacement during the latency period? (Or cheat and use a software buffer!) I wasn't sure what Ta and Tb are. Are they the latency of the input of the sound card? Onward. -- Regards from Virginia Beach, Earl Kiosterud www.smokeylake.com Adam I said low pass filtering wouldn't be necessary if the latency were accurately known. Later in the day a neuron spontaneously fired saying "that's wrong," with which the rest of the neurons agreed. So I retract that statement. There's still the 2f component that the multiplication of the two sines produces. I also asked about Ta and Tb. I then realized that they're the latency of the A and B points. T is time. You haven't commented on the soundcard's input latency. And I haven't thought much about it. -- Regards from Virginia Beach, Earl Kiosterud www.smokeylake.com |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
"AKAI", "KURZWEIL", "ROLAND", DVDs and CDs | Audio Opinions |