Unit 6
Introduction to Differential Equations
A differential equation relates a function to its own derivatives. That sounds abstract until you notice that a capacitor's current is proportional to the derivative of its voltage — so every circuit containing a capacitor or an inductor is a differential equation. This unit solves the ones you will meet most, and they turn out to be RC, RL and RLC.
1 · Vocabulary
| Term | Meaning | Example |
|---|---|---|
| Order | Highest derivative appearing | \(y'' + 3y' = 0\) is second order |
| Linear | \(y\) and its derivatives appear only to the first power, never multiplied together or inside a function | \(y' + P(x)y = Q(x)\) ✓; \(y' = y^2\) ✗ |
| General solution | Family containing arbitrary constants — one per order | \(y = Ce^{-t}\) |
| Particular solution | Constants pinned down by initial conditions | \(y = 5e^{-t}\) |
| IVP | The equation plus enough initial conditions to fix every constant | \(y' = -y,\; y(0) = 5\) |
To verify a claimed solution, substitute it and its derivatives back into the equation. This takes seconds and catches nearly every algebra slip — the same asymmetry that makes differentiating your integral worthwhile in Unit 1.
2 · Separable equations
If you can get all the \(y\)'s on one side and all the \(x\)'s on the other, integrate both sides:
The most important instance in all of engineering is the one where the rate of change is proportional to the amount present:
Dividing by \(h(y)\) silently assumes \(h(y) \neq 0\). Any \(y\) making \(h(y) = 0\) is also a (constant) solution, and it may be exactly the one the problem wants. Check for it before dividing.
3 · First-order linear and the integrating factor
Put the equation in standard form first — coefficient of \(y'\) equal to 1:
Multiply through by the integrating factor:
- Get standard form. Divide by the leading coefficient first — skipping this gives the wrong \(P\) and therefore the wrong \(\mu\).
- Compute \(\mu = e^{\int P\,dx}\). No constant of integration needed here.
- Multiply through and recognise the left side as \((\mu y)'\).
- Integrate both sides — keep \(C\) this time.
- Solve for \(y\) and apply the initial condition.
4 · RC and RL circuits
Apply Kirchhoff's voltage law to a resistor and capacitor in series with a source \(V_s\), using \(i = C\,dv/dt\):
With \(v(0) = 0\) (uncharged capacitor), the solution is the step response:
With no source and \(v(0) = V_0\), it is the natural response:
The RL circuit is structurally identical, with a different time constant:
Start where you start, end where you end, and get there exponentially. Find \(x_0\) (initial value), \(x_\infty\) (final value — treat the capacitor as open or the inductor as a short), and \(\tau\), and you have written the answer without solving anything. Your circuits course will hand you this formula; it is just the general solution of the ODE above.
5 · The time constant
| Elapsed | Fraction complete | Note |
|---|---|---|
| \(1\tau\) | 63.2% | \(1 - 1/e\) |
| \(2\tau\) | 86.5% | |
| \(3\tau\) | 95.0% | Often "close enough" |
| \(4\tau\) | 98.2% | |
| \(5\tau\) | 99.3% | The engineering convention for "settled" |
\(t = \tau\ln 10 \approx 2.30\tau\) to reach 90% of anything exponential, and \(t = \tau\ln 2 \approx 0.69\tau\) to reach 50%. These save real time, and they are independent of the circuit.
6 · Second-order equations
For constant-coefficient homogeneous equations:
Guess \(y = e^{rt}\). Every term picks up a factor of \(r\) per derivative, and \(e^{rt}\) divides out, leaving the characteristic equation:
Everything then depends on the discriminant — three cases, no others:
| Roots | General solution | Behaviour |
|---|---|---|
| Real, distinct \(r_1 \neq r_2\) | \(C_1 e^{r_1 t} + C_2 e^{r_2 t}\) | Two decaying exponentials — no oscillation |
| Real, repeated \(r\) | \(\big(C_1 + C_2 t\big)e^{rt}\) | The extra \(t\) is required — two constants are needed for a second-order equation |
| Complex \(\alpha \pm \beta i\) | \(e^{\alpha t}\big(C_1\cos\beta t + C_2\sin\beta t\big)\) | Oscillation at \(\beta\), envelope \(e^{\alpha t}\) |
The third row is where Euler's formula earns its place: \(e^{(\alpha+\beta i)t} = e^{\alpha t}(\cos\beta t + i\sin\beta t)\). Complex roots do not mean a complex answer — they mean a real oscillating one.
7 · RLC and the three damping regimes
A series RLC circuit, written in terms of charge, is exactly a second-order equation:
Its characteristic roots are conventionally written with two parameters:
| Condition | Name | Roots | Response |
|---|---|---|---|
| \(\alpha > \omega_0\) | Overdamped | Real, distinct | Slow, sluggish, no overshoot |
| \(\alpha = \omega_0\) | Critically damped | Real, repeated | Fastest possible with no overshoot |
| \(\alpha < \omega_0\) | Underdamped | Complex pair | Overshoots and rings at \(\omega_d = \sqrt{\omega_0^2 - \alpha^2}\) |
The three cases correspond exactly to the three partial-fraction cases from Unit 1: distinct linear factors give distinct exponentials, a repeated factor gives the \(te^{rt}\) term, and an irreducible quadratic gives a damped sinusoid. The characteristic polynomial here is the denominator you factor there. Unit 1 and Unit 6 are the same mathematics approached from opposite ends.
8 · Worked examples
1. Separable equation with an initial condition
Solve \(\dfrac{dy}{dx} = xy^2\), \(y(0) = 1\).
Separate (noting \(y = 0\) is also a solution, but not ours since \(y(0) = 1\)):
Apply the condition \(y(0) = 1\): \(-1 = 0 + C\), so \(C = -1\).
Check: \(y(0) = 1\) ✓. And note the solution blows up at \(x = \sqrt2\) — it only exists on \((-\sqrt2, \sqrt2)\), even though the original equation looked perfectly well behaved everywhere. Nonlinear equations do this; linear ones do not.
2. Integrating factor
Solve \(xy' + 2y = x^3\), \(x > 0\).
Standard form first — divide by \(x\):
Multiply through, and recognise the left side as a product derivative:
Note step one. Reading \(P = 2\) off the original equation, before dividing by \(x\), would give \(\mu = e^{2x}\) and the method would collapse. Standard form is not optional.
3. RC charging — derive it, do not quote it
A 10 kΩ resistor and 100 µF capacitor are switched onto a 12 V source at \(t = 0\), capacitor uncharged. Find \(v(t)\), the time to reach 10 V, and the current at \(t = 0\).
Set up from KVL: \(V_s = iR + v\), with \(i = C\,dv/dt\):
Solve by separation:
With \(v(0) = 0\), \(C = -\ln 12\), and rearranging:
Time to reach 10 V:
Initial current: at \(t = 0\) the capacitor voltage is 0, so the full 12 V is across the resistor:
An uncharged capacitor behaves as a short circuit at the instant of switching, and as an open circuit once fully charged. Both facts fall out of the solution rather than needing separate memorisation.
4. Second-order: all three cases at once
(a) \(y'' + 5y' + 6y = 0\)
(b) \(y'' + 4y' + 4y = 0\)
(c) \(y'' + 2y' + 5y = 0\)
In every case the real part of the root sets the decay rate and the imaginary part sets the oscillation frequency. All three here have negative real parts, so all three decay: the systems are stable. A root with positive real part would grow without bound.
5. Classifying an RLC circuit
A series RLC circuit has \(L = 10\) mH and \(C = 10\) µF. Classify its response for \(R = 10\,\Omega\), \(63.2\,\Omega\) and \(200\,\Omega\).
| \(R\) | \(\alpha = R/2L\) | Compare to \(\omega_0\) | Classification |
|---|---|---|---|
| 10 Ω | 500 | \(\alpha < \omega_0\) | Underdamped — rings |
| 63.2 Ω | 3162 | \(\alpha = \omega_0\) | Critically damped |
| 200 Ω | 10 000 | \(\alpha > \omega_0\) | Overdamped — sluggish |
Ringing frequency in the underdamped case:
Only 1.3% below \(\omega_0\). Light damping barely shifts the ringing frequency — it mostly changes how fast the ringing dies. That is why a lightly damped resonator can be treated as oscillating at \(\omega_0\) for most purposes.
The design lesson: resistance does not change what frequency the circuit wants to ring at; it changes how long it rings. \(R\) is the knob for damping, \(L\) and \(C\) for frequency.
Checklist
- I can classify an ODE by order and linearity before choosing a method.
- I check for equilibrium solutions before dividing in a separable equation.
- I put an equation in standard form before computing the integrating factor.
- I know \(\tau = RC\) and \(\tau = L/R\), and the 63% / 5\(\tau\) rules.
- I can write any first-order circuit response from \(x_0\), \(x_\infty\) and \(\tau\).
- I know the three characteristic-root cases, including the extra \(t\) for a repeated root.
- I can compute \(\alpha\) and \(\omega_0\) and classify an RLC circuit's damping.
- I know real parts set decay and imaginary parts set oscillation.