Please take a look at the Digital Show and Tell video by Monty Montgomery of Xiph.org on band limiting, starting at 17:20.A perfectly band limited square will not produce any ripple at all. If it does it is not band limited enough. At least that is my experience with real DAC filters, not simulations.
The result is because the non bandlimited square wave. And the result is desirable because of the brickwall low pass filter. If you want to produce better square wave, the only way is to increase sampling frequency. If you use slow roll of or something similar you will have severe imaging being the interpretation of the input digital signal is non-unique.OK. A quick change to use a band limited square wave. Results are below. The minimum phase filters still produce higher ripples.
View attachment 33376
Gibbs effect is fundamentally caused by limited bandwidth. It will always be there in digital signaling because sampling frequency is always a fixed value. And in a bandwidth limited system, Gibbs effect is considered ideal/expected.Ripple & ringing seem to be used interchangably to refer to any periodic passband amplitude variation, whether the Gibbs effect of linear phase filters or the greater ripple of minimum phase filters.
Yes, the ripples are not added at all, they are an artefact of limiting the bandwidth. Those signal components are always there, but they are exposed in a finite bandwidth systemGibbs effect is fundamentally caused by limited bandwidth. It will always be there in digital signaling because sampling frequency is always a fixed value. And in a bandwidth limited system, Gibbs effect is considered ideal/expected.
The real story starts around 19:00. And then you should look at interpolations, sinc interpolation.Please take a look at the Digital Show and Tell video by Monty Montgomery of Xiph.org on band limiting, starting at 17:20.
Yes, but there is no horizontal scale so it is impossible to tell! I would expect all of the signals to have the same rise time if they are all limited to the same bandwidth, and it seems to show that.The example in that video is not the point. What you show is not really 'ripple', but ringing. A bandlimited square should show noticable rise times. Your results above with a 'bandlimited square' indicate the rise time is still near perfect, so - as expected - the ringing is still there.
You can see this happening in my examples too. The min phase filter overshoots the step by a bigger margin. In my case, about 3 dB more. The ripple is close to Nyquist so clipping is not a practical concern with music.
Sure you can band limit (or more precisely, low pass filter) a square wave so that it has no overshoot. But the frequency response of such a filter will have significant roll off in the pass band, and that makes it a poor anti-alias filter. The key performace criteria of the AA filter is to keep as much of the waveform intact as possible for the contents with frequencies below Nyquist but reject as much as possible for those above it.Here's a square wave band-limited such that there's no overshoot or ripple. @NTK, your filters should all look pretty much the same on this.
Sure you can band limit (or more precisely, low pass filter) a square wave so that it has no overshoot. But the frequency response of such a filter will have significant roll off in the pass band, and that makes it a poor anti-alias filter. The key performace criteria of the AA filter is to keep as much of the waveform intact as possible for the contents with frequencies below Nyquist but reject as much as possible for those above it.
However, @mansr's "square looking wave" is not the only band limited signal that resembles a square wave. Here I created a band limited 2 kHz square wave (blue curve) by summing only the first 5 terms of the expanded sine series (i.e. 2 kHz fundamental, 6 kHz 3rd harmonic, 10 kHz 5th harmonic, 14 kHz 7th harmonic and 18 kHz 9th harmonic). This is a totally legitimate band limited signal with no spectral contents above 20 kHz.@mansr's square wave is limited to (odd) harmonics below Nyquist, hence a "legal" input signal.
If the goal of the exercise is to look at ringing, well of course an "illegal" signal will show the effects of being convolved with a band-width limited system.
My point is that this phase distortion eats into the available headroom of the output circuitry.
The point I made earlier was that the analog circuitry should anyway have at lest 3 dB headroom to deal with inter-sample peaks
True - and a surprising number of products with DACs in them don't have this analogue-stage headroom.
Isn't the overshoot (when a clipped audio sample is present for instance) not a question of digital reconstruction filtering before or in the DAC chip?
So both the digital and analog parts should have enough headroom to allow for this.