262 lines
8.4 KiB
HTML
262 lines
8.4 KiB
HTML
<!DOCTYPE html>
|
|
|
|
<!--Converted with LaTeX2HTML 2002-2-1 (1.71)
|
|
original version by: Nikos Drakos, CBLU, University of Leeds
|
|
* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan
|
|
* with significant contributions from:
|
|
Jens Lippmann, Marek Rouchal, Martin Wilck and others -->
|
|
<HTML>
|
|
<HEAD>
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
|
|
|
<TITLE>Fidelity of interpolating delay lines</TITLE>
|
|
<META NAME="description" CONTENT="Fidelity of interpolating delay lines">
|
|
<META NAME="keywords" CONTENT="book">
|
|
<META NAME="resource-type" CONTENT="document">
|
|
<META NAME="distribution" CONTENT="global">
|
|
|
|
<META NAME="Generator" CONTENT="LaTeX2HTML v2002-2-1">
|
|
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
|
|
|
|
<LINK REL="STYLESHEET" HREF="book.css">
|
|
|
|
<LINK REL="next" HREF="node115.html">
|
|
<LINK REL="previous" HREF="node113.html">
|
|
<LINK REL="up" HREF="node104.html">
|
|
<LINK REL="next" HREF="node115.html">
|
|
</HEAD>
|
|
|
|
<BODY >
|
|
<!--Navigation Panel-->
|
|
<A ID="tex2html2254"
|
|
HREF="node115.html">
|
|
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next"
|
|
SRC="next.png"></A>
|
|
<A ID="tex2html2248"
|
|
HREF="node104.html">
|
|
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up"
|
|
SRC="up.png"></A>
|
|
<A ID="tex2html2242"
|
|
HREF="node113.html">
|
|
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous"
|
|
SRC="prev.png"></A>
|
|
<A ID="tex2html2250"
|
|
HREF="node4.html">
|
|
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents"
|
|
SRC="contents.png"></A>
|
|
<A ID="tex2html2252"
|
|
HREF="node201.html">
|
|
<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index"
|
|
SRC="index.png"></A>
|
|
<BR>
|
|
<B> Next:</B> <A ID="tex2html2255"
|
|
HREF="node115.html">Pitch shifting</A>
|
|
<B> Up:</B> <A ID="tex2html2249"
|
|
HREF="node104.html">Time shifts and delays</A>
|
|
<B> Previous:</B> <A ID="tex2html2243"
|
|
HREF="node113.html">Variable and fractional shifts</A>
|
|
<B> <A ID="tex2html2251"
|
|
HREF="node4.html">Contents</A></B>
|
|
<B> <A ID="tex2html2253"
|
|
HREF="node201.html">Index</A></B>
|
|
<BR>
|
|
<BR>
|
|
<!--End of Navigation Panel-->
|
|
|
|
<H1><A ID="SECTION001180000000000000000">
|
|
Fidelity of interpolating delay lines</A>
|
|
</H1>
|
|
|
|
<P>
|
|
Since they are in effect doing wavetable lookup, variable delay lines
|
|
introduce distortion to the signals they operate on. Moreover, a
|
|
subtler problem can come up even when the delay line is not changing in length:
|
|
the frequency response, in real situations, is never perfectly flat for a
|
|
delay line whose length is not an integer.
|
|
|
|
<P>
|
|
If the delay time is changing from sample to sample, the distortion results of
|
|
Section <A HREF="node31.html#sect2.interpolation">2.5</A> apply. To use them, we suppose that the
|
|
delay line input can be broken down into sinusoids and consider separately what
|
|
happens to each individual sinusoid. We can use Table 2.1
|
|
(Page <A HREF="node31.html#tab02.1"><IMG ALIGN="BOTTOM" BORDER="1" ALT="[*]"
|
|
SRC="crossref.png"></A>) to predict
|
|
the RMS level of the combined distortion products for an interpolated
|
|
variable delay line.
|
|
|
|
<P>
|
|
We'll assume here that we want to use four-point interpolation. For sinusoids
|
|
with periods longer than 32 samples (that is, for frequencies below 1/16 of the
|
|
Nyquist frequency) the distortion is 96 dB or better--unlikely ever to be
|
|
noticeable. At a 44 kHz. sample rate, these periods would correspond to
|
|
frequencies up to about 1400 Hertz. At higher frequencies the quality degrades,
|
|
and above 1/4 the Nyquist frequency the distortion products, which are only
|
|
down about 50 dB, will probably be audible.
|
|
|
|
<P>
|
|
The situation for a complex tone depends primarily on the amplitudes and
|
|
frequencies of its higher partials. Suppose, for instance, that a tone's
|
|
partials above 5000 Hertz are at least 20 dB less than its strongest partial, and
|
|
that above 10000 Hertz they are down 60 dB. Then as a rough estimate, the
|
|
distortion products from the range 5000-10000 will each be limited to
|
|
about -68 dB and those from above 10000 Hertz will be limited to about -75 dB
|
|
(because the worst figure in the table is about -15 dB and this must be
|
|
added to the strength of the partial involved.)
|
|
|
|
<P>
|
|
If the high-frequency content of the input signal does turn out to give
|
|
unacceptable distortion products, in general it is more effective to increase
|
|
the sample rate than the number of points of interpolation. For periods
|
|
greater than 4 samples, doubling the period (by doubling the sample
|
|
rate, for example) decreases distortion by about 24 dB.
|
|
|
|
<P>
|
|
The 4-point interpolating delay line's frequency response is nearly
|
|
flat up to half the Nyquist frequency, but thereafter it dives quickly.
|
|
Suppose (to pick the worst case) that the delay is set halfway between two
|
|
integers, say 1.5. Cubic interpolation gives:
|
|
<BR><P></P>
|
|
<DIV ALIGN="CENTER">
|
|
<!-- MATH
|
|
\begin{displaymath}
|
|
x[1.5] = {{-x[0] + 9x[1] + 9 x[2] - x[3]} \over 8}
|
|
\end{displaymath}
|
|
-->
|
|
|
|
<IMG
|
|
WIDTH="250" HEIGHT="40" BORDER="0"
|
|
SRC="img792.png"
|
|
ALT="\begin{displaymath}
|
|
x[1.5] = {{-x[0] + 9x[1] + 9 x[2] - x[3]} \over 8}
|
|
\end{displaymath}">
|
|
</DIV>
|
|
<BR CLEAR="ALL">
|
|
<P></P>
|
|
Now let <IMG
|
|
WIDTH="31" HEIGHT="32" ALIGN="MIDDLE" BORDER="0"
|
|
SRC="img80.png"
|
|
ALT="$x[n]$"> be a (real-valued) unit-amplitude sinusoid with angular
|
|
frequency <IMG
|
|
WIDTH="14" HEIGHT="13" ALIGN="BOTTOM" BORDER="0"
|
|
SRC="img27.png"
|
|
ALT="$\omega $">, whose phase is zero at <IMG
|
|
WIDTH="23" HEIGHT="13" ALIGN="BOTTOM" BORDER="0"
|
|
SRC="img793.png"
|
|
ALT="$1.5$">:
|
|
<BR><P></P>
|
|
<DIV ALIGN="CENTER">
|
|
<!-- MATH
|
|
\begin{displaymath}
|
|
x[n] = \cos(\omega \cdot (n - 1.5))
|
|
\end{displaymath}
|
|
-->
|
|
|
|
<IMG
|
|
WIDTH="164" HEIGHT="28" BORDER="0"
|
|
SRC="img794.png"
|
|
ALT="\begin{displaymath}
|
|
x[n] = \cos(\omega \cdot (n - 1.5))
|
|
\end{displaymath}">
|
|
</DIV>
|
|
<BR CLEAR="ALL">
|
|
<P></P>
|
|
and compute <IMG
|
|
WIDTH="41" HEIGHT="32" ALIGN="MIDDLE" BORDER="0"
|
|
SRC="img795.png"
|
|
ALT="$x[1.5]$"> using the above formula:
|
|
<BR><P></P>
|
|
<DIV ALIGN="CENTER">
|
|
<!-- MATH
|
|
\begin{displaymath}
|
|
x[1.5] = {{9 \cos(\omega/2) - \cos(3 \omega / 2)}\over4}
|
|
\end{displaymath}
|
|
-->
|
|
|
|
<IMG
|
|
WIDTH="218" HEIGHT="40" BORDER="0"
|
|
SRC="img796.png"
|
|
ALT="\begin{displaymath}
|
|
x[1.5] = {{9 \cos(\omega/2) - \cos(3 \omega / 2)}\over4}
|
|
\end{displaymath}">
|
|
</DIV>
|
|
<BR CLEAR="ALL">
|
|
<P></P>
|
|
This is the peak value of the sinusoid that comes back out of the delay
|
|
line, and since the peak amplitude going in was one, this shows the
|
|
frequency response of the delay line. This is graphed in Figure
|
|
<A HREF="#fig07.18">7.18</A>. At half the Nyquist frequency (<!-- MATH
|
|
$\omega = \pi / 2$
|
|
-->
|
|
<IMG
|
|
WIDTH="60" HEIGHT="32" ALIGN="MIDDLE" BORDER="0"
|
|
SRC="img797.png"
|
|
ALT="$\omega = \pi / 2$">) the gain
|
|
is about
|
|
-1 dB, which is a barely perceptible drop in amplitude. At the Nyquist
|
|
frequency
|
|
itself, however, the gain is zero.
|
|
|
|
<P>
|
|
|
|
<DIV ALIGN="CENTER"><A ID="fig07.18"></A><A ID="8143"></A>
|
|
<TABLE>
|
|
<CAPTION ALIGN="BOTTOM"><STRONG>Figure 7.18:</STRONG>
|
|
Gain of a four-point interpolating delay line with a delay halfway
|
|
between two integers. The DC gain is one.</CAPTION>
|
|
<TR><TD><IMG
|
|
WIDTH="447" HEIGHT="172" BORDER="0"
|
|
SRC="img798.png"
|
|
ALT="\begin{figure}\psfig{file=figs/fig07.18.ps}\end{figure}"></TD></TR>
|
|
</TABLE>
|
|
</DIV>
|
|
|
|
<P>
|
|
As with the results for distortion, the frequency response improves radically
|
|
with a doubling of sample rate. If we run our delay at a sample rate of 88200
|
|
Hertz instead of the standard 44100, we will get only about 1 dB of roll-off all
|
|
the way up to 20000 Hertz.
|
|
|
|
<P>
|
|
<HR>
|
|
<!--Navigation Panel-->
|
|
<A ID="tex2html2254"
|
|
HREF="node115.html">
|
|
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next"
|
|
SRC="next.png"></A>
|
|
<A ID="tex2html2248"
|
|
HREF="node104.html">
|
|
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up"
|
|
SRC="up.png"></A>
|
|
<A ID="tex2html2242"
|
|
HREF="node113.html">
|
|
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous"
|
|
SRC="prev.png"></A>
|
|
<A ID="tex2html2250"
|
|
HREF="node4.html">
|
|
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents"
|
|
SRC="contents.png"></A>
|
|
<A ID="tex2html2252"
|
|
HREF="node201.html">
|
|
<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index"
|
|
SRC="index.png"></A>
|
|
<BR>
|
|
<B> Next:</B> <A ID="tex2html2255"
|
|
HREF="node115.html">Pitch shifting</A>
|
|
<B> Up:</B> <A ID="tex2html2249"
|
|
HREF="node104.html">Time shifts and delays</A>
|
|
<B> Previous:</B> <A ID="tex2html2243"
|
|
HREF="node113.html">Variable and fractional shifts</A>
|
|
<B> <A ID="tex2html2251"
|
|
HREF="node4.html">Contents</A></B>
|
|
<B> <A ID="tex2html2253"
|
|
HREF="node201.html">Index</A></B>
|
|
<!--End of Navigation Panel-->
|
|
<ADDRESS>
|
|
Miller Puckette
|
|
2006-12-30
|
|
</ADDRESS>
|
|
</BODY>
|
|
</HTML>
|