TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
Op_Grad_EF.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 <Op_Grad_EF.h>
17#include <Neumann_sortie_libre.h>
18#include <Dirichlet.h>
19#include <Navier_Stokes_std.h>
20#include <Probleme_base.h>
21#include <Schema_Temps_base.h>
22#include <EcrFicPartage.h>
23#include <SFichier.h>
24#include <Champ_P0_EF.h>
25#include <Check_espace_virtuel.h>
26#include <Debog.h>
27#include <Discretisation_base.h>
28#include <EChaine.h>
29
30#include <interface_INITGAUSS.h>
31#include <interface_CALCULSI.h>
32#include <Domaine.h>
33
34Implemente_instanciable(Op_Grad_EF,"Op_Grad_EF",Operateur_Grad_base);
35
36
37//// printOn
38//
39
41{
42 return s << que_suis_je() ;
43}
44
45//// readOn
46//
47
49{
50 return s ;
51}
52
57
58#undef lire_valimp_dans_med_
59
60/*! @brief
61 *
62 */
63void Op_Grad_EF::associer(const Domaine_dis_base& domaine_dis,
64 const Domaine_Cl_dis_base& domaine_Cl_dis,
65 const Champ_Inc_base& inc)
66{
67 const Domaine_EF& zEF = ref_cast(Domaine_EF, domaine_dis);
68 const Domaine_Cl_EF& zclEF = ref_cast(Domaine_Cl_EF, domaine_Cl_dis);
69 le_dom_EF = zEF;
70 la_zcl_EF = zclEF;
71 // const IntTab& face_sommets=zEF.face_sommets();
72#ifdef lire_valimp_dans_med_
73// assert(face_sommets.dimension(1)==4);
74// if (face_sommets.dimension(1)==4)
75 {
76 zclEF.equation().probleme().discretisation().discretiser_champ("CHAMP_SOMMETS",zEF,"int_P_bord","?",dimension,0.,int_P_bord_);
77
78
79 {
80 OWN_PTR(Champ_Don_base) champ_lu;
81 EChaine ee("champ_fonc_med last_time termes.med MAILLAGE_GENEPI terme_pression_limite_qdm_10 som 0.");
82 ee>>champ_lu;
83 int_P_bord_->affecter(champ_lu);
84 }
85 }
86#endif
87
88}
89
90
91
92
93static int bid=0;
94void test(const DoubleTab& pression, DoubleTab& grad,const Op_Grad_EF& op)
95{
96 if (bid==0)
97 {
98 bid=1;
99 DoubleTab pe(pression);
100 pe=1;
101 op.ajouter(pe,grad);
102 Cerr<<"ici max grad "<<grad.mp_max_abs_vect()<<finl;
103 //Cerr<<grad<<finl;
104 }
105
106}
107
108
109
110
111void Op_Grad_EF::ajouter_bord(DoubleTab& resu,const Domaine_EF& domaine_EF,const Domaine_Cl_EF& domaine_Cl_EF) const
112{
113 // const IntTab& face_voisins = domaine_EF.face_voisins();
114 const DoubleTab& face_normales = domaine_EF.face_normales();
115
116 const IntTab& face_sommets=domaine_EF.face_sommets();
117 int nb_som_face=domaine_EF.nb_som_face();
118 const DoubleTab& xs = domaine_EF.domaine().les_sommets();
119
120 if (int_P_bord_)
121 {
122 resu+= int_P_bord_->valeurs();
123 }
124 else
125 {
126 const DoubleVect& porosite_sommet = domaine_EF.porosite_sommet();
127
128 if (face_sommets.dimension(1)==4)
129 {
130 ArrOfInt filter(4) ;
131 filter[0] = 0 ;
132 filter[1] = 2 ;
133 filter[2] = 3 ;
134 filter[3] = 1 ;
135
136 interface_INITGAUSS init_gauss;
137 int npgau=9;
138 int nbnn=4;
139 DoubleTab xgau(npgau,3),frgau(npgau,nbnn),dfrgau(npgau,nbnn,(int)3),poigau(npgau);
140 int dim=2;
141 // init_gauss.compute(&dim,&nbnn,&npgau,xgau.addr(),frgau.addr(),dfrgau.addr(),poigau.addr());
142 init_gauss.Compute(dim,nbnn,npgau,xgau,frgau,dfrgau,poigau);
143 //ArrOfInt num(nbnn);
144 interface_CALCULSI CALCULSI;
145 DoubleTab xl(3,8),poro(4),detj(npgau), cnorm(3),si(4);
146 int ip=0;
147 const DoubleTab& coord=domaine_EF.domaine().coord_sommets();
148
149 //const DoubleTab& face_normales = domaine_EF.face_normales();
150
151 ArrOfInt num(4);
152 for ( int n_bord=0; n_bord<domaine_EF.nb_front_Cl(); n_bord++)
153 {
154 const Cond_lim& la_cl = domaine_Cl_EF.les_conditions_limites(n_bord);
155 const Front_VF& le_bord = ref_cast(Front_VF,la_cl->frontiere_dis());
156
157 int nfin = le_bord.nb_faces_tot();
158 if ( sub_type(Neumann_sortie_libre,la_cl.valeur()) )
159 {
160 const Neumann_sortie_libre& la_cl_typee =
161 ref_cast(Neumann_sortie_libre, la_cl.valeur());
162
163 for (int ind_face=0; ind_face<nfin; ind_face++)
164 {
165 int face=le_bord.num_face(ind_face);
166 for (int i=0; i<3; i++)
167 cnorm(i)=face_normales(face,i);
168 cnorm/=norme_array(cnorm);
169 // int elem = face_voisins(face,0);
170 double val_imp= la_cl_typee.flux_impose(ind_face);
171
172 for (int i=0; i<nbnn; i++)
173 {
174 num[i]=face_sommets(face,filter[i]);
175 }
176
177 for (int i=0; i<nbnn; i++)
178 {
179 for (int d=0; d<Objet_U::dimension; d++)
180 xl(d,i)=coord(num[i],d);
181 poro(i)=porosite_sommet[num[i]];
182 }
183
184 ip=1;
185 CALCULSI.Compute(nbnn, xl,
186 poro,ip,
187 npgau, xgau, frgau, dfrgau,
188 poigau,detj, cnorm,si);
189 for (int i=0; i<nbnn; i++)
190 {
191
192 for (int d=0; d<Objet_U::dimension; d++)
193 {
194 int som=num[(i)];
195 const double r_f = domaine_EF.xv(face,0);
196 const double r_s = xs(som,0);
197 const double corr = (axi && r_f>0.) ? (r_s / r_f) : 1.0;
198 resu(som,d) += corr * si(i) * cnorm(d) * val_imp;
199 }
200 }
201 }
202 }
203 }
204 }
205 else
206 for ( int n_bord=0; n_bord<domaine_EF.nb_front_Cl(); n_bord++)
207 {
208 const Cond_lim& la_cl = domaine_Cl_EF.les_conditions_limites(n_bord);
209 const Front_VF& le_bord = ref_cast(Front_VF,la_cl->frontiere_dis());
210
211 int nfin = le_bord.nb_faces_tot();
212 if ( sub_type(Neumann_sortie_libre,la_cl.valeur()) )
213 {
214 const Neumann_sortie_libre& la_cl_typee =
215 ref_cast(Neumann_sortie_libre, la_cl.valeur());
216
217 for (int ind_face=0; ind_face<nfin; ind_face++)
218 {
219 int face=le_bord.num_face(ind_face);
220 // int elem = face_voisins(face,0);
221 double val_imp= la_cl_typee.flux_impose(ind_face);
222 val_imp/=nb_som_face;
223 const double r_f = domaine_EF.xv(face,0);
224 for (int s=0; s<nb_som_face; s++)
225 {
226 int som=face_sommets(face,s);
227 const double r_s = xs(som,0);
228 const double corr = (axi && r_f>0.) ? (r_s / r_f) : 1.0;
229 for (int dir=0; dir<Objet_U::dimension; dir++)
230 resu(som,dir)+=corr*val_imp*face_normales(face,dir)*porosite_sommet(som);
231 }
232 }
233 }
234 }
235 }
236 domaine_Cl_EF.imposer_symetrie(resu);
237}
238
239
240DoubleTab& Op_Grad_EF::ajouter(const DoubleTab& pression, DoubleTab& grad) const
241{
242
243 test(pression,grad,(*this));
244 // Gradient of a scalar field located at element centers
245
246 // Initialize grad to zero
247 grad = 0;
248 assert_espace_virtuel_vect(pression);
249 Debog::verifier("pression dans Op_Grad_EF",pression);
250 const Domaine_EF& domaine_ef=ref_cast(Domaine_EF,equation().domaine_dis());
251
252
253 const DoubleTab& Bij_thilde=domaine_ef.Bij_thilde();
254 int nb_elem_tot=domaine_ef.domaine().nb_elem_tot();
255 int nb_som_elem=domaine_ef.domaine().nb_som_elem();
256 const IntTab& elems=domaine_ef.domaine().les_elems() ;
257 const DoubleTab& xs = domaine_ef.domaine().les_sommets();
258
259 for (int elem=0; elem<nb_elem_tot; elem++)
260 {
261 double pe=pression(elem);
262 const double r_e = domaine_ef.xp(elem,0);
263 for (int s=0; s<nb_som_elem; s++)
264 {
265 int som=elems(elem,s);
266 for (int i=0; i<dimension; i++)
267 {
268 const double r_s = xs(som,0);
269 const double w = bidim_axi ? (r_s / r_e) : 1.0;
270 grad(som,i) -= w * Bij_thilde(elem,s,i) * pe;
271 }
272 }
273 }
274
275 const IntTab& faces_sommets=domaine_ef.face_sommets();
276 int nb_som_face=faces_sommets.dimension(1);
277 // const IntTab& face_voisins = domaine_ef.face_voisins();
278 const DoubleTab& face_normales = domaine_ef.face_normales();
279 const Domaine_Cl_EF& domaine_Cl_EF = la_zcl_EF.valeur();
280
281
282
283 // account for BCs: add term - int P on the boundary
284 // test ...
285 for (int n_bord=0; n_bord<domaine_ef.nb_front_Cl()*1; n_bord++)
286 {
287 const Cond_lim& la_cl = domaine_Cl_EF.les_conditions_limites(n_bord);
288 if (sub_type(Neumann_sortie_libre,la_cl.valeur()) )
289 continue;
290
291 const Front_VF& le_bord = ref_cast(Front_VF,la_cl->frontiere_dis());
292 int num1 = 0;
293 int num2 = + le_bord.nb_faces_tot();
294 if (sub_type(Dirichlet,la_cl.valeur()) )
295 // this does nothing
296 for (int ind_face=num1; ind_face<num2; ind_face++)
297 {
298 int face=le_bord.num_face(ind_face);
299 for (int s=0; s<nb_som_face; s++)
300 {
301 int som=faces_sommets(face,s);
302 for (int comp=0; comp<dimension; comp++)
303 grad(som,comp) = 0;
304 }
305 }
306
307
308 else
309 for (int ind_face=num1; ind_face<num2*0; ind_face++)
310 {
311 int face=le_bord.num_face(ind_face);
312 if (domaine_ef.surface(face) < 1e-10) continue;
313 // int elem1 = face_voisins(face,0);
314 // double diff = - pression[elem1]/nb_som_face;
315
316 for (int s=0; s<nb_som_face; s++)
317 {
318 int som=faces_sommets(face,s);
319 // compute grad.S /S2
320 double grad_n=0;
321 for (int comp=0; comp<dimension; comp++)
322 grad_n+=grad(som,comp)*face_normales(face,comp);
323 grad_n/=(domaine_ef.surface(face)*domaine_ef.surface(face));
324 for (int comp=0; comp<dimension; comp++)
325 grad(som,comp) -= grad_n*face_normales(face,comp);
326 }
327 }
328 }
329 ajouter_bord(grad,domaine_ef,la_zcl_EF.valeur());
331 return grad;
332}
333
334DoubleTab& Op_Grad_EF::calculer(const DoubleTab& pre, DoubleTab& grad) const
335{
336 grad = 0;
337 return ajouter(pre,grad);
338
339}
340
342{
343 const Domaine_Cl_EF& domaine_Cl_EF = la_zcl_EF.valeur();
344 const Domaine_EF& domaine_EF = le_dom_EF.valeur();
345 const IntTab& face_voisins = domaine_EF.face_voisins();
346 const DoubleTab& face_normales = domaine_EF.face_normales();
347 const Navier_Stokes_std& eqn_hydr = ref_cast(Navier_Stokes_std,equation());
348 const Champ_P0_EF& la_pression_P0 = ref_cast(Champ_P0_EF,eqn_hydr.pression_pa());
349 const DoubleTab& pression_P0 = la_pression_P0.valeurs();
350 if (flux_bords_.size_array()==0) flux_bords_.resize(domaine_EF.nb_faces_bord(),dimension);
351 flux_bords_ = 0.;
352 for (int n_bord=0; n_bord<domaine_EF.nb_front_Cl(); n_bord++)
353 {
354 const Cond_lim& la_cl = domaine_Cl_EF.les_conditions_limites(n_bord);
355 const Front_VF& le_bord = ref_cast(Front_VF,la_cl->frontiere_dis());
356 int ndeb = le_bord.num_premiere_face();
357 int nfin = ndeb + le_bord.nb_faces();
358 for (int face=ndeb; face<nfin; face++)
359 {
360 int elem = face_voisins(face,0);
361 for (int i=0; i<dimension; i++)
362 flux_bords_(face,i) = pression_P0(elem)*face_normales(face,i);
363 }
364 }
365}
366
368{
369 const int impr_mom=le_dom_EF->domaine().moments_a_imprimer();
370 const int impr_sum=(le_dom_EF->domaine().bords_a_imprimer_sum().est_vide() ? 0:1);
371 const int impr_bord=(le_dom_EF->domaine().bords_a_imprimer().est_vide() ? 0:1);
373 double temps = sch.temps_courant();
374 const Domaine_Cl_EF& domaine_Cl_EF = la_zcl_EF.valeur();
375 const Domaine_EF& domaine_EF = le_dom_EF.valeur();
376 int n_bord ;
377 int face;
378 const ArrOfDouble& c_grav=le_dom_EF->domaine().cg_moments();
379 int flag=je_suis_maitre();
380 ouvrir_fichier(Flux_grad,"",flag);
381 ouvrir_fichier( Flux_grad_moment,"moment",impr_mom&&flag);
382 ouvrir_fichier(Flux_grad_sum,"sum",impr_sum&&flag);
383 EcrFicPartage Flux_grad_face;
384 ouvrir_fichier_partage(Flux_grad_face,"",impr_bord);
385 if (je_suis_maitre())
386 {
387 Flux_grad.add_col(temps);
388 if (impr_mom) Flux_grad_moment.add_col(temps);
389 if (impr_sum) Flux_grad_sum.add_col(temps);
390 }
391 for ( n_bord=0; n_bord<domaine_EF.nb_front_Cl(); n_bord++)
392 {
393 const Cond_lim& la_cl = domaine_Cl_EF.les_conditions_limites(n_bord);
394 const Front_VF& le_bord = ref_cast(Front_VF,la_cl->frontiere_dis());
395
396 int ndeb = le_bord.num_premiere_face();
397 int nfin = ndeb + le_bord.nb_faces();
398
399 double fluxx_s = 0. ;
400 double fluxy_s = 0. ;
401 double fluxz_s = 0. ;
402 double fluxx_sum_s = 0. ;
403 double fluxy_sum_s = 0. ;
404 double fluxz_sum_s = 0. ;
405 double moment_x = 0.;
406 double moment_y = 0.;
407 double moment_z = 0.;
408 for (face=ndeb; face<nfin; face++)
409 {
410 if (dimension == 2)
411 {
412 fluxx_s += flux_bords_(face,0) ;
413 fluxy_s += flux_bords_(face,1) ;
414
415 // Compute the moment exerted by the fluid on the boundary (OM/\F)
416 if (impr_mom) moment_z+=flux_bords_(face,1)*c_grav[0]-flux_bords_(face,0)*c_grav[1];
417
418 if (domaine_EF.domaine().bords_a_imprimer_sum().contient(le_bord.le_nom()))
419 {
420 fluxx_sum_s += flux_bords_(face,0) ;
421 fluxy_sum_s += flux_bords_(face,1) ;
422 }
423 }
424 else if (dimension == 3)
425 {
426 fluxx_s += flux_bords_(face,0) ;
427 fluxy_s += flux_bords_(face,1) ;
428 fluxz_s += flux_bords_(face,2) ;
429
430 // Compute the moment exerted by the fluid on the boundary (OM/\F)
431 moment_x+=flux_bords_(face,2)*c_grav[1]-flux_bords_(face,1)*c_grav[2];
432 moment_y+=flux_bords_(face,0)*c_grav[2]-flux_bords_(face,2)*c_grav[0];
433 moment_z+=flux_bords_(face,1)*c_grav[0]-flux_bords_(face,0)*c_grav[1];
434 if (domaine_EF.domaine().bords_a_imprimer_sum().contient(le_bord.le_nom()))
435 {
436 fluxx_sum_s += flux_bords_(face,0) ;
437 fluxy_sum_s += flux_bords_(face,1) ;
438 fluxz_sum_s += flux_bords_(face,2) ;
439 }
440 }
441 }
442 if (dimension == 2)
443 {
444 // Optimization: combine 5 mp_sum into 1 collective call
445 mp_sum_for_each(fluxx_s, fluxy_s, fluxx_sum_s, fluxy_sum_s, moment_z);
446 if (je_suis_maitre())
447 {
448 Flux_grad.add_col(fluxx_s);
449 Flux_grad.add_col(fluxy_s);
450 if (impr_sum)
451 {
452 Flux_grad_sum.add_col(fluxx_sum_s);
453 Flux_grad_sum.add_col(fluxy_sum_s);
454 }
455 if (impr_mom) Flux_grad_moment.add_col(moment_z);
456 }
457 }
458 if (dimension == 3)
459 {
460 // Optimization: combine 9 mp_sum into 1 collective call
461 ArrOfDouble tmp(9);
462 tmp[0] = fluxx_s;
463 tmp[1] = fluxy_s;
464 tmp[2] = fluxz_s;
465 tmp[3] = fluxx_sum_s;
466 tmp[4] = fluxy_sum_s;
467 tmp[5] = fluxz_sum_s;
468 tmp[6] = moment_x;
469 tmp[7] = moment_y;
470 tmp[8] = moment_z;
472 fluxx_s = tmp[0];
473 fluxy_s = tmp[1];
474 fluxz_s = tmp[2];
475 fluxx_sum_s = tmp[3];
476 fluxy_sum_s = tmp[4];
477 fluxz_sum_s = tmp[5];
478 moment_x = tmp[6];
479 moment_y = tmp[7];
480 moment_z = tmp[8];
481 if(je_suis_maitre())
482 {
483 Flux_grad.add_col(fluxx_s);
484 Flux_grad.add_col(fluxy_s);
485 Flux_grad.add_col(fluxz_s);
486 if (impr_sum)
487 {
488 Flux_grad_sum.add_col(fluxx_sum_s);
489 Flux_grad_sum.add_col(fluxy_sum_s);
490 Flux_grad_sum.add_col(fluxz_sum_s);
491 }
492 if (impr_mom)
493 {
494 Flux_grad_moment.add_col(moment_x);
495 Flux_grad_moment.add_col(moment_y);
496 Flux_grad_moment.add_col(moment_z);
497 }
498 }
499 }
500 }
501 if (je_suis_maitre())
502 {
503 Flux_grad << finl;
504 if (impr_mom) Flux_grad_moment<<finl;
505 if (impr_sum) Flux_grad_sum<<finl;
506 }
507 for ( n_bord=0; n_bord<domaine_EF.nb_front_Cl(); n_bord++)
508 {
509 const Cond_lim& la_cl = domaine_Cl_EF.les_conditions_limites(n_bord);
510 const Front_VF& le_bord = ref_cast(Front_VF,la_cl->frontiere_dis());
511
512 int ndeb = le_bord.num_premiere_face();
513 int nfin = ndeb + le_bord.nb_faces();
514 if (domaine_EF.domaine().bords_a_imprimer().contient(le_bord.le_nom()))
515 {
516 if (je_suis_maitre()) Flux_grad_face << "# Force par face sur " << le_bord.le_nom() << " au temps " << temps << " : " << finl;
517 for (face=ndeb; face<nfin; face++)
518 {
519 if (dimension==2)
520 Flux_grad_face << "# Face a x= " << domaine_EF.xv(face,0) << " y= " << domaine_EF.xv(face,1) << " flux_x= " << flux_bords_(face,0) << " flux_y= " << flux_bords_(face,1) << finl;
521 else if (dimension == 3)
522 Flux_grad_face << "# Face a x= " << domaine_EF.xv(face,0) << " y= " << domaine_EF.xv(face,1) << " z= " << domaine_EF.xv(face,3) << " flux_x= " << flux_bords_(face,0) << " flux_y= " << flux_bords_(face,1) << " flux_z= " << flux_bords_(face,2) << finl;
523 }
524 Flux_grad_face.syncfile();
525 }
526 }
527
528 return 1;
529}
530
class Champ_Don_base base class of Given Fields (not calculated)
Class Champ_Inc_base.
DoubleTab & valeurs() override
Returns the array of field values at the current time.
class Champ_P0_EF Represents a P0-per-element discrete field associated with a domain discretized as ...
Definition Champ_P0_EF.h:31
class Cond_lim Generic class used to represent any class
Definition Cond_lim.h:31
static void verifier(const char *const msg, double)
Definition Debog.cpp:21
Dirichlet This class is the base class of the hierarchy of Dirichlet-type boundary conditions.
Definition Dirichlet.h:31
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
int nb_som_elem() const
Returns the number of vertices of the geometric elements that make up the domain.
Definition Domaine.h:474
int_t nb_elem_tot() const
Definition Domaine.h:132
DoubleTab_t & les_sommets()
Definition Domaine.h:113
IntTab_t & les_elems()
Definition Domaine.h:129
const DoubleTab_t & coord_sommets() const
Definition Domaine.h:112
const ArrOfDouble & cg_moments() const
Definition Domaine.h:307
void imposer_symetrie(DoubleTab &, int tous_les_sommets_sym=0) const
Imposes symmetry conditions, i.e. cancels the field components along the normal(s).
class Domaine_Cl_dis_base Domaine_Cl_dis_base objects represent discretized boundary conditions
const Cond_lim & les_conditions_limites(int) const
Returns the i-th boundary condition.
class Domaine_EF
Definition Domaine_EF.h:56
const DoubleVect & porosite_sommet() const
Definition Domaine_EF.h:84
const DoubleTab & Bij_thilde() const
Definition Domaine_EF.h:90
virtual double face_normales(int face, int comp) const
Definition Domaine_VF.h:47
double xv(int num_face, int k) const
Definition Domaine_VF.h:76
int face_sommets(int i, int j) const
Returns the index of the i-th vertex of face num_face.
Definition Domaine_VF.h:582
virtual double surface(int i) const
Definition Domaine_VF.h:53
int nb_som_face() const
Returns the number of vertices per face.
Definition Domaine_VF.h:493
double xp(int num_elem, int k) const
Definition Domaine_VF.h:77
int face_voisins(int num_face, int i) const
Returns the neighbouring element of num_face in direction i.
Definition Domaine_VF.h:418
int nb_faces_bord() const
Returns the number of faces on which boundary conditions are applied:
Definition Domaine_VF.h:512
class Domaine_dis_base This class is the base of the hierarchy of discretized domains.
int nb_front_Cl() const
const Domaine & domaine() const
An input stream whose source is a character string.
Definition EChaine.h:31
Sortie & syncfile() override
Triggers writing to disk of the data accumulated on the different processors since the last call to s...
Class defining operators and methods for all reading operation in an input flow (file,...
Definition Entree.h:42
Probleme_base & probleme()
Returns the problem associated with the equation.
class Front_VF
Definition Front_VF.h:36
int nb_faces() const
Definition Front_VF.h:53
int num_premiere_face() const
Definition Front_VF.h:63
int nb_faces_tot() const
Definition Front_VF.h:58
int num_face(const int) const
Definition Front_VF.h:68
const Nom & le_nom() const override
Returns the name of the geometric boundary.
const Equation_base & equation() const
Returns the reference to the equation pointed to by MorEqn::mon_equation.
Definition MorEqn.h:62
Navier_Stokes_std This class carries the terms of the momentum equation.
Champ_Inc_base & pression_pa()
Neumann_sortie_libre This class represents an open boundary without imposed velocity.
virtual double flux_impose(int i) const
Returns the value of the imposed flux on the i-th component of the field representing the flux at the...
Definition Neumann.cpp:35
static int dimension
Definition Objet_U.h:94
friend class Sortie
Definition Objet_U.h:70
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
static int bidim_axi
Definition Objet_U.h:97
static int axi
Definition Objet_U.h:96
virtual Sortie & printOn(Sortie &) const
Writes the object to an output stream. Virtual method to override.
Definition Objet_U.cpp:278
class Op_Grad_EF
Definition Op_Grad_EF.h:34
DoubleTab & calculer(const DoubleTab &, DoubleTab &) const override
DoubleTab & ajouter(const DoubleTab &, DoubleTab &) const override
OWN_PTR(Champ_Don_base) int_P_bord_
void associer(const Domaine_dis_base &, const Domaine_Cl_dis_base &, const Champ_Inc_base &) override
void mettre_a_jour(double) override
DOES NOTHING - to override in derived classes.
void ajouter_bord(DoubleTab &resu, const Domaine_EF &domaine_EF, const Domaine_Cl_EF &domaine_Cl_EF) const
int impr(Sortie &os) const override
DOES NOTHING - to override in derived classes.
void calculer_flux_bords() const override
Classe Operateur_Grad_base This class is the base of the hierarchy of operators representing.
DoubleTab flux_bords_
virtual void mettre_a_jour(double temps)
DOES NOTHING - to override in derived classes.
void ouvrir_fichier_partage(EcrFicPartage &, const Nom &, const int flag=1) const
Opening/creation of a shared file for printing an operator. To override in derived classes.
void ouvrir_fichier(SFichier &os, const Nom &, const int flag=1) const
Opening/creation of a file for printing an operator. To override in derived classes.
const Discretisation_base & discretisation() const
Returns the discretization associated with the problem.
const Schema_Temps_base & schema_temps() const
Returns the time scheme associated with the problem.
static void mp_sum_for_each(T &arg1, T &arg2)
C++14 compatible mp_sum_for_each: combine multiple mp_sum calls into one collective operation Usage: ...
Definition Process.cpp:208
static void mp_sum_for_each_item(TRUSTArray< _TYPE_ > &x, int n=-1)
Definition Process.cpp:194
static int je_suis_maitre()
Returns 1 if on the master processor of the current group (i.e. me() == 0), 0 otherwise.
Definition Process.cpp:82
class Schema_Temps_base
double temps_courant() const
Returns the current time.
Base class for output streams.
Definition Sortie.h:52
_SIZE_ dimension(int d) const
Definition TRUSTTab.tpp:133
_TYPE_ mp_max_abs_vect(Mp_vect_options opt=VECT_REAL_ITEMS) const
Definition TRUSTVect.h:160
virtual void echange_espace_virtuel(IsExchangeBlocking exchange_type=IsExchangeBlocking::DefaultBlocking, const std::string kernel_name="noname")
void Compute(const int idimg, const int nbnn, const int npgau, ArrOfDouble &xgau, ArrOfDouble &frgau, ArrOfDouble &dfrgau, ArrOfDouble &poigau) const