How it Works
This simulation numerically integrates the Lane-Emden equation using a 4th-order Runge-Kutta solver. The polytropic model assumes a simple equation of state P = Kρ^(1+1/n), which allows the four stellar structure equations to be reduced to a single dimensionless ODE.
Starting from the center with θ(0)=1, θ′(0)=0, the solver marches outward in ξ until θ → 0 (the stellar surface). The physical variables (density, pressure, temperature, enclosed mass) are then scaled using the chosen central density and stellar mass.
Frequently Asked Questions
What is the Lane-Emden equation?
The Lane-Emden equation θ″ + (2/ξ)θ′ + θⁿ = 0 describes the density profile of a self-gravitating polytropic gas sphere, where ξ is the dimensionless radius and n is the polytropic index.
What does the polytropic index n represent?
The polytropic index n relates pressure and density via P ∝ ρ^(1+1/n). n=0 is an incompressible star, n=1 approximates neutron stars, n=3 (Eddington's standard model) approximates radiation-pressure dominated massive stars.
What is hydrostatic equilibrium in a star?
Hydrostatic equilibrium means the inward gravitational force exactly balances the outward pressure gradient: dP/dr = -G·M(r)·ρ/r². This condition prevents the star from collapsing or expanding.
How is mass enclosed computed in stellar models?
The mass enclosed within radius r is found by integrating: dM/dr = 4π·r²·ρ(r). For a polytrope this becomes M(ξ) = 4π·ρ_c·r_n³·(-ξ²·θ′) evaluated at each shell.
What is the central density of a polytrope?
The central density ρ_c is a free parameter set by the total mass of the star. The density profile follows ρ(ξ) = ρ_c·θⁿ(ξ), falling to zero at the surface ξ₁ where θ(ξ₁) = 0.
How does luminosity vary inside a star?
Luminosity increases outward as energy is generated by nuclear burning. dL/dr = 4π·r²·ρ·ε where ε is the energy generation rate per unit mass (typically ε ∝ ρT⁴ for the pp-chain).
What determines the temperature gradient inside a star?
In radiative zones: dT/dr = -(3κρ·L)/(64πσT³r²). In convective zones the temperature gradient follows the adiabatic lapse rate. The transition depends on the Schwarzschild stability criterion.
What is the Eddington standard model?
The Eddington standard model uses a polytrope with index n=3, which corresponds to a star where radiation pressure is significant. It correctly predicts mass-luminosity relations for massive main sequence stars.
Why do stars have layered structures?
Different physical processes dominate at different radii: nuclear burning in the core, radiative energy transport in intermediate zones, and convective envelopes at the surface where opacity is high. Each region has distinct density and temperature profiles.
How accurate are polytrope models for real stars?
Polytropes are simplified models. The n=3 polytrope gives a reasonable approximation for the Sun's density profile. Modern stellar models use detailed opacity tables, nuclear reaction networks, and mixing length theory for convection.