Lane-Emden's equation has fundamental importance in the recent analysis of many problems in relativity and astrophysics including some models of density profiles for dark matter halos. An efficient numerical method is presented for linear and nonlinear Lane-Emden-type equations using the Bernstein polynomial operational matrix of integration. The proposed approach is different from other numerical techniques as it is based on the Bernstein polynomial integration matrix. Some illustrative examples are given to demonstrate the efficiency and validity of the proposed algorithm.
1. Introduction
In recent years, the studies of singular initial value problems in some special second-order ordinary differential equations (ODEs) have attracted the attention of many mathematicians and physicists. One of the most intriguing equations is the Lane-Emden-type equations which models many phenomena in mathematical physics and astrophysics. It is a nonlinear ordinary differential equation which describes the equilibrium density distribution in self-gravitating sphere of polytrophic isothermal gas and has a singularity at the origin. This equation has fundamental importance in the field of radiative cooling and modeling of clusters of galaxies. It has also proven to be most versatile in the examination of a variety of situations, including the analysis of isothermal cores, convective stellar interiors, and fully degenerate stellar configurations. Moreover, it has been recently observed [1–3] that the density profiles of dark matter halos are often modeled by the isothermal Lane-Emden equation with suitable boundary conditions at the origin. Since the solution is often given by some numerical approximation, the chosen method would implies some consequences on the physical interpretation of the dark matter evolution. In the following we will give an efficient method for computing its numerical solution.
Lane-Emden’s equations [4, 5] are categorized as nonlinear ordinary differential equations with singular initial values. The more general Cauchy problem in this category is the following equation:y′′(t)+αty′(t)+f(t,y)=g(t),α,t≥0,
with initial conditions (ICs)y(0)=a,y′(0)=0,
where primes denote differentiation with respect to t, α is constant, and f(t,y) is a nonlinear function of t and y.
It has been shown [6] that there exists an analytic solution of (1), (2) in the neighbourhood of the singular point t=0.
In the special case, where α=2, f(t,y)=f(y), g(t)=0 and IC (2) holds, we have one of the most studied casesy′′(t)+2ty′(t)+f(y)=0,t≥0.
For instance, with f(y)=yn and a=1, we gety′′(t)+2ty′(t)+yn=0,t≥0,
which in the form1t2ddt(t2dydt)+yn=0
subject to IC y(0)=1,y′(0)=0
was originally given by Lane [4] and (later) Emden [5].
The parameter n has physical significance only in the range 0≤n≤5. The solution for a given index n is known as polytropic index n. Equation (3) with IC (5) has well-known analytical solutions [7] for n=0,1,5 while, for other values of n, numerical solutions are still sought. The series solution can be found by perturbation techniques and Adomian decomposition methods (ADM). However, these solutions are often convergent in restricted regions. Thus, some techniques such as the Padé method are required to enlarge the convergent regions [8, 9].
Similarly, by choosing f(t,y)=ey and a=0 in (1′) and (2), isothermal gas spheres equation are modeled byy′′(t)+2ty′(t)+ey(t)=0,t≥0,
with IC y(0)=0,y′(0)=0.
A number of methods have recently been proposed to solve (1′), (6). They are quasilinearization methods [10–12], a piecewise linearization technique [13], and the Lagrangian-based analytic solution [14]. The approximate solutions were also given by homotopy analysis method (HAM) [15, 16], variational iteration method [17], and variational approach method [18].
A numerical method based on conversion into integral equations solved by Legendre wavelets is given in [19]. Hybrid functions have also been used in [20] to find the numerical solutions of (1) for some particular nonlinear cases.
In [21] the transform t=ex to (1′) is given to getÿ(x)+ẏ(x)+e2xf(y(x))=0,
subject to the conditionsLimx→-∞y(x)=a,limx→-∞e-xẏ(x)=0,
where dots denote differentiations with respect to x. Then, an approximate solution of (8) is obtained in [0,1] by variational iteration method, for special cases whenf(y)=yn and n=0,1,5.
Legendre’s spectral method for solving only singular IVPs is given in [22]. In [23], modified homotopy analysis methods (MHAMs) enable to obtain approximate solution and to show that MHAM solution contains the previous solutions obtained by ADM and HPM.
A collocation method based on Chebyshev’s polynomials is proposed in [24]. In [25–27], three different methods are presented, to solve (1), based on the Hermite function collocation method, the Lagrangian method, and radial basis function approximation, respectively. The Jacobi-Gauss collocation method is given in [28]. In [29] the optimal homotopy asymptotic method is applied to obtain the analytic solution of singular Lane-Emden-type equation. The perturbation technique and delta-expansion method are presented in [30, 31], respectively.
The aim of the present paper is to apply the Bernstein polynomial operational matrix of integration for the first time, to propose a reliable numerical technique for solving linear and nonlinear Lane-Emden’s equations. Some special cases of the problem are solved to show its validity and efficiency in comparison with other existing numerical methods. The approximate solution, obtained by the proposed method, shows its superiority on the other existing numerical solution.
2. Bernstein’s Polynomials
A Bernstein polynomial [32] is a polynomial in the Bernstein form that is a linear combination of the Bernstein basis polynomials. The Bernstein basis polynomials of degree n are defined byBi,n(t)=(ni)ti(1-t)n-i,fori=0,1,2,…,n.
There are (n+1)nth degree Bernstein basis polynomials forming a basis for the linear space Vn consisting of all polynomials of degree less than or equal to n in R [t]-the ring of polynomials over the field R. For mathematical convenience, we usually set Bi,n=0if i<0 or i>n. Any polynomial B(t) in Vn may be written asB(t)=∑i=0nβiBi,n(t).
Then B(t) is called a polynomial in the Bernstein form or the Bernstein polynomial of degree n. The coefficients βi are called Bernstein’s or Bezier’s coefficients. Often, the Bernstein basis polynomials Bi,n(t) are called the Bernstein polynomials. We will follow this convention as well. A function f∈L2[0,1] may be written asf(t)=limn→∞∑i=0ncinBin(t),
where cin=〈c,Bin〉 and 〈,〉 is the standard inner product on L2[0,1].
If (3) is truncated at n=m′, then we havef≅∑i=0mcimBim=CTΨ(t),
where C and Ψ(t) are (m′+1)×1 matrices given byC=[c0,m′c1,m′⋯cm′,m′]T,Ψ(t)=[B0,m′(t)B1,m′(t)⋯Bm′,m′(t)]T.
For taking the collocation points, let t0 be any point near to zero and other point as follows:ti=t0+im′+1,i>0.
Let us use the notationm=m′+1, for defining the Bernstein operational matrix Φm×m as follows: Φm×m=[B0,m′(t0)B1,m′(t1)⋯Bm′,m′(tm′)]T.
For example, when m=6, the Bernstein operational matrix is expressed asΦm×m=[0.00600.40190.26220.09300.01620.00060.00000.20240.32920.23340.08160.00790.00000.05440.22050.31250.21850.05280.00000.00820.08300.23530.32920.19950.00000.00070.01670.09450.26460.40190.00000.00000.00140.01580.08860.3373].
3. Block Pulse Function and Operational Matrix of Integration
a set of block pulse functions (BPFs) is defined on [0,1) asbi(t)={1,im≤t<i+1m,0,otherwise,wherei=0,1,…,m-1.
The functions bi(t) are disjoint and orthogonal, that is,bi(t)bj(t)={0,i≠j,1,i=j,∫01bi(t)bj(t)dt={0,i≠j,1m,i=j.
The block pulse operational matrix of the integration Fα is defined [33] as following:
(IαBm)(t)≈FαBm(t),
where Iα=∭⋯︷αtimesBm(t)=[b0(t)b1(t)⋯bm-1(t)],Fα=1mα1Γ(α+2)[1ε1ε2⋯εm-101ε1⋯εm-2001⋯εm-3000⋱⋮00001],
with
εk=(k+1)α+12kα+1+(k-1)α+1.
In general the operational matrix of integration of the vector ψm(t) can be obtained as∫0tψm(τ)dτ≈Pm×mψm(t),
where P is the m×m operational matrix for integration.
The Bernstein polynomial can also be expanded and approximated into an m-term block pulse function (BPF) as
ψm(t)=Φm×mBm(t).
Let us consider that the matrix Pm×mα is the Bernstein polynomial operational matrix of the integration, then we have
(Iαψm)(t)≈Pm×mαψm(t).
Now, we have(Iαψm)(t)≈(IαΦm×mBm)(t)=Φm×m(IαBm)(t)≈Φm×mFαBm(t).
From (25) and (18) we getPm×mαψm(t)≈Φm×mFαΦm×m-1ψm(t).
Then, the Bernstein polynomial operational matrix of the integration Pm×mα is given byPm×mα=Φm×mFαΦm×m-1.
4. Outline of the Method
In this section, the method presented in Section 3 is applied to solve the linear and nonlinear Lane-Emden equations. Letting F(t,y)=f(y)=yn(t)witha=1,(1′) can be written asy′′(t)+2ty′(t)+yn(t)=0,withICy(0)=1,y′(0)=0,
where t,n≥0.
Since exact solutions for the case n=0,1,5 are known, we solve them first by the proposed algorithm developed in Section 3.
Let D2y(t)=kmTψm(t),
where kmT is unknown,⟹Dy(t)=kmTPm×m1ψm(t),⟹y(t)=kmTPm×m2ψm(t).
We have y(t)=kmTPm×m2Φm×mBm(t)+1.
Assume kmTPm×m2Φm×m+1=[a1a2⋯am],[y(t)]n=[a1na2n⋯amn]Bm(t).
Substituting (31)–(34) in (30), we getkmTΦm×mBm(t)+2tkmTPm×m1Φm×mBm(t)+[a1na2n⋯amn]Bm(t)=0.
Solution of (35) yields the value of kmT.
5. Numerical Results and Discussions
In this section some special cases of (1′) have been considered to illustrate the efficiency of the method.
5.1. Standard Lane-Emden Equation
Consider the standard Lane-Emden equation:
y′′(t)+2ty′(t)+yn(t)=0,
with initial condition y(0)=1 and y′(0)=0, which has the exact solution for the case n=0, 1, and 5 are known. Equation (36) with the initial conditions has been solved with the proposed method, and obtained results are presented in Figure 1 along with Table 1.
Comparison of the numerical solution and error obtained by present method for n=3 in (36) with series solution [25].
x
Our method
Series method [25]
m=32
m=128
m=256
0.0
0.00E+00
0.00E+00
0.00E+00
0.00E+00
0.1
4.02E-05
2.51E-06
6.28E-07
1.40E-06
0.5
2.89E-05
1.85E-06
4.96E-07
2.99E-06
1.0
4.39E-05
3.79E-05
3.76E-05
1.99E-06
Graph of standard Lane-Emden’s equation and its approximate solution at different values of n=1,1.5,2.5,3,3.5,5 (at m=32) for Section 5.1.
Here we can see that the function basically follows the same form as that for an index n=0, with a few minor differences; however, the polytrope of index n=0 also terminates at a finite radius just as is observed in the relation for a polytrope of index n=1. Though these two solutions for n=1 and n=0 share many characteristics, the solution for the polytrope of index n=5 contains some radically different and unexpected characteristics. In this case the behavior of the function is markedly different than that of its predecessors. Here the density of the star initially decreases rapidly as radius increases but slows rapidly once a t-value of around three is reached. At this point the decrease slows continually. Though it may not be apparent on the graphic provided, the function never reaches 0. It is, therefore, evident that a polytropic star of index n=5 has an infinite radius, and in reality cannot exist.
5.2. Isothermal Gas Spheres Equation
Letting f(t,y)=ey with a=0, (1) can be written asy′′(t)+2ty′(t)+ey=0,
with IC y(0)=0, y′(0)=0. The isothermal gas spheres are modeled in [6]. Equation (38) is solved with the presented method, and the obtained solution is compared with the existing solutions. The plot of proposed and exact solution is given in Figure 2 and comparison has been done in Table 2.
Comparison of the numerical solution and error obtained by present method with series solution [25].
x
Our method
Series method [25]
m=32
m=128
m=256
0.0
0.00E+00
0.00E+00
0.00E+00
0.00E+00
0.1
4.05E-05
2.53E-06
6.32E-07
5.85E-07
0.2
4.00E-05
2.50E-06
6.26E-07
6.04E-07
0.5
3.65E-05
2.28E-06
5.72E-07
5.58E-07
1.0
2.51E-05
7.88E-07
5.07E-07
8.20E-07
Graph of approximate solution in comparison with [9] solution for Section 5.2.
5.3. Nonlinear Homogeneous Lane-Emden Equation
Let f(t,y)=4(2ey+ey/2) with a=0, (1) be written asy′′(t)+2ty′(t)+4(2ey+ey/2)=0,t≥0
with IC y(0)=0 and y′(0)=0, where the exact solution is y(t)=-In(1+t2). We solve the above problem, by applying the technique described in Section 4 with m= 32, 128 and 256 and plotted in Figures 3 and 4, and comparison has been done in Table 3.
Comparison of the numerical solution and error obtained by present method with series solution [25].
x
Present method
Series method [25]
m=32
m=128
m=256
0.0
0.00E+00
0.00E+00
0.00E+00
0.00E+00
0.1
4.66E-04
2.91E-05
7.28E-06
3.94E-06
0.5
1.46E-04
9.16E-06
2.29E-07
3.02E-06
1.0
8.60E-05
3.68E-06
1.28E-08
9.31E-07
Graph of exact solution and approximate solution (at m=32) for Section 5.3.
Absolute error for m=32.
6. Conclusions
The Bernstein polynomial operational matrix of integrations has been applied for solving one of the most popular and intriguing differential equations, that is, the Lane-Emden equations. These results are useful in a few respects and deal with some actual state equation for stars. Though these two solutions for n=1 and n=0 share many characteristics, the solution for the polytrope of index n=5 contains some radically different and unexpected characteristics. In this case the behavior of the function is markedly different than that of its predecessors. Here the density of the star ρ=λyn, where λ represents the central density of the star and y that of a related dimensionless quantity, initially decreases rapidly as radius increases but slows rapidly once a t-value of around three is reached. At this point the decrease slows continually. Though it may not be apparent on the graphic provided, the function never reaches 0. It is, therefore, evident that a polytropic star of index n=5 has an infinite radius and in reality cannot exist. Despite this fact, such a model provides important theoretical perspective concerning the theory, as one may view this as the border between polytropic one that are physically feasible. It is also of interest to note that such a stellar model has, in spite of the infinite radius, a finite mass. Additionally, other stellar models, which are created in a “layered” fashion where each layer consists of a polytrope of a different index, may also utilize this function for a portion of the star, in which case a finite radius would be possible. In addition to these relations, there are also a number of other conclusions that one can draw from the polytropic model of stars. For relations of this type, there exists a relation between the polytropic index, mass of a star, and the radius. It is perhaps evident in the discussion of the analytic solutions of the polytropic index that one could possibly infer a relation between the polytropic index of the star and the radius that one would calculate from that star. In the attempt to find a relation, the most immediate result is obtained from the simple equations of stellar state.
RiaziN.BordbarM. R.Generalized Lane-Emden equation and the structure of galactic dark matter20064534955102-s2.0-3374578309210.1007/s10773-006-9031-5de VegaH. J.SanchezN. G.Model-independent analysis of dark matter points to a particle mass at the keV scale201040428858942-s2.0-7795366574110.1111/j.1365-2966.2010.16319.xMarshG. E.Dark matter and charged exotic dustIn press, http://arxiv.org/abs/1107.0315LaneJ. H.On theoretical temperature of the sun under the hypothesis of a gaseous mass maintaining its internal heat and depending on the laws of gases known to terrestrial experiment1870505774EmdenR.1907Berlin, GermanyTeubnerDavisH. T.1962New York, NY, USADoverChandrasekharS.1967New York, NY, USADoverShawagfehN. T.Nonperturbative approximate solution for Lane-Emden equation1993349436443692-s2.0-21144474137WazwazA. M.A new algorithm for solving differential equations of Lane-Emden type20011182-32873102-s2.0-004092614510.1016/S0096-3003(99)00223-4MandelzweigV. B.TabakinF.Quasilinearization approach to nonlinear problems in physics with application to nonlinear ODEs200114122682812-s2.0-003597650510.1016/S0010-4655(01)00415-5KrivecR.MandelzweigV. B.Numerical investigation of quasilinearization method in quantum mechanics2001138169792-s2.0-003587917010.1016/S0010-4655(01)00191-6KrivecR.MandelzweigV. B.Quasilinearization approach to computations with singular potentials2008179128658672-s2.0-5554912417610.1016/j.cpc.2008.07.006RamosJ. I.Linearization methods in classical and quantum mechanics200315321992082-s2.0-003779937010.1016/S0010-4655(03)00226-1KhaliqueC. M.NtsimeP.Exact solutions of the Lane-Emden-type equation20081374764802-s2.0-4174908396110.1016/j.newast.2008.01.002LiaoS. J.A new analytic algorithm of Lane-Emden type equations200314211162-s2.0-003754277610.1016/S0096-3003(02)00943-8Van GorderR. A.VajraveluK.Analytic and numerical solutions to the Lane-Emden equation200837239606060652-s2.0-5034910335810.1016/j.physleta.2008.08.002YildirimA.ÖzişT.Solutions of singular IVPs of Lane-Emden type by the variational iteration method2009706248024842-s2.0-5904908543610.1016/j.na.2008.03.012HeJ. H.Variational approach to the Lane-Emden equation20031432-35395412-s2.0-003818267910.1016/S0096-3003(02)00382-XYousefiS. A.Legendre wavelets method for solving differential equations of Lane-Emden type20061812141714222-s2.0-3375045478510.1016/j.amc.2006.02.031MarzbanH. R.TabrizidoozH. R.RazzaghiM.Hybrid functions for nonlinear initial-value problems with applications to Lane-Emden type equations200837237588358862-s2.0-4954912448110.1016/j.physleta.2008.07.055DehghanM.ShakeriF.Approximate solution of a differential equation arising in astrophysics using the variational iteration method200813153592-s2.0-3454850902910.1016/j.newast.2007.06.012AdibiH.RismaniA. M.On using a modified Legendre-spectral method for solving singular IVPs of Lane-Emden type2010607212621302-s2.0-7795792271210.1016/j.camwa.2010.07.056SinghO. P.PandeyR. K.SinghV. K.An analytic algorithm of Lane-Emden type equations arising in astrophysics using modified Homotopy analysis method20091807111611242-s2.0-6734916614210.1016/j.cpc.2009.01.012YangC.HouJ.A Numerical Method for Lane-Emden Equations Using Chebyshev Polynomials and the Collocation MethodProceedings of the IEEE International Conference on Computational and Information Sciences201097100ParandK.DehghanM.RezaeiA. R.GhaderiS. M.An approximation algorithm for the solution of the nonlinear Lane-Emden type equations arising in astrophysics using Hermite functions collocation method20101816109611082-s2.0-7795062678710.1016/j.cpc.2010.02.018ParandK.RezaeiA. R.TaghaviA.Lagrangian method for solving LaneEmden type equation arising in astrophysics on semi-infinite domains2010677-86736802-s2.0-7804943245510.1016/j.actaastro.2010.05.015ParandK.k_parand@sbu.ac.irAbbasbandyS.abbasbandy@yahoo.comKazemS.saeedkazem@gmail.comRezaeiA. R.alireza.rz@gmail.comAn improved numerical method for a class of astrophysics problems based on radial basis functions2011831, article 01501110.1088/0031-8949/83/01/015011BhrawyA. H.alibhrawy@yahoo.co.ukAlofiA. S.A Jacobi-Gauss collocation method for solving nonlinear Lane-Emden type equations2012171627010.1016/j.cnsns.2011.04.025IqbalS.shaukat.iqbal.k@gmail.comJavedA.Application of optimal homotopy asymptotic method for the analytic solution of singular Lane-Emden type equation2011217197753776110.1016/j.amc.2011.02.083Van GorderR. A.Exact first integrals for a Lane-Emden equation of the second kind modeling a thermal explosion in a rectangular slab2011109137145Van GorderR. A.An elegant perturbation solution for the Lane-Emden equation of the second kind201116265672-s2.0-7795640473010.1016/j.newast.2010.08.005BernsteinS.Démonstration du théorème de Weierstrass fondée sur le calcul des probabilities19121312KilicmanA.Al ZhourZ. A. A.Kronecker operational matrices for fractional calculus and some applications200718712502652-s2.0-3424733620510.1016/j.amc.2006.08.122