Skip to main content
Examonaut

Topic 3 · Lesson 1 of 4

Series solutions

The idea

If yy is given at x=0x = 0 (and, for a second order equation, so is dydx\frac{dy}{dx}), the differential equation tells you the next derivative there. Differentiating the equation gives the one after that, and so on. Putting the values into the Maclaurin series

y=y0+x(dydx)0+x22!(d2ydx2)0+x33!(d3ydx3)0+…y = y_0 + x\left(\frac{dy}{dx}\right)_0 + \frac{x^2}{2!}\left(\frac{d^2y}{dx^2}\right)_0 + \frac{x^3}{3!}\left(\frac{d^3y}{dx^3}\right)_0 + \dots

gives the solution as a series. The subscript 0 means "the value at x=0x = 0". For a starting point x=ax = a, use the Taylor series in powers of (x−a)(x - a) instead.

The method

  1. Write down the values you are given.
  2. Use the equation to find the first missing derivative at the starting point.
  3. Differentiate the whole equation with respect to xx, using the product rule on terms like xyxy and the chain rule on terms like y2y^2 (its derivative is 2ydydx2y\frac{dy}{dx}). Then substitute the known values.
  4. Repeat until you have enough derivatives.
  5. Substitute into the series, with the factorials.

Keep each differentiated equation in a general form (do not substitute numbers too early), because you need to differentiate it again.

Worked example

A first order equation

Given dydx=x2+y2\frac{dy}{dx} = x^2 + y^2 with y=1y = 1 at x=0x = 0, find the series for yy up to x3x^3.

Show solution
  1. (dydx)0=0+12=1\left(\frac{dy}{dx}\right)_0 = 0 + 1^2 = 1.
  2. Differentiate: d2ydx2=2x+2ydydx\frac{d^2y}{dx^2} = 2x + 2y\frac{dy}{dx}, so (d2ydx2)0=0+2=2\left(\frac{d^2y}{dx^2}\right)_0 = 0 + 2 = 2.
  3. Differentiate again: d3ydx3=2+2(dydx)2+2yd2ydx2\frac{d^3y}{dx^3} = 2 + 2\left(\frac{dy}{dx}\right)^2 + 2y\frac{d^2y}{dx^2}, so (d3ydx3)0=2+2+4=8\left(\frac{d^3y}{dx^3}\right)_0 = 2 + 2 + 4 = 8.
  4. y=1+x+22x2+86x3+⋯=1+x+x2+43x3+…y = 1 + x + \frac{2}{2}x^2 + \frac{8}{6}x^3 + \dots = 1 + x + x^2 + \frac{4}{3}x^3 + \dots

Worked example

A second order equation

Given d2ydx2−xdydx+y=0\frac{d^2y}{dx^2} - x\frac{dy}{dx} + y = 0, with y=2y = 2 and dydx=1\frac{dy}{dx} = 1 at x=0x = 0, find the series for yy up to x4x^4.

Show solution
  1. d2ydx2=xdydx−y\frac{d^2y}{dx^2} = x\frac{dy}{dx} - y, so (d2ydx2)0=0−2=−2\left(\frac{d^2y}{dx^2}\right)_0 = 0 - 2 = -2.
  2. Differentiate: d3ydx3=dydx+xd2ydx2−dydx=xd2ydx2\frac{d^3y}{dx^3} = \frac{dy}{dx} + x\frac{d^2y}{dx^2} - \frac{dy}{dx} = x\frac{d^2y}{dx^2}. So (d3ydx3)0=0\left(\frac{d^3y}{dx^3}\right)_0 = 0.
  3. Differentiate again: d4ydx4=d2ydx2+xd3ydx3\frac{d^4y}{dx^4} = \frac{d^2y}{dx^2} + x\frac{d^3y}{dx^3}, so (d4ydx4)0=−2\left(\frac{d^4y}{dx^4}\right)_0 = -2.
  4. y=2+x−22x2+0−224x4+⋯=2+x−x2−112x4+…y = 2 + x - \frac{2}{2}x^2 + 0 - \frac{2}{24}x^4 + \dots = 2 + x - x^2 - \frac{1}{12}x^4 + \dots

About a point other than 0

If the conditions are given at x=1x = 1, find the derivatives at x=1x = 1 and use powers of (x−1)(x - 1):

y=y1+(x−1)(dydx)1+(x−1)22!(d2ydx2)1+…y = y_1 + (x - 1)\left(\frac{dy}{dx}\right)_1 + \frac{(x - 1)^2}{2!}\left(\frac{d^2y}{dx^2}\right)_1 + \dots

For example, dydx=xy\frac{dy}{dx} = xy with y=2y = 2 at x=1x = 1 gives d2ydx2=y+xdydx\frac{d^2y}{dx^2} = y + x\frac{dy}{dx} and d3ydx3=2dydx+xd2ydx2\frac{d^3y}{dx^3} = 2\frac{dy}{dx} + x\frac{d^2y}{dx^2}, so the derivatives at x=1x = 1 are 22, 44 and 88. Then y=2+2(x−1)+2(x−1)2+43(x−1)3+…y = 2 + 2(x - 1) + 2(x - 1)^2 + \frac{4}{3}(x - 1)^3 + \dots, and y(1.1)≈2.2213y(1.1) \approx 2.2213. (The exact solution, y=2e12(x2−1)y = 2e^{\frac{1}{2}(x^2 - 1)}, gives 2.22142.2214.)

How good is the series?

A truncated series is accurate close to the starting point and gets worse further away, because the terms you left out grow with ∣x−a∣|x - a|. An estimate at x=0.1x = 0.1 from a series about 0 is usually excellent; at x=2x = 2 it may be useless. If asked to comment, say that the approximation is best near the point the series is centred on, and that more terms would improve it.

Practise this topic

Both are part of Premium.