146 #include "isol_hor.h" 149 #include "graphique.h" 152 #include "utilitaires.h" 156 void Isol_hor::init_data(
int bound_nn,
double lim_nn,
int bound_psi,
157 int bound_beta,
int solve_lapse,
int solve_psi,
158 int solve_shift,
double precis,
159 double relax_nn,
double relax_psi,
double relax_beta,
int niter) {
167 ofstream conv(
"resconv.d") ;
168 ofstream kss(
"kss.d") ;
169 conv <<
" # diff_nn diff_psi diff_beta " << endl ;
178 for (
int mer=0; mer<niter; mer++) {
187 double relax_init = 0.05 ;
188 double relax_speed = 0.005 ;
190 double corr = 1 - (1 - relax_init) *
exp (- relax_speed * mer) ;
196 cout <<
"nn = " << mer <<
" corr = " << corr << endl ;
200 cout <<
" relax_nn = " << relax_nn << endl ;
201 cout <<
" relax_psi = " << relax_psi << endl ;
202 cout <<
" relax_beta = " << relax_beta << endl ;
207 if (solve_lapse == 1) {
208 Valeur nn_bound (
mp.
get_mg()-> get_angu()) ;
214 nn_jp1 = sou_nn.poisson_dirichlet(nn_bound, 0) + 1. ;
219 nn_jp1 = sou_nn.poisson_neumann(nn_bound, 0) + 1. ;
224 nn_jp1 = sou_nn.poisson_dirichlet(nn_bound, 0) + 1. ;
229 nn_jp1 = sou_nn.poisson_neumann(nn_bound, 0) + 1. ;
234 nn_jp1 = sou_nn.poisson_dirichlet(nn_bound, 0) + 1. ;
239 nn_jp1 = sou_nn.poisson_dirichlet(nn_bound, 0) + 1. ;
244 nn_jp1 = sou_nn.poisson_neumann(nn_bound, 0) + 1. ;
252 cout <<
"Unexpected type of boundary conditions for the lapse!" 254 <<
" bound_nn = " << bound_nn << endl ;
262 maxabs(nn_jp1.laplacian() - sou_nn,
263 "Absolute error in the resolution of the equation for N") ;
269 nn_jp1 = relax_nn * nn_jp1 + (1 - relax_nn) *
nn() ;
277 Scalar psi_jp1 (
mp) ;
278 if (solve_psi == 1) {
279 Valeur psi_bound (
mp.
get_mg()-> get_angu()) ;
285 psi_jp1 = sou_psi.poisson_neumann(psi_bound, 0) + 1. ;
290 psi_jp1 = sou_psi.poisson_neumann(psi_bound, 0) + 1. ;
295 psi_jp1 = sou_psi.poisson_dirichlet(psi_bound, 0) + 1. ;
300 psi_jp1 = sou_psi.poisson_neumann(psi_bound, 0) + 1. ;
305 psi_jp1 = sou_psi.poisson_dirichlet(psi_bound, 0) + 1. ;
310 psi_jp1 = sou_psi.poisson_dirichlet(psi_bound, 0) + 1. ;
314 cout <<
"Unexpected type of boundary conditions for psi!" 316 <<
" bound_psi = " << bound_psi << endl ;
324 maxabs(psi_jp1.laplacian() - sou_psi,
325 "Absolute error in the resolution of the equation for Psi") ;
327 psi_jp1 = relax_psi * psi_jp1 + (1 - relax_psi) *
psi() ;
335 Vector beta_jp1(
beta()) ;
337 if (solve_shift == 1) {
343 source_vector = source_vector + source_reg ;
351 Valeur boundary_x (
mp.
get_mg()-> get_angu()) ;
352 Valeur boundary_y (
mp.
get_mg()-> get_angu()) ;
353 Valeur boundary_z (
mp.
get_mg()-> get_angu()) ;
355 switch (bound_beta) {
370 cout <<
"Unexpected type of boundary conditions for psi!" 372 <<
" bound_psi = " << bound_psi << endl ;
386 double precision = 1e-8 ;
387 poisson_vect_boundary(lambda, source_vector, beta_jp1, boundary_x,
388 boundary_y, boundary_z, 0, precision, 20) ;
442 source_vector.dec_dzpuis() ;
444 + lambda * beta_jp1.divergence(
ff)
445 .derive_con(
ff) - source_vector,
446 "Absolute error in the resolution of the equation for beta") ;
456 boost_vect.set(2) = 0. ;
457 boost_vect.set(3) = 0. ;
458 boost_vect.std_spectral_base() ;
460 beta_jp1 = beta_jp1 + boost_vect ;
465 boost_vect.set(2) = 0. ;
466 boost_vect.set(3) = 0. ;
467 boost_vect.std_spectral_base() ;
469 beta_jp1 = beta_jp1 + boost_vect ;
473 beta_jp1 = relax_beta * beta_jp1 + (1 - relax_beta) *
beta() ;
480 double diff_nn, diff_psi, diff_beta ;
484 if (solve_lapse == 1)
488 if (solve_shift == 1)
491 cout <<
"step = " << mer <<
" : diff_psi = " << diff_psi
492 <<
" diff_nn = " << diff_nn
493 <<
" diff_beta = " << diff_beta << endl ;
494 cout <<
"----------------------------------------------" << endl ;
495 if ((diff_psi<precis) && (diff_nn<precis) && (diff_beta<precis))
498 if (mer>0) {conv << mer <<
" " <<
log10(diff_nn) <<
" " <<
log10(diff_psi)
499 <<
" " <<
log10(diff_beta) << endl ; } ;
508 if (solve_lapse == 1)
510 if (solve_shift == 1)
513 if (solve_shift == 1)
520 gam().radial_vect(), 0, 1)) ;
521 double max_kss = kkss.val_grid_point(1, 0, 0, 0) ;
522 double min_kss = kkss.val_grid_point(1, 0, 0, 0) ;
524 Scalar aaLss (
pow(
psi(), 6) * kkss) ;
525 double max_aaLss = aaLss.val_grid_point(1, 0, 0, 0) ;
526 double min_aaLss = aaLss.val_grid_point(1, 0, 0, 0) ;
529 double max_hh_tilde = hh_tilde.val_grid_point(1, 0, 0, 0) ;
530 double min_hh_tilde = hh_tilde.val_grid_point(1, 0, 0, 0) ;
535 for (
int k=0 ; k<nnp ; k++)
536 for (
int j=0 ; j<nnt ; j++){
537 if (kkss.val_grid_point(1, k, j, 0) > max_kss)
538 max_kss = kkss.val_grid_point(1, k, j, 0) ;
539 if (kkss.val_grid_point(1, k, j, 0) < min_kss)
540 min_kss = kkss.val_grid_point(1, k, j, 0) ;
542 if (aaLss.val_grid_point(1, k, j, 0) > max_aaLss)
543 max_aaLss = aaLss.val_grid_point(1, k, j, 0) ;
544 if (aaLss.val_grid_point(1, k, j, 0) < min_aaLss)
545 min_aaLss = aaLss.val_grid_point(1, k, j, 0) ;
547 if (hh_tilde.val_grid_point(1, k, j, 0) > max_hh_tilde)
548 max_hh_tilde = hh_tilde.val_grid_point(1, k, j, 0) ;
549 if (hh_tilde.val_grid_point(1, k, j, 0) < min_hh_tilde)
550 min_hh_tilde = hh_tilde.val_grid_point(1, k, j, 0) ;
555 kss << mer <<
" " << max_kss <<
" " << min_kss <<
" " << max_aaLss <<
" " << min_aaLss
556 <<
" " << -1 * max_hh_tilde <<
" " << -1 * min_hh_tilde << endl ;
925 void Isol_hor::init_data_spher(
int bound_nn,
double lim_nn,
int bound_psi,
926 int bound_beta,
int solve_lapse,
int solve_psi,
927 int solve_shift,
double precis,
928 double relax,
int niter) {
936 ofstream conv(
"resconv.d") ;
937 ofstream kss(
"kss.d") ;
938 conv <<
" # diff_nn diff_psi diff_beta " << endl ;
942 for (
int mer=0; mer<niter; mer++) {
957 Vector tem_vect (
beta() ) ;
962 Scalar dbdr (
b_tilde().dsdr() ) ;
972 Scalar psisr (
psi()) ;
974 psisr.inc_dzpuis(2) ;
980 Scalar source_psi_spher(
mp) ;
981 source_psi_spher = -1./12. *
psi4()*
psi()/(
nn() *
nn()) * (dbdr - bsr) * (dbdr - bsr) ;
985 Scalar source_nn_spher(
mp) ;
986 source_nn_spher = 2./3. *
psi4() /
nn() * (dbdr - bsr) * (dbdr - bsr)
991 Scalar source_btilde_spher(
mp) ;
993 Scalar tmp ( -1./3. * (dbdr + 2 * bsr).dsdr() ) ;
994 tmp.std_spectral_base() ;
997 source_btilde_spher = tmp + 2 * bsr2
1000 Scalar source_btilde_trun(
mp) ;
1002 source_btilde_trun = tmp +
1019 sourcebeta -= source_reg ;
1020 Scalar source_btilde (sourcebeta(1) ) ;
1024 Scalar mag_sou_psi ( source_psi_spher ) ;
1025 mag_sou_psi.dec_dzpuis(4) ;
1026 Scalar mag_sou_nn ( source_nn_spher ) ;
1027 mag_sou_nn.dec_dzpuis(4) ;
1028 Scalar mag_sou_btilde ( source_btilde_trun ) ;
1029 mag_sou_btilde.dec_dzpuis(4) ;
1031 Scalar diff_sou_psi ( source_psi_spher - sourcepsi) ;
1032 diff_sou_psi.dec_dzpuis(4) ;
1033 Scalar diff_sou_nn ( source_nn_spher - sourcenn) ;
1034 diff_sou_nn.dec_dzpuis(4) ;
1035 Scalar diff_sou_btilde ( source_btilde_trun - source_btilde) ;
1036 diff_sou_btilde.dec_dzpuis(4) ;
1057 bound_nn = 1 ; lim_nn = 1. ; bound_psi = 1 ; bound_beta = 1 ;
1059 double kappa_0 = 0.2 - 1. ;
1063 kappa.std_spectral_base() ;
1064 kappa.inc_dzpuis(2) ;
1071 Valeur psi_bound (
mp.
get_mg()-> get_angu()) ;
1072 Valeur nn_bound (
mp.
get_mg()-> get_angu()) ;
1073 Valeur btilde_bound (
mp.
get_mg()-> get_angu()) ;
1078 Scalar tmp_psi = -1./4. * (2 * psisr +
1079 2./3. *
psi4()/(
psi() *
nn()) * (dbdr - bsr) ) ;
1081 Scalar tmp_nn = kappa ;
1083 Scalar tmp_btilde =
nn() / (
psi() *
psi()) ;
1086 for (
int k=0 ; k<nnp ; k++)
1087 for (
int j=0 ; j<nnt ; j++){
1089 nn_bound.set(0, k, j, 0) = tmp_nn.val_grid_point(1, k, j, 0) ;
1090 btilde_bound.set(0, k, j, 0) = tmp_btilde.val_grid_point(1, k, j, 0) ;
1093 psi_bound.std_base_scal() ;
1094 nn_bound.std_base_scal() ;
1095 btilde_bound.std_base_scal() ;
1104 Scalar psi_jp1 (
mp) ;
1105 if (solve_psi == 1) {
1107 psi_jp1 = source_psi_spher.poisson_neumann(psi_bound, 0) + 1. ;
1110 maxabs(psi_jp1.laplacian() - source_psi_spher,
1111 "Absolute error in the resolution of the equation for Psi") ;
1113 psi_jp1 = relax * psi_jp1 + (1 - relax) *
psi() ;
1118 Scalar nn_jp1 (
mp) ;
1119 if (solve_lapse == 1) {
1121 nn_jp1 = source_nn_spher.poisson_dirichlet(nn_bound, 0) + 1. ;
1124 maxabs(nn_jp1.laplacian() - source_nn_spher,
1125 "Absolute error in the resolution of the equation for N") ;
1131 nn_jp1 = relax * nn_jp1 + (1 - relax) *
nn() ;
1137 Scalar btilde_jp1 (
mp) ;
1138 if (solve_shift == 1) {
1140 btilde_jp1 = source_btilde_spher.poisson_dirichlet(btilde_bound, 0) ;
1143 maxabs(btilde_jp1.laplacian() - source_btilde_spher,
1144 "Absolute error in the resolution of the equation for btilde") ;
1146 btilde_jp1 = relax * btilde_jp1 + (1 - relax) *
b_tilde() ;
1154 double diff_nn, diff_psi, diff_btilde ;
1157 diff_btilde = 1.e-16 ;
1158 if (solve_lapse == 1)
1162 if (solve_shift == 1)
1165 cout <<
"step = " << mer <<
" : diff_psi = " << diff_psi
1166 <<
" diff_nn = " << diff_nn
1167 <<
" diff_btilde = " << diff_btilde << endl ;
1168 cout <<
"----------------------------------------------" << endl ;
1169 if ((diff_psi<precis) && (diff_nn<precis) && (diff_btilde<precis))
1172 if (mer>0) {conv << mer <<
" " <<
log10(diff_nn) <<
" " <<
log10(diff_psi)
1173 <<
" " <<
log10(diff_btilde) << endl ; } ;
1182 if (solve_lapse == 1)
1184 if (solve_shift == 1)
1186 Vector beta_jp1 (btilde_jp1 *
tgam().radial_vect()) ;
1190 if (solve_shift == 1 || solve_lapse == 1)
1199 gam().radial_vect(), 0, 1)) ;
1200 double max_kss = kkss.val_grid_point(1, 0, 0, 0) ;
1201 double min_kss = kkss.val_grid_point(1, 0, 0, 0) ;
1203 Scalar aaLss (
pow(
psi(), 6) * kkss) ;
1204 double max_aaLss = aaLss.val_grid_point(1, 0, 0, 0) ;
1205 double min_aaLss = aaLss.val_grid_point(1, 0, 0, 0) ;
1208 double max_hh_tilde = hh_tilde.val_grid_point(1, 0, 0, 0) ;
1209 double min_hh_tilde = hh_tilde.val_grid_point(1, 0, 0, 0) ;
1213 for (
int k=0 ; k<nnp ; k++)
1214 for (
int j=0 ; j<nnt ; j++){
1215 if (kkss.val_grid_point(1, k, j, 0) > max_kss)
1216 max_kss = kkss.val_grid_point(1, k, j, 0) ;
1217 if (kkss.val_grid_point(1, k, j, 0) < min_kss)
1218 min_kss = kkss.val_grid_point(1, k, j, 0) ;
1220 if (aaLss.val_grid_point(1, k, j, 0) > max_aaLss)
1221 max_aaLss = aaLss.val_grid_point(1, k, j, 0) ;
1222 if (aaLss.val_grid_point(1, k, j, 0) < min_aaLss)
1223 min_aaLss = aaLss.val_grid_point(1, k, j, 0) ;
1225 if (hh_tilde.val_grid_point(1, k, j, 0) > max_hh_tilde)
1226 max_hh_tilde = hh_tilde.val_grid_point(1, k, j, 0) ;
1227 if (hh_tilde.val_grid_point(1, k, j, 0) < min_hh_tilde)
1228 min_hh_tilde = hh_tilde.val_grid_point(1, k, j, 0) ;
1233 kss << mer <<
" " << max_kss <<
" " << min_kss <<
" " << max_aaLss <<
" " << min_aaLss
1234 <<
" " << -1 * max_hh_tilde <<
" " << -1 * min_hh_tilde << endl ;
1244 void Isol_hor::init_data_alt(
int,
double,
int,
1245 int,
int solve_lapse,
int solve_psi,
1246 int solve_shift,
double precis,
1247 double relax,
int niter) {
1255 ofstream conv(
"resconv.d") ;
1256 ofstream kss(
"kss.d") ;
1257 conv <<
" # diff_nn diff_psi diff_beta " << endl ;
1259 Scalar psi_j (
psi()) ;
1260 Scalar nn_j (
nn()) ;
1262 Scalar diffb ( btilde_j -
b_tilde() ) ;
1263 Scalar theta_j (
beta().divergence(
ff)) ;
1264 theta_j.dec_dzpuis(2) ;
1272 for (
int mer=0; mer<niter; mer++) {
1289 Scalar psisr (psi_j) ;
1291 psisr.inc_dzpuis(2) ;
1293 Scalar dchidr ( chi_j.dsdr() ) ;
1295 Scalar chisr (chi_j) ;
1297 chisr.inc_dzpuis(2) ;
1299 Scalar rdthetadr (theta_j.dsdr() ) ;
1300 rdthetadr.mult_r() ;
1301 rdthetadr.inc_dzpuis(2) ;
1303 Scalar theta_dz4 (theta_j) ;
1304 theta_dz4.inc_dzpuis(4) ;
1306 Scalar dbmb (dchidr - 2 * chisr) ;
1312 Scalar source_psi_spher(
mp) ;
1314 source_psi_spher = -1./12. * psi_j*psi_j*psi_j*psi_j*psi_j/(nn_j * nn_j)
1320 Scalar source_nn_spher(
mp) ;
1321 source_nn_spher = 2./3. * psi_j*psi_j*psi_j*psi_j/nn_j * dbmb *dbmb
1322 - 2 * psi_j.dsdr()/psi_j * nn_j.dsdr() ;
1328 double kappa_0 = 0.2 - 1. ;
1332 kappa.std_spectral_base() ;
1333 kappa.inc_dzpuis(2) ;
1338 Valeur psi_bound (
mp.
get_mg()-> get_angu()) ;
1339 Valeur nn_bound (
mp.
get_mg()-> get_angu()) ;
1346 Scalar tmp_psi = -1./4. * (2 * psisr +
1347 2./3. * psi_j*psi_j*psi_j/ nn_j * dbmb ) ;
1354 Scalar tmp_nn = kappa ;
1358 for (
int k=0 ; k<nnp ; k++)
1359 for (
int j=0 ; j<nnt ; j++){
1360 psi_bound.set(0, k, j, 0) = tmp_psi.val_grid_point(1, k, j, 0) ;
1361 nn_bound.set(0, k, j, 0) = tmp_nn.val_grid_point(1, k, j, 0) ;
1364 psi_bound.std_base_scal() ;
1365 nn_bound.std_base_scal() ;
1375 Scalar psi_jp1 (
mp) ;
1376 if (solve_psi == 1) {
1378 psi_jp1 = source_psi_spher.poisson_neumann(psi_bound, 0) + 1. ;
1381 maxabs(psi_jp1.laplacian() - source_psi_spher,
1382 "Absolute error in the resolution of the equation for Psi") ;
1384 psi_jp1 = relax * psi_jp1 + (1 - relax) * psi_j ;
1389 Scalar nn_jp1 (
mp) ;
1390 if (solve_lapse == 1) {
1392 nn_jp1 = source_nn_spher.poisson_dirichlet(nn_bound, 0) + 1. ;
1395 maxabs(nn_jp1.laplacian() - source_nn_spher,
1396 "Absolute error in the resolution of the equation for N") ;
1402 nn_jp1 = relax * nn_jp1 + (1 - relax) * nn_j ;
1409 Scalar theta_jp1 (
mp) ;
1410 Scalar chi_jp1 (
mp) ;
1412 if (solve_shift == 1) {
1415 Scalar theta_i(theta_j) ;
1416 Scalar chi_i(chi_j) ;
1420 for (
int i=0 ; i<niter ; i++) {
1432 Scalar source_theta_spher(
mp) ;
1433 source_theta_spher = (dbmb * (nn_j.dsdr()/nn_j - 6 * psi_j.dsdr()/psi_j)).dsdr() ;
1434 source_theta_spher.dec_dzpuis() ;
1438 Scalar source_chi_spher(
mp) ;
1439 source_chi_spher = 4./3. * (dchidr - 2 * chisr) * ( nn_j.dsdr()/nn_j - 6 * psi_j.dsdr()/psi_j )
1440 - 1./3. * rdthetadr + 2 * theta_dz4 ;
1443 Valeur theta_bound (
mp.
get_mg()-> get_angu()) ;
1444 Valeur chi_bound (
mp.
get_mg()-> get_angu()) ;
1450 Scalar tmp_theta = dchidr ;
1451 tmp_theta.dec_dzpuis(2) ;
1452 tmp_theta += nn_j/(psi_j*psi_j) ;
1456 Scalar tmp_chi = nn_j/(psi_j*psi_j) ;
1459 for (
int k=0 ; k<nnp ; k++)
1460 for (
int j=0 ; j<nnt ; j++){
1461 theta_bound.set(0, k, j, 0) = tmp_theta.val_grid_point(1, k, j, 0) ;
1462 chi_bound.set(0, k, j, 0) = tmp_chi.val_grid_point(1, k, j, 0) ;
1464 theta_bound.std_base_scal() ;
1465 chi_bound.std_base_scal() ;
1468 Scalar theta_ip1(
mp) ;
1469 Scalar chi_ip1(
mp) ;
1471 theta_ip1 = source_theta_spher.poisson_dirichlet(theta_bound, 0) ;
1472 chi_ip1 = source_chi_spher.poisson_dirichlet(chi_bound, 0) ;
1475 maxabs(theta_ip1.laplacian() - source_theta_spher,
1476 "Absolute error in the resolution of the equation for Theta") ;
1477 maxabs(chi_ip1.laplacian() - source_chi_spher,
1478 "Absolute error in the resolution of the equation for chi") ;
1481 theta_ip1 = relax * theta_ip1 + (1 - relax) * theta_i ;
1482 chi_ip1 = relax * chi_ip1 + (1 - relax) * chi_i ;
1485 double diff_theta_int, diff_chi_int, int_precis ;
1486 diff_theta_int = 1.e-16 ;
1487 diff_chi_int = 1.e-16 ;
1488 int_precis = 1.e-3 ;
1490 diff_theta_int =
max(
diffrel(theta_ip1, theta_i) ) ;
1491 diff_chi_int =
max(
diffrel(chi_ip1, chi_i) ) ;
1494 cout <<
"internal step = " << i
1495 <<
" diff_theta_int = " << diff_theta_int
1496 <<
" diff_chi_int = " << diff_chi_int << endl ;
1497 cout <<
"----------------------------------------------" << endl ;
1498 if ((diff_theta_int<int_precis) && (diff_chi_int<int_precis))
1500 theta_jp1 = theta_ip1 ;
1505 theta_i = theta_ip1 ;
1515 double diff_nn, diff_psi, diff_theta, diff_chi ;
1518 diff_theta = 1.e-16 ;
1521 if (solve_lapse == 1)
1525 if (solve_shift == 1)
1526 diff_theta =
max(
diffrel(theta_jp1, theta_j) ) ;
1527 if (solve_shift == 1)
1531 cout <<
"step = " << mer <<
" : diff_psi = " << diff_psi
1532 <<
" diff_nn = " << diff_nn
1533 <<
" diff_theta = " << diff_theta
1534 <<
" diff_chi = " << diff_chi << endl ;
1535 cout <<
"----------------------------------------------" << endl ;
1536 if ((diff_psi<precis) && (diff_nn<precis) && (diff_theta<precis) && (diff_chi<precis))
1539 if (mer>0) {conv << mer <<
" " <<
log10(diff_nn) <<
" " <<
log10(diff_psi)
1540 <<
" " <<
log10(diff_theta)
1541 <<
" " <<
log10(diff_chi) << endl ; } ;
1551 if (solve_lapse == 1)
1554 if (solve_shift == 1)
1556 theta_j = theta_jp1 ;
1559 Vector beta_jp1 (chi_jp1 *
tgam().radial_vect()) ;
1563 if (solve_shift == 1 || solve_lapse == 1)
1572 gam().radial_vect(), 0, 1)) ;
1573 double max_kss = kkss.val_grid_point(1, 0, 0, 0) ;
1574 double min_kss = kkss.val_grid_point(1, 0, 0, 0) ;
1576 Scalar aaLss (
pow(
psi(), 6) * kkss) ;
1577 double max_aaLss = aaLss.val_grid_point(1, 0, 0, 0) ;
1578 double min_aaLss = aaLss.val_grid_point(1, 0, 0, 0) ;
1581 double max_hh_tilde = hh_tilde.val_grid_point(1, 0, 0, 0) ;
1582 double min_hh_tilde = hh_tilde.val_grid_point(1, 0, 0, 0) ;
1586 for (
int k=0 ; k<nnp ; k++)
1587 for (
int j=0 ; j<nnt ; j++){
1588 if (kkss.val_grid_point(1, k, j, 0) > max_kss)
1589 max_kss = kkss.val_grid_point(1, k, j, 0) ;
1590 if (kkss.val_grid_point(1, k, j, 0) < min_kss)
1591 min_kss = kkss.val_grid_point(1, k, j, 0) ;
1593 if (aaLss.val_grid_point(1, k, j, 0) > max_aaLss)
1594 max_aaLss = aaLss.val_grid_point(1, k, j, 0) ;
1595 if (aaLss.val_grid_point(1, k, j, 0) < min_aaLss)
1596 min_aaLss = aaLss.val_grid_point(1, k, j, 0) ;
1598 if (hh_tilde.val_grid_point(1, k, j, 0) > max_hh_tilde)
1599 max_hh_tilde = hh_tilde.val_grid_point(1, k, j, 0) ;
1600 if (hh_tilde.val_grid_point(1, k, j, 0) < min_hh_tilde)
1601 min_hh_tilde = hh_tilde.val_grid_point(1, k, j, 0) ;
1606 kss << mer <<
" " << max_kss <<
" " << min_kss <<
" " << max_aaLss <<
" " << min_aaLss
1607 <<
" " << -1 * max_hh_tilde <<
" " << -1 * min_hh_tilde << endl ;
virtual const Vector & beta() const
shift vector at the current time step (jtime )
virtual const Scalar & psi() const
Conformal factor relating the physical metric to the conformal one: .
Tbl maxabs(const Tensor &aa, const char *comment=0x0, ostream &ost=cout, bool verb=true)
Maxima in each domain of the absolute values of the tensor components.
const Scalar & psi4() const
Factor at the current time step (jtime ).
const Valeur boundary_psi_Dir_evol() const
Dirichlet boundary condition for (evolution)
const Valeur boundary_psi_Dir_spat() const
Dirichlet boundary condition for (spatial)
const Valeur boundary_vv_z(double om) const
Component z of boundary value of .
Cmp exp(const Cmp &)
Exponential.
double omega
Angular velocity in LORENE's units.
const Valeur boundary_nn_Dir(double aa) const
Dirichlet boundary condition .
int get_np(int l) const
Returns the number of points in the azimuthal direction ( ) in domain no. l.
const Valeur boundary_nn_Dir_lapl(int mer=1) const
Dirichlet boundary condition for N fixing the divergence of the connection form . ...
const Valeur boundary_nn_Dir_eff(double aa) const
Dirichlet boundary condition for N (effectif) .
const Valeur boundary_beta_x(double om) const
Component x of boundary value of .
const Base_vect_spher & get_bvect_spher() const
Returns the orthonormal vectorial basis associated with the coordinates of the mapping.
Standard units of space, time and mass.
const Mg3d * get_mg() const
Gives the Mg3d on which the mapping is defined.
void update_aa()
Conformal representation of the traceless part of the extrinsic curvature: .
double & set(int i)
Read/write of a particular element (index i) (1D case)
const Valeur boundary_nn_Dir_kk() const
Dirichlet boundary condition for N using the extrinsic curvature.
const Valeur boundary_vv_y(double om) const
Component y of boundary value of .
int jtime
Time step index of the latest slice.
const Valeur boundary_psi_app_hor() const
Neumann boundary condition for (spatial)
const Scalar source_psi() const
Source for .
virtual const Vector & radial_vect() const
Returns the radial vector normal to a spherical slicing and pointing toward spatial infinity...
const Valeur boundary_psi_Dir() const
Dirichlet boundary condition for (spatial)
const Vector & derive_con(const Metric &gam) const
Returns the "contravariant" derivative of *this with respect to some metric , by raising the index of...
Tbl diffrel(const Cmp &a, const Cmp &b)
Relative difference between two Cmp (norme version).
double val_grid_point(int l, int k, int j, int i) const
Returns the value of the field at a specified grid point.
Map_af & mp
Affine mapping.
const Valeur boundary_nn_Neu_eff(double aa) const
Neumann boundary condition on nn (effectif) .
double boost_x
Boost velocity in x-direction.
void set_psi(const Scalar &psi_in)
Sets the conformal factor relating the physical metric to the conformal one: .
const Scalar & ln_psi() const
Logarithm of at the current time step (jtime ).
const Scalar b_tilde() const
Radial component of the shift with respect to the conformal metric.
Metric met_gamt
3 metric tilde
const Scalar source_nn() const
Source for N.
const Metric & gam() const
Induced metric at the current time step (jtime )
Tbl max(const Cmp &)
Maximum values of a Cmp in each domain.
const Scalar & divergence(const Metric &) const
The divergence of this with respect to a Metric .
const Vector source_beta() const
Source for .
const Valeur boundary_vv_x(double om) const
Component x of boundary value of .
Cmp pow(const Cmp &, int)
Power .
const Valeur boundary_beta_z() const
Component z of boundary value of .
Tenseur contract(const Tenseur &, int id1, int id2)
Self contraction of two indices of a Tenseur .
const Tensor & derive_cov(const Metric &gam) const
Returns the covariant derivative of this with respect to some metric .
virtual const Sym_tensor & k_dd() const
Extrinsic curvature tensor (covariant components ) at the current time step (jtime ) ...
Evolution_std< double > the_time
Time label of each slice.
virtual void inc_dzpuis(int inc=1)
Increases by inc units the value of dzpuis and changes accordingly the values in the compactified ext...
void des_meridian(const Scalar &uu, double r_min, double r_max, const char *nomy, int ngraph, const char *device=0x0, bool closeit=false, bool draw_bound=true)
Draws 5 profiles of a scalar field along various radial axes in two meridional planes and ...
const Valeur boundary_nn_Neu_kk(int nn=1) const
Neumann boundary condition for N using the extrinsic curvature.
virtual const Metric & tgam() const
Conformal metric Returns the value at the current time step (jtime ).
const Metric_flat & ff
Pointer on the flat metric with respect to which the conformal decomposition is performed.
const Base_vect_cart & get_bvect_cart() const
Returns the Cartesian basis associated with the coordinates (x,y,z) of the mapping, i.e.
Scalar & set(const Itbl &ind)
Returns the value of a component (read/write version).
Cmp log10(const Cmp &)
Basis 10 logarithm.
const Valeur boundary_psi_Neu_spat() const
Neumann boundary condition for (spatial)
const Scalar & dsdr() const
Returns of *this .
void arrete(int a=0)
Setting a stop point in a code.
Evolution_std< Scalar > n_evol
Values at successive time steps of the lapse function N.
const Valeur boundary_beta_y(double om) const
Component y of boundary value of .
int get_nt(int l) const
Returns the number of points in the co-latitude direction ( ) in domain no. l.
Evolution_std< Vector > beta_evol
Values at successive time steps of the shift vector .
const Valeur beta_boost_z() const
Boundary value for a boost in z-direction.
const Valeur beta_boost_x() const
Boundary value for a boost in x-direction.
double boost_z
Boost velocity in z-direction.
const Valeur boundary_nn_Neu_Cook() const
Neumann boundary condition for N using Cook's boundary condition.
const Valeur boundary_psi_Neu_evol() const
Neumann boundary condition for (evolution)
virtual const Scalar & nn() const
Lapse function N at the current time step (jtime )