# An Energy Conservation Algorithm for Nonlinear Dynamic Equation

Authors: Jian Pang; Yu Du; Ping Hu; Weidong Li; Z. D. Ma
Journal: Journal of Applied Mathematics
 (2012)

---

## Abstract

An energy conservation algorithm for numerically solving nonlinear multidegree-of-freedom (MDOF) dynamic equations is proposed. Firstly, by Taylor expansion and Duhamel integration, an integral iteration formula for numerically solving the nonlinear problems can be achieved. However, this formula still includes a parameter that is to be determined. Secondly, through some mathematical manipulations, the original dynamical equation can be further converted into an energy conservation equation which can then be used to determine the unknown parameter. Finally, an accurate numerical result for the nonlinear problem is achieved by substituting this parameter into the integral iteration formula. Several examples are used to compare the current method with the well-known Runge-Kutta method. They all show that the energy conservation algorithm introduced in this study can eliminate algorithm damping inherent in the Runge-Kutta algorithm and also has better stability for large integral steps.


---

## Body

## 1. Introduction

Numerical stability and algorithmic damping have been long recognized as two important aspects that need to be carefully handled in time integration algorithms for solving dynamic problems. Indeed, many works have been done in this area. For instance, to improve the stability, the Generalized-αmethod of Chung and Hulbert [1], the HHT-αmethod of Hilber et al. [2], and the WBZ-α method of Wood et al. [3] all demonstrate very good dissipation property either at low-frequency or high-frequency ranges. In references [4–8], Fung presents a series of time-step algorithms that are based on different mathematical and mechanical principles and can be used to deal with linear dynamical problems. Recent works on numerical methods have been focusing on modeling long-term qualitative properties and stabilities in the numerical solutions of nonlinear dynamic problems. In the past, the feature of the energy conservation of a system has been widely used in various numerical integration methods to achieve satisfactory results. Since the property of exact energy conservation enables the numerical scheme to be stable without resorting to high-frequency numerical dissipation [9], the feature of the energy conservation appears particularly attractive in numerically solving nonlinear dynamic systems. Consequently, much effort has gone into the development of energy conserving time-stepping schemes. By adding an additional constraint through the energy conservation equation between adjacent time steps, Bui proposed a modified Newmark family for nonlinear dynamic analysis [10]. Similar works are also reported by LaBudde and Greenspan [11], Hughes et al. [12], Greespan [13], Simo and Tarnow [14], Simo et al. [15], Greenspan [16], and Fung and Chow [17]. Interestingly, all works cited above derived their algorithms starting with the finite difference method, and most of them were based on Hamilton’s canonical equations of motion.Though energy conservative methods have showed some advantages, they also might suffer from some drawbacks in practical applications. In an attempt to obtain a stable large-step integration, Simo and Gonzalez [9] used the energy-momentum algorithm, which was obtained from the modification of midpoint scheme. By doing this, they risked to wrongly approximate slowly varying solution quantities in highly oscillatory systems, which was especially significant when fast and low modes are tightly coupled [18]. Moreover, with the addition of the constraint on the energy conservation, one has an overdetermined system that the exact solution has to satisfy. However, once the system is discretized and approximated in order to solve it numerically, the overdetermined system may not have a solution anymore. In other words, difficulties may occur in the multidimensional root finding of the corresponding nonlinear system of equations [19].In this paper, the authors proposed a time integration formula and scheme which can maintain the system energy conservation constraint automatically. However, this method is also different from the energy conservative methods developed previously in the following four aspects. Firstly, the solution of the nonlinear dynamic equation was presented analytically by Duhamel integral in the current method. Secondly, the current method used the Taylor expansion to approximate the exact solution of the nonlinear equation. During this process, an undetermined parameter was introduced. Thirdly, substituting the approximate solution into the analytical solution, an iterative formula with the undetermined parameter was derived. Finally, the energy conservation equation was established and the undetermined parameter was obtained. In practice, how to introduce and obtain the undetermined parameter should be carefully considered case by case, especially when the right hand term of the nonlinear equation includes functions of velocity and time. Another merit of the current algorithm was that it behaved very stable under large time steps. Comparisons with the Rounge-Kutta method showed that the proposed method had much better stabilities in solving different types of nonlinear equations.The remainder of this paper is arranged as follows. In Section2, a detailed process of deriving the integral iteration formula is presented. In the iteration formula, we will show that how an undetermined parameter is introduced into the formula. In Section 3, the energy conservation equation is established for obtaining the algebraic expression of the undetermined parameter. Section 4 focuses on the calculation of the multinomial interpolation used in Section 2. Section 5 shows some representative numerical examples which compare the current method with the popular Runge-Kutta method in terms of algorithmic damping and stability. Finally, some discussions and conclusions are given in Section 6.


## 2. Derivation of the Integral Iteration Formula

Step-by-step time-integration algorithms are commonly used to solve dynamic equations which mostly come from actual engineering problems. By spatial discretization using the finite element method, a nonlinear system may be represented by a second order nonlinear ordinary differential equation as(2.1)Mẍ+Kx=f(x,ẋ,t),
where M,Kare n-by-n constant  mass and stiffness matrices, respectively. x,ẋ,ẍ,f are vectors with rank n representing the displacement, velocity, and acceleration, respectively. t is time. The right hand term in (2.1), f(x,ẋ,t), is the force vector that includes all external forces such as the damping forces and the nonlinear forces. Using the matrix decomposition, the mass matrix M can be expressed as
(2.2)M=L⋅LTM-1=L-T⋅L-1.Substituting (2.2) into (2.1) and multiplying by L-1, we can obtain(2.3)LTẍ+L-1KL-T⋅LTx=L-1f.
Knowing that L,L-1,LT,L-T are all constant matrices, a variable substitution can be executed as(2.4)y=LTx,ẏ=LTx,̇ÿ=LTẍ.
Substituting (2.4) into (2.3), a new dynamic system which is equivalent to the original system can be obtained as(2.5)ÿ+K̅y=F(t),F(t)=L-1f(t),K̅=L-1KL-T.
Let(2.6)K̅=K0+D,
where D is a diagonal matrix and its diagonal elements are the diagonal elements of matrix K̅.K0 is a matrix whose diagonal elements are zero, and other elements are equal to those in K̅. Note that Dii≥0 for M which is a positive definite matrix and K is a semipositive definite matrix. Let(2.7)Dii=di2.
Then (2.5) can be rewritten as(2.8)ÿ+Dy=F(t)-K0y.
The separate form of the above matrix equation can be expressed as follows:(2.9)ÿi+di2yi=Fi(t)-k0iy,i=1,2,…,n,
where k0i is the ith row of the matrix K0. From (2.9), it is easy to see that the analytical solution of the displacement and the velocity can be obtained by the Duhamel integral as(2.10)yi(t)=yi(tk)cos⁡di(t-tk)+ẏi(tk)sin⁡di(t-tk)di+1di∫tktFi(ς)sin⁡di(t-ς)dς-1di∫tktk0iy(ς)sin⁡di(t-ς)dς,(2.11)ẏi(t)=-yi(tk)disin⁡di(t-tk)+ẏi(tk)cos⁡di(t-tk)+∫tktFi(ς)cos⁡di(t-ς)dς-∫tktk0iy(ς)cos⁡di(t-ς)dς.In order to derive the time integral formula, lett=tk+τin (2.10) and (2.11), where τ is the integral time step, then we have(2.12)yi(tk+τ)=yi(tk)cos⁡diτ+ẏi(tk)sin⁡diτdi+1di∫tktk+τFi(ς)sin⁡di(tk+τ-ς)dς-1di∫tktk+τk0iy(ς)sin⁡di(tk+τ-ς)dς,(2.13)ẏi(tk+τ)=-yi(tk)disin⁡diτ+ẏi(tk)cos⁡diτ+∫tktk+τFi(ς)cos⁡di(tk+τ-ς)dς-∫tktk+τk0iy(ς)cos⁡di(tk+τ-ς)dς.Inspecting (2.12) and (2.13), it can be found that there are still some unknown parameters that need to be identified before the time integral formula can be carried out numerically. They are the right hand side terms consisting of the undetermined variables y(t) and Fi(t). The latter one may also be a function of y(t) and ẏ(t). To proceed, the Taylor expansion formula is used to expand y(t) on the interval (tk≤t≤tk+τ) as(2.14)y(t)=y(tk)+(t-tk)ẏ(tk)+(t-tk)22ÿ(tk)+(t-tk)36a.In (2.14), y(t) is expanded to the third order term following exactly the Taylor expansion process, while in calculating the fourth order term, a new variable vector ais introduced. It should be pointed out that although the Taylor expansion is an approximation to the original variable y(t), (2.14) is still an exact expression of the variable y(t). This is because the last term in (2.14) which includes the newly introduced vector a can be interpreted to compensate for the difference between y(t) and the summation of the first three terms in (2.14). In order to express the vector a by the variable y(t), let y1=y(t=tk+τ),y0=y(t=tk). From (2.14), it can be obtained that(2.15)a=6τ3(y1-y0-τẏ0-τ22ÿ0),y(t)=N1(t)y0+N2(t)ẏ0+N3(t)ÿ0+N4(t)y1,
where:(2.16)N1(t)=1-(t-tk)3τ3,N2(t)=t-tk-(t-tk)3τ2,N3(t)=(t-tk)22-(t-tk)32τ,N4(t)=β(t-tk)3(t-tk-τ)+(t-tk)3τ3,
where an undetermined parameter β has been introduced in N4(t) to regulate the stability of the algorithm and will be determined by the energy conservation equation in the next section. By t=tk,t=tk+τ in (2.14), we can obtain(2.17)y(tk)=y0,ẏ(tk)=ẏ0,ÿ(tk)=ÿ0,y(tk+τ)=y1.By means of multinomial interpolation,f(t)(tk≤t≤tk+τ)  can be written as(2.18)f(t)=r0+(t-tk)r1+(t-tk)2r2+(t-tk)3r3+o((t-tk)4).Here we use the third order interpolation, and generally one can choose the order of interpolation discretionarily based on solely the algorithm accuracy order that is needed. Different interpolation order will lead to different integration formulas. Now, we will derive the integration formulas first, and the discussion of the interpolation will be addressed at Section4. Using (2.5) and (2.14), the last two terms of the right hand of (2.11) can be expressed separately as(2.19)1di∫tktk+τk0iy(ς)sin⁡di(tk+τ-ς)dς=α0ik0iy0+α1ik0iẏ0+α2ik0iÿ0+α3ik0iy1,1di∫tktk+τLi-1f(ς)sin⁡di(tk+τ-ς)dς=γ0iLi-1r0+γ1iLi-1r1+γ2iLi-1r2+γ3iLi-1r3,
where αki,γki,k=0,1,2,3 are scalar and can be obtained by follow polynomials(2.20)α0i=-(6sin⁡diτ+di3τ3cos⁡diτ-6diτ)di5τ3,α1i=(6diτ-di2τ2sin⁡diτ-6sin⁡diτ)di5τ2,α2i=(2diτ-3sin⁡diτ+diτcos⁡diτ)di5τ,α3i=(6sin⁡diτ+di3τ3-6diτ)di5τ3-β(di2τ2-4+4cos⁡diτ+diτsin⁡diτ)di6τ4,γ0i=(1-cos⁡diτ)di2,γ1i=(diτ-sin⁡diτ)di3,γ2i=(di2τ2-2+2cos⁡diτ)di4,γ3i=(di3τ3-6diτ+6sin⁡diτ)di5.
Substituting (2.20) into (2.12), we have(2.21)yi(tk+τ)=yi(tk)cos⁡diτ+ẏi(tk)sin⁡diτdi+γ0iLi-1r0+γ1iLi-1r1+γ2iLi-1r2+γ3iLi-1r3-(α0ik0iy0+α1ik0iẏ0+α2ik0iÿ0+α3ik0iy1)(i=1,2,…,n).
Knowing that y1=y(t=tk+τ), so we can write the above equation in a matrix form:(2.22)y1=U0y0+U1ẏ0+γ0L-1r0+γ1L-1r1+γ2L-1r2+γ3L-1r3-α0K0y0-α1K0ẏ0-α2K0ÿ0-α3K0y1,
where U0, U1,αk,γk(k=0,1,2,3) are diagonal matrices and their diagonal elements are cosdiτ, sindiτ/di, αki, γki(i=1,2,…,n,k=0,1,2,3), respectively. From (2.22), the iterative solution y1 can be expressed as(2.23)(I+α3K0)y1=(U0-α0K0)y0+(U1-α1K0)ẏ0-α2K0ÿ0+γ0L-1r0+γ1L-1r1+γ2L-1r2+γ3L-1r3.
Multiplying (2.23) by Lα3-1, we have(2.24)L(α3-1+K0)y1=Lα3-1(U0-α0K0)y0+Lα3-1(U1-α1K0)ẏ0-Lα3-1α2K0ÿ0+Lα3-1γ0L-1r0+γ1L-1r1+γ2L-1r2+γ3L-1r3.Note thatK0 is a matrix whose diagonal elements are zero, and other elements are equal to those in K̅ and αk is a diagonal matrix, so L(α3-1+K0) is a symmetrical matrix. The left hand side of (2.24) can be written as(2.25)L(α3-1+K0)LTL-Ty1=(Lα3-1LT+LK0LT)L-Ty1.
From (2.5) and (2.6), we have(2.26)LK0LT=L⋅(K̅-D)⋅LT=L⋅L-1KL-T⋅LT-LDLT=K-LDLT.
From (2.3) and (2.26), the left hand of (2.24) can be written as(2.27)L(α3-1+K0)y1=[K+L(α3-1-D)LT]⋅x1.
All the terms in the right hand side of (2.24) can be expressed separately as(2.28)Lα3-1(U0-α0K0)y0=[L(α3-1U0+α3-1α0D)LT-Lα3-1α0L-1K]⋅x0,Lα3-1(U1-α1K0)ẏ0=[L(α3-1U1+α3-1α1D)LT-Lα3-1α1L-1K]⋅ẋ0,Lα3-1α2K0ÿ0=Lα3-1α2L-1LK0LTL-Tÿ0=Lα3-1α2L-1(K-LDLT)⋅ẍ0.
After substituting proper variables, the iteration formula in terms of the original variables can be expressed as(2.29)[K+L(α3-1-D)LT]⋅x1=[L(α3-1U0+α3-1α0D)LT-Lα3-1α0L-1K]⋅x0+[L(α3-1U1+α3-1α1D)LT-Lα3-1α1L-1K]⋅ẋ0-Lα3-1α2L-1(K-LDLT)⋅ẍ0+Lα3-1γ0L-1r0+Lα3-1γ1L-1r1+Lα3-1γ2L-1r2+Lα3-1γ3L-1r3.In (2.29), there is a term consisting of a double derivative. According to (2.3), the term with the double derivative ẍ0 can be replaced by -L-TL-1Kx0+L-TL-1f0. Finally, the displacement iteration formula can be obtained as(2.30)[K+L(α3-1-D)LT]⋅x1=L⋅[(α3-1U0+α3-1α0D)LT-α3-1α0L-1K+α3-1α2L-1(K-LDLT)L-TL-1K]⋅x0+L⋅[(α3-1U1+α3-1α1D)LT-α3-1α1L-1K]⋅ẋ0+L⋅[α3-1γ0L-1-α3-1α2L-1(K-LDLT)⋅L-TL-1]r0+Lα3-1γ1L-1r1+Lα3-1γ2L-1r2+Lα3-1γ3L-1r3.Substituting (2.14) and (2.15) into (2.13) and through some mathematical manipulations, the velocity iteration formula can be obtained as(2.31)ẋ1=Rτx1+R0x0+R1ẋ0+L-T[η0L-1-(c2L-1K-c2DLT)L-TL-1]r0+L-Tη1L-1r1+L-Tη2L-1r2+L-Tη3L-1r3,
whereη0, η1, η2, η3 are diagonal matrices with diagonal elements η0i, η1i, η2i, η3i, respectively. cm is also a diagonal matrix and its diagonal elements are cmi(m=0,1,2,3). Every term in the right hand side of (2.31) is given as bellow: (2.32)R0=L-T[(V0LT+c0DLT-c0L-1K)+c2L-1K-c2DLT)L-TL-1⋅K,R1=L-T(V1LT+c1DLT-c1L-1K),Rτ=-L-Tc3(L-1K-DLT),c0i=(di3τ3sin⁡diτ-6cos⁡diτ-3di2τ2+6)di4τ3,c1i=-(di2τ2cos⁡diτ+6cos⁡diτ+2di2τ2-6]di4τ2,c2i=-(1/2)(2diτsin⁡diτ+6cos⁡diτ+di2τ2-6)di4τ,c3i=(6cos⁡diτ+3di2τ2-6)di4τ3-β(6diτcos⁡diτ-24sin⁡diτ-di2τ2+18)di5τ4,η0i=sin⁡diτdiη1i=1-cos⁡diτdi2η2i=2diτ-2sin⁡diτdi3,η3i=∫tktk+τ(ς-tk)3cos⁡di(tk+τ-ς)dς,
where V0, V1 are diagonal matrices with diagonal elements -disindiτ, cosdiτ, respectively.


## 3. Energy Conservation Equation

One reason of expressing the dynamic equation in the form of (2.1) is to establish the energy conservation equation more conveniently and more directly. The following steps illustrate the construction of the energy conservation equation. Multiplying ẋT to both sides of (2.1), we have(3.1)ẋTMẍ+ẋTKx=ẋTf(x,ẋ,t).Integrating (2.32) from tk to tk+1, we can obtain(3.2)∫tktk+1ẋTMẍdt+∫tktk+1ẋTKxdt=∫tktk+1ẋTfdtk=0,1,2,3,…,
namely,(3.3)12ẋTMẋ|tktk+1+12xTKx|tktk+1=∫tktk+1ẋTfdtk=0,1,2,3,….Simplifying (3.3), we can obtain an energy conservation equation between tk and tk+1as follows:(3.4)Tk+1-Tk+Vk+1-Vk=∫tktk+1ẋTfdtk=0,1,2,3,…,
where(3.5)Tk+1=12ẋk+1TMẋk+1,Tk=12ẋkTMẋk,Vk+1=12xk+1TKxk+1,Vk=12xkTKxk.Substituting (2.30) and (2.31) into the left hand side of (3.4), a polynomial of the undermined parameterβcan be easily achieved. For the right hand side of (3.4), the integral term can be firstly decomposed into two parts as follows:(3.6)f1=∫tktk+1ẋTq1(x)dt,f2=∫tktk+1ẋTq2(ẋ,t)dt,
where the term f1 is an integral of an autonomous system and can be integrated easily. The ẋ(t) in term f2 can be expressed as a polynomial of time using the relationship in (2.4) and taking the derivative of (2.15) with respect to time. Two predictive methods are recommended for determining the unknown term y1 in (2.15). One is to let y1=y0+ẏ0τ and the other is to let β=1 in (2.23).Then through (3.5), an algebraic equation with an undetermined parameter β can be established and β can be numerically obtained by the Newton iteration method or other algebraic methods. Finally, substituting β into (2.30) and (2.31), a numerical result can then be achieved.


## 4. Calculations of the Interpolation

Before giving some numerical examples, choosing the proper interpolation form of (2.18) must be discussed because it will affect the accuracy and stability of the proposed algorithm. In the current study, the authors use the Hermite interpolation to approximate the r1,r2,r3,r4 in (2.18), that is,(4.1){r0ir1ir2ir3i}=[1000-1τ01τ0-3τ2-2τ3τ2-1τ2τ31τ2-2τ31τ2]⋅{fi(0,xi(0),ẋi(0))fi′(0,xi(0),ẋi(0))fi(t,xi(τ),ẋi(τ))fi′(t,xi(τ),ẋi(τ))}.It should be noted that there are unknowns in the right hand term of (4.1) which are xi(τ),ẋi(τ). The prediction of the two unknowns is shown below. For example, we can let(4.2)xi(τ)=xi(0)+ẋi(0)⋅τ,ẋi(τ)=ẋi(0)+ẍi(0)⋅τ.Then at every iteration of (3.4), the parameter β can be updated. Submitting β into (2.30) and (2.31), a new prediction of the displacement and velocity can therefore be obtained.


## 5. Numerical Examples

In this section we give some numerical examples to verify the effectiveness of the proposed algorithm, in particular, the advantage in stability of the proposed algorithm. Since (2.14) is a fourth order Taylor expansion, the energy conservation algorithm has fourth order accuracy. So we choose the Rounge-Kutta method as a numerical comparison. The numerical results show the advantages of the proposed energy conservation algorithm in terms of its integration stability and the ability to eliminate the algorithm damping inherent in the Rounge-Kutta method.


### 5.1. The Oscillation of a Nonlinear Simple Pendulum

The dynamic equation of a nonlinear single pendulum without damping can be written as(5.1)ẍ+ω02sin⁡x=0,ω02=1.0,x(0)=1.57,
where x denotes the angular displacement. The numerical solutions are shown in Figure 1. From the figure we can see that the proposed energy conservation method (ECM) can keep the numerical stability and have no computing damping under large-step comparing with the Rounge-Kutta (RK) method. The numerical result of parameter β  is shown in Figure 2. Table 1 gives the comparison of the computing efficiency. The efficiency of the proposed method is not as good as the RK method due to the iteration of parameter β  and the time needed to compute the associated matrices. Figure 3 gives the error analysis between the ECM and the RK under time step 1.0 s.Table 1
Comparison of computing efficiency.
CPUMemoryIntegrationsStepsEnd timeTime elapsedRKIntel core2 2.26G2 G5000000.001 s500 s5.736 sECMIntel core2 2.26G2 G5001.0 s500 s1 m 7.123 sFigure 1
Angular Displacement comparison between the proposed energy conservation method (ECM) and the RK method.Figure 2
Value of parameterβ(time step = 1.0 s).Figure 3
The log-log plot of the error between the ECM and RK.


### 5.2. The Unforced Linear Vibration of the Cuboid Rigid Body with Two DOF

The structural diagram of the system is shown in Figure4. The mass of the rigid body is m and the length of the hemline is a. The center of mass is collocated at the geometry center (point C). The mass moment of inertia around the center of mass is J and the stiffness of the spring is k. The deformations of the two springs are x1,x2. The displacement in vertical direction of the center of mass is xc. The angular displacement of the rigid body about the mass center is ϕ. Using the above parameters, the equation of motion of the system can be written as(5.2)[m4+Ja2m4-Ja2m4-Ja2m4+Ja2]{ẍ1ẍ2}+[k00k]{x1x2}={00}.
Let m=8,a=1,k=2,J=1,x1=1,andx2=-1. Figures 5 and 6 compare the displacement (x1) and velocity (x2-dot) results predicted by the proposed method and the RK method. It can be seen that even with a big time step 1.0 s, the proposed method still has an accurate numerical solution but the RK method does not. Table 2 gives the comparison of the computing efficiency. Again, the efficiency of the proposed method is lower than that of the RK method in calculating these two degrees of freedom problem. Furthermore, it is noticed that the RK method almost keeps the same efficiency in Sections 5.1 and 5.2.Table 2
Comparison of computing efficiency.
CPUMemoryIntegrationsStepsEnd timeTime elapsedRKIntel core2 2.26G2 G5000000.001 s500 s5.849 sECMIntel core2 2.26G2 G5001.0 s500 s1 m 11.741 sFigure 4
Structural diagram of the cuboid rigid body.Figure 5
Comparison of displacement.Figure 6
Comparison of velocity.Figure7 gives the error analysis between the ECM and the RK under time step 1.0 s. As Figure 7 already shows that the accuracy of the ECM is almost same as the result of RK with a 0.001 time step, the comparison does not use the RK with a small time step.Figure 7
The log-log plot of the error between the ECM and RK with time step 1.0 s.


### 5.3. The Unforced Nonlinear Oscillation of a Spring Pendulum with Two DOF

The dynamic equation of the spring pendulum can be written as(5.3)ẍ1+2c1ẋ1+ω12x1-b1x1x2=0,ẍ2+2c2ẋ2+ω22x2-b2x12=0.Figures8 and 9 show the numerical solution under different damping. Parameters and initial condition are given as follows:(5.4)ω1=1.0,ω2=1.5,b1=b2=1.0,x1=x2=0.1,ẋ1=ẋ2=0.0.Figure 8
Displacement trajectory.Figure 9
Velocity trajectory.Figure10 shows the comparison of the numerical results between ECM and RK methods under large time steps. It is obvious that the proposed method can eliminate algorithm damping better and provides better stability than the RK scheme. Parameters and initial conditions used in the calculation are as follows:(5.5)c1=c2=0.0,ω1=1.0,ω2=1.5,b1=b2=1.0,x1=x2=0.1,ẋ1=ẋ2=0.0.Figure 10
Displacement trajectory.Figure11 shows long-time response of (5.2). Parameter and initial condition is as same as (5.4). From this figure we can see that after long-term iteration the proposed method still keeps numerical stability under a relatively large time step. But the algorithm damping makes the RK lose accuracy. Table 3 gives the comparison of the computing efficiency between RK and the ECM algorithms. It is shown that, in solving the two degrees of freedom nonlinear problem, the efficiency of the EMC is lower than the RK method. Moreover, comparing the elapsed time by the ECM in Table 2 and Table 3, it also can be seen that the computation efficiency of the ECM is worse for calculating nonlinear problems than for linear problems. Figure 12 shows the error analysis between the ECM and the RK under time step 1.0 s.Table 3
Comparison of computing efficiency.
CPUMemoryIntegrationsStepsEnd timeTime consumingRKIntel core2 2.26G2 G5000000.001 s500 s6.655 sECMIntel core2 2.26G2 G5001.0 s500 s4 m 18.263 sFigure 11
Displacement trajectory.Figure 12
The log-log plot of the error between the ECM and RK.


## 5.1. The Oscillation of a Nonlinear Simple Pendulum

The dynamic equation of a nonlinear single pendulum without damping can be written as(5.1)ẍ+ω02sin⁡x=0,ω02=1.0,x(0)=1.57,
where x denotes the angular displacement. The numerical solutions are shown in Figure 1. From the figure we can see that the proposed energy conservation method (ECM) can keep the numerical stability and have no computing damping under large-step comparing with the Rounge-Kutta (RK) method. The numerical result of parameter β  is shown in Figure 2. Table 1 gives the comparison of the computing efficiency. The efficiency of the proposed method is not as good as the RK method due to the iteration of parameter β  and the time needed to compute the associated matrices. Figure 3 gives the error analysis between the ECM and the RK under time step 1.0 s.Table 1
Comparison of computing efficiency.
CPUMemoryIntegrationsStepsEnd timeTime elapsedRKIntel core2 2.26G2 G5000000.001 s500 s5.736 sECMIntel core2 2.26G2 G5001.0 s500 s1 m 7.123 sFigure 1
Angular Displacement comparison between the proposed energy conservation method (ECM) and the RK method.Figure 2
Value of parameterβ(time step = 1.0 s).Figure 3
The log-log plot of the error between the ECM and RK.


## 5.2. The Unforced Linear Vibration of the Cuboid Rigid Body with Two DOF

The structural diagram of the system is shown in Figure4. The mass of the rigid body is m and the length of the hemline is a. The center of mass is collocated at the geometry center (point C). The mass moment of inertia around the center of mass is J and the stiffness of the spring is k. The deformations of the two springs are x1,x2. The displacement in vertical direction of the center of mass is xc. The angular displacement of the rigid body about the mass center is ϕ. Using the above parameters, the equation of motion of the system can be written as(5.2)[m4+Ja2m4-Ja2m4-Ja2m4+Ja2]{ẍ1ẍ2}+[k00k]{x1x2}={00}.
Let m=8,a=1,k=2,J=1,x1=1,andx2=-1. Figures 5 and 6 compare the displacement (x1) and velocity (x2-dot) results predicted by the proposed method and the RK method. It can be seen that even with a big time step 1.0 s, the proposed method still has an accurate numerical solution but the RK method does not. Table 2 gives the comparison of the computing efficiency. Again, the efficiency of the proposed method is lower than that of the RK method in calculating these two degrees of freedom problem. Furthermore, it is noticed that the RK method almost keeps the same efficiency in Sections 5.1 and 5.2.Table 2
Comparison of computing efficiency.
CPUMemoryIntegrationsStepsEnd timeTime elapsedRKIntel core2 2.26G2 G5000000.001 s500 s5.849 sECMIntel core2 2.26G2 G5001.0 s500 s1 m 11.741 sFigure 4
Structural diagram of the cuboid rigid body.Figure 5
Comparison of displacement.Figure 6
Comparison of velocity.Figure7 gives the error analysis between the ECM and the RK under time step 1.0 s. As Figure 7 already shows that the accuracy of the ECM is almost same as the result of RK with a 0.001 time step, the comparison does not use the RK with a small time step.Figure 7
The log-log plot of the error between the ECM and RK with time step 1.0 s.


## 5.3. The Unforced Nonlinear Oscillation of a Spring Pendulum with Two DOF

The dynamic equation of the spring pendulum can be written as(5.3)ẍ1+2c1ẋ1+ω12x1-b1x1x2=0,ẍ2+2c2ẋ2+ω22x2-b2x12=0.Figures8 and 9 show the numerical solution under different damping. Parameters and initial condition are given as follows:(5.4)ω1=1.0,ω2=1.5,b1=b2=1.0,x1=x2=0.1,ẋ1=ẋ2=0.0.Figure 8
Displacement trajectory.Figure 9
Velocity trajectory.Figure10 shows the comparison of the numerical results between ECM and RK methods under large time steps. It is obvious that the proposed method can eliminate algorithm damping better and provides better stability than the RK scheme. Parameters and initial conditions used in the calculation are as follows:(5.5)c1=c2=0.0,ω1=1.0,ω2=1.5,b1=b2=1.0,x1=x2=0.1,ẋ1=ẋ2=0.0.Figure 10
Displacement trajectory.Figure11 shows long-time response of (5.2). Parameter and initial condition is as same as (5.4). From this figure we can see that after long-term iteration the proposed method still keeps numerical stability under a relatively large time step. But the algorithm damping makes the RK lose accuracy. Table 3 gives the comparison of the computing efficiency between RK and the ECM algorithms. It is shown that, in solving the two degrees of freedom nonlinear problem, the efficiency of the EMC is lower than the RK method. Moreover, comparing the elapsed time by the ECM in Table 2 and Table 3, it also can be seen that the computation efficiency of the ECM is worse for calculating nonlinear problems than for linear problems. Figure 12 shows the error analysis between the ECM and the RK under time step 1.0 s.Table 3
Comparison of computing efficiency.
CPUMemoryIntegrationsStepsEnd timeTime consumingRKIntel core2 2.26G2 G5000000.001 s500 s6.655 sECMIntel core2 2.26G2 G5001.0 s500 s4 m 18.263 sFigure 11
Displacement trajectory.Figure 12
The log-log plot of the error between the ECM and RK.


## 6. Conclusion

(1) The energy conservation algorithm has the advantage in stability and time step compared with some numerical means because the numerical solution has been corrected by the energy conservation equation.(2) All examples have shown that the energy conservation method can eliminate algorithm damping. It is also an effective means for calculating the long-term characteristics of nonlinear dynamic systems.(3) The proposed method conserves the angular momentum automatically. Although the efficiency of the energy conservation method is not as good as the RK algorithm as well as some other numerical methods discussed in the literature, the integration step is large enough to implement long-term integration with good numerical stability.(4) The reason of the low efficiency of the proposed method is because the iterations need to calculate the parameterβ and the time consumed in matrix computing needed by the algorithm. The efficiency of the EMC is lower in dealing with nonlinear problems compared with linear problems.



---

*Source: 453230-2012-02-09.xml*