Concept

Sample rate — where it appears

The frequency at which a signal's value is recorded, which decides what band can be represented and what arrives folded into it. Everything above half of it is indistinguishable afterwards from something below, so a band limit before the sampler is not optional.

Named by 15 essays across 4 fields — each of them below, with the objects they name alongside it.

A 9.0 kHz input sampled at 10 kHz arrives as 1.0 kHz. computed by solving, not by drawing. The dots are the samples. The input at 9.00 kHz is above half the 10 kHz rate, and every dot also lies on the 1.00 kHz curve drawn beside it — the two sample sequences differ by 9.3e-15, which is the arithmetic and not a small effect. Nothing is attenuated and nothing is distorted: the samples are the samples of a different signal, at full amplitude, and there is no measurement of them that could say which one was there.

The frequency a sample rate invents

Every other boundary in this field is a model getting gradually worse. This one has no gradient at all: below half the sample rate a set of samples has one sinusoid through it, above half the sample rate it has another, and the two sets of numbers are identical to three parts in ten thousand billion. Nothing is attenuated, nothing is distorted, and there is no measurement of the samples that could say which signal was there.

digital · Sample rate
What the reconstruction returns, either side of 5.0 kHz. computed by solving, not by drawing. The Whittaker–Shannon sum is evaluated on the samples and compared with two things: the signal that was sampled, and the frequency the samples report. Below 5.00 kHz these are the same curve and the error is 4.88e-3 — the truncation of the sum at sixty-four samples either side, and nothing else. Above it they part: at 9.00 kHz the reconstruction is 1.59e-3 from the alias and 2.000 from the input. The small number is the interesting one. A reconstruction cannot be improved into the right answer, because it is already an exact answer to a different question.

An exact answer to a different question

The reconstruction that turns samples back into a signal is normally introduced as the thing that recovers what was there. Measured on both sides of half the sample rate it does something more interesting than failing: above the boundary it returns the alias to 1.6 parts in a thousand, which is the same accuracy it returns the input with below the boundary, and it is wrong about the input by twice the amplitude. Its error is not a degradation. It is exactness about something else.

digital · Sample rate
The sample rate each anti-alias filter demands for 80 dB. computed by solving, not by drawing. A 20 kHz passband, and each filter must be 80 dB down by the frequency that folds back into it. The required rate follows, and it is a property of the filter rather than of the converter: Bessel 3.53× Nyquist, Butterworth 2.08×, Chebyshev 1.53×. The elliptic design at a selectivity of 0.8 is refused: its equiripple stopband has a floor at -74.1 dB, which is above the requirement at every frequency, so no sample rate satisfies it. At a selectivity of 0.5 the same order needs 1.34×. The floor is the selectivity's, not the order's.

What the filter in front costs

The filter that keeps a converter honest is normally chosen for its skirt. Measured against one requirement — eighty decibels down by the frequency that folds back into a 20 kHz band — the choice is not a decibel or two of skirt but a factor in the clock: Bessel demands 3.53 times Nyquist, Butterworth 2.08, Chebyshev 1.53. And one design is refused outright, because an elliptic stopband is a floor rather than a slope and no sample rate reaches past a floor.

digital · Anti-alias
One bit, oversampled — and where the quantisation noise went. computed by solving, not by drawing. A first-order modulator is marched forward one sample at a time with a one-bit quantiser inside the loop, and the noise inside the band is read out of the transform of the error. It falls by 8.99 dB for every doubling of the oversampling ratio — measured 9.33, 10.12, 6.96, 9.54 — against 3.01 dB for plain oversampling, which is drawn beside it from the same starting point. The loop does not make less noise; it moves the noise out of the band, and at a ratio of 128 one bit is worth 9.18.

One bit, and where the noise went

Sampling faster spreads a fixed quantity of quantisation noise over a wider band, so the part inside the band of interest falls by 3.01 dB for every doubling — half a bit. Putting the quantiser inside a loop with an integrator does something different in kind: measured on a modulator marched forward one sample at a time, with its test tone inside the band the ratio is quoted over, the in-band noise falls by 8.99 dB per doubling. At an oversampling ratio of 128, one bit is worth 9.18 — and the octaves scatter by a decibel each, which is the loop telling the truth about what its error is made of.

digital · Noise-shaping
The droop a zero-order hold imposes at 48 kHz. computed by solving, not by drawing. Holding each sample for a clock period convolves the output with a rectangle, so the spectrum is multiplied by a sinc: -0.143 dB down at a tenth of the sample rate, -0.912 at a quarter and -3.922 at half — which is exactly 20 log(2/π) and contains no design decision at all. The dots are the amplitude of the fundamental read out of the transform of the staircase itself, agreeing with the closed form to 0.008%. There is also half a sample of delay, 10.417 µs here, which is the reason a held reconstruction is not a droopy copy of the signal but a droopy copy that has moved.

The staircase on the way out

A converter does not emit impulses. It holds each sample for a whole clock period, which is a convolution with a rectangle and therefore a multiplication by a sinc — 0.14 dB down at a tenth of the sample rate, 0.91 at a quarter, and 3.92 at half, which is exactly 20 log(2/π). Nobody chose that droop and it is nearly eight times the half-decibel ripple of a Chebyshev passband. Measured on the transform of the staircase itself, it agrees with the closed form to 0.008%.

digital · Reconstruction
What 10 ps of aperture jitter is worth, in bits. computed by solving, not by drawing. Samples are taken at instants displaced by a seeded Gaussian of 10 ps and the error is measured against the same sinusoid sampled exactly. The line is −20 log(2π f × jitter), which the measurement matches to 0.12 dB across three decades. The penalty is exactly twenty decibels a decade of input frequency, because the error is the signal's slope times the timing error and nothing else — so a converter holds 16 bits only up to 199 kHz and 12 bits up to 3.18 MHz. An aperture figure quoted without an input frequency states no resolution at all.

A picosecond, read as bits

Every other boundary in this collection has a frequency, an amplitude or a size on its axis. This one has a duration. A converter that samples at t + δ instead of t gets a value wrong by the slope times δ, so the damage is proportional to input frequency and to nothing else about the part: ten picoseconds holds sixteen bits up to 199 kHz and twelve bits up to 3.18 MHz, falling at exactly twenty decibels a decade. An aperture figure quoted without an input frequency states no resolution at all.

digital · Aperture jitter
A switched-capacitor low-pass driven past half its own clock. computed by solving, not by drawing. The clock is 1.00 MHz and the corner the earlier essay fitted is 1.59 kHz. The falling dashed curve is that continuous model, which knows nothing about a clock and goes on falling. The circles are the marched circuit, read at the frequency the output actually appears at. They part company past half the clock and by 992 kHz the model is 42.1 decibels wrong — an input just below the clock arrives just above direct current, in the middle of the passband, with the passband's own gain. The third curve is the exact discrete transfer function evaluated at the folded frequency, and it agrees with the march to 0.26 decibels, which is what says the march is measuring the folding rather than an artefact of itself.

The filter that samples

The rung below built a resistor out of a clock and measured two ways it is not one: a settling time, and a corner that is a capacitor ratio rather than an R–C product. Both are errors in a value and both get smaller as the design gets better. This is an error of a different kind — the arrangement is not a continuous system at all, and nothing below half the clock shows it. An input at 992 kilohertz arrives at 7.8 kilohertz with the passband's own gain, where the continuous model the rung below fitted says it is 56 decibels down.

filters · Switched-capacitor
The images a zero-order hold leaves, at 0.222 of the sample rate. computed by solving, not by drawing. A 10.67 kHz tone held at 48 kHz, with every line read out of a transform of the staircase itself. The sampled spectrum repeats at every multiple of the clock and the hold multiplies all of it by one sinc, so each image survives scaled by the sinc at its own frequency: the fundamental at -0.72 dB, the largest image (1fs−f, 37.3 kHz) at -11.60 dB, which is 10.88 dB of rejection. The sinc's nulls are exactly at the multiples of the clock and the two first-order images straddle the first of them without touching it — so the hold's rejection is 25.6 dB for a tone at 0.05 fs and 1.74 dB for one at 0.45, falling to nothing at half the clock. Measured and closed form agree to 0.026%.

The nulls are where nothing is

A zero-order hold multiplies the whole repeated spectrum by one sinc, so it attenuates every image at the image's own frequency and its nulls land exactly on the multiples of the clock. Nothing is ever at a null: the two first-order images straddle it, and the closer the signal comes to half the clock the closer they come to each other. The hold gives 25.6 dB of image rejection to a tone at a twentieth of the clock, 1.74 dB at 0.45 of it, and nothing at all at half — which is the frequency the band most needs it at.

digital · Reconstruction
Sampling 100–120 MHz: 6 allowed windows and 5 forbidden gaps. A band 20 MHz wide centred at 110 MHz, and the sample rates at which it and all its images land without overlapping. Twice the top of the band is 240 MHz and every rate above that works, which is the familiar answer. Below it there are 5 more windows, the slowest at 40.00 MHz — 1.00 times twice the band's WIDTH, which is the quantity that bounds a sample rate when the signal is not at baseband. Between the windows are 5 forbidden gaps, shaded: at 219.1 MHz the band's images overlap it, while 200.00 MHz works and 240.0 works. So a clock raised out of a working window has been made worse by being made faster, and "a faster clock is always an available answer" is a statement about baseband and not about sampling.

The clock that is too fast

Every sample rate in the requirement is a lower bound: the filter must be down by the frequency that folds back, and a faster clock is always at least as good. That holds for a signal at baseband. A band from 100 to 120 megahertz can be sampled at 240 and above, or at 120 to 200, or 80 to 100, or 60 to 66.7, or 48 to 50, or 40 — six disjoint windows with five forbidden gaps between them, so 110 megahertz fails while 100 works and 120 works. The bound is twice the band's width, 40 megahertz, and it is six times below twice its top.

digital · Anti-alias
With the period 1.3% long, eight periods read a sine 0.599% wrong through a rectangle, 79.4 ppm through a triangle, 22.8 ppm through a Hann window. Integrated over each weighted window, the worst over every starting phase. The error in a sine's root-mean-square summed over N assumed periods 1.3% too long, against N, for four weights across the window. The rectangle is the plain sum: 0.640% at two periods and flat in N, δ/2 as the earlier measurement found. The triangle is flat in N too but 75 times smaller at eight periods. The Hann window falls with N, as the −2.67 power: 414 ppm at two periods, 0.293 ppm at thirty-two. The four-term Blackman–Harris is below 4.85 ppm at every count from two. A weight that falls to zero at the window's ends counts the extra sliver of period at almost nothing.

The window that forgives the period

A converter that sums a waveform's square over whole periods reads its RMS exactly, and one that sums over periods 1.3% too long reads a sine 0.6% wrong — δ/2, for any number of periods — because the extra sliver of period counts at full weight. Weight the window down to zero at its ends and the sliver barely counts. Over eight periods a triangular weight reads the same sine 79 ppm wrong and a Hann weight 23 ppm; and they are different kinds of cure. The triangle is the only one that changes the error's order, from first to second in δ, so it wins when the period is nearly right; the Hann weight keeps first order but falls with the number of periods, about as its inverse square, so it wins over long windows. Both cost nothing with the period exact — from two periods up. Over one, a Blackman–Harris weight reads even a sine 10% wrong. The price is noise: a Hann-weighted reading of noise scatters √1.5 as widely.

power · Rms and average
At 60 dB of rejection an eighth-order filter keeps 3 of the brick wall's 6 windows; a fourth-order one keeps 2. computed by solving, not by drawing. The sample rates at which a band from 100 to 120 MHz can be sampled without anything the filter in front passes at more than −60 dB folding onto the band, for a band with hard edges and for Butterworth bandpass filters of order 12, 8, 6 and 4 on the band's own edges; each row is labelled with the span, in megahertz, where the filter is still above −60 dB. A real filter moves each window's edges inward by half its transition band. The window from 120 to 200 MHz narrows to 124.4–193.2, 127.9–188.4, 132.8–182.4, 149.7–166.9 MHz as the order falls, and the lower windows close altogether. Every window is checked by folding every frequency the filter passes.

The windows a real filter leaves

A band from 100 to 120 MHz can be sampled at any clock in six disjoint windows — for a band with hard edges. Put a real bandpass filter in front and ask that whatever folds onto the band be 60 dB down, and every window's edges move inward by half the filter's transition band: an eighth-order Butterworth keeps three of the six, a fourth-order one two, and the window from 120 to 200 MHz shrinks from ±25 per cent of clock tolerance to ±19.1 per cent at order eight and ±5.4 per cent at order four. The windows depend on the rejection only through the rejection per order: 40 dB at order four, 60 at order six and 80 at order eight all leave the same ±15.7 per cent. So a filter's order is bought in clock tolerance, at one order per ten decibels.

digital · Anti-alias
Sampled at 100 kHz, the loop repays its whole debt below 50.0 kHz: 6.60 kHz·Np each side, with a peak of 8.72 dB — the continuous loop had repaid 89% by then. computed by solving, not by drawing, from the loop's exact zero-order-hold equivalent. The three-pole amplifier of the area essay (second pole 4 kHz), closed through a sampler and hold at 100 kHz. The device sensitivity, in decibels, against linear frequency from zero to half the sample rate, where the discrete response ends. Margin 24.7° at a crossover of 5.71 kHz, against 34.9° for the continuous loop; peak +8.72 dB at 6.45 kHz. The area below zero is 6.598 kHz·Np and the area above, all of it inside the band, 6.598; net 1.84 × 10⁻² Hz·Np. The continuous loop, by 50.0 kHz, had repaid 88.6% of its own.

The band a sampled loop repays in

Close the three-pole amplifier's loop through a sampler and hold at 100 kHz and Bode's sensitivity integral still balances — but only over the band below 50 kHz, because that is all the band a sampled loop has. The whole debt, 6.60 kHz·Np, is repaid there; the continuous loop had repaid 88.6% of its own by the same frequency and spends decades above on the rest. Below a tenth of the sample rate the sampled loop is the continuous loop with half a sample of delay, 24.7° of margin against 24.6°. And the finite band turns the equality into a floor: hold the sensitivity 20 dB down over a third of the band and no loop can peak below 10 dB. This loop's floor is low and its margin sets its peak; the sample rate at which the peak is 3 dB above the continuous loop's is 18 times the crossover.

feedback · Desensitivity
A sinusoid sampled 8 times a cycle, at the phase that puts its peak between two samples. computed by solving, not by drawing: the samples of a unit sinusoid at 8 a cycle, synchronous, at the sampling phase that hides its peak worst. 8 samples a cycle is 4 times the Nyquist rate and holds the waveform completely; the largest sample is still 0.9239, 7.61% below the peak, which is 1 − cos(π/8). Read straight off the samples the peak needs 22.2 samples a cycle for 1% and 70.2 for 0.1%.

The rate each reading needs

Twice the frequency is the rate at which a set of samples holds a sinusoid completely, and it is not the rate at which any particular property can be read off them. Eight samples a cycle — four times the Nyquist rate — hold the waveform, and their largest is still 7.61% below the peak; the largest sample needs 22.2 a cycle for 1% and 70.2 for 0.1%, because its error falls only as the square of the rate. A parabola through the three largest gets 1% at 8. A zero crossing found by a straight line between two samples is a hundredth of a cycle right at 5 a cycle, its error falling as the cube, because a sine is straight at its zero. The rms of whole cycles is exact from three a cycle — and at exactly two it reads anything from zero to √2. A slow rate with a long record of a steady signal does what a fast rate does, once the samples have slipped a whole interval past it: 42 cycles at 4.0236 a cycle.

digital · Sample rate
Three waveforms at 16 samples a period, sampled at the worst instant: the largest sample of a sine is 1.92% short, of a triangle 12.5%, of a clipped sine 0. computed by solving, not by drawing: three waveforms with the same period and the same peak, sampled 16 times a period at the phase that puts the peak midway between two samples (dots). The sine leaves its peak as the square of the time, the triangle in proportion to it, and the sine clipped at nine-tenths of its height does not leave it at all for as long as it stays flat. The largest sample therefore falls short by 1.92% for the sine, 12.5% for the triangle, 0 for the clipped sine, at one rate, for three waveforms with the same period.

The peak that is a corner

The largest of a set of samples falls short of a sine wave's peak as the square of the sample interval, and that law belongs to the sine. Measured over every sampling phase, a triangle's corner falls short as the first power, 12.5 per cent at sixteen samples a period against the sine's 1.92, a peak whose curvature vanishes as the fourth power, and a sine clipped at nine-tenths of its height reads exactly above seven samples a period. The order in which a waveform leaves its peak is the whole of the law, and it also fixes how much better the average reading is than the worst. A real corner is round at some scale, so the law bends where the samples resolve its top harmonic, and a parabola through three samples helps a round peak, barely touches a corner and makes a flat one worse.

digital · Sample rate
A Gaussian edge read at 3 samples per rise, at the worst sampling phase: straight chords between the samples say the rise is 8.78% from its true value. computed by solving, not by drawing: a Gaussian edge (solid), its samples at 3 per 10–90% rise at the sampling phase that reads worst (dots), and the straight lines an instrument's linear interpolation draws through them (dashed). The chord crosses 10 and 90 per cent earlier and later than the edge does, because a Gaussian edge curves in opposite senses at the two thresholds. The reading is 1.0878 rises against 1.

The samples a rise time needs

A rise time is read from two thresholds, and an instrument that draws straight chords between its samples is wrong at each by an amount that goes as the square of the interval. For a Gaussian edge at the worst sampling phase that is 5.02 per cent at four samples per rise and 0.818 at ten; the rule of thumb of three to five is a five per cent rule, and one per cent takes nine. The reading is not monotonic in the rate: above 20.9 per rise a first-order edge reads exactly at whole numbers and 0.046 per cent at 24.5, because its two errors subtract at one phase, and a Gaussian edge reads worse there because its two add. Reconstructing before reading needs 1.87 per rise for one per cent, and at four times the edge's 3 dB bandwidth the reading is still 11.7 per cent out.

digital · Sample rate

Named alongside it

The objects these essays reach for when they reach for this one.

AliasingModel rangeNyquist rateReconstructionConvergence orderAnti-alias filterOversamplingZero-order holdEffective bitsTrue-rmsAnti imaging filterAperture jitter

All concepts