You are on page 1of 8

149

14

Homotopy Analysis Method

14.1 Introduction
Homotopy analysis method (HAM) [1–7] is one of the well-known
semi-analytical methods for solving various types of linear and nonlinear
differential equations (ordinary as well as partial). This method is based on
coupling of the traditional perturbation method and homotopy in topology.
By this method one may get exact solution or a power series solution which
converges in general to exact solution. The HAM consists of parameter ℏ ≠ 0
called as convergence control parameter, which controls the convergent
region and rate of convergence of the series solution. This method was first
proposed by Liao [4]. The same was successfully employed to solve many types
of problems in science and engineering [1–8] and the references mentioned
therein.

14.2 HAM Procedure


To illustrate the idea of HAM, we consider the following differential
equation [1–7] in general
N(u(x, t)) = 0, (x, t) ∈ Ω (14.1)
where N is the operator (linear or nonlinear) and u is the unknown function in
the domain Ω.
The method begins by defining homotopy operator H as below [7],
H(𝜙, p) ≡ (1 − p)[L(𝜙(x; p)) − u0 (x)] − pℏN(𝜙(x; p)), (14.2)
where p ∈ [0, 1] is an embedding parameter and ℏ ≠ 0 is the convergence control
parameter [3, 7], u0 is an initial approximation of the solution of Eq. (14.1), 𝜙

Advanced Numerical and Semi-Analytical Methods for Differential Equations, First Edition.
Snehashish Chakraverty, Nisha Rani Mahato, Perumandla Karunakar, and Tharasi Dilleswar Rao.
© 2019 John Wiley & Sons, Inc. Published 2019 by John Wiley & Sons, Inc.
150 14 Homotopy Analysis Method

is an unknown function, and L is the auxiliary linear operator satisfying the


property L(0) = 0.
By considering H(𝜙, p) = 0, we obtain

(1 − p)[L(𝜙(x, t; p)) − u0 (x, t)] = pℏN(𝜙(x, t; p)) (14.3)

which is called the zero-order deformation equation.


From Eq. (14.3), it is clear that for p = 0 we get L(𝜙(x, t; 0)) − u0 (x, t) = 0 that
gives 𝜙(x; 0) = u0 (x, t). On the other hand, for p = 1, Eq. (14.3) reduces to N(𝜙(x,
t; p)) = 0 which gives 𝜙(x, t; 1) = u(x). So, by changing p from 0 to 1 the solution
changes from u0 to u.
Using Maclaurin series, the function 𝜙(x, t; p) with parameter p may be writ-
ten as [7]
∑∞
1 𝜕 m 𝜙(x, t; p) ||
𝜙(x, t; p) = 𝜙(x, t; 0) + | p .
m
(14.4)
m=1
m! 𝜕pm |p=0

Denoting

1 𝜕 m 𝜙(x, t; p) ||
um (x, t) =
𝜕pm | , m = 1, 2, 3, … , (14.5)
m! |p=0
Eq. (14.4) turns into


𝜙(x, t; p) = u0 (x, t) + um (x, t)pm . (14.6)
m=1

If the series (14.6) converges for p = 1 [7], then we obtain the solution of
Eq. (14.1) as


u(x, t) = um (x, t). (14.7)
m=0

In order to determine the function um , we differentiate Eq. (14.3), m times


with respect to p. Next we divide the result by m! and substitute p = 0 [7]. In
this way we may find the mth-order deformation equation for m > 0 as below [7]

L(um (x, t) − 𝜒m um−1 (x, t)) = ℏH(x, t)Rm (um−1 (x, t)) (14.8)
{
0, if m ≤ 1
where H(x, t) is the auxiliary function, 𝜒m = and
1, if m > 1
( (∞ ))
1 𝜕 m−1 ∑
Rm (um−1 (x, t)) = N ui (x)pi
. (14.9)
(m − 1)! 𝜕pm−1 i=1
14.3 Numerical Examples 151

14.3 Numerical Examples


Here, we apply the present method to solve a linear partial differential equation
in Example 14.1 and a nonlinear partial differential equation in Example 14.2.

Example 14.1 We consider a homogeneous linear partial differential


equation from
2ut + ux − uxxt = 0 (14.10)
−x
subject to the initial condition u(x, 0) = e .
𝜕
Solution Here, the auxiliary linear operator is .
𝜕t
Using the above-discussed HAM, the zeroth-order deformation equation is
(from Eq. (14.3))
( )
𝜕
(1 − p) (𝜙(x, t; p)) − u(x, 0)
(𝜕t )
𝜕 𝜕 𝜕3
= pℏ 2 (𝜙(x, t; p)) + (𝜙(x, t; p)) − 2 (𝜙(x, t; p)) (14.11)
𝜕t 𝜕t 𝜕x 𝜕t
subject to the initial condition
𝜙(x, 0, p) = e−x .
where p ∈ [0, 1]. Obviously, if we take p = 0 we get 𝜙(x, t; 0) = e−x and when
p = 1 the equation is equivalent to Eq. (14.10). Thus, it holds
𝜙(x, t; 1) = u(x, t),
where


𝜙 = 𝜙(x, t; p) = u0 (x, t) + um (x, t)pm . (14.12)
m=1

The mth-order deformation equation is [5, 7, 8]


L(um (x, t) − 𝜒m um−1 (x, t)) = ℏH(x, t)Rm (um−1 (x, t)) (14.13)
subject to
um (x, 0) = 0
where
{
0, if m ≤ 1
𝜒m =
1, if m > 1
and
( )
𝜕 𝜕 𝜕3
Rm (um−1 (x, t)) = 2 um−1 + um−1 − 2 um−1 . (14.14)
𝜕t 𝜕x 𝜕x 𝜕t
152 14 Homotopy Analysis Method

Let H(x, t) = 1, then Eq. (14.13) may be rewritten as


L(um (x, t) − 𝜒m um−1 (x, t)) = ℏRm (um−1 (x, t))
um (x, t) − 𝜒m um−1 (x, t) = ℏL−1 (Rm (um−1 (x, t)))
where L−1 is the inverse linear differential operator.
t
um (x, t) = 𝜒m um−1 (x, t) + ℏ Rm (um−1 (x, t))d𝜏
∫0
Let u0 (x, t) = u(x, 0) = e−x
t

u1 (x, t) = 𝜒1 u0 (x, t) + ℏ R0 (u0 (x, t) d𝜏



0
t ( )
𝜕 𝜕 𝜕2
=0+ℏ 2 (e−x ) + (e−x ) − 2 (e−x ) d𝜏
∫0 𝜕𝜏 𝜕x 𝜕x 𝜕𝜏
t
=0+ℏ (0 − e−x − 0) d𝜏
∫0
= −ℏe−x t
t
u2 (x, t) = 𝜒2 u1 (x, t) + ℏ R1 (u1 (x, t)) d𝜏
∫0
t(
𝜕 𝜕
= −ℏe−x t + ℏ 2 (−ℏe−x 𝜏) + (−ℏe−x 𝜏)
∫0 𝜕𝜏 𝜕x
)
𝜕2
− (−ℏe−x 𝜏) d𝜏
𝜕x2 𝜕𝜏
t
= −ℏe−x t + ℏ (−2ℏe−x + ℏe−x 𝜏 + ℏe−x ) d𝜏
∫0
( 2
)
−x t
= −ℏe t + ℏ −2ℏe t + ℏe
−x −x
+ ℏe t
−x
2
ℏe−x t
= (ℏt − 2ℏ − 2)
2
t
u3 (x, t) = 𝜒3 u2 (x, t) + ℏ R2 (u2 (x, t)) d𝜏
∫0
ℏe−x t
= (ℏt − 2ℏ − 2)
2
t( )
𝜕 𝜕 𝜕2
+ℏ 2 (u2 (x, 𝜏)) + (u2 (x, 𝜏)) − 2 (u2 (x, 𝜏)) d𝜏
∫0 𝜕𝜏 𝜕x 𝜕x 𝜕𝜏
ℏe−x t
= (−ℏ2 t 2 + 6ℏt + 6ℏ2 t − 6ℏ2 − 12ℏ + 6).
6

14.3 Numerical Examples 153

The final solution of Eq. (14.10) is


u(x, t) = u0 (x, t) + u1 (x, t) + u2 (x, t) + u3 (x, t) · · ·
ℏe−x t
= e−x − ℏe−x t + (ℏt − 2ℏ − 2)
2
ℏe t
−x
+ (−ℏ2 t 2 + 6ℏt + 6ℏ2 t − 6ℏ2 − 12ℏ + 6) + · · ·
6
(
ℏt
= e−x 1 − ℏt + (ℏt − 2ℏ − 2)
2 )
ℏt
+ (−ℏ t + 6ℏt + 6ℏ2 t − 6ℏ2 − 12ℏ + 6) + · · ·
2 2
6
The approximate solution plots of Eq. (14.10) of order 6 (u(x, t) = u0
(x, t) + u1 (x, t) + u2 (x, t) + u3 (x, t) + u4 (x, t) + u5 (x, t) + u6 (x, t)) for
ℏ = − 0.5, − 0.8,− 1.0, − 1.2 are depicted in Figure 14.1 and also one may
see the comparison of present results with exact solution at t = 1. Similarly
Figure 14.2 represents the same type of results for ℏ = − 0.5, − 0.7, − 0.8, − 1.0
at t = 2.
Here, the exact solution of Eq. (14.10) is u(x, t) = e−x + t .
From the results presented in Figure 14.1, one may see that for ℏ = − 1.0 the
HAM solution is exactly the same as exact solution. The solution for ℏ = − 0.80
is also converging to exact solution. Figure 14.2 also confirms that for t = 2, the
HAM solution is converging to exact solution for ℏ = − 1.2. From the above dis-
cussion it may be concluded that proper values of control parameter ℏ should
be chosen for getting better solution with less error. It may be noted that the
HAM not only produces approximate convergent series solution but it can also
give exact solution depending on the considered problem with proper ℏ. This
may be observed in the next example.

2.8

2.6 Exact
HAM for h = –0.50
2.4 HAM for h = –0.70
HAM for h = –0.80
2.2 HAM for h = –1.0
Solution u(x,1)

1.8

1.6

1.4

1.2

0.8
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
x

Figure 14.1 Solution of Eq. (14.10) for different values of ℏ at t = 1.


154 14 Homotopy Analysis Method

Exact
7 HAM for h = –0.50
HAM for h = –0.80
HAM for h = –1.0
6 HAM for h = –1.2
Solution u(x, 2)

1
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
x

Figure 14.2 Solution of Eq. (14.10) for different values of ℏ at t = 2.

Example 14.2 Now, we take a nonlinear and nonhomogeneous advection


equation [9] as
ut + uux = x (14.15)
subject to the initial condition u(x, 0) = 2.
The zeroth order deformation equation in this case is
( )
𝜕
(1 − p) (𝜙(x, t; p)) − u(x, 0)
𝜕t
( )
𝜕 𝜕
= pℏ (𝜙(x, t; p)) + 𝜙(x, t; p) (𝜙(x, t; p)) − x (14.16)
𝜕t 𝜕x
subject to
𝜙 = 𝜙(x, 0; p) = 2,
where p ∈ [0, 1]. Obviously, if we take p = 0 we get (x, t; 0) = 2 and when p = 1
the equation is equivalent to Eq. (14.15). Thus, it holds 𝜙(x, t; 1) = u(x, t).
The Taylor series expansion of 𝜙(x, t; p) is


𝜙 = 𝜙(x, t; p) = u0 (x, t) + um (x, t)pm (14.17)
m=1

By substituting Eq. (14.17) into Eq. (14.16) and equating the coefficients of like
powers of p, the mth-order deformation equation may be obtained as below [8]
L(um (x, t) − 𝜒m um−1 (x, t)) = ℏH(x, t)Rm (um−1 (x, t)) (14.18)
14.3 Numerical Examples 155

Subject to um (x, 0) = 0
For H(x, t) = 1, the solution of the mth-order deformation equation (14.18)
reads as
t
um (x, t) = 𝜒m um−1 (x, t) + ℏ Rm (um−1 (x, t)) d𝜏 (14.19)
∫0
where
{
0, if m ≤ 1
𝜒m =
1, if m > 1
and
( )
𝜕 𝜕
Rm (um−1 (x, t)) = u + um−1 um−1 − x (14.20)
𝜕t m−1 𝜕x
Let u0 (x, t) = u(x, 0) = 2
t
u1 (x, t) = 0 + ℏ R0 (u0 (x, t)) d𝜏
∫0
t
=ℏ (−x) d𝜏
∫0
= ℏ(−xt)
= −ℏxt
t
u2 (x, t) = u1 (x, t) + ℏ R1 (u1 (x, t)) d𝜏
∫0
t ( )
𝜕 𝜕
= u1 (x, t) + ℏ (u1 ) + u1 (u1 ) − x d𝜏
∫0 𝜕𝜏 𝜕x
t
= −ℏxt + ℏ (−ℏx + ℏ2 x𝜏 2 − x) d𝜏
∫0
( )
t3
= −ℏxt + ℏ −ℏxt + ℏ2 x − xt
3
So, the solution of Eq. (14.15) up to three terms is
u(x, t) = u0 (x, t) + u1 (x, t) + u2 (x, t) + · · ·
( )
t3
= 2 − ℏxt − ℏxt + ℏ −ℏxt + ℏ2 x − xt + · · ·
3
( )
One may see that for ℏ = − 1, u(x, t) = 2 1 − 12 t 2 + 5 4
t −··· +
( ) 24

x t − 13 t 3 + 15
2 5
t −···

u(x, t) = 2 sech t + x tanh t


which is same as the exact solution [9].
156 14 Homotopy Analysis Method

Exercise
1 Apply the HAM to find the solution of the partial differential equation
ut + 14 u2x = x2 , subject to the initial condition u(x, 0) = 0.

x
2 Find the solution of ut + uut = x2 subject to u(x, 0) = 10
.

References
1 Wazwaz, A.M. (2008). A study on linear and nonlinear Schrodinger
equations by the variational iteration method. Chaos, Solitons and Fractals
37 (4): 1136–1142.
2 Song, L. and Zhang, H. (2007). Application of homotopy analysis method
to fractional KdV–Burgers–Kuramoto equation. Physics Letters A 367 (1):
88–94.
3 Liao, S. (2004). On the homotopy analysis method for nonlinear problems.
Applied Mathematics and Computation 147 (2): 499–513.
4 Liao, S. (2012). Homotopy Analysis Method in Nonlinear Differential
Equations, 153–165. Beijing: Higher Education Press.
5 Liang, S. and Jeffrey, D.J. (2009). Comparison of homotopy analysis method
and homotopy perturbation method through an evolution equation.
Communications in Nonlinear Science and Numerical Simulation 14 (12):
4057–4064.
6 Abbasbandy, S. (2006). The application of homotopy analysis method to non-
linear equations arising in heat transfer. Physics Letters A 360 (1): 109–113.
7 Hetmaniok, E., Słota, D., Trawiński, T., and Wituła, R. (2014). Usage of the
homotopy analysis method for solving the nonlinear and linear integral
equations of the second kind. Numerical Algorithms 67 (1): 163–185.
8 Liao, S.J., 1992. The proposed homotopy analysis technique for the solution
of nonlinear problems. Doctoral dissertation, PhD thesis, Shanghai Jiao Tong
University.
9 Wazwaz, A.M. (2010). Partial Differential Equations and Solitary Waves
Theory. Beijing: Springer Science & Business Media, Higher Education Press.

You might also like