The Harmonic Oscillator
The most fundamental oscillatory system in all of physics
1.1 Why the Harmonic Oscillator Matters
The harmonic oscillator is arguably the single most important model in physics. Any system near a stable equilibrium point can be approximated as a harmonic oscillator for small displacements. This universality makes it appear throughout mechanics, electromagnetism, quantum mechanics, and even general relativity.
Consider a general potential energy \(V(x)\) with a minimum at \(x = x_0\). Expanding in a Taylor series:
Since \(V'(x_0) = 0\) at the minimum, the leading-order behavior is quadratic:\(V(x) \approx \frac{1}{2}k(x - x_0)^2\) where \(k = V''(x_0)\). This is exactly the harmonic oscillator potential.
Physical examples: A mass on a spring, a pendulum for small angles, an LC circuit, molecular vibrations, phonons in a crystal lattice, and the quantum harmonic oscillator that underpins quantum field theory.
1.2 Equation of Motion and General Solution
Derivation 1: Newton's Second Law for SHM
For a mass \(m\) attached to an ideal spring with spring constant \(k\), the restoring force is \(F = -kx\). Applying Newton's second law:
This is a second-order linear ODE with constant coefficients. We try \(x = e^{i\alpha t}\):
The general solution is a linear combination of the two independent solutions:
General Solution of SHM
where \(A\) is the amplitude and \(\phi\) is the initial phase, both determined by initial conditions. Equivalently:\(x(t) = C_1\cos(\omega_0 t) + C_2\sin(\omega_0 t)\).
Key Parameters
Angular frequency
rad/s
Period
seconds
Frequency
Hertz (Hz)
1.3 Energy in Simple Harmonic Motion
Derivation 2: Energy Conservation
The kinetic and potential energies of a spring-mass system are:
Using \(k = m\omega_0^2\), the total energy is:
Total Energy
Energy oscillates between kinetic and potential forms, but the total is conserved. The time-averaged kinetic and potential energies are each equal to \(E/2\).
This equipartition of energy between kinetic and potential forms is a hallmark of the harmonic oscillator and persists even in the quantum mechanical treatment, where the ground-state energy \(E_0 = \frac{1}{2}\hbar\omega_0\) is split equally between kinetic and potential contributions.
1.4 The Simple Pendulum
Derivation 3: Pendulum as a Harmonic Oscillator
A mass \(m\) suspended from a string of length \(\ell\) swings under gravity. The torque about the pivot is \(\tau = -mg\ell\sin\theta\). Using \(\tau = I\ddot{\theta}\)with \(I = m\ell^2\):
For small angles, \(\sin\theta \approx \theta\), so the equation becomes:
Small-Angle Pendulum
The period is independent of mass and amplitude (for small oscillations). This isochronous property was discovered by Galileo around 1602 and later used by Huygens to build the first pendulum clock in 1656.
Beyond Small Angles
For larger amplitudes \(\theta_0\), the exact period involves an elliptic integral:
1.5 The LC Circuit
Derivation 4: Electrical Oscillations
An inductor \(L\) and capacitor \(C\) connected in a loop form an electrical oscillator. Using Kirchhoff's voltage law:
The analogy between mechanical and electrical oscillators is exact:
| Mechanical | Electrical | Role |
|---|---|---|
| Mass \(m\) | Inductance \(L\) | Inertia |
| Spring constant \(k\) | \(1/C\) | Restoring force |
| Displacement \(x\) | Charge \(Q\) | Generalized coordinate |
| Velocity \(\dot{x}\) | Current \(I\) | Generalized velocity |
| Damping \(b\) | Resistance \(R\) | Dissipation |
Energy in the LC Circuit
Energy oscillates between magnetic (inductor) and electric (capacitor) forms, analogous to kinetic and potential energy in the mass-spring system.
1.6 Initial Conditions and Phase Space
The general solution \(x(t) = A\cos(\omega_0 t + \phi)\) contains two constants determined by the initial conditions \(x(0) = x_0\) and\(\dot{x}(0) = v_0\):
Alternatively, writing \(x(t) = C_1\cos(\omega_0 t) + C_2\sin(\omega_0 t)\), we identify \(C_1 = x_0\) and \(C_2 = v_0/\omega_0\) directly.
Phase Space Representation
Plotting \(x\) vs \(p = m\dot{x}\) (or equivalently\(x\) vs \(\dot{x}/\omega_0\)) creates a phase portrait. For the SHO, trajectories are ellipses centered at the origin:
Each ellipse corresponds to a constant energy \(E = \frac{1}{2}m\omega_0^2 A^2\). The motion is always clockwise (for \(x\) vs \(p\) axes), reflecting the fact that positive momentum means increasing position. The origin is a stable equilibrium (an elliptic fixed point).
Phase space is a powerful tool because it applies to any dynamical system, not just the SHO. For a nonlinear oscillator, the phase portrait reveals qualitative behavior: stable and unstable equilibria, limit cycles, and separatrices. The SHO phase portrait is the linearization of any oscillatory system near a stable equilibrium.
Liouville's theorem: In Hamiltonian mechanics, the phase-space area enclosed by any trajectory is conserved in time. For the SHO, each ellipse has area \(2\pi E/\omega_0\). In quantum mechanics, this area is quantized in units of \(h\), leading to \(E_n = (n + \frac{1}{2})\hbar\omega_0\).
1.6b Superposition and Lissajous Figures
When a particle undergoes SHM simultaneously in two perpendicular directions with possibly different frequencies and phases:
The resulting trajectory in the \(xy\)-plane is a Lissajous figure. When \(\omega_x/\omega_y\) is a rational number \(p/q\), the path closes after \(q\) periods in \(x\) and \(p\)periods in \(y\). Key cases:
\(\omega_x = \omega_y\)
Ellipse (becomes line for \(\delta = 0, \pi\); circle for\(\delta = \pm\pi/2\) with equal amplitudes). This is precisely the polarization ellipse of Chapter 7.
\(\omega_x/\omega_y = 2\)
Figure-eight or bowtie pattern, depending on the phase difference. Used historically to determine frequency ratios in acoustics.
Irrational ratio
The trajectory never closes and eventually fills a rectangle โ this is the ergodic motion of a 2D oscillator with incommensurate frequencies.
Lissajous figures were first studied by Nathaniel Bowditch (1815) and later popularized by Jules Antoine Lissajous (1857), who displayed them using tuning forks and mirrors. Today they appear on oscilloscopes for comparing signal frequencies and phases.
1.6c Preview: The Quantum Harmonic Oscillator
In quantum mechanics, the harmonic oscillator becomes even more important. The Hamiltonian is:
The energy eigenvalues are quantized:
Quantum Energy Levels
The ground state energy \(E_0 = \frac{1}{2}\hbar\omega_0\) is the zero-point energy, a purely quantum effect with no classical analog. Equal spacing \(\Delta E = \hbar\omega_0\) between levels means the quantum oscillator emits/absorbs photons of a single frequency, matching the classical result.
The quantum harmonic oscillator is exactly solvable using either the power series method (Hermite polynomials) or the elegant algebraic method of raising and lowering operators (\(\hat{a}^\dagger\) and \(\hat{a}\)). This algebraic approach generalizes to quantum field theory, where each mode of the electromagnetic field is a quantum harmonic oscillator โ the "photon" is a quantum of excitation.
Connection to fields: A free quantum field is an infinite collection of harmonic oscillators, one for each momentum mode. The vacuum energy is the sum of all zero-point energies, leading to the Casimir effect and the cosmological constant problem.
1.6 Complex Notation
Derivation 5: Phasor Representation
A powerful technique is to represent oscillations using complex exponentials. We write:
The complex amplitude \(\tilde{A}\) encodes both the amplitude and phase. This notation simplifies algebraic manipulations enormously: differentiation becomes multiplication by \(i\omega_0\), and adding oscillations of the same frequency becomes adding complex numbers (phasor addition).
For the velocity and acceleration:
Why complex notation? When we add driven forces and damping in the next chapter, the complex exponential approach turns a second-order ODE into a simple algebraic equation. This is the standard approach in electrical engineering (AC circuit analysis) and throughout wave physics.
1.7 Applications
Quartz Crystal Oscillators
The piezoelectric effect in quartz crystals creates a mechanical resonator with\(Q \sim 10^5\). The resonant frequency is extremely stable, making quartz oscillators the basis of modern timekeeping in watches, computers, and telecommunications.
MEMS Accelerometers
Micro-electromechanical systems (MEMS) in smartphones use tiny spring-mass systems etched in silicon. Measuring the displacement of the mass reveals acceleration, enabling screen rotation, step counting, and navigation.
Molecular Vibrations
Atoms in molecules vibrate about their equilibrium bond lengths. These vibrations are well-modeled as harmonic oscillators and are probed by infrared spectroscopy. Each vibrational mode has a characteristic frequency that identifies functional groups.
Gravitational Wave Detectors
LIGO uses suspended mirrors as test masses in a giant interferometer. Understanding the harmonic oscillator response of these suspensions to gravitational waves was essential for the 2015 detection of gravitational waves from merging black holes.
1.8 Historical Context
Galileo Galilei (1602): Discovered the isochronous property of the pendulum by timing the swings of a chandelier in the Pisa Cathedral using his pulse as a clock. He realized that the period of oscillation was independent of amplitude for small swings.
Robert Hooke (1660): Published his law of elasticity, \(F = -kx\), initially as an anagram "ceiiinosssttuv" (Latin for "ut tensio, sic vis" โ as the extension, so the force). This linear restoring force is the defining feature of the harmonic oscillator.
Christiaan Huygens (1656): Built the first pendulum clock, achieving an accuracy of about 15 seconds per day โ a dramatic improvement over earlier mechanical clocks. His work on the cycloidal pendulum showed deep understanding of oscillatory mechanics.
Leonhard Euler (1739): Provided the complete mathematical framework for solving linear differential equations with constant coefficients, including the complex exponential solutions that we use today.
Lord Rayleigh (1877): In "The Theory of Sound," Rayleigh systematized the study of vibrations and oscillations, establishing many results we still use, including the Rayleigh quotient for estimating natural frequencies.
1.9 Python Simulation
This simulation visualizes simple harmonic motion, energy exchange, the pendulum period as a function of amplitude, and the phase-space trajectory.
Simple Harmonic Oscillator: SHM, Energy, Pendulum, and Phase Space
PythonClick Run to execute the Python code
Code will be executed with Python 3 on the server
Summary
Core Equations
- EOM: \(\ddot{x} + \omega_0^2 x = 0\)
- Solution: \(x = A\cos(\omega_0 t + \phi)\)
- Energy: \(E = \frac{1}{2}kA^2\)
- Pendulum: \(T = 2\pi\sqrt{\ell/g}\)
- LC circuit: \(\omega_0 = 1/\sqrt{LC}\)
Key Insights
- Any stable equilibrium is approximately harmonic
- Energy is conserved: \(\langle T \rangle = \langle V \rangle = E/2\)
- Period is amplitude-independent (isochrony)
- Mechanical-electrical analogy is exact
- Complex notation simplifies calculations
Practice Problems
Problem 1: Period of a Compound PendulumA uniform rod of length $L = 1.2$ m and mass $M = 2$ kg is pivoted at a point $d = 0.3$ m from its center of mass. Find the period of small oscillations.
Solution:
1. For a compound (physical) pendulum, the period of small oscillations is:
2. The moment of inertia of a uniform rod about its center is $I_{cm} = \frac{1}{12}ML^2$. By the parallel axis theorem:
3. The restoring torque about the pivot is $\tau = -Mgd\sin\theta \approx -Mgd\theta$ for small angles.
4. Substituting into the period formula:
5. Evaluating:
The equivalent simple pendulum length is $\ell_{eq} = I_{\text{pivot}}/(Md) = 0.42/0.6 = 0.70$ m. This is longer than $d$ because the distributed mass increases the effective inertia.
Problem 2: Energy of a Spring-Mass SystemA 0.5 kg mass on a spring ($k = 200$ N/m) oscillates with amplitude 4 cm. Calculate the total energy, maximum velocity, and the position where kinetic and potential energies are equal.
Solution:
1. The total energy of a simple harmonic oscillator equals the maximum potential energy:
2. Maximum velocity occurs at the equilibrium position ($x = 0$) where all energy is kinetic:
3. Alternatively, $v_{\max} = \omega A = \sqrt{k/m}\,A = \sqrt{400}\times 0.04 = 20 \times 0.04 = 0.80$ m/s. Confirmed.
4. When KE = PE, each equals $E/2$. Since $PE = \frac{1}{2}kx^2 = E/2$:
5. Therefore:
This is the position at phase angle $\pi/4$ (45ยฐ) from equilibrium, which is roughly 70.7% of the amplitude.
Problem 3: LC Circuit Resonance FrequencyAn LC circuit has $L = 50$ mH and $C = 20$ $\mu$F. Find the resonance frequency, the period of oscillation, and the peak current if the capacitor is initially charged to 12 V.
Solution:
1. The angular resonance frequency of an LC circuit is:
2. The frequency and period:
3. The initial energy stored in the capacitor is:
4. At peak current, all energy is in the inductor ($\frac{1}{2}LI_{\max}^2 = E$):
5. The peak current is:
Equivalently, $I_{\max} = V_0\sqrt{C/L} = 12\sqrt{(20\times10^{-6})/(50\times10^{-3})} = 12 \times 0.02 = 0.24$ A. The LC circuit is the electrical analog of the spring-mass system with $L \leftrightarrow m$ and $1/C \leftrightarrow k$.
Problem 4: Quality Factor from Amplitude DecayA damped oscillator with natural frequency $f_0 = 500$ Hz has its amplitude decrease to $e^{-1}$ of its initial value after 200 oscillations. Calculate the damping coefficient $\gamma$ and the quality factor $Q$.
Solution:
1. The amplitude of a damped oscillator decays as $A(t) = A_0\,e^{-\gamma t/2}$. The amplitude drops to $e^{-1}$ when:
2. This occurs after 200 oscillations, so $t = 200T = 200/f_0 = 200/500 = 0.4$ s:
3. The quality factor is defined as:
4. Therefore:
5. Physical interpretation: $Q = 2\pi \times (\text{energy stored})/(\text{energy lost per cycle})$. The system loses a fraction $\Delta E/E = 2\pi/Q \approx 0.01$ of its energy per cycle. After $Q/\pi \approx 200$ cycles, the energy drops by $e^{-2}$ (amplitude by $e^{-1}$), consistent with the given data. This high Q indicates a lightly damped resonator.
Problem 5: Coupled Oscillators โ Normal ModesTwo identical masses $m$ are connected by springs: each mass is attached to a wall by a spring of constant $k$, and they are coupled to each other by a spring of constant $k_c$. Find the normal mode frequencies. Evaluate for $m = 0.1$ kg, $k = 40$ N/m, $k_c = 10$ N/m.
Solution:
1. The equations of motion for displacements $x_1$ and $x_2$ from equilibrium are:
2. Introduce symmetric and antisymmetric coordinates: $q_+ = x_1 + x_2$, $q_- = x_1 - x_2$:
3. The normal mode frequencies are:
4. Substituting numerical values:
5. Results:
In the symmetric mode ($\omega_+$), both masses move together and the coupling spring is never stretched. In the antisymmetric mode ($\omega_-$), the masses move oppositely, and the coupling spring contributes additional restoring force $2k_c$, raising the frequency. The beat frequency for energy exchange is $\Delta\omega = 4.5$ rad/s.