Unit 1 - Notes
Unit 1: Introduction to Signals
1. Continuous-Time (CT) and Discrete-Time (DT) Signals
A signal is a function of one or more independent variables that conveys information about a physical phenomenon. In this course, the independent variable is typically time.
1.1 Continuous-Time (CT) Signals
A signal x(t) is a continuous-time signal if the independent variable t is continuous. The signal is defined for every value of time t.
- Notation:
x(t), where parentheses()denote a continuous variable. - Domain: The time variable
tbelongs to the set of real numbers (t ∈ ℝ). - Representation: Graphed as a continuous curve.
- Examples:
- Voltage across a resistor as a function of time.
- Room temperature measured over a day.
- An audio signal from a microphone.
1.2 Discrete-Time (DT) Signals
A signal x[n] is a discrete-time signal if the independent variable n is discrete (an integer). The signal is defined only at discrete instants in time.
- Notation:
x[n], where square brackets[]denote a discrete variable. - Domain: The time index
nbelongs to the set of integers (n ∈ ℤ). - Origin: Often generated by sampling a continuous-time signal at regular intervals, i.e.,
x[n] = x(nTₛ), whereTₛis the sampling period. - Representation: Graphed as a sequence of values, often using a stem plot.
- Examples:
- Daily closing value of a stock market index.
- A digital image (a 2D signal).
- The sequence of samples in a digital audio file.
2. Energy and Power Signals
Signal energy and power are measures of the size or strength of a signal.
2.1 Signal Energy
The total energy E of a signal is the integral (or sum) of the squared magnitude of the signal.
- Continuous-Time (CT):
TEXTE = ∫[-∞ to +∞] |x(t)|² dt - Discrete-Time (DT):
TEXTE = Σ[n=-∞ to +∞] |x[n]|²
Energy Signal: A signal is classified as an energy signal if its total energy is finite and non-zero (0 < E < ∞). For an energy signal, the average power is zero (P = 0).
- Characteristics: Typically, signals that are non-zero for a finite duration (time-limited) or signals that decay to zero as
t → ±∞. - Example: A rectangular pulse or a decaying exponential
x(t) = e^(-at)u(t)fora > 0.
2.2 Signal Power
The average power P of a signal is the time average of its energy.
- Continuous-Time (CT):
TEXTP = lim[T→∞] (1 / 2T) ∫[-T to T] |x(t)|² dt - Discrete-Time (DT):
TEXTP = lim[N→∞] (1 / (2N+1)) Σ[n=-N to N] |x[n]|²
Power Signal: A signal is classified as a power signal if its average power is finite and non-zero (0 < P < ∞). For a power signal, the total energy is infinite (E = ∞).
- Characteristics: Typically, periodic signals or signals that do not decay to zero.
- Example: A sinusoidal signal
x(t) = A cos(ω₀t)or the unit step functionu(t).
Note: A signal can be neither an energy signal nor a power signal (e.g., x(t) = t, which has both infinite energy and infinite power).
3. Transformations of the Independent Variable
These operations modify the time axis of a signal x(t) or x[n].
3.1 Time Shifting
y(t) = x(t - t₀)ory[n] = x[n - n₀]- Delay (Right Shift): If
t₀ > 0orn₀ > 0, the signal is shifted to the right (delayed in time). - Advance (Left Shift): If
t₀ < 0orn₀ < 0, the signal is shifted to the left (advanced in time).
3.2 Time Reversal (Reflection)
y(t) = x(-t)ory[n] = x[-n]- This operation flips the signal about the vertical axis (
t=0orn=0).
3.3 Time Scaling
y(t) = x(at)- Compression: If
|a| > 1, the signal is compressed in time (sped up). - Expansion: If
0 < |a| < 1, the signal is expanded in time (slowed down). - Note on DT signals: For
y[n] = x[an], scaling is only well-defined ifanresults in an integer for the values ofnwherex[n]is non-zero. For example,x[2n]would consist of only the even-indexed samples ofx[n].
3.4 Combined Transformations
When dealing with a combination like y(t) = x(at + b), the order of operations matters. It is best to factor out a:
y(t) = x(a(t + b/a))
This shows that the signal x(t) is first time-shifted by b/a and then time-scaled by a. Alternatively, one can first scale x(t) to get x(at) and then shift the result by b/a to get x(a(t+b/a)).
4. Periodic Signals
A signal is periodic if it repeats itself after a specific time interval.
4.1 CT Periodic Signals
A CT signal x(t) is periodic if there exists a positive constant T such that:
x(t) = x(t + T) for all t.
- Fundamental Period (T₀): The smallest positive value of
Tthat satisfies the condition. - Fundamental Frequency:
f₀ = 1/T₀(in Hertz) orω₀ = 2π/T₀(in radians/sec).
4.2 DT Periodic Signals
A DT signal x[n] is periodic if there exists a positive integer N such that:
x[n] = x[n + N] for all n.
- Fundamental Period (N₀): The smallest positive integer
Nthat satisfies the condition. - DT Sinusoid Periodicity: A discrete sinusoid
x[n] = cos(Ω₀n)is periodic only if its frequencyΩ₀is a rational multiple of2π. That is,Ω₀ / (2π) = k/Nfor some integerskandN. The fundamental period isN₀ = N/gcd(k, N), wheregcdis the greatest common divisor.
5. Even and Odd Signals
Signals can be decomposed based on their symmetry.
5.1 Even Signals
A signal is even if it is symmetric about the vertical axis.
- CT:
x(-t) = x(t) - DT:
x[-n] = x[n] - Example:
cos(t)is an even signal.
5.2 Odd Signals
A signal is odd if it is anti-symmetric about the origin.
- CT:
x(-t) = -x(t). This impliesx(0) = 0if the signal is defined att=0. - DT:
x[-n] = -x[n]. This impliesx[0] = 0. - Example:
sin(t)is an odd signal.
5.3 Even-Odd Decomposition
Any signal x(t) or x[n] can be uniquely represented as the sum of an even component and an odd component.
-
x(t) = xₑ(t) + xₒ(t) -
Even Component:
xₑ(t) = ½ [x(t) + x(-t)]
xₑ[n] = ½ [x[n] + x[-n]] -
Odd Component:
xₒ(t) = ½ [x(t) - x(-t)]
xₒ[n] = ½ [x[n] - x[-n]]
6. Exponential and Sinusoidal Signals
These are fundamental building blocks for more complex signals.
6.1 Continuous-Time Signals
- Real Exponential:
x(t) = Ce^(at)a > 0: Growing exponential.a < 0: Decaying exponential.
- Sinusoidal:
x(t) = A cos(ω₀t + φ)A: Amplitudeω₀: Angular frequency (rad/s)φ: Phase (radians)
- Complex Exponential:
x(t) = e^(st)wheres = σ + jωis a complex number.- Using Euler's identity
e^(jθ) = cos(θ) + j sin(θ), we get:
e^((σ + jω)t) = e^(σt) * e^(jωt) = e^(σt) [cos(ωt) + j sin(ωt)] - This represents a sinusoid with an amplitude that is either growing (
σ > 0) or decaying (σ < 0). - Sinusoids can be expressed using complex exponentials:
cos(ω₀t) = (e^(jω₀t) + e^(-jω₀t)) / 2
sin(ω₀t) = (e^(jω₀t) - e^(-jω₀t)) / 2j
- Using Euler's identity
6.2 Discrete-Time Signals
- Real Exponential:
x[n] = Cα^n|α| > 1: Growing sequence.|α| < 1: Decaying sequence.- If
αis negative, the sequence alternates in sign.
- Sinusoidal:
x[n] = A cos(Ω₀n + φ)Ω₀is the discrete-time frequency in radians/sample.
- Complex Exponential:
x[n] = z^nwherez = r * e^(jΩ₀)is a complex number.x[n] = (r * e^(jΩ₀))^n = r^n * e^(jΩ₀n) = r^n [cos(Ω₀n) + j sin(Ω₀n)]
7. The Unit Impulse and Unit Step Functions
These are idealized functions used to model events and analyze systems.
7.1 Continuous-Time Functions
-
Unit Step Function
u(t):
TEXTu(t) = { 1, t > 0 { 0, t < 0
Models a switch turning on att=0. -
Unit Impulse Function
δ(t)(Dirac Delta):
This is not a traditional function but a "generalized function" defined by its properties. It represents an idealized, infinitely narrow and high pulse att=0with a total area of 1.- Properties:
δ(t) = 0fort ≠ 0∫[-∞ to +∞] δ(t) dt = 1(Unit Area)- Sifting Property:
∫[-∞ to +∞] x(t) δ(t - t₀) dt = x(t₀)
- Properties:
-
Relationship:
- The impulse is the derivative of the step:
δ(t) = d/dt u(t) - The step is the integral of the impulse:
u(t) = ∫[-∞ to t] δ(τ) dτ
- The impulse is the derivative of the step:
7.2 Discrete-Time Functions
-
Unit Step Sequence
u[n]:
TEXTu[n] = { 1, n ≥ 0 { 0, n < 0 -
Unit Impulse Sequence
δ[n](Kronecker Delta):
TEXTδ[n] = { 1, n = 0 { 0, n ≠ 0 -
Relationship:
- The impulse is the first difference of the step:
δ[n] = u[n] - u[n-1] - The step is the running sum of the impulse:
u[n] = Σ[k=-∞ to n] δ[k] - Sifting Property:
Σ[n=-∞ to +∞] x[n] δ[n - n₀] = x[n₀]
- The impulse is the first difference of the step:
8. Operations on Signals
These operations involve the dependent variable (the signal's amplitude).
-
Amplitude Scaling:
y(t) = c * x(t)- Multiplies the amplitude of the signal by a constant
c.
- Multiplies the amplitude of the signal by a constant
-
Addition/Subtraction:
y(t) = x₁(t) + x₂(t)- The signals are added point-by-point in time.
-
Multiplication:
y(t) = x₁(t) * x₂(t)- The signals are multiplied point-by-point in time. This is fundamental to amplitude modulation.
9. Software Simulation of Basic Operations on Elementary Signals
We can use Python with NumPy and Matplotlib to simulate these signals and operations.
Example 1: Generating and Plotting a DT Signal
This code generates a discrete-time decaying exponential signal x[n] = (0.8)^n for 0 ≤ n ≤ 20.
import numpy as np
import matplotlib.pyplot as plt
# Define the discrete time axis
n = np.arange(0, 21)
# Generate the signal
x = 0.8**n
# Plot the signal
plt.figure(figsize=(10, 4))
plt.stem(n, x, use_line_collection=True)
plt.title('Discrete-Time Decaying Exponential: x[n] = (0.8)^n')
plt.xlabel('n (sample)')
plt.ylabel('Amplitude')
plt.grid(True)
plt.show()
Example 2: Time Shifting and Reversal of a DT Pulse
This code demonstrates shifting and reversing a rectangular pulse.
import numpy as np
import matplotlib.pyplot as plt
# Define the time axis
n = np.arange(-10, 11)
# Original signal: A rectangular pulse from n=-2 to n=2
x = np.where((n >= -2) & (n <= 2), 1, 0)
# Shifted signal y[n] = x[n-3] (Delay by 3)
y = np.where((n-3 >= -2) & (n-3 <= 2), 1, 0)
# Reversed signal z[n] = x[-n]
z = np.where((-n >= -2) & (-n <= 2), 1, 0)
# Plotting
fig, axs = plt.subplots(3, 1, figsize=(10, 8), sharex=True, sharey=True)
axs[0].stem(n, x, use_line_collection=True)
axs[0].set_title('Original Signal: x[n]')
axs[0].grid(True)
axs[1].stem(n, y, use_line_collection=True)
axs[1].set_title('Shifted Signal: y[n] = x[n-3]')
axs[1].grid(True)
axs[2].stem(n, z, use_line_collection=True)
axs[2].set_title('Reversed Signal: z[n] = x[-n]')
axs[2].set_xlabel('n (sample)')
axs[2].grid(True)
fig.tight_layout()
plt.show()
Example 3: Even-Odd Decomposition
This code decomposes a signal into its even and odd parts.
import numpy as np
import matplotlib.pyplot as plt
# Define the time axis
t = np.linspace(-5, 5, 500)
# Original Signal: A decaying exponential starting at t=-1
# x(t) = e^(-t) * u(t+1)
x = np.exp(-t) * (t >= -1)
# Reversed Signal: x(-t)
x_rev = np.exp(t) * (-t >= -1)
# Even Component: xe(t) = 0.5 * [x(t) + x(-t)]
x_e = 0.5 * (x + x_rev)
# Odd Component: xo(t) = 0.5 * [x(t) - x(-t)]
x_o = 0.5 * (x - x_rev)
# Plotting
fig, axs = plt.subplots(4, 1, figsize=(10, 10), sharex=True)
axs[0].plot(t, x)
axs[0].set_title('Original Signal: x(t)')
axs[0].grid(True)
axs[1].plot(t, x_e)
axs[1].set_title('Even Part: x_e(t)')
axs[1].grid(True)
axs[2].plot(t, x_o)
axs[2].set_title('Odd Part: x_o(t)')
axs[2].grid(True)
axs[3].plot(t, x_e + x_o, 'r--')
axs[3].set_title('Sum of Parts: x_e(t) + x_o(t)')
axs[3].set_xlabel('t (time)')
axs[3].grid(True)
fig.tight_layout()
plt.show()