You are on page 1of 9

131

12

Homotopy Perturbation Method

12.1 Introduction
Homotopy perturbation method (HPM) is a semi-analytical technique for
solving linear as well as nonlinear ordinary/partial differential equations. The
method may also be used to solve a system of coupled linear and nonlinear
differential equations. The HPM was proposed by J. He in 1999 [1]. This
method was developed by making use of artificial parameters [2]. Interested
readers may go through Refs. [3–6] for further details.
Almost all traditional perturbation methods are based on small parameter
assumption. But, a majority of nonlinear problems have no small parameters
at all and the determination of small parameters seems to be a special art
requiring special techniques. These small parameters are so sensitive, such
that a small change in small parameters will affect the results. An appropriate
choice of small parameters leads to ideal results. However, an unsuitable
choice of small parameters results in bad effects, sometimes seriously. Liu [2]
proposed artificial parameter method and Liao [7, 8] contributed homotopy
analysis method to eliminate small parameter assumption. Further, He [1, 9]
developed two effective techniques viz. variational iteration method (VIM)
and HPM in which no small parameter assumptions are required, where
details of the VIM are given in Chapter 13.

12.2 Basic Idea of HPM


In this section we illustrate the basic idea of the HPM. For this we consider the
following differential equation:
A(u) − f (r) = 0, r∈Ω (12.1)
subject to the boundary condition
( )
𝜕u
B u, = 0, r ∈ Γ (12.2)
𝜕r
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.
132 12 Homotopy Perturbation Method

where A represents a general differential operator, B is a boundary operator, Γ


is the boundary of the domain Ω, and f (r) is known analytic function.
The operator A can be decomposed into two parts viz. linear (L) and nonlin-
ear (N). Therefore, Eq. (12.1) may be written in the following form:

L(u) + N(u) − f (r) = 0 (12.3)

An artificial parameter p can be embedded in Eq. (12.3) as follows:

L(u) + p(N(u) − f (r)) = 0, (12.4)

where p ∈ [0, 1] is the embedding parameter (also called as an artificial param-


eter).
Using homotopy technique, proposed by He [1] and Liao [7, 8], we construct
a homotopy v(r, p) : Ω × [0, 1] → R to Eq. (12.3) which satisfies

H(v, p) = (1 − p)[L(v) − L(u0 )] + p[L(v) + N(v) − f (r)] = 0 (12.5)

and

H(v, p) = L(v) − L(u0 ) + pL(u0 ) + p[N(v) − f (r)] = 0. (12.6)

Here, u0 is an initial approximation of Eq. (12.6) which satisfies the given con-
ditions.
By substituting p = 0 and p = 1 in Eq. (12.6), we may get the following
equations, respectively.

H(v, 0) = L(v) − L(u0 )

and

H(v, 1) = A(v) − f (r) = 0.

As p changes from zero to unity, v(r, p) changes from u0 (r) to u(r). In topol-
ogy, this is called deformation and L(v) − L(u0 ) and A(v) − f (r) are homotopic
to each other. Due to the fact that p ∈ [0, 1] is a small parameter, we consider
the solution of Eq. (12.5) as a power series in p as below

v = v0 + p v1 + p2 v2 + · · · (12.7)

The approximate solution of Eq. (12.1) may then be obtained as

u = lim v = v0 + v1 + v2 + · · · (12.8)
p→1

The convergence of the series solution (12.8) has been given in Ref. [1].
12.3 Numerical Examples 133

12.3 Numerical Examples


Here, we use the present method to solve a nonlinear ordinary differential
equation in Example 12.1 and a nonlinear partial differential equation in
Example 12.2. Finally, a coupled nonlinear system of partial differential
equations has been solved in Example 12.3. It is worth mentioning that the
HPM can also be used for handling linear ordinary and partial differential
equations.

Example 12.1 We consider a homogeneous ordinary differential equation


from Ref. [5] as
dy
+ y2 = 0 (12.9)
dx
subject to the initial condition y(0) = 1.

Solution By using the HPM, we construct homotopy v(r, p) : Ω × [0, 1] → R


which satisfies
( ) ( )
dv dy0 dv
(1 − p) − +p + v2 = 0, (12.10)
dx dx dx
𝜕v 𝜕y0 𝜕y
= − p 0 − pv2 . (12.11)
𝜕x 𝜕x 𝜕x
Solution of Eq. (12.10) is assumed in the form of a power series
v = v0 + pv1 + p2 v2 + · · · (12.12)
where y = lim v = v0 + v1 + v2 + · · · using Eq. (12.8).
p→1
By substituting Eq. (12.12) in Eq. (12.11), we get

𝜕 𝜕y 𝜕y
(v + pv1 + p2 v2 + · · ·) = 0 − p 0 − p(v0 + pv1 + p2 v2 + · · ·)2
𝜕x 0 𝜕x 𝜕x
(12.13)
By equating like powers of p from both sides in Eq. (12.13), one may get
dv0 dy0
p0 ∶ = (12.14)
dx dx
dv dy
p1 ∶ 1 = − 0 − v20 (12.15)
dx dx
dv
p2 ∶ 2 = −2v0 v1 (12.16)
dx
dv
p3 ∶ 3 = −2v0 v2 − v21 (12.17)
dx
134 12 Homotopy Perturbation Method

dv4
p4 ∶ = −2v0 v3 − 2v1 v2 (12.18)
dx
and so on.
By integrating above Eqs. (12.14)–(12.18) with respect to “x” we get
v0 = y0 = 1
v1 = − x
v2 = x 2 .
v3 = − x3
v4 = x4 .
The solution of Eq. (12.9) is
y = lim(v0 + pv1 + p2 v2 + · · ·)
p→1

⇒ y = 1 − x + x2 − x3 + x4 + · · ·
1
⇒y=
1+x

Example 12.2 We consider a nonhomogeneous advection equation from Ref.


[10] as
ut + uux = x (12.19)
subject to the initial condition u(x, 0) = 2.

Solution In the present problem, L(u) = ut is the linear part and N(u) = uux
is the nonlinear part of the nonlinear differential Eq. (12.19), and the known
analytic function is f (x) = x.
Using the HPM as discussed above, we construct homotopy v(r, p) : Ω ×
[0, 1] → R which satisfies
( ) ( )
𝜕v 𝜕u0 𝜕v 𝜕v
(1 − p) − +p +v −x =0 (12.20)
𝜕t 𝜕t 𝜕t 𝜕x
This after simplification becomes
( )
𝜕v 𝜕u0 𝜕u 𝜕v
= −p 0 −p v −x . (12.21)
𝜕t 𝜕t 𝜕t 𝜕x
Assume the solution of Eq. (12.20) in the form of a power series as below
v = v0 + pv1 + p2 v2 + · · · (12.22)
where u = lim v = v0 + v1 + v2 + · · · using Eq. (12.8).
p→1
12.3 Numerical Examples 135

By substituting Eq. (12.22) in Eq. (12.21), we have

𝜕 𝜕u 𝜕u
(v + pv1 + p2 v2 + · · ·) = 0 − p 0
𝜕t 0 𝜕t 𝜕t
( )
𝜕
− p (v0 + pv1 + p v2 + · · ·) (v0 + pv1 + p2 v2 + · · ·) − x
2
(12.23)
𝜕x
By equating like powers of p from both sides of Eq. (12.23), we get

𝜕v0 𝜕u
p0 ∶ = 0 (12.24)
𝜕t 𝜕t
𝜕v1 𝜕u 𝜕v
p1 ∶ = − 0 − v0 0 + x (12.25)
𝜕t 𝜕t 𝜕x
𝜕v2 𝜕v 𝜕v
p2 ∶ = −v0 1 − v1 0 (12.26)
𝜕t 𝜕x 𝜕x
𝜕v3 𝜕v 𝜕v 𝜕v
p3 ∶ = −v0 2 − v1 1 − v2 0 (12.27)
𝜕t 𝜕x 𝜕x 𝜕x
𝜕v4 𝜕v 𝜕v 𝜕v 𝜕v
p4 ∶ = −v0 3 − v1 2 − v2 1 − v3 0 (12.28)
𝜕t 𝜕x 𝜕x 𝜕x 𝜕x
𝜕v5 𝜕v 𝜕v 𝜕v 𝜕v 𝜕v
p5 ∶ = −v0 4 − v1 3 − v2 2 − v3 1 − v4 0 (12.29)
𝜕t 𝜕x 𝜕x 𝜕x 𝜕x 𝜕x
and so on.
The general term may be written as

𝜕vn+1 ∑ 𝜕vn−i
n
pn+1 ∶ =− vi , n = 1, 2, 3, …
𝜕t i=0
𝜕x

By integrating above Eqs. (12.24)–(12.29) with respect to “t”, one may obtain

v0 = u0 = 2
v1 = xt
v2 = − t 2
1
v3 = − xt 3
3
5 4
v4 = t
12
2
v5 = xt 5
15

136 12 Homotopy Perturbation Method

The solution of the advection equation as p → 1 (using Eq. (12.8)) may then
be written as
1 5 2
u = 2 + xt − t 2 − xt3 + t 4 + xt 5 + · · ·
3 12 15
( ) ( )
1 5 1 2
u = 2 1 − t2 + t4 − · · · + x t − t3 + t5 − · · ·
2 24 3 15
u = 2 sech t + x tanh t.

Example 12.3 Next, we apply the HPM to solve a coupled nonlinear system
of Burgers’ equations [11]:
ut − uxx − 2uux + (uv)x = 0, (12.30)

vt − vxx − 2vvx + (uv)x = 0, (12.31)


subject to the initial conditions:
u(x, 0) = sin x and v(x, 0) = sin x. (12.32)

Solution By using modified HPM proposed by Sweilam and Khader [11], we


construct homotopies as follows:
ut = ut (x, 0) + p[uxx + 2uux − (uv)x ], (12.33)

vt = vt (x, 0) + p[vxx + 2vvx − (uv)x ], (12.34)


We consider solutions of (12.30) and (12.31) in the series form as
u = u0 + pu1 + p2 u2 + · · · (12.35)

v = v0 + pv1 + p2 v2 + · · · (12.36)
By substituting Eqs. (12.35) and (12.36) in Eqs. (12.33) and (12.34), respec-
tively, we get
𝜕
(u0+ pu1 + p2 u2 + · · ·) ⎫
𝜕t [ 2 ⎪
= 𝜕t𝜕 u(x, 0) + p 𝜕x
𝜕
2
(u0 + pu1 + p2 u2 + · · ·) ⎪
2 𝜕 2 ⎬ (12.37)
+ 2(u0 + pu1 + p u2 + · · ·) 𝜕x (u0 + pu1 + p u2 + · · ·) ⎪
]
𝜕
− 𝜕x ((u0 + pu1 + p2 u2 + · · ·)(v0 + pv1 + p2 v2 + · · ·)) ,⎪

𝜕
(v+ pv1 + p2 v2 + · · ·) ⎫
𝜕t 0 [ 2 ⎪
= 𝜕t𝜕 v(x, 0) + p 𝜕x
𝜕
2
(v0 + pv1 + p2 v2 + · · ·) ⎪
2 𝜕 2 ⎬ (12.38)
+ 2(v0 + pv1 + p v2 + · · ·) 𝜕x (v0 + pv1 + p v2 + · · ·) ⎪
]
𝜕
− 𝜕x ((u0 + pu1 + p2 u2 + · · ·)(v0 + pv1 + p2 v2 + · · ·)) ,⎪

12.3 Numerical Examples 137

By equating identical powers of p from both sides of Eqs. (12.37) and (12.38),
one can obtain
𝜕u0 𝜕
p0 ∶ = u0 (x, 0) (12.39)
𝜕t 𝜕t
𝜕v0 𝜕
= v0 (x, 0) (12.40)
𝜕t 𝜕t
After integrating, these lead to

u0 (x, t) = u0 (x, 0) = sin x,


v0 (x, t) = v0 (x, 0) = sin x, (12.41)
( )
𝜕u1 𝜕2 𝜕u0 𝜕v0 𝜕u0
1
p ∶ = 2 u0 + 2u0 − u0 + v0 , (12.42)
𝜕t 𝜕x 𝜕x 𝜕x 𝜕x
( )
𝜕v1 𝜕2 𝜕v 𝜕v 𝜕u
= 2 v0 + 2v0 0 − u0 0 + v0 0 , (12.43)
𝜕t 𝜕x 𝜕x 𝜕x 𝜕x
( )
𝜕u 𝜕2 𝜕u 𝜕u
p2 ∶ 2 = 2 u1 + 2 u0 1 + u1 0
𝜕t 𝜕x 𝜕x 𝜕x
( )
𝜕v1 𝜕v0 𝜕u1 𝜕u
− u0 + u1 + v0 + v1 0 , (12.44)
𝜕x 𝜕x 𝜕x 𝜕x
( )
𝜕v2 𝜕2 𝜕v 𝜕v
= 2 v1 + 2 v0 1 + v1 0
𝜕t 𝜕x 𝜕x 𝜕x
( )
𝜕v1 𝜕v0 𝜕u 𝜕u
− u0 + u1 + v0 1 + v1 0 , (12.45)
𝜕x 𝜕x 𝜕x 𝜕x
and so on.
By integrating Eqs. (12.42)–(12.45) with respect to time, we obtain
( ( ))
t
𝜕2 𝜕u0 𝜕v0 𝜕u0
u1 = u + 2u0 − u0 + v0 dt = −t sin x
∫0 𝜕x2 0 𝜕x 𝜕x 𝜕x
(12.46)
( ( ))
𝜕2
t
𝜕v0 𝜕v0 𝜕u0
v1 = v + 2v0 − u0 + v0 dt = −t sin x (12.47)
∫0 𝜕x2 0 𝜕x 𝜕x 𝜕x
t( 2 ( )
𝜕 𝜕u1 𝜕u0
u2 = u + 2 u0 + u1
∫0 𝜕x2 1 𝜕x 𝜕x
( ))
𝜕v1 𝜕v0 𝜕u1 𝜕u0 t2
− u0 + u1 + v0 + v1 dt = sin x (12.48)
𝜕x 𝜕x 𝜕x 𝜕x 2
138 12 Homotopy Perturbation Method

( ( )
t
𝜕2 𝜕v1 𝜕v0
v2 = v + 2 v0 + v1
∫0 𝜕x2 1 𝜕x 𝜕x
( ))
𝜕v1 𝜕v0 𝜕u1 𝜕u0 t2
− u0 + u1 + v0 + v1 dt = sin x. (12.49)
𝜕x 𝜕x 𝜕x 𝜕x 2
Similarly, we may obtain u3 , u4 , … and v3 , v4 , …
By setting p = 1 in Eqs. (12.35) and (12.36), the solutions of Eqs. (12.30) and
(12.31) may be found as
( )
t2 t2
u(x, t) = sin x − t sin x + sin x + · · · = sin x 1 − t + − · · · = sin xe−t .
2 2
2
( )
t t2
v(x, t) = sin x − t sin x + sin x + · · · = sin x 1 − t + − · · · = sin xe−t .
2 2
The test problems demonstrated above confirm that the HPM is an efficient
method for solving linear/nonlinear ordinary, partial, and coupled differen-
tial equations. The series usually converges with an increase in the number of
terms, but one may not expect the compact form solution always.

Exercise
dy
1 Apply the HPM to find the solution differential equation dt
+ y2 = 1,
y(0) = 0.

2 Solve the homogenous KdV equation ut − 6uux + uxxx = 0 subject to initial


condition u(x, 0) = 6x using the HPM.

References
1 He, J.H. (1999). Homotopy perturbation technique. Computer Methods in
Applied Mechanics and Engineering 178 (3): 257–262.
2 Liu, G.L., (1997). New research directions in singular perturbation theory:
artificial parameter approach and inverse-perturbation technique. Pro-
ceedings of the 7th Conference of modern Mathematics and Mechanics,
Shanghai (September 1997), pp. 47–53.
3 Karunakar, P. and Chakraverty, S. (2017). Comparison of solutions of linear
and non-linear shallow water wave equations using homotopy perturbation
method. International Journal of Numerical Methods for Heat and Fluid
Flow 27 (9): 2015–2029.
4 Karunakar, P. and Chakraverty, S. (2018). Solution of interval shallow
water wave equations using homotopy perturbation method. Engineering
Computations 35 (4): 1610–1624.
References 139

5 He, J.H. (2003). Homotopy perturbation method: a new nonlinear analytical


technique. Applied Mathematics and Computation 135 (1): 73–79.
6 He, J.H. (2004). The homotopy perturbation method for nonlinear oscilla-
tors with discontinuities. Applied Mathematics and Computation 151 (1):
287–292.
7 Liao, S.J. (1995). An approximate solution technique not depending on
small parameters: a special example. International Journal of Non-Linear
Mechanics 30 (3): 371–380.
8 Liao, S.J. (1997). Boundary element method for general nonlinear dif-
ferential operators. Engineering Analysis with Boundary Elements 20 (2):
91–99.
9 He, J.-H. (1999). Variational iteration method–a kind of non-linear ana-
lytical technique: some examples. International Journal of Non-Linear
Mechanics 34 (4): 699–708.
10 Wazwaz, A.M. (2010). Partial Differential Equations and Solitary Waves
Theory. Beijing: Springer Science & Business Media, Higher Education
Press.
11 Sweilam, N.H. and Khader, M.M. (2009). Exact solutions of some coupled
nonlinear partial differential equations using the homotopy perturbation
method. Computers and Mathematics with Applications 58 (11): 2134–2141.

You might also like