IPB

Welcome Guest ( Log In | Register )

2 Pages V   1 2 >  
Reply to this topicStart new topic
Sampling/Time Resolution - In search of sources
FreaqyFrequency
post Oct 4 2011, 21:36
Post #1





Group: Members
Posts: 58
Joined: 4-October 11
From: VA Beach, VA
Member No.: 94145



Greetings all,

I've been lurking on these forums for about the last year, and I finally signed up today to pick the brains of some of the more knowledgeable individuals here.

On Saturday, I'm giving an 8 minute informative speech on the essential elements of digital audio (PCM to be exact, leaving DSD out given the time limit), why it was a logical progression from analog recording and storage technology, and a brief sketch of lossy/lossless implementations of it.

My primary objective at this point is to get a rock solid source, stating that (and why) any sampling rate is able to capture a given bandlimited source with perfect time resolution (ignoring frequency response and filtering in this case, dealing only with time). I was encouraged to touch upon this point in particular because of a presentation I found on YouTube a few months back, whose essential message was "Digital is bad because you hear the music as packets rather than as an analog waveform" and was advocating that everyone dispense with their digital media and go get a turntable and vinyls. My intent is to disprove the "packets" notion, and this source is the closest I have seen to doing that as of now:

http://www.tonmeister.ca/main/textbook/node639.html

If anyone could supply further documentation (or their own findings/conclusions on the matter), that would be most appreciated. Thanks! smile.gif
Go to the top of the page
+Quote Post
saratoga
post Oct 4 2011, 21:40
Post #2





Group: Members
Posts: 4916
Joined: 2-September 02
Member No.: 3264



QUOTE (FreaqyFrequency @ Oct 4 2011, 16:36) *
My primary objective at this point is to get a rock solid source, stating that (and why) any sampling rate is able to capture a given bandlimited source with perfect time resolution (ignoring frequency response and filtering in this case, dealing only with time).


Stop by the library, pick up any introductory DSP textbook.
Go to the top of the page
+Quote Post
benski
post Oct 4 2011, 21:41
Post #3


Winamp Developer


Group: Developer
Posts: 670
Joined: 17-July 05
From: Brooklyn, NY
Member No.: 23375



http://www.dspguide.com/ch3/3.htm

Another good topic to start looking at is "intersample overs". Basically, that since digital audio is able to reliably reproduce data points in between samples (up to the bandwidth limit, of course), it is possible to have analog output values over 0dBFS because the inter-sample data is preserved. This is a product of the anti-aliasing filter (ADC) and the reconstruction filter (DAC).

This post has been edited by benski: Oct 4 2011, 21:48
Go to the top of the page
+Quote Post
FreaqyFrequency
post Oct 4 2011, 21:56
Post #4





Group: Members
Posts: 58
Joined: 4-October 11
From: VA Beach, VA
Member No.: 94145



Wow, you guys are quick on the draw! Thoroughly appreciate the swift replies, the library is actually less than a 2 mile walk from me and it's gorgeous out today so that's a great idea.

Thanks for the link, benski. Reading through it presently.


--------------------
FLAC -2 w/ lossyWAV 1.3.0i -q X -i
Go to the top of the page
+Quote Post
C.R.Helmrich
post Oct 4 2011, 22:19
Post #5





Group: Developer
Posts: 686
Joined: 6-December 08
From: Erlangen Germany
Member No.: 64012



Was about to post the link that benski already posted smile.gif That book managed to explain to me how a DFT works.

People saying things like "Digital is bad because you hear the music as packets rather than as an analog waveform" obviously don't have a clue about digital sampling, especially about sinc interpolation. I just stumbled across the following page. Haven't tried it, but maybe it can help you visualize that, when listening to digital audio, we don't listen to packets.

demonstrations.wolfram.com/SincInterpolationForSignalReconstruction/

Chris


--------------------
If I don't reply to your reply, it means I agree with you.
Go to the top of the page
+Quote Post
xnor
post Oct 4 2011, 22:42
Post #6





Group: Developer
Posts: 586
Joined: 29-April 11
From: Austria
Member No.: 90198



Some introductory wiki pages:
Sampling
Nyquist-Shannon
Pulse-code modulation
Delta-sigma modulation
...

This post has been edited by xnor: Oct 4 2011, 22:42
Go to the top of the page
+Quote Post
Speedskater
post Oct 4 2011, 23:21
Post #7





Group: Members
Posts: 138
Joined: 12-December 07
From: Cleveland, OH
Member No.: 49500



You might look through member "woodinville" (aka j.j.) 1100 posts, as he sometimes touches on the subject.

http://www.hydrogenaudio.org/forums/index.php?showuser=18957

Some of his Power Point presentations.

http://www.aes.org/sections/pnw/ppt.htm

This post has been edited by Speedskater: Oct 4 2011, 23:23


--------------------
Kevin
Go to the top of the page
+Quote Post
knutinh
post Oct 5 2011, 01:44
Post #8





Group: Members
Posts: 569
Joined: 1-November 06
Member No.: 37047



It is called Shannon-Nyquist sampling theoreme, and says that any analog signal of bandwidth <B can be discretely recorded and recreated using a discrete-time sampler/playback device combined with hypothetically perfect (typically lowpass) filters.

Some transient, and the same transient delayed by 1e-9 seconds clearly can both be "any analog signal of bandwidth <B" if B is chosen large enough.

The sampling theoreme does not cover how to design those filters in practice, nor the effects of finite number of bits. Therefore, real-world ADC and DAC systems are only an approximation to the sampling theoreme, but measurements and listening tests indicate that they can be _really good_ approximations.

Assuming 16 perfect bits and a sin(x)/x filter, there is a finite number of "positions" that a pulse can have in-between t1=0 and t2=1/44100 seconds, but that is a large number that I dont feel like worrying about. (if it was not finite, one could "encode" an infinite amount of information - bits - into the placement of an impulse sampled by only 2 16-bit integers. Clearly that violates a bunch of information-theoretical theoremes). Then again, a sin(x)/x filter sort of assumes an infinite signal in the first place so perhaps I am just talking nonsense.

You should probably ask you audience about the effects of finite particle size in vinyl records, quantum effects in (analog) electronics, and whether they want to go down the slippery slope of "I am going to dizz technology X not based on its practical merits, but on some flawed, silly model that I developed myself because I was too lazy to spend 2 minutes on wikipedia" :-)

-k

This post has been edited by knutinh: Oct 5 2011, 01:54
Go to the top of the page
+Quote Post
Axon
post Oct 5 2011, 02:23
Post #9





Group: Members (Donating)
Posts: 1984
Joined: 4-January 04
From: Austin, TX
Member No.: 10933



All I can suggest is to read this section from the wikipedia page on the Shannon-Nyquist Theorem, and come back and ask us if you have any questions. I don't think you can make a truly ironclad argument for the theorem without essentially restating that information: understanding the Fourier transform (and convolution) is crucial, and provides a clear roadmap for how to analyze the various nonlinearities of sampling.

Note, I'm not seriously suggesting your audience would have a grasp of convolution -- what I'm saying is that, if you are considering making an ironclad proof here, you might want to consider presenting this by describing the proof by analogy, instead of discussing individual examples. (I'm worried that you'll run into some audiophile who will try to outwit you in a game of "anecdotal claims of sound quality which prove Nyquist was wrong".)
Go to the top of the page
+Quote Post
FreaqyFrequency
post Oct 5 2011, 03:14
Post #10





Group: Members
Posts: 58
Joined: 4-October 11
From: VA Beach, VA
Member No.: 94145



Again, many thanks for all the replies, extremely informative stuff. The number of hits this has gotten in the time it's been up absolutely makes my jaw drop. This doesn't happen on any other forum I actively participate in.

In light of the last two replies concerning my audience, it'd probably be prudent to note at this point that this is a basic college Public Speaking course. My main objective is going to be capturing and holding the audience's attention on my topic; they will not (generally) have a clue about any of the technical details I'm going to be getting into, which is why I'm going for brevity and for concise information that is most effective to my end. I may have one or two classmates ask me for further information on something (if I get massively lucky), but I highly doubt that any of them will have the expertise (or the desire) to challenge me on anything in particular. This request for sources on this specific issue is mainly for preparedness, in case someone down the line tries to say "Well, CD isn't good enough because you only get 22.7 µs of resolution per sample; there must be information missing there." I've seen this stuff on various audiophilia-centered forums, with other arguments coming in such as "Some instruments have rise times as low as 10 µs", yadda yadda...I'm sure you're all quite well aware of the type, so I won't go on. ;)

All an attempt to arm myself with knowledge, especially when it is so readily available in this age.

This post has been edited by FreaqyFrequency: Oct 5 2011, 03:30
Go to the top of the page
+Quote Post
dhromed
post Oct 5 2011, 09:25
Post #11





Group: Members
Posts: 1303
Joined: 16-February 08
From: NL
Member No.: 51347



QUOTE (FreaqyFrequency @ Oct 5 2011, 04:14) *
The number of hits this has gotten in the time it's been up absolutely makes my jaw drop. This doesn't happen on any other forum I actively participate in.


HA is especially invested in providing extra cups to those mules/horses/whathaveyou who have led themselves to water and are obviously willing to drink.
Go to the top of the page
+Quote Post
drewfx
post Oct 5 2011, 17:38
Post #12





Group: Members
Posts: 81
Joined: 17-October 09
Member No.: 74078



The critical piece of information to stress to "civilians" (where any mathematical explanation is likely to go either over their head, or in one ear and out the other) is this:

When the digital signal is converted back to a continuous analog wave, the stuff between the samples isn't "lost" or "averaged" or "guestimated"; it's calculated.
Go to the top of the page
+Quote Post
benski
post Oct 5 2011, 18:02
Post #13


Winamp Developer


Group: Developer
Posts: 670
Joined: 17-July 05
From: Brooklyn, NY
Member No.: 23375



QUOTE (drewfx @ Oct 5 2011, 12:38) *
The critical piece of information to stress to "civilians" (where any mathematical explanation is likely to go either over their head, or in one ear and out the other) is this:

When the digital signal is converted back to a continuous analog wave, the stuff between the samples isn't "lost" or "averaged" or "guestimated"; it's calculated.


One analogy I like to use, although it's not 100% scientifically correct. Instead of thinking about the digital samples as "speaker position versus time", think of it as a series of pegs on a pegboard through which we will thread an analog "rope" through. If there are nuances to the analog signal in between sample points, the pegs will be placed in positions that will force the rope to bend in such a way as to recreate that original waveform.
Go to the top of the page
+Quote Post
FreaqyFrequency
post Oct 5 2011, 19:02
Post #14





Group: Members
Posts: 58
Joined: 4-October 11
From: VA Beach, VA
Member No.: 94145



That is a great analogy, and analogies will be a source of reliance for me in this context. The important thing will be to rid them of any notion that what we hear from a digital source is "pictures" or "frames" of the audio multiple times a second. I will be stressing the function of the reconstruction filter in the DAC, to be sure.

I'm now confident that I have trustworthy sources to pull from for this issue, so the rest will be a straight shot of explaining the advantages and an abbreviated explanation of implementations of PCM today (taking mp3, AAC, WAV, FLAC and splitting those into Redbook CD, iTunes, YouTube, Spotify, Pandora, etc.), and how the coding mechanisms for the lossy codecs work. Hopefully I have time to touch briefly on dither and noise shaping as well, as a further argument that the accuracy and precision of PCM greatly exceeds that of any analog storage medium today.

I just realized that I never included this in this thread. This is the video which inspired me to select this topic for the class.

http://www.youtube.com/watch?v=E-0D8784zGA

This post has been edited by FreaqyFrequency: Oct 5 2011, 19:04
Go to the top of the page
+Quote Post
db1989
post Oct 5 2011, 19:54
Post #15





Group: Super Moderator
Posts: 5275
Joined: 23-June 06
Member No.: 32180



I, too, like that analogy—and dhromed’s! biggrin.gif

This sounds like an interesting presentation that will clarify the issue and/or dispel myths for the audience, so I’m glad HA has helped you to find good sources, and I hope it goes well for you! recording or it didn’t happen wink.gif

This post has been edited by db1989: Oct 5 2011, 19:57
Go to the top of the page
+Quote Post
DVDdoug
post Oct 6 2011, 00:03
Post #16





Group: Members
Posts: 2566
Joined: 24-August 07
From: Silicon Valley
Member No.: 46454



QUOTE
When the digital signal is converted back to a continuous analog wave, the stuff between the samples isn't "lost" or "averaged" or "guestimated"; it's calculated.
And because of the required band-limiting before sampling, there isn't much happening between samples.
Go to the top of the page
+Quote Post
krabapple
post Oct 6 2011, 01:22
Post #17





Group: Members
Posts: 2230
Joined: 18-December 03
Member No.: 10538



If you want to see the sorts of trainwrecks that happen when 'audiophiles' try to wrap their heads around this (and the valiant HA member we know as Axon tries to
educate them), see this:

http://www.stevehoffman.tv/forums/showthread.php?t=85436

and concurrently, an HA thread on the topic, from the same era...with some of the same players (including the guy who thinks he's improved on Shannon/Nyquist)..plus Woodinville:

http://www.hydrogenaudio.org/forums/index....showtopic=49043

This post has been edited by krabapple: Oct 6 2011, 01:45
Go to the top of the page
+Quote Post
dhromed
post Oct 6 2011, 10:03
Post #18





Group: Members
Posts: 1303
Joined: 16-February 08
From: NL
Member No.: 51347



QUOTE (drewfx @ Oct 5 2011, 18:38) *
When the digital signal is converted back to a continuous analog wave, the stuff between the samples isn't "lost" or "averaged" or "guestimated"; it's calculated.


Averaging and lerping are also calculations, but no sane reconstruction filter uses them. wink.gif

What must be shown, I think, is that there are advanced mathematics and calculations that can easily obtain results beyond human perception. That it's not as simple as people think, but not as magical or subjective either.

You can attempt to explain complex idea, but as long as the person think it's gibberish rather than a internally consistent but complex thing that the person doesn't yet know about, you're not really educating him. In other words, first you have to make them understand that they don't understand, then make them understand that they could understand given time, and then explain it all.

If someone comes in saying "I know nothing!", that's your cue.
Go to the top of the page
+Quote Post
2Bdecided
post Oct 6 2011, 12:42
Post #19


ReplayGain developer


Group: Developer
Posts: 5101
Joined: 5-November 01
From: Yorkshire, UK
Member No.: 409



QUOTE (krabapple @ Oct 6 2011, 01:22) *
If you want to see the sorts of trainwrecks that happen when 'audiophiles' try to wrap their heads around this (and the valiant HA member we know as Axon tries to
educate them), see this:

http://www.stevehoffman.tv/forums/showthread.php?t=85436

and concurrently, an HA thread on the topic, from the same era...with some of the same players (including the guy who thinks he's improved on Shannon/Nyquist)..plus Woodinville:

http://www.hydrogenaudio.org/forums/index....showtopic=49043
Yeah, thanks for reminding me about that thread!
Go to the top of the page
+Quote Post
Woodinville
post Oct 8 2011, 03:12
Post #20





Group: Members
Posts: 1402
Joined: 9-January 05
From: JJ's office.
Member No.: 18957



The time resolution of a PROPERLY reconstructed PCM signal (note, if you take away the antiimaging filter the time resolution GETS WORSE!!) is approximately

1/ (2 pi fs nlevels)

for CD that is 1/( 2 pi 44100 65536).

Time reconstruction can not be perfect, because noise from quantization (by the way, also look up dithering, it's the level issue that also gets abused phenominally stupidly) creates a slight phase jitter.

This is, however, very small, i.e. on the order of 6 picoseconds give or take.

You'll also see the idea that "the sound is turned into stairsteps". This mistake comes from the fallacy that one can look at the signal before the antimaging filter and have it make sense. Somewhere out there I have a set of graphs to reply to that. Now let me see if I can find them.



This, of course, takes some explanation. The first (top) is the sine wave that results when you have ONLY the output from the DAC taht is below FS/2.

The next line adds either 2 or 4 images, I forget which (the squiggly line) and adds them to the sine wave, giving the rather odd lookign waveform.
Third line adds more.
The last line adds the first 1000 images. Notice that the result when it is added to the original signal, is the "stairstep" people whine about.

Every bit of that 'stairstep' except the original sine wave, however, results from frequencies above half the sampling rate, showing, once again, that Shannon was right.

You are welcome to grab the plot if you like.


--------------------
-----
J. D. (jj) Johnston
Go to the top of the page
+Quote Post
FreaqyFrequency
post Oct 8 2011, 17:33
Post #21





Group: Members
Posts: 58
Joined: 4-October 11
From: VA Beach, VA
Member No.: 94145



Thank you very much JJ, I've been following your work in particular for some time, between the thread at Skeptic back in 2005 and the Audio Myths Workshop at AES 2009. Your level of expertise is invaluable, and I thoroughly appreciate your chiming in here. smile.gif In fact, I read the link which krabapple posted as I was making final preparations to my Powerpoint yesterday, and considered adding in the "accurate to 346 picoseconds" blurb, but as you're about to see below, it's rather lucky that I didn't attempt to do so.

I gave the speech today, and the result...well, I had to trim the fat significantly and STILL ended up four minutes over the time budget, which means that I only got to mention CD and PCM in passing, while I did still cover the fact that, in CD form, PCM represents frequencies beyond the range of human hearing, and that its dynamic range can be as high as 130 dB (I had to bend this one for the sake of leaving out technicalities; this is of course when dither and noise shaping are used properly, and only in certain bands). My approach ended up being one focusing on the evolution of this technology (recording, manipulation, storage and playback that is) from the phonograph to PCM today. My teacher and even a couple classmates commented that they were very impressed by my level of confidence in discussing the material, so that (kinda sorta?) made up for going over time.

No recording, sadly, but I will tell you that a good amount of the speech was based directly on the first 8 minutes or so of this video here.

http://xiph.org/video/vid1.shtml

Monty is a far more eloquent/prepared speaker than I am, so if you haven't already seen this video, it's definitely worth it. No new information, only the fact that he summarizes so much, so neatly.

Thank you all again for your participation in this thread, I look forward to my stay here. I'm prepared to learn a whole lot more, since I know the end of the rabbit hole is a long way down from here. biggrin.gif

*Edit: I had missed the 2pi function in 1/(2pi*quant. levels*fs), so I guess that figure would actually be closer to 55 picoseconds. Either way, pretty far below the ability of any human being to distinguish a timing difference.

This post has been edited by FreaqyFrequency: Oct 8 2011, 17:58
Go to the top of the page
+Quote Post
Woodinville
post Oct 9 2011, 00:04
Post #22





Group: Members
Posts: 1402
Joined: 9-January 05
From: JJ's office.
Member No.: 18957



QUOTE (Woodinville @ Oct 7 2011, 19:12) *
The time resolution of a PROPERLY reconstructed PCM signal (note, if you take away the antiimaging filter the time resolution GETS WORSE!!) is approximately

1/ (2 pi fs nlevels)

for CD that is 1/( 2 pi 44100 65536).

Time reconstruction can not be perfect, because noise from quantization (by the way, also look up dithering, it's the level issue that also gets abused phenominally stupidly) creates a slight phase jitter.

This is, however, very small, i.e. on the order of 6 picoseconds give or take.

You'll also see the idea that "the sound is turned into stairsteps". This mistake comes from the fallacy that one can look at the signal before the antimaging filter and have it make sense. Somewhere out there I have a set of graphs to reply to that. Now let me see if I can find them.



This, of course, takes some explanation. The first (top) is the sine wave that results when you have ONLY the output from the DAC taht is below FS/2.

The next line adds either 2 or 4 images, I forget which (the squiggly line) and adds them to the sine wave, giving the rather odd lookign waveform.
Third line adds more.
The last line adds the first 1000 images. Notice that the result when it is added to the original signal, is the "stairstep" people whine about.

Every bit of that 'stairstep' except the original sine wave, however, results from frequencies above half the sampling rate, showing, once again, that Shannon was right.

You are welcome to grab the plot if you like.

Ugh, that's 6x10^-11, not 12 so it's circa 60 picoseconds. I do math better than arithmetic, apparently.


--------------------
-----
J. D. (jj) Johnston
Go to the top of the page
+Quote Post
Northpack
post Oct 9 2011, 11:28
Post #23





Group: Members
Posts: 455
Joined: 16-December 01
Member No.: 664



QUOTE (Woodinville @ Oct 8 2011, 03:12) *
The time resolution of a PROPERLY reconstructed PCM signal (note, if you take away the antiimaging filter the time resolution GETS WORSE!!) is approximately

1/ (2 pi fs nlevels)

for CD that is 1/( 2 pi 44100 65536).

Time reconstruction can not be perfect, because noise from quantization (by the way, also look up dithering, it's the level issue that also gets abused phenominally stupidly) creates a slight phase jitter.

That's very interesting. I never realized that it actually can't be infinite as some textbooks say oversimplifying - but of course you would run into the paradox described by knutinh if it were. Another example that everything in nature and thus in our means to represent nature has to be quantized at some level.
QUOTE
I had missed the 2pi function in 1/(2pi*quant. levels*fs), so I guess that figure would actually be closer to 55 picoseconds. Either way, pretty far below the ability of any human being to distinguish a timing difference.

That's what you think. I bet there are some audiophiles living on a quantum time scale... oh, wait, then they couldn't claim that digital is bad because it's discrete wink.gif

This post has been edited by Northpack: Oct 9 2011, 11:46
Go to the top of the page
+Quote Post
Woodinville
post Oct 9 2011, 11:45
Post #24





Group: Members
Posts: 1402
Joined: 9-January 05
From: JJ's office.
Member No.: 18957



QUOTE (Northpack @ Oct 9 2011, 03:28) *
That's very interesting. I never realized that it actually can't be infinite as some textbooks say oversimplifying.


Well, consider, there is always noise, and the signal slope is not infinite, there has to be some error. Not much, maybe, but some.

Having infinite slope means having infinite frequency, and that last quantum that takes up the mass-energy of the entire universe kinda gets to be a problem, and that's still not infinite.

So, in the real world, nothing is perfect, including "nothing".


--------------------
-----
J. D. (jj) Johnston
Go to the top of the page
+Quote Post
FreaqyFrequency
post Feb 12 2012, 23:47
Post #25





Group: Members
Posts: 58
Joined: 4-October 11
From: VA Beach, VA
Member No.: 94145



So I was flipping through some of my documents as I was working on another assignment today, and I realized that I had saved the original outline from this speech. For anyone who is interested, here it is:

https://docs.google.com/document/d/1QmlxQ-L...jJGk6-ocak/edit

I didn't get to cover all of the points in it for the aforementioned reason that I was grossly overtime by the time I got to the end, but that was my blueprint for it.


--------------------
FLAC -2 w/ lossyWAV 1.3.0i -q X -i
Go to the top of the page
+Quote Post

2 Pages V   1 2 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 27th August 2014 - 18:12