If the solution is an analytical function near \(x=0\) then we can use the regular power series
$$ y(x) = \sum_{n=0}^{\infty}{a_n x^n} = a_0 + a_1 x + a_2 x^2 + \cdots $$
If the ODE has
$$ y^{(n)} + p_{n-1}(x) y^{(n-1)} + \cdots + p_1(x) y' + p_0(x) y = r(x) $$
analytical coefficients i.e. \(p_i(x)\) are all analytical, then we can use power series.
Example 1
Find the solution of the following ODE near \(x=0\) using power series
$$ y' = y $$
solution:
$$ y(x) = \sum_{n=0}^{\infty}{a_n x^n} = a_0 + a_1 x + a_2 x^2 + \cdots $$
$$ y'(x) = \sum_{n=1}^{\infty}{a_n n x^{n-1}} = a_1 + 2 a_2 x + 3 a_3 x^2 + \cdots $$
$$ a_1 + 2 a_2 x + 3 a_3 x^2 + \cdots = a_0 + a_1 x + a_2 x^2 + \cdots $$ which gives
$$ a_1 = a_0 $$
$$ 2 a_2 = a_1 = a_0 \to a_2 = \frac{a_0}{2} $$
$$ 3 a_3 = a_2 \to a_3 = \frac{a_0}{2 \times 3} $$
$$ \cdots $$
$$ y(x) = a_0 + a_0 x + \frac{a_0}{2} x^2 + \frac{a_0}{2 \times 3} x^3 + \cdots $$
$$ y(x) = a_0 \left( 1 + x + \frac{1}{2!} x^2 + \frac{1}{3!} x^3 + \cdots \right)$$
Inside the paranthesis we have the Taylor series expansion of the exponential function.
We can not find \(a_0\) because we need one additinal condition: initial condition.
Compare this to the exact solution
$$ y(x) = c_1 e^{x} $$