TrioCFD 1.9.8
TrioCFD documentation
Loading...
Searching...
No Matches
IJK_Interfaces.h
1/****************************************************************************
2* Copyright (c) 2015 - 2016, CEA
3* All rights reserved.
4*
5* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
6* 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
7* 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
8* 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
9*
10* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
11* IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
12* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
13*
14*****************************************************************************/
15
16#ifndef IJK_Interfaces_included
17#define IJK_Interfaces_included
18
19#include <Connectivite_frontieres.h>
20#include <IJK_Field_vector.h>
21#include <IJK_Field.h> // est-ce que j'en ai vraiment besoin ?
22#include <Linear_algebra_tools_impl.h>
23#include <Maillage_FT_IJK.h>
24#include <Equation_base.h>
25#include <Parcours_interface.h>
26#include <Remaillage_FT_IJK.h>
27#include <SFichier.h>
28#include <Vecteur3.h>
29#include <Linear_algebra_tools_impl.h>
30#include <SurfaceVapeurIJKComputation.h>
31#include <ComputeValParCompoInCell.h>
32#include <TRUST_Ref.h>
33#include <Intersection_Interface_ijk.h>
34#include <IJK_Composantes_Connex.h>
35#include <TRUSTTabFT_cut_cell.h>
36#include <Cut_field.h>
37#include <Cut_cell_surface_efficace.h>
38#include <Domaine_dis_base.h>
39#include <Option_IJK.h>
40#include <Champs_compris_IJK_interface.h>
41#include <Champs_compris_IJK.h>
42
45
46#define VERIF_INDIC 0
47
48/*! @brief : class IJK_Interfaces
49 *
50 * Cette classe rassemble tous les algorithmes de gestion des interfaces pour le ijk
51 * (le maillage, les algo de remaillage, sauvegarde, reprise, etc)
52 *
53 */
55{
56 Declare_instanciable(IJK_Interfaces);
58public :
59 /*
60 * Surcharge de l'eq base
61 */
62 void set_param(Param& titi) const override { /* Do nothing */ }
64
65 void completer() override { /* Do nothing */ }
66 void associer_pb_base(const Probleme_base&) override;
67 void discretiser() override { /* Do nothing */ }
68 int preparer_calcul() override { return 1; }
69 const Milieu_base& milieu() const override;
70 Milieu_base& milieu() override;
71 void associer_milieu_base(const Milieu_base& ) override { /* Do nothing */ }
72 int nombre_d_operateurs() const override { return -123; }
73 const Operateur& operateur(int) const override { throw; }
74 Operateur& operateur(int) override { throw; }
75 const Champ_Inc_base& inconnue() const override { throw; }
76 Champ_Inc_base& inconnue() override { throw; }
77
80
81 // Interface Champs_compris_IJK_interface
82 bool has_champ(const Motcle& nom) const override { return champs_compris_.has_champ(nom); }
83 bool has_champ(const Motcle& nom, OBS_PTR(Champ_base)& ref_champ) const override { /* not used */ throw; }
84 bool has_champ_vectoriel(const Motcle& nom) const override { return champs_compris_.has_champ_vectoriel(nom); }
85 const IJK_Field_double& get_IJK_field(const Motcle& nom) override;
86 const IJK_Field_vector3_double& get_IJK_field_vector(const Motcle& nom) override;
87 static void Fill_postprocessable_fields(std::vector<FieldInfo_t>& chps);
88 void get_noms_champs_postraitables(Noms& noms,Option opt=NONE) const override;
89
90 void register_fields();
91
92 void dumplata_ft_mesh(const char *filename, const char *meshname, int step) const;
93
94 void initialize(const Domaine_IJK& splitting_FT,
95 const Domaine_IJK& splitting_NS,
97 const int thermal_probes_ghost_cells=0,
98 const bool compute_vint=true,
99 const bool is_switch=false);
100 void associer_switch(const Switch_FT_double& ijk_ft_switch);
101 void posttraiter_tous_champs(Motcles& liste) const;
102 int posttraiter_champs_instantanes(const Motcles& liste_post_instantanes,
103 const char *lata_name,
104 const int lata_step) const;
105 void sauvegarder_interfaces(const char *lata_name, const Nom& interf_name="??"); // const;
106 void calculer_color(ArrOfInt& color) const;
107 void postraiter_colors(Sortie& os, const double current_time) const;
108
109 void calculer_var_volume_remaillage(double timestep,
110 const DoubleTab& vitesses_translation_bulles,
111 const DoubleTab& mean_bubble_rotation_vector,
112 const DoubleTab& centre_gravite,
113 ArrOfDouble& var_volume);
114 void calculer_vecteurs_de_deplacement_rigide(DoubleTab& vitesses_translation_bulles,
115 DoubleTab& mean_bubble_rotation_vector,
116 DoubleTab& centre_gravite,
117 const int first_step_interface_smoothing = 0);
118 void transporter_maillage_deformation(const int correction_semi_locale_volume_bulle,
119 const DoubleTab& vitesses_translation_bulles,
120 const DoubleTab& mean_bubble_rotation_vector,
121 const DoubleTab& centre_gravite,
122 const double dt_tot,
123 ArrOfDouble& dvol,
124 const int rk_step,
125 const int first_step_interface_smoothing = 0);
126 void transporter_maillage_remaillage(int correction_semi_locale_volume_bulle,
127 const DoubleTab& vitesses_translation_bulles,
128 const DoubleTab& mean_bubble_rotation_vector,
129 const DoubleTab& centre_gravite,
130 double dt_tot,
131 ArrOfDouble& dvol,
132 const int rk_step,
133 const double temps);
134 void transporter_maillage_rigide(const double dt_tot,
135 const DoubleTab& vitesses_translation_bulles,
136 const DoubleTab& mean_bubble_rotation_vector,
137 const DoubleTab& centre_gravite,
138 const int rk_step,
139 const int first_step_interface_smoothing = 0);
140 void calculer_vitesse_de_deformation(int compo,
141 const DoubleTab& bounding_box_bulles,
142 const Cut_field_vector3_double& cut_field_velocity,
143 const DoubleTab& vitesses_translation_bulles,
144 const DoubleTab& mean_bubble_rotation_vector,
145 const DoubleTab& positions_bulles);
146
147 void calculer_bounding_box_bulles(DoubleTab& bounding_box, int option_shear = 0) const;
148 void preparer_duplicata_bulles(const DoubleTab& bounding_box_of_bubbles,
149 const DoubleTab& bounding_box_offsetp,
150 const DoubleTab& bounding_box_offsetm,
151 const DoubleTab& authorized_bounding_box,
152 ArrOfInt& masque_duplicata_pour_compo_reel);
153
154 void preparer_duplicata_bulles_masque_6bit(const DoubleTab& bounding_box,
155 const DoubleTab& authorized_bounding_box,
156 ArrOfInt& masque_duplicata_pour_compo);
157 void dupliquer_bulle_perio(ArrOfInt& masque_duplicata_pour_compo);
161
162 void deplacer_bulle_perio(const ArrOfInt& masque_deplacement_par_compo);
163 void transferer_bulle_perio(); // Les bulles trop proche du bord sont
164 // deplacees a l'oppose, vers l'autre bord perio.
165
167
168 void compute_vinterp();
169 // methode pour bulles fixes
170 void compute_external_forces_(IJK_Field_vector3_double& rappel_ft,
171 IJK_Field_vector3_double& rappel,
172 const IJK_Field_vector3_double& vitesse,
173 const IJK_Field_double& indic_ns,
174 const IJK_Field_double& indic_ft,
175 const double coef_immo,
176 const int tstep,
177 const double current_time,
178 const double coef_ammortissement,
179 const double coef_rayon_force_rappel,
180 double compteur,
181 double coef_mean_force,
182 double coef_force_time_n);
183 void compute_external_forces_parser(IJK_Field_vector3_double& rappel,
184 const IJK_Field_double& indic_ns,
185 const DoubleTab& individual_forces,
186 const ArrOfDouble& volume_reel,
187 const DoubleTab& position,
188 const double coef_rayon_force_rappel);
189 void compute_external_forces_color_function(IJK_Field_vector3_double& rappel,
190 const IJK_Field_double& indic_ns,
191 const IJK_Field_double& indic_ft,
192 DoubleTab& individual_forces,
193 const ArrOfDouble& volume_reel,
194 const DoubleTab& position);
195
196 void compute_indicatrice_non_perturbe(IJK_Field_double& indic_np,
197 const IJK_Field_double& indic,
198 const ArrOfDouble& volume_reel,
199 const DoubleTab& position) const;
200
201 int lire_motcle_non_standard(const Motcle& un_mot, Entree& is) override;
202
203 void activate_cut_cell();
205
211
212 void calcul_surface_efficace_face(TYPE_SURFACE_EFFICACE_FACE type_surface_efficace_face, double timestep, const Cut_field_vector3_double& total_velocity);
213 void calcul_surface_efficace_interface(TYPE_SURFACE_EFFICACE_INTERFACE type_surface_efficace_interface, double timestep, const Cut_field_vector3_double& velocity);
214 void calcul_surface_efficace_face_initial(TYPE_SURFACE_EFFICACE_FACE type_surface_efficace_face);
215 void calcul_surface_efficace_interface_initial(TYPE_SURFACE_EFFICACE_INTERFACE type_surface_efficace_interface);
216
217 // fin de methode pour bulles fixes
218 const Domaine_dis_base& get_domaine_dis() const { return refdomaine_dis_.valeur(); }
222 int is_frozen() const { return frozen_; }
223 void freeze() { frozen_ = 1; }
224
225 int get_nb_bulles_ghost(const int print = 0) const
226 {
227 if (print)
228 Cerr << "IJK_Interfaces::get_nb_bulles_ghost : On a " << nb_bulles_ghost_ << " bulles ghost." << finl;
229 return nb_bulles_ghost_;
230 }
231
232 int get_forcing_method() const { return parser_; }
235 int follow_colors() const { return follow_colors_; }
236 const ArrOfInt& get_colors() const { return through_yminus_; }
237 int ghost_compo_converter(const int i) const { return ghost_compo_converter_[i]; }
238
239// Methodes d'acces aux parametres de la repulsion a la paroi :
242
243 void set_reprise(const int i)
244 {
245 reprise_ = i;
246 return;
247 }
248
249 void set_fichier_sauvegarde(const char *lataname) { fichier_sauvegarde_interface_ = lataname; }
250 void set_fichier_reprise(const char *lataname) { fichier_reprise_interface_ = lataname; }
251 void set_seuil_indicatrice_petite(double seuil_indicatrice_petite)
252 {
253 seuil_indicatrice_petite_ = seuil_indicatrice_petite;
254
256 {
257 Cerr << "Erreur IJK_Interfaces: Incoherence parametres jeu de donnees, seuil_indicatrice_petite_ <= seuil_indicatrice_negligeable_." << finl;
259 }
260 };
261
263
264 // methode non-const. Pour appel depuis l'exterieur (comme IJK_switch)
272
273 // methodes non-const.
275 {
276 maillage_ft_ijk_.parcourir_maillage();
277 if (!maillage_ft_ijk_.Surfactant_facettes().get_disable_surfactant())
278 {
279 maillage_ft_ijk_.update_gradient_laplacien_Surfactant();
280 maillage_ft_ijk_.update_sigma_and_interfacial_source_term_sommet(ref_domaine_, false, use_tryggvason_interfacial_source_);
281 }
282 return;
283 };
284
285 void RK3_G_store_vi_resize(int n, int n2)
286 {
287 RK3_G_store_vi_.resize(n, n2);
288 return;
289 };
290
292 {
293 maillage_ft_ijk_.desc_sommets().echange_espace_virtuel(RK3_G_store_vi_);
294 return;
295 };
296
297 // methode non-const. Remplit le tableau des positions de reference
298 // vers lesquelles la force de rappel attire les bulles):
299 // (a partir de la position actuelle des bulles)
300 // pour calculs a bulles fixes
302 {
303 ArrOfDouble vol;
306 return;
307 };
308
312 const DoubleTab& RK3_G_store_vi() const { return RK3_G_store_vi_; }
313 const IntVect& get_num_compo() const { return num_compo_; }
314 const ArrOfInt& get_compo_to_group() const { return compo_to_group_; }
315
316 // Methode qui parcourt les facettes contenues dans la cellule num_elem
317 // pour trouver la phase de sa cellule voisine
318 // Donnees d'entree:
319 // - num_elem : indice de l'element traverse par l'interface
320 // - direction : precise dans quelle direction se trouve le voisin dont on
321 // cherche la phase
322 // - face_plus : precise dans quel sens se trouve le voisin dont on cherche
323 // la phase
324 // (+1 pour le voisin d'indice plus eleve, -1 pour l'autre )
325 int compute_cell_phase_with_interface_normal(int num_elem, int direction, int face_plus);
326
327 void calculer_kappa_ft(IJK_Field_double& kappa_ft);
328
329 void calculer_normales_et_aires_interfaciales(IJK_Field_double& ai,
330 IJK_Field_double& kappa_ai,
331 IJK_Field_vector3_double& normale_cell,
332 const int igroup) const;
333
335 const int elem,
336 ArrOfInt& liste_composantes_connexes_dans_element) const;
337 const int& nb_groups() const { return nb_groups_ ; }
338 const ArrOfDoubleFT& get_distance_autres_interfaces() const { return distance_autres_interfaces_; }
339 int get_ghost_number_from_compo(const int compo) const;
340
341 void calculer_surface_bulles(ArrOfDouble& surfaces) const;
342 void compute_surface_average_per_bubble(const ArrOfDouble& surfaces, const ArrOfDouble& in, ArrOfDouble& out) const;
343 void read_bubbles_barycentres_old_new(const Nom& interf_name);
344 bool read_bubbles_barycentres_vel(const Nom& interf_name,
345 FixedVector<ArrOfDouble,3>& bubbles_rising_dir,
346 FixedVector<ArrOfDouble,3>& bubbles_rising_vel,
347 ArrOfDouble& bubbles_rising_vel_mag);
348 bool read_bubbles_barycentres(const Nom& interf_name, const Nom& suffix, FixedVector<ArrOfDouble,3>& bubbles_bary);
349 void store_bubbles_barycentres(const Nom& interf_name);
350 void compute_bubbles_volume_and_barycentres(ArrOfDouble& volumes,
351 DoubleTab& barycentres,
352 const int& store_values);
353 void calculer_volume_bulles(ArrOfDouble& volumes,
354 DoubleTab& centre_gravite) const;
355
356 void calculer_aspect_ratio(ArrOfDouble& aspect_ratio) const;
357 void calculer_surfactant(ArrOfDouble& surfactant,ArrOfDouble& surfactant_min,ArrOfDouble& surfactant_max) const;
358 void calculer_poussee_bulles(const DoubleTab& gravite, DoubleTab& poussee) const;
359 void calculer_aire_interfaciale(IJK_Field_double& ai) const;
360 void calculer_aire_interfaciale_for_compo(IJK_Field_double& ai, const int compo) const;
361 double calculer_aire_interfaciale_for_compo(const int compo, const int i_ref, const int j_ref, const int k_ref) const;
362
363 void calculer_normale_et_aire_interfaciale(IJK_Field_double& ai,
364 IJK_Field_double& kappa_ai,
365 IJK_Field_vector3_double& normale_cell) const;
366
367 void compute_drapeaux_vapeur_v2(const IntVect& vecteur_composantes,
368 ArrOfInt& drapeau_liquide) const;
370 const Domaine_IJK& split,
371 const IntVect& vecteur_composantes,
372 ArrOfInt& drapeau_vapeur) const;
373 void compute_drapeaux_vapeur_v4(const IntVect& vecteur_composantes,
374 ArrOfInt& drapeau_vapeur) const;
375
376 void convert_to_IntVect(const ArrOfInt& in, IntVect& out) const;
377
379 IJK_Field_vector3_double& vpoint,
380 IJK_Field_vector3_double& vrepul,
381 IJK_Field_vector3_double& vabsrepul
382 ) const;
383
384 void remailler_interface(const double temps,
385 Maillage_FT_IJK& maillage,
386 ArrOfDouble& var_volume,
387 Remaillage_FT_IJK& algo_remaillage_local);
388
389 int is_terme_gravite_rhog() const;
390 void detecter_et_supprimer_rejeton(bool duplicatas_etaient_presents);
391 void update_surface_normale() const;
392
393 // Permet de recuperer un mcu qui est une vue de maillage_bulles_ft_ijk. Il
394 // n'y a pas de copie memoire, seulement des passages de case memoire.
395 // splitting.get_origin, get_constant_delta(DIRECTION_X),
396 // ...
397 static void get_maillage_MED_from_IJK_FT(MEDCouplingUMesh *maillage_bulles_mcu,
398 const Maillage_FT_IJK& maillage_bulles_ft_ijk);
399
400 const IJK_Field_double& get_surface_interface_old_ft() const { return surface_interface_ft_[old()]; }
401 const IJK_Field_double& get_surface_interface_old() const { return surface_interface_ns_[old()]; }
402 const IJK_Field_double& get_surface_interface_next_ft() const { return surface_interface_ft_[next()]; }
403 const IJK_Field_double& get_surface_interface_next() const { return surface_interface_ns_[next()]; }
404
405 const IJK_Field_vector3_double& get_barycentre_phase1_old_ft() const { return barycentre_phase1_ft_[old()]; }
406 const IJK_Field_vector3_double& get_barycentre_phase1_old() const { return barycentre_phase1_ns_[old()]; }
407 const IJK_Field_vector3_double& get_barycentre_phase1_next_ft() const { return barycentre_phase1_ft_[next()]; }
408 const IJK_Field_vector3_double& get_barycentre_phase1_next() const { return barycentre_phase1_ns_[next()]; }
409
410 double get_barycentre(bool next_time, int bary_compo, int phase, int i, int j, int k) const;
411 double get_barycentre_face(bool next_time, int face_dir, int bary_compo, int phase, int i, int j, int k) const;
412
413 // Getter des surfaces par face
414 const IJK_Field_vector3_double& get_surface_vapeur_par_face_ft() const { return surface_vapeur_par_face_[old()]; }
415 const IJK_Field_vector3_double& get_surface_vapeur_par_face() const { return surface_vapeur_par_face_ns_[old()]; }
416 const IJK_Field_vector3_double& get_indicatrice_surfacique_face_ft() const { return indicatrice_surfacique_face_ft_[old()]; }
417 const IJK_Field_vector3_double& get_indicatrice_surfacique_face_old() const { return indicatrice_surfacique_face_ns_[old()]; }
418 const IJK_Field_vector3_double& get_indicatrice_surfacique_face_next() const { return indicatrice_surfacique_face_ns_[next()]; }
419 const DoubleTabFT_cut_cell_vector3& get_indicatrice_surfacique_efficace_face() const { return indicatrice_surfacique_efficace_face_; }
420 const DoubleTabFT_cut_cell_scalar& get_surface_efficace_interface() const { return surface_efficace_interface_; }
421 const DoubleTabFT_cut_cell_vector3& get_vitesse_deplacement_interface() const { return vitesse_deplacement_interface_; }
422 const DoubleTabFT_cut_cell_vector3& get_normale_deplacement_interface() const { return normale_deplacement_interface_; }
423 const DoubleTabFT_cut_cell_vector3& get_coord_deplacement_interface() const { return coord_deplacement_interface_; }
424
425 // Getter des surfaces par face
426 // void get_surface_vapeur_par_face_ns(IJK_Field_vector3_double &surfs) const ;
427 // Getter des barycentres par face
432 static inline double opposing_barycentre(double initial_barycentre, double initial_area)
433 {
434 double weighted_barycentre = initial_barycentre*initial_area;
435 double opposing_area = 1 - initial_area;
436 double opposing_barycentre = ((opposing_area == 0.) || (opposing_area == 1.)) ? 1./2. : (1./2. - weighted_barycentre)/opposing_area;
437 //if (opposing_barycentre == .5 && (opposing_area > 0. && opposing_area < 1.))
438 // {
439 // assert(false);
440 // }
441 return opposing_barycentre;
442 }
443
444 int get_nb_face_mouillees() const { return n_faces_mouilles_[old()]; }
445
446 // TODO: utiliser le allocate de allocate_velociter dans
447 // IJK_Navier_Stockes_tools.cpp utiliser le pslitting de NS, pas le FT
448
449 //////////////////////////////////////////////////////////////////////
450 // API indicatrice et variables du maillage par cellule et par face //
451 //////////////////////////////////////////////////////////////////////
452
453 static double mean_over_compo(
455 const IJK_Field_int& nb_compo_traversante,
456 const int i,
457 const int j,
458 const int k
459 )
460 {
461 double res = 0.;
462 for (int compo = 0; compo <= nb_compo_traversante(i, j, k); compo++)
463 {
464 res += field_for_compo[compo](i, j, k);
465 }
466 if (nb_compo_traversante(i,j,k) > 0)
467 return res / nb_compo_traversante(i, j, k);
468 else
469 return 0.;
470 }
471
472 static void mean_over_compo(
474 const IJK_Field_int& nb_compo_traversante,
475 IJK_Field_vector3_double& mean_par_compo_field
476 )
477 {
478 const int ni = nb_compo_traversante.ni();
479 const int nj = nb_compo_traversante.nj();
480 const int nk = nb_compo_traversante.nk();
481 for (int dir=0; dir < 3; dir ++)
482 for (int i=0; i < ni; i++)
483 for (int j=0; j < nj; j++)
484 for (int k=0; k < nk; k++)
485 {
486 double res = 0.;
487 for (int compo = 0; compo <= nb_compo_traversante(i, j, k); compo++)
488 {
489 int idx = 3 * compo + dir;
490 const double last_val = field_for_compo[idx](i, j, k);
491 res += last_val;
492 }
493 if (nb_compo_traversante(i,j,k) > 0)
494 res = res / nb_compo_traversante(i, j, k);
495 else
496 res = 0.;
497 mean_par_compo_field[dir](i,j,k) = res;
498 }
499 }
500
501 static double mean_over_compo(
503 const IJK_Field_int& nb_compo_traversante,
504 const int dir,
505 const int i,
506 const int j,
507 const int k
508 )
509 {
510 double res = 0.;
511 for (int compo = 0; compo <= nb_compo_traversante(i, j, k); compo++)
512 {
513 int idx = 3 * compo + dir;
514 const double last_val = field_for_compo[idx](i, j, k);
515 res += last_val;
516 }
517 if (nb_compo_traversante(i,j,k) > 0)
518 return res / nb_compo_traversante(i, j, k);
519 else
520 return 0.;
521 }
522
523 int old() const { return 1 - old_en_premier_; }
524 int next() const { return old_en_premier_; }
525
526 // TODO: retirer l'acces a FT
528 // TODO: retirer l'acces a FT
530
531 // TODO: retirer l'acces a FT
532 const IJK_Field_double& I_ft() const { return indicatrice_ft_[old()]; }
533 const double& I_ft(const int i, const int j, const int k) const { return indicatrice_ft_[old()](i, j, k); }
534 const IJK_Field_double& In_ft() const { return indicatrice_ft_[next()]; }
535 const double& In_ft(const int i, const int j, const int k) const { return indicatrice_ft_[next()](i, j, k); }
536
537 const IJK_Field_vector3_double& BoI() const { return bary_of_interf_ns_[old()]; }
538 const IJK_Field_vector3_double& BoIn() const { return bary_of_interf_ns_[next()]; }
539
540 const IJK_Field_double& I() const { return indicatrice_ns_[old()]; }
541 const IJK_Field_double& In() const { return indicatrice_ns_[next()]; }
542 inline double I(const int i, const int j, const int k) const { return indicatrice_ns_[old()](i, j, k); }
543 inline double In(const int i, const int j, const int k) const { return indicatrice_ns_[next()](i, j, k); }
544
545 static int convert_indicatrice_to_phase(double indicatrice)
546 {
547 assert(est_pure(indicatrice));
548 int phase = (int)indicatrice;
549 return phase;
550 }
551
552 // Indicatrice non-zero : Cette indicatrice est utilisee pour calculer l'energie vol*indicatrice*T d'une cellule coupee en Probleme_FTD_IJK_cut_cell.
553 // Pour ne pas perdre d'information, le volume de l'autre temps est utilise si le volume est zero pour le temps consideree.
554 inline double I_nonzero(const int phase, const int i, const int j, const int k) const
555 {
556 double current_indic = (phase == 0) ? 1 - I(i, j, k) : I(i, j, k);
557 if (current_indic == 0)
558 {
559 double other_indic = (phase == 0) ? 1 - In(i, j, k) : In(i, j, k);
560 return (other_indic == 0) ? 1. : other_indic;
561 }
562 else
563 {
564 return current_indic;
565 }
566 }
567 inline double In_nonzero(const int phase, const int i, const int j, const int k) const
568 {
569 double current_indic = (phase == 0) ? 1 - In(i, j, k) : In(i, j, k);
570 if (current_indic == 0)
571 {
572 double other_indic = (phase == 0) ? 1 - I(i, j, k) : I(i, j, k);
573 return (other_indic == 0) ? 1. : other_indic;
574 }
575 else
576 {
577 return current_indic;
578 }
579 }
580
581 static inline int est_pure(double indicatrice) { return ((indicatrice == 0.) || (indicatrice == 1.)); }
582 static inline int devient_pure(double old_indicatrice, double next_indicatrice) { return ((!est_pure(old_indicatrice)) && (est_pure(next_indicatrice))); }
583 static inline int devient_diphasique(double old_indicatrice, double next_indicatrice) { return ((est_pure(old_indicatrice)) && (!est_pure(next_indicatrice))); }
584 static inline int phase_mourrante(int phase, double old_indicatrice, double next_indicatrice) { return devient_pure(old_indicatrice, next_indicatrice) && (IJK_Interfaces::convert_indicatrice_to_phase(1 - next_indicatrice) == phase); }
585 static inline int phase_naissante(int phase, double old_indicatrice, double next_indicatrice) { return devient_diphasique(old_indicatrice, next_indicatrice) && (IJK_Interfaces::convert_indicatrice_to_phase(1 - old_indicatrice) == phase); }
586 inline double devient_pure(const int i, const int j, const int k) const { return devient_pure(indicatrice_ns_[old()](i, j, k), indicatrice_ns_[next()](i, j, k)); }
587 inline double devient_diphasique(const int i, const int j, const int k) const { return devient_diphasique(indicatrice_ns_[old()](i, j, k), indicatrice_ns_[next()](i, j, k)); }
588 inline double phase_mourrante(const int phase, const int i, const int j, const int k) const { return phase_mourrante(phase, indicatrice_ns_[old()](i, j, k), indicatrice_ns_[next()](i, j, k)); }
589 inline double phase_naissante(const int phase, const int i, const int j, const int k) const { return phase_naissante(phase, indicatrice_ns_[old()](i, j, k), indicatrice_ns_[next()](i, j, k)); }
590
591 inline int est_reguliere(double old_indicatrice, double next_indicatrice) const { return ((old_indicatrice >= seuil_indicatrice_petite_) && (old_indicatrice <= 1-seuil_indicatrice_petite_) && (next_indicatrice >= seuil_indicatrice_petite_) && (next_indicatrice <= 1-seuil_indicatrice_petite_)); }
592
593 inline int est_desequilibre(double indicatrice) const { return (((indicatrice < seuil_indicatrice_petite_) || (indicatrice > 1-seuil_indicatrice_petite_)) && (!est_pure(indicatrice))); }
594 inline int a_desequilibre_final(double old_indicatrice, double next_indicatrice) const { return est_desequilibre(next_indicatrice) && (!devient_diphasique(old_indicatrice, next_indicatrice)); }
595 inline int a_desequilibre_initial_uniquement(double old_indicatrice, double next_indicatrice) const { return est_desequilibre(old_indicatrice) && (!a_desequilibre_final(old_indicatrice, next_indicatrice)) && (!devient_pure(old_indicatrice, next_indicatrice)); }
596
597 inline int below_small_threshold(double indicatrice) const { return ((indicatrice < seuil_indicatrice_petite_) && (!est_pure(indicatrice))); }
598 inline int next_below_small_threshold(double old_indicatrice, double next_indicatrice) const { return below_small_threshold(next_indicatrice) && (!devient_diphasique(old_indicatrice, next_indicatrice)); }
599 inline int only_old_below_small_threhshold(double old_indicatrice, double next_indicatrice) const { return below_small_threshold(old_indicatrice) && (!next_below_small_threshold(old_indicatrice, next_indicatrice)) && (!devient_pure(old_indicatrice, next_indicatrice)); }
600 inline int next_below_small_threshold_for_phase(int phase, double old_indicatrice, double next_indicatrice) const { return (phase ==0) ? next_below_small_threshold(1 - old_indicatrice, 1 - next_indicatrice) : next_below_small_threshold(old_indicatrice, next_indicatrice); }
601 inline int only_old_below_small_threshold_for_phase(int phase, double old_indicatrice, double next_indicatrice) const { return (phase ==0) ? only_old_below_small_threhshold(1 - old_indicatrice, 1 - next_indicatrice) : only_old_below_small_threhshold(old_indicatrice, next_indicatrice); }
602
603 const double& SI(const int compo, const int i, const int j, const int k) const
604 {
605 return surface_par_compo_[old()][compo](i, j, k);
606 }
607 double SI(const int i, const int j, const int k) const
608 {
609 double res = mean_over_compo(surface_par_compo_[old()], nb_compo_traversante_[old()], i, j, k);
610 return res;
611 }
612
617 // const double& SIn(const int compo, const int i, const int j, const int k)
618 // const {
619 // return surface_par_compo_next_[compo](i,j,k);
620 // }
621 // double SIn(const int i, const int j, const int k) const {
622 // double res = mean_over_compo(surface_par_compo_next_, i,j,k);
623 // return res;
624 // }
625
626 // Les composantes (dir) du vecteur normal moyen pour chaque compo comnnexe
627 // (c) de bulle dans le maille (compo = max_nb_of_compo_ * c + dir)
628 const double& nI(const int compo, const int i, const int j, const int k) const
629 {
630 return normal_of_interf_ns_[old()][compo](i, j, k);
631 }
632 Vecteur3 nI(const int i, const int j, const int k) const
633 {
634 const Vecteur3 res(normal_of_interf_ns_[old()][0](i, j, k),
635 normal_of_interf_ns_[old()][1](i, j, k),
636 normal_of_interf_ns_[old()][2](i, j, k));
637 return res;
638 }
639 const double& nIn(const int compo, const int i, const int j, const int k) const
640 {
641 return normal_of_interf_ns_[next()][compo](i, j, k);
642 }
643 Vecteur3 nIn(const int i, const int j, const int k) const
644 {
645 const Vecteur3 res(normal_of_interf_ns_[next()][0](i, j, k),
646 normal_of_interf_ns_[next()][1](i, j, k),
647 normal_of_interf_ns_[next()][2](i, j, k));
648 return res;
649 }
650
651 // Les composantes (dir) du barycentre de l'interface pour chaque compo
652 // comnnexe (c) de bulle dans le maille (compo = max_nb_of_compo_ * c + dir)
653 const double& xI(const int compo, const int i, const int j, const int k) const
654 {
655 return bary_of_interf_ns_[old()][compo](i, j, k);
656 }
657 Vecteur3 xIn(const int i, const int j, const int k) const
658 {
659 const Vecteur3 res(bary_of_interf_ns_[next()][0](i, j, k),
660 bary_of_interf_ns_[next()][1](i, j, k),
661 bary_of_interf_ns_[next()][2](i, j, k));
662 return res;
663 }
664 Vecteur3 xI(const int i, const int j, const int k) const
665 {
666 const Vecteur3 res(bary_of_interf_ns_[old()][0](i, j, k),
667 bary_of_interf_ns_[old()][1](i, j, k),
668 bary_of_interf_ns_[old()][2](i, j, k));
669 return res;
670 }
671
672 // Surface de la vapeur sur la face dans la direction compo de la cellule ijk
673 const double& Sf(const int compo, const int i, const int j, const int k) const
674 {
675 return surface_vapeur_par_face_ns_[old()][compo](i, j, k);
676 }
677 // Surface de la vapeur sur la face dans la direction compo de la cellule ijk
678 // au temps n+1
679 const double& Sfn(const int compo, const int i, const int j, const int k) const
680 {
681 return surface_vapeur_par_face_ns_[next()][compo](i, j, k);
682 }
683 // Surface de la vapeur sur la face dans la direction compo de la cellule ijk
684 // moyennee entre n et n+1.
685 // TODO: faire un tableau surface_vapeur_par_face_moy et le calculer en
686 // faisant la moyenne sur plusieurs petits pas.
687 double Sfm(const int compo, const int i, const int j, const int k) const
688 {
689 return (surface_vapeur_par_face_ns_[old()][compo](i, j, k) + surface_vapeur_par_face_ns_[next()][compo](i, j, k)) * 0.5;
690 }
691
692 void update_old_intersections(); // Copie de l'interface et des intersections associees au pas de temps precedent
695 const DoubleTab& gravite,
696 const double delta_rho,
697 const double sigma,
698 const double time,
699 const int itstep,
700 const bool parcourir = true
701 );
703 IJK_Field_double& indicatrice_intermediaire_ft_,
704 IJK_Field_double& indicatrice_intermediaire_ns_,
705 IJK_Field_vector3_double& indicatrice_surfacique_intermediaire_face_ft_,
706 IJK_Field_vector3_double& indicatrice_surfacique_intermediaire_face_ns_,
707 const bool parcourir = true
708 );
729 void set_compute_surfaces_mouillees() { surface_vapeur_par_face_computation_.set_compute_surfaces_mouillees(); }
730
731 const int& nb_compo_traversantes(const int i, const int j, const int k) const
732 {
733 return nb_compo_traversante_[next()](i,j,k);
734 }
735
741
743 {
745 return;
746 ijk_compo_connex_.compute_bounding_box_fill_compo_connex();
747 }
748
750 {
752 return;
753 ijk_compo_connex_.compute_compo_connex_from_interface();
754 }
755
757 {
759 return;
760 ijk_compo_connex_.initialise_bubbles_params();
761 }
762
763 void allocate_ijk_compo_connex_fields(const Domaine_IJK& splitting, const int& allocate_compo_fields)
764 {
766 return;
767 ijk_compo_connex_.allocate_fields(splitting, allocate_compo_fields);
768 }
769
771 const int& compute_rising_velocities,
772 const int& fill_rising_velocities,
773 const int& use_bubbles_velocities_from_interface,
774 const int& use_bubbles_velocities_from_barycentres)
775 {
777 return;
778 ijk_compo_connex_.associate_rising_velocities_parameters(splitting,
779 compute_rising_velocities,
780 fill_rising_velocities,
781 use_bubbles_velocities_from_interface,
782 use_bubbles_velocities_from_barycentres);
783 }
784
786 {
788 return;
789 ijk_compo_connex_.compute_rising_velocities();
790 }
791
792 const DoubleTab& get_bubble_barycentres_old_new(const int& get_new) const
793 {
794 if (get_new)
795 return bubbles_bary_new_;
796 else
797 return bubbles_bary_old_;
798 }
799
804
806
807protected:
808 // Met a jour les valeurs de surface_vapeur_par_face_ et barycentre_vapeur_par_face_
810
812
813 void verif_indic() ;
814
816 ArrOfDouble& potentiels_sommets,
817 ArrOfDouble& repulsions_sommets,
818 const DoubleTab& gravite,
819 const double delta_rho,
820 const double sigma,
821 const double time,
822 const int itstep
823 );
824
830 const DoubleTab& gravite,
831 const double delta_rho,
832 const double sigma,
833 const double time,
834 const int itstep
835 );
836
837 void calculer_indicatrice(IJK_Field_double& indic);
838 void calculer_indicatrice_optim(IJK_Field_double& indic);
839 void calculer_indicatrices(IJK_Field_vector3_double& indic);
840 void calculer_indicatrices_optim(IJK_Field_vector3_double& indic);
841
842 // Methode qui parcourt tous les elements de indic et met a jour uniquement
843 // ceux qui etaient traverses par l'interface a l'iteration precedente et qui
844 // ne le sont plus a l'iteration courante ces elements ont ete marques au
845 // prealable
846 int update_indicatrice(IJK_Field_double& indic);
847
848 void calculer_surface_interface(IJK_Field_double& surf_interface, IJK_Field_double& indic);
849 void calculer_barycentre(IJK_Field_vector3_double& baric, IJK_Field_double& indic);
850 void calculer_indicatrice_surfacique_face(IJK_Field_vector3_double& indic_surfacique_face, IJK_Field_double& indic, IJK_Field_vector3_double& norme);
851 void calculer_indicatrice_surfacique_barycentre_face(IJK_Field_vector3_double& indic_surfacique_face, FixedVector<FixedVector<IJK_Field_double, 2>, 3>& baric_face, IJK_Field_double& indic, IJK_Field_vector3_double& norme);
852
853
854 // Cette methode appelle la methode statique get_maillage_MED_from_IJK_FT sur
855 // ses propres membres. Elle met donc a jour le maillage maillage_bulles_med_.
856
857 // TODO: utiliser le allocate de allocate_velocity dans IJK_Navier_Stokes_tools.cpp utiliser le pslitting de NS, pas le FT
858
860 const ArrOfDouble& surface_facette,
861 const ArrOfDouble& surface_par_bulle,
862 const ArrOfInt& compo_connexes_facettes,
863 const int nbulles_reelles,
864 const int nbulles_ghost,
865 const DoubleTab& vitesse_sommets,
866 DoubleTab& vitesses_translation_sommets) const;
868 const ArrOfDouble& surface_facette,
869 const ArrOfDouble& surface_par_bulle,
870 const ArrOfInt& compo_connexes_facettes,
871 const int nbulles_reelles,
872 const int nbulles_ghost,
873 const DoubleTab& centre_gravite,
874 const DoubleTab& vitesse_sommets,
875 const DoubleTab& vitesse_translation_sommets,
876 DoubleTab& mean_bubble_rotation_vector) const;
877 void recursive_calcul_distance_chez_voisin(DoubleTab& vinterp_tmp,
878 int dir,
879 const Maillage_FT_IJK& mesh,
880 DoubleTab& coord_sommets,
881 ArrOfInt& compo_sommet,
882 ArrOfDouble& distance,
883 DoubleTab& v_closer,
884 double distmax);
885 void calculer_distance_autres_compo_connexe2(ArrOfDouble& distance,
886 DoubleTab& v_closer);
887 void calculer_distance_autres_compo_connexe_octree(const DoubleTab& sommets_a_tester,
888 const ArrOfInt& compo_connexe_sommets,
889 const DoubleTab& vinterp_tmp,
890 const Maillage_FT_IJK& mesh,
891 ArrOfDouble& distance,
892 DoubleTab& v_closer,
893 const double distmax);
894
895 void calculer_distance_autres_compo_connexe_ijk(const DoubleTab& sommets_a_tester,
896 const ArrOfInt& compo_connexe_sommets,
897 const DoubleTab& vinterp_tmp,
898 const Maillage_FT_IJK& mesh,
899 ArrOfDouble& distance,
900 DoubleTab& v_closer,
901 const double distmax);
902
903// reference vers le splitting_ft_ pour les interfaces :
904 OBS_PTR(Domaine_IJK) ref_domaine_;
905 OBS_PTR(Domaine_dis_base) refdomaine_dis_;
907 OBS_PTR(Switch_FT_double) ref_ijk_ft_switch_;
908
909 // Ou lire le maillage initial, dans la methode initialize():
910 // On peut reprendre un fichier lata ou sauv.lata :
911
912 IntVect num_compo_;
914 // variales pour calcul a bulles fixes
915 DoubleTab mean_force_;
916 DoubleTab force_time_n_;
918 int flag_positions_reference_ = 0; // Pas de position de reference imposee
919
923
924 // Pour ecrire dans le fichier sauv :
927
928 // Activation du suivi des couleurs des bulles
929 bool follow_colors_ = false;
930
931 // Activer la repulsion aux parois :
934 // La repulsion paroi est desactive par defaut,
935 // meme si l'inter-bulles l'est
936
937 // Pour calculer le terme source comme grad(potentiel*I) au lieu de
938 // potentiel_face*gradI
939 // Modification de l'evaluation du potentiel :
941
943 // recompute_indicator_ = 1; // doit-on calculer l'indicatrice avec une methode
944 // de debug (1) ou optimisee (0) ?
945
946 // Nombres de bulles reeles :
951 int parser_ = 0;
952 // doit-on calculer le forcage avec une methode de parser (1,
953 // lente) ou optimisee basee sur le num_compo_ (0) ?
954 // Dans le cas ou parser_ est a zero, il faut que
955 // recompute_indicator_ soit a 1, car c'est cette methode qui
956 // rempli num_compo_
957
958 // Stockage du maillage:
961
962 // Tableau intermediaire pour le deplacement des marqueurs en RK3 :
964 DoubleTab vinterp_;
965
966 int disable_rigid_translation_ = 0; // Desactive la partie translation du mouvement rigide
967 int disable_rigid_rotation_ = 1; // Desactive la partie rotation du mouvement rigide
968
969 ArrOfDouble var_volume_deformation_; // Variation de volume observee sur chaque sommet lors de la deformation de la bulle
970 ArrOfDouble var_volume_remaillage_; // Variation de volume cible pour l'operation de remaillage
971 ArrOfDouble var_volume_correction_globale_; // Variation de volume cible pour la correction globale de volume
972
973 IJK_Field_vector3_double deformation_velocity_;
974
975 // Algorithmes de parcours de l'interface (intersections Eulerien/Lagrangien)
977 // Le parcours a besoin d'une connectivite des faces de bords du maillage
978 // eulerien
980 // Algorithme de remaillage local
982
983 // Donnees sur la maillage NS : sa bounding_box et la periodicite :
985 bool perio_NS_[3];
986
987 bool avoid_duplicata_ = false;
989
990 // Domaine autorise pour les bulles :
991 // c'est le geom du splitting_FT reduit de ncells_forbidden_
992 // dans toutes les direction ou le domaine NS est perio.
993 // ncells_forbidden_ est le nombre de mailles au bord du domaine etendu ou on
994 // interdit a des bulles d'entrer (bulles detruites et remplacees par leur
995 // duplicata de l'autre cote)
996 int ncells_forbidden_ = 3; // Valeur recommandee par defaut.
997 // Suppression des bulles sur le pourtour du domaine lors de la sauvegarde
998 // finale.
999 int ncells_deleted_ = -1; // Valeur recommandee par defaut. On ne veut pas supprimer de bulles.
1000 bool frozen_ = false; // flag to disable the interfaces motion. By default, we want the motion of the interfaces.
1003
1004 // Domaine a l'interieur duquel la duplication d'une bulle est inutile
1006
1007 // Distance max en metres a laquelle agit la force de repulsion entre les
1008 // bulles
1010 // delta de pression maxi cree par la force de repulsion
1011 // (pour l'instant lineaire, valeur max quand la distance est nulle)
1012 double delta_p_max_repulsion_ = 0.; // desactive par defaut
1013
1014 // Si souhaite, une valeur differente pour les parois :
1016 double delta_p_wall_max_repulsion_ = 0.; // desactive par defaut
1017 int no_octree_method_ = 0; // to use the IJK-discretization to search for closest faces of vertices instead of the octree method (disabled by default)
1018
1020
1021 // Pour chaque bulle, a-t-elle traverse la frontiere perio y?
1022 ArrOfInt through_yminus_; // 0 : On ne sait pas
1023 // 1 : entree par yminus
1024 // -1 : entree par yplus
1025
1027
1028 int reprise_ = 0; // Flag indiquant si on fait une reprise
1029
1031 // Terme_Gravite terme_gravite_;
1032 int terme_gravite_ = GRAVITE_GRAD_I; // Par defaut terme gravite ft sans courants parasites
1033
1034 int nb_groups_ = 1; // Nombre de groupes/classes de bulles. Par defaut toutes les bulles sont dans le meme group.
1035 ArrOfInt compo_to_group_; // Tableau de conversion: numero_de_groupe =
1036 // compo_to_group_[icompo]
1037
1038 /////////////////////////////////////////////////////////////////
1039 // Tableau des valeurs aux faces mouillees (calcules avec med) //
1040 /////////////////////////////////////////////////////////////////
1041
1042 bool compute_surf_mouillees_ = false; // active seulement dans le cas
1043 // ou il y a des champs thermique ou d energie.
1044 // attention, ca desactive seulement le calcul, pas l'allocation.
1046
1047 // Surfaces vapeur des faces du maillage IJK
1050
1051 // Normale de l'interface par maille ijk sur domaine NS
1054 // Barycentre de l'interface par maille ijk sur domaine NS
1057
1058 // Barycentres vapeur des faces du maillage IJK
1061
1062 /////////////////////////////////////
1063 // indicatrice et var moy par cell //
1064 /////////////////////////////////////
1065
1067 bool old_en_premier_ = true;
1068
1071
1072 // Indicatrice apres la deformation de l'interface mais avant le remaillage/lissage de l'interface
1075
1076 // Indicatrice apres le remaillage/lissage de l'interface mais avant le deplacement rigide
1079
1080 // Indicatrice cible apres le remaillage. Le remaillage vise a atteindre cette indicatrice.
1082
1085
1088
1089
1090 IJK_Field_double field_repulsion_;
1091
1092 // Indicatrice surfacique aux faces du maillage cartesien,
1093 // indiquant la fraction de la surface de chaque face associee a la phase.
1094 // Note : similaire a surface_vapeur_par_face_, mais sans medcoupling.
1097
1098 // Indicatrice surfacique apres la deformation de l'interface mais avant le remaillage/lissage de l'interface
1101
1102 // Indicatrice surfacique apres le remaillage/lissage de l'interface mais avant le deplacement rigide (pas utilisee)
1105
1108
1109 // On prevoie un tableau assez grand pour contenir tous les groupes.
1112
1113#if VERIF_INDIC
1114 // pour verifier le calcul optimise de l'indicatrice
1115 IJK_Field_double indicatrice_ft_test_;
1117#endif
1118
1119 // Vecteur des composantes normale dans chaque cellule par composante connexe
1134
1137
1149
1155
1156 // Pour le calcul des champs cut-cell
1158 DoubleTabFT_cut_cell_vector3 indicatrice_surfacique_efficace_face_;
1162 IJK_Field_vector3_double indicatrice_surfacique_efficace_deformation_face_; // ne peut etre sur la structure diphasique, car cree et utilisee avant
1163 DoubleTabFT_cut_cell_scalar surface_efficace_interface_;
1164 DoubleTabFT_cut_cell_scalar surface_efficace_interface_initial_;
1165 DoubleTabFT_cut_cell_vector3 coord_deplacement_interface_;
1166 DoubleTabFT_cut_cell_vector3 vitesse_deplacement_interface_;
1167 DoubleTabFT_cut_cell_vector3 normale_deplacement_interface_;
1168
1169 std::map<Motcle, IJK_Field_double> scalar_post_fields_;
1170
1171private:
1172
1173 Champs_compris_IJK champs_compris_;
1174
1175};
1176
1177#endif /* IJK_Interfaces_included */
Classe Champ_Inc_base.
classe Champ_base Cette classe est la base de la hierarchie des champs.
Definition Champ_base.h:43
Similar to Champs_compris_interface but for IJK scalar and vector fields.
Same as Champs_compris, but specialised for IJK fields and also supports quering for vectorial fields...
This class encapsulates all the information related to the eulerian mesh for TrioIJK.
Definition Domaine_IJK.h:47
classe Domaine_dis_base Cette classe est la base de la hierarchie des domaines discretisees.
Class defining operators and methods for all reading operation in an input flow (file,...
Definition Entree.h:42
classe Equation_base Le role d'une equation est le calcul d'un ou plusieurs champs....
Domaine_dis_base & domaine_dis()
Renvoie le domaine discretise associe a l'equation.
The class IJK_Field_vector is a fixed array of polymorphic IJK fields.
: class IJK_Interfaces
void reset_flags_and_counters()
ArrOfInt ghost_compo_converter_
const Remaillage_FT_IJK & remaillage_ft_ijk() const
void calculer_kappa_ft(IJK_Field_double &kappa_ft)
int is_frozen() const
void associate_rising_velocities_parameters(const Domaine_IJK &splitting, const int &compute_rising_velocities, const int &fill_rising_velocities, const int &use_bubbles_velocities_from_interface, const int &use_bubbles_velocities_from_barycentres)
void calculer_surface_interface(IJK_Field_double &surf_interface, IJK_Field_double &indic)
const IJK_Field_vector< double, max_authorized_nb_of_groups_ > & groups_indicatrice_ft() const
const IJK_Field_double & get_surface_interface_next() const
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > phi_par_compo_
DoubleTab positions_reference_
ArrOfDoubleFT distance_autres_interfaces_
FixedVector< IJK_Field_vector3_double, 2 > indicatrice_surfacique_face_ft_
IJK_Field_vector3_double deformation_velocity_
void set_fichier_sauvegarde(const char *lataname)
const DoubleTabFT_cut_cell_vector3 & get_indicatrice_surfacique_efficace_face() const
static double opposing_barycentre(double initial_barycentre, double initial_area)
Vecteur3 nI(const int i, const int j, const int k) const
SurfaceVapeurIJKComputation surface_vapeur_par_face_computation_
void verif_indic()
int posttraiter_champs_instantanes(const Motcles &liste_post_instantanes, const char *lata_name, const int lata_step) const
double portee_force_repulsion_
const DoubleTabFT_cut_cell_vector3 & get_vitesse_deplacement_interface() const
double phase_mourrante(const int phase, const int i, const int j, const int k) const
const Milieu_base & milieu() const override
void calculer_surfactant(ArrOfDouble &surfactant, ArrOfDouble &surfactant_min, ArrOfDouble &surfactant_max) const
const ArrOfDouble & get_bubbles_velocities_magnitude_from_barycentres() const
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > indicatrice_par_compo_
const DoubleTab & get_bubble_barycentres_old_new(const int &get_new) const
void set_reprise(const int i)
int follow_colors() const
void compute_surface_average_per_bubble(const ArrOfDouble &surfaces, const ArrOfDouble &in, ArrOfDouble &out) const
void ajouter_terme_source_interfaces(IJK_Field_vector3_double &vpoint, IJK_Field_vector3_double &vrepul, IJK_Field_vector3_double &vabsrepul) const
const Intersection_Interface_ijk_face & get_intersection_ijk_face() const
const Operateur & operateur(int) const override
const IJK_Field_vector< double, max_authorized_nb_of_groups_ > & groups_indicatrice_n_ns() const
int is_terme_gravite_rhog() const
Probleme_FTD_IJK_base & probleme_ijk()
int a_desequilibre_final(double old_indicatrice, double next_indicatrice) const
FixedVector< IJK_Field_double, 2 > indicatrice_ns_
void initialize(const Domaine_IJK &splitting_FT, const Domaine_IJK &splitting_NS, const Domaine_dis_base &domaine_dis, const int thermal_probes_ghost_cells=0, const bool compute_vint=true, const bool is_switch=false)
int only_old_below_small_threshold_for_phase(int phase, double old_indicatrice, double next_indicatrice) const
double Sfm(const int compo, const int i, const int j, const int k) const
DoubleTab bubbles_velocities_
Nom fichier_sauvegarde_interface_
void set_param_reprise_pb(Param &)
int get_nb_bulles_ghost(const int print=0) const
Vecteur3 xI(const int i, const int j, const int k) const
friend class IJK_Composantes_Connex
ArrOfInt compo_to_group_
void set_compute_surfaces_mouillees()
void deplacer_bulle_perio(const ArrOfInt &masque_deplacement_par_compo)
double factor_length_duplicata_
void calculer_var_volume_remaillage(double timestep, const DoubleTab &vitesses_translation_bulles, const DoubleTab &mean_bubble_rotation_vector, const DoubleTab &centre_gravite, ArrOfDouble &var_volume)
void calculer_indicatrices(IJK_Field_vector3_double &indic)
void supprimer_certaines_bulles_reelles()
void posttraiter_tous_champs(Motcles &liste) const
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > surface_par_compo_
const ArrOfDoubleFT & get_distance_autres_interfaces() const
void transporter_maillage_deformation(const int correction_semi_locale_volume_bulle, const DoubleTab &vitesses_translation_bulles, const DoubleTab &mean_bubble_rotation_vector, const DoubleTab &centre_gravite, const double dt_tot, ArrOfDouble &dvol, const int rk_step, const int first_step_interface_smoothing=0)
double seuil_indicatrice_negligeable_
void calculer_indicatrice_optim(IJK_Field_double &indic)
const double & nIn(const int compo, const int i, const int j, const int k) const
int next() const
int est_reguliere(double old_indicatrice, double next_indicatrice) const
DoubleTab bubbles_bary_old_
const IJK_Field_double & I_ft() const
static int devient_diphasique(double old_indicatrice, double next_indicatrice)
const double & SI(const int compo, const int i, const int j, const int k) const
void completer() override
Complete la construction (initialisation) des objets associes a l'equation.
const FixedVector< FixedVector< IJK_Field_double, 2 >, 3 > & get_barycentre_phase1_face_ft() const
void compute_drapeaux_vapeur_v3(const Maillage_FT_IJK &mesh, const Domaine_IJK &split, const IntVect &vecteur_composantes, ArrOfInt &drapeau_vapeur) const
DoubleTabFT_cut_cell_vector3 vitesse_deplacement_interface_
void calculer_color(ArrOfInt &color) const
void calculer_indicatrice_apres_remaillage(const bool parcourir=true)
void calculer_vitesse_de_deformation(int compo, const DoubleTab &bounding_box_bulles, const Cut_field_vector3_double &cut_field_velocity, const DoubleTab &vitesses_translation_bulles, const DoubleTab &mean_bubble_rotation_vector, const DoubleTab &positions_bulles)
int lire_motcle_non_standard(const Motcle &un_mot, Entree &is) override
Lecture des parametres de type non simple d'un objet_U a partir d'un flot d'entree.
int timestep_sauvegarde_interface_
FixedVector< IJK_Field_double, 2 > surface_interface_ns_
const FixedVector< FixedVector< IJK_Field_double, 2 >, 3 > & get_barycentre_phase1_face() const
ArrOfDouble var_volume_correction_globale_
void compute_indicatrice_non_perturbe(IJK_Field_double &indic_np, const IJK_Field_double &indic, const ArrOfDouble &volume_reel, const DoubleTab &position) const
const Domaine_dis_base & get_domaine_dis() const
void associer_pb_base(const Probleme_base &) override
S'associe au Probleme passe en parametre.
Intersection_Interface_ijk_face & get_set_intersection_ijk_face()
FixedVector< IJK_Field_vector3_double, 2 > bary_of_interf_ns_
double delta_p_wall_max_repulsion() const
int compute_list_compo_connex_in_element(const Maillage_FT_IJK &mesh, const int elem, ArrOfInt &liste_composantes_connexes_dans_element) const
int get_ghost_number_from_compo(const int compo) const
const DoubleTab & get_bubble_rising_vectors_from_barycentres() const
const IntVect & get_num_compo() const
void calculer_aire_interfaciale_for_compo(IJK_Field_double &ai, const int compo) const
bool has_readen_barycentres_prev_
DoubleTabFT_cut_cell_scalar surface_efficace_interface_
Champ_Inc_base & inconnue() override
void calculer_vmoy_translation_composantes_connexes(const Maillage_FT_IJK &maillage, const ArrOfDouble &surface_facette, const ArrOfDouble &surface_par_bulle, const ArrOfInt &compo_connexes_facettes, const int nbulles_reelles, const int nbulles_ghost, const DoubleTab &vitesse_sommets, DoubleTab &vitesses_translation_sommets) const
DoubleTab mean_force_
const IJK_Field_double & I() const
void transporter_maillage_remaillage(int correction_semi_locale_volume_bulle, const DoubleTab &vitesses_translation_bulles, const DoubleTab &mean_bubble_rotation_vector, const DoubleTab &centre_gravite, double dt_tot, ArrOfDouble &dvol, const int rk_step, const double temps)
int get_flag_positions_reference() const
IJK_Field_double indicatrice_apres_remaillage_ft_
void update_indicatrice_variables_monofluides()
FixedVector< IJK_Field_vector3_double, 2 > indicatrice_surfacique_face_ns_
int old() const
void compute_drapeaux_vapeur_v2(const IntVect &vecteur_composantes, ArrOfInt &drapeau_liquide) const
DoubleTabFT_cut_cell_vector3 indicatrice_surfacique_efficace_face_initial_
FixedVector< FixedVector< IJK_Field_double, 3 *max_authorized_nb_of_components_ >, 2 > bary_par_compo_
const FixedVector< IJK_Field_vector3_double, 3 > & get_barycentre_vapeur_par_face_ft() const
DoubleTab RK3_G_store_vi_
const ArrOfInt & get_compo_to_group() const
OBS_PTR(Probleme_FTD_IJK_base) ref_ijk_ft_
FixedVector< FixedVector< IJK_Field_double, 3 *max_authorized_nb_of_components_ >, 2 > normale_par_compo_
IJK_Field_vector3_double indicatrice_surfacique_avant_remaillage_face_ft_
IJK_Composantes_Connex ijk_compo_connex_
const DoubleTabFT_cut_cell_vector3 & get_coord_deplacement_interface() const
void convert_to_IntVect(const ArrOfInt &in, IntVect &out) const
DoubleTab bubbles_bary_new_
FixedVector< FixedVector< FixedVector< IJK_Field_double, 2 >, 3 >, 2 > barycentre_phase1_face_ns_
const Champ_Inc_base & inconnue() const override
void dupliquer_bulle_perio(ArrOfInt &masque_duplicata_pour_compo)
const DoubleTab & get_bubble_velocities_from_barycentres() const
const IJK_Field_vector< double, max_authorized_nb_of_groups_ > & groups_indicatrice_ns() const
OBS_PTR(Domaine_dis_base) refdomaine_dis_
ArrOfDouble var_volume_deformation_
double I(const int i, const int j, const int k) const
void calculer_barycentre(IJK_Field_vector3_double &baric, IJK_Field_double &indic)
const IJK_Field_vector3_double & get_barycentre_phase1_next_ft() const
const DoubleTab & get_bubble_velocities_from_interface() const
double In_nonzero(const int phase, const int i, const int j, const int k) const
std::map< Motcle, IJK_Field_double > scalar_post_fields_
const IJK_Field_vector3_double & get_surface_vapeur_par_face_ft() const
ArrOfDouble var_volume_remaillage_
Remaillage_FT_IJK remaillage_ft_ijk_
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > grady_sigma_par_compo_
int get_nb_bulles_reelles() const
static int phase_naissante(int phase, double old_indicatrice, double next_indicatrice)
FixedVector< IJK_Field_int, 2 > nb_compo_traversante_
void set_fichier_reprise(const char *lataname)
void compute_compo_connex_from_bounding_box()
void preparer_duplicata_bulles(const DoubleTab &bounding_box_of_bubbles, const DoubleTab &bounding_box_offsetp, const DoubleTab &bounding_box_offsetm, const DoubleTab &authorized_bounding_box, ArrOfInt &masque_duplicata_pour_compo_reel)
int get_nb_face_mouillees() const
int ghost_compo_converter(const int i) const
int dt_impression_bilan_indicatrice_
bool read_bubbles_barycentres_vel(const Nom &interf_name, FixedVector< ArrOfDouble, 3 > &bubbles_rising_dir, FixedVector< ArrOfDouble, 3 > &bubbles_rising_vel, ArrOfDouble &bubbles_rising_vel_mag)
const double & nI(const int compo, const int i, const int j, const int k) const
const IJK_Field_vector3_double & get_indicatrice_surfacique_face_old() const
bool has_champ(const Motcle &nom) const override
DoubleTab bubbles_velocities_bary_
FixedVector< IJK_Field_vector3_double, 2 > normal_of_interf_
void discretiser() override
Discretise l'equation.
double I_nonzero(const int phase, const int i, const int j, const int k) const
Parcours_interface parcours_
void calculer_phi_repuls_sommet(ArrOfDouble &potentiels_sommets, ArrOfDouble &repulsions_sommets, const DoubleTab &gravite, const double delta_rho, const double sigma, const double time, const int itstep)
double portee_wall_repulsion_
FixedVector< IJK_Field_vector3_double, 2 > barycentre_phase1_ft_
DoubleTabFT_cut_cell_vector3 indicatrice_surfacique_efficace_face_
void postraiter_colors(Sortie &os, const double current_time) const
bool read_bubbles_barycentres(const Nom &interf_name, const Nom &suffix, FixedVector< ArrOfDouble, 3 > &bubbles_bary)
void get_noms_champs_postraitables(Noms &noms, Option opt=NONE) const override
FixedVector< FixedVector< FixedVector< IJK_Field_double, 2 >, 3 >, 2 > barycentre_phase1_face_ft_
void calculer_indicatrice_surfacique_barycentre_face(IJK_Field_vector3_double &indic_surfacique_face, FixedVector< FixedVector< IJK_Field_double, 2 >, 3 > &baric_face, IJK_Field_double &indic, IJK_Field_vector3_double &norme)
int get_recompute_indicator() const
void calculer_aire_interfaciale(IJK_Field_double &ai) const
int only_old_below_small_threhshold(double old_indicatrice, double next_indicatrice) const
int next_below_small_threshold(double old_indicatrice, double next_indicatrice) const
void calculer_normale_et_aire_interfaciale(IJK_Field_double &ai, IJK_Field_double &kappa_ai, IJK_Field_vector3_double &normale_cell) const
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > gradx_sigma_par_compo_
const IJK_Field_vector3_double & get_surface_vapeur_par_face() const
FixedVector< int, 2 > n_faces_mouilles_
void set_seuil_indicatrice_petite(double seuil_indicatrice_petite)
void calculer_indicatrice(IJK_Field_double &indic)
void update_old_intersections()
DoubleTab bounding_box_duplicate_criteria_
void RK3_G_store_vi_echange_esp_vect()
void detecter_et_supprimer_rejeton(bool duplicatas_etaient_presents)
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > repuls_par_compo_
void transporter_maillage_rigide(const double dt_tot, const DoubleTab &vitesses_translation_bulles, const DoubleTab &mean_bubble_rotation_vector, const DoubleTab &centre_gravite, const int rk_step, const int first_step_interface_smoothing=0)
int verbosite_surface_efficace_face_
void set_fichier_reprise_interface(const Nom &prefix)
IJK_Field_double indicatrice_avant_remaillage_ft_
ComputeValParCompoInCell val_par_compo_in_cell_computation_
int get_forcing_method() const
int compute_cell_phase_with_interface_normal(int num_elem, int direction, int face_plus)
bool compute_distance_autres_interfaces_
FixedVector< IJK_Field_vector3_double, 2 > bary_of_interf_
FixedVector< IJK_Field_double, 2 > surface_interface_ft_
void calculer_distance_autres_compo_connexe_ijk(const DoubleTab &sommets_a_tester, const ArrOfInt &compo_connexe_sommets, const DoubleTab &vinterp_tmp, const Maillage_FT_IJK &mesh, ArrOfDouble &distance, DoubleTab &v_closer, const double distmax)
Maillage_FT_IJK maillage_ft_ijk_
static void Fill_postprocessable_fields(std::vector< FieldInfo_t > &chps)
const IJK_Field_vector3_double & get_indicatrice_surfacique_face_next() const
FixedVector< FixedVector< IJK_Field_int, max_authorized_nb_of_components_ >, 2 > compos_traversantes_
void set_positions_reference()
const int & nb_groups() const
void RK3_G_store_vi_resize(int n, int n2)
FixedVector< IJK_Field_vector3_double, 2 > barycentre_phase1_ns_
void set_param(Param &titi) const override
IJK_Field_double indicatrice_avant_remaillage_ns_
void store_bubbles_barycentres(const Nom &interf_name)
double devient_pure(const int i, const int j, const int k) const
const IJK_Field_double & get_surface_interface_next_ft() const
void calculer_phi_repuls_par_compo(FixedVector< IJK_Field_double, max_authorized_nb_of_components_ > &surf_par_compo, FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 3 > &source_interf_par_compo, FixedVector< IJK_Field_double, max_authorized_nb_of_components_ > &phi_par_compo, FixedVector< IJK_Field_double, max_authorized_nb_of_components_ > &repuls_par_compo, const DoubleTab &gravite, const double delta_rho, const double sigma, const double time, const int itstep)
void initialise_ijk_compo_connex_bubbles_params()
static void get_maillage_MED_from_IJK_FT(MEDCouplingUMesh *maillage_bulles_mcu, const Maillage_FT_IJK &maillage_bulles_ft_ijk)
static int devient_pure(double old_indicatrice, double next_indicatrice)
Vecteur3 nIn(const int i, const int j, const int k) const
Intersection_Interface_ijk_cell & get_set_intersection_ijk_cell()
DoubleTabFT_cut_cell_scalar surface_efficace_interface_initial_
int verbosite_surface_efficace_interface_
IJK_Field_double field_repulsion_
const IJK_Field_double & In() const
const int & nb_compo_traversantes(const int i, const int j, const int k) const
const IJK_Composantes_Connex & get_ijk_compo_connex() const
void preparer_duplicata_bulles_masque_6bit(const DoubleTab &bounding_box, const DoubleTab &authorized_bounding_box, ArrOfInt &masque_duplicata_pour_compo)
static double mean_over_compo(const FixedVector< IJK_Field_double, max_authorized_nb_of_components_ > &field_for_compo, const IJK_Field_int &nb_compo_traversante, const int i, const int j, const int k)
int nombre_d_operateurs() const override
void calcul_surface_efficace_face_initial(TYPE_SURFACE_EFFICACE_FACE type_surface_efficace_face)
int a_desequilibre_initial_uniquement(double old_indicatrice, double next_indicatrice) const
void lire_maillage_ft_dans_lata()
void dumplata_ft_mesh(const char *filename, const char *meshname, int step) const
void compute_external_forces_(IJK_Field_vector3_double &rappel_ft, IJK_Field_vector3_double &rappel, const IJK_Field_vector3_double &vitesse, const IJK_Field_double &indic_ns, const IJK_Field_double &indic_ft, const double coef_immo, const int tstep, const double current_time, const double coef_ammortissement, const double coef_rayon_force_rappel, double compteur, double coef_mean_force, double coef_force_time_n)
void associer_switch(const Switch_FT_double &ijk_ft_switch)
const IJK_Field_double & get_surface_interface_old() const
void calculer_vecteurs_de_deplacement_rigide(DoubleTab &vitesses_translation_bulles, DoubleTab &mean_bubble_rotation_vector, DoubleTab &centre_gravite, const int first_step_interface_smoothing=0)
static void mean_over_compo(const FixedVector< IJK_Field_double, 3 *max_authorized_nb_of_components_ > &field_for_compo, const IJK_Field_int &nb_compo_traversante, IJK_Field_vector3_double &mean_par_compo_field)
void compute_rising_velocities_from_compo()
const double & I_ft(const int i, const int j, const int k) const
FixedVector< IJK_Field_vector3_double, 2 > surface_vapeur_par_face_ns_
FixedVector< IJK_Field_vector< double, max_authorized_nb_of_groups_ >, 2 > groups_indicatrice_ft_
void calcul_surface_efficace_interface_initial(TYPE_SURFACE_EFFICACE_INTERFACE type_surface_efficace_interface)
int next_below_small_threshold_for_phase(int phase, double old_indicatrice, double next_indicatrice) const
FixedVector< FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 3 >, 2 > source_interf_par_compo_
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > surf_par_compo_
bool use_tryggvason_interfacial_source_
DoubleTabFT_cut_cell_scalar indicatrice_surfacique_efficace_face_absolute_error_
void calcul_surface_efficace_face(TYPE_SURFACE_EFFICACE_FACE type_surface_efficace_face, double timestep, const Cut_field_vector3_double &total_velocity)
double SI(const int i, const int j, const int k) const
bool read_barycentres_velocity_
void switch_indicatrice_next_old()
int timestep_reprise_interface_
const IJK_Field_double & get_surface_interface_old_ft() const
double get_barycentre_face(bool next_time, int face_dir, int bary_compo, int phase, int i, int j, int k) const
bool has_champ(const Motcle &nom, OBS_PTR(Champ_base)&ref_champ) const override
DoubleTab bounding_box_delete_criteria_
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > courbure_par_compo_
const Maillage_FT_IJK & old_maillage_ft_ijk() const
const IJK_Field_vector3_double & get_indicatrice_surfacique_face_ft() const
void calculer_indicatrices_optim(IJK_Field_vector3_double &indic)
void calculer_indicatrice_surfacique_face(IJK_Field_vector3_double &indic_surfacique_face, IJK_Field_double &indic, IJK_Field_vector3_double &norme)
const Intersection_Interface_ijk_cell & get_intersection_ijk_cell() const
int preparer_calcul() override
Tout ce qui ne depend pas des autres problemes eventuels.
const IJK_Field_vector3_double & BoI() const
const IJK_Field_vector< double, max_authorized_nb_of_groups_ > & groups_indicatrice_n_ft() const
ArrOfDouble bubbles_velocities_bary_magnitude_
Connectivite_frontieres connectivite_frontieres_
const double & Sfn(const int compo, const int i, const int j, const int k) const
const FixedVector< IJK_Field_double, max_authorized_nb_of_components_ *3 > & get_norm_par_compo_itfc_in_cell_ft() const
void calculer_vmoy_rotation_composantes_connexes(const Maillage_FT_IJK &maillage, const ArrOfDouble &surface_facette, const ArrOfDouble &surface_par_bulle, const ArrOfInt &compo_connexes_facettes, const int nbulles_reelles, const int nbulles_ghost, const DoubleTab &centre_gravite, const DoubleTab &vitesse_sommets, const DoubleTab &vitesse_translation_sommets, DoubleTab &mean_bubble_rotation_vector) const
const ArrOfInt & get_colors() const
void calculer_distance_autres_compo_connexe2(ArrOfDouble &distance, DoubleTab &v_closer)
const Maillage_FT_IJK & maillage_ft_ijk() const
bool has_computed_bubble_barycentres_
void compute_compo_connex_from_interface()
double portee_wall_repulsion() const
Intersection_Interface_ijk_cell intersection_ijk_cell_
bool has_champ_vectoriel(const Motcle &nom) const override
const double & Sf(const int compo, const int i, const int j, const int k) const
void parcourir_maillage()
void calculer_indicatrice_intermediaire(IJK_Field_double &indicatrice_intermediaire_ft_, IJK_Field_double &indicatrice_intermediaire_ns_, IJK_Field_vector3_double &indicatrice_surfacique_intermediaire_face_ft_, IJK_Field_vector3_double &indicatrice_surfacique_intermediaire_face_ns_, const bool parcourir=true)
void calculer_aspect_ratio(ArrOfDouble &aspect_ratio) const
int get_dt_impression_bilan_indicatrice() const
const IJK_Field_vector3_double & get_barycentre_phase1_old_ft() const
const FixedVector< IJK_Field_double, max_authorized_nb_of_components_ *3 > & get_bary_par_compo_itfc_in_cell_ft() const
const FixedVector< IJK_Field_vector3_double, 3 > & get_barycentre_vapeur_par_face() const
bool correction_gradient_potentiel_
static int est_pure(double indicatrice)
double get_barycentre(bool next_time, int bary_compo, int phase, int i, int j, int k) const
double phase_naissante(const int phase, const int i, const int j, const int k) const
const double & xI(const int compo, const int i, const int j, const int k) const
const DoubleTabFT_cut_cell_scalar & get_surface_efficace_interface() const
void calcul_surface_efficace_interface(TYPE_SURFACE_EFFICACE_INTERFACE type_surface_efficace_interface, double timestep, const Cut_field_vector3_double &velocity)
void compute_external_forces_color_function(IJK_Field_vector3_double &rappel, const IJK_Field_double &indic_ns, const IJK_Field_double &indic_ft, DoubleTab &individual_forces, const ArrOfDouble &volume_reel, const DoubleTab &position)
DoubleTab force_time_n_
static int phase_mourrante(int phase, double old_indicatrice, double next_indicatrice)
const IJK_Field_vector3_double & get_barycentre_phase1_old() const
Intersection_Interface_ijk_face intersection_ijk_face_
double devient_diphasique(const int i, const int j, const int k) const
FixedVector< IJK_Field_vector3_double, 2 > surface_vapeur_par_face_
void update_surface_normale() const
IJK_Field_double indicatrice_apres_remaillage_ns_
const double & In_ft(const int i, const int j, const int k) const
void calculer_bounding_box_bulles(DoubleTab &bounding_box, int option_shear=0) const
void remailler_interface(const double temps, Maillage_FT_IJK &maillage, ArrOfDouble &var_volume, Remaillage_FT_IJK &algo_remaillage_local)
void calculer_indicatrice_avant_remaillage(const bool parcourir=true)
void calculer_poussee_bulles(const DoubleTab &gravite, DoubleTab &poussee) const
const IJK_Field_double & get_IJK_field(const Motcle &nom) override
double delta_p_max_repulsion_
FixedVector< FixedVector< IJK_Field_vector3_double, 3 >, 2 > barycentre_vapeur_par_face_
void recursive_calcul_distance_chez_voisin(DoubleTab &vinterp_tmp, int dir, const Maillage_FT_IJK &mesh, DoubleTab &coord_sommets, ArrOfInt &compo_sommet, ArrOfDouble &distance, DoubleTab &v_closer, double distmax)
OBS_PTR(Switch_FT_double) ref_ijk_ft_switch_
void supprimer_duplicata_bulles()
OBS_PTR(Domaine_IJK) ref_domaine_
DoubleTab bubbles_rising_vectors_bary_
static double mean_over_compo(const FixedVector< IJK_Field_double, 3 *max_authorized_nb_of_components_ > &field_for_compo, const IJK_Field_int &nb_compo_traversante, const int dir, const int i, const int j, const int k)
const IJK_Field_vector3_double & BoIn() const
void calculer_volume_bulles(ArrOfDouble &volumes, DoubleTab &centre_gravite) const
const IJK_Field_double & In_ft() const
FixedVector< IJK_Field_vector3_double, 2 > normal_of_interf_ns_
ArrOfInt through_yminus_
DoubleTab bounding_box_forbidden_criteria_
void compute_bubbles_volume_and_barycentres(ArrOfDouble &volumes, DoubleTab &barycentres, const int &store_values)
void compute_drapeaux_vapeur_v4(const IntVect &vecteur_composantes, ArrOfInt &drapeau_vapeur) const
IJK_Field_double delta_volume_theorique_bilan_ns_
IJK_Field_vector3_double indicatrice_surfacique_efficace_deformation_face_
int below_small_threshold(double indicatrice) const
IJK_Field_vector3_double indicatrice_surfacique_avant_remaillage_face_ns_
void compute_external_forces_parser(IJK_Field_vector3_double &rappel, const IJK_Field_double &indic_ns, const DoubleTab &individual_forces, const ArrOfDouble &volume_reel, const DoubleTab &position, const double coef_rayon_force_rappel)
Vecteur3 xIn(const int i, const int j, const int k) const
Operateur & operateur(int) override
const IJK_Field_vector3_double & get_barycentre_phase1_next() const
FixedVector< IJK_Field_double, 2 > indicatrice_ft_
IJK_Field_vector3_double indicatrice_surfacique_apres_remaillage_face_ns_
void associer_milieu_base(const Milieu_base &) override
void imprime_bilan_indicatrice()
void calculer_distance_autres_compo_connexe_octree(const DoubleTab &sommets_a_tester, const ArrOfInt &compo_connexe_sommets, const DoubleTab &vinterp_tmp, const Maillage_FT_IJK &mesh, ArrOfDouble &distance, DoubleTab &v_closer, const double distmax)
void read_bubbles_barycentres_old_new(const Nom &interf_name)
FixedVector< IJK_Field_vector< double, max_authorized_nb_of_groups_ >, 2 > groups_indicatrice_ns_
const IJK_Field_vector3_double & get_IJK_field_vector(const Motcle &nom) override
int est_desequilibre(double indicatrice) const
double delta_p_wall_max_repulsion_
Maillage_FT_IJK old_maillage_ft_ijk_
int update_indicatrice(IJK_Field_double &indic)
DoubleTabFT_cut_cell_vector3 coord_deplacement_interface_
void set_recompute_indicator(int i)
FixedVector< FixedVector< IJK_Field_vector3_double, 3 >, 2 > barycentre_vapeur_par_face_ns_
void sauvegarder_interfaces(const char *lata_name, const Nom &interf_name="??")
void allocate_ijk_compo_connex_fields(const Domaine_IJK &splitting, const int &allocate_compo_fields)
void calculer_indicatrice_next(const DoubleTab &gravite, const double delta_rho, const double sigma, const double time, const int itstep, const bool parcourir=true)
static int convert_indicatrice_to_phase(double indicatrice)
const DoubleTabFT_cut_cell_vector3 & get_normale_deplacement_interface() const
void calculer_normales_et_aires_interfaciales(IJK_Field_double &ai, IJK_Field_double &kappa_ai, IJK_Field_vector3_double &normale_cell, const int igroup) const
void calculer_surface_bulles(ArrOfDouble &surfaces) const
IJK_Field_vector3_double indicatrice_surfacique_apres_remaillage_face_ft_
FixedVector< FixedVector< IJK_Field_double, max_authorized_nb_of_components_ >, 2 > gradz_sigma_par_compo_
DoubleTabFT_cut_cell_vector3 normale_deplacement_interface_
DoubleTab bounding_box_NS_domain_
double In(const int i, const int j, const int k) const
const DoubleTab & RK3_G_store_vi() const
double seuil_indicatrice_petite_
DoubleTabFT_cut_cell_vector6 indicatrice_surfacique_efficace_face_correction_
: class Maillage_FT_IJK
classe Milieu_base Cette classe est la base de la hierarchie des milieux (physiques)
Definition Milieu_base.h:50
Une chaine de caractere (Nom) en majuscules.
Definition Motcle.h:26
Un tableau d'objets de la classe Motcle.
Definition Motcle.h:63
class Nom Une chaine de caractere pour nommer les objets de TRUST
Definition Nom.h:31
Un tableau de chaine de caracteres (VECT(Nom)).
Definition Noms.h:26
classe Operateur Classe generique de la hierarchie des operateurs.
Definition Operateur.h:39
static bool DISABLE_DIPHASIQUE
Definition Option_IJK.h:26
Helper class to factorize the readOn method of Objet_U classes.
Definition Param.h:112
classe Probleme_base C'est un Probleme_U qui n'est pas un couplage.
static void exit(int exit_code=-1)
Routine de sortie de TRUST dans une region Kokkos.
Definition Process.cpp:455
Classe de base des flux de sortie.
Definition Sortie.h:52