76#include "bin_bhns_extr.h"
78#include "utilitaires.h"
89 bool relat,
bool kerrs,
bool multi)
90 :
ref_triad(0.,
"Absolute frame Cartesian basis"),
106 :
ref_triad(0.,
"Absolute frame Cartesian basis"),
121 :
ref_triad(0.,
"Absolute frame Cartesian basis"),
218 ost <<
"Binary BH-NS system" << endl ;
219 ost <<
"===================" << endl ;
221 if (
star.in_kerrschild()) {
222 ost <<
"Kerr-Schild background metric" << endl ;
223 ost <<
"-----------------------------" << endl ;
226 ost <<
"Conformally flat background metric" << endl ;
227 ost <<
"----------------------------------" << endl ;
229 if (
star.with_multipole()) {
230 ost <<
"Multipole falloff boundary condition" << endl ;
231 ost <<
"------------------------------------" << endl ;
234 ost <<
"1/r falloff boundary condition" << endl ;
235 ost <<
"------------------------------" << endl ;
238 <<
"Orbital angular velocity : "
239 <<
omega * f_unit <<
" rad/s" << endl ;
240 ost <<
"Coordinate separation between BH and NS : "
241 <<
separ / km <<
" km" << endl ;
243 ost << endl <<
"Neutron star : " ;
244 ost << endl <<
"============ " << endl ;
246 if (
star.is_relativistic()) {
247 ost <<
"Relativistic star" << endl ;
248 ost <<
"-----------------" << endl ;
251 ost <<
"WARNING : BH-NS binary should be relativistic !!!" << endl ;
252 ost <<
"-------------------------------------------------" << endl ;
254 ost <<
"Number of domains occupied by the star : " <<
star.get_nzet()
256 ost <<
"Equation of state : " << endl ;
257 ost <<
star.get_eos() << endl ;
260 <<
"Enthalpy at the coordinate origin : "
261 <<
star.get_ent()()(0,0,0,0) <<
" c^2" << endl ;
262 ost <<
"Proper baryon density at the coordinate origin : "
263 <<
star.get_nbar()()(0,0,0,0) <<
" x 0.1 fm^-3" << endl ;
264 ost <<
"Proper energy density at the coordinate origin : "
265 <<
star.get_ener()()(0,0,0,0) <<
" rho_nuc c^2" << endl ;
266 ost <<
"Pressure at the coordinate origin : "
267 <<
star.get_press()()(0,0,0,0) <<
" rho_nuc c^2" << endl ;
269 <<
"Lapse N at the coordinate origin : "
270 <<
star.get_nnn()()(0,0,0,0) << endl ;
271 ost <<
"Conformal factor A^2 at the coordinate origin : "
272 <<
star.get_a_car()()(0,0,0,0) << endl ;
275 <<
"Equatorial radius (to BH) a_to : "
276 <<
star.ray_eq_pi()/km <<
" km" << endl ;
277 ost <<
"Equatorial radius (opp. to BH) a_opp : "
278 <<
star.ray_eq()/km <<
" km" << endl ;
281 <<
"Baryon mass in isolation : " <<
star.mass_b() / msol
283 <<
"Gravitational mass in isolation : " <<
star.mass_g() / msol
285 <<
"Baryon mass in a binary system : " <<
mass_b_extr() / msol
289 ost <<
"Star in a binary system" << endl ;
290 ost <<
"-----------------------" << endl ;
292 if (
star.is_irrotational()) {
293 ost <<
"irrotational configuration" << endl ;
296 ost <<
"corotating configuration" << endl ;
299 ost <<
"Absolute abscidia of the stellar center: "
300 <<
star.get_mp().get_ori_x()/km <<
" km" << endl ;
301 ost <<
"Orientation with respect to the absolute frame : "
302 <<
star.get_mp().get_rot_phi() <<
" rad" << endl ;
304 double r0 = 0.5 * (
star.ray_eq() +
star.ray_eq_pi() ) ;
306 double d_ns =
separ +
star.ray_eq() - r0 ;
308 double d_tilde = d_ns / r0 ;
310 ost << endl <<
"Comparison with those by Baumgarte et al. :" << endl ;
311 ost <<
" Radius r0 : " << r0 / km <<
" km " << endl ;
312 ost <<
" Separation d : " << d_ns / km <<
" km " << endl ;
313 ost <<
" Normalized sep. (d/r0) : " << d_tilde << endl ;
315 ost << endl <<
"Black hole : " ;
316 ost << endl <<
"========== " << endl ;
317 ost <<
"Gravitational mass of BH : "
318 <<
mass_bh / msol <<
" M_sol" << endl ;
330 const Eos* p_eos = &(
star.get_eos() ) ;
333 if (p_eos_poly != 0x0) {
335 double kappa = p_eos_poly->
get_kap() ;
336 double gamma = p_eos_poly->
get_gam() ;
337 double kap_ns2 =
pow( kappa, 0.5 /(gamma-1) ) ;
340 double r_poly = kap_ns2 /
sqrt(ggrav) ;
343 double t_poly = r_poly ;
346 double m_poly = r_poly / ggrav ;
351 double r0 = 0.5 * (
star.ray_eq() +
star.ray_eq_pi() ) ;
353 double d_ns =
separ +
star.ray_eq() - r0 ;
357 ost << endl <<
"Quantities in polytropic units : " ;
358 ost << endl <<
"==============================" << endl ;
359 ost <<
" ( r_poly = " << r_poly / km <<
" km )" << endl ;
360 ost <<
" d_e_max : " <<
separ / r_poly << endl ;
363 ost <<
" d_bh/M_bh : " << d_ns/r_poly / (
mass_bh/m_poly) << endl ;
364 ost <<
" Omega : " <<
omega * t_poly << endl ;
365 ost <<
" Omega M_bh : " <<
omega * t_poly *
mass_bh / m_poly
367 ost <<
" M_bar(NS) : " <<
mass_b_extr() / m_poly << endl ;
368 ost <<
" M_bar(NS_0) : " <<
star.mass_b() / m_poly << endl ;
370 << 0.5 * (
star.ray_eq() +
star.ray_eq_pi()) / r_poly << endl ;
371 ost <<
" M_grv(BH) : " <<
mass_bh / m_poly << endl ;
const Base_vect_cart ref_triad
Cartesian triad of the absolute reference frame.
double * p_ya_barycenter_extr
Absolute coordinate Y of the barycenter of the baryon density in the Kerr-Schild background metric.
double * p_mass_b_extr
Baryon mass of the neutron star in the Kerr-Schild background metric or in the conformally flat one.
double ya_barycenter_extr() const
in the Kerr-Schild background metric
double mass_b_extr() const
Baryon mass of the neutron star in the Kerr-Schild background metric or in the conformally flat.
Et_bin_bhns_extr star
Neutron star.
void operator=(const Bin_bhns_extr &)
Assignment to another Bin_bhns_extr.
Bin_bhns_extr(Map &mp, int nzet, const Eos &eos, bool irrot, bool relat, bool kerrs, bool multi)
Standard constructor.
void set_der_0x0() const
Sets to 0x0 all the pointers on derived quantities.
double separ
Absolute orbital separation between two centers of BH and NS.
friend ostream & operator<<(ostream &, const Bin_bhns_extr &)
Display.
double mass_bh
Gravitational mass of BH.
double xa_barycenter_extr() const
Absolute coordinate X of the barycenter of the baryon density in the Kerr-Schild background metric or...
void display_poly(ostream &) const
Display in polytropic units.
void sauve(FILE *) const
Save in a file.
ostream & operator>>(ostream &) const
Operator >> (function called by the operator <<).
~Bin_bhns_extr()
Destructor.
double omega
Angular velocity with respect to an asymptotically inertial observer.
double * p_xa_barycenter_extr
Absolute coordinate X of the barycenter of the baryon density in the Kerr-Schild background metric or...
void del_deriv() const
Deletes all the derived quantities.
Polytropic equation of state (relativistic case).
double get_gam() const
Returns the adiabatic index (cf. Eq. (3)).
double get_kap() const
Returns the pressure coefficient (cf.
Equation of state base class.
Cmp sqrt(const Cmp &)
Square root.
Cmp pow(const Cmp &, int)
Power .
int fread_be(int *aa, int size, int nb, FILE *fich)
Reads integer(s) from a binary file according to the big endian convention.
int fwrite_be(const int *aa, int size, int nb, FILE *fich)
Writes integer(s) into a binary file according to the big endian convention.
Map(const Mg3d &)
Constructor from a multi-domain 3D grid.
Standard units of space, time and mass.