Electronic Design

Novel Differentiator Handles Discrete Time-Domain Signals

This Design Brief introduces a computationally efficient network that computes the derivative of a discrete time-domain (digital) sequence. While recursive differentiating networks exist, this article describes a simple tapped-delay line (finite impulse response or FIR) differentiator that has guaranteed linear phase.

Although the idea of differentiation is well-defined in the world of continuous signals, that's not the case for discrete signals. Fortunately, however, we can approximate the calculus of a derivative operation in the domain of discrete signals. (While DSP purists prefer to use the terminology "digital differencer," we'll use the term " differentiator.")

To review the notion of differentiation, think about a continuous sine wave, whose frequency is rad./s, represented by:

The derivative of that sine wave is:

Therefore, the derivative of a sine wave is a cosine wave whose amplitude is proportional to the original x(t) sine wave's frequency. Equation 2 says that an ideal differentiator's frequency magnitude response is a straight line increasing with frequencyω. Keeping that in mind, consider two common discrete-time FIR (non-recursive) differentiators: a first-difference and a central-difference differentiator. They are computationally simple schemes for estimating the derivative of a digital x(n) time-domain signal sequence with respect to time.

The first-difference differentiator, which involves the simple process of computing the difference between successive x(n) signal samples, is defined in the time domain by:

The frequency magnitude response of that differentiator is the dashed |Hfd(ω)| curve in Figure 1. For comparison, Figure 1 also shows an ideal differentiator's straight-line |Hidea(ω)| = magnitude response. The frequency axis in the figure covers the positive frequency range 0≤ ω ≤ π samples/radian, corresponding to a cyclic frequency range of 0 to fs/2, where fs is the x(n) sample rate in hertz.

Equation 3 is sweet in its simplicity, but unfortunately its |Hfd(ω)| tends to amplify high-frequency noise that often contaminates real-world signals. For that reason, the central-difference differentiator is often used in practice. The time-domain expression of the central-difference differentiator is:

The central-difference differentiator's frequency magnitude response is the dotted |Hcd(ω)| curve in Figure 1. The tradeoff for |Hcd(ω)|'s desirable high-frequency (noise) attenuation is that its frequency range of linear operation is only from zero to roughly = 0.16 π samples/radian (0.08fs Hz). Unfortunately, that's less than the frequency range of linear operation of the first-difference differentiator.

As noted, this Design Brief describes a third alternative, a computationally efficient differentiator that maintains the central-difference differentiator's beneficial high-frequency attenuation behavior, but extends its frequency range of linear operation. The differentiator is defined by:

This novel differentiator's normalized frequency magnitude response is the solid |Hdif(ω)| curve in Figure 1. Its frequency range of linear operation extends from to zero to approximately = 0.34π samples/radian (0.17fs Hz). This is twice the usable frequency range of the central-difference differentiator.

The implementation of the differentiator is shown in Figure 2, where a delay block comprises two unit delays. The folded-FIR structure for this differentiator is presented in Figure 3, which shows that only a single multiply need be performed per ydif(n) output sample. The really slick aspect of the ydif(n) differentiator is that its non-unity coefficients (±1/16) are integer powers of two. This means that a multiplication can be implemented with an arithmetic right shift by four bits. Happily, such a binary right-shift implementation is a linearphase, multiplier-less differentiator.

Another valuable feature of the ydif(n) differentiator is that its time delay (group delay) is exactly three sample periods (3/fs), making it convenient for use with popular FM demodulation methods.1

Reference:

  1. Lyons, Richard, Understanding Digital Signal Processing, 2nd Edition, Prentice Hall, Upper Saddle River, N.J., 2004, p. 549-552
Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish