39 const DoubleVect& fs = domaine.face_surfaces();
40 const IntTab& f_e = domaine.face_voisins();
42 const int nb_faces = domaine.nb_faces();
43 DoubleTrav num_flux_left(nb_faces), num_flux_right(nb_faces);
47 for (
int f = 0; f < nb_faces; f++)
48 for (
int i = 0; i < 2; i++)
51 if (e >= 0 && e < domaine.nb_elem())
53 secmem(e, 0) -= (i ? num_flux_right(f) : num_flux_left(f)) * fs(f);
54 secmem(e, 1) += (i ? num_flux_right(f) : num_flux_left(f)) * fs(f);
62 const IntTab& f_e = domaine.face_voisins();
70 const int m = interface.id_phase_pression_inter();
74 const DoubleTab& vit_n = pb.
equation_qdm().vitesse_normale();
75 const DoubleTab& p = pb.
equation_qdm().pression().valeurs();
84 for (
int f = 0; f < domaine.nb_faces(); f++)
87 const int el = f_e(f, 0), er = f_e(f, 1);
88 double Sm = 0., Sp = 0., un_l = 0.;
89 compute_non_conservative_hll_left_bounds(vit_n, c, f, el, er, m, n, nb_phases, Sm, Sp, un_l);
91 num_flux_left(f) = (Sp * alpha(el, 0) - Sm * alpha(er, 0)) * un_l + Sp * Sm * (alpha(er, 0) - alpha(el, 0));
92 num_flux_left(f) /= (Sp - Sm);
94 compute_non_conservative_hll_right_bounds(vit_n, c, f, el, er, m, n, nb_phases, Sm, Sp, un_l);
96 num_flux_right(f) = (Sp * alpha(er, 0) - Sm * alpha(el, 0)) * un_l + Sp * Sm * (alpha(el, 0) - alpha(er, 0));
97 num_flux_right(f) /= (Sp - Sm);
102 for (
int f = 0; f < domaine.nb_faces(); f++)
105 const int el = f_e(f, 0), er = f_e(f, 1);
106 double Sm = 0., Sp = 0., un_l = 0.;
107 compute_non_conservative_hll_left_bounds(vit_n, c, f, el, er, m, n, nb_phases, Sm, Sp, un_l);
109 num_flux_left(f) = (Sp * alpha(el, 0) - Sm * alpha(er, 0)) * un_l * p(el, m);
110 num_flux_left(f) /= -(Sp - Sm);
112 compute_non_conservative_hll_right_bounds(vit_n, c, f, el, er, m, n, nb_phases, Sm, Sp, un_l);
114 num_flux_right(f) = (Sp * alpha(er, 0) - Sm * alpha(el, 0)) * un_l * p(er, m);
115 num_flux_right(f) /= -(Sp - Sm);
120 Cerr <<
"Op_NConserv_HLL_Coloc_Elem should not be used for equation " <<
equation().
que_suis_je() << finl;
128 for (
int f = 0; f < domaine.nb_faces(); f++)
131 assert(f_e(f, 1) < 0 && f_e(f, 0) >= 0 && vit_n(f, 0) != -123.123);
132 const int e = f_e(f, 0);
137 flux_bords_(f, 0) = num_flux_left(f) * domaine.face_surfaces(f);
141 const double alpha_bord = ref_cast(
Dirichlet, cls_alpha[fcl(f, 1)].valeur()).val_imp(fcl(f, 2), 0);
143 flux_bords_(f, 0) = num_flux_left(f) * domaine.face_surfaces(f);
148 flux_bords_(f, 0) = num_flux_left(f) * domaine.face_surfaces(f);
152 Cerr <<
"The BC of type " << fcl(f, 0) <<
" for the equation " << eq.
que_suis_je() <<
" is not available \n";
const Cond_lim & les_conditions_limites(int) const
Renvoie la i-ieme condition aux limites.