28char altBH_QI_C[] =
"$Header: /cvsroot/Lorene/C++/Source/Compobj/altBH_QI.C,v 1.5 2014/10/13 08:52:49 j_novak Exp $" ;
75 ifstream file(file_name) ;
77 cerr <<
"Problem in opening the file " << file_name << endl ;
90 const Mg3d* mg =
mp.get_mg() ;
92 file.ignore(1000,
'\n') ;
93 file.ignore(1000,
'\n') ;
95 cout <<
"nz : " << nz << endl ;
96 a_car.set_etat_qcq() ;
99 krphi.allocate_all() ;
101 for (
int l=1; l<nz; l++) {
102 cout <<
"l = " << l << endl ;
106 double* r_iso =
new double[nr] ;
107 double* r_areal =
new double[nr] ;
108 double* psi4 =
new double[nr] ;
109 double* alpha =
new double[nr] ;
110 double* Krphi =
new double[nr] ;
111 double* beta_phi =
new double[nr] ;
115 r_areal[nr-1] = __infinity ;
116 r_iso[nr-1] = __infinity ;
122 for (
int i=0; i<nr_max; i++) {
130 file >> beta_phi[i] ;
131 cout <<
"r_iso, psi4, beta_phi : " << r_iso[i] <<
" " << psi4[i] <<
" " << beta_phi[i] << endl ;
134 if (l==1) r_inner = r_iso[0] ;
136 for (
int k=0; k<np; k++) {
137 for (
int j=0; j<nt; j++) {
138 for (
int i=0; i<nr; i++) {
139 a_car.set_grid_point(l,k,j,i) = psi4[i] ;
140 nn.set_grid_point(l,k,j,i) = alpha[i] ;
141 nphi.set_grid_point(l,k,j,i) = -
a_spin * beta_phi[i] / psi4[i] / (r_iso[i]*r_iso[i]) ;
142 krphi.set_grid_point(l,k,j,i) =
a_spin * Krphi[i] / r_iso[i] ;
149 mp.homothetie(r_inner /
mp.val_r(1,-1.,0.,0.)) ;
154 a_car.std_spectral_base() ;
155 nn.std_spectral_base() ;
156 nphi.std_spectral_base() ;
157 krphi.std_spectral_base() ;
161 bbb.std_spectral_base() ;
254 ost << endl <<
"Alternative black hole spacetime in quasi-isotropic coordinates (class AltBH_QI) " << endl ;
273 if ( (
mp.get_mg())->get_np(0) == 1) {
char description2[256]
String describing the model.
void operator=(const AltBH_QI &)
Assignment to another AltBH_QI.
AltBH_QI(Map &mp_i, const char *file_name, double a_spin_i)
Standard constructor.
virtual ~AltBH_QI()
Destructor.
char description1[256]
String describing the model.
virtual void del_deriv() const
Deletes all the derived quantities.
Scalar krphi
K_{(r)(phi)} read in the file.
virtual ostream & operator>>(ostream &) const
Operator >> (virtual function called by the operator <<).
double a_spin
Spin parameter of the model.
virtual void set_der_0x0() const
Sets to 0x0 all the pointers on derived quantities.
virtual void extrinsic_curvature()
Computation of the extrinsic curvature.
virtual void sauve(FILE *) const
Save in a file.
void operator=(const Compobj_QI &)
Assignment to another Compobj_QI.
Scalar nphi
Metric coefficient .
virtual void del_deriv() const
Deletes all the derived quantities.
Compobj_QI(Map &map_i)
Standard constructor.
virtual ostream & operator>>(ostream &) const
Operator >> (virtual function called by the operator <<).
Scalar b_car
Square of the metric factor B.
Scalar bbb
Metric factor B.
Scalar a_car
Square of the metric factor A.
Sym_tensor kk
Extrinsic curvature tensor .
Scalar nn
Lapse function N .
virtual void extrinsic_curvature()
Computation of the extrinsic curvature.
Map & mp
Mapping describing the coordinate system (r,theta,phi).
Base class for pure radial mappings.
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.
Tensor field of valence 0 (or component of a tensorial field).
void mult_sint()
Multiplication by .
Cmp sqrt(const Cmp &)
Square root.
Map(const Mg3d &)
Constructor from a multi-domain 3D grid.
Standard units of space, time and mass.