28char blackhole_C[] =
"$Header: /cvsroot/Lorene/C++/Source/Black_hole/blackhole.C,v 1.5 2014/10/13 08:52:45 j_novak Exp $" ;
61#include "utilitaires.h"
73 kerrschild(kerrschild_i),
79 shift(mp_i, CON, mp_i.get_bvect_cart()),
80 shift_rs(mp_i, CON, mp_i.get_bvect_cart()),
81 shift_bh(mp_i, CON, mp_i.get_bvect_cart()),
83 taij(mp_i, CON, mp_i.get_bvect_cart()),
84 taij_rs(mp_i, CON, mp_i.get_bvect_cart()),
87 flat(mp_i, mp_i.get_bvect_cart()) {
120 kerrschild(bh.kerrschild),
123 lapconf_rs(bh.lapconf_rs),
124 lapconf_bh(bh.lapconf_bh),
127 shift_rs(bh.shift_rs),
128 shift_bh(bh.shift_bh),
132 taij_quad(bh.taij_quad),
133 taij_quad_rs(bh.taij_quad_rs),
145 lapconf_rs(mp_i, *(mp_i.get_mg()), fich),
148 shift(mp_i, CON, mp_i.get_bvect_cart()),
149 shift_rs(mp_i, mp_i.get_bvect_cart(), fich),
150 shift_bh(mp_i, CON, mp_i.get_bvect_cart()),
151 confo(mp_i, *(mp_i.get_mg()), fich),
152 taij(mp_i, CON, mp_i.get_bvect_cart()),
153 taij_rs(mp_i, CON, mp_i.get_bvect_cart()),
156 flat(mp_i, mp_i.get_bvect_cart()) {
161 fread(&
mass_bh,
sizeof(
double), 1, fich) ;
238 assert( &(bh.
mp) == &
mp ) ;
274 fwrite(&
mass_bh,
sizeof(
double), 1, fich) ;
296 ost <<
"Kerr-Schild background" << endl ;
297 ost <<
"----------------------" << endl ;
300 ost <<
"Conformally flat background" << endl ;
301 ost <<
"---------------------------" << endl ;
304 ost <<
"lapconf on the AH : "
306 ost <<
"lapse on the AH : "
308 ost <<
"shift(1) on the AH : "
309 <<
shift(1).val_grid_point(1,0,nt-1,0) << endl ;
310 ost <<
"shift(2) on the AH : "
311 <<
shift(2).val_grid_point(1,0,nt-1,0) << endl ;
312 ost <<
"shift(3) on the AH : "
313 <<
shift(3).val_grid_point(1,0,nt-1,0) << endl ;
314 ost <<
"confo on the AH : "
316 ost <<
"Gravitational mass : "
317 <<
mass_bh / msol <<
" M_sol" << endl ;
318 ost <<
"Irreducible mass : "
319 <<
mass_irr() / msol <<
" M_sol" << endl ;
321 <<
mass_adm() / msol <<
" M_sol" << endl ;
322 ost <<
"Komar mass : "
323 <<
mass_kom() / msol <<
" M_sol" << endl ;
325 double irr_gm, adm_gm, kom_gm ;
329 ost <<
"Diff. (Mirr-Mg)/Mg : " << irr_gm << endl ;
330 ost <<
"Diff. (Madm-Mg)/Mg : " << adm_gm << endl ;
331 ost <<
"Diff. (Mkom-Mg)/Mg : " << kom_gm << endl ;
Base class for black holes.
Vector shift_bh
Part of the shift vector from the analytic background.
virtual double mass_kom() const
Komar mass.
Vector shift_rs
Part of the shift vector from the numerical computation.
Black_hole(Map &mp_i, bool Kerr_schild, double massbh)
Standard constructor.
Scalar taij_quad
Part of the scalar generated by .
Scalar taij_quad_rs
Part of the scalar.
Sym_tensor taij
Trace of the extrinsic curvature.
virtual double mass_irr() const
Irreducible mass of the black hole.
double * p_spin_am_bh
Radius of the apparent horizon.
Sym_tensor taij_rs
Part of the extrinsic curvature tensor.
Map & mp
Mapping associated with the black hole.
Scalar lapconf
A function (lapse function * conformal factor) lapconf generated by the black hole.
Vector shift
Shift vector generated by the black hole.
Metric_flat flat
Flat metric defined on the mapping (Spherical components with respect to the mapping of the black hol...
Scalar lapconf_rs
Part of lapconf from the numerical computation.
void set_der_0x0() const
Sets to 0x0 all the pointers on derived quantities.
Tbl * p_angu_mom_bh
Spin angular momentum.
virtual ~Black_hole()
Destructor.
virtual double mass_adm() const
ADM mass.
double * p_rad_ah
Komar mass.
virtual void sauve(FILE *) const
Save in a file.
Scalar lapconf_bh
Part of lapconf from the analytic background.
double * p_mass_kom
ADM mass.
void operator=(const Black_hole &)
Assignment to another Black_hole.
Scalar lapse
Lapse function generated by the black hole.
bool kerrschild
true for a Kerr-Schild background, false for a conformally flat background
Scalar confo
Conformal factor generated by the black hole.
double mass_bh
Gravitational mass of BH.
double * p_mass_adm
Irreducible mass of the black hole.
virtual ostream & operator>>(ostream &) const
Operator >> (virtual function called by the operator <<)
double * p_mass_irr
Conformal metric .
virtual void del_deriv() const
Deletes all the derived quantities.
Base class for coordinate mappings.
const Mg3d * get_mg() const
Gives the Mg3d on which the mapping is defined.
int get_nt(int l) const
Returns the number of points in the co-latitude direction ( ) in domain no. l.
virtual void sauve(FILE *) const
Save in a file.
virtual void std_spectral_base()
Sets the spectral bases of the Valeur va to the standard ones for a scalar field.
double val_grid_point(int l, int k, int j, int i) const
Returns the value of the field at a specified grid point.
virtual void std_spectral_base()
Sets the standard spectal bases of decomposition for each component.
virtual void sauve(FILE *) const
Save in a binary file.
virtual void set_etat_zero()
Sets the logical state of all components to ETATZERO (zero state).
Standard units of space, time and mass.