Download as pdf or txt
Download as pdf or txt
You are on page 1of 15

Nonlinear Dyn

https://doi.org/10.1007/s11071-017-3964-5

ORIGINAL PAPER

A novel numerical algorithm based on Galerkin–Petrov


time-discretization method for solving chaotic nonlinear
dynamical systems
Muhammad Sabeel Khan · Muhammad Ijaz Khan

Received: 22 May 2017 / Accepted: 19 November 2017


© Springer Science+Business Media B.V., part of Springer Nature 2017

Abstract Nonlinear chaotic systems yield many inter- Keywords Nonlinear dynamical systems · Time-
esting features related to different physical phenomena discretization method · Numerical Solution · Galerkin–
and practical applications. These systems are very sen- Petrov method
sitive to initial conditions at each time-iteration level
in a numerical algorithm. In this article, we study the
behavior of some nonlinear chaotic systems by a new 1 Introduction
numerical approach based on the concept of Galerkin–
Petrov time-discretization formulation. Computational Nonlinear chaotic systems arise in many interest-
algorithms are derived to calculate dynamical behavior ing engineering applications [1–17]. Cheng et al. [1]
of nonlinear chaotic systems. Dynamical systems rep- investigate the chaotic dynamics of micro-electro-
resenting weather prediction model and finance model mechanical resonator, which has its prospects in differ-
are chosen as test cases for simulation using the derived ent applications. In local area networks, the study on
algorithms. The obtained results are compared with traffic network shows complex dynamics and exhibits
classical RK-4 and RK-5 methods, and an excellent chaotic [2] behavior. Chaotic dynamical systems also
agreement is achieved. The accuracy and convergence appear in the study [3] of biological viscous fluids
of the method are shown by comparing numerically where different viscoelastic properties of these fluids
computed results with the exact solution for two test can be calculated. Moreover, fluid flows through micro-
problems derived from another nonlinear dynamical channels at large Reynolds number result in chaotic
system in two-dimensional space. It is shown that the flows, which are induced by non-inertial forces like
derived numerical algorithms have a great potential in acoustic force, viscoelastic force and interfacial ten-
dealing with the solution of nonlinear chaotic systems sion. To simulate an economic system, also a numer-
and thus can be utilized to delineate different features ical algorithm based on Adams–Bashforth numerical
and characteristics of their solutions. scheme has been presented in [4]. In biology, spa-
tiotemporal chaotic system has been used to develop
M. S. Khan (B) numerical algorithms [18] based on DNA encoding for
Department of Applied Mathematics and Statistics, image encryption. The nonlinear Korteweg–de Vries
Institute of Space Technology, Islamabad 44000, Pakistan
e-mail: drmsabeel@gmail.com
equation has been studied numerically by Dehghan et
al. [19] using collocation and radial basis functions.
M. I. Khan
Department of Mechanical Engineering, Khawaja Fareed Uni-
Nonlinear dynamics of micro-gas-bearing system has
versity of Engineering and Information Technology, Abu Dhabi been investigated by Wang [20] using a hybrid numeri-
Road, Rahim Yar Khan, Pakistan cal method. He’s variational iteration method was used

123
M. S. Khan, M. I. Khan

by Shakeri [21] to discuss the nonlinear behavior of clusions are drawn based on the obtained simulation
Klein–Gordon equation. The numerical algorithms for results in Sect. 4.
image encryption are discussed in [5–8,22] and refer-
ences therein. Other numerical algorithms solving non-
stationary nonlinear problems are discussed in [23] and 2 A mathematical framework for GTDM
references therein. Wang [24] has used a hybrid tech-
nique combining finite difference and differential trans- In this section, we present a time-discretization method
form method in order to study the nonlinear dynamical to solve nonlinear dynamical chaotic systems of the
analysis of a micro-gas-bearing system. form
Analyzing such dynamical systems with chaotic d
behavior is very much unpredictable due to strong sen- {U (t)} = F (t, U (t)) . (1)
dt
sitivity to initial conditions at each time-iteration level
in a numerical algorithm. To understand the complex where U (t) = (x, y, z)T is the vector of state variables
chaotic nature [9–12,25–27] of these flows, it is there- and F is the vector of nonlinear elementary functions
fore necessary to develop numerical algorithms that can in space and time. Such systems yield many interesting
accurately predict true characteristics of flow behavior. features related to different physical phenomena [1–
Here, we propose new novel numerical algorithms 3,9–15,18–20,25–27]. In order to develop a numerical
based on Galerkin- type discretization methods [28– method to solve such dynamical systems, here, we use
30]. Galerkin method that was first introduced by a the concept of a Galerkin-type formulation and time
Russian mathematician Grigoryevich Galerkin now has discretization. Consider S as a space of all admissible
been successfully applied to solve different problems solutions to the set of nonlinear ordinary differential
in engineering sciences, for instance see [31] and refer- equations in Eq. (1). We search a vector of state vari-
ences therein for a comprehensive review on its appli- ables U : (0, τ ] → S such that
cations. The accuracy and robustness of these methods d
{U (t)} = F(t, U (t)), ∀t ∈ (0, τ ] ,
have already been shown [28]. Galerkin schemes are dt
class of numerical methods which convert the strong where, U (0) = U0 . (2)
form of differential equations to a weak formulation
By choosing  as a test space, the problem in Eq. (2)
where the differential equations are transformed to dis-
can be formulated as follows: Find U ∈ S such that
crete set of equations. The discrete set of equations
is obtained after applying the principle of variations τ
d
using a test function from the test function space. The V T (t) U (t)dt
dt
solution is then sought in the solution function space 0
usually defined by suitable basis functions. Among τ
other class of Galerkin methods, the test function space = V T (t) F (t, U (t)) dt, ∀V ∈.
in Galerkin–Petrov method is not same as the solu- 0
tion function space. Therefore, this method is gener- With U (0) = U0 , (3)
ally applicable to all types of problems where solution
function space is different from test function space. Equation (3) is the weak form of problem in Eq. (2).
Here, we employ this technique to develop a numer- Now, to solve it over the time interval I = (0, τ ] let
ical scheme for some chaotic dynamical systems and us discretize the interval I into N number of subin-
outline numerical algorithms for their simulations. tervals with each subinterval In = (tn−1 , tn where
This paper is organized as follows: In Sect. 2, a math- n ∈ {1, . . ., N} and having the property
ematical framework based on the Galerkin discretiza- 
N

tion method is described to develop Galerkin time- (tn−1 , tn = (0, τ ] ,
discretization method (GTDM) for nonlinear dynami- n=1
cal systems. In Sect. 3, the GTDM is then applied to two Moreover, it also satisfies,
dynamical systems and their numerical algorithms are  
presented. In Sect. 4, numerical results are discussed (tn−1 , tn (tm−1 , tm = φ, ∀n = m
and simulation data is shown. In the last section, con- n, m = 1, . . ., N .

123
A novel numerical algorithm based on Galerkin–Petrov time-discretization method

  
To approximate the vector of state variables U (t) at the d
vT (t) Uσ (t) ϕn,i (t) dt
time interval In , we choose n, j (t) ∈ Pk (In ) as a set In dt
  
of linearly independent basis functions. Here, Pk (In )
= vT (t) F (t, Uσ (t)) ϕn.i (t) dt; v ∈ S H . (7)
denotes the following space of kth- degree polynomials In
defined on interval In
Or, equivalently we write using Eq. (7)
P (In , S H ) ⎛ ⎞
   k

k d
:= U (t) : In → S H ; U (t) = u j t j , ∀t ∈ In , u j ∈ S H . ⎝vT (t) un ψn, j (t)⎠
j
j=0 dt
In j=0
(4) ⎛ ⎛ ⎞⎞

k
The vector of state variables U (t) in Eq. (4) is thus ϕn,i (t) dt = ⎝vT (t) F ⎝t, un ψn, j (t)⎠⎠
j

approximated by In j=0

ϕn.i (t) dt; v ∈ S H . (8)



k
j
U (t) ≈ Uσ (t) = un ψn, j (t) , ∀t ∈ In (5) To define basis functions in Eq. (8), we use the map-

ping Mn : I → I¯n , which maps the time interval
j=0

j I = [−1, 1] from natural time frame to physical time
where are the vector elements in Hilbert space S H .
un
Global vector of state variables Uσ (t) : In → S H interval I¯n . Now, for any t ∈ I there exists a t ∈ I¯n
belongs to the discrete solution space Sσk ⊂ S where such that

tn−1 +tn
t
Sσk := U (t) ∈ C (In , S H ) : U (t) | In t = Mn tˆ := + tˆ ∈ I¯n ; n=1, . . ., N .
2 2
∈ Pk I¯n , S H ; ∀n = 1, . . ., N ,
 where
t is the time step size. The basis functions
with I¯n = In {tn−1 }. The symbol σ above represents defined on the physical time interval I¯n can now be
the discretization parameter. The test function V (t) is computed on the natural time interval as
taken from the discrete test space ℘σk where,
 
 ψn, j (t) := ψ j Mn−1 (t) ; j = 0, . . ., k,
℘σk := V (t) ∈ L2 (In , S H ) : V (t) | In  
ϕn.i (t) := ϕ̂i Mn−1 (t) ; i = 0, . . .k − 1.
∈ Pk−1 (In , S H ) ; ∀n = 1, . . ., N } .

   
By denoting Vσ (t) as a discrete approximation of the where ψ j ∈ Pk Iˆ and ϕ̂i ∈ Pk−1 Iˆ are satisfying
continuous test function V (t), the weak problem in Eq. the property
(3) takes the following variational form which states:
Find Uσ (t) ∈ Uo + Sσ,0
k such that

ψ j (−1) = δ0, j , ψ̂ j (1) = δk, j , (9)

d
VσT (t) tUσ (t) dt
d δk, j denote the Kronecker’s delta. To get a second-order
0 approximation of the discrete vector of state variables
τ j
Uσ (t), we need to find the coefficients un ; j = 0, 1, 2.
= VσT (t)F (t, Uσ (t)) dt; Vσ ∈ ℘σk . (6) By using the property of basis function from Eq. (9) and
0 by the application of initial condition the coefficients,
 un0 can be determined from the following
k
Above sσ,0 := Sσk So denotes the subspace of Sσk
initial condition. Define a polynomial ϕn,i ∈
with zero 
Pk−1 I¯n on the time interval I which is zero U0 , n=1
 every-  un0 = k , n > 1. (10)
where in I except at the time interval I¯n = tn−1 , tn , un−1
and v ∈ S H being arbitrary scalar function and then
the variational form in Eq. (6) on the time interval In Since it is convenient to work with natural time interval
reads Iˆ, Eq. (9) is transformed into

123
M. S. Khan, M. I. Khan


k  
t  2.2 Discretized system of nonlinear equations
j
αi, j vT un = vT F
2
j=0
Iˆ By choosing k = 2 and selecting the test function
⎛ ⎞  T
k
v = ψ̂i tˆj ϕ̂0 tˆj ϕ̂1 tˆj as given in Sect. 2.1,
⎝ Mn tˆ , j ˆ
un  j tˆ ⎠ ϕ̂i tˆ dtˆ; v ∈ SH the discretized form of the nonlinear chaotic dynam-
j=0
ical system in Eq. 1 is thus obtained from Eq. 14 as
(11) follows
where i = 0, . . ., k − 1 and


d un1 = 21 un0 + 21 un2 +
t
8 F tn,0 , un − F tn,2 , un
0 2
αi, j := ψ̂j tˆ ϕ̂i tˆ d tˆ.
dtˆ
.
un2 = un0 +
t6 F tn,0 , un + 4F tn,1 , un + F tn,2 , un
0 1 2

By the application (k + 1)-point Gauss–Lobatto quadra- (15)
ture formula to the integral term in the above equation,
we write

k   3 Application of GTDM to nonlinear dynamical
j
αi, j vT un systems
j=0


k     In this section, the proposed technique GTDM is
j
≈ ŵl vT F Mn tˆl , kj=0 un ψ̂ j tˆl ϕ̂i tˆl ; v ∈ SH
l=0
applied to develop numerical algorithms for comput-
(12) ing the solution of nonlinear dynamical systems. In
this respect, we choose two test cases where, in the first
where Ŵl are the weights, tˆ0 = −1, tˆk = 1, and tˆl ∈
case, Lorenz system [13] with application to weather
Iˆ; l = 1, . . ., k − 1, and the roots of the Legendre poly-
prediction is selected, which is characterized by the
nomial Pk−1 (t). By abbreviating
following set of equations
tn,l := gn tˆl , βi , l := ŵl ϕ̂ tˆl and η j.l := ψ̂ j tˆl .
(13) ẋ = a(y − x),
we finally get the following system of coupled equa- ẏ = bx − y − x z,
tions ż = −cz + x y, (16)
⎛ ⎛ ⎞⎞

k  
t
k
k
αi, j vT un
j
= βi,l ⎝vT F ⎝tn,l , un η j,i ⎠⎠
j where a, b and c are some positive parameters. In the
2 second case, a nonlinear model [14] with application
j=0 l=0 j=0

v ∈ SH , i = 0, . . ., k − 1 and j = 0, . . ., k, (14) to finance is considered for simulation. The finance


model in three state variables x, y and z each represent-
with the initial condition as described in Eq. (10).
ing interest rate, investment demand and price index,
respectively, is given as
2.1 Computation of parameters αi, j , βi, j and η j,l
ẋ = z + (y − a)x,
To compute the unknown parameters in Eq. (14), let us ẏ = 1 − by − x 2 ,
select the following set of test functions ż = −x − cz, (17)
3
ψ̂i tˆj = δi, j , ϕ̂0 tˆj = − tˆj , ϕ̂1 tˆj = 1 where a, b and c are nonnegative parameters represent-
4
∀i, j ∈ {0, 1, 2} ing, respectively, the saving amount, the cost per invest-
    ment and elasticity of demand of commercial markets.
where each ψ̂j tˆ ∈ Pk Iˆ , ϕ̂i tˆ ∈ Pk−1 Iˆ , and Now, in order to get the time-discrete form of the non-
tˆ0 = −1, tˆ1 = 0, and tˆ2 = 1. By this assumption, the linear dynamical systems in Eqs. 16 and 17, we use the
following values of αi, j , βi, j and η j,l are obtained, set of discretized coupled equations from Eq. 16. In
respectively

this respect, the vector of state variables in the nth time

⎨ α0,0 = − 2 , α0,1 = 1 = α1,2 , α0,2 = −α0,0 , α1,0 = −α0,1 , α1,1 = 0,
1
element is un = (xn , yn , z n )T . Moreover, the nonlinear
β0,0 = 41 , β0,1 =0, β0,2 = − β0,0 , β1,1 = − 3β0,0 , β1,0 =β1,2 = − 4β11,1 function F (tn , un ) corresponding to the system in Eq.

⎩ η = δ , ∀i, j ∈ {0, 1,2}.
i, j i, j 16 is

123
A novel numerical algorithm based on Galerkin–Petrov time-discretization method


⎨ a(yn − xn ) xn1 , yn1 and z n1 from the following nonlinear
F (tn , un ) = bxn − yn − xn z n , equations (derived using the second set of

−cz n + xn yn equations from Eq. 15).
 
and corresponding to system in Eq. 17, it takes the 6 − a
t
xn2 = xn0
following form 6 + a
t
⎧     !
⎨ z n + (yn − a)xn a
t
+ yn0 + 4 yn1 − xn1 + yn2
F (tn , un ) = 1 − byn − xn2 . 6 + a
t
⎩  
−xn − cz n 6 −
t
yn2 = yn0
The time-discrete forms of the models in Eqs. 16 and 6 +
t
  0 
17 are thus shown in numerical algorithms outlined in
t bxn + 4bxn1 − 4yn1 − xn0 z n0
+
the following subsection. 6 +
t −4xn1 z n1 + bxn2 − xn2 z n2
   
6 − c
t
t
z n2 = z n0 +
6 + c
t 6 + c
t
3.1 Numerical algorithms  
xn yn − 4cz n + 4xn yn + xn2 yn2
0 0 1 1 1

The numerical algorithms to solve dynamical systems


in (16) and (17) are outlined as follows Step 7: Now the resulting system of nonlinear equa-
Numerical Algorithm A.1: (Lorenz System) tions after Step 6, which is completely in vari-
Step 1: Initialize the known parameters a, b and c. ables xn2 , yn2 and z n2 , is solved for the numerical
Step 2: Choose a time step size
t and discretize the values of xn2 , yn2 and z n2 by Newton–Raphson
time domain into N time elements. iteration scheme where a double precision, i.e.,
Step 3: Set time-element number n = 1 and run loop 10−16 , is used in the calculations of the numer-
over total number of time elements (below the ical values.
index n in the subscript is representing the nth Step 8: Now, by back substituting the numerical val-
time element). ues of xn2 , yn2 and z n2 from Step 7 in the equa-
Step 4: Set the initial conditions at initial time tn as tions determined in Step 5, the numerical val-
xn0 = x(0), yn0 = y(0), z n0 = z(0). ues of xn1 , yn1 and z n1 are obtained.
Step 5: Determine the symbolic expression for xn1 , yn1 , Step 9: Compute the solution at time step tn by using
z n1 in terms of symbolic variables xn2 , yn2 , z n2 Eq. (5).
from the following equations (derived using Step 10: Update the time-element number n = n +1(or
the first set of equations from Eq. 15). equivalently tn ← tn +
t).
  Step 11: Update the solution for the next time iteration
1 a
t by xn0 = xn−12 , y0 = y2 , z0 = z2 .
xn =
1
− xn0 n n−1 n n−1
2 8 Step 12: If n ≤ N , then go to Step 5.
 
1 a
t a
t  0 
Step 13: Stop when n > N , i.e., the maximum number
+ + xn2 + yn − yn2
2 8 8 of time elements reached.
   
1
t 1
t Numerical Algorithm A.2: (A model with applica-
yn =
1
− yn +
0
+ yn2
2 8 2 8 tions to finance)

t   0  !
+ b xn − xn2 − xn0 z n0 + xn2 z n2 Step 1: Initialize the known parameters a, b and c.
 8  Step 2: Choose a time step size
t and discretize the
1 c
t
zn =
1
− z n0 time domain into N time elements.
2 8 Step 3: Set time-element number n = 1 and run loop
 
1 c
t
t  0 0 
over total number of time elements (below the
+ + z n2 + xn yn − xn2 yn2
2 8 8 index n in the subscript is representing the nth
time element).
Step 6: By using the symbolic expression for xn1 , yn1 Step 4: Set the initial conditions at initial time tn as
and z n1 from Step 5, eliminate the variables xn0 = x(0), yn0 = y(0), z n0 = z(0).

123
M. S. Khan, M. I. Khan

Step 5: Determine the symbolic expression for xn1 , yn1 , Step 8: Now, by back substituting the numerical values
z n1 in terms of symbolic variables xn2 , yn2 , z n2 of xn2 , yn2 and z n2 from Step 7 in the equations
from the following equations (derived using determined in Step 5, the numerical values of
the first set of equations from Eq. 15). xn1 , yn1 and z n1 are obtained.
" # Step 9: Compute the solution at time step tn by using
1
t yn0 − a
xn =
1
+ xn0 Eq. (5).
2 8 Step 10: Update the time-element number n = n + 1
" #
1
t yn2 − a (or equivalently tn ← tn +
t).
+ − xn2 Step 11: Update the solution for the next time iteration
2 8
by xn0 = xn−1 2 , y0 = y2 , z0 = z2 .

t  0  n n−1 n n−1
+ z n − z n2 Step 12: If n ≤ N , then go to Step 5.
 8    Step 13: Stop when n > N , i.e., the maximum number
1 b
t 1 b
t of time elements reached.
yn =
1
− yn0 + + yn2
2 8 2 8

t  2  !
+ xn − xn0 xn2 + xn0
 8    3.2 Numerical results and discussion
1 c
t 1 c
t
zn =
1
− zn +
0
+ z n2
2 8 2 8 In this section, we present numerical investigations

t  2  by applying the proposed numerical algorithms out-
+ xn − xn0 lined in previous section. In particular, we apply these
8
algorithms to compute solutions of two test case prob-
Step 6: By using the symbolic expression for xn1 , yn1 lems where in the first case, parametric values for the
and z n1 from Step 5, eliminate the variables weather prediction model are taken to be a = 10, b =
xn1 , yn1 and z n1 from the following nonlinear 28.0, c = 83 , whereas, in the second case, parameter
equations (derived using the second set of a = 0.9, b = 0.2, c = 1.2 are chosen for observ-
equations from Eq. 15). ing chaotic behavior of finance model. In both the test
⎛  ⎞ cases, a time step size of 5.0 × 10− 4 is selected for

t yn0 − a numerical simulations by aforementioned algorithms
xn2 = ⎝1 + ⎠ xn0
and a step size of 1.0 × 10− 4 is chosen for simula-
6
⎡    !⎤ tions with RK-4 and RK-5 methods. In Table 1, dif-
0 1 1 1

t ⎣ z n + 4 z n + yn − a xn ⎦ ferences between the computed values of solution for
+ weather prediction model by numerical Algorithm A.1
6 +z n2 + yn2 − a xn2
  and by RK-4 and RK-5 are shown. It is observed that
b
t
t the numerical values of solution obtained by Algorithm
yn2 = 1 + yn0 +
6 6 A.1 are in good agreement with the solution by RK-
     2   2 (
2
6− xn0 −4 byn1 + xn1 − byn2 − xn2 4 and RK-5. Since we observe by choosing a larger
  time step size for time discretization the Algorithm
c
t A.1 converging toward the solution by RK-4 and RK-
z n2 = 1 − z n0
6 5 in comparison with a smaller time size, this clearly

t  0   
indicates that the numerical Algorithm A.1 shows bet-
− xn + 4 xn1 + cz n1 + xn2 + cz n2
6 ter accuracy and efficiency than classical RK-4 and
RK-5 methods. In Table 2, the differences between
Step 7: Now the resulting system of nonlinear equa- numerically computed solution for the finance model
tions after Step 6, which is completely in vari- by numerical Algorithm A.2 and by RK-4 and RK-5
ables xn2 ., yn2 and z n2 , is solved for the numerical are shown. It can be seen that the computed solution
values of xn2 , yn2 and z n2 by Newton–Raphson by RK-4, RK-5 and Algorithm A.2 are in strong agree-
iteration scheme where a double precision, i.e., ment. Since in computations a larger time step size for
10−16 , is used in the calculations of the numer- Algorithm A.2 was chosen in comparison with the RK-
ical values. 4 and RK-5, this clearly shows the efficiency and accu-

123
A novel numerical algorithm based on Galerkin–Petrov time-discretization method

Table 1 Comparison of numerically computed solution of the finance model


t |GT D M{0.0005} − R K − 4{0.0001} | |GT D M{0.0005} − R K − 5{0.0001} |
|xVM − xRK−4 | |yVM − yRK−4 | |z VM − z RK−4 | |xVM − xRK−5 | |yVM − yRK−5 | |z VM − z RK−5 |

0.05 0.0 0.0 0.0 0.0 0.0 0.0


1.0 3.99680E−14 7.90002E−14 0.0 3.01981E−14 7.99998E−14 0.0
3.0 9.99201E−16 1.99840E−15 1.9984E−15 9.99201E−16 1.9984E−15 1.9984E−15
5.0 9.99201E−16 0.0 9.99201E−16 0.0 0.0 9.99201E−16
7.0 1.99840E−14 1.99840E−14 1.49880E−14 1.9984E−14 1.9984E−14 1.4988E−14
9.0 1.29896E−14 1.99840E−14 1.40998E−14 1.39888E−14 1.9984E−14 1.40998E−14
11.0 2.70894E−14 0.0 1.29900E−14 2.80886E−14 0.0 1.39888E−14
13.0 5.09592E−14 1.69864E−14 1.19900E−14 5.19584E−14 1.79856E−14 1.29896E−14

Table 2 Comparison of numerically computed solution of the Lorenz system


t |GT D M{0.0005} − R K − 4{0.0001} | |GT D M{0.0005} − R K − 5{0.0001} |
|xVM − xRK−4 | |yVM − yRK−4 | |z VM − z RK−4 | |xVM − xRK−5 | |yVM − yRK−5 | |z VM − z RK−5 |

0.05 3.59996E−11 7.79821E−12 3.09992E−11 3.62004E−11 7.99716E−12 3.07985E−11


1.0 9.83595E−11 7.5857E−11 9.60974E−11 9.92397E−11 7.63769E−11 9.69997E−11
3.0 7.6925E−10 1.282E−09 2.184E−10 7.7404E−10 1.2902E−09 2.19497E−10
5.0 2.23762E−09 3.74495E−09 4.193E−10 2.25248E−09 3.76986E−09 4.22201E−10
7.0 1.00266E−07 1.9713E−07 5.41343E−07 1.00934E−07 1.98443E−07 5.4495E−07
9.0 1.06162E−07 4.71035E−08 3.1944E−07 1.0687E−07 4.74178E−08 3.2157E−07
11.0 3.8875E−07 5.36451E−07 1.92567E−07 3.91342E−07 5.40028E−07 1.93851E−07
13.0 1.922E−06 3.6265E−05 2.9825E−05 1.93481E−06 3.65068E−05 3.00239E−05

Table 3 Numerical comparison between GTDM and PSLM [32] for the Lorenz system
t x(t) y(t) z(t)

GTDM PSLM [32] GTDM PSLM [32] GTDM PSLM [32]

2 − 1.4443587183 − 1.444359 − 1.074977073153 − 1.074977 19.517057379695 19.517057


4 − 14.675080071 − 14.675080 − 20.18910627242 − 20.189107 29.063362821949 29.063361
6 − 2.8830270962 − 2.883028 − 4.763557246761 − 4.763557 20.355566551121 20.355558
8 − 2.6792457270 − 2.679253 1.429467167434 1.429476 27.105635762159 27.105659
10 − 12.026706367 − 12.026645 − 17.5202517158 − 17.520281 24.300412027998 24.300154

racy of the Algorithm A.2 in comparison with RK-4 here in this paper. Since Algorithms A.1 and A.2 are
and RK-5 methods, which are based on finite differ- developed by Galerkin-type approximation of the solu-
ence approach. Our numerical results in Tables 1 and tion, it is assumed that the time domain is divided into a
2 are in accordance with the inherited efficiency and number of finite time elements where in each time ele-
accuracy property of Galerkin finite element approx- ment the corresponding solution of dynamical systems
imation techniques over finite difference approaches. is interpolated using base functions from test space.
This efficiency and accuracy of Algorithms A.1 and A.2 Whereby, contrary to this, RK-4 and RK-5 methods are
is therefore a natural extension and inherited property based on finite difference approximations of dynamical
of the Galerkin finite time-element method presented system equations in (16) and (17).

123
M. S. Khan, M. I. Khan

Table 4 Numerical values of time τ at which the trajectory of the Lorenz system returns to the ε − neighborhood of the initial condition
x(0) = 13.41265629, y(0) = 13.46430003, z(0) = 33.46156416.
[0, τ ] x(τ ) y(τ ) z(τ )

[0, 6.8260] 13.358897850394738 13.464002755923682 33.339476149879438


[0, 6.8270] 13.359519225187706 13.378645246087572 33.429750683715660
[0, 6.8280] 13.359279534634879 13.292175829566359 33.518641110783790
[0, 13.6090] 13.445509277553224 13.466713555045599 33.540075477431330
[0, 19.5320] 13.369524794713751 13.453342908158270 33.366479904188537
[0, 24.8880] 13.810666803632571 13.978465048413877 33.921567493839134
[0, 28.6090] 13.497381062170620 13.499597864014303 33.633867002473110
[0, 84.3210] 13.692202749027736 13.718338525186850 33.888864847627360
[0, 106.3090] 13.364018973083699 13.332858336617569 33.478128543145694
[0, 112.3920] 13.339319316784044 13.284320251087705 33.467704250234213

Table 5 Numerical comparison between GTDM and forward Euler Method (F-EM) [34] for the Lorenz system
t GTDM F-EM [34]


t = 2 × 10−3
t = 8 × 10−6
t = 1 × 10−4
t = 2 × 10−3

x(t)
2 − 1.4443587183 − 1.445082544625001 − 1.451863279117216 − 1.856018921480414
4 − 14.675080071 − 14.70658727604749 − 15.06237829617887 − 9.146042219418225
6 − 2.8830270962 − 2.876562414260005 − 2.545463917873713 − 9.279433262344831
8 − 2.6792457270 − 2.515027338334119 − 2.536644686278581 − 1.886422821481079
y(t)
2 − 1.074977073153 − 1.078303221664098 − 1.123634286775006 − 2.256171562188527
4 − 20.18910627242 − 20.15834677067291 − 19.68028684450857 − 0.934256402379442
6 − 4.763557246761 − 4.775601516104895 − 4.983038404805640 − 14.18315454721178
8 1.429467167434 1.231651937300182 1.024747666236082 − 3.592784453100530
z(t)
2 19.517057379695 19.510239787732331 19.402521688882963 17.60254846675436
4 29.063362821949 29.201789125603991 30.886659575469068 35.77573379613243
6 20.355566551121 20.510873716390236 22.964989102240686 20.16566561613884
8 27.105635762159 26.565009117984363 23.195993249608350 20.52401105121721

Table 3 presents the comparison of numerical results tem in the time interval [0, 6.827] using power series
by the present method GTDM with the piecewise method and showed that the trajectory of the Lorenz
successive linearization method (PSLM) [32] for the system returns to the (ε = 0.13) − neighborhood of
Lorenz system. The initial condition x(0) = 1, y(0) = the initial condition x(0) = 13.41265629, y(0) =
5, z(0) = 10 and the time step size
t = 0.002 are used 13.46430003, z(0) = 33.46156416. We verify this
here to simulate the results in Table 3 for the Lorenz finding by our presented numerical approach GTDM
system. It is found that the numerical solutions com- using Algorithm A.1, and our observations are listed in
puted by Algorithm A.1 using presented GTDM are in Table 4. Hence, algorithm allows to calculate the large
strong agreement with the solution by PSLM at differ- values of time ‘t’ such that the solution point in the
ent time levels. In paper [33, pp. 164, 165], the author trajectory falls in ε-neighborhood of its initial point.
numerically computed the trajectory of the Lorenz sys-

123
A novel numerical algorithm based on Galerkin–Petrov time-discretization method

Table 6 Some periodic solutions of the Lorenz system using GTDM


t
t x(t) y(t) z(t)

0 0.001 − 13.763610682134200 − 19.578751942451795 27.000000000000000


2.3380 13.763511040983688 19.578600831436397 27.000050941057269
4.6760 − 13.763641676099483 − 19.578765577471135 27.000036201330215
2.3380 0.0001 13.763502142059525 19.578600834850871 27.000050941352404
4.6760 − 13.763647759006947 − 19.578745526955135 27.000036235429795
5.4553 13.763498239939076 19.578621362683869 27.000042478193577
7.7933 − 13.763605078786396 − 19.578757711600379 27.000021432424244
8.5726 13.763532459388279 19.578626043025292 27.000039712210397
10.9106 − 13.763602346177409 − 19.578724959140641 27.000012347940393

Fig. 1 Time-history plot of the converged solution by numerical Algorithm A.1

Moreover, these values of t are many in numbers for gives data for three periodic orbits of the Lorenz sys-
the Lorenz system. tem. We choose the first periodic orbit AB with x, y
The comparison of the numerical solution by GTDM and z coordinates of a point on the periodic orbit as
for the Lorenz system with the numerical method F- listed in Table 6 for t = 0. The period T = t − 0
EM in [34] at different time steps and at different of this periodic orbit, which alternates between the
time step sizes is listed in Table 5. It is found that positive and negative wings of the Lorenz system, is
small time steps are required to achieve the accuracy calculated and is listed in Table 6 using the presented
of the numerical solution by F-EM in comparison with numerical approach GTDM. It is found that the val-
the presented numerical approach GTDM. Thus, our ues obtained by GTDM are in strong agreement with
presented numerical approach is much better in com- those obtained by Lindstedt–Poincare technique [35]
parison with F-EM and gives accurate results even and are similar up to four decimal places. The con-
at large time step sizes. Viswanath in his paper [35] verged solution at each nodal value of time elements

123
M. S. Khan, M. I. Khan

Fig. 2 x y-phase portrait of converged solution obtained by numerical Algorithm A.1

Fig. 3 yz-phase portrait of converged solution obtained by numerical Algorithm A.1

123
A novel numerical algorithm based on Galerkin–Petrov time-discretization method

Fig. 4 x z-phase portrait of converged solution obtained by numerical Algorithm A.1

obtain a time-history plot in Fig. 6 for the interest rate,


investment demand and price index. The phase plot of
interest rate versus investment demand is shown in Fig.
7, whereas in Fig. 8 the phase portrait of investment
demand versus price index is seen.
To show convergence and accuracy of above-proposed
GTDM, we consider the following two test problems:
Test problem 1:
Consider the nonlinear dynamical chaotic system [15]
in the x-z reference frame.

ẋ = −εαx ,
Fig. 5 x yz-phase portrait of converged solution obtained by
numerical Algorithm A.1 ż = −εγ z

With the initial conditions x(0) = 33.466, z(0) =


56.0, where, a = 10, α = 4003 , γ = 2α and 0 < ε ≤ 1
by presented method is shown in Fig. 1 for Lorenz are known parameters.
model in (16) computed by the numerical Algorithm The exact
 solution to!above dynamical system is
A.1. In Figs. 2, 3, 4 and 5, x y,yz,x z and x yz-phase −εα t− 3 ln(33.466)
diagrams are shown for the weather prediction model x(t) = e 
400
!
,
where solution is computed by numerical Algorithm −εγ t− 3 ln(56)
z(t) = e 800
.
A.1. A chaotic behavior is observed for the parametric
Test problem 2:
values of a = 10, b = 28.0, c = 83 .
The numerical Algorithm A.2, which is based on Consider once again the same nonlinear dynamical sys-
the discretization of Finance model in (17), is used to tem [15] in y − z reference frame

123
M. S. Khan, M. I. Khan

Fig. 6 Time-history plot of the converged solution by numerical Algorithm A.2

Fig. 7 x y-phase portrait of converged solution obtained by numerical Algorithm A.2

123
A novel numerical algorithm based on Galerkin–Petrov time-discretization method

Fig. 8 yz-phase portrait of converged solution obtained by numerical Algorithm A.2

Table 7 L 2 Norm error, L ∞ error for different step sizes to achieve different accuracy levels

t Test Problem 1 Test Problem 1 Test Problem 2


xExact − xGTDM 2 xExact − xGTDM ∞ z Exact − z GTDM 2 z Exact − z GTDM ∞ yExact − yGTDM 2 yExact − yGTDM ∞

1.0E−03 6.79943E−02 1.82346E−02 3.23279E−01 1.22745E−01 9.48825E−04 2.54455E−04


5.0E−04 2.40117E−02 4.56199E−03 1.13777E−01 3.05128E−02 3.35071E−04 6.36602E−05
4.0E−04 1.71790E−02 2.91890E−03 8.13674E−02 1.95414E−02 2.39724 E−04 4.07318E−05
2.5E−04 8.48697E−03 1.14008E−03 4.01798E−02 7.63377E−03 1.18431E−04 1.59093E−05
1.0E−04 2.14687E−03 1.82395E−04 1.01614E−02 1.22108E−03 2.99585E−05 2.54523E−06

ẏ = εβ(1 + b sin ωt)y, L 2 = X exact − X GTDM 2


)
ż = −εγ z * N
* , ,2
=+ ,Xi − Xi
exact VGTDM
, , and
i=0
with the initial conditions y(0) = −0.467, z(0) = L ∞ = X exact − X GTDM ∞
56.0, where b = 0.01, β = 400 , ,
3 , γ = 2α and 0 < , i ,
ε ≤ 1 are constants. Let us consider this problem in = max ,X exact − X GTDM
i
,.
i
the presence of frequency ω = t −1 sin−1 −2b−1 of
where X GTDM is numerically computed value by the
non-stationary periodic external force term.
Galerkin time discretization method presented in Sec-
The exact solution
 to above system
! in this case
tion II. The convergence and accuracy of the developed
−εβ t− 3 ln(−0.467)
becomes y(t) = e 400
and z(t) as men- method are listed in Table 7 for different time step sizes
tioned before. where both numerical and exact solutions for test prob-
We compute L 2 -norm and L ∞ error by using the lems described above are compared. From above two
following definitions test cases, we observe that our method shows an excel-

123
M. S. Khan, M. I. Khan

lent convergence of the numerical solution to the exact 6. Wang, X., Teng, L., Qin, X.: A novel color image encryption
solution. algorithm based on chaos. Signal Process 92, 1101–1108
(2012)
7. Liu, H.J., Wang, X.Y.: Color image encryption based on one-
time keys and robust chaotic maps. Comput. Math. Appl. 59,
4 Conclusions 3320–3327 (2010)
8. Wang, X.Y., Zhang, Y.Q., Bao, X.M.: A color image encryp-
tion scheme using permutation-substitution based on chaos.
In this article, we study the numerical solution of Entropy 17(6), 3877–3897 (2015)
some chaotic dynamical systems by a novel time- 9. Kikuchi, R., Yano, T., Tsutsumi, A., Yoshida, K., Pun-
discretization approach. We present new algorithms to chochar, M., Drahos, J.: Diagnosis of chaotic dynamics of
numerically simulate two different nonlinear models bubble motion in a bubble column. Chem. Eng. Sci. 52(21–
22), 3741 (1997)
with application to finance and weather forecasting. 10. Letzel, H.M., Schouten, J.C., Krishna, R., van den Bleek,
Numerical results for these systems are presented and C.M.: Characterization of regimes and regime transitions in
discussed for different time step sizes. It is shown that bubble columns by chaos analysis of pressure signals. Chem.
our method has an excellent convergence of solution in Eng. Sci. 52(24), 4447 (1997)
11. Guzmán, A.M., Amon, C.H.: Dynamical flow characteri-
comparison with the RK-4 and RK-5 classical numeri- zation of transitional and chaotic regimes in converging–
cal schemes, since RK-4 and RK-5 require smaller time diverging channels. J. Fluid Mech. 321, 25–57 (1996)
step size to reach the same tolerance in comparison 12. Pine, D.J., Gollub, J.P., Brady, J.F., Leshansky, A.M.: Chaos
with our method with larger time step size. The devel- and threshold for irreversibility in sheared suspension.
Nature 438(7070), 997 (2005)
oped numerical algorithms are simulated for two test 13. Leonov, G.A., Kuznetsov, N.V.: On differences and similar-
problems where exact solution for a nonlinear dynami- ities in the analysis of Lorenz, Chen and Lu systems. Appl.
cal system in two-dimensional space is obtained. An Math. Comput. 256, 334–343 (2015)
excellent agreement is observed between the exact 14. Gao, Q., Ma, J.: Chaos and Hopf bifurcation of a finance
system. Nonlinear Dyn. 58, 209–216 (2009)
and numerical solutions obtained by the derived Algo- 15. Huang, D.: Global dynamics in the periodically-forced-
rithms A.1 and A.2. We conclude that our method has Chen system. Prog. Theor. Phys. 112(5), 785–796 (2004)
a great potential in dealing with the simulations of 16. Eftekhari, S.A., Nejad, F.B., Dowell, E.H.: Bifurcation
chaotic dynamical systems and thus can be utilized to boundary analysis as a nonlinear damage detection feature:
does it work? J. Fluids Struct. 27(2), 297–310 (2011)
predict different features and characteristics of these 17. Ma, R., Ban, X., Pang, J.S., Liu, H.X.: Submission to the
systems. DTA2012 special issue: convergence of time discretiza-
tion schemes for continuous-time dynamic network loading
Acknowledgements The first author is grateful to Higher Edu- models. Netw. Spatial Econ. 15(3), 419–441 (2015)
cation Commission (HEC) of Pakistan for providing financial 18. Song, C., Qiao, Y.: A novel image encryption algorithm
support under the research Grant Numbers 21-557/SRGP/R&D/ based on DNA encoding and spatiotemporal chaos. Entropy
HEC/2014, in order to complete this research work. 17(10), 6954–6968 (2015)
19. Dehghan, M., Shokri, A.: A numerical method for KdV
equation using collocation and radial basis functions. Non-
linear Dyn. 50, 111–120 (2007)
References 20. Wang, C.C.: Application of a hybrid numerical method to the
nonlinear dynamic analysis of a micro gas bearing system.
1. Luo, S., Sun, Q., Cheng, W.: Chaos control of the micro- Nonlinear Dyn. 59, 695–710 (2010)
electro-mechanical resonator by using adaptive dynamic 21. Shakeri, F., Dehghan, M.: Numerical solution of the Klein–
surface technology with extended state observer. AIP Adv. Gordon equation via He’s variational iteration method. Non-
6, 045104 (2016) linear Dyn. 51, 89–97 (2008)
2. Liu, Y., Zhang, J.: Predicting traffic flow in local area net- 22. Wang, X.Y., Lei, Y., Liu, R., Kadir, A.: A chaotic image
works by the largest Lyapunov exponent. Entropy 18(1), 32 encryption algorithm based on perceptron model. Nonlinear
(2016) Dyn. 62, 615–621 (2010)
3. Lim, Y., Han, J., Lam, Y.C.: Chaos analysis of viscoelastic 23. Jamal, M., Braikat, B., Boutmir, S., Damil, N., Potier-Ferry,
chaotic flows of polymeric fluids in a micro-channel. AIP M.: A high order implicit algorithm for solving instation-
Adv. 5, 077150 (2015) ary non-linear problems. Comput. Mech. 28(375–380), 34
4. Baskonus, H.M., Mekkaoui, T., Hammouch, Z., Bulut, H.: (2002)
Active control of a chaotic fractional order economic system. 24. Wang, C.C.: Application of a hybrid numerical method to the
Entropy 17(8), 5771–5783 (2015) nonlinear dynamic analysis of a micro gas bearing system.
5. Wang, Y., Wong, K., Liao, X., Chen, G.: A new chaos-based Nonlinear Dyn. 59, 695–710 (2010)
fast image encryption algorithm. Appl. Soft Comput. 11(1), 25. Sprott, J.C.: Chaos and Time-Series Analysis. Oxford Uni-
514–522 (2011) versity Press, Oxford (2003)

123
A novel numerical algorithm based on Galerkin–Petrov time-discretization method

26. Drahos, J., Tihon, J., Serio, C., Lubbert, A.: Deterministic 32. Motsa, S.S.: A new piecewise-quasilinearization method for
chaos analysis of pressure fluctuations in a horizontal pipe solving chaotic systems of initial value problems. Cent. Eur.
at intermittent flow regime. Chem. Eng. J. Biochem. Eng. J. J. Phys. 10(4), 936–946 (2012)
64(1), 149 (1996) 33. Pchelintsev, A.N.: Numerical and physical modeling of the
27. Wang, S.F., Mosdorf, R., Shoji, M.: Nonlinear analysis on dynamics of the Lorenz system. Numer. Anal. Appl. 7(2),
fluctuation feature of two-phase flow through a T-junction. 159–167 (2014)
Int. J. Heat Mass Transf. 46(9), 1519 (2003) 34. Tamma, K.K., Zhou, X., Sha, D.: The time dimension:
28. Kuzmin, D., ämäläinen, J.H.: Finite Element Methods a theory towards the evolution, classification, characteri-
for Computational Fluid Dynamics. Cambridge University zation and design of computational algorithms for tran-
Press, Cambridge (2015) sient/dynamic applications. Arch. Comput. Methods Eng.
29. Fambri, F., Dumbser, M.: Semi-implicit discontinuous 7(2), 67–290 (2000)
Galerkin methods for the incompressible Navier–Stokes 35. Viswanath, D.: The fractal property of the Lorenz attractor.
equations on adaptive staggered Cartesian grids. Comput. Physica D 190, 115–128 (2004)
Methods Appl. Mech. Eng. 324, 170–203 (2017)
30. Guo, R., Filbet, F., Xu, Y.: Efficient high order semi-implicit
time discretization and local discontinuous Galerkin meth-
ods for highly nonlinear PDEs. J. Sci. Comput. 68(3), 1029–
1054 (2016)
31. Dorodnitsyn, A.V., Bisnovatyi-Kogan, G.S.: Application of
the Galerkin method to the problem of stellar stability. AIP
Conf. Proc. 586, 760 (2001)

123

You might also like