# solving a differential equationusing Fourier theory

I am trying to solve the following system of equations:

$y''(x)+ \lambda y(x) = 0, x \in (0, 2 \pi)$

$y(0) = y(2 \pi)$

$y'(0) = y'(2 \pi)$

find the solutions of the form $y(x) = a_0/2+ \Sigma_{n=1} ^{\infty} a_n cos(\alpha_n x) + b_n sin(\alpha_n x)$

Using the indication, we have according tothe solution to the exercise (I need some explanation as to why): $y''(x)+ \lambda y(x) = \lambda a_0/2+ \Sigma_{n=1} ^{\infty} (\lambda- \alpha_n^2) cos(\alpha_n ) + b_n sin(\alpha_n x)$

If I try to write $y''(x)+ \lambda y(x)$ I get: $y''(x)+ \lambda y(x) = (x) = \Big(a_0/2+ \Sigma_{n=1} ^{\infty} a_n cos(\alpha_n x) + b_n sin(\alpha_n x)\Big) + \Big(a_0/2+ \Sigma_{n=1} ^{\infty} a_n cos(\alpha_n x) + b_n sin(\alpha_n x)\Big)''$

But I can't do much with the second part and I certainly don't get $y''(x)+ \lambda y(x) = \lambda a_0/2+ \Sigma_{n=1} ^{\infty} (\lambda- \alpha_n^2) cos(\alpha_n ) + b_n sin(\alpha_n x)$

• It depends how far back you want to start to solve this problem. If you assume that $y$ has a series form to begin with, it is relatively straight forward. If you want to derive the series for $y$, it will take a little longer. – mattos Jun 10 '17 at 14:27

Since your equation is periodic on the boundaries, you can use Fourier series to expand the solution $y(x)$ in the form $$y(x) = a_0+\sum_{n=1}^{\infty}{a_n\cos{(\alpha_nx)}+b_n\sin{(\alpha_nx)}}$$ Introducing this expression in your differential equation you obtain
$$y''(x)+\lambda y(x) = a_0\lambda + \sum_{n=1}^{\infty}{(\lambda-\alpha_n^2)a_n\cos{(\alpha_nx)}}+(\lambda-\alpha_n^2)b_n\sin{(\alpha_nx)}=0$$ Last equation only holds for if $a_0=0$ and $\alpha_n^2=\lambda$ hence your general solution is: $$y(x) = \sum_{n=1}^{\infty}{a_n\cos{(\sqrt{\lambda}x)}+ b_n\sin{(\sqrt{\lambda}x)}}$$ Define new constants $$a=\sum_{n=1}^{\infty}{a_n}\qquad b=\sum_{n=1}^{\infty}{b_n}$$ And the sought function is finally: $$y(x)=a\cos{(\sqrt{\lambda}x)}+b\sin{(\sqrt{\lambda}x)}$$ and apply the BCs.
Notice that your BVP only has a solution iff $\sqrt{\lambda}=1$. This comes from imposing the BC: $$\left[\begin{array}{cc} \cos{(2\pi\sqrt{\lambda})}-1& \sin{(2\pi\sqrt{\lambda})} \\ \sin{(2\pi\sqrt{\lambda})} & \cos{(2\pi\sqrt{\lambda})}-1 \end{array}\right] \left[\begin{array}{c} a \\b\end{array}\right]=\vec{0}$$ and therefore $$(\cos{(2\pi\sqrt{\lambda})}-1)^2+\sin^2{(2\pi\sqrt{\lambda})}=0$$ must hold, resulting $\sqrt{\lambda}=1$ whatever $a$ and $b$ values.