Differential equations are not a pure mathematical game — they are
the language for understanding the physical world. From celestial motion
to circuit response, from spring vibration to chemical reactions, almost
all dynamical system behaviors can be described by differential
equations. In this chapter, we explore the core applications of ordinary
differential equations in physics and engineering, building a bridge
from mathematics to practice.
Differential
Equations in Classical Mechanics
Mathematical
Expression of Newton's Laws of Motion
Newton's second lawis the
cornerstone of mechanics, but it is essentially a differential
equation:Hereis the position vector, and the
forcemay depend on
position, velocity, and time.
Important observation: Given the expression for
force, an object's motion is completely determined by its initial
position and initial velocity. This embodies the
deterministic nature of Newtonian mechanics.
Free Fall with Air
Resistance
Consider an object falling from height, subject to both gravity and
air resistance:whereis the drag
coefficient andis the velocity
(downward positive).
Terminal velocity: When, acceleration is zero, reaching
terminal velocity:
Solution process: This is a separable first-order
ODE:Using partial fraction decomposition:After integration:
import numpy as np import matplotlib.pyplot as plt from scipy.integrate import odeint, solve_ivp
deffalling_with_drag(): """Free fall with air resistance""" m = 70# Mass kg (human body) g = 9.8# Gravitational acceleration k = 0.25# Drag coefficient (depends on body size and posture) v_terminal = np.sqrt(m * g / k) print(f"Terminal velocity: {v_terminal:.1f} m/s ({v_terminal * 3.6:.1f} km/h)") defdrag_ode(v, t): return g - (k/m) * v**2 t = np.linspace(0, 30, 500) v0 = 0 # Numerical solution v_numerical = odeint(drag_ode, v0, t).flatten() # Analytical solution v_analytical = v_terminal * np.tanh(g * t / v_terminal) # Position (integrate velocity) x_numerical = np.cumsum(v_numerical) * (t[1] - t[0]) fig, axes = plt.subplots(1, 3, figsize=(15, 5)) # Velocity-time ax1 = axes[0] ax1.plot(t, v_numerical, 'b-', linewidth=2, label='Numerical') ax1.plot(t, v_analytical, 'r--', linewidth=2, label='Analytical') ax1.axhline(y=v_terminal, color='k', linestyle=':', label=f'Terminal: {v_terminal:.1f} m/s') ax1.set_xlabel('Time (s)', fontsize=12) ax1.set_ylabel('Velocity (m/s)', fontsize=12) ax1.set_title('Velocity vs Time', fontsize=14, fontweight='bold') ax1.legend() ax1.grid(True, alpha=0.3) # Position-time ax2 = axes[1] ax2.plot(t, x_numerical, 'g-', linewidth=2) ax2.set_xlabel('Time (s)', fontsize=12) ax2.set_ylabel('Distance (m)', fontsize=12) ax2.set_title('Distance vs Time', fontsize=14, fontweight='bold') ax2.grid(True, alpha=0.3) # Comparison of different drag coefficients ax3 = axes[2] k_values = [0.1, 0.25, 0.5, 1.0] for k_val in k_values: v_term = np.sqrt(m * g / k_val) v = v_term * np.tanh(g * t / v_term) ax3.plot(t, v, linewidth=2, label=f'k = {k_val}') ax3.set_xlabel('Time (s)', fontsize=12) ax3.set_ylabel('Velocity (m/s)', fontsize=12) ax3.set_title('Effect of Drag Coefficient', fontsize=14, fontweight='bold') ax3.legend() ax3.grid(True, alpha=0.3) plt.tight_layout() plt.savefig('falling_with_drag.png', dpi=150, bbox_inches='tight') plt.show()
falling_with_drag()
Planetary Motion and
the Kepler Problem
The two-body problem is one of the most important problems in
classical mechanics. Consider a planet of massorbiting a star of mass():Introducing polar coordinatesand using conservation of
angular momentum, we obtain the Binet
equation:where.
This is a simple harmonic oscillator equation! The general solution
is:This is the polar equation of a
conic section, whereis the eccentricity: -: Ellipse (bound orbit) -: Parabola (critical escape) -: Hyperbola (escape orbit)
defkepler_orbits(): """Visualization of Kepler orbits""" fig, axes = plt.subplots(1, 2, figsize=(14, 6)) # Orbits with different eccentricities ax1 = axes[0] theta = np.linspace(0, 2*np.pi, 1000) eccentricities = [0, 0.3, 0.6, 0.9] p = 1# Semi-latus rectum for e in eccentricities: r = p / (1 + e * np.cos(theta)) # Only plot bound portion valid = r > 0 x = r[valid] * np.cos(theta[valid]) y = r[valid] * np.sin(theta[valid]) ax1.plot(x, y, linewidth=2, label=f'e = {e}') # Parabola and hyperbola for e, style in [(1.0, '--'), (1.5, ':')]: theta_range = np.linspace(-np.pi*0.8, np.pi*0.8, 500) r = p / (1 + e * np.cos(theta_range)) valid = r > 0 x = r[valid] * np.cos(theta_range[valid]) y = r[valid] * np.sin(theta_range[valid]) ax1.plot(x, y, linestyle=style, linewidth=2, label=f'e = {e}') ax1.plot(0, 0, 'yo', markersize=15, label='Sun') ax1.set_xlim(-4, 2) ax1.set_ylim(-3, 3) ax1.set_aspect('equal') ax1.set_xlabel('x', fontsize=12) ax1.set_ylabel('y', fontsize=12) ax1.set_title('Kepler Orbits: Different Eccentricities', fontsize=14, fontweight='bold') ax1.legend(loc='upper right') ax1.grid(True, alpha=0.3) # Numerical orbit simulation ax2 = axes[1] defkepler_ode(t, state, GM): x, y, vx, vy = state r = np.sqrt(x**2 + y**2) ax = -GM * x / r**3 ay = -GM * y / r**3 return [vx, vy, ax, ay] GM = 1.0 # Different initial conditions initial_conditions = [ ([1, 0, 0, 1.0], 'Circle'), ([1, 0, 0, 0.8], 'Ellipse'), ([1, 0, 0, 1.414], 'Parabola-like'), ] for (state0, name) in initial_conditions: t_span = (0, 20) t_eval = np.linspace(0, 20, 2000) sol = solve_ivp(kepler_ode, t_span, state0, args=(GM,), t_eval=t_eval, method='DOP853', rtol=1e-10) ax2.plot(sol.y[0], sol.y[1], linewidth=2, label=name) ax2.plot(0, 0, 'yo', markersize=15) ax2.set_xlim(-3, 2) ax2.set_ylim(-2, 2) ax2.set_aspect('equal') ax2.set_xlabel('x', fontsize=12) ax2.set_ylabel('y', fontsize=12) ax2.set_title('Numerical Orbit Simulation', fontsize=14, fontweight='bold') ax2.legend() ax2.grid(True, alpha=0.3) plt.tight_layout() plt.savefig('kepler_orbits.png', dpi=150, bbox_inches='tight') plt.show()
kepler_orbits()
In-Depth Analysis of
Vibration Systems
Multi-Degree-of-Freedom
Vibration Systems
Real vibration systems often have multiple degrees of freedom.
Considermasses connected by
springs:where,,
andare mass, damping, and
stiffness matrices respectively.
Modal analysis: For undamped free vibrationAssuming solution form, we obtain the eigenvalue
problem:Eigenvaluescorrespond to natural
frequencies, and eigenvectorscorrespond to
mode shapes.
In this chapter, we explored the broad applications of ordinary
differential equations in physics and engineering:
Mechanical Systems
Point mass motion: From simple free fall to complex
planetary motion
Vibration systems: Single and
multi-degree-of-freedom, linear and nonlinear
Rigid body dynamics: Euler equations and gyroscopic
motion
Electromagnetism
Circuit analysis: RLC circuits, coupled circuits,
nonlinear elements
Frequency response: Transfer functions and Bode
plots
Thermal and Chemical
Heat conduction: Newton's law of cooling and its
applications
Reaction kinetics: First-order, consecutive, and
reversible reactions
Biological and Ecological
Population dynamics: Predator-prey models,
competitive exclusion
Epidemic models: SIR model and basic reproduction
number
Control Systems
Feedback control: Stability and pole placement
PID control: Most common control strategy in
industry
Fluid Mechanics
Simplified models: Poiseuille flow, boundary layer
theory
Exercises
Basic Problems
Akg object falls from
high altitude with air resistance. Find the terminal velocity and time to reach 99% of
terminal velocity.
Solve the damped harmonic oscillatorwith initial
conditions,.
In an RLC circuit withH,μ F,Ω, determine if the circuit is
underdamped or overdamped and find the natural frequency.
A first-order reaction has a half-life of 2 hours. Find the time
for the reactant concentration to drop to 10% of its initial
value.
In the SIR model, if/day,/day,
calculateand explain its
physical meaning.
Advanced Problems
Double pendulum: Derive the equations of motion
and solve numerically. Observe sensitivity to initial
conditions.
Van der Pol oscillator:Analyze the limit cycle behavior for different values of.
Chemical oscillation (simplified
Belousov-Zhabotinsky reaction model):Explore oscillatory
behavior in parameter space.
Spacecraft attitude control: Design a simple
feedback control law to stabilize satellite attitude angle to
zero.
Epidemic control: Introduce vaccination
ratein the SIR model and analyze
how to chooseto prevent
outbreak.
Programming Problems
Implement a general second-order system simulator that can
analyze step response, frequency response, and phase plane trajectories
for different damping ratios.
Write a program to solve the restricted three-body problem and
visualize orbits.
Implement a PID controller for temperature control system
simulation, including auto-tuning capability.
Simulate multi-degree-of-freedom building structure response
under earthquake excitation, analyzing effects of different interstory
stiffness.
Discussion Questions
Why can a gyroscope maintain stable orientation? Explain from the
perspective of angular momentum conservation.
In control systems, why does pure integral control lead to
instability or oscillation?
In ecosystems, why are the periodic oscillations predicted by the
Lotka-Volterra model rarely observed in reality?
From physical intuition, explain why critical damping is
"optimal"— neither oscillating nor taking longest to reach
equilibrium.
References
Strogatz, S. H. (2018). Nonlinear Dynamics and Chaos. CRC
Press.
Ogata, K. (2010). Modern Control Engineering. Prentice
Hall.
Murray, J. D. (2002). Mathematical Biology. Springer.
Thornton, S. T., & Marion, J. B. (2004). Classical Dynamics
of Particles and Systems. Brooks/Cole.
Dorf, R. C., & Bishop, R. H. (2017). Modern Control
Systems. Pearson.
Batchelor, G. K. (2000). An Introduction to Fluid Dynamics.
Cambridge University Press.