c Initial central density rho = (DABS(P/C))**(1.d0/lambda) ydot(1) = 4.d0*Pi*r**2*rho c lower bound to zero if ( r .le. 0.d0 ) then phidot = 0.0 else phidot = (m+4.d0*Pi*r**3*P)/(r*(r-2.d0*m)) endif ydot(2) = -(P+rho)*phidotAt every step we calculate a new radius
The usage of the program is the following:
usage: star <rho_0> <C> <lambda> <dr> c================================================================ c Command line info c c <rho_0> central density of the compact object c c <C> Constant in the equation of state c c <lambda> exponent of the density in the equation of state. c c <dr> integration step increment in radius. c================================================================As a suggestion from the instructor it delivers the logarithm in base
To perform the survey of the phase space we need the values of mass and radius at different central densities. With this objetive we wrote a code denominated survey.f that uses star.f as a subroutine, integra.f.
lnx1 111> ./survey Phys 555 Numerical Relativity Group 2 usage: survey <rhomax> <deltarho> <C> <lambda> <dr> <tol> c=========================================================== c Physics 555b Numerical Relativity Group 2 c c survey.f c This program goes thru different values of the c central density so we can plot M vs rho0, and radius c vs rho0. The integration of the equations is carried c out by the subroutine integra. c April-March 2205 c c Command line info c c <rho_0_up> for the upper limit of the central density c c <deltarho> for the setp increment in rho_0 c c <C> Constant in the Polytropic equation of state c c <lambda> exponent of rho in equation of state c c <dr> integration step increment of radius c===========================================================