Time-view of distortion residual - diyAudio
Go Back   Home > Forums > Design & Build > Equipment & Tools

Equipment & Tools From test equipment to hand tools

Please consider donating to help us continue to serve you.

Ads on/off / Custom Title / More PMs / More album space / Advanced printing & mass image saving
Reply
 
Thread Tools Search this Thread
Old 23rd February 2013, 08:08 AM   #1
diyAudio Member
 
jan.didden's Avatar
 
Join Date: May 2002
Location: Great City of Turnhout, Belgium
Blog Entries: 7
Default Time-view of distortion residual

Many of us seem to slowly migrate from dedicated distortion measuring equipment (HP, Tek, AP) to software based solutions based on a sound card.
One feature I always valued on the dedicated equipment was that you can look at the distortion residual, basically the waveform coming out of the fundamental rejection filter.
If you know how to interprete that residual, you can tell a lot about what is going on in the DUT.

With software/sound card solutions this feature is lost.
But does it have to be?
The software involved effortlessly switches between frequency (FFT) and time domain views.
On idea I had is this: you look at the FFT of the signal, and digitally remove whatever is in the fundamental's bin. Then you take the result, convert it back to the time domain and presto! that is the distortion residual.
You can then show it on the PC or send it out through the other soundcard analog output so you can put it on a 'scope.

As far as I know, nobody has done this. Is there a good reason why it isn't done, or is it a case that nobody thought about it yet?

Comments?

jan
__________________
If you don't change your beliefs, your life will be like this forever. Is that good news? - W. S. Maugham
Check out Linear Audio!
  Reply With Quote
Old 23rd February 2013, 08:16 AM   #2
diyAudio Member
 
abraxalito's Avatar
 
Join Date: Sep 2007
Location: Hangzhou - Marco Polo's 'most beautiful city'. 700yrs is a long time though...
Blog Entries: 105
Send a message via MSN to abraxalito Send a message via Yahoo to abraxalito Send a message via Skype™ to abraxalito
You'd need to keep the phase part of the FFT too, without the phase the value of the residual as a diagnostic is somewhat diminished. Also there's no one bin for the fundamental, its smeared out by the windowing function. That is unless the sample rate clock is locked to the test tone fundamental, which is entirely possible if the test tone DAC and the ADC are on the same soundcard.
__________________
I have the advantage of having found out how hard it is to get to really know something... how easy it is to make mistakes and fool yourself. - Richard Feynman
  Reply With Quote
Old 23rd February 2013, 08:27 AM   #3
diyAudio Member
 
jan.didden's Avatar
 
Join Date: May 2002
Location: Great City of Turnhout, Belgium
Blog Entries: 7
Quote:
Originally Posted by abraxalito View Post
You'd need to keep the phase part of the FFT too, without the phase the value of the residual as a diagnostic is somewhat diminished.
Right. But that is not a real problem, is it?

Quote:
Originally Posted by abraxalito View Post
Also there's no one bin for the fundamental, its smeared out by the windowing function. That is unless the sample rate clock is locked to the test tone fundamental, which is entirely possible if the test tone DAC and the ADC are on the same soundcard.
Yes I realised that. I guess that too is not a real issue, but must be safeguarded in the software. For instance, one software I tested (can't remember the name at the moment) has a setting where you lock the two and also size the FFT to make it totally synchronous, no window needed.

Edit: I believe Virtins has the synchronous option.

jan
__________________
If you don't change your beliefs, your life will be like this forever. Is that good news? - W. S. Maugham
Check out Linear Audio!

Last edited by jan.didden; 23rd February 2013 at 08:30 AM.
  Reply With Quote
Old 23rd February 2013, 08:33 AM   #4
diyAudio Member
 
abraxalito's Avatar
 
Join Date: Sep 2007
Location: Hangzhou - Marco Polo's 'most beautiful city'. 700yrs is a long time though...
Blog Entries: 105
Send a message via MSN to abraxalito Send a message via Yahoo to abraxalito Send a message via Skype™ to abraxalito
No, keeping the phase of the FFT isn't any kind of problem.

I'm wondering though given the need for phase locking the SR to shoe-horn the fundamental into just the one bin whether there's any role for FFT at all. Since the time sequence is what's already acquired, why not just subtract the invFFT of the fundamental from that (still in the time domain) to get the residual directly? This just needs measuring the precise amplitude and phase of the fundamental to get a null.
__________________
I have the advantage of having found out how hard it is to get to really know something... how easy it is to make mistakes and fool yourself. - Richard Feynman
  Reply With Quote
Old 23rd February 2013, 08:41 AM   #5
diyAudio Member
 
jan.didden's Avatar
 
Join Date: May 2002
Location: Great City of Turnhout, Belgium
Blog Entries: 7
Something like this maybe:

....the filtering of a FFT filter is not done in time domain. Instead, the input signal is transformed from time domain to frequency domain using FFT, its spectrum is then multiplied with the filterís frequency response and the result is transformed back to time domain using inverse FFT.

jan
__________________
If you don't change your beliefs, your life will be like this forever. Is that good news? - W. S. Maugham
Check out Linear Audio!
  Reply With Quote
Old 23rd February 2013, 08:42 AM   #6
jcx is offline jcx  United States
diyAudio Member
 
Join Date: Feb 2003
Location: ..
I built a subcircut for LTspice: Spice simulation

I assume Audio DiffMaker wouldn't have any trouble with sine wave input
  Reply With Quote
Old 23rd February 2013, 08:49 AM   #7
diyAudio Member
 
jan.didden's Avatar
 
Join Date: May 2002
Location: Great City of Turnhout, Belgium
Blog Entries: 7
That Spice tool is brilliant!
Maybe I finally should convert to LTspice after all...

But I am also looking for a soundcard/software solution; though, come to think of it, you can feed LTspice an external .wav and also export a signal to .wav, isn't it?

jan
__________________
If you don't change your beliefs, your life will be like this forever. Is that good news? - W. S. Maugham
Check out Linear Audio!
  Reply With Quote
Old 23rd February 2013, 04:32 PM   #8
jcx is offline jcx  United States
diyAudio Member
 
Join Date: Feb 2003
Location: ..
LTspice does have .wav I/O - can simultaneously play and record with Audacity - digital sine .wav can be generated in either, with same soundcard DAC/ADC using a common clock sync shouldn't be a problem

but I expect the Liberty Insturments free DiffMaker sw would do a better job with a deeper null

Last edited by jcx; 23rd February 2013 at 04:35 PM.
  Reply With Quote
Old 23rd February 2013, 06:39 PM   #9
diyAudio Member
 
jan.didden's Avatar
 
Join Date: May 2002
Location: Great City of Turnhout, Belgium
Blog Entries: 7
You mean feeding Diffmaker the fundamental and the distorted version and do a subtraction? Yes I should try that out.

jan
__________________
If you don't change your beliefs, your life will be like this forever. Is that good news? - W. S. Maugham
Check out Linear Audio!
  Reply With Quote
Old 2nd March 2013, 05:05 PM   #10
RNMarsh is offline RNMarsh  United States
diyAudio Member
 
RNMarsh's Avatar
 
Join Date: May 2012
Location: 2457 Cascade Trail; Cool, CA. 95614
jan.... That would be great.... waiting to hear your results.

Thx-RNMarsh
  Reply With Quote

Reply


Hide this!Advertise here!
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Time domain distortion cvjoint Everything Else 39 22nd November 2012 07:27 PM
From Power Compression towards Thermal Distortion / developing on a point of view mige0 Multi-Way 190 28th December 2008 07:28 PM
sine wave with 1% residual distortion Bernhard Digital Source 13 10th April 2007 08:25 PM
dead time, and class D distortion zenmasterbrian Class D 90 22nd January 2007 12:47 PM


New To Site? Need Help?

All times are GMT. The time now is 10:39 AM.


vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2014 DragonByte Technologies Ltd.
Copyright ©1999-2014 diyAudio

Content Relevant URLs by vBSEO 3.3.2