16#include <Echange_contact_rayo_transp_VDF.h>
17#include <Modele_rayo_transp.h>
18#include <Champ_front_uniforme.h>
19#include <Champ_front_calc.h>
20#include <Champ_Uniforme.h>
21#include <Pb_Fluide_base.h>
22#include <Domaine_VDF.h>
33 assert (!le_modele_rayo_);
41 le_modele_rayo_ =ref_cast(
Pb_Fluide_base, this_pb).get_mod_rayo_transp();
50 le_modele_rayo_ = ref_cast(
Pb_Fluide_base, other_pb).get_mod_rayo_transp();
54 Cerr << finl <<
"Big issue in Echange_contact_rayo_transp_VDF::initialiser !!!" << finl;
56 Cerr <<
"of problems " << this_pb.
le_nom() <<
" and " <<
nom_autre_pb_ <<
" , but neither is a fluid radiation problem !!!" << finl;
57 Process::exit(
"Please fix your data file and use the classical paroi_contact BC for these boundaries ... \n");
75 const int nb_faces_bord = ma_front_vf.
nb_faces();
77 for (
int numfa = 0; numfa < nb_faces_bord; numfa++)
79 const int ind_fac = numfa + ndeb;
86 teta_i_(numfa) = mon_inco(elem);
100 Cerr <<
"end of construction in " <<
que_suis_je() << finl;
124 Cerr <<
"big problem in " <<
que_suis_je() << finl;
129 Process::exit(
"The boundary name must be the same for both domains at the raccord level");
135 if (domaine_dis1.
domaine().
raccord(nom_racc1)->que_suis_je() !=
"Raccord_distant_homogene")
145 assert(nb_comp == 1);
146 int is_pb_fluide = 0;
149 DoubleTab& mon_h = h_imp_->valeurs();
152 double invhparoi = 1. /
h_paroi;
163 for (
int ii = 0; ii < taille; ii++)
164 for (
int jj = 0; jj < nb_comp; jj++)
165 mon_h(ii, jj) = 1. / (1. /
autre_h(ii, jj) + 1. / mon_h(ii, jj));
172 Cerr <<
"This path should not be taken: Echange_contact_rayo_transp_VDF::calculer_Teta_equiv " << __FILE__ << finl;
191 int nb_faces_bord = ma_front_vf.
nb_faces();
206 const Front_VF& frontfluide = (ispbfluide ? ma_front_vf : autre_front_vf);
207 int nb_faces_bord_fluide = frontfluide.
nb_faces();
208 DoubleVect flux_radia_fluide(nb_faces_bord_fluide);
211 for (
int nfluide = 0; nfluide < nb_faces_bord_fluide; nfluide++)
212 flux_radia_fluide(nfluide) = modrayo.
flux_radiatif(nfluide + ndebfluide);
214 DoubleVect fluxradia;
218 if ((ispbfluide) || (domaine_dis1.
domaine().
raccord(nom_racc1)->que_suis_je() !=
"Raccord_distant_homogene"))
219 fluxradia = flux_radia_fluide;
223 for (
int numfa = 0; numfa < nb_faces_bord; numfa++)
225 ind_fac = numfa + ndeb;
231 double new_Teta_i = (mon_h(numfa, 0) * mon_inco(elem) + lautre_h(numfa, 0) * t_autre(numfa, 0) - fluxradia(numfa)) / (mon_h(numfa, 0) + lautre_h(numfa, 0));
233 double tetisa =
teta_i_(numfa);
236 Teta_equiv(numfa, 0) = (-mon_h(numfa, 0) * mon_inco(elem) + (lautre_h(numfa, 0) + mon_h(numfa, 0)) *
teta_i(numfa)) / lautre_h(numfa, 0);
240 Cerr <<
"Teta_equiv fin " << Teta_equiv(numfa, 0) <<
" Teta_i_old " << tetisa <<
" Teta_i " <<
teta_i_(numfa);
241 Cerr <<
" Teta_equiv avt modif " << (mon_h(numfa, 0) * mon_inco(elem) + lautre_h(numfa, 0) * t_autre(numfa) - fluxradia(numfa)) / (mon_h(numfa, 0) + lautre_h(numfa, 0));
242 Cerr <<
" h " << mon_h(numfa, 0) <<
" autreh " << lautre_h(numfa, 0) <<
" flux radia " << fluxradia(numfa);
243 Cerr <<
" mon T " << mon_inco(elem) <<
" autre T " << t_autre(numfa) << finl;
247 Debog::verifier(
"Teta_equiv dans Echange_contact_rayo_transp_VDF::calculer_Teta_paroi", Teta_equiv);
264Echange_contact_Rayo_transp_sans_relax_VDF::Echange_contact_Rayo_transp_sans_relax_VDF()
DoubleTab & valeurs() override
Returns the array of field values at the current time.
virtual void associer_fr_dis_base(const Frontiere_dis_base &)
Associates a discretized boundary with the field.
virtual void mettre_a_jour(double temps)
DOES NOTHING, to override.
class Champ_front_calc Derived class of Champ_front_var representing
const Frontiere_dis_base & front_dis() const
Returns the discretized boundary corresponding to the domain on which the trace is taken.
const Champ_Inc_base & inconnue() const
Returns the associated unknown field.
const Milieu_base & milieu() const
Returns the medium associated with the equation carrying the unknown field whose trace is taken.
DoubleTab & valeurs_au_temps(double temps) override
Returns the values at the desired time.
Domaine_Cl_dis_base & domaine_Cl_dis()
Returns the domain of discretized boundary conditions to which the object belongs.
virtual Frontiere_dis_base & frontiere_dis()
Returns the discretized boundary to which the boundary conditions apply.
virtual double teta_i(int numfa) const
void preparer_surface(const Frontiere_dis_base &, const Domaine_Cl_dis_base &)
static void verifier(const char *const msg, double)
Raccord_t & raccord(int i)
Domaine_dis_base & domaine_dis()
Returns a reference to the discretized domain associated with the boundary conditions.
int face_voisins(int num_face, int i) const
Returns the neighbouring element of num_face in direction i.
class Domaine_dis_base This class is the base of the hierarchy of discretized domains.
const Frontiere_dis_base & frontiere_dis(const Nom &) const
Returns the boundary of Name nom.
const Domaine & domaine() const
void mettre_a_jour(double temps) override
Performs a time update of the boundary condition.
virtual Champ_front_base & T_ext()
Returns the T_ext field of temperature imposed at the boundary.
Class defining operators and methods for all reading operation in an input flow (file,...
class Equation_base The role of an equation is the calculation of one or more fields....
virtual const Champ_Inc_base & inconnue() const =0
Probleme_base & probleme()
Returns the problem associated with the equation.
Domaine_dis_base & domaine_dis()
Returns the discretized domain associated with the equation.
virtual int nb_comp() const
int num_premiere_face() const
virtual void trace_face_distant(const DoubleTab &, DoubleTab &) const
const Nom & le_nom() const override
Returns the name of the Objet_U. Virtual method to override: returns "neant" in this implementation.
const Frontiere & frontiere() const
Returns the associated geometric boundary.
const Nom & le_nom() const override
Returns the name of the geometric boundary.
static Objet_U & objet(const Nom &)
See Interprete_bloc::objet_global(). BM: the Interprete class is not the best place for this.
Milieu_base This class is the base of the (physical) medium hierarchy.
virtual bool is_rayo_transp() const
virtual const Champ_Don_base & conductivite() const
Returns the conductivity of the medium (const version).
double relaxation() const
double flux_radiatif(int num_face_global) const
const Equation_base & equation() const
Returns the reference to the equation pointed to by MorEqn::mon_equation.
class Nom: a character string for naming TRUST objects.
const Nom & que_suis_je() const
Returns the string identifying the class.
virtual Entree & readOn(Entree &)
Reads an Objet_U from an input stream. Virtual method to override.
virtual const Nom & le_nom() const
Returns the name of the Objet_U. Virtual method to override: returns "neant" in this implementation.
virtual Sortie & printOn(Sortie &) const
Writes the object to an output stream. Virtual method to override.
Pb_Fluide_base This class provides a base class for.
const Nom & le_nom() const override
Returns the name of the Objet_U. Virtual method to override: returns "neant" in this implementation.
class Probleme_base It is a Probleme_U that is not a coupling.
virtual const Milieu_base & milieu() const
Returns the physical medium associated with the problem (const version).
static void exit(int exit_code=-1)
Exit routine for TRUST within a Kokkos region.
Base class for output streams.
_SIZE_ dimension(int d) const