TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
VEF_discretisation.cpp
1/****************************************************************************
2* Copyright (c) 2026, 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#include <Taux_cisaillement_P0_VEF.h>
17#include <Champ_Fonc_Tabule_P0_VEF.h>
18#include <Correlation_Vec_Sca_VEF.h>
19#include <Rotationnel_Champ_P1NC.h>
20#include <Rotationnel_Champ_Q1NC.h>
21#include <Critere_Q_Champ_P1NC.h>
22#include <T_paroi_Champ_P1NC.h>
23#include <VEF_discretisation.h>
24#include <Y_plus_Champ_P1NC.h>
25#include <Navier_Stokes_std.h>
26#include <grad_T_Champ_P1NC.h>
27#include <grad_U_Champ_P1NC.h>
28#include <h_conv_Champ_P1NC.h>
29#include <Champ_Ostwald_VEF.h>
30#include <Champ_Fonc_Tabule.h>
31#include <Schema_Temps_base.h>
32#include <Champ_Fonc_Q1NC.h>
33#include <Fluide_Ostwald.h>
34#include <Champ_Uniforme.h>
35#include <Domaine_VEF.h>
36#include <Quadri_VEF.h>
37#include <Tetra_VEF.h>
38#include <Hexa_VEF.h>
39#include <Tri_VEF.h>
40
41Implemente_instanciable(VEF_discretisation, "VEFPreP1B|VEF", Discret_Thyd);
42// XD vef discretisation_base vefprep1b INHERITS_BRACE Finite element volume discretization (P1NC/P1-bubble element).
43// XD_CONT Since the 1.5.5 version, several new discretizations are available thanks to the optional keyword Read. By
44// XD_CONT default, the VEFPreP1B keyword is equivalent to the former VEFPreP1B formulation (v1.5.4 and sooner). P0P1
45// XD_CONT (if used with the strong formulation for imposed pressure boundary) is equivalent to VEFPreP1B but the
46// XD_CONT convergence is slower. VEFPreP1B dis is equivalent to VEFPreP1B dis Read dis { P0 P1
47// XD_CONT Changement_de_base_P1Bulle 1 Cl_pression_sommet_faible 0 }
48
49// By default, P0+P1 and changing basis to do P0+P1->P1Bulle
50// REMEMBER: we don't necessarily go through the readOn() piece of code if we just write
51// VEF dis
52// instead of
53// VEF dis
54// Read dis { ... }
55// !!!!
57{
58 alphaE_ = false;
59 alphaS_ = false;
60 P1Bulle_ = 0;
61 cl_pression_sommet_faible_ = 1;
62 return Discret_Thyd::readOn(is);
63}
64
66{
68
69 param.ajouter("changement_de_base_P1bulle", &P1Bulle_); // XD_ADD_P entier(into=[0,1])
70 // XD_CONT changement_de_base_p1bulle 1 This option may be used to have the P1NC/P0P1 formulation (value set to 0) or
71 // XD_CONT the P1NC/P1Bulle formulation (value set to 1, the default).
72 param.ajouter_flag("P0", &alphaE_); // XD_ADD_P rien
73 // XD_CONT Pressure nodes are added on element centres
74 param.ajouter_flag("P1", &alphaS_); // XD_ADD_P rien
75 // XD_CONT Pressure nodes are added on vertices
76 param.ajouter_flag("Pa", &alphaA_); // XD_ADD_P rien
77 // XD_CONT Only available in 3D, pressure nodes are added on bones
78 param.ajouter_flag("RT", &alphaRT_); // XD_ADD_P rien
79 // XD_CONT For P1NCP1B (in TrioCFD)
80 param.ajouter("modif_div_face_dirichlet", &modif_div_face_dirichlet_); // XD_ADD_P entier(into=[0,1])
81 // XD_CONT This option (by default 0) is used to extend control volumes for the momentum equation.
82 param.ajouter("CL_pression_sommet_faible", &cl_pression_sommet_faible_); // XD_ADD_P entier(into=[0,1])
83 // XD_CONT This option is used to specify a strong formulation (value set to 0, the default) or a weak formulation
84 // XD_CONT (value set to 1) for an imposed pressure boundary condition. The first formulation converges quicker and is
85 // XD_CONT stable in general cases. The second formulation should be used if there are several outlet boundaries with
86 // XD_CONT Neumann condition (see Ecoulement_Neumann test case for example).
87}
88
90{
91 // A few checks
92 if (dimension != 3 && alphaA_)
93 Process::exit("Pa support is only available in 3D.");
94 if (!alphaE_ && !alphaS_ && !alphaA_)
95 {
96 // P0P1Bulle by default with strong pressure BC
97 alphaE_ = true;
98 alphaS_ = true;
99 P1Bulle_ = true;
100 cl_pression_sommet_faible_ = 0;
101 //Process::exit("You must choose at least one support among P0, P1, Pa.");
102 }
103 if (alphaA_ && !alphaE_)
104 Process::exit("Discretisations Pa or P1+Pa are not yet supported.");
105 if (P1Bulle_)
106 if (!((alphaE_) && (alphaS_) && (!alphaA_)))
107 Process::exit("Option 'changement_de_base_P1bulle' is available only in P0/P1");
108
109 if (alphaRT_)
110 {
111 if (!alphaE_ && !alphaS_ && !alphaA_)
112 Process::exit("Choose P0 discretization.");
113 Cerr << "Linke's scheme, OK for steady-state pb. The pressure computed is the Bernoulli pressure P =p+|u|^2" << finl;
114 }
115}
116
118{
119 s << "lire " << le_nom() << " { " << finl;
120 if (alphaE_) s << " P0";
121 if (alphaS_) s << " P1";
122 if (alphaA_) s << " Pa";
123 if (alphaRT_) s << " RT";
124 s << " changement_de_base_P1bulle " << P1Bulle_;
125 s << " modif_div_face_dirichlet " << modif_div_face_dirichlet_;
126 s << " cl_pression_sommet_faible " << cl_pression_sommet_faible_;
127 s << " } " << finl;
128 return s;
129}
130
131/*! @brief Discretizes a field for VEFP1B according to a discretization directive.
132 *
133 * @brief The directive is a Motcle such as "pression",
134 * "divergence_vitesse" (creates a field of type P1_isoP1Bulle).
135 * This method determines the field type to create based on element type
136 * and the discretization directive. It then determines the number of degrees of freedom
137 * and sets all field parameters (type, nb_compo, nb_ddl, nb_pas_dt,
138 * name(s), unit(s), field nature, and assigns a time) and associates the Domaine_dis to the field.
139 * See the code for the correspondence between directives and
140 * the field type created.
141 *
142 */
143void VEF_discretisation::discretiser_champ(const Motcle& directive, const Domaine_dis_base& z, Nature_du_champ nature, const Noms& noms, const Noms& unites, int nb_comp, int nb_pas_dt, double temps,
144 OWN_PTR(Champ_Inc_base)& champ, const Nom& sous_type) const
145{
146 Motcles motcles(2);
147 motcles[0] = "pression"; // Standard choice for pressure
148 motcles[1] = "divergence_vitesse"; // Field type obtained by computing div v
149
150 Nom type;
151 int default_nb_comp = 0; // Default number of components
152 int rang = motcles.search(directive);
153 switch(rang)
154 {
155 case 0:
156 type = "Champ_P1_isoP1Bulle";
157 default_nb_comp = 1;
158 break;
159 case 1:
160 type = "Champ_P1_isoP1Bulle";
161 default_nb_comp = 1;
162 break;
163 default:
164 assert(rang < 0);
165 break;
166 }
167
168 if (directive == DEMANDE_DESCRIPTION)
169 Cerr << "VEF_discretisation : " << motcles;
170
171 // If the directive is not recognized (or if it is a description request)
172 // then call the ancestor:
173 if (rang < 0)
174 {
175 VEF_discretisation::discretiser_champ_(directive, z, nature, noms, unites, nb_comp, nb_pas_dt, temps, champ);
176 return;
177 }
178
179 const int nb_ddl = -1; // the p1b descriptor will provide the actual number
180 if (nb_comp < 0)
181 nb_comp = default_nb_comp;
182 assert(nb_comp > 0);
183 creer_champ(champ, z, type, noms[0], unites[0], nb_comp, nb_ddl, nb_pas_dt, temps, directive, que_suis_je());
184
185 if (nature == multi_scalaire)
186 {
187 Cerr << "There is no field of type OWN_PTR(Champ_Inc_base) with P1Bulle discretization" << finl;
188 Cerr << "and a multi_scalaire nature." << finl;
189 exit();
190 }
191}
192
193void VEF_discretisation::discretiser_champ_(const Motcle& directive, const Domaine_dis_base& z, Nature_du_champ nature, const Noms& noms, const Noms& unites, int nb_comp, int nb_pas_dt, double temps,
194 OWN_PTR(Champ_Inc_base)& champ, const Nom& sous_type) const
195{
196 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
197
198 Motcles motcles(7);
199 motcles[0] = "vitesse"; // Standard choice for velocity
200 motcles[1] = "pression"; // Standard choice for pressure
201 motcles[2] = "temperature"; // Standard choice for temperature
202 motcles[3] = "divergence_vitesse"; // Field type obtained by computing div v
203 motcles[4] = "gradient_pression"; // Field type obtained by computing grad P
204 motcles[5] = "champ_elem"; // Create a field at elements (type P0)
205 motcles[6] = "champ_sommets"; // Create a field at vertices (type P1)
206
207 // The velocity field type depends on element type:
208 Nom type_champ_vitesse;
209 if (sub_type(Tri_VEF, domaine_vef.type_elem()) || sub_type(Tetra_VEF, domaine_vef.type_elem()))
210 type_champ_vitesse = "Champ_P1NC";
211 else if (sub_type(Quadri_VEF,domaine_vef.type_elem()) || sub_type(Hexa_VEF, domaine_vef.type_elem()))
212 type_champ_vitesse = "Champ_Q1NC";
213 else
214 {
215 Cerr << "VEF_discretisation::discretiser_champ :\n The geometric element ";
216 Cerr << domaine_vef.type_elem().que_suis_je();
217 Cerr << " is not supported." << finl;
218 exit();
219 }
220
221 Nom type;
222 int default_nb_comp = 0; // Default number of components
223 int rang = motcles.search(directive);
224 switch(rang)
225 {
226 case 0:
227 type = type_champ_vitesse;
228 default_nb_comp = dimension;
229 break;
230 case 1:
231 type = "Champ_P0_VEF";
232 default_nb_comp = 1;
233 break;
234 case 2:
235 type = type_champ_vitesse;
236 default_nb_comp = 1;
237 break;
238 case 3:
239 type = "Champ_P0_VEF";
240 default_nb_comp = 1;
241 break;
242 case 4:
243 type = type_champ_vitesse;
244 default_nb_comp = dimension;
245 break;
246 case 5:
247 type = "Champ_P0_VEF";
248 default_nb_comp = 1;
249 break;
250 case 6:
251 type = "Champ_P1_VEF";
252 default_nb_comp = 1;
253 break;
254 default:
255 assert(rang < 0);
256 break;
257 }
258
259 if (directive == DEMANDE_DESCRIPTION)
260 Cerr << "VEF_discretisation : " << motcles;
261
262 // If the directive is not recognized (or if it is a description request)
263 // then call the ancestor:
264 if (rang < 0)
265 {
266 Discret_Thyd::discretiser_champ(directive, z, nature, noms, unites, nb_comp, nb_pas_dt, temps, champ);
267 return;
268 }
269
270 // Compute the number of degrees of freedom
271 int nb_ddl = 0;
272 if (type == "Champ_P0_VEF")
273 nb_ddl = z.nb_elem();
274 else if (type == type_champ_vitesse)
275 nb_ddl = domaine_vef.nb_faces();
276 else if (type == "Champ_P1_VEF")
277 nb_ddl = domaine_vef.nb_som();
278 else
279 assert(0);
280
281 if (nb_comp < 0)
282 nb_comp = default_nb_comp;
283 assert(nb_comp > 0);
284 creer_champ(champ, z, type, noms[0], unites[0], nb_comp, nb_ddl, nb_pas_dt, temps, directive, que_suis_je());
285 if (nature == multi_scalaire)
286 {
287 champ->fixer_nature_du_champ(nature);
288 champ->fixer_unites(unites);
289 champ->fixer_noms_compo(noms);
290 }
291
292}
293
294/*! @brief Same as VEF_discretisation::discretiser_champ(..., Champ_Inc).
295 *
296 */
297void VEF_discretisation::discretiser_champ(const Motcle& directive, const Domaine_dis_base& z, Nature_du_champ nature, const Noms& noms, const Noms& unites, int nb_comp, double temps,
298 OWN_PTR(Champ_Fonc_base)& champ) const
299{
300 discretiser_champ_fonc_don(directive, z, nature, noms, unites, nb_comp, temps, champ);
301}
302
303/*! @brief Same as VEF_discretisation::discretiser_champ(..., Champ_Inc).
304 *
305 */
306void VEF_discretisation::discretiser_champ(const Motcle& directive, const Domaine_dis_base& z, Nature_du_champ nature, const Noms& noms, const Noms& unites, int nb_comp, double temps,
307 OWN_PTR(Champ_Don_base)& champ) const
308{
309 discretiser_champ_fonc_don(directive, z, nature, noms, unites, nb_comp, temps, champ);
310}
311
312/*! @brief Same as VEF_discretisation::discretiser_champ(..., Champ_Inc). Common processing for champ_fonc and champ_don.
313 * This method is private (passing an Objet_U is not clean from the outside).
314 *
315 */
316void VEF_discretisation::discretiser_champ_fonc_don(const Motcle& directive, const Domaine_dis_base& z, Nature_du_champ nature, const Noms& noms, const Noms& unites, int nb_comp, double temps,
317 Objet_U& champ) const
318{
319 // Two pointers for easy access to champ_don or champ_fonc depending on the type of the champ object.
320 OWN_PTR(Champ_Fonc_base) * champ_fonc = dynamic_cast<OWN_PTR(Champ_Fonc_base)*>(&champ);
321 OWN_PTR(Champ_Don_base) * champ_don = dynamic_cast<OWN_PTR(Champ_Don_base)*>(&champ);
322
323 Motcles motcles(2);
324 motcles[0] = "pression"; // Standard choice for pressure
325 motcles[1] = "divergence_vitesse"; // Field type obtained by computing div v
326
327 Nom type;
328 int default_nb_comp = 0; // Default number of components
329 int rang = motcles.search(directive);
330 switch(rang)
331 {
332 case 0:
333 type = "Champ_Fonc_P1_isoP1Bulle";
334 default_nb_comp = 1;
335 break;
336 case 1:
337 type = "Champ_Fonc_P1_isoP1Bulle";
338 default_nb_comp = 1;
339 break;
340 default:
341 assert(rang < 0);
342 break;
343 }
344
345 if (directive == DEMANDE_DESCRIPTION)
346 Cerr << "VEF_discretisation : " << motcles;
347
348 // If the directive is not recognized (or if it is a description request)
349 // then call the ancestor:
350 if (rang < 0)
351 {
352 if (champ_fonc)
353 VEF_discretisation::discretiser_champ_fonc_don_(directive, z, nature, noms, unites, nb_comp, temps, *champ_fonc);
354 else
355 VEF_discretisation::discretiser_champ_fonc_don_(directive, z, nature, noms, unites, nb_comp, temps, *champ_don);
356 return;
357 }
358
359 int nb_ddl = -1; // the p1b descriptor will provide the actual number
360
361 if (nb_comp < 0)
362 nb_comp = default_nb_comp;
363 assert(nb_comp > 0);
364 if (champ_fonc)
365 creer_champ(*champ_fonc, z, type, noms[0], unites[0], nb_comp, nb_ddl, temps, directive, que_suis_je());
366 else
367 creer_champ(*champ_don, z, type, noms[0], unites[0], nb_comp, nb_ddl, temps, directive, que_suis_je());
368
369 if (nature == multi_scalaire)
370 {
371 Cerr << "There is no field of type OWN_PTR(Champ_Fonc_base) or OWN_PTR(Champ_Don_base) with P1Bulle discretization" << finl;
372 Cerr << "and a multi_scalaire nature." <<finl;
373 exit();
374 }
375}
376
377void VEF_discretisation::discretiser_champ_fonc_don_(const Motcle& directive, const Domaine_dis_base& z, Nature_du_champ nature, const Noms& noms, const Noms& unites, int nb_comp, double temps,
378 Objet_U& champ) const
379{
380 // Two pointers for easy access to champ_don or champ_fonc depending on the type of the champ object.
381 OWN_PTR(Champ_Fonc_base) * champ_fonc = dynamic_cast<OWN_PTR(Champ_Fonc_base)*>(&champ);
382 OWN_PTR(Champ_Don_base) * champ_don = dynamic_cast<OWN_PTR(Champ_Don_base)*>(&champ);
383
384 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
385
386 Motcles motcles(8);
387 motcles[0] = "pression"; // Standard choice for pressure
388 motcles[1] = "temperature"; // Standard choice for temperature
389 motcles[2] = "divergence_vitesse"; // Field type obtained by computing div v
390 motcles[3] = "champ_elem"; // Create a field at elements (type P0)
391 motcles[4] = "vitesse"; // Standard choice for velocity
392 motcles[5] = "gradient_pression"; // Field type obtained by computing grad P
393 motcles[6] = "champ_sommets"; // Create a field at vertices
394 motcles[7] = "champ_face"; // Create a field at faces
395
396 // The velocity field type depends on the element type:
397 Nom type_champ_vitesse, type_champ_sommets;
398 Nom type_elem_domaine = domaine_vef.domaine().type_elem()->que_suis_je();
399 if (Motcle(type_elem_domaine) != "Segment")
400 {
401 const Elem_VEF_base& elem_vef = domaine_vef.type_elem();
402 if (sub_type(Tri_VEF, elem_vef) || sub_type(Tetra_VEF, elem_vef))
403 {
404 type_champ_vitesse = "Champ_Fonc_P1NC";
405 type_champ_sommets = "Champ_Fonc_P1_VEF";
406 }
407 else if (sub_type(Quadri_VEF, elem_vef) || sub_type(Hexa_VEF, elem_vef))
408 {
409 type_champ_vitesse = "Champ_Fonc_Q1NC";
410 type_champ_sommets = "Champ_Fonc_Q1_VEF";
411 }
412 else
413 {
414 Cerr << "VEF_discretisation::discretiser_champ :\n The geometric element ";
415 Cerr << elem_vef.que_suis_je();
416 Cerr << " is not supported." << finl;
417 exit();
418 }
419 }
420
421 Nom type;
422 int default_nb_comp = 0; // Default number of components
423 int rang = motcles.search(directive);
424 switch(rang)
425 {
426 case 0:
427 type = "Champ_Fonc_P0_VEF";
428 default_nb_comp = 1;
429 break;
430 case 1:
431 type = type_champ_vitesse;
432 default_nb_comp = 1;
433 break;
434 case 2:
435 type = "Champ_Fonc_P0_VEF";
436 default_nb_comp = 1;
437 break;
438 case 3:
439 type = "Champ_Fonc_P0_VEF";
440 default_nb_comp = 1;
441 break;
442 case 4:
443 type = type_champ_vitesse;
444 default_nb_comp = dimension;
445 break;
446 case 5:
447 type = type_champ_vitesse;
448 default_nb_comp = dimension;
449 break;
450 case 6:
451 type = type_champ_sommets;
452 default_nb_comp = 1;
453 break;
454 case 7:
455 type = type_champ_vitesse;
456 default_nb_comp = 1;
457 break;
458
459 default:
460 assert(rang < 0);
461 break;
462 }
463
464 if (directive == DEMANDE_DESCRIPTION)
465 Cerr << "VEF_discretisation : " << motcles;
466
467 // If the directive is not recognized (or if it is a description request)
468 // then call the ancestor:
469 if (rang < 0)
470 {
471 if (champ_fonc)
472 Discret_Thyd::discretiser_champ(directive, z, nature, noms, unites, nb_comp, temps, *champ_fonc);
473 else
474 Discret_Thyd::discretiser_champ(directive, z, nature, noms, unites, nb_comp, temps, *champ_don);
475 return;
476 }
477
478 // Compute the number of degrees of freedom
479 int nb_ddl = 0;
480 if (type == "Champ_Fonc_P0_VEF")
481 nb_ddl = z.nb_elem();
482 else if (type == type_champ_vitesse)
483 nb_ddl = domaine_vef.nb_faces();
484 else if ((type == "Champ_Fonc_P1_VEF") || (type == "Champ_Fonc_Q1_VEF"))
485 nb_ddl = domaine_vef.nb_som();
486 else
487 assert(0);
488
489 if (nb_comp < 0)
490 nb_comp = default_nb_comp;
491 assert(nb_comp > 0);
492 if (champ_fonc)
493 creer_champ(*champ_fonc, z, type, noms[0], unites[0], nb_comp, nb_ddl, temps, directive, que_suis_je());
494 else
495 creer_champ(*champ_don, z, type, noms[0], unites[0], nb_comp, nb_ddl, temps, directive, que_suis_je());
496
497 if ((nature == multi_scalaire) && (champ_fonc))
498 {
499 champ_fonc->valeur().fixer_nature_du_champ(nature);
500 champ_fonc->valeur().fixer_unites(unites);
501 champ_fonc->valeur().fixer_noms_compo(noms);
502 }
503 else if ((nature == multi_scalaire) && (champ_don))
504 {
505 Cerr << "There is no field of type OWN_PTR(Champ_Don_base) with a multi_scalaire nature." << finl;
506 exit();
507 }
508}
509
511{
512 Cerr << "Discretization of the wall distance" << finl;
513 Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
514 ch.typer("Champ_Fonc_P0_VEF");
515 Champ_Fonc_P0_VEF& ch_dist_paroi = ref_cast(Champ_Fonc_P0_VEF, ch.valeur());
516 ch_dist_paroi.associer_domaine_dis_base(domaine_vef);
517 ch_dist_paroi.nommer("distance_paroi");
518 ch_dist_paroi.fixer_nb_comp(1);
519 ch_dist_paroi.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
520 ch_dist_paroi.fixer_unite("m");
521 ch_dist_paroi.changer_temps(sch.temps_courant());
522}
523
525{
526 Cerr << "Discretization of global wall distance" << finl;
527 Noms noms(1), unites(1);
528 noms[0] = Nom("distance_paroi_globale");
529 unites[0] = Nom("m");
530 discretiser_champ(Motcle("champ_elem"), z, scalaire, noms , unites, 1, 0, ch);
531}
532
534{
535 Cerr << "Discretization of vorticity " << finl;
536 const Domaine_VEF& domaine_VEF = ref_cast(Domaine_VEF, z);
537
538 if (sub_type(Tri_VEF,domaine_VEF.type_elem()) || sub_type(Tetra_VEF, domaine_VEF.type_elem()))
539 {
540 ch.typer("Rotationnel_Champ_P1NC");
541 const Champ_P1NC& vit = ref_cast(Champ_P1NC, ch_vitesse);
542 Rotationnel_Champ_P1NC& ch_W = ref_cast(Rotationnel_Champ_P1NC, ch.valeur());
543 ch_W.associer_domaine_dis_base(domaine_VEF);
544 ch_W.associer_champ(vit);
545 ch_W.nommer("vorticite");
546 if (dimension == 2)
547 ch_W.fixer_nb_comp(1);
548 else
549 {
551 ch_W.fixer_nom_compo(0, "vorticitex");
552 ch_W.fixer_nom_compo(1, "vorticitey");
553 ch_W.fixer_nom_compo(2, "vorticitez");
554 }
555 ch_W.fixer_nb_valeurs_nodales(domaine_VEF.nb_elem());
556 ch_W.fixer_unite("s-1");
557 ch_W.changer_temps(ch_vitesse.temps());
558 }
559 else if (sub_type(Quadri_VEF,domaine_VEF.type_elem()) || sub_type(Hexa_VEF, domaine_VEF.type_elem()))
560 {
561 ch.typer("Rotationnel_Champ_Q1NC");
562 const Champ_Q1NC& vit = ref_cast(Champ_Q1NC, ch_vitesse);
563 Rotationnel_Champ_Q1NC& ch_W = ref_cast(Rotationnel_Champ_Q1NC, ch.valeur());
564 ch_W.associer_domaine_dis_base(domaine_VEF);
565 ch_W.associer_champ(vit);
566 ch_W.nommer("vorticite");
567 if (dimension == 2)
568 ch_W.fixer_nb_comp(1);
569 else
570 {
572 ch_W.fixer_nom_compo(0, "vorticitex");
573 ch_W.fixer_nom_compo(1, "vorticitey");
574 ch_W.fixer_nom_compo(2, "vorticitez");
575 }
576 ch_W.fixer_nb_valeurs_nodales(domaine_VEF.nb_elem());
577 ch_W.fixer_unite("s-1");
578 ch_W.changer_temps(ch_vitesse.temps());
579 }
580 else
581 {
582 Cerr << "Problem in element typing in VEF_discretisation::vorticite" << finl;
583 exit();
584 }
585}
586
588{
589 if (sub_type(Champ_P1NC, ch_vitesse))
590 {
591 ch.typer("Rotationnel_Champ_P1NC");
592 const Champ_P1NC& vit = ref_cast(Champ_P1NC, ch_vitesse);
593 const Domaine_VEF& domaine_VEF = ref_cast(Domaine_VEF, vit.domaine_dis_base());
594 Rotationnel_Champ_P1NC& ch_W = ref_cast(Rotationnel_Champ_P1NC, ch.valeur());
595 ch_W.associer_domaine_dis_base(domaine_VEF);
596 ch_W.associer_champ(vit);
597 ch_W.nommer("vorticite");
598 if (dimension == 2)
599 ch_W.fixer_nb_comp(1);
600 else
601 {
603 ch_W.fixer_nom_compo(0, "vorticitex");
604 ch_W.fixer_nom_compo(1, "vorticitey");
605 ch_W.fixer_nom_compo(2, "vorticitez");
606 }
607 ch_W.fixer_nb_valeurs_nodales(domaine_VEF.nb_elem());
608 ch_W.fixer_unite("s-1");
609 ch_W.changer_temps(sch.temps_courant());
610 }
611 else if (sub_type(Champ_Q1NC, ch_vitesse))
612 {
613 ch.typer("Rotationnel_Champ_Q1NC");
614 const Champ_Q1NC& vit = ref_cast(Champ_Q1NC, ch_vitesse);
615 const Domaine_VEF& domaine_VEF = ref_cast(Domaine_VEF, vit.domaine_dis_base());
616 Rotationnel_Champ_Q1NC& ch_W = ref_cast(Rotationnel_Champ_Q1NC, ch.valeur());
617 ch_W.associer_domaine_dis_base(domaine_VEF);
618 ch_W.associer_champ(vit);
619 ch_W.nommer("vorticite");
620 if (dimension == 2)
621 ch_W.fixer_nb_comp(1);
622 else
623 {
625 ch_W.fixer_nom_compo(0, "vorticitex");
626 ch_W.fixer_nom_compo(1, "vorticitey");
627 ch_W.fixer_nom_compo(2, "vorticitez");
628 }
629 ch_W.fixer_nb_valeurs_nodales(domaine_VEF.nb_elem());
630 ch_W.fixer_unite("s-1");
631 ch_W.changer_temps(sch.temps_courant());
632 }
633 else
634 {
635 Cerr << "Problem in element typing in VEF_discretisation::creer_champ_vorticite" << finl;
636 exit();
637 }
638}
639
640/*! @brief Discretizes the incompressible fluid in VEF, specifically K and N.
641 *
642 * @param (Domaine_dis_base&) domain to discretize
643 * @param (Fluide_Ostwald&) fluid to discretize
644 * @param (Champ_Inc_base&) velocity
645 * @param (Champ_Inc_base&) temperature
646 */
648{
649 Cerr << "VEF discretization of the Ostwald fluid" << finl;
650 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
651 const Champ_Inc_base& ch_vitesse = eqn_hydr.inconnue();
652 const Champ_P1NC& vit = ref_cast(Champ_P1NC, ch_vitesse);
653
654 Champ_Don_base& mu = le_fluide.viscosite_dynamique();
655 // mu is always a champ_Ostwald_VEF, the following must always be done
656 Champ_Ostwald_VEF& ch_mu = ref_cast(Champ_Ostwald_VEF, mu);
657 Cerr << "associate domainedisbase VEF" << finl;
658 ch_mu.associer_domaine_dis_base(domaine_vef);
659 ch_mu.associer_fluide(le_fluide);
660 ch_mu.associer_champ(vit);
661 ch_mu.associer_eqn(eqn_hydr);
662 Cerr << "associations completed: domain dis base, fluid, field VEF" << finl;
663 ch_mu.fixer_nb_comp(1);
664
665 Cerr << "done fixer_nb_valeurs_nodales" << finl;
666 Cerr << "nb_valeurs_nodales VEF = " << domaine_vef.nb_elem() << finl;
667 ch_mu.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
668
669 Cerr << "done changer_temps" << finl;
670 ch_mu.changer_temps(vit.temps());
671 Cerr << "mu VEF is discretized " << finl;
672}
673
674void VEF_discretisation::critere_Q(const Domaine_dis_base& z, const Domaine_Cl_dis_base& zcl, const Champ_Inc_base& ch_vitesse, OWN_PTR(Champ_Fonc_base)& ch) const
675{
676 // We pass zcl so there is only one method regardless of the discretization,
677 // but it is not used here!!!
678 Cerr << "Discretization of Q criterion " << finl;
679 const Champ_P1NC& vit = ref_cast(Champ_P1NC, ch_vitesse);
680 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
681 ch.typer("Critere_Q_Champ_P1NC");
682 Critere_Q_Champ_P1NC& ch_cQ = ref_cast(Critere_Q_Champ_P1NC, ch.valeur());
683 ch_cQ.associer_domaine_dis_base(domaine_vef);
684 ch_cQ.associer_champ(vit);
685 ch_cQ.nommer("Critere_Q");
686 ch_cQ.fixer_nb_comp(1);
687 ch_cQ.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
688 ch_cQ.fixer_unite("s-2");
689 ch_cQ.changer_temps(ch_vitesse.temps());
690}
691
692void VEF_discretisation::y_plus(const Domaine_dis_base& z, const Domaine_Cl_dis_base& zcl, const Champ_Inc_base& ch_vitesse, OWN_PTR(Champ_Fonc_base)& ch) const
693{
694 Cerr << "Discretization of y_plus" << finl;
695 const Champ_P1NC& vit = ref_cast(Champ_P1NC, ch_vitesse);
696 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
697 const Domaine_Cl_VEF& domaine_cl_vef = ref_cast(Domaine_Cl_VEF, zcl);
698 ch.typer("Y_plus_Champ_P1NC");
699 Y_plus_Champ_P1NC& ch_yp = ref_cast(Y_plus_Champ_P1NC, ch.valeur());
700 ch_yp.associer_domaine_dis_base(domaine_vef);
701 ch_yp.associer_domaine_Cl_dis_base(domaine_cl_vef);
702 ch_yp.associer_champ(vit);
703 ch_yp.nommer("Y_plus");
704 ch_yp.fixer_nb_comp(1);
705 ch_yp.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
706 ch_yp.fixer_unite("adimensionnel");
707 ch_yp.changer_temps(ch_vitesse.temps());
708}
709
710void VEF_discretisation::t_paroi(const Domaine_dis_base& z,const Domaine_Cl_dis_base& zcl, const Champ_Inc_base& ch_temp, OWN_PTR(Champ_Fonc_base)& ch) const
711{
712 Cerr << "Discretization of temperature_paroi" << finl;
713 const Champ_P1NC& temp = ref_cast(Champ_P1NC, ch_temp);
714 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
715 const Domaine_Cl_VEF& domaine_cl_vef = ref_cast(Domaine_Cl_VEF, zcl);
716 ch.typer("T_paroi_Champ_P1NC");
717 T_paroi_Champ_P1NC& ch_tp = ref_cast(T_paroi_Champ_P1NC, ch.valeur());
718 ch_tp.associer_domaine_dis_base(domaine_vef);
719 ch_tp.associer_domaine_Cl_dis_base(domaine_cl_vef);
720 ch_tp.associer_champ(temp);
721 ch_tp.nommer("temperature_paroi");
722 ch_tp.add_synonymous("wall_temperature");
723 ch_tp.fixer_nb_comp(1);
724 ch_tp.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
725 ch_tp.fixer_unite("K-C");
726 ch_tp.changer_temps(ch_temp.temps());
727}
728
729void VEF_discretisation::grad_u(const Domaine_dis_base& z, const Domaine_Cl_dis_base& zcl, const Champ_Inc_base& ch_vitesse, OWN_PTR(Champ_Fonc_base)& ch) const
730{
731
732 const Champ_P1NC& vit = ref_cast(Champ_P1NC, ch_vitesse);
733 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
734 const int nb_comp = dimension * dimension;
735 const Domaine_Cl_VEF& domaine_cl_vef = ref_cast(Domaine_Cl_VEF, zcl);
736 ch.typer("grad_u_Champ_P1NC");
737 grad_U_Champ_P1NC& ch_grad_u = ref_cast(grad_U_Champ_P1NC, ch.valeur());
738 ch_grad_u.fixer_nature_du_champ(vectoriel);
739 ch_grad_u.associer_domaine_dis_base(domaine_vef);
740 ch_grad_u.associer_domaine_Cl_dis_base(domaine_cl_vef);
741 ch_grad_u.associer_champ(vit);
742 ch_grad_u.nommer("gradient_vitesse");
743 ch_grad_u.fixer_nb_comp(nb_comp);
744 ch_grad_u.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
745 ch_grad_u.fixer_unite("s-1");
746 ch_grad_u.changer_temps(ch_vitesse.temps());
747
748 if (dimension == 2)
749 {
750 ch_grad_u.fixer_nom_compo(0, "dUdX"); // du/dx
751 ch_grad_u.fixer_nom_compo(1, "dUdY"); // du/dy
752 ch_grad_u.fixer_nom_compo(2, "dVdX"); // dv/dx
753 ch_grad_u.fixer_nom_compo(3, "dVdY"); // dv/dy
754 }
755 else
756 {
757 ch_grad_u.fixer_nom_compo(0, "dUdX"); // du/dx
758 ch_grad_u.fixer_nom_compo(1, "dUdY"); // du/dy
759 ch_grad_u.fixer_nom_compo(2, "dUdZ"); // du/dz
760 ch_grad_u.fixer_nom_compo(3, "dVdX"); // dv/dx
761 ch_grad_u.fixer_nom_compo(4, "dVdY"); // dv/dy
762 ch_grad_u.fixer_nom_compo(5, "dVdZ"); // dv/dz
763 ch_grad_u.fixer_nom_compo(6, "dWdX"); // dw/dx
764 ch_grad_u.fixer_nom_compo(7, "dWdY"); // dw/dy
765 ch_grad_u.fixer_nom_compo(8, "dWdZ"); // dw/dz
766 }
767
768}
769
770void VEF_discretisation::grad_T(const Domaine_dis_base& z, const Domaine_Cl_dis_base& zcl, const Champ_Inc_base& ch_temperature, OWN_PTR(Champ_Fonc_base)& ch) const
771{
772 Cerr << "Discretization of gradient_temperature" << finl;
773
774 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
775 creer_champ(ch, domaine_vef, "gradient_temperature_Champ_P1NC", "gradient_temperature", "K/m", dimension, domaine_vef.nb_elem(), ch_temperature.temps());
776
777 grad_T_Champ_P1NC& ch_gt = ref_cast(grad_T_Champ_P1NC, ch.valeur());
778 const Champ_P1NC& temp = ref_cast(Champ_P1NC, ch_temperature);
779 const Domaine_Cl_VEF& domaine_cl_vef = ref_cast(Domaine_Cl_VEF, zcl);
780 ch_gt.associer_domaine_Cl_dis_base(domaine_cl_vef);
781 ch_gt.associer_champ(temp);
782}
783
784void VEF_discretisation::h_conv(const Domaine_dis_base& z, const Domaine_Cl_dis_base& zcl, const Champ_Inc_base& ch_temperature, OWN_PTR(Champ_Fonc_base)& ch, Motcle& nom, int temp_ref) const
785{
786 Cerr << "Discretization of h_conv" << finl;
787 const Champ_P1NC& temp = ref_cast(Champ_P1NC, ch_temperature);
788 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
789 const Domaine_Cl_VEF& domaine_cl_vef = ref_cast(Domaine_Cl_VEF, zcl);
790 ch.typer("h_conv_Champ_P1NC");
791 h_conv_Champ_P1NC& ch_gt = ref_cast(h_conv_Champ_P1NC, ch.valeur());
792 ch_gt.associer_domaine_dis_base(domaine_vef);
793 ch_gt.associer_domaine_Cl_dis_base(domaine_cl_vef);
794 ch_gt.associer_champ(temp);
795 ch_gt.temp_ref() = temp_ref;
796 ch_gt.nommer(nom);
797 ch_gt.fixer_nb_comp(1);
798 ch_gt.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
799 ch_gt.fixer_unite("W/m2.K");
800 ch_gt.changer_temps(ch_temperature.temps());
801}
802
803void VEF_discretisation::taux_cisaillement(const Domaine_dis_base& z, const Domaine_Cl_dis_base& zcl, const Champ_Inc_base& ch_vitesse, OWN_PTR(Champ_Fonc_base)& champ) const
804{
805 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
806 const Domaine_Cl_VEF& domaine_cl_vef = ref_cast(Domaine_Cl_VEF, zcl);
807 champ.typer("Taux_cisaillement_P0_VEF");
808 Taux_cisaillement_P0_VEF& ch = ref_cast(Taux_cisaillement_P0_VEF, champ.valeur());
809 ch.associer_domaine_dis_base(domaine_vef);
810 const Champ_P1NC& vit = ref_cast(Champ_P1NC, ch_vitesse);
811 ch.associer_champ(vit, domaine_cl_vef);
812 ch.nommer("Taux_cisaillement");
813 ch.fixer_nb_comp(1);
814 ch.fixer_nb_valeurs_nodales(domaine_vef.nb_elem());
815 ch.fixer_unite("s-1");
816 ch.changer_temps(ch_vitesse.temps());
817}
818
819void VEF_discretisation::modifier_champ_tabule(const Domaine_dis_base& domaine_dis, Champ_Fonc_Tabule& le_champ_tabule, const VECT(OBS_PTR(Champ_base)) &ch_inc) const
820{
821 le_champ_tabule.typer_champ_tabule_discretise("Champ_Fonc_Tabule_P0_VEF");
822 Champ_Fonc_Tabule_P0_VEF& le_champ_tabule_dis = ref_cast(Champ_Fonc_Tabule_P0_VEF, le_champ_tabule.le_champ_tabule_discretise());
823 le_champ_tabule_dis.associer_domaine_dis_base(domaine_dis);
824 le_champ_tabule_dis.associer_param(ch_inc, le_champ_tabule.table());
825 le_champ_tabule_dis.nommer(le_champ_tabule.le_nom()); // We give a name to this field, help for debug
826 le_champ_tabule_dis.fixer_nb_comp(le_champ_tabule.nb_comp());
827 le_champ_tabule_dis.fixer_nb_valeurs_nodales(domaine_dis.nb_elem());
828 le_champ_tabule_dis.changer_temps(ch_inc[0]->temps());
829}
830
831void VEF_discretisation::residu(const Domaine_dis_base& z, const Champ_Inc_base& ch_inco, OWN_PTR(Champ_Fonc_base)& champ) const
832{
833 Nom ch_name(ch_inco.le_nom());
834 ch_name += "_residu";
835 Cerr << "Discretization of " << ch_name << finl;
836
837 const Domaine_VEF& domaine_vef = ref_cast(Domaine_VEF, z);
838 int nb_comp = ch_inco.valeurs().line_size();
839 Discretisation_base::discretiser_champ("champ_face", domaine_vef, ch_name, "units_not_defined", nb_comp, ch_inco.temps(), champ);
840 Champ_Fonc_base& ch_fonc = ref_cast(Champ_Fonc_base, champ.valeur());
841 DoubleTab& tab = ch_fonc.valeurs();
842 tab = -10000.0;
843 Cerr << "[Information] Discretisation_base::residu : the residue is set to -10000.0 at initial time" << finl;
844}
845
847{
849 Domaine_VEF& zvef = ref_cast(Domaine_VEF, dom);
850 zvef.discretiser_suite(*this);
851 return zvef;
852}
class Champ_Don_base base class of Given Fields (not calculated)
DoubleTab & valeurs() override
Overrides Champ_base::valeurs() Returns the array of values.
class Champ_Fonc_P0_VEF
int fixer_nb_valeurs_nodales(int n) override
Sets the number of degrees of freedom per component.
void associer_param(const VECT(OBS_PTR(Champ_base))&, const Table &)
Class Champ_Fonc_Tabule Derived class of Champ_Fonc_base representing.
const Table & table() const
void typer_champ_tabule_discretise(const Nom &typ)
const Champ_Fonc_base & le_champ_tabule_discretise() const
Returns the computed tabulated field.
class Champ_Fonc_base Base class of fields that are functions of a calculated quantity
void associer_domaine_dis_base(const Domaine_dis_base &) override
Class Champ_Inc_base.
const Domaine_dis_base & domaine_dis_base() const override
DoubleTab & valeurs() override
Returns the array of field values at the current time.
class Champ_Ostwald_VEF
void associer_eqn(const Navier_Stokes_std &)
void associer_champ(const Champ_P1NC &un_champ)
void associer_fluide(const Fluide_Ostwald &le_fluide)
int fixer_nb_valeurs_nodales(int nb_noeuds) override
Sets the number of degrees of freedom per component.
class Champ_base This class is the base of the fields hierarchy.
Definition Champ_base.h:43
virtual double changer_temps(const double t)
Sets the time at which the field is defined.
double temps() const
Returns the time of the field.
class Critere_Q_Champ_P1NC
void associer_champ(const Champ_P1NC &)
class Discret_Thyd This class is the base class representing a discretization
void set_param(Param &param) const override
virtual Domaine_dis_base & discretiser() const
static void creer_champ(OWN_PTR(Champ_Inc_base)&ch, const Domaine_dis_base &z, const Nom &type, const Nom &nom, const Nom &unite, int nb_comp, int nb_ddl, int nb_pas_dt, double temps, const Nom &directive=NOM_VIDE, const Nom &nom_discretisation=NOM_VIDE)
Static method that creates an OWN_PTR(Champ_Inc_base) of the specified type.
static const Motcle DEMANDE_DESCRIPTION
void discretiser_champ(const Motcle &directive, const Domaine_dis_base &z, const Nom &nom, const Nom &unite, int nb_comp, int nb_pas_dt, double temps, OWN_PTR(Champ_Inc_base)&champ, const Nom &sous_type=NOM_VIDE) const
class Domaine_Cl_dis_base Domaine_Cl_dis_base objects represent discretized boundary conditions
class Domaine_VEF
Definition Domaine_VEF.h:53
const Elem_VEF_base & type_elem() const
Definition Domaine_VEF.h:74
virtual void discretiser_suite(const VEF_discretisation &)
int nb_faces() const
Returns the total number of faces.
Definition Domaine_VF.h:471
class Domaine_dis_base This class is the base of the hierarchy of discretized domains.
const Domaine & domaine() const
Class defining operators and methods for all reading operation in an input flow (file,...
Definition Entree.h:42
virtual void fixer_nb_comp(int i)
Sets the number of components of the field.
const Nom & le_nom() const override
Returns the name of the field.
void nommer(const Nom &) override
Gives a name to the field.
virtual const Nom & fixer_unite(const Nom &)
Specifies the unit of a scalar field or whose all components have the same unit.
virtual Nature_du_champ fixer_nature_du_champ(Nature_du_champ nat)
Sets the nature of a field: scalar, multiscalar, vectorial.
virtual int nb_comp() const
Definition Field_base.h:56
virtual void add_synonymous(const Nom &nom)
Definition Field_base.h:53
virtual const Nom & fixer_nom_compo(int, const Nom &)
Sets the name of the i-th component of the field.
class Fluide_Ostwald
const Champ_Don_base & viscosite_dynamique() const
Definition Fluide_base.h:58
A character string (Nom) in uppercase.
Definition Motcle.h:26
An array of Motcle objects.
Definition Motcle.h:63
int search(const Motcle &t) const
Definition Motcle.cpp:319
Navier_Stokes_std This class carries the terms of the momentum equation.
const Champ_Inc_base & inconnue() const override
Returns the velocity (unknown field of the equation) (const version).
class Nom: a character string for naming TRUST objects.
Definition Nom.h:31
An array of character strings (VECT(Nom)).
Definition Noms.h:26
Base class for TRUST objects (Objet_U).
Definition Objet_U.h:68
static int dimension
Definition Objet_U.h:94
const Nom & que_suis_je() const
Returns the string identifying the class.
Definition Objet_U.cpp:104
virtual Entree & readOn(Entree &)
Reads an Objet_U from an input stream. Virtual method to override.
Definition Objet_U.cpp:289
virtual const Nom & le_nom() const
Returns the name of the Objet_U. Virtual method to override: returns "neant" in this implementation.
Definition Objet_U.cpp:317
virtual Sortie & printOn(Sortie &) const
Writes the object to an output stream. Virtual method to override.
Definition Objet_U.cpp:278
Helper class to factorize the readOn method of Objet_U classes.
Definition Param.h:112
void ajouter_flag(const char *keyword, const bool *value)
Register a boolean flag whose mere presence switches it to true.
Definition Param.cpp:474
void ajouter(const char *keyword, const int *value, Param::Nature nat=Param::OPTIONAL)
Register an integer parameter.
Definition Param.cpp:364
static void exit(int exit_code=-1)
Exit routine for TRUST within a Kokkos region.
Definition Process.cpp:466
void associer_champ(const Champ_P1NC &)
void associer_champ(const Champ_Q1NC &)
class Schema_Temps_base
double temps_courant() const
Returns the current time.
Base class for output streams.
Definition Sortie.h:52
int line_size() const
Definition TRUSTVect.tpp:67
class T_paroi_Champ_P1NC
void associer_domaine_Cl_dis_base(const Domaine_Cl_dis_base &le_dom_Cl_dis_base)
void associer_champ(const Champ_P1NC &)
class Taux_cisaillement_P0_VEF
void associer_champ(const Champ_P1NC &, const Domaine_Cl_dis_base &)
void discretiser_champ(const Motcle &directive, const Domaine_dis_base &z, Nature_du_champ nature, const Noms &nom, const Noms &unite, int nb_comp, int nb_pas_dt, double temps, OWN_PTR(Champ_Inc_base)&champ, const Nom &sous_type=NOM_VIDE) const override
Discretizes a field for VEFP1B according to a discretization directive.
void check_param() override
void distance_paroi_globale(const Schema_Temps_base &, Domaine_dis_base &, OWN_PTR(Champ_Fonc_base)&) const override
void vorticite(Domaine_dis_base &, const Champ_Inc_base &, OWN_PTR(Champ_Fonc_base)&) const
void creer_champ_vorticite(const Schema_Temps_base &, const Champ_Inc_base &, OWN_PTR(Champ_Fonc_base)&) const override
void set_param(Param &param) const override
void grad_T(const Domaine_dis_base &z, const Domaine_Cl_dis_base &, const Champ_Inc_base &temperature, OWN_PTR(Champ_Fonc_base)&ch) const override
void critere_Q(const Domaine_dis_base &z, const Domaine_Cl_dis_base &, const Champ_Inc_base &vitesse, OWN_PTR(Champ_Fonc_base)&ch) const override
void h_conv(const Domaine_dis_base &z, const Domaine_Cl_dis_base &, const Champ_Inc_base &temperature, OWN_PTR(Champ_Fonc_base)&ch, Motcle &nom, int temp_ref) const override
void distance_paroi(const Schema_Temps_base &, Domaine_dis_base &, OWN_PTR(Champ_Fonc_base)&) const
void y_plus(const Domaine_dis_base &z, const Domaine_Cl_dis_base &, const Champ_Inc_base &vitesse, OWN_PTR(Champ_Fonc_base)&ch) const override
void taux_cisaillement(const Domaine_dis_base &, const Domaine_Cl_dis_base &, const Champ_Inc_base &, OWN_PTR(Champ_Fonc_base)&) const override
void residu(const Domaine_dis_base &, const Champ_Inc_base &, OWN_PTR(Champ_Fonc_base)&) const override
void grad_u(const Domaine_dis_base &z, const Domaine_Cl_dis_base &, const Champ_Inc_base &temperature, OWN_PTR(Champ_Fonc_base)&ch) const override
void t_paroi(const Domaine_dis_base &z, const Domaine_Cl_dis_base &zcl, const Champ_Inc_base &, OWN_PTR(Champ_Fonc_base)&ch) const override
void proprietes_physiques_fluide_Ostwald(const Domaine_dis_base &, Fluide_Ostwald &, const Navier_Stokes_std &, const Champ_Inc_base &) const override
Discretizes the incompressible fluid in VEF, specifically K and N.
class Y_plus_Champ_P1NC
void associer_domaine_Cl_dis_base(const Domaine_Cl_dis_base &le_dom_Cl_dis_base)
void associer_champ(const Champ_P1NC &)
class grad_T_Champ_P1NC
void associer_domaine_Cl_dis_base(const Domaine_Cl_dis_base &le_dom_Cl_dis_base)
void associer_champ(const Champ_P1NC &)
class grad_U_Champ_P1NC
void associer_domaine_Cl_dis_base(const Domaine_Cl_dis_base &le_dom_Cl_dis_base)
void associer_champ(const Champ_P1NC &)
class h_conv_Champ_P1NC
void associer_champ(const Champ_P1NC &)
void associer_domaine_Cl_dis_base(const Domaine_Cl_dis_base &le_dom_Cl_dis_base)