101k views
4 votes
Use a Taylor Series solution, centered at zero to solve the initial-value problem below. (Find a 5th degree approximation only) dy/dx = x + y y(0) = 1

1 Answer

3 votes

We're looking for a solution of the form


y=\displaystyle\sum_(n=0)^\infty a_nx^n=a_0+a_1x+a_2x^2+\cdots

Given that
y(0)=1, we would end up with
a_0=1.

Its first derivative is


y'=\displaystyle\sum_(n=0)^\infty na_nx^(n-1)=\sum_(n=1)^\infty na_nx^(n-1)=\sum_(n=0)^\infty(n+1)a_(n+1)x^n

The shifting of the index here is useful in the next step. Substituting these series into the ODE gives


\displaystyle\sum_(n=0)^\infty(n+1)a_(n+1)x^n-\sum_(n=0)^\infty a_nx^n=x

Both series start with the same-degree term
x^0, so we can condense the left side into one series.


\displaystyle\sum_(n=0)^\infty\bigg((n+1)a_(n+1)-a_n\bigg)x^n=x

Pull out the first two terms (
x^0 and
x^1) of the series:


a_1-a_0+(2a_2-a_1)x+\displaystyle\sum_(n=2)^\infty\bigg((n+1)a_(n+1)-a_n\bigg)x^n=x

Matching the coefficients of the
x^0 and
x^1 terms on either side tells us that


\begin{cases}a_1-a_0=0\\2a_2-a_1=1\end{cases}

We know that
a_0=1, so
a_1=1 and
a_2=1. The rest of the coefficients, for
n\ge2, are given according to the recurrence,


(n+1)a_(n+1)-a_n=0\implies a_(n+1)=(a_n)/(n+1)

so that
a_3=\frac{a_2}3=\frac13,
a_4=\frac{a_3}4=\frac1{12}, and
a_5=\frac{a_4}5=\frac1{60}. So the 5th degree approximation to the solution to this ODE centered at
x=0 is


y\approx1+x+x^2+\frac{x^3}3+(x^4)/(12)+(x^5)/(60)

User Ilanus
by
5.8k points