30char bhole_C[] =
"$Header: /cvsroot/Lorene/C++/Source/Bhole/bhole.C,v 1.15 2014/10/13 08:52:39 j_novak Exp $" ;
171#include "utilitaires.h"
172#include "et_bin_nsbh.h"
173#include "graphique.h"
178 rayon ((mp.get_alpha())[0]),
179 omega(0), omega_local(0), rot_state(COROT), boost (new double[3]), regul(0),
180 n_auto(mpi), n_comp(mpi), n_tot(mpi),
181 psi_auto(mpi), psi_comp(mpi), psi_tot(mpi),
182 grad_n_tot (mpi, 1, COV, mpi.get_bvect_cart()),
183 grad_psi_tot (mpi, 1, COV, mpi.get_bvect_cart()),
184 shift_auto(mpi, 1, CON, mpi.get_bvect_cart()),
185 taij_auto(mpi, 2, CON, mpi.get_bvect_cart()),
186 taij_comp(mpi, 2, CON, mpi.get_bvect_cart()),
187 taij_tot (mpi, 2, CON, mpi.get_bvect_cart()),
188 tkij_auto (mpi, 2, CON, mpi.get_bvect_cart()),
189 tkij_tot (mpi, 2, CON, mpi.get_bvect_cart()),
191 for (
int i=0 ; i<3 ; i++)
198 mp(source.mp), rayon(source.rayon), omega (source.omega), omega_local(source.omega_local), rot_state(source.rot_state),
199 boost (new double [3]), regul(source.regul), n_auto(source.n_auto),
200 n_comp(source.n_comp), n_tot(source.n_tot), psi_auto(source.psi_auto),
201 psi_comp(source.psi_comp), psi_tot(source.psi_tot),
202 grad_n_tot (source.grad_n_tot), grad_psi_tot (source.grad_psi_tot),
203 shift_auto(source.shift_auto),
204 taij_auto (source.taij_auto),
205 taij_comp(source.taij_comp), taij_tot(source.taij_tot),
206 tkij_auto(source.tkij_auto), tkij_tot(source.tkij_tot), decouple(source.decouple) {
208 for (
int i=0 ; i<3 ; i++)
220 assert (&
mp == &source.
mp) ;
226 for (
int i=0 ; i<3 ; i++)
386 trace = grad(0, 0)+grad(1, 1)+grad(2, 2) ;
390 for (
int i=0 ; i<3 ; i++) {
391 for (
int j=i+1 ; j<3 ; j++)
396 for (
int i=0 ; i<3 ; i++)
397 for (
int j=0 ; j<3 ; j++)
497 mp(mpi), rayon ((mp.get_alpha())[0]),
498 boost (new double[3]), n_auto(mpi), n_comp(mpi), n_tot(mpi),
499 psi_auto(mpi), psi_comp(mpi), psi_tot(mpi),
500 grad_n_tot (mpi, 1, COV, mpi.get_bvect_cart()),
501 grad_psi_tot (mpi, 1, COV, mpi.get_bvect_cart()),
502 shift_auto(mpi, 1, CON, mpi.get_bvect_cart()),
503 taij_auto(mpi, 2, CON, mpi.get_bvect_cart()),
504 taij_comp(mpi, 2, CON, mpi.get_bvect_cart()),
505 taij_tot (mpi, 2, CON, mpi.get_bvect_cart()),
506 tkij_auto (mpi, 2, CON, mpi.get_bvect_cart()) ,
507 tkij_tot (mpi, 2, CON, mpi.get_bvect_cart()) ,
560double Bhole::local_momentum()
const {
571 vecteur.set_etat_qcq() ;
572 for (
int i=0 ; i<3 ; i++)
574 vecteur.set_std_base() ;
579 integrant.std_base_scal() ;
Tenseur psi_auto
Part of generated by the hole.
Tenseur shift_auto
Part of generated by the hole.
double omega_local
local angular velocity
Tenseur psi_comp
Part of generated by the companion hole.
Tenseur_sym tkij_auto
Auto .
double omega
Angular velocity in LORENE's units.
Tenseur grad_psi_tot
Total gradient of .
double regul
Intensity of the correction on the shift vector.
Tenseur_sym taij_auto
Part of generated by the hole.
int rot_state
State of rotation.
Tenseur grad_n_tot
Total gradient of N .
Tenseur n_auto
Part of N generated by the hole.
Tenseur_sym taij_comp
Part of generated by the companion hole.
void init_bhole()
Sets the values of the fields to :
double * boost
Lapse on the horizon.
double rayon
Radius of the horizon in LORENE's units.
void init_bhole_seul()
Initiates for a single the black hole.
double area() const
Computes the area of the throat.
Tenseur n_comp
Part of N generated by the companion hole.
Map_af & mp
Affine mapping.
Tenseur_sym taij_tot
Total , which must be zero on the horizon of the regularisation on the shift has been done.
void sauve(FILE *fich) const
Write on a file.
void fait_psi_comp(const Bhole &comp)
Imports the part of due to the companion hole comp .
Bhole(Map_af &mapping)
Standard constructor.
Tenseur_sym tkij_tot
Total .
void fait_taij_auto()
Calculates the part of generated by shift_auto .
void fait_n_comp(const Bhole &comp)
Imports the part of N due to the companion hole comp .
void operator=(const Bhole &)
Affectation.
Cmp decouple
Function used to construct the part of generated by the hole from the total .
void regularise_shift(const Tenseur &comp)
Corrects shift_auto in such a way that the total is equal to zero in the horizon,...
Component of a tensorial field *** DEPRECATED : use class Scalar instead ***.
void import(const Cmp &ci)
Assignment to another Cmp defined on a different mapping.
void std_base_scal()
Sets the spectral bases of the Valeur va to the standard ones for a scalar.
void annule(int l)
Sets the Cmp to zero in a given domain.
void set_etat_zero()
Sets the logical state to ETATZERO (zero).
void set_dzpuis(int)
Set a value to dzpuis.
void import_symy(const Cmp &ci)
Assignment to another Cmp defined on a different mapping.
void set_val_inf(double val)
Sets the value of the Cmp to val at infinity.
void raccord(int n)
Performs the matching of the nucleus with respect to the first shell.
void import_asymy(const Cmp &ci)
Assignment to another Cmp defined on a different mapping.
Class for a star in a NS-BH binary system.
const Tenseur & get_d_n_auto() const
Returns the gradient of {\tt n_auto} (Cartesian components with respect to {\tt ref_triad})
const Tenseur & get_confpsi_auto() const
Returns the part of the conformal factor $\Psi$ generated principaly by the star.
const Tenseur & get_n_auto() const
Returns the part of the lapse {\it N} generated principaly by the star.
const Tenseur & get_d_confpsi_auto() const
Returns the gradient of {\tt confpsi_auto} (Cartesian components with respect to {\tt ref_triad})
double integrale_surface(const Cmp &ci, double rayon) const
Performs the surface integration of ci on the sphere of radius rayon .
const Base_vect_cart & get_bvect_cart() const
Returns the Cartesian basis associated with the coordinates (x,y,z) of the mapping,...
Coord y
y coordinate centered on the grid
Coord r
r coordinate centered on the grid
const Base_vect_spher & get_bvect_spher() const
Returns the orthonormal vectorial basis associated with the coordinates of the mapping.
Coord x
x coordinate centered on the grid
const Mg3d * get_mg() const
Gives the Mg3d on which the mapping is defined.
int get_nzone() const
Returns the number of domains.
Tensor handling *** DEPRECATED : use class Tensor instead ***.
const Base_vect * get_triad() const
Returns the vectorial basis (triad) on which the components are defined.
Cmp & set()
Read/write for a scalar (see also operator=(const Cmp&) ).
void sauve(FILE *) const
Save in a file.
void set_etat_qcq()
Sets the logical state to ETATQCQ (ordinary state).
void dec2_dzpuis()
dzpuis -= 2 ;
const Tenseur & gradient() const
Returns the gradient of *this (Cartesian coordinates)
void set_std_base()
Set the standard spectal basis of decomposition for each component.
void set_etat_zero()
Sets the logical state to ETATZERO (zero state).
void inc2_dzpuis()
dzpuis += 2 ;
void change_triad(const Base_vect &new_triad)
Sets a new vectorial basis (triad) of decomposition and modifies the components accordingly.
void set_triad(const Base_vect &new_triad)
Assigns a new vectorial basis (triad) of decomposition.
int get_etat() const
Returns the logical state.
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.