Hacker News new | ask | show | jobs
by cnvogel 3287 days ago
A DAQ that reconstructs a perfect square wave (or a perfect stair-step function) is employing a "Zero Order Hold", and it would make a god-awful audio DAC.

https://en.wikipedia.org/wiki/Zero-order_hold

With a 0OH you'd gain the ability to potentially reconstruct a infinite bandwidth signal (the squarewave), which is irrelevant in the audio case: With a 10kHz squarewave, the next harmonic would be at 30kHz which is already waaaay out of the human range of hearing.

But limiting the bandwidth of a DAC (or ADC) is the fundamental property which causes it to be able to perfectly reproduce the frequencies within its bandwidth (~up to 20kHz in HiFi Audio), so that's desirable. And the "ripples" on top of a squarewave are just the manifestation of this property: If you cut away the frequencies above Nyquist, you get a rippled squarewave. And conversely if you compute the difference between the perfect squarewave and the "rippled" squarewave you get out of an Audio DAC this only contains (non-audible) energy outside of the bandwith of the DAC!

1 comments

Sure. But you're still talking about the analog portion of the circuit. If the analog output of a digital recording - supposedly the input was a near-perfect square wave - is different from the analog output of an analog recording, and neither looks like the input signal, then it is a) certainly possible to make an analog output stage that produces a more precise output that better matches the input, and b) possible to make an output that better matches the analog output. Remember, the input was supposedly a perfect square wave, and contained inaudible components. The recording/playback component had nothing to do with the fact that you can't hear the entire spectrum.

All the limitations are in the analog phase. As you point out, it depends on the design tradeoffs in the DAC, amplifiers, etc, and that's an important lesson to learn in the class that was being taught. Nevertheless, the point I was replying to is the claim that the digital representation could not represent a square wave. That's certainly not true, and no Fourier transforms are necessary to demonstrate it. A PCM recording is just a series of impulses, not a series of sine waves.