FS01: Periodic Functions, Harmonics, and Why Fourier Series Exist
Fourier series begin with a simple observation: many physical motions repeat.
A pendulum oscillates. A vibrating string repeats its motion. An alternating voltage cycles. A
rotating shaft returns to the same orientation. A repeating pulse train returns after each pulse
interval.
The first goal of Fourier analysis is therefore not to compute coefficients. It is to understand the
mathematical structure of repetition.
This lecture develops that structure in small steps:
- what it means for a function to be periodic,
- the difference between a period and the fundamental period,
- frequency and angular frequency,
- amplitude and phase,
- harmonics and harmonic number,
- why integer multiples of one fundamental frequency fit together naturally,
- why sums of harmonics remain periodic,
- how simple harmonics begin to build complicated repeating waveforms.
The Fourier coefficient formulas are deliberately postponed. At the end of this article, the natural
next question will be:
- How can we measure how much of a particular harmonic is present in a function?
FS02 answers that question by introducing inner products of functions.
1 Periodic functions
A function f is periodic if there exists a positive number T such that
for every x for which both sides are defined.
The number T is called a period of the function.
Equation (1) says that if we move forward by T, the function value repeats exactly.
For a time-dependent function,
so the system returns to the same function value after every interval T.
Figure 1. A periodic function repeats after a fixed horizontal displacement T. A nonperiodic
function has no single positive displacement that reproduces the complete graph for all values of
the independent variable.
1.1 The independent variable does not have to be time
Fourier series are often introduced with time-dependent oscillations, but the independent variable
can be many things.
Examples include:
- time t,
- position x along a string,
- angle 𝜃 around a circle,
- position along a repeating crystal lattice,
- spatial coordinate in a periodically repeated boundary condition.
For this reason, the notation
should be understood generically.
When the independent variable is time, T has units of time. When the independent variable is
distance, the period has units of distance.
2 A period is not always the fundamental period
Suppose
If T is one period, then
for all t.
Because cosine repeats when its argument increases by 2π,
is the smallest positive choice.
Thus
But if T is a period, then
are also periods because the function repeats after any whole number of cycles.
The fundamental period is the smallest positive period.
We will denote it by
For
the fundamental period is
3 Frequency
Frequency counts cycles per unit time.
If one complete cycle requires time T0, then the number of cycles completed in one unit of time
is
The SI unit of frequency is the hertz:
For example, if
then
| f0 | =  | (15)
|
| = 4 Hz. | (16) |
The system completes four cycles each second.
4 Angular frequency
One complete cycle corresponds to an angular advance of
If the cycle takes time T0, then the angular rate is
Using
we obtain
Therefore the three quantities are related by
Figure 2. A sinusoid can be viewed as the projection of uniform circular motion. One full
revolution is one cycle, corresponding to an angular advance of 2π radians. This gives
ω0 = 2π∕T0 = 2πf0.
4.1 Why radians are especially natural
Radians make the phase of a sinusoid directly proportional to angle.
The argument
is dimensionless because
when radians are treated as dimensionless angular measure.
After one period,
| ω0(t + T0) | = ω0t + ω0T0 | (24)
|
| = ω0t + 2π. | (25) |
Cosine and sine therefore return to the same values.
5 Amplitude
Consider
The constant A is the amplitude.
For A > 0,
The amplitude controls vertical scale, not the rate at which the waveform repeats.
Thus changing A does not change the period:
6 Phase
A more general sinusoid is
The constant ϕ is the phase angle.
It tells us where in its cycle the oscillation is located when t = 0.
At t = 0,
The phase can also be interpreted as a horizontal shift.
Factor ω0 from the argument:
| ω0t + ϕ | = ω0 . | (31) |
Thus
Relative to A cos(ω0t), the graph is shifted left by
Equivalently, if we write
then the corresponding phase is
Figure 3. Two sinusoids can have the same amplitude and frequency but different phase. A
positive phase in Acos(ωt + ϕ) shifts the graph to the left by ϕ∕ω.
7 Combining sine and cosine at the same frequency
Fourier series use both sine and cosine terms. It is useful to see that a sine-plus-cosine pair at one
frequency is still just one sinusoid with a different amplitude and phase.
Start with
Suppose we want to rewrite this as
Use the identity
Then
| C cos(ωt − δ) | = C cos(ωt) cos δ | (39)
|
| + C sin(ωt) sin δ. | (40) |
Compare with Equation (36). The cosine coefficients must match:
The sine coefficients must also match:
Square both equations and add:
| A2 + B2 | = C2 cos 2δ + C2 sin 2δ | (43)
|
| = C2(cos 2δ + sin 2δ) | (44)
|
| = C2. | (45) |
Therefore
Divide Equation (42) by Equation (41):
Thus the phase may be written carefully as
which places the angle in the correct quadrant.
This result will later let us move freely between sine-cosine coefficients and amplitude-phase
descriptions.
8 What is a harmonic?
Suppose a periodic function has fundamental period
Its fundamental frequency is
and its fundamental angular frequency is
The frequencies
are called harmonics.
Equivalently,
The integer n is the harmonic number.
Thus:
- n = 1 is the fundamental or first harmonic,
- n = 2 is the second harmonic,
- n = 3 is the third harmonic,
- and so on.
The corresponding sinusoidal basis functions are
Figure 4. The first four harmonics. Higher harmonic number means more oscillations within the
same fundamental period T0. The nth harmonic completes exactly n cycles while the fundamental
completes one.
9 The period of the nth harmonic
The nth harmonic is
Its angular frequency is
Therefore its smallest positive period is
| Tn | =  | (57)
|
| =  | (58)
|
| =   | (59)
|
| = . | (60) |
So the second harmonic repeats twice as fast as the fundamental, the third harmonic three times as
fast, and so on.
But an important subtlety is that every harmonic also repeats after the larger interval
T0.
For the nth harmonic,
| cos[nω0(t + T0)] | = cos(nω0t + nω0T0) | (61)
|
| = cos(nω0t + 2πn) | (62)
|
| = cos(nω0t). | (63) |
Thus T0 is a common period of every integer harmonic.
This fact is one of the central reasons Fourier series use integer multiples of a fundamental
frequency.
10 Why integer harmonics line up after one fundamental period
Suppose a sinusoidal basis function has angular frequency ω and must fit a period T0.
We require
for every t.
The phase advance over one period must therefore be a whole number of turns:
Solve for ω:
But
Hence
The harmonic frequencies are therefore not arbitrary. They are exactly the sinusoidal frequencies
that complete an integer number of cycles in the interval T0.
Figure 5. Integer harmonics all return to their starting phase after the common interval T0. This
is the geometric reason the Fourier basis is naturally indexed by integer harmonic number.
11 Superposition of harmonics remains periodic
Consider a finite harmonic sum
Evaluate it one fundamental period later:
| SN(t + T0) | = A0 | (70)
|
| + ∑
n=1NA
n cos[nω0(t + T0)] | (71)
|
| + ∑
n=1NB
n sin[nω0(t + T0)]. | (72) |
Use
Then
Therefore
and
Hence
Any finite sum of integer harmonics is therefore periodic with common period T0.
Its fundamental period can sometimes be smaller than T0 if some low harmonics are absent, but T0
is always a period.
12 The constant or DC component
The term
in Equation (69) does not oscillate.
It is a constant offset.
In time-dependent signal language, it is often called the DC component.
Adding a constant does not change periodicity:
Geometrically, the constant component simply shifts the entire waveform upward or
downward.
Later, the real Fourier series will conventionally write this constant term as
FS05 will derive why this factor of 1∕2 appears.
13 How harmonics build a more complicated waveform
Consider
| S(t) | = 1 + 2 cos(ω0t) | (81)
|
| − 0.75 sin(2ω0t) | (82)
|
| + 0.40 cos(3ω0t). | (83) |
This contains:
- a constant component 1,
- a first-harmonic cosine of amplitude 2,
- a second-harmonic sine of amplitude 0.75 with a negative sign,
- a third-harmonic cosine of amplitude 0.40.
Each piece is simple. Their sum is less obviously sinusoidal.
Figure 6. Superposition of a constant term and the first three harmonics. The individual
components are simple sinusoids, but their sum already produces a visibly more complicated
repeating waveform.
This is the central Fourier idea in its simplest form:
- complicated periodic shape can arise from simple periodic components,
- the frequencies are organized as integer harmonics,
- amplitudes and phases determine the detailed shape.
14 Commensurate frequencies
Integer harmonics are an especially simple example of commensurate frequencies.
Two angular frequencies ω1 and ω2 are commensurate if their ratio is rational:
for integers p and q.
If the ratio is rational, a common period can exist.
For example, consider
The frequencies are
and
Both are integer multiples of
Thus choose
Then
The two terms are the second and third harmonics of the common fundamental.
The common fundamental period is
| T0 | =  | (91)
|
| = s. | (92) |
15 Incommensurate frequencies need not produce a periodic sum
Now consider
Suppose, for contradiction, that this sum has a common period P inherited from both sinusoidal
components.
The first component would require
for some integer m.
The second would require
for some integer n.
Divide the second relation by the first:
But the left side is irrational while the right side is rational.
This is impossible.
Therefore the two component periods have no common integer multiple, and the sum does not
repeat with one finite fundamental period.
This example explains why Fourier series for a function of period T0 use a discrete set of
commensurate frequencies
16 Preview of the real Fourier series
The real Fourier series has the form
At this stage, Equation (98) should be read structurally rather than computationally.
It says:
- one constant component may be present,
- the first harmonic may contain sine and cosine pieces,
- the second harmonic may contain sine and cosine pieces,
- the third harmonic may contain sine and cosine pieces,
- the pattern continues to higher harmonic number.
We have not yet derived
That derivation must wait until we know how to measure the similarity between two
functions.
17 Partial sums
An infinite series cannot be drawn by adding infinitely many terms one at a time.
Instead we use a partial sum.
Define
The integer N tells us the highest harmonic retained.
For example:
- S1 contains only the constant and first harmonic,
- S2 includes harmonics through n = 2,
- S10 includes harmonics through n = 10.
The sequence
is what we actually study when asking whether a Fourier series converges.
18 Square-wave preview
A classic example is the odd square wave.
Later, FS07 will derive its coefficients from first principles. For now, accept the preview
formula
The first approximation keeps only the first harmonic:
Including the third harmonic gives
Including the fifth harmonic gives
As additional odd harmonics are added, the graph becomes increasingly square-like.
Figure 7. Preview of square-wave synthesis. Adding odd harmonics changes a smooth sinusoid
into a waveform with increasingly flat plateaus and increasingly sharp transitions. FS07 will
derive the coefficients rather than assume them.
The figure contains an important warning. Near the jump, the approximation develops overshoot.
This does not disappear in the simple way one might first expect. The phenomenon is studied
carefully in FS15 and FS16.
19 Why adding higher harmonics changes shape
Higher harmonics oscillate more rapidly.
The first harmonic controls large-scale variation over the entire period. The second harmonic can
add structure on half-period scales. The tenth harmonic can add structure on scales about
one-tenth of the period.
Thus harmonic number is connected to scale:
- low harmonic number describes broad features,
- high harmonic number describes finer features.
This is the beginning of the spectral viewpoint.
Later we will see a deeper connection between smoothness and the rate at which high-harmonic
coefficients decrease.
20 Why Fourier series are plausible
We can now give a careful answer to the title question.
Fourier series are plausible for periodic functions because:
- Sine and cosine are themselves periodic.
- The integer harmonics all share the required common period T0.
- Linear combinations of those harmonics remain periodic.
- Amplitudes and phases provide enough freedom to change the waveform shape.
- Higher harmonics supply progressively finer variation within one period.
However, these facts do not yet prove that every periodic function equals its Fourier series at every
point.
Different notions of convergence must be distinguished. Discontinuities require special care. Some
functions are better behaved than others.
Those questions are postponed until FS14 through FS16.
At this stage, the correct conclusion is more modest:
- integer harmonic sinusoids form a natural candidate basis for representing periodic
functions.
The next several lectures develop the mathematics needed to make that statement precise.
21 Worked Example 1: period, frequency, and angular frequency
Suppose a repeating signal has period
Convert to seconds:
The frequency is
| f0 | =  | (108)
|
| =  | (109)
|
| = 200 Hz. | (110) |
The angular frequency is
| ω0 | = 2πf0 | (111)
|
| = 2π(200) | (112)
|
| = 400π rad∕s | (113)
|
| ≈ 1256.64 rad∕s. | (114) |
22 Worked Example 2: amplitude-phase conversion
Rewrite
as one cosine.
The combined amplitude is
| C | =  | (116)
|
| = 5. | (117) |
The phase is
| δ | = atan2(4, 3) | (118)
|
| ≈ 53.13∘. | (119) |
Therefore
The original sine and cosine terms were not two distinct frequencies. They were two quadrature
components of one sinusoid at the same frequency.
23 Worked Example 3: finding a common fundamental
Consider
The angular frequencies are
Their greatest common angular frequency is
Then
and
Thus the waveform contains the second and third harmonics of the fundamental.
Its fundamental period is
| T0 | = s | (126)
|
| ≈ 2.094 s. | (127) |
24 Worked Example 4: identifying harmonic content
Consider
| f(t) | = 2 + 3 cos(ω0t) | (128)
|
| − sin(2ω0t) + 0.5 cos(3ω0t). | (129) |
The components are:
- DC component: 2,
- first harmonic: cosine amplitude 3,
- second harmonic: sine coefficient −1,
- third harmonic: cosine amplitude 0.5,
- all harmonics above n = 3: absent.
Every oscillating term has frequency equal to an integer multiple of ω0, so the entire function has
T0 = 2π∕ω0 as a period.
25 Worked Example 5: a smaller fundamental period can hide inside a chosen period
Consider
Both terms repeat after
so T0 is certainly a period.
But the first term has period
and the second has period
After T0∕2:
cos ![[ ( ) ]
T0
2ω0 t +---
2](https://images.physicslibrary.org/cache/objects/1517/make4ht/PeriodicFunctionsHarmonicsAndWhyFourierSeriesExist106x.png) | = cos(2ω0t + 2π) | (134)
|
| = cos(2ω0t), | (135) |
and
sin ![[ ( T ) ]
4ω0 t +--0
2](https://images.physicslibrary.org/cache/objects/1517/make4ht/PeriodicFunctionsHarmonicsAndWhyFourierSeriesExist107x.png) | = sin(4ω0t + 4π) | (136)
|
| = sin(4ω0t). | (137) |
Therefore T0∕2 is a period of the whole function.
The chosen T0 was a common period, but it was not the fundamental period.
This is why the phrase fundamental period must be used carefully.
26 Physical examples of harmonic decomposition
The harmonic viewpoint appears throughout physics.
Vibrating string
A string fixed at both ends supports normal modes with frequencies
An arbitrary initial shape can be decomposed into those spatial harmonics.
Acoustics
A musical tone may contain a fundamental plus overtones. The relative harmonic amplitudes help
determine timbre.
Electrical signals
A periodic voltage can be decomposed into a DC term plus sinusoidal harmonics. A linear circuit
can then be analyzed one frequency at a time.
Periodic forcing
A nonsinusoidal periodic force acting on an oscillator can be written as a sum of harmonic
forces. Because the oscillator equation is linear, the individual harmonic responses can be
superposed.
Partial differential equations
The heat and wave equations naturally produce sinusoidal eigenfunctions under common
boundary conditions. Fourier series then become a method for matching arbitrary initial
data.
These applications are developed later in the FS sequence rather than assumed here.
27 What FS01 has not yet answered
We now know why the harmonic frequencies
are natural for a period-T0 problem.
But several major questions remain:
- How do we determine the coefficient of one particular harmonic?
- Why do unwanted harmonics disappear when extracting a coefficient?
- Why are sine and cosine special relative to one another over a complete period?
- Under what conditions does the infinite series converge to the original function?
- What happens at a discontinuity?
The first three questions require the ideas of inner product and orthogonality.
Figure 8. FS01 establishes the frequency structure of the Fourier basis. FS02 and FS03 next
supply the inner-product and orthogonality machinery needed to extract individual harmonic
coefficients.
28 Self-check questions
A learner should be able to answer the following before moving to FS02.
- What equation defines a periodic function?
- What is the difference between a period and the fundamental period?
- How are T0, f0, and ω0 related?
- What does phase change geometrically?
- What is the nth harmonic?
- Why does the nth harmonic complete exactly n cycles during one fundamental period?
- Why is any finite sum of integer harmonics periodic with common period T0?
- What does the constant or DC component do to a waveform?
- What is a partial sum?
- Why can incommensurate frequencies fail to produce a periodic sum?
- Why is a Fourier-series representation plausible but not yet proven by this lecture?
29 Practice exercises
- Show directly that sin(5t) has fundamental period 2π∕5.
- A signal has frequency 60 Hz. Find its period and angular frequency.
- A cosine has angular frequency 20π rad∕s. Find its frequency and period.
- Rewrite 5 cos(ωt) + 12 sin(ωt) as one cosine with a phase shift.
- Identify the harmonic numbers present in
- Determine a fundamental angular frequency for
Then determine the fundamental period.
- Show that
is periodic and find its fundamental period.
- Explain why
has no common period inherited from both component sinusoids.
- Verify directly that the finite harmonic sum in Equation (69) satisfies SN(t + T0) = SN(t).
- Plot the square-wave partial sums S1, S3, and S5 from Equation (102). Describe what
changes and what does not.
30 Summary
A periodic function satisfies
The smallest positive period is the fundamental period T0.
Frequency and angular frequency are
The integer harmonics are
The nth harmonic completes n cycles during one fundamental period and therefore returns to its
starting phase after T0.
Consequently, finite sums of integer harmonics are periodic with common period T0.
Amplitude determines scale. Phase determines horizontal position within the cycle. Higher
harmonics add progressively finer structure to a waveform.
These facts explain why sine and cosine harmonics are natural building blocks for periodic
functions.
The next article, FS02, asks how to measure the amount of one basis function inside another
function. The answer begins by generalizing the vector dot product to an inner product of
functions.
References
References
[1] PhysicsLibrary, FS00: Fourier Series Roadmap, Motivation, and Learning Path.
[2] R. V. Churchill and J. W. Brown, Fourier Series and Boundary Value Problems,
McGraw-Hill.
[3] E. Kreyszig, Advanced Engineering Mathematics, Wiley.
[4] G. B. Arfken, H. J. Weber, and F. E. Harris, Mathematical Methods for Physicists,
Academic Press.