87 p_lap_alpha[0] = &lap_alpha1 ;
88 p_lap_alpha[1] = &lap_alpha2 ;
89 p_source[0] = &source1 ;
90 p_source[1] = &source2 ;
99 for (
int i=0; i<2; i++) {
107 *(p_lap_alpha[i]) = alpha_auto().laplacien() ;
124 *(p_source[i]) = - qpig * a_car * ener_euler
125 - 0.25 * ( akcar_auto + akcar_comp )
133 Tbl diff =
diffrel( (*(p_lap_alpha[i]))(), (*(p_source[i]))() ) ;
136 "Binaire::ham_constr : relative difference Lap(alpha) <-> source : " 137 << endl << diff << endl ;
177 p_source[0] = &source1 ;
178 p_source[1] = &source2 ;
189 for (
int i=0; i<2; i++) {
223 *(p_source[i]) = 2 * qpig * (ener_euler + press) * u_euler
224 - 5 *
contract(kij_auto, 1, d_alpha, 0) ;
228 Tbl diffx =
diffrel( (*(p_divk[i]))(0), (*(p_source[i]))(0)) ;
229 Tbl diffy =
diffrel( (*(p_divk[i]))(1), (*(p_source[i]))(1)) ;
230 Tbl diffz =
diffrel( (*(p_divk[i]))(2), (*(p_source[i]))(2)) ;
232 cout <<
"Binaire::mom_constr : norme div(K) : " << endl ;
233 cout <<
"X component : " <<
norme( (*(p_divk[i]))(0) ) << endl ;
234 cout <<
"Y component : " <<
norme( (*(p_divk[i]))(1) ) << endl ;
235 cout <<
"Z component : " <<
norme( (*(p_divk[i]))(2) ) << endl ;
237 cout <<
"Binaire::mom_constr : norme source : " << endl ;
238 cout <<
"X component : " <<
norme( (*(p_source[i]))(0) ) << endl ;
239 cout <<
"Y component : " <<
norme( (*(p_source[i]))(1) ) << endl ;
240 cout <<
"Z component : " <<
norme( (*(p_source[i]))(2) ) << endl ;
244 "Binaire::mom_constr : rel. diff. div(K) <-> source : " 246 cout <<
"X component : " << diffx << endl ;
247 cout <<
"Y component : " << diffy << endl ;
248 cout <<
"Z component : " << diffz << endl ;
251 somx +=
max(
abs(diffx) ) ;
252 somy +=
max(
abs(diffy) ) ;
253 somz +=
max(
abs(diffz) ) ;
const Map & get_mp() const
Returns the mapping.
void dec2_dzpuis()
dzpuis -= 2 ;
const Tenseur & get_a_car() const
Returns the total conformal factor .
Etoile_bin star1
First star of the system.
const Tenseur & get_akcar_comp() const
Returns the part of the scalar generated by shift_auto and shift_comp , i.e.
Tbl * p_mom_constr
Relative error on the momentum constraint.
Standard units of space, time and mass.
const Tenseur_sym & get_tkij_auto() const
Returns the part of the extrinsic curvature tensor generated by shift_auto .
double & set(int i)
Read/write of a particular element (index i) (1D case)
const Tenseur & get_d_beta_auto() const
Returns the gradient of beta_auto (Cartesian components with respect to ref_triad ) ...
double * p_ham_constr
Relative error on the Hamiltonian constraint.
Tenseur flat_scalar_prod(const Tenseur &t1, const Tenseur &t2)
Scalar product of two Tenseur when the metric is : performs the contraction of the last index of t1 w...
const Base_vect_cart ref_triad
Cartesian triad of the absolute reference frame.
const Tenseur & get_logn_auto() const
Returns the logarithm of the part of the lapse N generated principaly by the star.
const Tenseur & get_d_logn_auto() const
Returns the gradient of logn_auto (Cartesian components with respect to ref_triad ) ...
Tbl diffrel(const Cmp &a, const Cmp &b)
Relative difference between two Cmp (norme version).
const Tenseur & get_press() const
Returns the fluid pressure.
void set_etat_qcq()
Sets the logical state to ETATQCQ (ordinary state).
const Tbl & mom_constr() const
Estimates the relative error on the momentum constraint equation by comparing ${}_j K^{ij}$ with {equ...
Etoile_bin * et[2]
Array of the two stars (to perform loops on the stars): { et[0]} contains the address of { star1} and...
double ham_constr() const
Estimates the relative error on the Hamiltonian constraint equation by comparing $ A$ with {equation}...
void change_triad(const Base_vect &new_triad)
Sets a new vectorial basis (triad) of decomposition and modifies the components accordingly.
Tbl norme(const Cmp &)
Sums of the absolute values of all the values of the Cmp in each domain.
Tbl max(const Cmp &)
Maximum values of a Cmp in each domain.
Tenseur contract(const Tenseur &, int id1, int id2)
Self contraction of two indices of a Tenseur .
const Tenseur & get_d_beta_comp() const
Returns the gradient of beta_comp (Cartesian components with respect to ref_triad ) ...
const Tenseur & get_ener_euler() const
Returns the total energy density with respect to the Eulerian observer.
const Tenseur & get_d_logn_comp() const
Returns the gradient of logn_comp (Cartesian components with respect to ref_triad ) ...
const Tenseur & get_akcar_auto() const
Returns the part of the scalar generated by shift_auto , i.e.
Cmp abs(const Cmp &)
Absolute value.
const Tenseur & get_u_euler() const
Returns the fluid 3-velocity with respect to the Eulerian observer.
Tensor handling *** DEPRECATED : use class Tensor instead ***.
const Tenseur & get_beta_auto() const
Returns the logarithm of the part of the product AN generated principaly by the star.
const Tenseur & gradient() const
Returns the gradient of *this (Cartesian coordinates)
Etoile_bin star2
Second star of the system.