# Solve initial value problem by the method of power series.

Could someone help me solve the initial value problem

$y'' - xy = x^2 \\ y(0) = 2 ; y'(0) = 1$

by the $\bf method\bf$ $\bf of\bf$ $\bf power\bf$ $\bf series \bf$.

I'm not really sure how to handle the $x^2$ when it isn't being multiplied by some form of $y$. Advice?

-
I suggest considering all the terms corresponding to powers of $x$ less than 3 individually and grouping the rest. What do you get when you try to substitute $y=\sum a_n x^n$? –  Antonio Vargas Mar 18 '12 at 4:24
This doesn't match the initial conditions, but I noticed that y = -x is a solution to the equation. Not sure if this means much. –  marty cohen Mar 18 '12 at 4:49

## 1 Answer

If $y=\sum_kc_kx^k$, then the initial conditions determine $c_0=2$ and $c_1=1$. The differential equation yields

$$\sum_kk(k-1)c_kx^{k-2}-\sum_kc_kx^{k+1}=x^2\;.$$

The only constant term in this equation is from the first sum, so we must have $c_2=0$. The coefficients of the linear terms are $6c_3$ from the first sum, $-c_0=-2$ from the second and nothing on the right, so $c_3=1/3$. The coefficients of the quadratic terms are $12c_4$ from the first sum, $-c_1=-1$ from the second and $1$ on the right, so $c_4=1/6$. The right-hand side doesn't contribute to any of the remaining terms, so for $k\ge5$ we have $k(k-1)c_k=c_{k-3}$. Thus the solution is

$$y=2\left(1+\frac1{3!}x^3+\frac{1\cdot4}{6!}x^6+\dotso\right)+x+2\left(\frac2{4!}x^4+\frac{2\cdot5}{7!}x^7+\dotso\right)\;.$$

The closed form given by Wolfram|Alpha doesn't look very encouraging.

-
It looks like this simplifies to $y = 2 \, _0F_1\left(;\frac{2}{3};\frac{x^3}{9}\right)+x \left(2 \, _0F_1\left(;\frac{4}{3};\frac{x^3}{9}\right)-1\right)$. –  user26872 Mar 19 '12 at 2:03