31char bin_hor_C[] =
"$Header: /cvsroot/Lorene/C++/Source/Bin_hor/bin_hor.C,v 1.12 2014/10/13 08:52:42 j_novak Exp $" ;
90#include "utilitaires.h"
98 hole1(mp1), hole2(mp2), omega(0){
108 hole1(source.hole1), hole2(source.hole2), omega(source.omega) {
179 int bound_psi,
int bound_beta,
double alpha)
const {
192 double mass_ih = mass_ih1 + mass_ih2 ;
201 assert ((orientation1 == 0) || (orientation1 == M_PI)) ;
202 int aligne1 = (orientation1 == 0) ? 1 : -1 ;
210 angular1.
set(1) = aligne1 *
omega * yya1 ;
211 angular1.
set(2) = - aligne1 *
omega * xxa1 ;
225 assert ((orientation2 == 0) || (orientation2 == M_PI)) ;
226 int aligne2 = (orientation2 == 0) ? 1 : -1 ;
234 angular2.
set(1) = aligne2 *
omega * yya2 ;
235 angular2.
set(2) = - aligne2 *
omega * xxa2 ;
274 double J_smarr = (mass_komar - horizon) / 2. /
omega ;
285 ost <<
"# bound N, lim N : " << bound_nn <<
" " << lim_nn
286 <<
" - bound Psi : " << bound_psi <<
" - bound shift : " << bound_beta
287 <<
" alpha = " << alpha << endl ;
289 ost <<
"# distance omega Mass_ADM Mass_K M_area J_ADM J_hor" << endl ;
290 ost << distance <<
" " ;
291 ost <<
omega <<
" " ;
292 ost << mass_adm <<
" " ;
293 ost << mass_komar <<
" " ;
294 ost << mass_area <<
" " ;
295 ost << J_adm <<
" " ;
296 ost << J_hor << endl ;
297 ost <<
"# mass_ih1 mass_ih2 mass_ih j1 J2 omega1 omega2" << endl ;
298 ost << mass_ih1 <<
" " ;
299 ost << mass_ih2 <<
" " ;
300 ost << mass_ih <<
" " ;
303 ost << omega1 <<
" " ;
304 ost << omega2 << endl ;
305 ost <<
"# ADM_mass/M_area J/M_area2 omega*M_area" << endl ;
306 ost << mass_adm / mass_area <<
" " ;
307 ost << J_adm /mass_area / mass_area <<
" " ;
308 ost <<
omega * mass_area << endl ;
309 ost <<
"# Diff J_hor/J_ADM Diff J_ADM/J_Smarr Diff J_hor/J_smarr"
311 ost << fabs(J_adm - J_hor) / J_adm <<
" " << fabs(J_adm - J_smarr) / J_adm
312 <<
" " << fabs(J_hor - J_smarr) / J_hor << endl ;
double omega
Angular velocity.
Single_hor hole1
Black hole one.
Single_hor * holes[2]
Array on the black holes.
Single_hor hole2
Black hole two.
double ang_mom_hor() const
Calculates the angular momentum of the black hole using the formula at the horizon.
void init_bin_hor()
Initialisation of the system.
double adm_mass() const
Calculates the ADM mass of the system.
double ang_mom_adm() const
Calculates the angular momentum of the black hole.
void sauve(FILE *fich) const
Total or partial saves in a binary file.
double komar_mass() const
Calculates the Komar mass of the system using : .
void decouple()
Calculates decouple which is used to obtain tkij_auto and tkij_comp.
void operator=(const Bin_hor &)
Affectation operator.
Bin_hor(Map_af &mp1, Map_af &mp2)
Standard constructor.
virtual ~Bin_hor()
Destructor.
void set_omega(double ome)
Sets the orbital velocity to ome.
void write_global(ostream &, double lim_nn, int bound_nn, int bound_psi, int bound_beta, double alpha) const
Write global quantities in a formatted file.
void extrinsic_curvature()
Calculation of the extrinsic curvature tensor.
double integrale_surface(const Cmp &ci, double rayon) const
Performs the surface integration of ci on the sphere of radius rayon .
virtual double val_r(int l, double xi, double theta, double pphi) const
Returns the value of the radial coordinate r for a given in a given domain.
const Base_vect_cart & get_bvect_cart() const
Returns the Cartesian basis associated with the coordinates (x,y,z) of the mapping,...
Coord ya
Absolute y coordinate.
const Base_vect_spher & get_bvect_spher() const
Returns the orthonormal vectorial basis associated with the coordinates of the mapping.
double get_ori_x() const
Returns the x coordinate of the origin.
double get_rot_phi() const
Returns the angle between the x –axis and X –axis.
Coord xa
Absolute x coordinate.
const Mg3d * get_mg() const
Gives the Mg3d on which the mapping is defined.
virtual const Vector & radial_vect() const
Returns the radial vector normal to a spherical slicing and pointing toward spatial infinity.
int get_np(int l) const
Returns the number of points in the azimuthal direction ( ) in domain no. l.
int get_nt(int l) const
Returns the number of points in the co-latitude direction ( ) in domain no. l.
int get_nzone() const
Returns the number of domains.
int get_nr(int l) const
Returns the number of points in the radial direction ( ) in domain no. l.
Base_val ** std_base_vect_cart() const
Returns the standard spectral bases for the Cartesian components of a vector.
Tensor field of valence 0 (or component of a tensorial field).
const Vector & derive_cov(const Metric &gam) const
Returns the gradient (1-form = covariant vector) of *this
Valeur & set_spectral_va()
Returns va (read/write version)
void annule_hard()
Sets the Scalar to zero in a hard way.
double mass_hor() const
Mass computed at the horizon
const Sym_tensor & get_k_dd() const
k_dd
Metric_flat ff
3 metric flat
Scalar psi
Conformal factor .
Map_af & mp
Affine mapping.
double area_hor() const
Area of the horizon.
void init_bhole()
Sets the values of the fields to :
const Map_af & get_mp() const
Returns the mapping (readonly).
double ang_mom_hor() const
Angular momentum (modulo)
double omega_hor() const
Orbital velocity
virtual void sauve(FILE *fich) const
Total or partial saves in a binary file.
double get_radius() const
Returns the radius of the horizon.
void n_comp_import(const Single_hor &comp)
Imports the part of N due to the companion hole comp .
Scalar nn
Lapse function .
const Scalar b_tilde() const
Radial component of the shift with respect to the conformal metric.
void psi_comp_import(const Single_hor &comp)
Imports the part of due to the companion hole comp .
Metric tgam
3 metric tilde
void set_base(const Base_val &)
Sets the bases for spectral expansions (member base )
Tensor field of valence 1.
virtual void std_spectral_base()
Sets the standard spectal bases of decomposition for each component.
virtual void change_triad(const Base_vect &)
Sets a new vectorial basis (triad) of decomposition and modifies the components accordingly.
Scalar & set(int)
Read/write access to a component.
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.
Tensor up_down(const Metric &gam) const
Computes a new tensor by raising or lowering all the indices of *this .
Tenseur contract(const Tenseur &, int id1, int id2)
Self contraction of two indices of a Tenseur .