xx TOVola

TOVola

David Boyer <dboyer@uidaho.edu >

October 10, 2024

Abstract

TOVola is a thorn for the Einstien Toolkit that solves the Tolman-Oppenheimer-Volkov (TOV) equations for spherically symmetric static stars using an adaptive ODE method (RK45 or DP78) using GSL’s ODE solver. This TOV solver is compatible with three types of Equations of State (EOS): Simple Polytrope, Piecewise Polytrope, and Tabulated EOS. Examples of using each EOS is included in the par directory. Raw data is solved for, normalized, and set onto the ET grid, and constraint tested via the Baikal thorn.[1]

1 Introduction

TOVola is a thorn developed to handle the TOV equations using multiple different types of EOS and use adaptive methods to solve the system of ODEs. It is specifically developed to solve the TOV equations and adjust and interpolate the TOV data to the ET grid.

TOVola features multiple EOS compatibility, for Simple and Piecewise Polytropes, as well as Tabulated EOS. EOS parameters are stored by the GRHayL library, GRHayLib [2], so make sure you specify for it either your polytropic parameters or your specific table path in your parfile.

2 TOV Equations and Equations of State

Note that this section will not be a derivation of the equations. If more information is desired, see the original TOV papers [3,x4].

The TOV equations are the equations of hydrostatic equilibrium for relativistic stars that are spherically symmetric and static. They are as follows:

where we adopt geometerized units (G=c=1). We followed the form used in nrpytutorial.[5]

I will note that I will be differentiating between total energy density and baryon matter density as and , respectively. is the system’s pressure, is mass, is Schwarzchild radius, is an associated metric function tied to the lapse, and is the isotropic radius.

One must also declare an EOS the relates and :

TOVola has compatibility with three different types of EOS: Simple Polytrope, Piecewise Polytrope, and Tabulated EOS:

Furthermore, and are related by the following equation:

where is the internal energy density.

3 Solving the ODE System

The ODE solver that TOVola uses is the GSL ODE solver. It can solve any ODE system it is given, as long as it is broken into a set of 1st-order ODEs (exactly what the TOV equations are in the first place).

It can handle a variety of ODE methods, as well as adaptive and non-adaptive methods. TOVola only enables the adaptive RK4(5) method (ARKF) and the adaptive DP7(8) method (ADP8). If there is demand, I can enable more methods, but these are the ones that I felt were of the most use.

The integration starts by calculating the initial pressure of the system from a given central baryon density, . Then, using GSL, it steps through the integration. The integration will continue until the termination condition is hit, which was chosen to be the surface of the star. It saves the solution for each step, reallocating memory for the stored solution if the solution gets sufficiently large.

Afterwards, the raw is normalized and conformal factors and lapses are calculated for further use in the toolkit. TOVola then uses an interpolator heavily inspired from the nrpytutorial[5] library to interpolate the adjusted data to the ET grid. From there, the grid functions are saved and, if needed, time levels are populated by copying the data over (as the TOVs are static).

The example parfiles give an example of what you can do with that data from there. In the example parfiles, the initial data is stored with Hydrobase and ADMbase, and the Baikal thorn calculates the constraint violation of the initial data. Gallery examples are also currently in the works that use the thorn GRHydro to evolve the initial data that was calculated by TOVola. In [2], initial data from TOVola is being used for the evolutions of TOV data. Once TOVola creates the initial data, it is up to the user to then decide what they want to use that initial data for.

4 Using TOVola

In this section, I will explain the general use of this thorn.

4.1 Basic Usage

For finding TOV solutions using TOVola, one only needs to set up variables in a parfile. Since most of the EOS information is stored by GRHayL, most of the TOVola parameters are related to the error tolerances for GSL, with the exception of the beta equilibrium temperature Tin and the choice of EOS type TOVolaxEOSxtype. To see examples of how to build a TOV parfile, just look at the examples in the par directory and follow suit.

4.2 Compatible Equations of State As mentioned earlier, TOVola has 3 types of EOS that are compatible: Simple Polytrope, Piecewise Polytrope, and Tabulated EOS.

As GRHayL[2] holds the information on the EOS, you must set its parameters in the parfile as well. Depending on the EOS you are using, you will set different parameters ( and for polytropes, or a betaxequilibriumxtemperature for Tabulated). For more details, please refer to the example parfiles in the par directory. They act as templates of how your parfile should look.

4.2.1 Using a Simple Polytrope

Aside from telling both TOVola and GRHayLib which EOS type you are using, GRHayLib also needs to know the polytropic parameters:

     GRHayLib::Gammaxth

     GRHayLib::Gammaxppolyxin[0]

     GRHayLib::kxppoly0

4.2.2 Using a Piecewise Polytrope

Piecewise Polytrope is practically identical in setting up as the simple polytrope, however, you need to tell GRHayLib the polytropic parameters of each region, as well as how many regions you are using:

     GRHayLib::neos

GRHayLib::Gammaxth
GRHayLib::Gammaxppolyxin[i] for each region
GRHayLib::rhoxppolyxin[i] for each region boundary
GRHayLib::kxppoly0

4.2.3 Using a Tabulated EOS Setting up a Tabulated EOS is going to be rather different than the last two EOS types. GRHayLib needs to know a completely different set of variables than the polytropes. Instead of the polytropic parameters, you need to give GRHayLib information that will help it slice the table you are using. Furthermore, you will need to activate the GRHayLID thorn to impose a beta equilibrium temperature. This will allow for proper table slicing:

TOVola::TOVolaxTin, beta equilibrium temperature, to take the table slice we want GRHayLib::EOSxtablepath, where your table is located.

GRHayLib::Yxexatm
GRHayLib::Yxexmin
GRHayLib::Yxexmax

GRHayLib::Txatm
GRHayLib::Txmin
GRHayLib::Txmax
GRHayLID::imposexbetaxequilibrium = yes
GRHayLID::beqxtemperature

Please note: TOVola does NOT provide the EOS table. You must provide your own table to be able to use the Tabulated feature. HDF5 EOS tables are readily available at ”stellarcollapse.org”.

4.3 Examples Example parfiles can be found in the thorn’s par directory. There is one for each type of EOS:

Simple.par

A Simple Polytrope example, with and

Piecewise.par

A Piecewise Polytrope example, using the Piecewise parameters for and of Read et. al for the SLy EOS.[6] 7 Regions are used in this example.

     Tabulated.par

An Example of using a Tabulated EOS. One must replace the GRHayLib::EOSxtablepath in the parfile to the location of you EOS table. We used an SLy4 table for this specific example.

Baikal was used to test each EOS type and example for any Hamiltonian or momentum constraint violation, so these example parfiles still include constraint violation calculations.

Gallery examples are also being created that evolve the initial data with GRHydro and will be included in the example parfiles once they are acceptable.

5 Acknowledgements

I acknowledge the use of nrpytutorial[5] to generate a base interpolator to put the TOV data on the grid, of which I edited from there. I acknowledge the use of the GRHayL thorn, which was used to store and use EOS specific data in the solution to the TOVs.

References

[1]xxxZ. Etienne. Document in the nrpytutorial github repo: https://nbviewer.jupyter.org/github/zachetienne/nrpytutorial/blob/master/Tutorial-ETKxthorn-BaikalETK.ipynb

[2]xxxS. Cupp, L. Werneck, T. Pierre Jacques, Z. Etienne. Paper In Prep (6/24). Thorn found in the GRHayL directory of the toolkit

[3]xxxR.xC. Tolman, Phys. Rev. 55, 364 (1939).

[4]xxxJ.xR. Oppenheimer and G. Volkoff, Physical Review 55, 374 (1939). [5]xxxZ. Etienne. Github repository: https://github.com/zachetienne/nrpytutorial [6]xxxJ. Read, B. Lackey, B. Owen, and J. Friedman, Phys. Rev. D 79, 124032 (2008).

6 Parameters

11 tovolaxabsolutexmaxxstep 10 Scope: private01 REAL

11 Description: Biggest possible step size.

11 Range 10 01 Default: 1.0
11 (0.0:*  10 Must be positive

11

11 tovolaxabsolutexminxstep  10 Scope: private01  REAL

11 Description: Smallest possible step size

11 Range 10 01 Default: 1.0e-20
11 (0.0:*  10 Must be positive

11

11 tovolaxcentralxbaryonxdensity 10 Scope: private01  REAL

11 Description: What’s the initial baryon density? (Used to calculate initial pressure).

11 Range 10 01 Default: 0.125
11 (0.0:*  10 Must be Positive

11

11 tovolaxeosxtype  10 Scope: private01  KEYWORD

11 Description: What EOS type are you using?

11 Range 10 01 Default: Simple
11 Simple  10 Simple Polytrope
11 Piecewise  10 Piecewise Polytrope
11 Tabulated  10 Tabulated EOS

11

11 tovolaxerrorxlimit  10 Scope: private01  REAL

11 Description: Limiting factor of the error. Determines GSL’s Tolerance.

11 Range 10 01 Default: 1.0e-8
11 (0.0:*  10 Must be Positive

11 tovolaxinitialxodexstepxsize 10 Scope: private01  REAL

11 Description: Initial Step Size

11 Range 10 01 Default: 1.0e-20
11 (0.0:*  10 Must be Positive

11

11 tovolaxinterpolationxstencil 10 Scope: private01  INT

11 Description: Stencil Size for Interpollator to Grid

11 Range 10 01 Default: 11
11 1:*  10 Minimum stencil of 1

11

11 tovolaxmaxxinterpolationxstencil 10 Scope: private01  INT

11 Description: Maximum Interpollator stencil

11 Range 10 01 Default: 13
11 1:*  10 Minimum stencil of 1

11

11 tovolaxodexmethod  10 Scope: private01  KEYWORD

11 Description: What type of ODE method are we using (More Methods can be added if there is demand)

11  Range  10              01  Default: ARKF
11 ARKF  10 ”Adaptive Runge-Kutta-Fehlberg (RK4(5))”
11 ADP8  10 Adaptive Dormand-Prince Eigth Order (DP7(8))

11

11 tovolaxsize  10 Scope: private01  INT

11 Description: Maximum number of steps

11 Range 10 01 Default: 10000000
11 1:*  10 Minimum of 1 step

11

11 tovolaxtin  10 Scope: private01  REAL

11 Description: Beta Equilibrium Temperature

11 Range 10 01 Default: 1.0e-2
11 (0.0:*  10 Must be Positive

11

11 tovolaxtovxpopulatextimelevels10 Scope: private01  INT

11 Description: Populate that amount of timelevels

11 Range 10 01 Default: 1
11 1:3  10 1 (default) to 3

11

11 initialxhydro  10 Scope: shared from HYDROBASE01  KEYWORD

11 Extends ranges:

11 TOVola  10 TOV star initial hydrobase variables

7 Interfaces

General Implements: tovola

Inherits: grhaylib admbase hydrobase grid

8 Schedule This section lists all the variables which are assigned storage by thorn GRHayLET/TOVola. Storage can either last for the duration of the run (Always means that if this thorn is activated storage will be assigned, Conditional means that if this thorn is activated storage will be assigned for the duration of the run if some condition is met), or can be turned on for the duration of a schedule function.

Storage NONE

Scheduled Functions

CCTKxPARAMCHECK x tovolaxparameterxchecker x check if interpollation stencil does not exceed maximum value, and eos type is used appropriately. x

11 x 11 Language: 11 c
11 x 11 Options: 11 global
11 x 11 Type:  11 function

HydroBasexInitial (conditional) x tovolaxtovxgrid x group for the tov initial data x

11 x 11 Sync: 11 admbase::metric
11 x 11 x  11 admbase::curv
11 x 11 x  11 admbase::lapse
11 x 11 x  11 admbase::shift

11 x 11 x  11 rho

11 x 11 x  11 press

11 x 11 x  11 eps
11 x 11 x  11 vel

11 x 11 x  11 wxlorentz
11 x 11 Type: 11 group

11

TOVolaxTOVxGrid (conditional) x tovolaxsolvexandxinterp x performs/drives the tov initial data solution algorithm. calls the integration function for the raw data, normalizes the data to make it more usable, and interpolates to the et grid. x

11 x 11 Language: 11 c
11 x 11 Reads:  11 grid::coordinates
11 x 11 Type:  11 function
11 x 11 Writes: 11 admbase::curv(everywhere)
11 x 11 x  11 admbase::shift(everywhere)
11 x 11 x  11 admbase::alp(everywhere)
11 x 11 x  11 admbase::metricxpxp(everywhere)
11 x 11 x  11 admbase::metricxp(everywhere)
11 x 11 x  11 admbase::metric(everywhere)
11 x 11 x  11 hydrobase::rhoxpxp(everywhere)
11 x 11 x  11 hydrobase::rhoxp(everywhere)
11 x 11 x  11 hydrobase::rho(everywhere)
11 x 11 x  11 hydrobase::pressxpxp(everywhere)
11 x 11 x  11 hydrobase::pressxp(everywhere)
11 x 11 x  11 hydrobase::press(everywhere)
11 x 11 x  11 hydrobase::epsxpxp(everywhere)
11 x 11 x  11 hydrobase::epsxp(everywhere)
11 x 11 x  11 hydrobase::eps(everywhere)
11 x 11 x  11 hydrobase::velxpxp(everywhere)
11 x 11 x  11 hydrobase::velxp(everywhere)
11 x 11 x  11 hydrobase::vel(everywhere)
11 x 11 x  11 hydrobase::wxlorentzxpxp(everywhere)
11 x 11 x  11 hydrobase::wxlorentzxp(everywhere)
11 x 11 x  11 hydrobase::wxlorentz(everywhere)