16#include <IJK_Interfaces.h>
17#include <Cut_cell_FT_Disc.h>
18#include <Maillage_FT_Disc.h>
20#include <Array_tools.h>
21#include <Domaine_IJK.h>
33 coord_.associer_persistant(*
this);
48 ref_interfaces_ = interfaces;
49 ref_domaine_ = splitting;
97 ref_interfaces_ = interfaces;
98 ref_domaine_ = splitting;
207 Cerr <<
"(Cut_cell_FT_Disc::update " << string_localisation <<
") Iter: " <<
processed_count_-1 <<
" n_tot_=" <<
n_tot_ <<
" n_loc_=" <<
n_loc_ << finl;
214 const int ni = ref_domaine_->get_nb_elem_local(0);
215 const int nj = ref_domaine_->get_nb_elem_local(1);
216 const int nk = ref_domaine_->get_nb_elem_local(2);
223 for (
int k = 0; k < nk; k++)
225 for (
int j = 0; j < nj; j++)
227 for (
int i = 0; i < ni; i++)
229 if (!ref_interfaces_->est_pure(0.5*(old_indicatrice(i,j,k) + next_indicatrice(i,j,k))))
241 for (
int k = 0; k < nk; k++)
243 for (
int j = 0; j < nj; j++)
245 for (
int i = 0; i < ni; i++)
247 if (!ref_interfaces_->est_pure(0.5*(old_indicatrice(i,j,k) + next_indicatrice(i,j,k))))
269 for (
int n = 0; n <
n_loc_; n++)
278 for (
int n = 0; n <
n_loc_; n++)
287 assert(ref_domaine_->is_uniform(0));
288 assert(ref_domaine_->is_uniform(1));
289 assert(ref_domaine_->is_uniform(2));
290 for (
int n = 0; n <
n_loc_; n++)
301 coord_(n,0) = (i + ref_domaine_->get_offset_local(0) + .5)*ref_domaine_->get_constant_delta(0) + ref_domaine_->get_origin(0);
302 coord_(n,1) = (j + ref_domaine_->get_offset_local(1) + .5)*ref_domaine_->get_constant_delta(1) + ref_domaine_->get_origin(1);
303 coord_(n,2) = (k + ref_domaine_->get_offset_local(2) + .5)*ref_domaine_->get_constant_delta(2) + ref_domaine_->get_origin(2);
318 const int ni = ref_domaine_->get_nb_elem_local(0);
319 const int nj = ref_domaine_->get_nb_elem_local(1);
320 const int nk = ref_domaine_->get_nb_elem_local(2);
344 int n_initial = n_loc;
345 for (
int k = 0; k < nk; k++)
347 for (
int j = 0; j < nj; j++)
349 for (
int i = 0; i < ni; i++)
351 if (!ref_interfaces_->est_pure(0.5*(old_indicatrice(i,j,k) + next_indicatrice(i,j,k))))
353 int independent_index = ref_domaine_->get_independent_index(i, j, k);
390 for (
int n = 0; n < n_initial; n++)
397 if (ref_interfaces_->est_pure(0.5*(old_indicatrice(i,j,k) + next_indicatrice(i,j,k))))
406 assert(index_perm == n_loc);
415 assert(persistent_double_data_(0).valeur().dimension(0) <= n_loc);
418 for (
int i = 0; i < persistent_double_data_.size(); i++)
423 for (
int i = 0; i < persistent_int_data_.size(); i++)
446 for (
int i = 0; i < persistent_double_data_.size(); i++)
448 int n_initial = persistent_double_data_(i).valeur().dimension(0);
450 persistent_double_data_(i).valeur().resize(size, persistent_double_data_(i).valeur().dimension(1));
453 for (
int n = n_initial; n < size; n++)
455 for (
int j = 0; j < persistent_double_data_(i).valeur().dimension(1); j++)
457 persistent_double_data_(i).valeur()(n,j) = 0;
462 for (
int i = 0; i < transient_double_data_.size(); i++)
464 transient_double_data_(i).valeur().resize(size, transient_double_data_(i).valeur().dimension(1));
467 for (
int n = 0; n < size; n++)
469 for (
int j = 0; j < transient_double_data_(i).valeur().dimension(1); j++)
471 transient_double_data_(i).valeur()(n,j) = 0;
476 for (
int i = 0; i < lazy_double_data_.size(); i++)
478 lazy_double_data_(i).valeur().resize(size, lazy_double_data_(i).valeur().dimension(1));
482 for (
int i = 0; i < persistent_int_data_.size(); i++)
484 int n_initial = persistent_int_data_(i).valeur().dimension(0);
486 persistent_int_data_(i).valeur().resize(size, persistent_int_data_(i).valeur().dimension(1));
489 for (
int n = n_initial; n < size; n++)
491 for (
int j = 0; j < persistent_int_data_(i).valeur().dimension(1); j++)
493 persistent_int_data_(i).valeur()(n,j) = 0;
498 for (
int i = 0; i < transient_int_data_.size(); i++)
500 transient_int_data_(i).valeur().resize(size, transient_int_data_(i).valeur().dimension(1));
503 for (
int n = 0; n < size; n++)
505 for (
int j = 0; j < transient_int_data_(i).valeur().dimension(1); j++)
507 transient_int_data_(i).valeur()(n,j) = 0;
512 for (
int i = 0; i < lazy_int_data_.size(); i++)
514 lazy_int_data_(i).valeur().resize(size, lazy_int_data_(i).valeur().dimension(1));
522 int independent_index;
525 for (
int n = 0; n <
n_loc_; n++)
532 independent_index = ref_domaine_->get_independent_index(i, j, k);
545 independent_index = ref_domaine_->get_independent_index(i, j, k);
553 int left_neighbour_x = (ref_domaine_->get_neighbour_processor(0, 0) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 0);
554 int left_neighbour_y = (ref_domaine_->get_neighbour_processor(0, 1) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 1);
555 int left_neighbour_z = (ref_domaine_->get_neighbour_processor(0, 2) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 2);
556 int right_neighbour_x = (ref_domaine_->get_neighbour_processor(1, 0) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 0);
557 int right_neighbour_y = (ref_domaine_->get_neighbour_processor(1, 1) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 1);
558 int right_neighbour_z = (ref_domaine_->get_neighbour_processor(1, 2) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 2);
560 int shift_x_min = - (left_neighbour_x != ref_domaine_->me());
561 int shift_y_min = - (left_neighbour_y != ref_domaine_->me());
562 int shift_z_min = - (left_neighbour_z != ref_domaine_->me());
563 int shift_x_max = + (right_neighbour_x != ref_domaine_->me())*(right_neighbour_x != left_neighbour_x);
564 int shift_y_max = + (right_neighbour_y != ref_domaine_->me())*(right_neighbour_y != left_neighbour_y);
565 int shift_z_max = + (right_neighbour_z != ref_domaine_->me())*(right_neighbour_z != left_neighbour_z);
568 for (
int shift_x = shift_x_min; shift_x <= shift_x_max; shift_x++)
570 for (
int shift_y = shift_y_min; shift_y <= shift_y_max; shift_y++)
572 for (
int shift_z = shift_z_min; shift_z <= shift_z_max; shift_z++)
574 int dest_pe_position_x = ref_domaine_->get_local_slice_index(0) + shift_x;
575 int dest_pe_position_y = ref_domaine_->get_local_slice_index(1) + shift_y;
576 int dest_pe_position_z = ref_domaine_->get_local_slice_index(2) + shift_z;
577 int dest_pe = ref_domaine_->periodic_get_processor_by_ijk(dest_pe_position_x, dest_pe_position_y, dest_pe_position_z);
578 if (dest_pe == ref_domaine_->me())
580 assert(shift_x == 0);
581 assert(shift_y == 0);
582 assert(shift_z == 0);
590 array_trier_retirer_doublons(pe_list);
596 int ni = ref_domaine_->get_nb_elem_local(0);
597 int nj = ref_domaine_->get_nb_elem_local(1);
598 int nk = ref_domaine_->get_nb_elem_local(2);
607 assert(n_tot == n_loc);
613 int left_neighbour_x = (ref_domaine_->get_neighbour_processor(0, 0) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 0);
614 int left_neighbour_y = (ref_domaine_->get_neighbour_processor(0, 1) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 1);
615 int left_neighbour_z = (ref_domaine_->get_neighbour_processor(0, 2) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 2);
616 int right_neighbour_x = (ref_domaine_->get_neighbour_processor(1, 0) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 0);
617 int right_neighbour_y = (ref_domaine_->get_neighbour_processor(1, 1) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 1);
618 int right_neighbour_z = (ref_domaine_->get_neighbour_processor(1, 2) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 2);
620 int shift_x_min = - (left_neighbour_x != ref_domaine_->me());
621 int shift_y_min = - (left_neighbour_y != ref_domaine_->me());
622 int shift_z_min = - (left_neighbour_z != ref_domaine_->me());
623 int shift_x_max = + (right_neighbour_x != ref_domaine_->me())*(right_neighbour_x != left_neighbour_x);
624 int shift_y_max = + (right_neighbour_y != ref_domaine_->me())*(right_neighbour_y != left_neighbour_y);
625 int shift_z_max = + (right_neighbour_z != ref_domaine_->me())*(right_neighbour_z != left_neighbour_z);
627 for (
int shift_x = shift_x_min; shift_x <= shift_x_max; shift_x++)
629 for (
int shift_y = shift_y_min; shift_y <= shift_y_max; shift_y++)
631 for (
int shift_z = shift_z_min; shift_z <= shift_z_max; shift_z++)
633 int dest_pe_position_x = ref_domaine_->get_local_slice_index(0) + shift_x;
634 int dest_pe_position_y = ref_domaine_->get_local_slice_index(1) + shift_y;
635 int dest_pe_position_z = ref_domaine_->get_local_slice_index(2) + shift_z;
636 int dest_pe = ref_domaine_->periodic_get_processor_by_ijk(dest_pe_position_x, dest_pe_position_y, dest_pe_position_z);
637 if (dest_pe == ref_domaine_->me())
639 assert(shift_x == 0);
640 assert(shift_y == 0);
641 assert(shift_z == 0);
647 int left_bnd_x = (shift_x < 0);
648 int left_bnd_y = (shift_y < 0);
649 int left_bnd_z = (shift_z < 0);
650 int right_bnd_x = ((shift_x > 0) || ((shift_x_max == 0) && (shift_x < 0) && (right_neighbour_x != ref_domaine_->me())));
651 int right_bnd_y = ((shift_y > 0) || ((shift_y_max == 0) && (shift_y < 0) && (right_neighbour_y != ref_domaine_->me())));
652 int right_bnd_z = ((shift_z > 0) || ((shift_z_max == 0) && (shift_z < 0) && (right_neighbour_z != ref_domaine_->me())));
654 for (
int n = 0; n < n_loc; n++)
661 if (is_within_a_ghost_distance_of_boundary
672 send_buffer << n << x << y << z;
683 const ArrOfInt& recv_pe_list =
schema_comm_.get_recv_pe_list();
684 for (
int indice_pe = 0; indice_pe < recv_pe_list.
size_array(); indice_pe++)
686 const int pe_source = recv_pe_list[indice_pe];
691 int numero_sur_pe_source;
695 recv_buffer >> numero_sur_pe_source >> pos_x >> pos_y >> pos_z;
696 if (recv_buffer.
eof())
699 int nsom =
coord_.dimension(0);
702 coord_.append_line(pos_x, pos_y, pos_z);
720 for (
int i = 0; i < persistent_double_data_.size(); i++)
722 desc_.echange_espace_virtuel(persistent_double_data_(i).valeur());
726 for (
int i = 0; i < persistent_int_data_.size(); i++)
728 desc_.echange_espace_virtuel(persistent_int_data_(i).valeur());
735 for (
int i = 0; i < persistent_double_data_.size(); i++)
737 desc_.echange_espace_virtuel(persistent_double_data_(i).valeur(), op);
741 for (
int i = 0; i < persistent_int_data_.size(); i++)
743 desc_.echange_espace_virtuel(persistent_int_data_(i).valeur(), op);
750 for (
int n = 0; n <
n_loc_; n++)
772 const int nk_tot = ref_domaine_->get_nb_elem_local(2) + 2*
ghost_size_;
777 for (
int index = 0; index <
n_tot_; index++)
783 for (
int k_intermediaire = previous_k+1; k_intermediaire <= k; k_intermediaire++)
790 for (
int k_intermediaire = previous_k+1; k_intermediaire <= ref_domaine_->get_nb_elem_local(2) +
ghost_size_; k_intermediaire++)
799 for (
int n = 0; n <
n_loc_; n++)
811 u.i = (
long long int)n;
830 u.i = (
long long int)n;
843 for (
int index = 0; index <
n_tot_; index++)
852 bool est_reguliere = ref_interfaces_->est_reguliere(old_indicatrice(i,j,k), next_indicatrice(i,j,k));
853 bool devient_pure = ref_interfaces_->devient_pure(old_indicatrice(i,j,k), next_indicatrice(i,j,k));
854 bool devient_diphasique = ref_interfaces_->devient_diphasique(old_indicatrice(i,j,k), next_indicatrice(i,j,k));
855 bool desequilibre_final = ref_interfaces_->a_desequilibre_final(old_indicatrice(i,j,k), next_indicatrice(i,j,k));
856 bool desequilibre_initial_uniquement = ref_interfaces_->a_desequilibre_initial_uniquement(old_indicatrice(i,j,k), next_indicatrice(i,j,k));
857 bool monophasique = ref_interfaces_->est_pure(.5*(old_indicatrice(i,j,k) + next_indicatrice(i,j,k)));
858 assert(est_reguliere + devient_pure + devient_diphasique + desequilibre_final + desequilibre_initial_uniquement + monophasique == 1);
875 int previous_statut_diphasique = 0;
877 for (
int index = 0; index <
n_tot_; index++)
881 if (statut_diphasique > previous_statut_diphasique)
883 for (
int k_intermediaire = previous_statut_diphasique+1; k_intermediaire <= statut_diphasique; k_intermediaire++)
887 previous_statut_diphasique = statut_diphasique;
890 for (
int k_intermediaire = previous_statut_diphasique+1; k_intermediaire <= static_cast<int>(
STATUT_DIPHASIQUE::count); k_intermediaire++)
898 const int ni = ref_domaine_->get_nb_elem_local(0);
899 const int nj = ref_domaine_->get_nb_elem_local(1);
900 const int nk = ref_domaine_->get_nb_elem_local(2);
913 for (
int n = 0; n <
n_loc_; n++)
916 int i = ijk_no_per[0];
917 int j = ijk_no_per[1];
918 int k = ijk_no_per[2];
921 int index_ijk_per = 0;
922 while (index_ijk_per >= 0)
935 int i = ijk_no_per[0];
936 int j = ijk_no_per[1];
937 int k = ijk_no_per[2];
940 int index_ijk_per = 0;
941 while (index_ijk_per >= 0)
967 for (
int n = 0; n <
n_loc_; n++)
974 if ((next_indicatrice(i,j,k) == 0) || (next_indicatrice(i,j,k) == 1))
986 assert(index_perm + n_deletion ==
n_loc_);
995 assert(persistent_double_data_(0).valeur().dimension(0) <=
n_loc_);
998 for (
int i = 0; i < persistent_double_data_.size(); i++)
1003 for (
int i = 0; i < persistent_int_data_.size(); i++)
1027 const int ni = ref_domaine_->get_nb_elem_local(0);
1028 const int nj = ref_domaine_->get_nb_elem_local(1);
1029 const int nk = ref_domaine_->get_nb_elem_local(2);
1031 for (
int k = 0; k < nk; k++)
1033 for (
int j = 0; j < nj; j++)
1035 for (
int i = 0; i < ni; i++)
1043 for (
int index_statut_diphasique = 0; index_statut_diphasique < 5; index_statut_diphasique++)
1045 int statut_diphasique = liste_statuts_valides[index_statut_diphasique];
1048 for (
int index = index_min; index < index_max; index++)
1057 if (!ref_domaine_->within_ghost(i, j, k, 0, 0))
1074 for (
int n = 0; n <
n_loc_; n++)
1092 for (
int n = 0; n <
n_loc_; n++)
1103 if ((i_1 != i_2) || (j_1 != j_2) || (k_1 != k_2))
1118 if ((i_1 != i_2) || (j_1 != j_2) || (k_1 != k_2))
1129 for (
int i = 0; i < persistent_double_data_.size(); i++)
1131 if (persistent_double_data_(i).valeur().dimension(0) !=
n_tot_)
1135 for (
int i = 0; i < transient_double_data_.size(); i++)
1137 if (transient_double_data_(i).valeur().dimension(0) !=
n_tot_)
1141 for (
int i = 0; i < lazy_double_data_.size(); i++)
1143 if (lazy_double_data_(i).valeur().dimension(0) !=
n_tot_)
1147 for (
int i = 0; i < persistent_int_data_.size(); i++)
1149 if (persistent_int_data_(i).valeur().dimension(0) !=
n_tot_)
1153 for (
int i = 0; i < transient_int_data_.size(); i++)
1155 if (transient_int_data_(i).valeur().dimension(0) !=
n_tot_)
1159 for (
int i = 0; i < lazy_int_data_.size(); i++)
1161 if (lazy_int_data_(i).valeur().dimension(0) !=
n_tot_)
1169 Cerr <<
"# Impression des elements diphasiques pour le PE#" << ref_domaine_->me() <<
" [N IJK XYZ T]" << finl;
1170 for (
int n = 0; n <
n_loc_; n++)
1182 Cerr << n << symbole <<
" " << i <<
" " << j <<
" " << k <<
" " <<
coord_(n,0) <<
" " <<
coord_(n,1) <<
" " <<
coord_(n,2) << finl;
1196 Cerr << n << symbole <<
" " << i <<
" " << j <<
" " << k <<
" " <<
coord_(n,0) <<
" " <<
coord_(n,1) <<
" " <<
coord_(n,2) << finl;
1198 Cerr <<
"# Fin impression elements diphasiques" << finl;
1203 Cerr <<
"# Impression des elements distants [N PE IJK XYZ T]" << finl;
1204 const int ni = ref_domaine_->get_nb_elem_local(0);
1205 const int nj = ref_domaine_->get_nb_elem_local(1);
1206 const int nk = ref_domaine_->get_nb_elem_local(2);
1208 int left_neighbour_x = (ref_domaine_->get_neighbour_processor(0, 0) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 0);
1209 int left_neighbour_y = (ref_domaine_->get_neighbour_processor(0, 1) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 1);
1210 int left_neighbour_z = (ref_domaine_->get_neighbour_processor(0, 2) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(0, 2);
1211 int right_neighbour_x = (ref_domaine_->get_neighbour_processor(1, 0) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 0);
1212 int right_neighbour_y = (ref_domaine_->get_neighbour_processor(1, 1) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 1);
1213 int right_neighbour_z = (ref_domaine_->get_neighbour_processor(1, 2) < 0) ? ref_domaine_->me() : ref_domaine_->get_neighbour_processor(1, 2);
1215 int shift_x_min = - (left_neighbour_x != ref_domaine_->me());
1216 int shift_y_min = - (left_neighbour_y != ref_domaine_->me());
1217 int shift_z_min = - (left_neighbour_z != ref_domaine_->me());
1218 int shift_x_max = + (right_neighbour_x != ref_domaine_->me())*(right_neighbour_x != left_neighbour_x);
1219 int shift_y_max = + (right_neighbour_y != ref_domaine_->me())*(right_neighbour_y != left_neighbour_y);
1220 int shift_z_max = + (right_neighbour_z != ref_domaine_->me())*(right_neighbour_z != left_neighbour_z);
1221 for (
int shift_x = shift_x_min; shift_x <= shift_x_max; shift_x++)
1223 for (
int shift_y = shift_y_min; shift_y <= shift_y_max; shift_y++)
1225 for (
int shift_z = shift_z_min; shift_z <= shift_z_max; shift_z++)
1227 int dest_pe_position_x = ref_domaine_->get_local_slice_index(0) + shift_x;
1228 int dest_pe_position_y = ref_domaine_->get_local_slice_index(1) + shift_y;
1229 int dest_pe_position_z = ref_domaine_->get_local_slice_index(2) + shift_z;
1230 int dest_pe = ref_domaine_->periodic_get_processor_by_ijk(dest_pe_position_x, dest_pe_position_y, dest_pe_position_z);
1231 if (dest_pe == ref_domaine_->me())
1233 assert(shift_x == 0);
1234 assert(shift_y == 0);
1235 assert(shift_z == 0);
1239 int left_bnd_x = (shift_x < 0);
1240 int left_bnd_y = (shift_y < 0);
1241 int left_bnd_z = (shift_z < 0);
1242 int right_bnd_x = ((shift_x > 0) || ((shift_x_max == 0) && (shift_x < 0) && (right_neighbour_x != ref_domaine_->me())));
1243 int right_bnd_y = ((shift_y > 0) || ((shift_y_max == 0) && (shift_y < 0) && (right_neighbour_y != ref_domaine_->me())));
1244 int right_bnd_z = ((shift_z > 0) || ((shift_z_max == 0) && (shift_z < 0) && (right_neighbour_z != ref_domaine_->me())));
1246 for (
int n = 0; n <
n_loc_; n++)
1253 || (right_bnd_x && (i_selon_x >= ni -
ghost_size_))
1255 || (right_bnd_y && (i_selon_y >= nj -
ghost_size_))
1257 || (right_bnd_z && (i_selon_z >= nk -
ghost_size_)))
1264 Cerr << n <<
" " << dest_pe <<
" " << i <<
" " << j <<
" " << k <<
" " <<
coord_(n,0) <<
" " <<
coord_(n,1) <<
" " <<
coord_(n,2) << finl;
1270 Cerr <<
"# Fin impression elements distants" << finl;
1275 return ref_interfaces_;
1280 return ref_domaine_;
1292 assert(
get_n(i, j, k) < 0);
1294 double indic = ref_interfaces_->I(i, j, k);
1295 assert(indic == ref_interfaces_->In(i, j, k));
1306 for (
int i = 0; i <= imax; i++)
1308 if (array(i) == value)
1324 const int initial_sign = array(0) > 0 ? 1 : -1;
1325 for (
int i = 0; i < array.
dimension(0); i++)
1327 const int sign = array(i) > 0 ? 1 : -1;
1328 if ((array(i) == 0) || (sign != initial_sign))
1338 for (
int i = 0; i < array.
dimension(0); i++)
1340 if ((array(i,0) == 0) || (array(i,0) == 1) || (array(i,0) == 2))
1351 for (
int i = 0; i < array.
dimension(0); i++)
1364 for (
int i = 0; i < array.
dimension(0); i++)
1390 const int max_nb_columns = 6;
1391 assert(array.
dimension(1) <= max_nb_columns);
1394 int sign = processed(0) > 0 ? 1 : -1;
1396 for (
int i = 0; i < array.
dimension(0); i++)
1398 if (sign*processed(i) < 0)
1409 T first_cycle_value[max_nb_columns];
1410 for (
int j = 0; j < array.
dimension(1); j++)
1412 first_cycle_value[j] = array(i,j);
1414 int current_index = i;
1415 int next_index = permutation[i];
1417 while (next_index != i)
1419 for (
int j = 0; j < array.
dimension(1); j++)
1421 array(current_index,j) = array(next_index,j);
1424 processed(current_index) = -processed(current_index);
1426 current_index = next_index;
1427 next_index = permutation[next_index];
1430 for (
int j = 0; j < array.
dimension(1); j++)
1432 array(current_index,j) = first_cycle_value[j];
1434 processed(current_index) = -processed(current_index);
1441 int old_independent_index = -1;
1442 for (
int n = imin; n < imax; n++)
1444 int independent_index = array(n);
1445 if (old_independent_index >= independent_index)
1447 old_independent_index = independent_index;
const Domaine_IJK & get_domaine() const
void echange_espace_virtuel()
void initialise_schema_comm()
void update_index_sorted_by_k()
void imprime_elements_distants()
bool verifier_taille_tableaux()
const IJK_Interfaces & get_interfaces() const
void update_index_sorted_by_indicatrice(const IJK_Field_double &old_indicatrice, const IJK_Field_double &next_indicatrice)
int get_n_from_indicatrice_index(int index) const
static bool verifier_toujours_meme_signe_et_non_nul(const IntTabFT_cut_cell &array)
void initialise_processed()
void compute_virtual_independent_index()
Int3 ijk_per_of_index(int i, int j, int k, int index) const
int next_index_ijk_per(int i, int j, int k, int index, int negative_ghost_size, int positive_ghost_size) const
void initialise_permutation()
int add_and_remove_local_elements(const IJK_Field_double &old_indicatrice, const IJK_Field_double &next_indicatrice)
bool verifier_coherence_coord_independent_index()
const Desc_Structure_FT & get_desc_structure() const
IntTabFT_cut_cell_scalar permutation_
static bool verifier_pas_de_doublons(const IntTabFT_cut_cell &array)
Int3 get_ijk(int n) const
static int find_value_unsorted(T value, const TRUSTTabFT< T > &array, int imin, int imax)
IntTabFT_cut_cell_vector2 index_sorted_by_k_
void resize_data(int size)
void update_index_sorted_by_statut_diphasique(const IJK_Field_double &old_indicatrice, const IJK_Field_double &next_indicatrice)
static bool verifier_si_ordonne(const IntTabFT_cut_cell &array, int imin, int imax)
IJK_Field_int indice_diphasique_
IntTabFT_cut_cell_scalar independent_index_
int initialise_independent_index(const IJK_Field_double &old_indicatrice, const IJK_Field_double &next_indicatrice)
DoubleTabFT_cut_cell_vector3 index_sorted_by_indicatrice_
void imprime_elements_diphasiques()
int initialise_communications()
void fill_buffer_with_variable(const TRUSTTabFT< T > &array, int component=0) const
void fill_variable_with_buffer(TRUSTTabFT< T > &array, int component=0) const
void update(const IJK_Field_double &old_indicatrice, const IJK_Field_double &next_indicatrice)
IntTabFT_cut_cell_vector3 index_sorted_by_statut_diphasique_
double indic_pure(const int i, const int j, const int k) const
Domaine_IJK::Localisation localisation_
int get_n_from_statut_diphasique_index(int index) const
int get_statut_diphasique_value_index(int statut_diphasique) const
static bool verifier_tableau_jamais_nul(const DoubleTabFT_cut_cell &array)
int get_n(int i, int j, int k) const
static void apply_permutation(TRUSTTabFT< T > &array, const IntTabFT_cut_cell &permutation_indices, IntTabFT_cut_cell &processed)
IJK_Field_double write_buffer_
void remplir_indice_diphasique()
DoubleTabFT_cut_cell_vector3 coord_
static bool verifier_valide_permutation(const IntTabFT_cut_cell &array)
IntTabFT_cut_cell_scalar processed_
void remove_dead_and_virtual_cells(const IJK_Field_double &next_indicatrice)
IntTabFT statut_diphasique_value_index_
void initialise(IJK_Interfaces &interfaces, Domaine_IJK &splitting, Domaine_IJK::Localisation loc)
: class Desc_Structure_FT
: class Descripteur_FT Descripteur_FT stocke pour chaque PE une liste de numeros d'elements.
int contient_element(int pe, int element) const
Renvoie "pas zero" si l'element est deja dans le descripteur pour le pe donne, 0 sinon.
int ajoute_element(int PE_voisin, int element)
Ajoute l'element au tableau du PE_voisin.
void calcul_liste_pe_voisins()
Calcule la liste des PEs dont la liste d'elements est non vide, tries dans l'ordre croissant de numer...
This class encapsulates all the information related to the eulerian mesh for TrioIJK.
Localisation
Localisation sub class.
Class defining operators and methods for all reading operation in an input flow (file,...
Domaine_IJK::Localisation get_localisation() const
class Nom Une chaine de caractere pour nommer les objets de TRUST
Classe de base des flux de sortie.
void append_array(_TYPE_ valeur)
_SIZE_ size_array() const
_SIZE_ dimension(int d) const