Consider the initial value problem of first order ordinary differential equation in the form

$${y}^{{\prime }}+{q}^{{\prime }}\left(x\right)y=g\left(x\right)+f\left(x,y\right) \left(1\right)$$

Where a is given constant and \(g\left(x\right), f\left(x,y\right)\) is a real function.

We rewrite (1) in the form

$$Ly=g\left(x\right)+f\left(x,y\right) \left(2\right)$$

Where the differential operator L is defined by

$$L\left(.\right)={e}^{-q\left(x\right)}\frac{d}{dx}{e}^{q\left(x\right)}\left(.\right) \left(3\right)$$

The inverse operator \({\text{L}}^{-1}\) is therefore considered integral operator, as below

$${L}^{-1}\left(.\right)={e}^{-q\left(x\right)}{\int }_{0}^{x}{e}^{q\left(x\right)}(.)dx \left(4\right)$$

Applying \({L}^{-1}\) on (2) we find

$${L}^{-1}\left(Ly\right)={L}^{-1}( g\left(x\right)+f\left(x,y\right) )$$

$$y\left(x\right)=\varPhi \left(x\right)+{L}^{-1}g\left(x\right)+{L}^{-1}f\left(x,y\right) \left(5\right)$$

Such that\(L\left(\varPhi \left(x\right)\right)=0\)

The Adomian decomposition strategy introduces the solution *y*(*x*) by an infinite series of components

$$y\left(x\right)=\sum _{n=0}^{\infty }{y}_{n}\left(x\right) \left(6\right)$$

and

$$f\left(x,y\right)=\sum _{n=0}^{\infty }{A}_{n} \left(7\right)$$

where the components \({y}_{n}\left(x\right)\) of the solution will be determined recurrently. Specific algorithms formulate called Adomian polynomials. The following algorithm:

$${ A}_{0}=f\left({u}_{0}\right)$$

$${A}_{1}={f}^{{\prime }}\left({u}_{0}\right){u}_{1}$$

$${A}_{2}={f}^{{\prime }}\left({u}_{0}\right){u}_{2}+\frac{1}{2}{f}^{{\prime }{\prime }}\left({u}_{0}\right){u}_{1}^{2}$$

$${A}_{3}={f}^{{\prime }}\left({u}_{0}\right){u}_{3}+{f}^{{\prime }}\left({u}_{0}\right){u}_{1}{u}_{2}+\frac{1}{3!}{f}^{{\prime }{\prime }{\prime }}\left({u}_{0}\right){u}_{1}^{3}, \left(8\right)$$

can be used to construct Adomian polynomials, when \(f\left(u\right)\)is a nonlinear function.

By substituting (6) and (7) into (5),

$$\sum _{n=0}^{\infty }{y}_{n}\left(x\right)=\varPhi \left(x\right)+{L}^{-1}g\left(x\right)+{L}^{-1}\sum _{n=0}^{\infty }{A}_{n} \left(9\right)$$

Through using Adomian decomposition strategy, the components \({y}_{n}\left(x\right)\) can be determined as

$${y}_{0}=\varPhi \left(x\right)+{L}^{-1}g\left(x\right)$$

$${y}_{n+1}\left(x\right)={L}^{-1}{A}_{n} n \ge 0, \left(10\right)$$

Which gives

$${y}_{0}=\varPhi \left(x\right)+{L}^{-1}g\left(x\right),$$

$${y}_{1}={-L}^{-1}{A}_{0} ,$$

$${y}_{2}={-L}^{-1}{A}_{1} ,$$

$${y}_{3}={-L}^{-1}{A}_{2} , \left(11\right)$$

From (8) and (11), we can determine the components \({y}_{n}\left(x\right)\), and hence the series solution of \(y\left(x\right)\) in (6) can be immediately obtained.

For numerical purposes, the n-term approximate

$${\varPsi }_{n}=\sum _{n=0}^{n-1}{y}_{n}\left(x\right) \left(12\right)$$

can be used to approximate the exact solution.