Skip to content
Tutorials Center
My learning

Topics

Lesson 6 of 36 ยท Signals and Classification

Operations on Signals: Shift, Scale, Reverse

Master the transformations of the independent variable: time shift, time reversal, time scaling and their combinations, plus amplitude operations, with Python checks.

Two kinds of operations appear everywhere. Operations on the amplitude change the value of the signal: multiply, add, differentiate. Operations on the independent variable change the time axis: shift, reverse, stretch. The second kind is the classic source of mistakes, so we take it slowly.

Amplitude operations

  • Scaling: y(t) = a x(t) multiplies every value (a gain, or attenuation if |a| < 1).
  • Addition: y(t) = x1(t) + x2(t) mixes two signals.
  • Multiplication: y(t) = x1(t) x2(t), as in amplitude modulation.
  • Differentiation / differencing: dx/dt for continuous time, x[n] - x[n-1] for discrete.
  • Integration / accumulation: integral of x or sum of x[k].
Python Differencing and accumulating

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Differencing and accumulating undo each other, the discrete analog of differentiation and integration.

Time shifting

y(t) = x(t - t0) is x delayed by t0 (moved to the right) when t0 > 0, and advanced (moved left) when t0 < 0. The sign trips people up: x(t - 2) looks like a "minus" but moves the picture right, because the event that used to occur at t = 0 now occurs when t - 2 = 0, i.e. at t = 2.

In discrete time with arrays, a delay by k samples prepends k zeros.

Python Delay and advance

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Time reversal

y(t) = x(-t) mirrors the signal about t = 0. A recording played backwards is a time-reversed signal. In arrays, reversal is x[::-1], as long as the index axis is mirrored too.

Time scaling

y(t) = x(a t) compresses the signal if a > 1 (faster) and stretches it if 0 < a < 1 (slower); a negative a also reverses. In discrete time scaling is delicate: x[2n] downsamples (throws samples away), and x[n/2] needs invented values at odd n (upsampling with zeros or interpolation).

Python Compress, stretch, downsample

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Combining operations: the order rule

For y(t) = x(a t - b) there are two safe procedures that give the same answer:

  1. Shift first, then scale. Form v(t) = x(t - b), then y(t) = v(a t).
  2. Scale first, then shift. Form w(t) = x(a t), then y(t) = w(t - b/a).

Mixing these up (for instance shifting by b after scaling) is the classic error. The most reliable check is to evaluate: the point where the argument a t - b equals a landmark of x tells you where that landmark lands in y.

Python Check x(2t - 3) by landmarks

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

The pulse of width 1 became a pulse of width 0.5 (compressed by 2) starting at t = 1.5 (it was shifted by b/a = 1.5, not by 3).

flowchart LR
    A["x(t)"] -->|"shift: t - 3"| B["x(t - 3)"]
    B -->|"scale: 2t"| C["x(2t - 3)"]

Shift first, then scale the whole shifted signal: the shift gets compressed with it.

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. Which direction does x(t - 2) move the graph of x(t)?

    The event previously at t = 0 now happens where t - 2 = 0, so at t = 2: a delay to the right.
  2. 2. What does x(2t) do to a signal?

    Reaching every value in half the time compresses the graph horizontally.
  3. 3. The discrete operation x[2n] is called:

    It keeps every second sample and discards the others.
  4. 4. The pulse from 0 to 1 passes through x(2t - 3). Where does the resulting pulse start?

    The start corresponds to 2t - 3 = 0, so t = 1.5.

Summary

  • Amplitude operations act on values; independent-variable operations act on the time axis.
  • x(t - t0) delays by t0 (right shift); x(-t) reverses; x(a t) compresses for a > 1.
  • In discrete time, x[2n] downsamples and x[n/2] needs upsampling.
  • For x(a t - b), use landmarks or shift first and then scale.

Next: Even, Odd and Periodic Signals