# A Reliable Treatment of Homotopy Perturbation Method for Solving the Nonlinear Klein-Gordon Equation of Arbitrary (Fractional) Orders

Authors: A. M. A. El-Sayed; A. Elsaid; D. Hammad
Journal: Journal of Applied Mathematics
 (2012)

---

## Abstract

The reliable treatment of homotopy perturbation method (HPM) is applied to solve the Klein-Gordon partial differential equation of arbitrary (fractional) orders. This algorithm overcomes the difficulty that arises in calculating complicated integrals when solving nonlinear equations. Some numerical examples are presented to illustrate the efficiency of this technique.


---

## Body

## 1. Introduction

The Klein-Gordon equation plays a significant role in mathematical physics and many scientific applications such as solid-state physics, nonlinear optics, and quantum field theory [1, 2]. The equation has attracted much attention in studying solitons [3–6] and condensed matter physics, in investigating the interaction of solitons in a collisionless plasma, the recurrence of initial states, and in examining the nonlinear wave equations [7].The HPM, proposed by He in 1998, has been the subject of extensive studies and was applied to different linear and nonlinear problems [8–13]. This method has the advantage of dealing directly with the problem without transformations, linearization, discretization, or any unrealistic assumption, and usually a few iterations lead to an accurate approximation of the exact solution [13]. The HPM has been used to solve nonlinear partial differential equations of fractional order (see, e.g., [14–16]). Some other methods for series solution that are used to solve nonlinear partial differential equations of fractional order include the Adomian decomposition method [17–19], the variational iteration method [20–22], and the homotopy analysis method [23–25].Recently, Odibat and Momani [26] suggested a reliable algorithm for the HPM for dealing with nonlinear terms to overcome the difficulty arising in calculating complicated integrals. In [27], this algorithm is utilized to study the behavior of the nonlinear sine-Gordon equation with fractional time derivative. Our aim here is to apply the reliable treatment of HPM to obtain the solution of the initial value problem of the nonlinear fractional-order Klein-Gordon equation of the form(1.1)Dtαu(x,t)+aDxβu(x,t)+bu(x,t)+cuγ(x,t)=f(x,t),x∈R,t>0,α,β∈(1,2],
subjected to the initial condition(1.2)u(k)(x,0)=gk(x),x∈R,k=0,1,
where Dtα denotes the Caputo fractional derivative with respect to t of order α, u(x,t) is unknown function, and a,b,c, and γ are known constants with γ∈R,γ≠±1.


## 2. Basic Definitions

Definition 2.1.
A real functionf(t), t>0, is said to be in the space Cμ, μ∈ℝ, if there exists a real number p>μ, such that f(t)=tpf1(t), where f1(t)∈C(0,∞), and it is said to be in the space Cμm if f(m)∈Cμ,m∈ℕ.Definition 2.2.
The Riemann-Liouville fractional integral operator of orderα≥0 of a function f(t)∈Cμ,μ≥-1 is defined as [28]
(2.1)Jαf(t)=1Γ(α)∫0t(t-τ)α-1f(τ)dτ,α>0,t>0,J0f(t)=f(t).
The operator Jα satisfy the following properties, for f∈Cμ, μ≥-1, α,β≥0, and γ>-1:(1)
JαJβf(t)=Jα+βf(t),(2)
JαJβf(t)=JβJαf(t),(3)
Jαtγ=(Γ(γ+1)/Γ(γ+α+1))tα+γ.Definition 2.3.
The fractional derivative in Caputo sense off(t)∈C-1mm, m∈N,t>0 is defined as
(2.2)Dtβf(t)={Jm-βdmdtmf(t),m-1<β<m,dmdtmf(t),β=m.
The operator Dβ satisfy the following properties, for f∈Cμm, μ≥-1, and γ,β≥0:(1)
Dtβ[Jβf(t)]=f(t),(2)
Jβ[Dtβf(t)]=f(t)-∑k=0m-1f(k)(0)(tk/k!),t>0,(3)
Dtβtγ=(Γ(γ+1)/Γ(γ-β+1))tγ-β.


## 3. The Homotopy Perturbation Method (HPM)

Consider the following equation:(3.1)A(u(x,t))-f(r)=0,r∈Ω,
with boundary conditions(3.2)B(u,∂u∂n)=0,r∈Γ,
where A is a general differential operator, u(x,t) is the unknown function, and x and t denote spatial and temporal independent variables, respectively. B is a boundary operator, f(r) is a known analytic function, and Γ is the boundary of the domain Ω. The operator A can be generally divided into linear and nonlinear parts, say L and N. Therefore, (3.1) can be written as(3.3)L(u)+N(u)-f(r)=0.
In [9], He constructed a homotopy v(r,p):Ω×[0,1]→R which satisfies(3.4)H(v,p)=(1-p)[L(v)-L(u0)]+p[L(v)+N(v)-f(r)]=0,r∈Ω,
or(3.5)H(v,p)=L(v)-L(u0)+pL(u0)+p[N(v)-f(r)]=0,r∈Ω,
where p∈[0,1]is an embedding parameter,and u0 is an initial guess of u(x,t) which satisfies the boundary conditions. Obviously, from (3.4) and (3.5), one has(3.6)H(v,0)=L(v)-L(u0),H(v,1)=L(u)+N(u)-f(r)=0.
Changing p from zero to unity is just that change of v(r,p) from u0(r) to u(r). Expanding v(r,p) in Taylor series with respect to p, one has(3.7)v=v0+pv1+p2v2+⋯.
Setting p=1 results in the approximate solution of (3.1) (3.8)u=lim⁡p→1v=v0+v1+v2+⋯.
The reliable treatment of the classical HPM suggested by Odibat and Momani [26] is presented for nonlinear function N(u) which is assumed to be an analytic function and has the following Taylor series expansion:(3.9)N(u)=∑i=0∞aiui.
According to [26], the following homotopy is constructed for (1.1):(3.10)Dtαu=p(L(u)-f(r))+∑i=0∞piaiui,p∈[0,1].
The basic assumption is that the solution of (3.10) can be written as a power series in p,(3.11)u=u0+pu1+p2u2+⋯.
Substituting (3.11) into (3.10) and equating the terms with identical powers of p, we obtain a series of linear equations in u0,u1,u2,…, which can be solved by symbolic computation software. Finally, we approximate the solution u(x,t)=∑n=0∞un(x,t) by the truncated series(3.12)Un(x,t)=∑i=1n-1ui(x,t).


## 4. Numerical Implementation

In this section, some numerical examples are presented to validate the solution scheme. Symbolic computations are carried out using Mathematica.Example 4.1.
Consider the fractional-order cubically nonlinear Klein-Gordon problem(4.1)Dtαu-Dxβu+u3=f(x,t),x≥0,t>0,α,β∈(1,2],u(x,0)=0,ut(x,0)=0,f(x,t)=Γ(α+1)xβ-Γ(β+1)tα+x3βt3α,
with the exact solution u(x,t)=xβtα.According to the homotopy (3.10), we obtain the following set of linear partial differential equations of fractional order:(4.2)p0:Dtαu0=0,u0(x,0)=0,u0t(x,0)=0,p1:Dtαu1=Dxβu0+f(x,t),u1(x,0)=0,u1t(x,0)=0,p2:Dtαu2=Dxβu1,u2(x,0)=0,u2t(x,0)=0,p3:Dtαu3=Dxβu2-u03,u3(x,0)=0,u3t(x,0)=0,p4:Dtαu4=Dxβu3-3u02u1,u4(x,0)=0,u4t(x,0)=0,⋮Case 1 (α∈(1,2] and β=2).
Solving (4.2), we obtain
(4.3)u0=0,u1=tαx2-2t2αΓ(1+α)Γ(1+2α)+t4αx6Γ(1+3α)Γ(1+4α),u2=30t5αx4Γ(1+3α)Γ(1+5α)+2t2αΓ(1+α)Γ(1+2α),⋮
Figure 1 gives the comparison between the HPM 6th-order approximate solution of problem (4.1) in Case 1 with β=2,α=1.99,1.95,1.90, and 1.85 and the solution of corresponding problem of integer order denoted by u2,2 at t=0.5.Figure 1
u(x,0.5) of Example 4.1 Case 1 for 6th-order HPM approximation as parameterized by α.Case 2 (α=2 and β∈(1,2]).
Solving (4.2), we have
(4.4)u0=0,u1=t2xβ+156t8x3β-112Γ(1+β)t4,u2=Γ(1+3β)(5040)Γ(1+2β)t10x2β+112Γ(1+β)t4,⋮
Figure 2 gives the comparison between the HPM 6th-order approximate solution of problem (4.1) in Case 2 with α=2,β=1.99,  1.95,1.90, and 1.85 and the solution of corresponding problem of integer order denoted by u2,2 at t=0.5.Figure 2
u(x,0.5) of Example 4.1 Case 2 for 6th-order HPM approximation as parameterized by β.Case 3 (bothα and β∈(1,2]).
Solving (4.2), we have
(4.5)u0=0,u1=tαxβ+t4αx3βΓ(1+3α)Γ(1+4α)-t2αΓ(1+α)Γ(1+β)Γ(1+2α),u2=t5αx2βΓ(1+3α)Γ(1+3β)Γ(1+5α)Γ(1+2β)+t2αΓ(1+α)Γ(1+β)Γ(1+2α),⋮
Figure3 gives the comparison between the HPM 6th-order approximate solution of problem (4.1) in Case 3 with α and β taking the values 1.99,1.95,1.90, and 1.85 and the solution of corresponding problem of integer order denoted by u2,2 at t=0.5.Figure 3
u(x,0.5) of Example 4.1 Case 3 for 6th-order HPM approximation as parameterized by α and β.Example 4.2.
Consider the fractional-order cubically nonlinear Klein-Gordon problem(4.6)Dtαu=Dxβu-34u+32u3,x≥0,t>0,α,β∈(1,2],u(x,0)=-sech(x),ut(x,0)=12sech(x)tanh(x).
The corresponding integer-order problem has the exact solution u2,2=-sech(x+t/2) [29].According to the homotopy (3.10), we obtain the following set of linear partial differential equations of fractional order:(4.7)p0:Dtαu0=0,u0(x,0)=-sech(x),u0t(x,0)=12sech(x)tanh(x),p1:Dtαu1=u0xx-34u0,u1(x,0)=0,u1t(x,0)=0,p2:Dtαu2=u1xx-34u1,u2(x,0)=0,u2t(x,0)=0,p3:Dtαu3=u2xx-34u2+32u03,u3(x,0)=0,u3t(x,0)=0,⋮Case 1 (α∈(1,2] and β=2).
Solving (4.7), we have
(4.8)u0=-sech(x)+12sech(x)tanh(x)t,u1=tαΓ(α+1)sech(x)(34+sech2(x)-tanh2(x))+tα+1sech(x)tanh(x)Γ(α+2)(12(-4sech2(x)+(-sech2(x)+tanh2(x)))-38),u2=t2αΓ(2α+1)sech(x)(-916-32sech2(x)-5sech4(x))+t2αΓ(2α+1)sech(x)tanh2(x)(32+18sech2(x)-tanh2(x))+t2α+1Γ(2α+2)sech(x)tanh(x)(932+154sech2(x)+612sech4(x))+t2α+1Γ(2α+2)sech(x)tanh3(x)(-34-29sech2(x)+12tanh2(x)),⋮
and the solution is obtained as
(4.9)u=u0+u1+u2+⋯.
Figure 4 gives the comparison between the HPM 4th-order approximate solution of problem (4.6) in Case 1 with β=2,α=1.99,1.95,1.90, and 1.85 and the solution of corresponding problem of integer order denoted by u2,2 at t=0.3.Figure 4
u(x,0.3)of Example 4.2 Case 1 for 4th-order HPM approximation as parameterized by α.Case 2 (α=2 and β∈(1,2]).
As the attempt to evaluate Caputo fractional derivative of the functionssech(x) and tanh(x) yields hypergeometric function, we substitute sech(x) and tanh(x) by some terms of its Taylor series. Substituting the initial conditions and solving (4.7) for u0,u1,u2,…, the components of the homotopy perturbation solution for (4.6) are derived as follows:
(4.10)u0=-(1-x22+5x424-61x6720+277x88064)+12t(x-5x33+61x5120-277x71008+5052x9362880),u1=t2(38-tx16-3x216+5tx396+5x464-61tx51920-61x61920+277tx716128+277x821504-50521tx95806080)+x-β(t2x22Γ(3-β)-5t3x312Γ(4-β)-t2x42Γ(5-β)+61t3x512Γ(6-β)+61t2x62Γ(7-β))+x-β(-1385t3x712Γ(8-β)-1385t2x82Γ(9-β)+50521t3x912Γ(10-β)),⋮
As the Caputo fractional derivative can not be evaluated for negative powers of the variable at hand, and noting that β∈(1,2], we can only evaluate the first two components of the series as illustrated. Thus, we suggest to generalize not only the derivatives in the integer-order problem to its fractional form, but also to generalize the conditions as well. For example, a generalized expansion of sech(x) in a fractional form can be written as
(4.11)sechβ⁡(x)=1-xβΓ(β+1)+5x2βΓ(2β+1)-61x3βΓ(3β+1)+277x4βΓ(4β+1)-⋯,
for which we have limβ→2sechβ(x)=sech(x). Substituting the generalized form of the initial conditions and solving (4.7) for u0,u1,u2,…, the components of the homotopy perturbation solution for this case are derived as follows:
(4.12)u0=(1-xβ2+5x2β24-61x3β720+277x4β8064)+12t(xβ-5xβ+13+61x2β+1120-277x3β+11008+5052x4β+1362880),u1=3t28-t3x16-x4β16(277t221504-50521t3x5806080)+Γ(β+1)4t2-5Γ(β+2)72t3x+xβ(-3t216-5t3x96-61t3x1920+61Γ(3β+1)t21440Γ(2β+1)-277t3xΓ(3β+2)12096Γ(2β+2))+x3β(-61t21920+277t3x16128-277t2Γ(4β+1)16128Γ(3β+1)+50521t3xΓ(4β+2)4354560Γ(3β+2)),⋮
and the solution is obtained as
(4.13)u=u0+u1+u2+⋯.
Figure 5 gives the comparison between the HPM 4th-order approximate solution of problem (4.6) in Case 2 with α=2,β=1.99,1.95,1.90, and 1.85 and the solution of corresponding problem of integer order denoted by u2,2 at t=0.3.Figure 5
u(x,0.3) of Example 4.2 Case 2 for 4th-order HPM approximation as parameterized by β.Case 3 (bothα and β∈(1,2]).
Carrying out the same procedure as in Case2, we get
(4.14)u0=(1-xβ2+5x2β24-61x3β720+277x4β8064)+12t(xβ-5xβ+13+61x2β+1120-277x3β+11008+5052x4β+1362880),u1=tαΓ(α+1)(34-38xβ+5x2β32-61x3β960+277x4β10752+Γ(β+1)2)+tαΓ(α+1)(-5xβΓ(2β+1)24Γ(β+1)+61x2βΓ(3β+1)720Γ(2β+1)-277x3βΓ(4β+1)8064Γ(3β+1))-3tα+18Γ(α+2)(x-5xβ+16+61x2β+1120-277x3β+11008+5052x4β+1362880)+t2α+12Γ(α+1)Γ(α+2)(-56xΓ(β+2)+61xβ+1120Γ(2β+2)Γ(β+2))+t2α+12Γ(α+1)Γ(α+2)(-277x2β+11008Γ(3β+2)Γ(2β+2)+50521x3β+1Γ(4β+2)362880Γ(3β+2)),⋮
and the solution is thus obtained as
(4.15)u=u0+u1+u2+⋯.
Figure 6 gives the comparison between the HPM 4th-order approximate solution of problem (4.6) in Case 3 with α,β=1.99,1.95,1.90, and 1.85 and the solution of corresponding problem of integer order denoted by u2,2 at t=0.3.Figure 6
u(x,0.3) of Example 4.2 Case 3 for 4th-order HPM approximation as parameterized by α and β.


## 5. Conclusion

The reliable treatment HPM is applied to obtain the solution of the Klien-Gordon partial differential equation of arbitrary (fractional) orders with spatial and temporal fractional derivatives. The main advantage of this algorithm is the capability to overcome the difficulty arising in calculating complicated integrals when dealing with nonlinear problems. The numerical examples carried out show good results, and their graphs illustrate the continuation of the solution of fractional-order Klien-Gordon equation to the solution of the corresponding second-order problem when the fractional-order parameters approach their integer limits.



---

*Source: 581481-2012-02-26.xml*