Transformations of the independent variable
Three operations and nothing more: shift, mirror and stretch. The trouble starts when they are combined, because the shift of x(at+b) is not b but b/a, and everyone gets that wrong at some point.
01Three operations and nothing more
Everything that can be done to the time axis of a signal is built from three moves:
| Operation | Expression | What it does |
|---|---|---|
| Shifting | \( x(t - t_0) \) | With \( t_0 \gt 0 \) it moves to the right: it is a delay |
| Reflection | \( x(-t) \) | Mirrors about the vertical axis: the future becomes the past |
| Scaling | \( x(at) \) | With \( |a| \gt 1 \) it compresses; with \( |a| \lt 1 \), it expands |
The first two rows come with their own sign trap. That \( x(t - t_0) \) moves to the right seems backwards, but it makes sense if you think about where what used to happen at zero happens now: it takes \( t = t_0 \) for the argument to equal zero. And the same thing happens with scaling: multiplying the argument by 2 shortens the signal to half, because the argument reaches each value sooner.
02The combined case, where everybody goes wrong
When they appear together, \( y(t) = x(at + b) \), the order matters and the shift is not \( b \). Factoring out \( a \) makes it plain:
There is a method that never fails and spares you from having to remember the order: track the key points. If the original signal has a corner, a jump or a peak at \( t = t_1 \), that same feature appears in the transformed signal where the argument equals \( t_1 \):
With two or three key points mapped, the whole signal is already determined, with no arguments about order or signs. That is what the lab does: it shows where each corner ends up.
Above, the original signal with its three key points; below, \( x(at+b) \) with the same points mapped. Move \( a \) and \( b \) and watch what happens to each one.
03In discrete time, scaling is something else
Shifting and reflection work the same way: \( x[n - n_0] \) and \( x[-n] \) hold no surprises, except that \( n_0 \) must be an integer. Scaling, on the other hand, changes in nature.
| Operation | Name | What happens |
|---|---|---|
| \( x[Mn] \), \( M \) an integer | Decimation | Samples are discarded. Information is lost: it cannot be undone |
| \( x[n/L] \), \( L \) an integer | Interpolation | Gaps appear that have to be filled in: it is not defined if \( n/L \) is not an integer |
The difference with the continuous case is fundamental. Compressing a continuous signal is reversible: you expand it back and it is the same. Decimating a sequence throws samples in the trash, and unless the signal was oversampled, what was lost does not come back. That is why in digital processing decimation is always preceded by an antialiasing filter, and interpolation followed by a reconstruction filter.
Going from 48 kHz to 44.1 kHz —from professional audio to compact disc— means multiplying by 147/160. It is done by interpolating by 147 and decimating by 160, with a filter in between. All the machinery of sampling-rate conversion is this transformation, applied carefully.
04Where each one shows up
| Transformation | In a circuit or system |
|---|---|
| \( x(t - t_0) \) | A delay line, an echo, propagation along a cable |
| \( x(t) + \alpha\,x(t - t_0) \) | A simple echo, and also multipath interference |
| \( x(-t) \) | Convolution and correlation, where a signal is reflected before it slides |
| \( x(at) \) | Changing the playback speed, or Doppler shift |
| \( x[Mn] \) | Lowering the sampling rate of a digital stream |
The third row is the one that will be used most from here on. Convolution is defined with \( h(t - \tau) \), which is a reflection followed by a shift, and understanding those two operations well is what keeps the convolution integral from being an opaque formula.
05In the lab
Given a signal with corners at \( t = 0 \), \( 1 \) and \( 1.5 \), sketch \( x(2t + 3) \), \( x(-t + 1) \) and \( x(-2t - 1) \) by mapping each corner with \( t = (t_1 - b)/a \). Check all three with the lab.
Build with two operational amplifiers and a digital delay line a system \( y(t) = x(t) + 0.5\,x(t - 20\text{ ms}) \). Observe the effect on a pulse train and on a sinusoid, and explain why periodic nulls appear in frequency.
Sample a 3 kHz sinusoid at 40 kHz and then keep one sample out of every eight. Compare with what you get by filtering at 2.5 kHz first. Explain the difference.
06Common mistakes
- Shifting by \( b \) instead of \( b/a \). The most frequent mistake of all. The key points avoid it.
- Reversing the direction of the shift. \( x(t - t_0) \) with positive \( t_0 \) moves to the right.
- Believing that \( x(2t) \) stretches the signal. It compresses it: it reaches each value sooner.
- Doing the operations in any order. Scaling and then shifting is not the same as the reverse, unless the shift is corrected.
- Decimating without filtering first. What is lost does not come back, and on top of that aliasing appears.
07Self-assessment
Which way does \( x(t - 3) \) move?
To the right: it is a delay of 3 units.
If \( x(t) \) has a corner at \( t = 2 \), where is it in \( x(2t + 1) \)?
Where \( 2t + 1 = 2 \), that is, at \( t = 0.5 \).
What is the effective shift in \( x(3t + 6) \)?
\( b/a = 2 \) to the left, not 6. Then it is compressed by 3.
What does \( x(-2t) \) do to the signal?
It reflects it and compresses it to half. The sign does the reflection; the magnitude, the scaling.
Why is decimation not reversible?
Because samples are discarded. Unless the signal was oversampled, the information that lay between the ones that remain is lost.
What transformations are inside a convolution?
A reflection and a shift: \( h(t - \tau) \) is \( h \) mirrored and moved to \( t \).
08Further reading
- Alan V. Oppenheim and Alan S. Willsky. Signals and Systems. 2nd ed. (Spanish edition, “Señales y sistemas”), Prentice Hall, 1998. Section 1.2, with the graphical examples that are the reference for this topic.
- John G. Proakis and Dimitris G. Manolakis. Digital Signal Processing. 4th ed. (Spanish edition, “Tratamiento digital de señales”), Pearson, 2007. Decimation, interpolation and sampling-rate conversion, with the filters that are needed.
- Simon Haykin and Barry Van Veen. Signals and Systems. (Spanish edition, “Señales y sistemas”), Limusa Wiley, 2001. A good treatment of the order of operations, with both routes worked out in parallel.