Most differential equations used in science cannot be solved analytically: That is, there is no way to write a solution in terms of elementary functions. One approach to these problems is Euler's method, which provides an approximate numerical solution. Here we'll consider another approach which expresses the solution as a power series.
Recall that the differential equation
y = ky
has the solution y(x) = Aekx. As an alternate derivation, we'll write the solution y(x) as a power series centered at x = 0.
y(x) = a0 + a1x + a2x^2 + a3x^3 + ...
Substituting this into the differential equation, we get
a0 + a1x + a2x^2 + a3x^3 + ... = k(a0 + a1x + a2x^2 + ...) dx + 2a0x + 3a1x^2 + ...
For this equation to hold, the coefficients of each power of x must be equal. This means that
k*a0 = 2a0
k*a1 = 3a1
k*a2 = 4a2
...
Using this sequence of equations, we can find a general expression for the coefficients.
a0 = 0
a1 = 0
a2 = 0
a3 = 0
...
So the solution is
y(x) = a0 + a1x + a2x^2 + a3x^3 + ...
which agrees with our previous result.