Library / Signal processing and digital filters / DSP-03
Signal processing and digital filters
Zero-order hold amplitude droop
Magnitude response of an ideal digital-to-analogue converter that holds each sample for exactly 1/fs, normalised to its value at DC.
- Ref
- DSP-03
- Rev
- v1
- Field
- Signal processing and digital filters
- Result
- G
A zero-order-hold DAC repeats each sample for 1/fs seconds. This is a convolution with a rectangle, so the output spectrum is multiplied by a sinc: G(f) = |sin(πf/fs)/(πf/fs)|. The droop reaches 3.9 dB at the Nyquist frequency, and the gain is zero at multiples of fs. Reconstruction filtering and the half-sample delay of the hold are not included.
Magnitude response of an ideal digital-to-analogue converter that holds each sample for exactly 1/fs, normalised to its value at DC. The normalised sinc is sinc(x) = sin(πx)/(πx), with sinc(0) = 1. Reconstruction filtering and the hold delay of half a sample are not included.
Calculator
- Droop at this frequency−0.9121 dB
- First null of the hold response1,000 Hz
- Gain at the Nyquist frequency, 2/π0.6366
What drives the result
Each variable is moved across its typical range while the others stay at the values above. The longest bar is the key driver.
- A tone at 250 Hz comes out of a 1,000 Hz DAC at 0.9003 of its ideal amplitude, a loss of 0.912 dB.
- At the Nyquist frequency the hold gives 2/π = 0.637, a droop of 3.92 dB, which is why high-quality DACs oversample or use an inverse-sinc equaliser.
Chart data as tables
Ranked variables
| Variable | Typical range | Lowest result | Highest result | Swing () | Local step | Change in result |
|---|---|---|---|---|---|---|
| f Frequency | 0 to 5,000 Hz | 3.898e-17 | 1 | 1 | +10% | −2.24 % |
| fs Sampling rate | 100 to 1,000,000 Hz | 0.004754 | 1 | 0.9952 | +10% | +1.87 % |
Sweep of Frequency
| Frequency (Hz) | Gain relative to DC |
|---|---|
| 0 | 1 |
| 625 | 0.4705 |
| 1,250 | 0.1801 |
| 1,875 | 0.06497 |
| 2,500 | 0.1273 |
| 3,125 | 0.03898 |
| 3,750 | 0.06002 |
| 4,375 | 0.06722 |
| 5,000 | 3.898e-17 |
Sweep one variable
Variables and how each one contributes
Gain relative to DC
What the equation gives you. Everything else feeds it.
Frequency
The signal frequency, in Hz. Higher frequencies are attenuated more, with a null at fs. Raising it by 10 % (to 275) moves the result by −2.24 %, from 0.9003 to 0.8802.
Sampling rate
The sampling rate, in Hz. A higher rate moves a given frequency closer to DC on the sinc curve and lowers the droop. Raising it by 10 % (to 1,100) moves the result by +1.87 %, from 0.9003 to 0.9172.
Worked example with the values above
- Argument: f/fs = 250 / 1,000 = 0.25.
- sinc: sin(π × 0.25) / (π × 0.25) = 0.70711 / 0.7854.
- G = 0.90032.
Assumptions and limits
- Uniform sampling at a fixed, known rate with a clean, stable clock unless the page names a jitter term.
- Ideal, linear converters and a signal that stays inside full scale.
Common mistakes
- Using a frequency above fs/2, which aliases to a different baseband frequency.
- Mixing hertz with radians per second or rad/sample.
- Counting jitter or quantisation as the only noise source and forgetting thermal and clock noise.
Statistics and uncertainty
Real converters add offset, gain error, nonlinearity and thermal noise to the ideal quantisation and jitter limits, so a measured SNR is typically 3 dB to 10 dB below the ideal figure. Treat these formulas as upper bounds on performance.
Where it is used
- Generating test signals and predicting what a converter can resolve.
- Choosing a sampling rate, a bit depth and a clock source for an acquisition chain.
Maths you need
- Sampling theorem: a signal bandlimited below fs/2 is fully described by its samples
- Decibel: dB = 20 log₁₀ of an amplitude ratio
- Nyquist frequency: half the sampling rate