15.2 Comparing Exact, Approximate, and Numerical Solutions
Three Answers to the Same Problem
Here is a differential equation that appears everywhere in physics:
$$m\frac{d^2x}{dt^2} + b\frac{dx}{dt} + kx = 0$$
This is the damped harmonic oscillator --- a mass on a spring with friction. You have studied it in Chapter 13. It has an exact, closed-form solution:
$$x(t) = Ae^{-\gamma t}\cos(\omega_d t + \phi)$$
where $\gamma = b/2m$ is the damping rate and $\omega_d = \sqrt{\omega_0^2 - \gamma^2}$ is the damped frequency.
That solution took a page of algebra to derive. It handles every parameter value (in the underdamped regime). It is correct to infinite precision for all time. It is the gold standard.
Now here is a second answer to the same problem. If the damping is small, you might ignore it entirely and write:
$$x(t) \approx A\cos(\omega_0 t + \phi)$$
Two lines. No exponential decay. The frequency is the natural frequency $\omega_0 = \sqrt{k/m}$, not the shifted $\omega_d$. This approximation says: "the oscillation looks roughly sinusoidal, and the amplitude does not change much over a few cycles." For weak damping, this is 3% off over the first few periods. For strong damping, it is useless.
And here is a third answer. Open a computer, write the Euler method update from Section 4.5:
$$v_{n+1} = v_n + a_n \Delta t, \qquad x_{n+1} = x_n + v_n \Delta t$$
with $a_n = -(k/m)x_n - (b/m)v_n$. Run it for 10,000 steps with $\Delta t = 0.001$ s. The result: six decimal places of accuracy in a tenth of a second of computation. No algebra required. No closed-form formula. Just a column of numbers that traces the motion.
Three answers. Same problem. Which one is "best"?
Before you read on: Consider this situation. You are designing a car suspension system (a damped spring). You need to know how the suspension responds to a bump. Would you rather have:
(a) The exact formula, so you can see how the response depends on every parameter?
(b) The undamped approximation, so you can quickly estimate the bounce frequency?
(c) A numerical simulation, so you can handle the full nonlinear spring and real road profile?
Write down your choice and your reasoning. There is no single correct answer --- that is the point.
The Damped Oscillator: A Concrete Comparison
Let us make this tangible with specific numbers. Consider a system with:
- Mass: $m = 1.0$ kg
- Spring constant: $k = 100$ N/m (so $\omega_0 = 10$ rad/s)
- Initial displacement: $x_0 = 0.1$ m, released from rest
We will compare the three solution methods for two different damping values: weak damping ($b = 1.0$ kg/s, so $\gamma = 0.5$ s$^{-1}$) and moderate damping ($b = 6.0$ kg/s, so $\gamma = 3.0$ s$^{-1}$).
Weak damping: $\gamma/\omega_0 = 0.05$
The exact solution gives:
$$x(t) = 0.1\, e^{-0.5t}\cos(9.987t)$$
The damped frequency $\omega_d = \sqrt{100 - 0.25} = 9.987$ rad/s is nearly identical to $\omega_0 = 10$ rad/s. The period is $T_d = 0.6290$ s versus $T_0 = 0.6283$ s. Over the first five periods, the amplitude drops by a factor of $e^{-0.5 \times 3.14} \approx 0.21$ --- the oscillation is visibly decaying, but the frequency is barely shifted.
The undamped approximation gives:
$$x(t) \approx 0.1\cos(10t)$$
For the first two or three cycles, this looks almost indistinguishable from the exact solution on a graph. The frequency error is 0.13%. The amplitude error grows with time (the approximation does not decay), but over a few periods, it is small. After five periods, the exact amplitude has dropped to about 0.021 m while the approximation still says 0.1 m. The approximation is good for short times and terrible for long times.
The numerical (Euler) solution with $\Delta t = 0.01$ s tracks the exact solution well for the first few periods but slowly drifts. The drift is a discretization artifact: Euler's method slightly overshoots at each step, and the errors accumulate. Halving the step size to $\Delta t = 0.005$ s cuts the error roughly in half. Using a better algorithm (like the fourth-order Runge-Kutta method) virtually eliminates the drift.
Pause and think: At weak damping, the undamped approximation matches the exact solution well for a few periods but then diverges. The Euler method matches well at small step sizes but drifts at larger ones. These are two completely different kinds of error. Can you articulate the difference?
The approximation error comes from simplifying the physics --- ignoring a real effect (damping). The numerical error comes from discretizing the mathematics --- replacing a continuous process with finite steps. One is a modeling choice. The other is a computational limitation.
Moderate damping: $\gamma/\omega_0 = 0.3$
Now the story changes. The exact solution gives:
$$x(t) = 0.1\, e^{-3.0t}\cos(9.539t)$$
The damped frequency $\omega_d = 9.539$ rad/s is noticeably lower than $\omega_0 = 10$, a shift of about 4.6%. The amplitude drops by a factor of $e^{-3.0 \times 0.66} \approx 0.14$ in just one period. The oscillation dies out fast.
The undamped approximation $x(t) \approx 0.1\cos(10t)$ is now poor from the start. The frequency is wrong by 4.6%, which means the approximate solution drifts out of phase within two cycles. And it predicts constant amplitude when the real amplitude is plummeting. By the end of the first period, the exact amplitude is already down to 0.014 m while the approximation still says 0.1 m. The approximation has failed qualitatively, not just quantitatively --- it predicts steady oscillation when the real system is rapidly damping out.
The numerical solution with a reasonable step size still works fine. The Euler method needs a small enough $\Delta t$ (roughly $\Delta t \ll 1/\omega_0$, so $\Delta t \ll 0.1$ s), but given that, it tracks the exact solution faithfully. It does not care whether the damping is weak or strong. It just follows the equation.
What Each Method Is Good For
The comparison above reveals a pattern. Each solution type has characteristic strengths and weaknesses, and they are not the same strengths and weaknesses.
| Exact (analytic) | Approximate (analytic) | Numerical | |
|---|---|---|---|
| Accuracy | Perfect (within the model) | Good in a limited regime; can fail qualitatively outside it | Controllable: improve by reducing step size |
| Insight | High --- shows how the answer depends on every parameter | Very high --- often the clearest view of dominant behavior | Low --- gives numbers, not structure |
| Effort | Can be enormous; many equations have no closed form | Usually low --- that is the whole point | Low to moderate, depending on the algorithm |
| Generality | Only works for solvable equations | Only works near the regime where the approximation holds | Works for almost any equation, solvable or not |
| What it answers best | "How does the behavior depend on parameters?" | "What is the dominant effect?" and "What is the rough scale?" | "What happens for these specific numbers?" |
This table is worth studying. Notice that no single method dominates all the rows. The exact solution wins on accuracy and loses on effort and generality. The approximation wins on insight and effort but loses on accuracy and range. The numerical solution wins on generality and loses on insight.
Pause and think: You encounter a differential equation that describes the oscillation of a bridge in the wind. The equation includes nonlinear terms that make it unsolvable in closed form. You need to know whether the bridge oscillation grows or decays over time. Which approach would you start with, and why?
One reasonable strategy: start with a linearized approximation to understand the qualitative behavior (does the oscillation grow or decay?), then use a numerical simulation with the full nonlinear equation to check the approximation and get precise amplitudes. The exact solution is not available --- but you do not need it if the other two methods cover your question.
When Approximations Are "Good Enough"
The phrase "good enough" is doing serious work here, and it deserves scrutiny. An approximation is not good or bad in the abstract --- it is good or bad relative to a question.
Consider the undamped approximation for the damped oscillator. Is it "good enough"?
-
If your question is: "What is the oscillation frequency to within 1%?" Then the approximation is good enough whenever $\gamma/\omega_0 < 0.14$, because the frequency error is $\omega_0 - \omega_d \approx \gamma^2/(2\omega_0)$, which is second-order in $\gamma$. For the weakly damped case above ($\gamma/\omega_0 = 0.05$), the frequency error is 0.13%. Good enough.
-
If your question is: "What is the amplitude after 10 seconds?" Then the approximation is never good enough for any nonzero damping, because it predicts constant amplitude while the true amplitude decays exponentially. The approximation gets the qualitative behavior wrong on long timescales.
-
If your question is: "Does the system oscillate or not?" Then the approximation is good enough whenever $\gamma < \omega_0$ (underdamped regime), because the approximation correctly predicts oscillation. But it fails when $\gamma \geq \omega_0$ (overdamped or critically damped), where the exact solution has no oscillation at all. The approximation would still predict oscillation when the system is actually decaying monotonically.
The lesson: you cannot judge an approximation without knowing the question. The same approximation can be excellent for one purpose and disastrous for another.
Before you read on: Here is a claim: "The small-angle approximation $\sin\theta \approx \theta$ is valid for angles below 15 degrees." Is this a meaningful statement? What is missing from it?
What is missing is the tolerance. The error at 15 degrees is about 1%. If your application requires 0.1% accuracy, the approximation fails above about 5 degrees. If you only need 10% accuracy, it is fine up to about 40 degrees. The "valid below 15 degrees" rule only makes sense once you specify how much error you are willing to accept.
Principled Approximation vs. Sloppy Guessing
Section 4.4 introduced linearization as a deliberate, controlled technique. In this capstone section, it is worth articulating what separates a principled approximation from a sloppy one, because this distinction is one of the most important things you can take from a physics course.
A principled approximation has four features:
-
A stated small parameter. You must identify what is small and say so explicitly. "We approximate because $\gamma/\omega_0 \ll 1$" is principled. "We approximate because it's easier" is not.
-
A controlled expansion. The approximation should be the leading term of a systematic expansion. You should be able to write the next correction term, even if you choose not to compute it. For the damped oscillator: $\omega_d = \omega_0\sqrt{1 - (\gamma/\omega_0)^2} \approx \omega_0\left(1 - \frac{1}{2}(\gamma/\omega_0)^2\right)$. The correction term tells you the size of the error.
-
A validity condition. You should know when the approximation breaks down. "This is valid for $\gamma/\omega_0 < 0.1$" is principled. "This is valid for small damping" is vague.
-
A way to check. You should be able to verify the approximation against a more accurate method --- exact solution, numerical simulation, or experiment --- at least for some test cases.
If your approximation has all four features, you are doing what every working physicist does. If it is missing any of them, you are guessing, and guessing is fragile.
This is worth saying directly: approximation is not a concession to laziness. It is an expert skill. The best physicists in the world spend most of their time making approximations. But they make principled approximations, and they always know the boundaries of validity.
When Numerical Solutions Go Wrong
Numerical methods have their own failure modes, and they are different from approximation failures. The most common problems for the Euler-type methods you learned in Section 4.5 are:
Step size too large. If $\Delta t$ is not small compared to the timescales of the problem, the numerical solution oscillates wildly, grows without bound, or drifts away from the true solution. For the harmonic oscillator with frequency $\omega_0$, you need $\Delta t \ll 2\pi/\omega_0$ (the period). If $\omega_0 = 10$ rad/s, the period is 0.63 s, and you need $\Delta t$ much smaller than this --- say 0.01 s or less. If you use $\Delta t = 0.5$ s, the solution will be garbage.
Accumulated drift. Even with a reasonable step size, Euler's method introduces a small error at each step. Over many steps, these errors accumulate. For conservative systems (like an undamped oscillator), the Euler method gradually adds energy to the system, making the amplitude grow over time. The true solution conserves energy; the numerical one does not. This is a systematic artifact of the algorithm, not random noise.
Stiff equations. Some differential equations have both fast and slow timescales. To track the fast dynamics, you need a tiny $\Delta t$. But the motion you care about happens on the slow timescale, which means you need an enormous number of steps. Standard Euler methods become impractical. Specialized "stiff solvers" exist for these problems, but they are beyond our scope.
[Interactive: Three-Panel Solution Comparator. The screen shows three synchronized panels, each plotting $x(t)$ for the damped harmonic oscillator.
Left panel: The exact analytic solution $x(t) = Ae^{-\gamma t}\cos(\omega_d t + \phi)$.
Center panel: The undamped approximation $x(t) = A\cos(\omega_0 t + \phi)$.
Right panel: The Euler method numerical solution, built step by step.
Controls:
- A slider for the damping parameter $\gamma$ (from 0 to $\omega_0$).
- A slider for the Euler step size $\Delta t$ (from 0.001 s to 0.2 s).
- A time window slider (show the first 1, 5, 10, or 20 periods).
Guided exploration:
- "Set $\gamma = 0.1\omega_0$ and $\Delta t = 0.01T_0$. All three curves should look nearly identical. This is the regime where all three methods agree."
- "Now increase $\gamma$ slowly. At what value do the center and left panels start to visibly disagree? Which feature --- frequency or amplitude --- diverges first?"
- "Reset $\gamma$ to $0.1\omega_0$. Now increase $\Delta t$. At what step size does the right panel start to drift? Does it drift in amplitude, in phase, or both?"
- "Set $\gamma = 0.5\omega_0$ and $\Delta t = 0.1T_0$. Now both the approximation and the numerical solution are failing, but for completely different reasons. Describe each failure."
- "Challenge: find parameter values where the approximation is accurate but the numerical solution is not. Then find values where the opposite is true."]
A Harder Example: The Nonlinear Pendulum
The damped oscillator is a convenient testbed because it has an exact solution. But the real power of this three-way comparison shows up when the exact solution does not exist.
The equation of motion for a pendulum (without the small-angle approximation) is:
$$\frac{d^2\theta}{dt^2} = -\frac{g}{L}\sin\theta$$
This equation has no closed-form solution in terms of elementary functions. (It can be expressed using elliptic integrals, but those are essentially defined by this equation --- so the "exact solution" is just a name for the problem, not a simplification of it.)
Here, your three methods give:
-
Exact analytic: Not available in elementary form. The solution exists and is unique (existence and uniqueness theorems guarantee this), but you cannot write it as a formula involving $\sin$, $\cos$, $e^x$, etc.
-
Small-angle approximation: Replace $\sin\theta \approx \theta$. The equation becomes $\ddot{\theta} = -(g/L)\theta$, which is simple harmonic motion with $\omega_0 = \sqrt{g/L}$ and period $T_0 = 2\pi\sqrt{L/g}$. This is the formula you have been using since Chapter 13.
-
Numerical solution: Apply Euler's method (or a better algorithm) to the full nonlinear equation. No difficulty at all --- the computer does not care whether the equation is linear or nonlinear.
Pause and think: The small-angle approximation predicts that the pendulum period is independent of amplitude: $T_0 = 2\pi\sqrt{L/g}$, regardless of how far you pull it. But the exact (nonlinear) pendulum does have an amplitude-dependent period. For a swing of 90 degrees, the true period is about 18% longer than $T_0$.
Which method --- approximation or numerical --- would you use to discover that the period depends on amplitude? The approximation cannot reveal this, because the amplitude dependence was precisely the thing that was thrown away in the linearization. Only the numerical solution (or the elliptic integral expression) captures it.
This example reveals something important. The exact analytic solution, when it exists, can show you everything. But when it does not exist, you face a real choice between an approximation that is transparent but limited and a numerical solution that is complete but opaque. Often the best strategy is to use both: the approximation to understand the qualitative behavior, and the numerical simulation to check it and fill in the details.
Choosing Your Tool: A Decision Framework
By now you have three tools in your kit for solving differential equations, and you have seen that each has a natural domain. Here is a practical framework for choosing among them.
Start with the exact solution --- if it exists and you can find it. Exact solutions are the gold standard. They show you how the answer depends on every parameter. They never drift. They work for all times. If the equation is one you recognize (constant coefficients, separable, linear with known techniques), solve it exactly. You have built this skill through Chapters 4 and 13.
Use an approximation when: (a) the exact solution does not exist or is too complex to interpret, (b) you need a quick estimate or a scaling law, or (c) you want to understand which effects dominate. But always identify your small parameter, state the validity condition, and check against a more accurate method.
Use a numerical solution when: (a) the equation has no closed form, (b) you need precise numbers for specific parameter values, (c) the system is too complex for analytic treatment (multiple coupled equations, time-varying parameters, nonlinearities), or (d) you want to check an approximation.
In practice, experts use all three. A typical workflow looks like this:
- Try to find an exact solution or recognize the equation type.
- If the exact solution is complex, make a principled approximation to extract the dominant behavior.
- Run a numerical simulation to verify the approximation and explore parameter space.
- Use the analytic results (exact or approximate) to interpret what the numerical simulation is showing.
This is not a hierarchy where one method outranks the others. It is an ecosystem where each method supports the others. The approximation tells you what to look for in the numerical output. The numerical simulation tells you where the approximation breaks down. The exact solution, when available, anchors everything.
Practice
Layer 1: Concrete
Problem 1. A mass-spring system with $m = 2.0$ kg, $k = 50$ N/m, and $b = 2.0$ kg/s is displaced to $x_0 = 0.2$ m and released from rest.
(a) Write the exact solution for $x(t)$.
(b) Write the undamped approximation for $x(t)$.
(c) Compute $x(t)$ at $t = 1.0$ s using both the exact solution and the approximation. What is the percentage error of the approximation?
(d) At what time does the approximation error in amplitude first exceed 10%?
Check your answer
First, identify the parameters: - $\omega_0 = \sqrt{k/m} = \sqrt{25} = 5.0$ rad/s - $\gamma = b/(2m) = 2.0/(2 \times 2.0) = 0.5$ s$^{-1}$ - $\omega_d = \sqrt{\omega_0^2 - \gamma^2} = \sqrt{25 - 0.25} = \sqrt{24.75} \approx 4.975$ rad/s - $\gamma/\omega_0 = 0.1$ (weak damping) **(a)** The exact solution (released from rest with $x_0 = 0.2$ m): $$x(t) = 0.2\, e^{-0.5t}\cos(4.975t)$$ (The phase $\phi$ is approximately zero for release from rest when damping is weak. More precisely, there is a small correction, but for $\gamma/\omega_0 = 0.1$ it is negligible.) **(b)** The undamped approximation: $$x(t) \approx 0.2\cos(5.0t)$$ **(c)** At $t = 1.0$ s: - Exact: $x(1.0) = 0.2\, e^{-0.5} \cos(4.975) = 0.2 \times 0.6065 \times 0.2837 \approx 0.0344$ m - Approximate: $x(1.0) = 0.2 \cos(5.0) = 0.2 \times 0.2837 \approx 0.0567$ m The approximation overestimates the magnitude because it does not include the exponential decay. The percentage error is $(0.0567 - 0.0344)/0.0344 \approx 65\%$. This large error illustrates that even with weak damping ($\gamma/\omega_0 = 0.1$), the amplitude error grows substantially over a few periods. **(d)** The amplitude envelope of the exact solution is $0.2\, e^{-0.5t}$. The approximation predicts constant amplitude $0.2$. The amplitude error exceeds 10% when: $$\frac{0.2 - 0.2\, e^{-0.5t}}{0.2\, e^{-0.5t}} > 0.10$$ $$e^{0.5t} - 1 > 0.10$$ $$e^{0.5t} > 1.10$$ $$t > 2\ln(1.10)/1.0 = 2 \times 0.0953 \approx 0.19 \text{ s}$$ The amplitude error exceeds 10% in less than one period ($T_0 \approx 1.26$ s). The approximation fails fast for amplitude, even when it works well for frequency.Problem 2. Using Euler's method with $\Delta t = 0.05$ s, compute the first 5 steps for the same system (starting from $x_0 = 0.2$ m, $v_0 = 0$). Compare $x$ at step 5 ($t = 0.25$ s) to the exact value. Then describe qualitatively what would happen if you used $\Delta t = 0.5$ s instead.
Check your answer
The update equations are: $$a_n = -(k/m)x_n - (b/m)v_n = -25x_n - v_n$$ $$v_{n+1} = v_n + a_n \Delta t$$ $$x_{n+1} = x_n + v_n \Delta t$$ | Step | $t$ (s) | $x$ (m) | $v$ (m/s) | $a$ (m/s$^2$) | |:---|:---|:---|:---|:---| | 0 | 0.00 | 0.2000 | 0.0000 | $-5.000$ | | 1 | 0.05 | 0.2000 | $-0.2500$ | $-4.750$ | | 2 | 0.10 | 0.1875 | $-0.4875$ | $-4.200$ | | 3 | 0.15 | 0.1631 | $-0.6975$ | $-3.380$ | | 4 | 0.20 | 0.1282 | $-0.8664$ | $-2.339$ | | 5 | 0.25 | 0.0849 | $-0.9834$ | $-1.139$ | At $t = 0.25$ s, the Euler result is $x \approx 0.085$ m. The exact solution gives $x(0.25) = 0.2\,e^{-0.125}\cos(1.244) \approx 0.2 \times 0.882 \times 0.324 \approx 0.057$ m. The Euler method overshoots the exact solution --- it has not yet turned around as sharply. The error is noticeable but manageable. With $\Delta t = 0.5$ s, the period is $T_0 \approx 1.26$ s, so each step spans nearly 40% of a full oscillation. The solution would miss the oscillatory behavior entirely, producing wild swings or divergent growth. The step size is simply too large to resolve the dynamics. As a rough rule, you need at least 10--20 steps per period for Euler's method to give reasonable results.Layer 2: Pattern
Problem 3. For each of the following differential equations, predict: (a) Can it be solved exactly in closed form? (b) Is there a useful approximation regime? (c) Would a numerical method be necessary for full generality?
- $\ddot{x} = -\omega_0^2 x$ (simple harmonic oscillator)
- $\ddot{\theta} = -(g/L)\sin\theta$ (nonlinear pendulum)
- $\dot{v} = g - cv^2$ (free fall with quadratic drag)
- $\ddot{x} = -\omega_0^2 x - \beta x^3$ (Duffing oscillator)
- $\dot{v} = g - cv^2\text{sgn}(v)$ (quadratic drag on a projectile in 2D, where direction matters)
Check your answer
| Equation | Exact? | Useful approximation? | Numerical needed? | |:---|:---|:---|:---| | 1. $\ddot{x} = -\omega_0^2 x$ | Yes. $x(t) = A\cos(\omega_0 t + \phi)$. This is the canonical solvable equation. | Not needed --- the exact solution is already simple. | Not needed, but useful for verification. | | 2. $\ddot{\theta} = -(g/L)\sin\theta$ | Not in elementary functions. Solvable with elliptic integrals. | Yes: $\sin\theta \approx \theta$ for small angles gives SHM. Excellent for $\theta_{\max} < 15°$. | Yes, for large-angle motion. Numerical methods handle all amplitudes equally well. | | 3. $\dot{v} = g - cv^2$ | Yes, by separation of variables. The solution involves $\tanh$. | Yes: for early times ($v \ll v_{\text{terminal}}$), ignore drag and get $v \approx gt$. For late times, $v \approx v_{\text{terminal}}$. | Not strictly needed (it is solvable), but numerical methods are convenient for the full trajectory $x(t)$. | | 4. $\ddot{x} = -\omega_0^2 x - \beta x^3$ | No closed-form solution in elementary functions. | Yes: for small $x$, the $\beta x^3$ term is negligible and the equation reduces to SHM. The approximation is good when $\beta x^2 \ll \omega_0^2$. | Yes, for large-amplitude motion where the nonlinear term matters. | | 5. Quadratic drag in 2D | No. The coupling between components and the $\text{sgn}(v)$ factor make this analytically intractable. | Limited: you can approximate early-time behavior as projectile motion without drag. | Yes. This is a case where numerical methods are essentially the only practical approach. | The pattern: linear equations with constant coefficients tend to be solvable exactly. Nonlinear equations (involving $\sin$, $x^3$, $v^2$, etc.) usually are not, except in special cases. Approximation works by locally linearizing or by identifying a dominant balance. Numerical methods work on everything.Layer 3: Structure
Problem 4. What makes an approximation "principled" versus "sloppy"? Consider two students solving the nonlinear pendulum equation $\ddot{\theta} = -(g/L)\sin\theta$.
-
Student A writes: "For small angles, $\sin\theta \approx \theta$, so the equation becomes $\ddot{\theta} = -(g/L)\theta$, which gives SHM with period $T = 2\pi\sqrt{L/g}$."
-
Student B writes: "The pendulum goes back and forth, so it is probably sinusoidal. I will guess $\theta(t) = \theta_0\cos(\omega t)$ and use dimensional analysis to get $\omega = \sqrt{g/L}$."
Both students arrive at the same formula. Is one approach better than the other? Explain.
Check your answer
Both students get the same answer, but Student A's approach is fundamentally stronger. Here is why: **Student A** has made a principled approximation: - The small parameter is identified: $\theta \ll 1$ (in radians). - The approximation $\sin\theta \approx \theta$ is the first term of a Taylor expansion, so the next correction is known: $\sin\theta \approx \theta - \theta^3/6$. This means the error can be estimated. - The validity condition is clear: the approximation is good when $\theta^3/6 \ll \theta$, i.e., when $\theta^2 \ll 6$, or $\theta \ll \sqrt{6} \approx 2.4$ radians. In practice, it is good to a few percent for $\theta < 0.5$ radians ($\approx 30°$). - The result can be systematically improved: using perturbation theory with the $\theta^3/6$ correction gives the amplitude-dependent period correction $T \approx T_0(1 + \theta_0^2/16 + \ldots)$. **Student B** has made a guess that happens to be correct: - There is no small parameter identified, so there is no way to know when the guess fails. - There is no systematic correction available. If the guess is wrong (as it would be for large angles), there is no path to improvement. - The dimensional analysis step is clever but does not confirm the functional form --- it only gives the right units. There are infinitely many functions of $t$ with the right dimensions. The key distinction: Student A's method has an error estimate built in and can be improved systematically. Student B's method, if it happens to be wrong, offers no guidance for fixing it. In physics, an answer without an error estimate is incomplete.Layer 4: Debug
Problem 5. A student uses Euler's method to simulate an undamped harmonic oscillator ($\ddot{x} = -\omega_0^2 x$, with $\omega_0 = 2\pi$ rad/s, so the period is 1 second). The student uses a step size of $\Delta t = 0.01$ s and runs the simulation for 100 periods (100 seconds, 10,000 steps). The student reports: "The simulation shows the amplitude growing over time. Therefore the system is unstable."
Is the student's conclusion correct? If not, diagnose the problem and explain what is actually happening.
Check your answer
The student's conclusion is **incorrect**. The undamped harmonic oscillator is not unstable --- it conserves energy and oscillates at constant amplitude forever. The growing amplitude is an artifact of the Euler method, not a property of the physical system. Here is what is happening. The standard (forward) Euler method has a systematic energy error: at each step, it slightly overestimates the speed or the displacement (depending on the phase of the oscillation). Over many steps, these small overshoots accumulate, and the total energy of the numerical solution grows. The amplitude increases because the numerical method is pumping energy into the system. This is a well-known property of Euler's method for conservative systems. The energy added per step is proportional to $(\Delta t)^2$, so the energy error grows linearly with the number of steps. After 10,000 steps, the accumulated error can be substantial. **How to diagnose this:** - Plot the total energy $E = \frac{1}{2}mv^2 + \frac{1}{2}kx^2$ at each time step. If it is growing, the algorithm is adding energy. The true system conserves energy. - Halve the step size and run again. If the amplitude growth slows down (but does not disappear), the problem is the algorithm, not the physics. - Compare to the exact solution $x(t) = A\cos(\omega_0 t)$. The exact solution has constant amplitude. **How to fix this:** - Use a smaller step size ($\Delta t = 0.001$ s). This reduces the energy error per step but costs 10 times more computation. - Use the symplectic Euler method (also called the Euler-Cromer method): update velocity first, then use the *new* velocity to update position. This small change makes the algorithm conserve energy on average, eliminating the amplitude drift. - Use a higher-order method like fourth-order Runge-Kutta, which has much smaller discretization errors. The deeper lesson: when a numerical simulation gives surprising results, always ask whether the surprise is physics or artifact. Check by varying the step size, comparing to known solutions, and monitoring conserved quantities. If the result changes when you change the step size, it is an artifact.Reflection
Think about the three solution methods you compared in this section: exact analytic solutions, principled approximations, and numerical simulations.
When would you choose each one? Consider not just accuracy but also what you are trying to learn. If you want to understand how a system's behavior depends on its parameters, which method is most revealing? If you need a quick estimate for an engineering decision, which method gives you an answer fastest? If you encounter an equation you have never seen before, which method lets you make progress immediately?
What does "understanding" a system mean? Is it having a formula? Knowing the qualitative behavior? Being able to predict numbers? All of these? The three methods offer different kinds of understanding, and a complete physicist uses all of them.
How has your view of approximation changed? At the start of this course, approximation might have felt like giving up --- like admitting you could not solve the real problem. Now you have seen that approximation is how experts extract the most important information from complex systems. The skill is not avoiding approximation; it is making approximations that are transparent, controlled, and checkable.
Looking Ahead
You have just put three fundamental tools --- exact solutions, approximations, and numerical methods --- side by side, compared their strengths, and practiced choosing among them. This is a meta-skill: knowing not just how to use a tool but which tool to reach for.
In the next section, you will add a fourth tool to your kit: dimensional analysis and scaling arguments. Where the three methods in this section all require setting up and solving (or approximating or numerating) a differential equation, dimensional analysis lets you extract information about the answer before you write down any equation at all. It is, in a sense, the most extreme form of principled approximation --- getting the structure of the answer from almost no work at all. Section 15.3 will show you how far you can go with units alone, and why this "quick trick" is actually one of the deepest ideas in physics.