Hello! Welcome to your lesson on Simple Harmonic Motion.
In our last lesson, we concluded our study of rotational dynamics with the powerful principle of conservation of angular momentum. As previewed, we are now shifting our focus to another fundamental topic in mechanics: oscillatory motion.
Many systems in nature, from the vibration of a guitar string to the swaying of a skyscraper, exhibit periodic motion. The most fundamental and ubiquitous type of periodic motion is Simple Harmonic Motion (SHM). It serves as the basis for understanding more complex oscillations and waves.
Today's lesson will equip you to derive and solve the equation of motion for simple harmonic motion (SHM) from physical principles. We will start with a classic physical system, use Newton's laws to obtain its governing differential equation, and then explore several powerful methods to solve it, leveraging your growing calculus skills.
1. The Equation of Motion for SHM
Let's consider the archetypal example of SHM: a mass attached to a horizontal spring with spring constant , sliding on a frictionless surface.

We can derive the equation of motion by following these steps:
-
Identify the Force: According to Hooke's Law, an ideal spring exerts a restoring force that is linearly proportional to the displacement from its equilibrium position. The negative sign indicates the force is always directed opposite to the displacement.
-
Apply Newton's Second Law: The net force on the mass causes it to accelerate.
-
Combine the Laws: By equating the two expressions for the force, we get the equation of motion for the mass-spring system.
Rearranging this equation gives us the standard form of the Simple Harmonic Oscillator (SHO) equation:
This is a second-order, linear, homogeneous ordinary differential equation with constant coefficients. Its properties are central to all of physics.
We define the natural angular frequency as:
This intrinsic frequency depends only on the physical properties of the system (mass and spring stiffness). The SHO equation can now be written more compactly as:
where is shorthand for .
For a clear walkthrough of this derivation, watch the beginning of the following video.
Second-Order Ordinary Differential Equations: Solving the Harmonic Oscillator Four Ways
This video by Steve Brunton provides an excellent derivation of the harmonic oscillator equation from first principles using the mass-spring system.
Watch the first 6 minutes and 40 seconds of the video. Pay attention to how Newton's Second Law and Hooke's Law combine to form the second-order differential equation.
This same mathematical form appears in many other physical systems. For example, a simple pendulum of length oscillating at small angles is described by . This shows the universality of the SHO equation.
2. Solving the SHO Equation
Now that we have the equation, how do we find the function that describes the position of the mass over time? Since this is a differential equation, its solution isn't just a number, but a function. We will explore two key methods.
Method 1: The "Physics Guess" - Sinusoidal Solutions
Our physical intuition tells us that the mass will oscillate back and forth. The simplest mathematical functions that describe oscillation are sines and cosines. Let's make an educated guess (an ansatz) that the solution is a combination of these:
where and are constants. To verify this, we take two derivatives:
So, we have , which is exactly our SHO equation . Our guess is correct!
The constants and are determined by the initial conditions of the motion—the position and velocity at .
- At , . So, .
- At , . So, .
Therefore, the specific solution for a given set of initial conditions is:
The following reading provides a detailed, step-by-step derivation of this general solution and how to determine the constants from initial conditions.
8.01SC S22 Chapter 23: Simple Harmonic Motion
This section from the MIT OpenCourseWare notes for Classical Mechanics provides a clear, analytic derivation of the solution to the SHO equation and shows how to apply initial conditions.
Please read section '23.2 Simple Harmonic Motion: Analytic' and subsection '23.2.1 General Solution of Simple Harmonic Oscillator Equation'. Focus on how the guess is verified (Eq. 23.2.5), how the general solution is formed as a sum of sine and cosine (Eq. 23.2.16), and how the constants are determined (Eq. 23.2.18 to 23.2.20).
Method 2: The Systematic Approach - Complex Exponentials
While guessing works well here, a more powerful and systematic method for linear ODEs uses complex numbers. This approach is fundamental in advanced physics and engineering.
We guess a solution of the form . The beauty of the exponential function is that its derivative is proportional to itself. Substituting this into gives:
Since is never zero, we can divide it out, leaving the characteristic equation:
This gives us two complex solutions: and .
Because the SHO equation is linear, any linear combination of solutions is also a solution (this is the principle of superposition). So, the general complex solution is:
However, the position must be a real number. For to be real, it must equal its own complex conjugate, . This condition forces the constants to be related: . This ensures that the imaginary parts cancel out, leaving a real, physical solution.
Using Euler's formula, , this complex form can be shown to be equivalent to our previous sinusoidal solution.
This method might seem like a detour, but it is the standard, rigorous way to solve all linear ODEs with constant coefficients, which appear constantly in physics (e.g., in circuits, quantum mechanics, and damped/driven oscillations).
Second-Order Ordinary Differential Equations: Solving the Harmonic Oscillator Four Ways
Let's see this powerful method in action. The same video from Steve Brunton that we started with also explains this exponential approach beautifully.
Watch the section on using an exponential guess, which starts around 23:46 and ends at 33:24. Focus on how the guess x(t) = e^{\lambda t} leads to the characteristic equation and complex eigenvalues, and how Euler's formula connects the complex exponential solution back to the real-world sinusoidal motion.
3. Interpreting the Solution: Amplitude, Frequency, and Phase
The general solution for SHM, , can be rewritten in a more physically intuitive form using a trigonometric identity:
Here:
- Amplitude (): The maximum displacement from equilibrium. It is determined by the initial conditions: .
- Phase Constant (): The phase angle that determines the position of the object at . It is also set by initial conditions: .
- Period (): The time for one complete oscillation. .
- Frequency (): The number of oscillations per second. . Measured in Hertz (Hz).
Notice the crucial distinction: (angular frequency) is an intrinsic property of the system, while and are determined by how you start the motion.

Test your understanding!
A 0.5 kg mass is attached to a spring with a spring constant of 50 N/m. It is pulled to a position m and released from rest ().
- What is the natural angular frequency ?
- What are the amplitude and phase constant ? (Assume )
- Write the equation of motion .
Show answer
- .
- The amplitude is m.
The phase constant is found from . Since m is positive, we need , so we choose . - The equation of motion is meters.
4. Engineering Application: Natural Frequency and Static Equilibrium
One of the most important takeaways for engineering is the concept of natural frequency. Every elastic structure, from a bridge to an airplane wing, has one or more natural frequencies at which it will oscillate if disturbed.
If an external periodic force is applied at or near this natural frequency, the amplitude of the vibrations can increase dramatically, leading to structural failure. This phenomenon is called resonance, and we will study it in depth in a future lesson. A key part of mechanical design is to calculate a system's natural frequencies to ensure they are far from any driving frequencies the system will experience during operation (e.g., from an engine or from wind).
The following video from MIT OpenCourseWare discusses the importance of natural frequency and introduces a key technique: analyzing oscillations around the static equilibrium position.
19. Introduction to Mechanical Vibration
This MIT lecture excerpt discusses how to properly set up the equation of motion to find the natural frequency, and highlights an important simplification: if you measure displacement from the static equilibrium position, constant forces like gravity often drop out of the dynamic equation.
Watch from 13:07 to 30:20. The first part (13:07 - 19:19) shows how to simplify the equation of motion by defining your coordinate system around the static equilibrium point. The second part (20:11 - 30:20) derives the general solution and shows how initial conditions determine the final motion. This reinforces what we've learned and puts it in a practical context.
Conclusion
In this lesson, we took a deep dive into the foundations of oscillatory motion. We saw how a simple physical system with a linear restoring force leads to the universal equation of Simple Harmonic Motion.
Key Takeaways:
- Simple Harmonic Motion is described by the second-order ODE: .
- This equation arises from applying physical principles (like Newton's Second Law and Hooke's Law) to systems near a point of stable equilibrium.
- The general solution is sinusoidal: .
- The natural angular frequency (e.g., ) is an intrinsic property of the system's physics.
- The amplitude and phase constant are determined by the initial conditions ().
- Solving the SHO equation can be done by physical intuition (guessing sinusoids) or more systematically using complex exponentials, a powerful technique for all linear ODEs.
Preview of the Next Lesson:
Our model so far has been an idealization. In the real world, nearly all oscillating systems experience some form of friction or drag, which causes the motion to die out. In our next lesson, we will introduce a damping force and analyze damped harmonic oscillators. We'll discover the different ways a system can return to equilibrium—underdamped, overdamped, and critically damped—by solving a slightly more complex differential equation.