# Series Solution to Legendre Equation

My professor taught us the series solution to ODE's method today in class, and one of our homework problems was to solve the Legendre Equation.

$$\text{Legendre Equation:} \frac{d^2y}{dx^2}(1-x^2) -2x\frac{dy}{dx} + \alpha(\alpha + 1)y = 0$$

By making a series expansion at $$k = 0$$:

$$y = \sum_{k=0}^\infty{a_nx^n}$$ $$y' = \sum_{k=0}^\infty{na_nx^{n-1}}$$ $$y'' = \sum_{k=0}^\infty{n(n-1)a_nx^{n-2}}$$ Plugging in: $$\sum_{k=0}^\infty{n(n-1)a_nx^{n-2}}(1-x^2) -2x\sum_{k=0}^\infty{na_nx^{n-1}} + \alpha(\alpha + 1)\sum_{k=0}^\infty{a_nx^n} = 0$$ $$\sum_{n=0}^\infty{n(n-1)a_nx^{n-2}}-\sum_{n=0}^\infty{n(n-1)a_nx^n} -2x\sum_{n=0}^\infty{na_nx^{n-1}}+\alpha(\alpha+1)\sum_{n=0}^\infty{a_nx^n}=0$$

$$\sum_{n=0}^\infty{n(n-1)a_nx^{n-2}}-\sum_{n=0}^\infty{n(n-1)a_nx^n} -2\sum_{n=0}^\infty{na_nx^{n}}+\alpha(\alpha+1)\sum_{n=0}^\infty{a_nx^n}=0$$

$$\sum_{n=0}^\infty{(n+2)(n+1)a_{n+2}x^{n}}-\sum_{n=0}^\infty{n(n-1)a_nx^n} -2\sum_{n=0}^\infty{na_nx^{n}}+\alpha(\alpha+1)\sum_{n=0}^\infty{a_nx^n}=0$$

$$\sum_{n=0}^\infty{(n+1)(n+2)a_{n+2}+[-n(n-1)-2n+\alpha(\alpha+1)]a_n}=0,$$

Each term must cancel so: $$(n+1)(n+2)a_{n+2} + [-n(n+1) + \alpha(\alpha +1)]a_n = 0$$

$$a_{n+2} = \frac{n(n+1)-\alpha(\alpha+1)}{(n+1)(n+2)}a_n$$ $$= \frac{[\alpha + (n+1)](\alpha -n)}{(n+1)(n+2)}$$

Therefore: $$a_2 = \frac{-\alpha(\alpha+1)}{1·2}a_0$$ $$a_4 = -\frac{(\alpha-2)(\alpha+3)}{3·4}a_2$$ $$a_4= (-1)^2\frac{[(\alpha-2)\alpha][(\alpha+1)(\alpha+3)]}{1·2·3·4}a_0$$

So the even solution is: $$y_1(x)=1+\sum_{n=1}^\infty{(-1)^n\frac{[(\alpha-2n+2)...(\alpha-2)\alpha][(\alpha+1)(\alpha+3)...(\alpha+2n-1)]}{(2n)!}x^{2n}}.$$ Then, the odd solution is: $$y_2(x)=x+\sum_{n=1}^\infty{(-1)^n\frac{[(\alpha-2n+1)...(\alpha-3)(\alpha-1)][(\alpha+2)(\alpha+4)...(\alpha+2n)]}{(2n+1)!}x^{2n+1}}.$$

Does this look right? This is my first attempt at the series solution method, so I would really appreciate any help. Thanks in advance!

Since the equation is of second order, there will be two arbitraty constants $$a_0$$ and $$a_1$$. You properly established that $$a_{n+2} = \frac{n(n+1)-\alpha(\alpha+1)}{(n+1)(n+2)}a_n\tag 1$$ and to me, this is enough.
The solution is then $$y=a_0+a_1x+\sum_{n=2}^\infty a_n x^n$$ For sure, you could write it as $$y=a_0+a_1x+\sum_{n=1}^\infty a_{2n} x^{2n}+\sum_{n=1}^\infty a_{2n+1} x^{2n+1}$$ and using $$(1)$$ make the coefficients totally explicit solving the recurrence equation given by $$(1)$$.
In any manner, you did a good job and $$\to +1$$.