Where a signal becomes a number

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.

Assumes: The frequency a sample rate invents · One step, computed twice

The rate each reading needs closed on the question every oscilloscope specification answers with a rule of thumb: how many samples per rise time give a rise-time reading to a stated accuracy? It predicted the form of the answer. A crossing interpolated between two samples is exact at an inflection, where a chord and a curve share a slope and a value, and this was the reason a zero-crossing reading in that essay was so good. A ten-to-ninety per cent reading has no inflection at either threshold, so its error should fall only as the square of the rate. The peak that is a corner has since shown what happens to a square law when the waveform changes, and rises are a good place to apply that lesson, because a rise time is a difference between two readings with one sampling clock.

The rule of thumb is usually three to five samples on the rise. The form of the answer is what the prediction said it would be. Its constant, and especially its structure, are not what a rule of thumb can capture. A rise-time reading turns out to depend on a whole number in a way a peak reading does not, a first-order edge has a corner very close to one of its thresholds, and the most quoted sampling rule fails on the very edge used to justify it.

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 valuecomputed 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.00.1000.5000.9001-1.50-1-0.50000.50011.50time, in the edge's own 10–90% riseover the final valuethe edgeGaussianchordslinear interpolationsamples per rise3reading, worst phase8.78%solved, then checked — worst sampling phasecurving apart at both thresholds
Fig. 1 A Gaussian edge (solid), its samples at 3 per 10–90% rise at the sampling phase that reads worst (dots), and the straight chords a linear interpolation draws through them (dashed). The chords cross 10 and 90 per cent away from the edge in opposite directions. The reading is 8.78% long at 3 per rise; the slider runs from 18.9% at 2 to 0.818% at 10.

Three edges, each in its own units

Three edges cover what a rise commonly looks like. A first-order edge, 1−e−t/τ1 - e^{-t/\tau}, is what any RC network gives, and it has a sharp corner at the start. A Gaussian edge is an error function, which is what a cascade of many similar poles tends to, and it has no corner anywhere: the delay a chain adds measures exactly that limit, and the instrument’s own rise time uses it as the model of an instrument’s front end. A raised cosine is a compact edge with a definite start and end, the shape of a controlled-slew digital driver.

Time is measured in each edge’s own 10–90 per cent rise, so a rate is stated in samples per rise and the three are directly comparable. The reading is what a digitising instrument does by default: find the pair of samples straddling each threshold, draw a straight line between them, and take where the line crosses. The two crossings are subtracted. Every error below is a worst case over the sampling phase, the position of the sample clock relative to the edge, because a single-shot edge gets one phase and no choice of it.

An error at each threshold

Between two samples a distance Δ\Delta apart, the chord differs from the curve by x(1−x)Δ2v′′/2x(1 - x)\Delta^2 v''/2, where xx is where in the interval the threshold falls, and in time that is x(1−x)Δ2v′′/2v′x(1-x)\Delta^2 v''/2v'. The second derivative decides everything. On a Gaussian edge at 10 per cent the curve is bending upward and at 90 per cent downward, by the same amount, so the chord crosses 10 per cent early and 90 per cent late, and both errors lengthen the reading. They add. On a first-order edge v′′/v′v''/v' has the same value at every point of the curve, so the errors have the same sign at both thresholds and are in position to cancel.

Since the two thresholds share a sampling clock, the phase xx at one fixes the phase at the other. They differ by the number of intervals in the rise, modulo one, so the reading is a function of the phase with that offset built into it.

At 4 samples per rise the reading depends on where the samples fell: a first-order edge reads from 0 to 8.38%, a Gaussian from 0 to 5.02%. computed by solving, not by drawing: the error of the reading from straight chords at 4 samples per rise against the sampling phase, for three edges. first-order: 0 to 8.38%; Gaussian: 0 to 5.02%; raised cosine: 0 to 3.88%. Each threshold's chord is wrong by x(1 − x)Δ²·v″/2v′ at its own phase within the interval. Two thresholds share a sampling clock, so their phases differ by a fixed amount set by the rise's length in intervals, and the reading is the difference of two such errors. A first-order edge is worse at this rate than its curvature says, because it crosses 10 per cent only 0.0480 of a rise after its starting corner, and at 4 per rise an interval can straddle the corner.
Fig. 2 The error of the reading from straight chords at 4 samples per rise against the sampling phase, for three edges. First-order: from nothing to 8.38%. Gaussian: nothing to 5.02%. Raised cosine: nothing to 3.88%. At this rate every edge has a phase at which the reading is exact and a phase at which it is several per cent long.

The figure’s range is the point. At four samples per rise, a rate well inside the rule of thumb, the same edge reads exactly at one sampling phase and 5.02 per cent long at another. A set of repeated single-shot readings of one Gaussian edge at this rate therefore scatters over five per cent, all of it upward, with no noise on it at all. That is a spread a user will take for noise and try to average away; averaging will reach the mean, which is itself biased long, by an amount that does not vanish.

The first-order edge reads worse here than its curvature predicts, and the reason is that it is the only one of the three with a corner. It crosses 10 per cent at 0.0480 of a rise after its start, so at four per rise the interval holding the threshold also holds the corner. A chord across a corner has nothing to do with the second derivative, and that is what the 8.38 per cent is.

A comb at the whole numbers

Move the rate far enough up that the intervals clear the corner, at 1/0.0480=20.91/0.0480 = 20.9 samples per rise, and something a peak reading did not have appears. A whole number of intervals in the rise puts the two thresholds at the same phase. A first-order edge’s two errors then have the same sign and the same size, and the difference is zero.

The error is not monotonic in the rate: a first-order edge reads 0 at 24 samples per rise and 0.0457% at 24.5, and a Gaussian one reads worse at the whole number. computed by solving, not by drawing: the worst error of the rise-time reading over every sampling phase, against the samples per rise, for a first-order edge and a Gaussian edge. First-order: 20: 0.00214%, 22: 0, 24: 0, 24.5: 0.0457%, 26: 0, 26.5: 0.039%, 30: 0, 30.5: 0.0292%. Gaussian: 24: 0.142%, 24.5: 0.105%, 30: 0.0912%, 30.5: 0.0675%. With a whole number of intervals in the rise, both thresholds fall at one sampling phase. A first-order edge has the same v″/v′ everywhere, so its two chord errors then subtract to nothing; a Gaussian edge has opposite curvature at the two thresholds, so they add. The comb begins only near 20.9 per rise, where the 10 per cent threshold's interval stops straddling the edge's starting corner, and a rise that is not known in advance cannot be arranged to fall on it.
Fig. 3 The worst error of the rise-time reading against the samples per rise, for a first-order edge (solid) and a Gaussian edge (dashed), over every sampling phase. The first-order edge reads nothing measurable at 22, 24, 26 and 30, and 0.0457% at 24.5, 0.039% at 26.5 and 0.0292% at 30.5. The Gaussian edge goes the other way: 0.142% at 24, 0.105% at 24.5. The vertical line is where the threshold’s interval clears the first-order edge’s starting corner.

So the first-order edge’s error is a comb. It falls to nothing at each whole number, at every phase, and rises between them: 0.0457 per cent at 24.5, and nothing to the precision of the arithmetic at 24. A Gaussian edge inverts it, because its two errors have opposite signs and a whole number makes them add at the same phase. It reads 0.142 per cent at 24, and 0.105 at 24.5, where the worst phases of the two thresholds no longer coincide.

A comb like that has no practical use for setting a rate, since the rise being measured is unknown and it is what the measurement is for. It matters for a different reason: an instrument reading a known calibrator edge, with a rise that happens to be a whole number of its sample intervals, gets a far better number than it will get on anything else, and it gets that number on a first-order calibrator with a clock in a round ratio. It is a good way to convince oneself of the accuracy of a measurement. The figure says how much of that accuracy is arithmetic.

Below the corner rate there is no comb at all. At 16 per rise the first-order edge reads 0.097 per cent and the whole number offers nothing. This is the same structure the peak that is a corner found: the law at a given rate is a statement about what lies inside one sample interval, and the corner at the start of a first-order edge is inside it until 20.9 per rise.

The bill in samples per rise

To compare edges fairly the comb has to be set aside, and half-integer rates do that, sitting between its teeth. The worst error at those rates falls as a clean square law on all three, with slopes of 2.00, 2.01 and 2.02 by the top of the range.

Linear interpolation's bill in samples per rise: for a Gaussian edge, 4.0 for 5%, 9.0 for 1% and 28 for 0.1%, the error falling as the square of the rate. computed by solving, not by drawing: the worst error of the reading from straight chords against the samples per rise, at half-integer rates so that no edge is helped by the comb, for three edges. first-order: slope 2.00; 5.1 per rise stays inside 5%, 10.0 inside 1%, 18 inside 0.1%; Gaussian: slope 2.01; 4.0 per rise stays inside 5%, 9.0 inside 1%, 28 inside 0.1%; raised cosine: slope 2.02; 3.2 per rise stays inside 5%, 7.9 inside 1%, 24 inside 0.1%. The stay-inside rate is walked down from a hundred until the error first leaves the band, so it counts every tooth of the comb. A rule of thumb of three to five samples per rise is a five per cent rule.
Fig. 4 The worst error of the reading from straight chords against the samples per rise, at half-integer rates, for three edges. All three slopes reach 2.00–2.02. To stay inside 5%: first-order 5.1 per rise, Gaussian 4.0, raised cosine 3.2. Inside 1%: 10.0, 9.0 and 7.9. Inside 0.1%: 18, 28 and 24.

The stay-inside rate is what a specification would have to quote, found by walking down from a hundred per rise until the error first leaves the band, so that no tooth of the comb can flatter it. For five per cent a Gaussian edge needs 4.0 samples per rise, a first-order edge 5.1 and a raised cosine 3.2. For one per cent they need 9.0, 10.0 and 7.9. For a tenth of a per cent they need 28, 18 and 24.

So the rule of thumb has its size at last: three to five samples per rise is a five per cent rule. It is a reasonable rule for that purpose, with one proviso, which is that the same reading will scatter over the whole of those five per cent from shot to shot. An engineer who wants one per cent needs twice the upper end of it, and an engineer who wants a tenth needs more than five times the upper end.

The order of the edges also swaps across the table. At five per cent the first-order edge is worst, because its corner is inside the interval. At a tenth of a per cent it is the best of the three, because by then the corner is cleared and the errors partly cancel across the rise. Which edge is hardest to read depends on how well it is being read.

Reconstruction changes the sum

A straight chord is the cheap reading, and an exact answer to a different question measured the expensive one. A reconstruction sum through the samples returns the waveform between them, and many oscilloscopes do this by default under the name sin(x)/x, after which the thresholds are found on the reconstructed curve. If the edge’s spectrum lies below half the sample rate, the reconstruction is exact and the reading has no sampling error at all, so the question moves from curvature to bandwidth.

A Gaussian edge of rise trt_r has a 3 dB bandwidth of 0.332/tr0.332/t_r, and the most common sampling rule for such instruments is a sample rate of four times the bandwidth. That is 1.33 samples per rise, far below anything the chord could tolerate, and it is the number the rule of thumb’s reconstruction advocates quote. It is worth measuring.

Reconstruct first and a Gaussian edge needs 1.87 samples per rise for 1% against a chord's 9.0, which is 5.6 times its 3 dB bandwidth; at four times that bandwidth it still reads 11.7%. computed by solving, not by drawing: the worst error of a Gaussian edge's rise-time reading against the samples per rise, by straight chords (solid) and by a windowed sinc reconstruction bisected at each threshold (dashed, dots). 0.7: 129%, 92.2%; 0.8: 100%, 68.5%; 0.9: 78.6%, 50.6%; 1: 61.7%, 37%; 1.1: 48.4%, 26.7%; 1.2: 37.8%, 18.9%; 1.4: 36%, 8.8%; 1.6: 31.1%, 3.48%; 2: 18.9%, 0.606%; 2.5: 11.8%, 0.175%; 3: 8.78%, 0.0212%; 4: 5.02%, 0. A Gaussian edge of rise tr has a 3 dB bandwidth of 0.332/tr, so a sample rate of four times that bandwidth, a common oscilloscope rule, is 1.33 per rise. A Gaussian spectrum has no edge: at half that sample rate it is still at 25% of its low-frequency level, and what lies above aliases into the edge where no reconstruction can return it. The reading needs 5.6 times the bandwidth for 1 per cent.
Fig. 5 The worst error of a Gaussian edge’s rise-time reading against the samples per rise, by straight chords (solid) and by a windowed sinc reconstruction bisected at each threshold (dashed, dots). At 2 per rise: 18.9% and 0.606%. At 3: 8.78% and 0.0212%. For 1%: 9.0 and 1.87 per rise. The vertical line is four times the 3 dB bandwidth, 1.33 per rise, where the reconstruction is still 11.7% out.

The reconstruction is a very large improvement everywhere it works: 0.606 per cent against the chord’s 18.9 at two samples per rise, and 0.0212 per cent against 8.78 at three, a factor of four hundred at the same rate. For one per cent it needs 1.87 per rise against 9.0. All of that is what reconstruction is sold on, and rightly.

It also has a cliff that a chord does not. At 1.33 per rise, the rule’s rate, the reading is 11.7 per cent out at the worst phase, which is not the “plenty of margin” the rule suggests. The reason is the Gaussian shape of the spectrum: it has no edge. At half that sample rate it is still at a quarter of its low-frequency amplitude, and everything above it folds back into the band and into the edge, in a phase-dependent way that no reconstruction can undo. It is not noise, but the frequency a sample rate invents in another form. For one per cent a Gaussian edge needs 5.6 times its 3 dB bandwidth.

Real instruments mostly do not have a Gaussian front end at this rate, since a designer choosing four times the bandwidth chooses a sharper roll-off to go with it, and a brick-wall filter has a much smaller spectrum above Nyquist. That sharper roll-off carries an overshoot and a group delay of its own, which is a reading error of a different kind, and the corner that says nothing about an edge measures how little a 3 dB figure tells anyone about that. So the choice is not really between a rule that is right and one that is wrong. It is between two ways of paying for a rise-time reading, either in sample rate or in the shape of the filter ahead of it.

One instrument, three edges

A worked case puts these on one bench. A 10 GS/s instrument reads a 1 ns Gaussian edge at ten samples per rise, and a chord reads it 0.818 per cent long at worst, which a user would accept. The same instrument reads a 200 ps edge at two samples per rise, where a chord is 18.9 per cent out and a reconstruction 0.606. And a 150 ps edge, at 1.5 per rise, has moved past where either is believable, since the reconstruction is above three per cent and rising steeply. So between a nanosecond and 150 ps the choice of interpolation goes from immaterial to decisive, and in the last step no interpolation is enough. A menu setting labelled linear or sin(x)/x is deciding a factor of thirty in the reading’s accuracy at the rate where it first starts to matter.

Which reading is being asked for

Worth separating is what each error means to whoever is reading it. The first figure’s 8.78 per cent at three per rise is a reading about one edge at one phase. An instrument in equivalent-time mode, averaging repeated edges with a jittered clock, gets every phase and reaches the mean over them. That mean is still long on a Gaussian edge, since the curvature’s bias is one-sided, but with a smaller worst case, and reconstruction removes it altogether. The instrument’s own rise time measures the other route by which an instrument lengthens an edge: its own bandwidth adds in quadrature, and that error is independent of the sampling and has to be budgeted separately. A rise that reads 5 per cent long at four per rise, with a front end three times as fast as the edge adding another 5.4 per cent, is a reading about ten per cent long, and no setting of the instrument says so.

There is also a connection worth drawing to the boundary that is a rise time, which argued that a rise time is the quantity a layout should be designed against. A boundary computed from a reading ten per cent short of a true edge moves by the same ten per cent in length, and a rule that a designer takes off a scope inherits it.

What the sampling left out

The samples here are exact, with no noise and no aperture. Noise changes the reading twice over, since noise on a sample moves a threshold crossing by the noise over the slope, and the slope is what the 10 and 90 per cent levels have least of. At a stated signal-to-noise ratio there is a rate above which the reading no longer improves, because the sampling error has fallen below the noise’s, and it is likely to be well below nine per rise. Quantisation has a related effect on the thresholds, with its own floor, and six decibels a bit gives its scale.

The edges are ideal in another way: each is monotonic and has no overshoot. An edge with an overshoot has a 90 per cent crossing on a steeper part of its curve and possibly more than one of them, which changes the reading’s definition rather than its accuracy.

The numbers worth carrying

Read through straight chords at the worst sampling phase, a Gaussian edge is 18.9 per cent out at two samples per rise, 5.02 at four and 0.818 at ten; three to five is a five per cent rule, one per cent takes nine, and a tenth takes twenty-eight. The error falls as the square of the rate, except that a first-order edge reads exactly at a whole number of intervals above 20.9 per rise and a Gaussian edge reads worse there. Reconstructing the edge first needs 1.87 samples per rise for one per cent, 5.6 times its 3 dB bandwidth, and at the usual four times that bandwidth the same reading is 11.7 per cent out.

Still open: a noisy edge, an edge that overshoots, and a bandwidth and a rate chosen together

The rate at which noise takes over. A threshold crossing moves by the noise over the slope. Past some rate that term is larger than the chord’s, which is falling as the square, and a higher rate buys nothing unless the noise is filtered, which a reconstruction does and a chord does not. Where that crossing lies for a stated signal-to-noise ratio, and whether a reconstruction’s benefit survives it, is the measurement that would finish the rule of thumb.

An edge that overshoots. A filter sharp enough to make the four-times rule honest puts an overshoot on every edge it passes, and a reading from a reconstructed curve then measures the filter’s rise as much as the signal’s. Whether a Bessel-like or Butterworth-like front end gives the better reading at a stated sample rate is a comparison of two errors that move in opposite directions.

A rate and a bandwidth chosen as a pair. An instrument’s designer picks both. There is an optimum between the aliasing error, which falls as the bandwidth falls, and the instrument’s own rise, which grows, and it says how far an instrument’s own bandwidth should sit below half its sample rate for rise-time work. That optimum is a function of the edge being read, and how much the choice costs on an edge of a different shape is the part worth measuring.

Part 5 on sample rate

One argument about Sample rate, and one of 5 essays on it so far, each part numbered by how much of the idea it assumes. What sits either side of it:

The objects named here

The third axis, after the field and the idea: the things themselves, and every essay that touches each one.

AliasingConvergence orderModel rangeNyquist rateReconstructionRise timeSample rate