bnsfuka Derived Type

type, public, extends(bnsbase) :: bnsfuka

TYPE representing a binary system of neutron stars (\(\mathrm{BNS}\)) produced with \(\texttt{FUKA}\)


Inherits

type~~bnsfuka~~InheritsGraph type~bnsfuka bnsfuka C_PTR C_PTR type~bnsfuka->C_PTR bns_ptr grid_function_scalar grid_function_scalar type~bnsfuka->grid_function_scalar mass_density, pressure, specific_energy, v_euler_x, v_euler_y, v_euler_z type~bnsbase bnsbase type~bnsfuka->type~bnsbase type~id_lattice id_lattice type~bnsfuka->type~id_lattice star_lattice type~idbase idbase type~bnsbase->type~idbase timer timer type~idbase->timer construction_timer type~surface surface type~idbase->type~surface surfaces type~tabu_eos tabu_eos type~idbase->type~tabu_eos tab_eos

Contents

allocate_bnsfuka_memory check_i_matter construct_binary deallocate_bnsfuka_memory derived_type_constructor destruct_binary estimate_lengthscale_field finalize find_center find_print_surfaces find_radius find_surface get_adm_mass get_angular_momentum get_angular_vel get_barycenter1_x get_barycenter2_x get_bns_identifier get_center1_x get_center2_x get_cold_system get_distance get_distance_com get_energy_density_center1 get_energy_density_center2 get_ent_center1 get_ent_center2 get_eos1 get_eos1_fukaid get_eos1_id get_eos2 get_eos2_fukaid get_eos2_id get_eos_id get_estimate_length_scale get_fa get_field get_fv get_gamma0_1 get_gamma0_2 get_gamma1_1 get_gamma1_2 get_gamma2_1 get_gamma2_2 get_gamma3_1 get_gamma3_2 get_gamma_1 get_gamma_2 get_grav_mass1 get_grav_mass2 get_kappa0_1 get_kappa0_2 get_kappa1_1 get_kappa1_2 get_kappa2_1 get_kappa2_2 get_kappa3_1 get_kappa3_2 get_kappa_1 get_kappa_2 get_linear_momentum get_logP1_1 get_logP1_2 get_logRho0_1 get_logRho0_2 get_logRho1_1 get_logRho1_2 get_logRho2_1 get_logRho2_2 get_mass1 get_mass2 get_n_matter get_nbar_center1 get_nbar_center2 get_npeos_1 get_npeos_2 get_one_lapse get_pressure_center1 get_pressure_center2 get_radius1_x_comp get_radius1_x_opp get_radius1_y get_radius1_z get_radius2_x_comp get_radius2_x_opp get_radius2_y get_radius2_z get_rho_center1 get_rho_center2 get_specific_energy_center1 get_specific_energy_center2 get_total_spatial_extent get_zero_shift initialize initialize_id integrate_baryon_mass_density interpolate_fuka_spatial_metric is_hydro_positive print_bns_properties print_summary print_summary_derived read_bns_properties read_fuka_id_mass_b read_fuka_id_member read_fuka_id_particles read_fuka_mass_density read_fuka_pressure read_fuka_spatial_metric read_id_full read_id_hydro read_id_k read_id_mass_b read_id_particles read_id_spacetime read_mass_density read_pressure return_adm_mass return_barycenter return_center return_eos_name return_eos_parameters return_mass return_spatial_extent run_kadath_reader sanity_check set_cold_system set_estimate_length_scale set_n_matter set_one_lapse set_up_lattices_around_stars set_zero_shift test_position

Source Code


Components

Type Visibility Attributes Name Initial
double precision, public :: adm_mass

ADM mass of the system

double precision, public :: angular_momentum_x = 0.0D0

component of the angular momentum of the BNS system

double precision, public :: angular_momentum_y = 0.0D0

component of the angular momentum of the BNS system

double precision, public :: angular_momentum_z = 0.0D0

component of the angular momentum of the BNS system

double precision, public :: angular_vel

Angular velocity

double precision, public :: area_radius1

Areal (or circumferential) radius of star 1 Note that these is the areal radius of the star in the binary system, which is different than that of an isolated star. The latter is used in the mass-radius diagrams, together with the gravitatonal mass

double precision, public :: area_radius2

Areal (or circumferential) radius of star 2 Note that these is the areal radius of the star in the binary system, which is different than that of an isolated star. The latter is used in the mass-radius diagrams, together with the gravitatonal mass

double precision, public, DIMENSION(2,3) :: barycenter

Array containing the barycenters of the stars

double precision, public :: barycenter1_x

Barycenter of star 1

double precision, public :: barycenter2_x

Barycenter of star 2

double precision, public, DIMENSION(3) :: barycenter_system

Array containing the barycenters of the stars

integer, private :: bns_identifier = 0

Identifier of the bnsfuka object

type(C_PTR), private :: bns_ptr

C pointer to the \(\texttt{FUKA}\)'s object storing the \(\mathrm{BNS}\) \id| N.B. This variable is global. The pointer to the second \(\texttt{FUKA}\) \(\texttt{Bin_NS}\) object will overwrite the first one, and so on. This variable stores the pointer to the last defined \(\texttt{FUKA}\) \(\texttt{Bin_NS}\) object. That's why it is not freed in the destructor of a bns object. Presently, it has to be freed by the user at the end of the PROGRAM. See the last part of the PROGRAM in sphincs_id.f90, for example.

double precision, public, DIMENSION(2,3) :: center

Array containing the centers of the stars

double precision, public :: center1_x

Stellar center of star 1 (origin of the LORENE chart centered on star 1)

double precision, public :: center2_x

Stellar center of star 2 (origin of the LORENE chart centered on star 2)

type(timer), public :: construction_timer

Timer that times the construction of the appropriate object

double precision, public :: distance

Distance between the points of maximum baryon density

double precision, public :: distance_com

Distance between the centers of mass

double precision, public :: energy_density_center1

Central energy density for star 1

double precision, public :: energy_density_center2

Central energy density for star 2

double precision, public :: ent_center1

Central enthalpy for star 1

double precision, public :: ent_center2

Central enthalpy for star 2

character(len=:), public, ALLOCATABLE :: eos1

Name of the equation of state (\(\mathrm{EOS}\)) of star 1

integer, private :: eos1_fukaid

\(\texttt{FUKA}\) identifier for the \(\mathrm{EOS}\) of star 1

integer, public :: eos1_id

\(\texttt{SPHINCS_ID}\) identifier for the \(\mathrm{EOS}\) of star 1

character(len=:), public, ALLOCATABLE :: eos2

Name of the equation of state (\(\mathrm{EOS}\)) of star 2

integer, private :: eos2_fukaid

\(\texttt{FUKA}\) identifier for the \(\mathrm{EOS}\) of star 2

integer, public :: eos2_id

\(\texttt{SPHINCS_ID}\) identifier for the \(\mathrm{EOS}\) of star 2

character(len=:), private, ALLOCATABLE :: eos_file_1

String containing the name of the \(\mathrm{EOS}\) file used by \(\texttt{FUKA}\) of star 1

character(len=:), private, ALLOCATABLE :: eos_file_2

String containing the name of the \(\mathrm{EOS}\) file used by \(\texttt{FUKA}\) of star 2

character(len=max_length), public, DIMENSION(2) :: eos_filenames

Array of strings containing the names of the files containing the \(\mathrm{EOS}\) to be used for each matter object.

character(len=:), public, ALLOCATABLE :: eos_table1

String containing the path to the files containing the table of the \(\mathrm{EOS}\) for star 1.

character(len=:), public, ALLOCATABLE :: eos_table2

String containing the path to the files containing the table of the \(\mathrm{EOS}\) for star 2.

character(len=:), private, ALLOCATABLE :: eos_type_1

String containing the type of the \(\mathrm{EOS}\) of star 1

character(len=:), private, ALLOCATABLE :: eos_type_2

String containing the type of the \(\mathrm{EOS}\) of star 2

character(len=:), private, ALLOCATABLE :: filename

String containing the name of the '.info' \(\mathrm{ID}\) file output by \(\texttt{FUKA}\)

procedure, public, POINTER, NOPASS :: finalize_sph_id_ptr

Pointer to a procedure that finalize the \(\mathrm{SPH}\) \(\mathrm{ID}\); for example, correct for the residual ADM linear momentum.

double precision, public, DIMENSION(:), ALLOCATABLE :: g_xx

1-D array storing the xx component of the spatial metric [pure number]

double precision, public, DIMENSION(:), ALLOCATABLE :: g_xy

1-D array storing the xy component of the spatial metric [pure number]

double precision, public, DIMENSION(:), ALLOCATABLE :: g_xz

1-D array storing the xz component of the spatial metric [pure number]

double precision, public, DIMENSION(:), ALLOCATABLE :: g_yy

1-D array storing the yy component of the spatial metric [pure number]

double precision, public, DIMENSION(:), ALLOCATABLE :: g_yz

1-D array storing the yz component of the spatial metric [pure number]

double precision, public, DIMENSION(:), ALLOCATABLE :: g_zz

1-D array storing the zz component of the spatial metric [pure number]

double precision, public :: gamma0_1

Piecewise polytrope: polytropic index for star 1

double precision, public :: gamma0_2

Piecewise polytrope: polytropic index for star 2

double precision, public :: gamma1_1

Piecewise polytrope: polytropic index for star 1

double precision, public :: gamma1_2

Piecewise polytrope: polytropic index for star 2

double precision, public :: gamma2_1

Piecewise polytrope: polytropic index for star 1

double precision, public :: gamma2_2

Piecewise polytrope: polytropic index for star 2

double precision, public :: gamma3_1

Piecewise polytrope: polytropic index for star 1

double precision, public :: gamma3_2

Piecewise polytrope: polytropic index for star 2

double precision, public :: gamma_1

Single polytrope: polytropic index for star 1

double precision, public :: gamma_2

Single polytrope: polytropic index for star 2

double precision, public, DIMENSION(:), ALLOCATABLE :: k_xx

1-D array storing the xx component of the extrinsic curvature [c/MSun_geo]

double precision, public, DIMENSION(:), ALLOCATABLE :: k_xy

1-D array storing the xy component of the extrinsic curvature [c/MSun_geo]

double precision, public, DIMENSION(:), ALLOCATABLE :: k_xz

1-D array storing the xz component of the extrinsic curvature [c/MSun_geo]

double precision, public, DIMENSION(:), ALLOCATABLE :: k_yy

1-D array storing the yy component of the extrinsic curvature [c/MSun_geo]

double precision, public, DIMENSION(:), ALLOCATABLE :: k_yz

1-D array storing the yz component of the extrinsic curvature [c/MSun_geo]

double precision, public, DIMENSION(:), ALLOCATABLE :: k_zz

1-D array storing the zz component of the extrinsic curvature [c/MSun_geo]

double precision, public :: kappa0_1

Piecewise polytrope: polytropic constant for star 1 [pure number]

double precision, public :: kappa0_2

Piecewise polytrope: polytropic constant for star 2 [pure number]

double precision, public :: kappa1_1

Piecewise polytrope: polytropic constant for star 1 [pure number]

double precision, public :: kappa1_2

Piecewise polytrope: polytropic constant for star 2 [pure number]

double precision, public :: kappa2_1

Piecewise polytrope: polytropic constant for star 1 [pure number]

double precision, public :: kappa2_2

Piecewise polytrope: polytropic constant for star 2 [pure number]

double precision, public :: kappa3_1

Piecewise polytrope: polytropic constant for star 1 [pure number]

double precision, public :: kappa3_2

Piecewise polytrope: polytropic constant for star 2 [pure number]

double precision, public :: kappa_1

Single polytrope: polytropic constant for star 1 [pure number]

double precision, public :: kappa_2

Single polytrope: polytropic constant for star 2 [pure number]

double precision, private :: komar_mass

Komar mass of the binary system

integer, public :: l_curr

Variable set to the current refinement level to consider, when reading the hydro \(\mathrm{ID}\) on the refined mesh in computing the constraints

double precision, public, DIMENSION(:), ALLOCATABLE :: lapse

1-D array storing the lapse function

double precision, public :: linear_momentum_x = 0.0D0

component of the ADM linear momentum of the system

double precision, public :: linear_momentum_y = 0.0D0

component of the ADM linear momentum of the system

double precision, public :: linear_momentum_z = 0.0D0

component of the ADM linear momentum of the system

double precision, public :: logP1_1

Piecewise polytrope: Base 10 exponent of the pressure at the first fiducial density (between and ) for star 1

double precision, public :: logP1_2

Piecewise polytrope: Base 10 exponent of the pressure at the first fiducial density (between and ) for star 2

double precision, public :: logRho0_1

Piecewise polytrope: Base 10 exponent of the first fiducial density (between and ) for star 1

double precision, public :: logRho0_2

Piecewise polytrope: Base 10 exponent of the second fiducial density (between and ) for star 2

double precision, public :: logRho1_1

Piecewise polytrope: Base 10 exponent of the second fiducial density (between and ) for star 1

double precision, public :: logRho1_2

Piecewise polytrope: Base 10 exponent of the second fiducial density (between and ) for star 2

double precision, public :: logRho2_1

Piecewise polytrope: Base 10 exponent of the third fiducial density (between and ) for star 1

double precision, public :: logRho2_2

Piecewise polytrope: Base 10 exponent of the third fiducial density (between and ) for star 2

double precision, public :: mOmega

mOmega= ( angular_vel ) ( mass_grav1 + mass_grav2 ) [pure number]

Constant used in K. Hotokezaka et al, Phys. Rev. D 87, 024001 (see Sec. IIB) to determine when the BNS is at approximately 3-4 quasicircular orbits from merger. For the EOS APR4 and ALF2, this requirement is approximately satisfied for mOmega ; for the EOS H4 and MS1, for mOmega .

double precision, public, DIMENSION(2) :: mass

Array containing the baryonic masses

double precision, public :: mass1

Baryonic mass of star 1

double precision, public :: mass2

Baryonic mass of star 2

type(grid_function_scalar), public, DIMENSION(max$tpo) :: mass_density

1-D array storing the baryon mass density in the fluid frame

double precision, public, DIMENSION(2) :: mass_grav

Array containing the gravitational masses

double precision, public :: mass_grav1

Gravitational mass of star 1

double precision, public :: mass_grav2

Gravitational mass of star 2

double precision, public :: nbar_center1

Central baryon number density for star 1

double precision, public :: nbar_center2

Central baryon number density for star 2

integer, public :: npeos_1

Piecewise polytrope: Number of polytropic pieces for star 1

integer, public :: npeos_2

Piecewise polytrope: Number of polytropic pieces for star 2

integer, private :: nx_lattice = 400

Number of points for each lattice around the stars, along the axis

integer, private :: ny_lattice = 400

Number of points for each lattice around the stars, along the axis

integer, private :: nz_lattice = 400

Number of points for each lattice around the stars, along the axis

type(grid_function_scalar), public, DIMENSION(max$tpo) :: pressure

1-D array storing the pressure

double precision, public :: pressure_center1

Central pressure for star 1

double precision, public :: pressure_center2

Central pressure for star 2

double precision, public, DIMENSION(2,6) :: radii

Array containing the signed radii of the stars

double precision, public :: radius1_x_comp

Radius of star 1, in the x direction, towards the companion

double precision, public :: radius1_x_opp

Radius of star 1, in the x direction, opposite to companion

double precision, public :: radius1_y

Radius of star 1, in the y direction

double precision, public :: radius1_z

Radius of star 1, in the z direction

double precision, public :: radius2_x_comp

Radius of star 2, in the x direction, towards the companion

double precision, public :: radius2_x_opp

Radius of star 2, in the x direction, opposite to companion

double precision, public :: radius2_y

Radius of star 2, in the y direction

double precision, public :: radius2_z

Radius of star 2, in the z direction

double precision, public :: rho_center1

Central baryon mass density for star 1

double precision, public :: rho_center2

Central baryon mass density for star 2

double precision, public, DIMENSION(:), ALLOCATABLE :: shift_x

1-D array storing the x component of the shift vector [c]

double precision, public, DIMENSION(:), ALLOCATABLE :: shift_y

1-D array storing the y component of the shift vector [c]

double precision, public, DIMENSION(:), ALLOCATABLE :: shift_z

1-D array storing the z component of the shift vector [c]

type(grid_function_scalar), public, DIMENSION(max$tpo) :: specific_energy

1-D array storing the specific internal energy

double precision, public :: specific_energy_center1

Central specific energy for star 1

double precision, public :: specific_energy_center2

Central specific energy for star 2

type(id_lattice), private, DIMENSION(2) :: star_lattice

Array storing two id_lattice objects, one per star

type(surface), public, DIMENSION(:), ALLOCATABLE :: surfaces

Array containing, for each matter object, a set of coordinates of some points modelling the surfaces.

double precision, public :: t_merger

Estimated time of the merger P. C. Peters, "Gravitational Radiation and the Motion of Two Point Masses", Phys. Rev. 136, B1224 (1964)

type(tabu_eos), public, DIMENSION(:), ALLOCATABLE :: tab_eos

Array containing a tabulated \(\mathrm{EOS}\) for each matter object, when used.

integer, private, DIMENSION(max$tpo) :: tpo$log = 0

Variable that stores the identifiers for the tpo objects constructed using this bnsfuka object

integer, public :: tpo_curr = 0

Variable set to the current tpo object to consider, when reading the hydro \(\mathrm{ID}\) on the refined mesh in computing the constraints

type(grid_function_scalar), public, DIMENSION(max$tpo) :: v_euler_x

1-D array storing the x component of the fluid 3-velocity with respect to the Eulerian observer [c]

type(grid_function_scalar), public, DIMENSION(max$tpo) :: v_euler_y

1-D array storing the y component of the fluid 3-velocity with respect to the Eulerian observer [c]

type(grid_function_scalar), public, DIMENSION(max$tpo) :: v_euler_z

1-D array storing the z component of the fluid 3-velocity with respect to the Eulerian observer [c]


Finalization Procedures

final :: destruct_bnsfuka

Finalizer (Destructor) of a bnsfuka object


Type-Bound Procedures

procedure, public :: allocate_bnsfuka_memory

Allocates memory for the bnsfuka member arrays

Allocates memory for the bnsfuka member 3D arrays storing the hydro fields

  • interface

    public module subroutine allocate_bnsfuka_memory(this, d)

    Allocates allocatable arrays member of a bnsfuka object

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: d

    Dimension of the arrays

procedure, public, NON_OVERRIDABLE :: check_i_matter

Checks that the given index is between 1 and n_matter, included. If not, it stops the execution of the program.

  • interface

    public module subroutine check_i_matter(this, i_matter)

    Checks that the given index i_matter is between 1 and n_matter, included. If not, it stops the execution of the program.

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: this
    integer, intent(in) :: i_matter

    Value to be checked

procedure, public :: construct_binary

Constructs the \(\texttt{FUKA}\) bns_export object

  • interface

    public module subroutine construct_binary(this, fukafile)

    Interface of the subroutine that constructs the \(\texttt{FUKA}\) \(\texttt{Bin_NS}\) object

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    character(kind=C_CHAR, len=*), intent(in), optional :: fukafile

    \(\texttt{FUKA}\) binary file containing the spectral \(\mathrm{BNS}\) \(\mathrm{ID}\)

procedure, public :: deallocate_bnsfuka_memory

Deallocates memory for the bnsfuka member arrays

  • interface

    public module subroutine deallocate_bnsfuka_memory(this)

    Deallocates allocatable arrays member of a bnsfuka object

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

procedure, public :: derived_type_constructor => construct_bnsfuka

  • interface

    public module subroutine construct_bnsfuka(derived_type, filename, eos_filenames)

    Prints a summary of the physical properties the system to the standard output and, optionally, to a formatted file whose name is given as the optional argument filename

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(out) :: derived_type

    Constructed bnsfuka object

    character(len=*), intent(in), optional :: filename

    \(\texttt{FUKA}\) binary file containing the spectral \(\mathrm{BNS}\) \(\mathrm{ID}\)

    character(len=*), intent(in), optional, DIMENSION(:) :: eos_filenames

    Array of strings containing the names of the files containing the \(\mathrm{EOS}\) to be used for each matter object. If not PRESENT, information from the file filename is used

procedure, public :: destruct_binary

Destructs the \(\texttt{FUKA}\) bns_export object

  • interface

    public module subroutine destruct_binary(this)

    Destructs a \(\texttt{FUKA}\) \(\texttt{Bin_NS}\) object

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

procedure, public :: estimate_lengthscale_field

Estimate typical length scales, one per each matter object, by computing , where is a field given as input, and represent a derivative of it. Presently, the derivatives are computed separately along each spatial dimension, as 1D derivatives.

  • interface

    public module function estimate_lengthscale_field(this, get_field, n_mat) result(scales)

    Estimate typical length scales, one per each matter object, by computing , where is a field given as input, and represent a derivative of it. Presently, the derivatives are computed separately along each spatial dimension, as 1D derivatives.

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(inout) :: this
    function get_field(x, y, z) result(val)

    Returns the value of a field at the desired point

    Arguments
    Type IntentOptional Attributes Name
    double precision, intent(in) :: x

    coordinate of the desired point

    double precision, intent(in) :: y

    coordinate of the desired point

    double precision, intent(in) :: z

    coordinate of the desired point

    Return Value double precision

    Value of the field at

    integer, intent(in) :: n_mat

    Return Value double precision, DIMENSION(n_mat)

    Array of the minimum over the lattices that surround each matter object

procedure, public, NOPASS :: finalize

Corrects the \(\mathrm{SPH}\) \(\mathrm{ID}\) so that the linear momentum is zero

  • interface

    public module subroutine finalize(npart, pos, nlrf, u, pr, vel_u, theta, nstar, nu)

    Post-process the \(\mathrm{SPH}\) \(\mathrm{ID}\); for example, correct for the residual ADM linear momentum.

    Arguments

    Type IntentOptional Attributes Name
    integer, intent(in) :: npart

    Particle number

    double precision, intent(inout), DIMENSION(3,npart) :: pos

    Particle positions

    double precision, intent(inout), DIMENSION(npart) :: nlrf

    Baryon density in the local rest frame on the particles

    double precision, intent(inout), DIMENSION(npart) :: u

    Specific internal energy on the particles

    double precision, intent(inout), DIMENSION(npart) :: pr

    Pressure on the particles

    double precision, intent(inout), DIMENSION(3,npart) :: vel_u

    Spatial velocity in the computing frame on the particles

    double precision, intent(inout), DIMENSION(npart) :: theta

    Generalized Lorentz factor on the particles

    double precision, intent(inout), DIMENSION(npart) :: nstar

    Proper baryon density in the local rest frame on the particles

    double precision, intent(inout), DIMENSION(npart) :: nu

    Baryon number per particle

procedure, public, NON_OVERRIDABLE :: find_center

Finds the center of a matter object, as the point where the density is maximal.

  • interface

    public module function find_center(this, separation, x_sign, get_density) result(center)

    Finds the center of a star, as the point where the density is maximal.

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    double precision, intent(in) :: separation

    Separation between the stars

    double precision, intent(in) :: x_sign

    Sign of the x coordinates of the point inside the star

    procedure(get_density_at_pos), optional :: get_density

    Return Value double precision

    Center of a star, as the point where the density is maximal.

procedure, public, NON_OVERRIDABLE :: find_print_surfaces

Finds the surfaces of the stars, and prints them to a formatted file.

  • interface

    public module subroutine find_print_surfaces(this)

    Finds the surfaces of the stars, and prints them to a formatted file.

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(inout) :: this

    bnsbase object owning this PROCEDURE

procedure, public, NON_OVERRIDABLE :: find_radius

Finds the radius of a star, relative to a center and along a direction. The radius is determined as the first point where the density is zero.

  • interface

    public module function find_radius(this, center, vector, get_density) result(radius)

    Finds the radius of a matter object, relative to a center and along a direction. The radius is determined as the first point where the density is zero.

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    double precision, intent(in), DIMENSION(3) :: center

    Center point relative to which the radius is measured

    double precision, intent(in), DIMENSION(3) :: vector

    Vector that defines the direction along which to measure the radius. If not normalized, it will be normalized.

    procedure(get_density_at_pos), optional :: get_density

    Return Value double precision

    Radius of the star relative to center, along the direction specified by vector

procedure, public, NON_OVERRIDABLE :: find_surface

Finds the surface of a star, using [[bnsbase::find_radius]] along many directions.

  • interface

    public module subroutine find_surface(this, center, n_theta, n_phi, surface)

    Finds the surface of a star, using [[bnsbase::find_radius]] along many directions.

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    double precision, intent(in), DIMENSION(3) :: center

    Center point relative to which the radius is measured

    integer, intent(in) :: n_theta

    Number of points in for the colatitude

    integer, intent(in) :: n_phi

    Number of points in for the azimuth

    double precision, intent(out), DIMENSION(:,:,:), ALLOCATABLE :: surface

    Array storing the coordinates of the points on the surface

procedure, public :: get_adm_mass

Returns adm_mass

  • interface

    public pure module function get_adm_mass(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_angular_momentum

Returns the angular momentum vector angular_momentum_x, angular_momentum_y, angular_momentum_z

  • interface

    public pure module function get_angular_momentum(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision, (3)

    Result

procedure, public :: get_angular_vel

Returns angular_vel

  • interface

    public pure module function get_angular_vel(this)

    Returns angular_vel

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_barycenter1_x

Returns barycenter1_x

  • interface

    public pure module function get_barycenter1_x(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_barycenter2_x

Returns barycenter2_x

  • interface

    public pure module function get_barycenter2_x(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_bns_identifier

Returns bns_identifier

  • interface

    public module function get_bns_identifier(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    Return Value double precision

procedure, public :: get_center1_x

Returns center1_x

  • interface

    public pure module function get_center1_x(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_center2_x

Returns center2_x

  • interface

    public pure module function get_center2_x(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public, NON_OVERRIDABLE :: get_cold_system

Returns cold_system, the LOGICAL variable that specifies if the system is cold (no thermal component)

  • interface

    public pure module function get_cold_system(this)

    Returns cold_system, the LOGICAL variable at specifies if the system is cold (no thermal component)

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: this

    Return Value logical

    cold_system

procedure, public :: get_distance

Returns distance

  • interface

    public pure module function get_distance(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_distance_com

Returns distance_com

  • interface

    public pure module function get_distance_com(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_energy_density_center1

  • interface

    public pure module function get_energy_density_center1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_energy_density_center2

  • interface

    public pure module function get_energy_density_center2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_ent_center1

Returns ent_center1

  • interface

    public pure module function get_ent_center1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_ent_center2

Returns ent_center2

  • interface

    public pure module function get_ent_center2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_eos1

Returns eos1

  • interface

    public pure module function get_eos1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value character(len=:), ALLOCATABLE

    Result

procedure, public :: get_eos1_fukaid

Returns eos1_fukaid

  • interface

    public module function get_eos1_fukaid(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    Return Value integer

procedure, public :: get_eos1_id => get_eos1_fukaid

Returns the \(\texttt{FUKA}\) identifier for the EOS of star 1

  • interface

    public module function get_eos1_fukaid(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    Return Value integer

procedure, public :: get_eos2

Returns eos2

  • interface

    public pure module function get_eos2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value character(len=:), ALLOCATABLE

    Result

procedure, public :: get_eos2_fukaid

Returns eos2_fukaid

  • interface

    public module function get_eos2_fukaid(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    Return Value integer

procedure, public :: get_eos2_id => get_eos2_fukaid

Returns the \(\texttt{FUKA}\) identifier for the EOS of star 2

  • interface

    public module function get_eos2_fukaid(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    Return Value integer

procedure, public :: get_eos_id

Returns eos1_id or eos2_id

  • interface

    public module function get_eos_id(this, i_matter)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    integer, intent(in) :: i_matter

    Index of the matter object whose string is to return

    Return Value integer

    Result

procedure, public, NON_OVERRIDABLE :: get_estimate_length_scale

Returns estimate_length_scale, the LOGICAL variable that specifies if a typical length scale, equal to the ratio of a field over its gradient, should be computed

  • interface

    public pure module function get_estimate_length_scale(this)

    Returns estimate_length_scale, the LOGICAL variable that specifies if a typical length scale, equal to the ratio of a field over its gradient, should be computed

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: this

    Return Value logical

    estimate_length_scale

procedure, public :: get_fa => get_field_array

Access the bnsfuka-member arrays

  • interface

    public module function get_field_array(this, field) result(field_array)

    Returns the bnsfuka member arrays named field

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    character(len=:), intent(in), ALLOCATABLE :: field

    Name of the desired bnsfuka member array

    Return Value double precision, DIMENSION(:), ALLOCATABLE

    Desired bnsfuka member array

generic, public :: get_field => get_fa, get_fv

GENERIC PROCEDURE, overloded to access the bnsfuka-member variables as arrays and as values

procedure, public :: get_fv => get_field_value

Access the components of the bnsfuka-member arrays

  • interface

    public module function get_field_value(this, field, n) result(field_value)

    Returns the component n of the bnsfuka member arrays named field

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    character(len=:), intent(in), ALLOCATABLE :: field

    Name of the desired bnsfuka member array

    integer, intent(in) :: n

    Component of the desired bnsfuka member array

    Return Value double precision

    Component n of the desired bnsfuka member array

procedure, public :: get_gamma0_1

Returns gamma0_1

  • interface

    public pure module function get_gamma0_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma0_2

Returns gamma0_2

  • interface

    public pure module function get_gamma0_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma1_1

Returns gamma1_1

  • interface

    public pure module function get_gamma1_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma1_2

Returns gamma1_2

  • interface

    public pure module function get_gamma1_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma2_1

Returns gamma2_1

  • interface

    public pure module function get_gamma2_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma2_2

Returns gamma2_2

  • interface

    public pure module function get_gamma2_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma3_1

Returns gamma3_1

  • interface

    public pure module function get_gamma3_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma3_2

Returns gamma3_2

  • interface

    public pure module function get_gamma3_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma_1

Returns gamma_1

  • interface

    public pure module function get_gamma_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_gamma_2

Returns gamma_2

  • interface

    public pure module function get_gamma_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_grav_mass1

Returns mass_grav1

  • interface

    public pure module function get_grav_mass1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_grav_mass2

Returns mass_grav2

  • interface

    public pure module function get_grav_mass2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa0_1

Returns kappa0_1

  • interface

    public pure module function get_kappa0_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa0_2

Returns kappa0_2

  • interface

    public pure module function get_kappa0_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa1_1

Returns kappa1_1

  • interface

    public pure module function get_kappa1_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa1_2

Returns kappa1_2

  • interface

    public pure module function get_kappa1_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa2_1

Returns kappa2_1

  • interface

    public pure module function get_kappa2_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa2_2

Returns kappa2_2

  • interface

    public pure module function get_kappa2_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa3_1

Returns kappa3_1

  • interface

    public pure module function get_kappa3_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa3_2

Returns kappa3_2

  • interface

    public pure module function get_kappa3_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa_1

Returns kappa_1

  • interface

    public pure module function get_kappa_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_kappa_2

Returns kappa_2

  • interface

    public pure module function get_kappa_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_linear_momentum

Returns the linear momentum vector linear_momentum_x, linear_momentum_y, linear_momentum_z

  • interface

    public pure module function get_linear_momentum(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision, (3)

    Result

procedure, public :: get_logP1_1

Returns logP1_1

  • interface

    public pure module function get_logP1_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_logP1_2

Returns logP1_2

  • interface

    public pure module function get_logP1_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_logRho0_1

Returns logRho0_1

  • interface

    public pure module function get_logRho0_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_logRho0_2

Returns logRho0_2

  • interface

    public pure module function get_logRho0_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_logRho1_1

Returns logRho1_1

  • interface

    public pure module function get_logRho1_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_logRho1_2

Returns logRho1_2

  • interface

    public pure module function get_logRho1_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_logRho2_1

Returns logRho2_1

  • interface

    public pure module function get_logRho2_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_logRho2_2

Returns logRho2_2

  • interface

    public pure module function get_logRho2_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_mass1

Returns mass1

  • interface

    public pure module function get_mass1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_mass2

Returns mass2

  • interface

    public pure module function get_mass2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public, NON_OVERRIDABLE :: get_n_matter

Returns n_matter, the number of matter objects in the physical system

  • interface

    public pure module function get_n_matter(this)

    Returns n_matter, the number of matter objects in the physical system

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: this

    Return Value integer

    n_matter, the number of matter objects in the

procedure, public :: get_nbar_center1

Returns nbar_center1

  • interface

    public pure module function get_nbar_center1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_nbar_center2

Returns nbar_center2

  • interface

    public pure module function get_nbar_center2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_npeos_1

Returns npeos_1

  • interface

    public pure module function get_npeos_1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value integer

    Result

procedure, public :: get_npeos_2

Returns npeos_2

  • interface

    public pure module function get_npeos_2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value integer

    Result

procedure, public, NON_OVERRIDABLE :: get_one_lapse

Returns one_lapse, the LOGICAL variable that determines if the lapse function , i.e., if the geodesic gauge is to be used

  • interface

    public pure module function get_one_lapse(this)

    Returns n_matter, the number of matter objects in the physical system

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: this

    Return Value logical

    n_matter, the number of matter objects in the

procedure, public :: get_pressure_center1

  • interface

    public pure module function get_pressure_center1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_pressure_center2

  • interface

    public pure module function get_pressure_center2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius1_x_comp

Returns radius1_x_comp

  • interface

    public pure module function get_radius1_x_comp(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius1_x_opp

Returns radius1_x_opp

  • interface

    public pure module function get_radius1_x_opp(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius1_y

Returns radius1_y

  • interface

    public pure module function get_radius1_y(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius1_z

Returns radius1_z

  • interface

    public pure module function get_radius1_z(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius2_x_comp

Returns radius2_x_comp

  • interface

    public pure module function get_radius2_x_comp(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius2_x_opp

Returns radius2_x_opp

  • interface

    public pure module function get_radius2_x_opp(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius2_y

Returns radius2_y

  • interface

    public pure module function get_radius2_y(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_radius2_z

Returns radius2_y

  • interface

    public pure module function get_radius2_z(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_rho_center1

Returns rho_center1

  • interface

    public pure module function get_rho_center1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_rho_center2

Returns rho_center2

  • interface

    public pure module function get_rho_center2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_specific_energy_center1

  • interface

    public pure module function get_specific_energy_center1(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: get_specific_energy_center2

  • interface

    public pure module function get_specific_energy_center2(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public, NON_OVERRIDABLE :: get_total_spatial_extent

Returns the spatial extent of the physical system considered, as the array of 6 numbers

  • interface

    public module function get_total_spatial_extent(this) result(box)

    INTERFACE to the SUBROUTINE that detects the spatial extent of the physical system considered, and returns a 6-dimensional array containing the coordinates of a box centered at the center of the object and containing the system.

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: this

    Object of class idbase which this PROCEDURE is a member of

    Return Value double precision, DIMENSION(6)

    6-dimensional array containing the coordinates of a box containing the physical system.

procedure, public, NON_OVERRIDABLE :: get_zero_shift

Returns zero_shift, the LOGICAL variable that determines if the shift

  • interface

    public pure module function get_zero_shift(this)

    Returns n_matter, the number of matter objects in the physical system

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: this

    Return Value logical

    n_matter, the number of matter objects in the

procedure, public, NON_OVERRIDABLE :: initialize

This PROCEDURE calls the constructor of the idbase-extended type and the SUBROUTINE sanity_check afterwards. It is recommended to use this SUBROUTINE to construct objects of idbase-extended type since the sanity check is performed automatically.

  • interface

    public module subroutine initialize(derived_type, filename, eos_filenames)

    Initialize the DERIVED TYPE that extends idbase

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(out) :: derived_type

    Object of DERIVED TYPE that extends [[idbase], to be constructed

    character(len=*), intent(in), optional :: filename

    Name of the file containing the \(\mathrm{ID}\)

    character(len=*), intent(in), optional, DIMENSION(:) :: eos_filenames

    Array of strings containing the names of the files containing the \(\mathrm{EOS}\) to be used for each matter object. If not PRESENT, information from the file filename is used

procedure, public :: initialize_id => initialize_id_bnsfuka

  • interface

    public recursive module subroutine initialize_id_bnsfuka(this, flag, switch)

    Initialize the \(\texttt{FUKA}\) \(\mathrm{BNS}\) \(\mathrm{ID}\).

    • If flag= [[utility:flag$sph]], set up the lattices around the stars for the \(\mathrm{BNS}\) produced with \(\texttt{FUKA}\).
    • If flag= [[utility:flag$tpo]], allocate memory for the hydro grid functions.
    • If flag > 0, assign its value to l_curr.
    • If [[utility:flag$tpo]] < flag < 0, assign its value to tpo_curr.

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this
    integer, intent(in) :: flag

    Identifies what kind of initialization has to be done

    logical, intent(in), optional :: switch

    If .TRUE., switch to a different initialization

procedure, public :: integrate_baryon_mass_density

Integrates the baryon mass density over a matter object, using spherical coordinates, and computes its radial profile inside the star

  • interface

    public module subroutine integrate_baryon_mass_density(this, center, radius, central_density, dr, dth, dphi, mass, mass_profile, mass_profile_idx, radii, surf)

    INTERFACE to the SUBROUTINE integrating the baryon mass density to compute the radial mass profile of a single star.

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(inout) :: this

    Object of class idbase which this PROCEDURE is a member of

    double precision, intent(in), DIMENSION(3) :: center

    Center of the star

    double precision, intent(in) :: radius

    Central density of the star

    double precision, intent(in) :: central_density

    Integration steps

    double precision, intent(in) :: dr

    Radius of the star

    double precision, intent(in) :: dth

    Radius of the star

    double precision, intent(in) :: dphi

    Radius of the star

    double precision, intent(inout) :: mass

    Integrated mass of the star

    double precision, intent(out), DIMENSION(3,0:NINT(radius/dr)) :: mass_profile

    Array storing the radial mass profile of the star

    integer, intent(out), DIMENSION(0:NINT(radius/dr)) :: mass_profile_idx

    Array to store the indices for array mass_profile, sorted so that mass_profile[mass_profile_idx] is in increasing order

    double precision, intent(in), optional, DIMENSION(2) :: radii
    type(surface), intent(in), optional :: surf

    Surface of the matter object

procedure, public :: interpolate_fuka_spatial_metric

  • interface

    public module function interpolate_fuka_spatial_metric(this, x, y, z) result(res)

    Returns the \(\texttt{FUKA}\) conformally flat spatial metric component at a point

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    real(kind=C_DOUBLE), intent(in), VALUE :: x

    coordinate of the desired point

    real(kind=C_DOUBLE), intent(in), VALUE :: y

    coordinate of the desired point

    real(kind=C_DOUBLE), intent(in), VALUE :: z

    coordinate of the desired point

    Return Value real(kind=C_DOUBLE)

    at

procedure, public :: is_hydro_positive

Returns 1 if the energy density or the specific energy or the pressure are negative

  • interface

    public module function is_hydro_positive(this, x, y, z) result(res)

    Returns 1 if the energy density or the specific energy or the pressure are negative, 0 otherwise

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    double precision, intent(in), VALUE :: x

    coordinate of the desired point

    double precision, intent(in), VALUE :: y

    coordinate of the desired point

    double precision, intent(in), VALUE :: z

    coordinate of the desired point

    Return Value logical

    .TRUE. if the energy density or the specific energy or the pressure are negative, .FALSE. otherwise

procedure, public :: print_bns_properties

Prints the parameters of the \(\mathrm{BNS}\) to the standard output

  • interface

    public module subroutine print_bns_properties(this)

    Prints the \(\mathrm{BNS}\) parameters to the standard output

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

procedure, public :: print_summary => print_summary_bnsbase

  • interface

    public module subroutine print_summary_bnsbase(this, filename)

    Prints a summary of the physical properties the \(\mathrm{BNS}\) system to the standard output and, optionally, to a formatted file whose name is given as the optional argument filename

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    character(len=*), intent(inout), optional :: filename

    Name of the formatted file to print the summary to

procedure, public :: print_summary_derived => print_summary_bnsfuka

  • interface

    public module subroutine print_summary_bnsfuka(this, filename)

    Prints a summary of the physical properties of the \(\mathrm{BNS}\) produced by \(\texttt{FUKA}\) to the standard output and, optionally, to a formatted file whose name is given as the optional argument filename

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this
    character(len=*), intent(inout), optional :: filename

    Name of the formatted file to print the summary to

procedure, public :: read_bns_properties

Imports the parameters of the \(\mathrm{BNS}\) from \(\texttt{FUKA}\)

  • interface

    public module subroutine read_bns_properties(this)

    Imports the \(\mathrm{BNS}\) parameters from \(\texttt{FUKA}\)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

procedure, public :: read_fuka_id_mass_b

  • interface

    public module subroutine read_fuka_id_mass_b(this, x, y, z, g, baryon_density, gamma_euler)

    Stores the hydro \(\mathrm{ID}\) in the arrays needed to compute the baryon mass

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    double precision, intent(in) :: x
    double precision, intent(in) :: y
    double precision, intent(in) :: z
    double precision, intent(out), DIMENSION(6) :: g
    double precision, intent(out) :: baryon_density
    double precision, intent(out) :: gamma_euler

procedure, public :: read_fuka_id_member

Stores the \(\mathrm{ID}\) in the bnsfuka member arrays

  • interface

    public module subroutine read_fuka_id_member(this, n, x, y, z)

    Stores the \(\mathrm{ID}\) in the bnsfuka member arrays

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: n
    double precision, intent(in), DIMENSION(:) :: x
    double precision, intent(in), DIMENSION(:) :: y
    double precision, intent(in), DIMENSION(:) :: z

procedure, public :: read_fuka_id_particles

  • interface

    public module subroutine read_fuka_id_particles(this, n, x, y, z, lapse, shift_x, shift_y, shift_z, g_xx, g_xy, g_xz, g_yy, g_yz, g_zz, baryon_density, energy_density, specific_energy, pressure, u_euler_x, u_euler_y, u_euler_z)

    Stores the hydro \(\mathrm{ID}\) in the arrays needed to compute the \(\mathrm{SPH}\) \(\mathrm{ID}\)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: n
    real(kind=C_DOUBLE), intent(in), DIMENSION(:) :: x
    real(kind=C_DOUBLE), intent(in), DIMENSION(:) :: y
    real(kind=C_DOUBLE), intent(in), DIMENSION(:) :: z
    double precision, intent(inout), DIMENSION(:) :: lapse
    double precision, intent(inout), DIMENSION(:) :: shift_x
    double precision, intent(inout), DIMENSION(:) :: shift_y
    double precision, intent(inout), DIMENSION(:) :: shift_z
    double precision, intent(inout), DIMENSION(:) :: g_xx
    double precision, intent(inout), DIMENSION(:) :: g_xy
    double precision, intent(inout), DIMENSION(:) :: g_xz
    double precision, intent(inout), DIMENSION(:) :: g_yy
    double precision, intent(inout), DIMENSION(:) :: g_yz
    double precision, intent(inout), DIMENSION(:) :: g_zz
    double precision, intent(inout), DIMENSION(:) :: baryon_density
    double precision, intent(inout), DIMENSION(:) :: energy_density
    double precision, intent(inout), DIMENSION(:) :: specific_energy
    double precision, intent(inout), DIMENSION(:) :: pressure
    double precision, intent(inout), DIMENSION(:) :: u_euler_x
    double precision, intent(inout), DIMENSION(:) :: u_euler_y
    double precision, intent(inout), DIMENSION(:) :: u_euler_z

procedure, public :: read_fuka_mass_density

Returns the \(\texttt{FUKA}\)'s mass density at the given point

  • interface

    public module function read_fuka_mass_density(this, x, y, z) result(res)

    Returns the \(\texttt{FUKA}\) baryon mass density at a point

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    double precision, intent(in), VALUE :: x

    coordinate of the desired point

    double precision, intent(in), VALUE :: y

    coordinate of the desired point

    double precision, intent(in), VALUE :: z

    coordinate of the desired point

    Return Value double precision

    Baryon mass density at

procedure, public :: read_fuka_pressure

Returns the \(\texttt{FUKA}\)'s pressure at the desired point

  • interface

    public module function read_fuka_pressure(this, x, y, z) result(res)

    Returns the \(\texttt{FUKA}\) pressure at a point

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnslorene object which this PROCEDURE is a member of

    double precision, intent(in), VALUE :: x

    coordinate of the desired point

    double precision, intent(in), VALUE :: y

    coordinate of the desired point

    double precision, intent(in), VALUE :: z

    coordinate of the desired point

    Return Value double precision

    Pressure at

procedure, public :: read_fuka_spatial_metric

Returns the \(\texttt{FUKA}\)'s conformally flat spatial ADM metric

  • interface

    public module function read_fuka_spatial_metric(this, x, y, z) result(res)

    Returns the \(\texttt{FUKA}\) conformally flat spatial metric component at a point

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    real(kind=C_DOUBLE), intent(in), VALUE :: x

    coordinate of the desired point

    real(kind=C_DOUBLE), intent(in), VALUE :: y

    coordinate of the desired point

    real(kind=C_DOUBLE), intent(in), VALUE :: z

    coordinate of the desired point

    Return Value real(kind=C_DOUBLE)

    at

procedure, public :: read_id_full => read_fuka_id_full

  • interface

    public module subroutine read_fuka_id_full(this, n, x, y, z, lapse, shift_x, shift_y, shift_z, g_xx, g_xy, g_xz, g_yy, g_yz, g_zz, k_xx, k_xy, k_xz, k_yy, k_yz, k_zz, baryon_density, energy_density, specific_energy, pressure, u_euler_x, u_euler_y, u_euler_z)

    Stores the \(\mathrm{ID}\) in non bnsfuka-member arrays with the same shape as the bnsfuka member arrays

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: n
    double precision, intent(in), DIMENSION(:) :: x
    double precision, intent(in), DIMENSION(:) :: y
    double precision, intent(in), DIMENSION(:) :: z
    double precision, intent(inout), DIMENSION(:) :: lapse
    double precision, intent(inout), DIMENSION(:) :: shift_x
    double precision, intent(inout), DIMENSION(:) :: shift_y
    double precision, intent(inout), DIMENSION(:) :: shift_z
    double precision, intent(inout), DIMENSION(:) :: g_xx
    double precision, intent(inout), DIMENSION(:) :: g_xy
    double precision, intent(inout), DIMENSION(:) :: g_xz
    double precision, intent(inout), DIMENSION(:) :: g_yy
    double precision, intent(inout), DIMENSION(:) :: g_yz
    double precision, intent(inout), DIMENSION(:) :: g_zz
    double precision, intent(inout), DIMENSION(:) :: k_xx
    double precision, intent(inout), DIMENSION(:) :: k_xy
    double precision, intent(inout), DIMENSION(:) :: k_xz
    double precision, intent(inout), DIMENSION(:) :: k_yy
    double precision, intent(inout), DIMENSION(:) :: k_yz
    double precision, intent(inout), DIMENSION(:) :: k_zz
    double precision, intent(inout), DIMENSION(:) :: baryon_density
    double precision, intent(inout), DIMENSION(:) :: energy_density
    double precision, intent(inout), DIMENSION(:) :: specific_energy
    double precision, intent(inout), DIMENSION(:) :: pressure
    double precision, intent(inout), DIMENSION(:) :: u_euler_x
    double precision, intent(inout), DIMENSION(:) :: u_euler_y
    double precision, intent(inout), DIMENSION(:) :: u_euler_z

procedure, public :: read_id_hydro => read_fuka_id_hydro

  • interface

    public module subroutine read_fuka_id_hydro(this, nx, ny, nz, pos, baryon_density, energy_density, specific_energy, pressure, u_euler)

    Stores the hydro \(\mathrm{ID}\) in the arrays needed to compute the constraints on the refined mesh

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: nx
    integer, intent(in) :: ny
    integer, intent(in) :: nz
    double precision, intent(in), DIMENSION(:,:,:,:) :: pos
    double precision, intent(inout), DIMENSION(:,:,:) :: baryon_density
    double precision, intent(inout), DIMENSION(:,:,:) :: energy_density
    double precision, intent(inout), DIMENSION(:,:,:) :: specific_energy
    double precision, intent(inout), DIMENSION(:,:,:) :: pressure
    double precision, intent(inout), DIMENSION(:,:,:,:) :: u_euler

procedure, public :: read_id_k => read_fuka_id_k

  • interface

    public module subroutine read_fuka_id_k(this, n, x, y, z, k_xx, k_xy, k_xz, k_yy, k_yz, k_zz)

    Stores the components of the extrinsic curvature in arrays

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: n
    double precision, intent(in), DIMENSION(:) :: x
    double precision, intent(in), DIMENSION(:) :: y
    double precision, intent(in), DIMENSION(:) :: z
    double precision, intent(inout), DIMENSION(:) :: k_xx
    double precision, intent(inout), DIMENSION(:) :: k_xy
    double precision, intent(inout), DIMENSION(:) :: k_xz
    double precision, intent(inout), DIMENSION(:) :: k_yy
    double precision, intent(inout), DIMENSION(:) :: k_yz
    double precision, intent(inout), DIMENSION(:) :: k_zz

procedure, public :: read_id_mass_b => interpolate_fuka_id_mass_b

  • interface

    public module subroutine interpolate_fuka_id_mass_b(this, x, y, z, g, baryon_density, gamma_euler)

    Stores the hydro \(\mathrm{ID}\) in the arrays needed to compute the baryon mass

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    double precision, intent(in) :: x
    double precision, intent(in) :: y
    double precision, intent(in) :: z
    double precision, intent(out), DIMENSION(6) :: g
    double precision, intent(out) :: baryon_density
    double precision, intent(out) :: gamma_euler

procedure, public :: read_id_particles => interpolate_fuka_id_particles

  • interface

    public module subroutine interpolate_fuka_id_particles(this, n, x, y, z, lapse, shift_x, shift_y, shift_z, g_xx, g_xy, g_xz, g_yy, g_yz, g_zz, baryon_density, energy_density, specific_energy, pressure, u_euler_x, u_euler_y, u_euler_z)

    Stores the hydro \(\mathrm{ID}\) in the arrays needed to compute the \(\mathrm{SPH}\) \(\mathrm{ID}\)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: n
    real(kind=C_DOUBLE), intent(in), DIMENSION(:) :: x
    real(kind=C_DOUBLE), intent(in), DIMENSION(:) :: y
    real(kind=C_DOUBLE), intent(in), DIMENSION(:) :: z
    double precision, intent(inout), DIMENSION(:) :: lapse
    double precision, intent(inout), DIMENSION(:) :: shift_x
    double precision, intent(inout), DIMENSION(:) :: shift_y
    double precision, intent(inout), DIMENSION(:) :: shift_z
    double precision, intent(inout), DIMENSION(:) :: g_xx
    double precision, intent(inout), DIMENSION(:) :: g_xy
    double precision, intent(inout), DIMENSION(:) :: g_xz
    double precision, intent(inout), DIMENSION(:) :: g_yy
    double precision, intent(inout), DIMENSION(:) :: g_yz
    double precision, intent(inout), DIMENSION(:) :: g_zz
    double precision, intent(inout), DIMENSION(:) :: baryon_density
    double precision, intent(inout), DIMENSION(:) :: energy_density
    double precision, intent(inout), DIMENSION(:) :: specific_energy
    double precision, intent(inout), DIMENSION(:) :: pressure
    double precision, intent(inout), DIMENSION(:) :: u_euler_x
    double precision, intent(inout), DIMENSION(:) :: u_euler_y
    double precision, intent(inout), DIMENSION(:) :: u_euler_z

procedure, public :: read_id_spacetime => read_fuka_id_spacetime

  • interface

    public module subroutine read_fuka_id_spacetime(this, nx, ny, nz, pos, lapse, shift, g, ek)

    Stores the spacetime \(\mathrm{ID}\) in multi-dimensional arrays needed to compute the BSSN variables and constraints

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: nx
    integer, intent(in) :: ny
    integer, intent(in) :: nz
    double precision, intent(in), DIMENSION(:,:,:,:) :: pos
    double precision, intent(inout), DIMENSION(:,:,:) :: lapse
    double precision, intent(inout), DIMENSION(:,:,:,:) :: shift
    double precision, intent(inout), DIMENSION(:,:,:,:) :: g
    double precision, intent(inout), DIMENSION(:,:,:,:) :: ek

procedure, public :: read_mass_density => interpolate_fuka_mass_density

  • interface

    public module function interpolate_fuka_mass_density(this, x, y, z) result(res)

    Returns the \(\texttt{FUKA}\) baryon mass density at a point

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    double precision, intent(in), VALUE :: x

    coordinate of the desired point

    double precision, intent(in), VALUE :: y

    coordinate of the desired point

    double precision, intent(in), VALUE :: z

    coordinate of the desired point

    Return Value double precision

    Baryon mass density at

procedure, public :: read_pressure => interpolate_fuka_pressure

  • interface

    public module function interpolate_fuka_pressure(this, x, y, z) result(res)

    Returns the \(\texttt{FUKA}\) pressure at a point

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnslorene object which this PROCEDURE is a member of

    double precision, intent(in), VALUE :: x

    coordinate of the desired point

    double precision, intent(in), VALUE :: y

    coordinate of the desired point

    double precision, intent(in), VALUE :: z

    coordinate of the desired point

    Return Value double precision

    Pressure at

procedure, public :: return_adm_mass => get_adm_mass

  • interface

    public pure module function get_adm_mass(this)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object which this PROCEDURE is a member of

    Return Value double precision

    Result

procedure, public :: return_barycenter => get_barycenter

  • interface

    public module function get_barycenter(this, i_matter)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    integer, intent(in) :: i_matter

    Index of the matter object whose parameter is to return

    Return Value double precision, DIMENSION(3)

    Result

procedure, public :: return_center => get_center

  • interface

    public module function get_center(this, i_matter)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    integer, intent(in) :: i_matter

    Index of the matter object whose parameter is to return

    Return Value double precision, DIMENSION(3)

    Result

procedure, public :: return_eos_name => get_eos

  • interface

    public module function get_eos(this, i_matter)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    integer, intent(in) :: i_matter

    Index of the matter object whose string is to return

    Return Value character(len=:), ALLOCATABLE

    Result

procedure, public :: return_eos_parameters => get_eos_parameters

  • interface

    public module subroutine get_eos_parameters(this, i_matter, eos_params)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: i_matter

    Index of the matter object whose parameter is to return

    double precision, intent(out), DIMENSION(:), ALLOCATABLE :: eos_params

    Array containing the parameters of the \(\mathrm{EOS}\) for the i_matter-th matter object

procedure, public :: return_mass => get_mass

  • interface

    public module function get_mass(this, i_matter)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    integer, intent(in) :: i_matter

    Index identifying the matter object

    Return Value double precision

    Result

procedure, public :: return_spatial_extent => get_radii

  • interface

    public module function get_radii(this, i_matter)

    Arguments

    Type IntentOptional Attributes Name
    class(bnsbase), intent(in) :: this

    bnsbase object owning this PROCEDURE

    integer, intent(in) :: i_matter

    Index of the matter object whose string is to return

    Return Value double precision, DIMENSION(6)

    Result

procedure, public :: run_kadath_reader

Calls the MPI-parallelized version of the function KadathExportBNS within Kadath

  • interface

    public module subroutine run_kadath_reader(this, mpi_ranks, nx, ny, nz, xmin, xmax, ymin, ymax, zmin, zmax, coords, lapse, shift_x, shift_y, shift_z, g_xx, g_xy, g_xz, g_yy, g_yz, g_zz, k_xx, k_xy, k_xz, k_yy, k_yz, k_zz, mass_density, specific_energy, pressure, v_eul_x, v_eul_y, v_eul_z, filename)

    Calls the MPI-parallelized vsion of the function KadathExportBNS from Kadath

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

    integer, intent(in) :: mpi_ranks

    Number of MPI ranks

    integer, intent(in) :: nx

    Number of lattice points in the direction

    integer, intent(in) :: ny

    Number of lattice points in the direction

    integer, intent(in) :: nz

    Number of lattice points in the direction

    double precision, intent(in) :: xmin

    Minimum value for over the lattice

    double precision, intent(in) :: xmax

    Maximum value for over the lattice

    double precision, intent(in) :: ymin

    Minimum value for over the lattice

    double precision, intent(in) :: ymax

    Maximum value for over the lattice

    double precision, intent(in) :: zmin

    Minimum value for over the lattice

    double precision, intent(in) :: zmax

    Maximum value for over the lattice

    double precision, intent(inout), DIMENSION(nx,ny,nz,3) :: coords

    Array containing the \(\mathrm{ID}\) on a lattice. First three indices run over the lattice's dimensions, the fourth one runs ovr the fields

    double precision, intent(inout), DIMENSION(nx,ny,nz) :: lapse
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: shift_x
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: shift_y
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: shift_z
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: g_xx
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: g_xy
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: g_xz
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: g_yy
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: g_yz
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: g_zz
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: k_xx
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: k_xy
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: k_xz
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: k_yy
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: k_yz
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: k_zz
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: mass_density
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: specific_energy
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: pressure
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: v_eul_x
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: v_eul_y
    double precision, intent(inout), DIMENSION(nx,ny,nz) :: v_eul_z
    character(len=*), intent(in) :: filename

    Path to the \(\mathrm{ID}\) file output by \(\texttt{FUKA}\), as given in the parameter fe sphincs_id_parameters.dat

procedure, public, NON_OVERRIDABLE :: sanity_check

Checks that n_matter and the sizes returned by return_spatial_extent and get_total_spatial_extent are acceptable. It is called by initialize, after the constructor of the derived type.

  • interface

    public module subroutine sanity_check(derived_type)

    Check that the DERIVED TYPE that extends idbase is constructed consistently

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(in) :: derived_type

    Object of DERIVED TYPE that extends idbase

procedure, public, NON_OVERRIDABLE :: set_cold_system

Sets cold_system, the LOGICAL variable that specifies if the system is cold (no thermal component)

  • interface

    public module subroutine set_cold_system(this, value)

    Sets cold_system, the LOGICAL variable at specifies if the system is cold (no thermal component)

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(inout) :: this
    logical, intent(in) :: value

    Value to set cold_system to

procedure, public, NON_OVERRIDABLE :: set_estimate_length_scale

Sets estimate_length_scale, the LOGICAL variable that specifies if a typical length scale, equal to the ratio of a field over its gradient, should be computed

  • interface

    public module subroutine set_estimate_length_scale(this, value)

    Sets estimate_length_scale, the LOGICAL variable that specifies if a typical length scale, equal to the ratio of a field over its gradient, should be computed

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(inout) :: this
    logical, intent(in) :: value

    Value to set cold_system to

procedure, public, NON_OVERRIDABLE :: set_n_matter

Sets n_matter, the number of matter objects in the physical system, to a value

  • interface

    public pure module subroutine set_n_matter(this, value)

    Sets n_matter, the number of matter objects in the physical system, to the given value

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(inout) :: this
    integer, intent(in) :: value

    Value to set n_matter to

procedure, public, NON_OVERRIDABLE :: set_one_lapse

Sets one_lapse, the LOGICAL variable that determines if the lapse , i.e., if the geodesic gauge is to be used

  • interface

    public pure module subroutine set_one_lapse(this, logic)

    Sets n_matter, the number of matter objects in the physical system, to the given value

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(inout) :: this
    logical, intent(in) :: logic

    Value to set n_matter to

procedure, public :: set_up_lattices_around_stars

Sets up two fine lattice, one around each star, to be able to interpolate the \(\mathrm{ID}\) at the particle positions. It calls run_kadath_reader

Integrates the \(\texttt{FUKA}\) baryon mass density and computes the radial mass profile

  • interface

    public module subroutine set_up_lattices_around_stars(this)

    Sets up two fine lattice, one around each star, to be able to interpolate the \(\mathrm{ID}\) at the particle positions. It calls run_kadath_reader

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(inout) :: this

    bnsfuka object which this PROCEDURE is a member of

procedure, public, NON_OVERRIDABLE :: set_zero_shift

Sets zero_shift, the LOGICAL variable that determines if the shift

  • interface

    public pure module subroutine set_zero_shift(this, logic)

    Sets n_matter, the number of matter objects in the physical system, to the given value

    Arguments

    Type IntentOptional Attributes Name
    class(idbase), intent(inout) :: this
    logical, intent(in) :: logic

    Value to set n_matter to

procedure, public :: test_position => is_hydro_positive_interpolation

  • interface

    public module function is_hydro_positive_interpolation(this, x, y, z) result(res)

    Returns 1 if the energy density or the specific energy or the pressure are negative, 0 otherwise

    Arguments

    Type IntentOptional Attributes Name
    class(bnsfuka), intent(in) :: this

    bnsfuka object which this PROCEDURE is a member of

    double precision, intent(in), VALUE :: x

    coordinate of the desired point

    double precision, intent(in), VALUE :: y

    coordinate of the desired point

    double precision, intent(in), VALUE :: z

    coordinate of the desired point

    Return Value logical

    .TRUE. if the energy density or the specific energy or the pressure are negative, .FALSE. otherwise

Source Code

  TYPE, EXTENDS(bnsbase):: bnsfuka
  !# TYPE representing a binary system of neutron stars (|bns|) produced with
  !  |fuka|


    PRIVATE


    INTEGER:: bns_identifier= 0
    !! Identifier of the bnsfuka object
    INTEGER:: eos1_fukaid
    !! |fuka| identifier for the |eos| of star 1
    INTEGER:: eos2_fukaid
    !! |fuka| identifier for the |eos| of star 2

    !
    !-- ID fields on a lattice around each star
    !
    INTEGER:: nx_lattice= 400
    !! Number of points for each lattice around the stars, along the \(x\) axis
    INTEGER:: ny_lattice= 400
    !! Number of points for each lattice around the stars, along the \(y\) axis
    INTEGER:: nz_lattice= 400
    !! Number of points for each lattice around the stars, along the \(z\) axis
    TYPE(id_lattice), DIMENSION(2):: star_lattice
    !# Array storing two [[bns_fuka:id_lattice]] objects, one per star

    !
    !-- Hydro fields stored on a refined mesh
    !
    INTEGER, DIMENSION(max$tpo):: tpo$log= 0
    !# Variable that stores the identifiers for the [[tpo]] objects constructed
    !  using this [[bnsfuka]] object
    INTEGER, PUBLIC:: tpo_curr= 0
    !# Variable set to the current [[tpo]] object to consider, when reading
    !  the hydro |id| on the refined mesh in computing the constraints
    INTEGER, PUBLIC:: l_curr
    !# Variable set to the current refinement level to consider, when reading
    !  the hydro |id| on the refined mesh in computing the constraints
    TYPE(grid_function_scalar), DIMENSION(max$tpo), PUBLIC:: mass_density
    !! 1-D array storing the baryon mass density in the fluid frame
    TYPE(grid_function_scalar), DIMENSION(max$tpo), PUBLIC:: pressure
    !! 1-D array storing the pressure
    TYPE(grid_function_scalar), DIMENSION(max$tpo), PUBLIC:: specific_energy
    !! 1-D array storing the specific internal energy
    TYPE(grid_function_scalar), DIMENSION(max$tpo), PUBLIC:: v_euler_x
    !# 1-D array storing the x component of the fluid 3-velocity with respect to
    !  the Eulerian observer [c]
    TYPE(grid_function_scalar), DIMENSION(max$tpo), PUBLIC:: v_euler_y
    !# 1-D array storing the y component of the fluid 3-velocity with respect to
    !  the Eulerian observer [c]
    TYPE(grid_function_scalar), DIMENSION(max$tpo), PUBLIC:: v_euler_z
    !# 1-D array storing the z component of the fluid 3-velocity with respect to
    !  the Eulerian observer [c]


    DOUBLE PRECISION:: komar_mass
    !! Komar mass of the binary system \([M_\odot]\)

    !& C pointer to the |fuka|'s object storing the |bns| \id|
    !  N.B. This variable is global. The pointer to the second |fuka| |binns|
    !       object will overwrite the first one, and so on.
    !       This variable stores the pointer to the last defined |fuka| |binns|
    !      object. That's why it is not freed in the destructor of a bns object.
    !       Presently, it has to be freed by the user at the end of the PROGRAM.
    !       See the last part of the PROGRAM in sphincs_id.f90, for example.
    TYPE(C_PTR):: bns_ptr

    CHARACTER(LEN=:), ALLOCATABLE:: eos_type_1
    !! String containing the type of the |eos| of star 1
    CHARACTER(LEN=:), ALLOCATABLE:: eos_file_1
    !! String containing the name of the |eos| file used by |fuka| of star 1
    CHARACTER(LEN=:), ALLOCATABLE:: eos_type_2
    !! String containing the type of the |eos| of star 2
    CHARACTER(LEN=:), ALLOCATABLE:: eos_file_2
    !! String containing the name of the |eos| file used by |fuka| of star 2

    CHARACTER(LEN=:), ALLOCATABLE:: filename
    !! String containing the name of the '.info' |id| file output by |fuka|


    CONTAINS


    !-------------------!
    !--  SUBROUTINES  --!
    !-------------------!

    PROCEDURE:: derived_type_constructor => construct_bnsfuka

    PROCEDURE:: construct_binary
    !! Constructs the |fuka| bns_export object

    PROCEDURE:: destruct_binary
    !! Destructs the |fuka| bns_export object

    PROCEDURE:: allocate_bnsfuka_memory
    !! Allocates memory for the [[bnsfuka]] member arrays

    !PROCEDURE:: allocate_bnsfuka_hydro_memory
    !# Allocates memory for the [[bnsfuka]] member 3D arrays storing the
    !  hydro fields

    PROCEDURE:: deallocate_bnsfuka_memory
    !! Deallocates memory for the [[bnsfuka]] member arrays

    PROCEDURE:: read_bns_properties
    !! Imports the parameters of the |bns| from |fuka|

    PROCEDURE:: run_kadath_reader
    !# Calls the MPI-parallelized version of the function KadathExportBNS
    !  within Kadath

    PROCEDURE:: set_up_lattices_around_stars
    !# Sets up two fine lattice, one around each star, to be able to interpolate
    ! the |id| at the particle positions. It calls [[bnsfuka:run_kadath_reader]]

    !PROCEDURE:: integrate_field_on_star => integrate_baryon_mass_density
    !# Integrates the |fuka| baryon mass density and computes the
    !  radial mass profile

    PROCEDURE, PUBLIC:: print_bns_properties
    !! Prints the parameters of the |bns| to the standard output

    PROCEDURE:: read_fuka_id_member
    !! Stores the |id| in the [[bnsfuka]] member arrays

    PROCEDURE:: read_id_full      => read_fuka_id_full
    PROCEDURE:: read_id_spacetime => read_fuka_id_spacetime
    PROCEDURE:: read_id_hydro     => read_fuka_id_hydro
    PROCEDURE:: read_id_k         => read_fuka_id_k

    PROCEDURE:: read_fuka_id_particles
    PROCEDURE:: read_fuka_id_mass_b
    PROCEDURE:: read_id_particles => interpolate_fuka_id_particles
    PROCEDURE:: read_id_mass_b    => interpolate_fuka_id_mass_b

    PROCEDURE:: print_summary_derived => print_summary_bnsfuka

    PROCEDURE:: initialize_id => initialize_id_bnsfuka

    PROCEDURE, NOPASS:: finalize
    !# Corrects the |sph| |id| so that the linear \(\mathrm{ADM}\) momentum
    !  is zero

    !-----------------!
    !--  FUNCTIONS  --!
    !-----------------!

    !> Returns the |fuka|'s mass density at the given point
    PROCEDURE:: read_fuka_mass_density
    PROCEDURE:: read_mass_density => interpolate_fuka_mass_density

    !> Returns the |fuka|'s pressure at the desired point
    PROCEDURE:: read_fuka_pressure
    PROCEDURE:: read_pressure => interpolate_fuka_pressure

    !> Returns the |fuka|'s conformally flat spatial ADM metric
    PROCEDURE:: read_fuka_spatial_metric
    PROCEDURE:: interpolate_fuka_spatial_metric

    !& Returns 1 if the energy density or the specific energy or the pressure
    !  are negative
    PROCEDURE:: is_hydro_positive
    PROCEDURE:: test_position => is_hydro_positive_interpolation

    !
    !-- Overloaded FUNCTION to access the fields as arrays and as values
    !

    GENERIC, PUBLIC:: get_field => get_fa, get_fv
    !# GENERIC PROCEDURE, overloded to access the [[bnsfuka]]-member variables
    !  as arrays and as values
    PROCEDURE::       get_fa    => get_field_array
    !! Access the [[bnsfuka]]-member arrays
    PROCEDURE::       get_fv    => get_field_value
    !! Access the components of the [[bnsfuka]]-member arrays

    !
    !-- FUNCTIONS that access member variables
    !
    PROCEDURE:: get_eos1_id => get_eos1_fukaid
    !! Returns the |fuka| identifier for the EOS of star 1
    PROCEDURE:: get_eos2_id => get_eos2_fukaid
    !! Returns the |fuka| identifier for the EOS of star 2

    PROCEDURE:: return_eos_parameters => get_eos_parameters

    PROCEDURE, PUBLIC:: get_eos1_fukaid
    !! Returns [[bnsfuka:eos1_fukaid]]
    PROCEDURE, PUBLIC:: get_eos2_fukaid
    !! Returns [[bnsfuka:eos2_fukaid]]

    PROCEDURE, PUBLIC:: get_bns_identifier
    !! Returns [[bnsfuka:bns_identifier]]

    !PROCEDURE, PUBLIC:: get_bns_ptr

    !PROCEDURE:: derived_type_destructor => destruct_bnsfuka

    !PROCEDURE:: derived_type_destructor => destruct_bnsfuka
    FINAL:: destruct_bnsfuka
    !! Finalizer (Destructor) of a [[bnsfuka]] object

  END TYPE bnsfuka