Frequency-domain representation transforms time-based signals into their frequency components, making it possible to see which frequencies are present and how strong each one is. This is foundational in signal processing because many operations (filtering, modulation, compression) are far easier to understand and design when you work in the frequency domain rather than the time domain.
The two main tools here are the Fourier series (for periodic signals) and the Fourier transform (for aperiodic signals). Both decompose signals into sinusoidal building blocks, but they apply to different types of signals and produce different kinds of output.
Frequency Spectrum of Signals
Understanding the Frequency Spectrum
The frequency spectrum is a way of displaying how a signal's energy or power is distributed across different frequencies. Instead of seeing a waveform evolve over time, you see which frequencies are present and how much each one contributes.
Any signal can be decomposed into a sum of sinusoidal components, each with its own frequency, amplitude, and phase. The frequency spectrum captures exactly this decomposition. It tells you the dominant frequencies in a signal and their relative strengths.
Two plots are commonly used to represent the spectrum:
- Magnitude spectrum: shows the amplitude of each frequency component
- Phase spectrum: shows the phase angle of each frequency component
Together, these two plots give you complete information about the signal's frequency content.
Obtaining the Frequency Spectrum
To get the frequency spectrum, you apply a mathematical transformation to the time-domain signal. Which transformation you use depends on the type of signal:
- Fourier series for periodic signals (signals that repeat)
- Fourier transform for aperiodic signals (signals that don't repeat)
Both convert the signal from the time domain to the frequency domain, but the Fourier series produces a discrete set of frequency components (harmonics), while the Fourier transform produces a continuous frequency function.
Fourier Series for Periodic Signals
Representing Periodic Signals with Fourier Series
The Fourier series expresses a periodic signal as a sum of sinusoids at integer multiples of a fundamental frequency. A periodic signal repeats with period , so its fundamental frequency is .
The trigonometric form of the Fourier series is:
- is the DC component (the average value of the signal over one period)
- and are the Fourier coefficients for the -th harmonic
- is the fundamental frequency, and is the frequency of the -th harmonic
The key idea: no matter how complex a periodic waveform looks (a square wave, a sawtooth, etc.), it can be built from sine and cosine waves at harmonically related frequencies.
Calculating Fourier Coefficients
The Fourier coefficients are found by integrating the signal multiplied by the corresponding sine or cosine over one full period:
- DC coefficient:
- Cosine coefficients:
- Sine coefficients:
Why do these formulas work? Sine and cosine functions at different harmonic frequencies are orthogonal over one period. When you multiply by and integrate, all the other frequency components average to zero, leaving only the contribution at frequency . This orthogonality is what makes the decomposition possible.
Each pair determines both the amplitude and phase of the -th harmonic. The amplitude of the -th component is , and its phase is .
Analyzing Harmonic Content
Once you have the Fourier coefficients, you can examine the harmonic content of the signal, meaning which harmonics are present and how strong each one is.
For example, a square wave with period contains only odd harmonics (), with amplitudes that decrease as . A triangle wave also has only odd harmonics, but its amplitudes fall off as , which is why a triangle wave sounds "smoother" than a square wave.
By plotting the magnitude of each coefficient versus frequency, you get a line spectrum showing discrete spikes at each harmonic. This is a defining feature of periodic signals: their spectra are discrete, not continuous.
Fourier Transform for Aperiodic Signals
Representing Aperiodic Signals with Fourier Transform
Aperiodic signals don't repeat, so the Fourier series doesn't apply directly. Instead, you use the Fourier transform, which generalizes the Fourier series to non-periodic signals.
You can think of it this way: as the period of a periodic signal approaches infinity, the harmonics get closer and closer together until the discrete line spectrum becomes a continuous function of frequency. That continuous function is the Fourier transform.
The Fourier transform of a continuous-time signal is:
- is a complex-valued function of frequency
- Its magnitude gives the amplitude density at each frequency
- Its angle gives the phase at each frequency
Unlike the Fourier series, which gives you discrete coefficients, the Fourier transform gives a continuous spectrum. For example, a rectangular pulse of width has a Fourier transform shaped like a sinc function: , with energy spread across all frequencies.
Inverse Fourier Transform
The inverse Fourier transform recovers the time-domain signal from its frequency-domain representation:
This means the transform pair is reversible: no information is lost when you go from time domain to frequency domain and back. The forward transform decomposes the signal into frequency components; the inverse transform reassembles them.
Applying Fourier Transform to Aperiodic Signals
The Fourier transform applies to a wide range of aperiodic signals:
- Transient signals: short-duration events like an impulse or a decaying exponential
- Pulses: signals with a rapid rise and fall, such as rectangular or Gaussian pulses
- Non-periodic waveforms: any signal that doesn't repeat
A useful intuition: signals that are short in time tend to have wide frequency spectra (energy spread over many frequencies), while signals that are long in time tend to have narrow spectra. This is an informal statement of the time-frequency uncertainty principle, which you'll encounter more formally later.
Fourier Transform Properties
These properties let you predict how changes to a signal in one domain affect its representation in the other domain. They're extremely useful for solving problems without recomputing the full transform integral every time.
Linearity Property
If and , then:
where and are constants. Scaling and addition in the time domain map directly to scaling and addition in the frequency domain. This means you can analyze complex signals by breaking them into simpler pieces, transforming each piece separately, and adding the results.
Time-Shifting Property
If , then:
Shifting a signal in time by doesn't change its magnitude spectrum at all. It only adds a linear phase shift of to the phase spectrum. This makes sense: delaying a signal doesn't change which frequencies are present, only when they arrive.
Frequency-Shifting Property
If , then:
Multiplying by a complex exponential in the time domain shifts the entire spectrum by . This is the basis of modulation in communications: you shift a baseband signal up to a carrier frequency for transmission. In practice, multiplying by (which is the real part of the complex exponential) creates copies of the spectrum centered at and .
Scaling Property
If , then:
where is a non-zero constant. Compressing a signal in time () spreads its spectrum out in frequency and reduces its amplitude. Stretching a signal in time () narrows its spectrum and increases its amplitude. This is another manifestation of the time-frequency tradeoff: you can't make a signal shorter in time without making it wider in frequency, and vice versa.
Parseval's Theorem
Parseval's theorem states that the total energy of a signal is the same whether you compute it in the time domain or the frequency domain:
The left side sums up energy over time; the right side sums up energy over frequency. The quantity is called the energy spectral density, and it tells you how the signal's energy is distributed across frequencies.
This theorem is useful for two reasons: it lets you calculate signal energy in whichever domain is more convenient, and it serves as a sanity check. If you compute a Fourier transform and the energy doesn't match between domains, something went wrong.