Professional Documents
Culture Documents
Math
DOI 10.1007/s40819-015-0128-5
ORIGINAL PAPER
Abstract In this article, a numerical approximation is presented for solving the nonlinear
Lane–Emden type equations. The method is based on cubic B-spline approximations that
leads to a system of nonlinear equations and the unknowns have been obtained by using
the optimization. Truncation error of this method is obtained. Some numerical examples are
presented to demonstrate the validity and applicability of the method.
Introduction
Lane–Emden equations are singular initial value problems relating to second-order ordi-
nary differential equations (ODEs) which have been used to model several phenomena in
mathematical physics and astrophysics such as thermal explosions, stellar structure, the ther-
mal behaviour of a spherical cloud of gas, isothermal gas spheres, and thermionic currents
[1,2]. In astrophysics, the equation which describes the equilibrium density distribution in
self-gravitating sphere of polytropic isothermal gas was proposed by Lane [3] and further
describe by Emden [4] which are known as Lane–Emden equations. Lane–Emden equations
have the following form:
m
y (x) + y (x) + f (x, y) = g(x), 0 < x ≤ 1, m ≥ 0, (1)
x
with supplementary conditions
y(0) = α, y (0) = 0. (2)
B Hossein Aminikhah
hossein.aminikhah@gmail.com; aminikhah@guilan.ac.ir
Somayyeh Kazemi
somayehkazemi8@gmail.com
1 Department of Applied Mathematics, School of Mathematical Sciences, University of Guilan,
P.O. Box 1914, P.C. 41938 Rasht, Iran
123
Int. J. Appl. Comput. Math
Let be a uniform partition of an interval [a, b] as follows a = x 0 < x1 < · · · < xn−1 < xn =
b, where xi : xi = a + i h, i = 0, 1, . . . , n, h = b−an . The cubic B-splines basis functions
are defined as [19]:
⎧
⎪
⎪ (x − xi−2 )3 xi−2 ≤ x < xi−1
⎪
⎪
⎪
⎪
⎪ (x − xi−2 ) − 4(x − xi−1 ) xi−1 ≤ x < xi
3 3
1 ⎨
B3,i (x) = 3 (xi+2 − x) − 4(xi+1 − x)
3 3 xi ≤ x < xi+1 (3)
h ⎪ ⎪
⎪
⎪ (xi+2 − x) 3 xi+1 ≤ x < xi+2
⎪
⎪
⎪
⎩
0 otherwise
where the set {B3,−1 , B3,0 , . . . , B3,n+1 } of cubic B-splines forms a basis over the region
a ≤ x ≤ b. The values of B3,i (x) and its derivatives are tabulated in Table 1.
In order to define Lane–Emden equation at the origin, we use the L’Hôpital rule at the
point x = 0, and we can obtain [20,21]
123
Int. J. Appl. Comput. Math
(m + 1)y (x) + f (x, y(x)) = g(x), f or x = 0,
(4)
y (x) + m
x y (x) + f (x, y(x)) = g(x), f or x = 0.
In this method, the solution of Eq. (1) is approximated by S(x) where is defined as a linear
combination of cubic B-splines basis functions [22], as follows:
n+1
S(x) = Ci B3,i (x) (5)
i=−1
where B3,i (x) are the cubic B-spline functions and Ci are the unknown coefficients. Each
B-spline covers the four elements so that an element is covered by four B-splines. By using
Table 1 the approximate values of S(x) and its two derivatives at the point x = xi can be
determined as follows:
E 1 = S(x0 ) − α,
E 2 = S (x0 ),
E 3 = (m + 1)S (0) + f (0, S(0)) − g(0),
m
E i+3 = S (xi ) + S (xi ) + f (xi , S(xi )) − g(xi ), i = 1, 2, . . . , n.
xi
Now, we wish to minimize the error norm, the L 2 -norm, such that
n+3
L2 = E i2 = 0. (10)
i=1
123
Int. J. Appl. Comput. Math
By solving Eq. (10), we can get the values of Ci for i = −1, 0, . . . , n + 1. Now, with
substituting the values C−1 , C0 , . . . , Cn+1 into Eqs. (6)–(8), the approximate value of S(x)
and its derivatives will ensure.
Truncation Error
In this section, we calculate the truncation error. Attention to Eqs. (6)–(8), we will get the
following relationships [13]
h[S (xi−1 ) + 4S (xi ) + S (xi+1 )] = 3[S(xi+1 ) − S(xi−1 )], (11)
h 2 S (xi ) = 6[S(xi+1 ) − S(xi )] − 2h[2S (xi ) + S (xi+1 )]. (12)
By using Eqs. (11) and (12), we have
h 4 (5)
S (xi ) = y (xi ) − y (xi ) + O(h 6 ), (13)
180
h 2 (4) h 4 (6)
S (xi ) = y (xi ) − y (xi ) + y (xi ) + O(h 6 ). (14)
12 360
Then, truncation error is defined as follows:
m
e(xi ) = g(xi ) − y (xi ) − y (xi ) − f (xi , y(xi ))
xi
m m
= S (xi ) + S (xi ) + f (xi , S(xi )) − y (xi ) − y (xi ) − f (xi , y(xi ))
xi xi
m
= (S (xi ) − y (xi )) + (S (xi ) − y (xi )), i = 1, 2, . . . , n.
xi
Hence,
y (4) (xi ) 2 y (6) (xi ) my (5) (xi )
e(xi ) = − h + − h 4 + O(h 6 ), i = 1, 2, . . . , n (15)
12 360 180xi
Numerical Results
In this section, three examples are studied to demonstrate the accuracy of the present method.
The error between the proposed method and the exact solutions is measured numerically with
the maximum absolute errors (L ∞ -norms) and Euclidean norms (L 2 -norms) for different
123
Int. J. Appl. Comput. Math
values of the step size h and absolute errors in some mesh points are presented. All the
results of these examples are calculated by using MATLAB 2015a. Results obtained by the
method are found to be a good agreement with the exact solution.
123
Int. J. Appl. Comput. Math
The exact solution of this problem is given as y(x) = e−x . Comparison between analytical
2
and numerical results are presented in Table 2. Table 3 shows absolute and norm errors for
different values of h. A plot of absolute errors is displayed in Fig. 1.
Example 2 Consider the following nonlinear Lane–Emden equation
2
y (x) + y (x) + y 5 (x) = 0, 0 < x ≤ 1, (19)
x
subject to the initial conditions
y(0) = 1, y (0) = 0. (20)
123
Int. J. Appl. Comput. Math
2
The exact solution of this problem is given as y(x) = (1+ x3 )−1/2 . In Table 4 a comparison
between exact and numerical results are presented. Absolute and norm errors for different
values of h are presented in Table 5. Absolute error between the numerical and analytical
solution is also depicted in Fig. 2.
123
Int. J. Appl. Comput. Math
123
Int. J. Appl. Comput. Math
Conclusion
The Lane–Emden type equations describe a variety of phenomena in theoretical physics and
astrophysics, including the aspects of stellar structure, the thermal history of a spherical
cloud of gas, isothermal gas spheres, and thermionic currents. The fundamental goal of
this paper has been to construct an approximation to the solution of nonlinear Lane–Emden
equation. We presented a new approach to solve Lane–Emden equations using cubic B-spline
approximations. This method produces a system of nonlinear equations. The unknowns are
obtained by optimization. Three problems have been solved to assess the efficiency and
performance of the method.
Acknowledgments We are very grateful to anonymous referee for their careful reading and valuable com-
ments which led to the improvement of this paper.
References
1. Chandrasekhar, S.: An Introduction to the Study of Stellar Structure. Dover Publications, New York, NY
(1967)
2. Richardson, O.U.: The Emission of Electricity From Hot Bodies. Longmans Green and Company, London
(1921)
3. Lane, J.H.: On the theoretical temperature of the sun under the hypothesis of a gaseous mass maintaining
its volume by its internal heat and depending on the laws of gases known to terrestrial experiment. Am.
J. Sci. Arts 2nd Ser. 50, 57–74 (1870)
4. Emden Gaskugeln, R.: Anwendungen der mechanischen Warmen-theorie auf Kosmologie and meteorol-
ogische Problem, Leipzig, Teubner (1907)
5. Bender, C.M., Milton, K.A., Pinsky, S.S., Simmons Jr, L.M.: A new perturbative approach to nonlinear
problems. J. Math. Phys. 30, 1447–1455 (1989)
6. Mandelzweig, V.B., Tabakin, F.: Quasilinearization approach to nonlinear problems in physics with appli-
cation to nonlinear ODEs. Comput. Phys. Commun. 141, 268–281 (2001)
7. Wazwaz, A.M.: A new algorithm for solving differential equations of Lane–Emden type. Appl. Math.
Comput. 118, 287–310 (2001)
123
Int. J. Appl. Comput. Math
8. Aminikhah, H., Moradian, S.: Numerical solution of singular Lane–Emden equation. ISRN Math. Phys.
Volume 2013, Article ID 507145, 9 pp
9. Liao, S.J.: On the Proposed Homotopy Analysis Technique for Nonlinear Problems and Its Applications.
Ph.D. Dissertation, Shanghai Jio Tong University, Shanghai, China (1992)
10. He, J.H.: An approximation solution technique depending upon an artificial parameter. Commun. Non-
linear Sci. Numer. Simul. 3, 92–97 (1998)
11. Ramos, J.I.: Series approach to the Lane–Emden equation and comparison with the homotopy perturbation
method. Chaos Solitons Fractals 38, 400–408 (2008)
12. Parand, K., Dehghan, M., Rezaeia, A., Ghaderi, S.: An approximation algorithm for the solution of
the nonlinear Lane–Emden type equations arising in astrophysics using Hermite functions collocation
method. Comput. Phys. Commun. 181, 1096–1108 (2010)
13. Kadalbajoo, M.K., Kumar, V.: B-spline method for a class of singular two-point boundary value problems
using optimal grid. Appl. Math. Comput. 188, 1856–1869 (2007)
14. Goh, J., Majid, A.A., Ismail, A.I.M.: A quartic B-spline for second-order singular boundary value prob-
lems. Comput. Math. Appl. 64, 115–120 (2012)
15. Khuri, S.A., Sayfy, A.: A spline collocation approach for a generalized parabolic problem subject to
non-classical conditions. Appl. Math. Comput. 218, 9187–9196 (2012)
16. Mittal, R.C., Jain, R.K.: Numerical solutions of nonlinear Burgers equation with modified cubic B-splines
collocation method. Appl. Math. Comput. 218, 7839–7855 (2012)
17. Aminikhah, H., Alavi, J.: Numerical study of the nonlinear Cauchy diffusion problem and Newell-
Whitehead equation via cubic B-spline quasi-interpolation. Iran. J. Numer. Anal. Optim. 5, 63–72 (2015)
18. Jafari, Hossein, Tajadodi, Haleh, Baleanu, Dumitru: A numerical approach for fractional order Riccati
differential equation using B-spline operational matrix. Fract. Calc. Appl. Anal. 18, 387–399 (2015)
19. Deboor, C.: A Practical Guide to Splines. Springer, Berlin (1978)
20. Caglar, N., Caglar, H.: B-spline solution of singular boundary value problems. Appl. Math. Comput. 182,
1509–1513 (2006)
21. Ravi, A.S.V., Kanth, Y.N.: Reddy, higher order finite difference method for a class of singular boundary
value problems. Appl. Math. Comput. 155, 249–258 (2004)
22. Prenter, P.M.: Splines and Variational Methods. Wiley, Hoboken (1989)
123