Skip to content
Part IA Michaelmas, Lent, Easter Term

Methods II Tripos Questions

First Order ODEs

Example from notes

Solve: y+3y=e2xy' + 3y = e^{-2x}

Solution:

Integrating factor: μ=e3dx=e3x\mu = e^{\int 3\,dx} = e^{3x}

ddx(e3xy)=e3xe2x=ex\frac{d}{dx}(e^{3x}y) = e^{3x}e^{-2x} = e^x

e3xy=ex+Ce^{3x}y = e^x + C

y=e2x+Ce3xy = e^{-2x} + Ce^{-3x}


Second Order ODEs

Example: Damped Oscillator

Solve y+4y+5y=0y'' + 4y' + 5y = 0 with y(0)=1y(0) = 1, y(0)=0y'(0) = 0.

Characteristic equation: λ2+4λ+5=0\lambda^2 + 4\lambda + 5 = 0

λ=4±16202=2±i\lambda = \frac{-4 \pm \sqrt{16 - 20}}{2} = -2 \pm i

General solution: y=e2x(Acosx+Bsinx)y = e^{-2x}(A\cos x + B\sin x)

Apply initial conditions:

y(0)=A=1y(0) = A = 1

y(x)=2e2x(cosx+Bsinx)+e2x(sinx+Bcosx)y'(x) = -2e^{-2x}(\cos x + B\sin x) + e^{-2x}(-\sin x + B\cos x)

y(0)=2(1)+B=0B=2y'(0) = -2(1) + B = 0 \Rightarrow B = 2

Solution: y=e2x(cosx+2sinx)y = e^{-2x}(\cos x + 2\sin x)


Lagrange Multipliers

Maximum of f(x,y)=xyf(x,y) = xy on x2+4y2=1x^2 + 4y^2 = 1

Set up: L=xyλ(x2+4y21)\mathcal{L} = xy - \lambda(x^2 + 4y^2 - 1)

Equations:

  • y2λx=0y - 2\lambda x = 0 … (i)
  • x8λy=0x - 8\lambda y = 0 … (ii)
  • x2+4y2=1x^2 + 4y^2 = 1 … (iii)

From (i): λ=y2x\lambda = \frac{y}{2x}

Substitute into (ii): x8y22x=x4y2x=0x - \frac{8y^2}{2x} = x - \frac{4y^2}{x} = 0

x2=4y2x^2 = 4y^2

From (iii): 4y2+4y2=8y2=14y^2 + 4y^2 = 8y^2 = 1

y=±122y = \pm\frac{1}{2\sqrt{2}}

x=±12x = \pm\frac{1}{\sqrt{2}}

Maximum: f=122122=18f = \frac{1}{2\sqrt{2}} \cdot \frac{1}{2\sqrt{2}} = \frac{1}{8}

(When signs match.)


Vector Calculus

Line Integral Example

Compute CFdr\int_C \mathbf{F} \cdot d\mathbf{r} for F=(y,x)\mathbf{F} = (y, x) along CC:

  1. Straight line from (0,0)(0,0) to (1,1)(1,1)
  2. Curve y=x2y = x^2 from (0,0)(0,0) to (1,1)(1,1)

Check if conservative:

×F=FyxFxy=xxyy=11=0\nabla \times \mathbf{F} = \frac{\partial F_y}{\partial x} - \frac{\partial F_x}{\partial y} = \frac{\partial x}{\partial x} - \frac{\partial y}{\partial y} = 1 - 1 = 0

F\mathbf{F} is conservative. Find potential: ϕ=xy+C\phi = xy + C.

Line integral = ϕ(1,1)ϕ(0,0)=1\phi(1,1) - \phi(0,0) = 1

Both paths give the same result: 1.


Stokes’ Theorem Verification

Verify Stokes’ theorem for F=(y,x,0)\mathbf{F} = (-y, x, 0) on circle x2+y2a2x^2 + y^2 \leq a^2 in plane z=0z = 0.

Curl: ×F=(0,0,2)\nabla \times \mathbf{F} = (0, 0, 2)

Surface integral: S(×F)dS=S2dS=2πa2\int_S (\nabla \times \mathbf{F}) \cdot d\mathbf{S} = \int_S 2\,dS = 2\pi a^2

Line integral: Boundary is circle x2+y2=a2x^2 + y^2 = a^2 at z=0z = 0.

r=(acosθ,asinθ,0)\mathbf{r} = (a\cos\theta, a\sin\theta, 0)

dr=(asinθ,acosθ,0)dθd\mathbf{r} = (-a\sin\theta, a\cos\theta, 0)\,d\theta

F=(asinθ,acosθ,0)\mathbf{F} = (-a\sin\theta, a\cos\theta, 0)

Fdr=a2sin2θ+a2cos2θ=a2\mathbf{F} \cdot d\mathbf{r} = a^2\sin^2\theta + a^2\cos^2\theta = a^2

Fdr=02πa2dθ=2πa2\oint \mathbf{F} \cdot d\mathbf{r} = \int_0^{2\pi} a^2\,d\theta = 2\pi a^2

Both equal: 2πa22\pi a^2


Fourier Series

Parseval’s Theorem Application

Use Fourier series for f(x)=xf(x) = x on [π,π][-\pi, \pi] to evaluate n=11n2\sum_{n=1}^{\infty} \frac{1}{n^2}.

Fourier coefficients:

Since ff is odd: an=0a_n = 0.

bn=1πππxsin(nx)dx=2(1)n+1nb_n = \frac{1}{\pi}\int_{-\pi}^{\pi} x\sin(nx)\,dx = \frac{2(-1)^{n+1}}{n}

Parseval:

12πππx2dx=12n=1bn2\frac{1}{2\pi}\int_{-\pi}^{\pi} x^2\,dx = \frac{1}{2}\sum_{n=1}^{\infty} b_n^2

π23=124n2\frac{\pi^2}{3} = \frac{1}{2}\sum \frac{4}{n^2}

n=11n2=π26\sum_{n=1}^{\infty} \frac{1}{n^2} = \frac{\pi^2}{6}


Fourier Series of Square Wave

f(x)={1π<x<010<x<πf(x) = \begin{cases} -1 & -\pi < x < 0 \\ 1 & 0 < x < \pi \end{cases}

Even though ff is odd, this gives a series with only sine terms:

f(x)=4π(sinx+13sin3x+15sin5x+)f(x) = \frac{4}{\pi}\left(\sin x + \frac{1}{3}\sin 3x + \frac{1}{5}\sin 5x + \cdots\right)

=4πk=0sin((2k+1)x)2k+1= \frac{4}{\pi}\sum_{k=0}^{\infty} \frac{\sin((2k+1)x)}{2k+1}

Note: This can also be obtained by differentiating the triangle wave series.