16#include <Source_Reaction_Particules_VDF.h>
18#include <Transport_Marqueur_FT.h>
20#include <Domaine_VDF.h>
21#include <Champ_implementation_P1.h>
23#include <Dirichlet_homogene.h>
24#include <Milieu_base.h>
25#include <MD_Vector_tools.h>
26#include <Probleme_base.h>
47 const DoubleTab& source_action = eq_marqueur_->source_stockage();
51 const Domaine& domaine_geom = zdis.
domaine();
53 const IntTab& sommet_poly = domaine_geom.
les_elems();
57 const DoubleTab& positions = maillage.
sommets();
64 int nb_som_face = domaine_geom.type_elem()->nb_som_face();
71 const int nb_elem_reels = domaine_geom.
nb_elem();
74 DoubleTab source_som(0, dim);
83 const DoubleTab& rho_faces = champ_rho.
valeurs();
88 for (
int pos=0; pos<nb_pos; pos++)
90 x_pos = positions(pos,0);
91 y_pos = positions(pos,1);
93 z_pos = positions(pos,2);
98 if (elem < nb_elem_reels)
100 for (
int som=0; som<nb_som_elem; som++)
102 som_glob = sommet_poly(elem,som);
104 coord_b = coord_barycentrique_P1_rectangle(sommet_poly,coord,x_pos,y_pos,elem,som) ;
106 coord_b = coord_barycentrique_P1_hexaedre(sommet_poly,coord,x_pos,y_pos,z_pos,elem,som) ;
107 for (
int k=0; k<dim; k++)
108 source_som(som_glob,k) -= source_action(pos,k)*coord_b;
120 for (num_cl=0 ; num_cl<zdis.
nb_front_Cl() ; num_cl++)
125 int nfin = ndeb + le_bord.
nb_faces();
129 for (
int face=ndeb ; face<nfin ; face++)
131 int ncomp = orient(face);
134 rho = (is_FT==1?rho_faces(face):rho_faces(0,0));
135 for (
int nbsf=0; nbsf<nb_som_face; nbsf++)
137 som_glob = face_som(face,nbsf);
138 resu(face) += (1./nb_som_face)*source_som(som_glob,ncomp)/rho;
144 for (
int face=premiere_face_interne; face<nb_faces; face++)
146 int ncomp = orient(face);
149 rho = (is_FT==1?rho_faces(face):rho_faces(0,0));
151 for (
int nbsf=0; nbsf<nb_som_face; nbsf++)
153 som_glob = face_som(face,nbsf);
154 resu(face) += (1./nb_som_face)*source_som(som_glob,ncomp)/rho;
virtual DoubleTab & valeurs()=0
class Champ_base This class is the base of the fields hierarchy.
class Cond_lim Generic class used to represent any class
Classe Dirichlet_homogene This class is the base class of the hierarchy of homogeneous Dirichlet-type...
Dirichlet This class is the base class of the hierarchy of Dirichlet-type boundary conditions.
int nb_som_elem() const
Returns the number of vertices of the geometric elements that make up the domain.
const DoubleTab_t & coord_sommets() const
virtual void creer_tableau_sommets(Array_base &, RESIZE_OPTIONS opt=RESIZE_OPTIONS::COPY_INIT) const
Creates an array with one "row" per mesh vertex.
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.
int orientation(int) const override
inline DoubleVect& Domaine_VDF::porosite_face() {
int nb_faces() const
Returns the total number of faces.
int face_sommets(int i, int j) const
Returns the index of the i-th vertex of face num_face.
int premiere_face_int() const
A face is internal if and only if it separates two elements.
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,...
virtual const Milieu_base & milieu() const =0
virtual Domaine_Cl_dis_base & domaine_Cl_dis()
Returns the discretized boundary condition domain associated with the equation.
Probleme_base & probleme()
Returns the problem associated with the equation.
Domaine_dis_base & domaine_dis()
Returns the discretized domain associated with the equation.
int num_premiere_face() const
: class Maillage_FT_Disc Cette classe decrit un maillage:
const DoubleTab & sommets() const
renvoie le tableau des sommets (reels et virtuels) dimension(0) = nombre de sommets,
const ArrOfInt & sommet_elem() const
pour postraitement, renvoie sommet_elem_
virtual const Champ_base & masse_volumique() const
Returns the mass density of the medium (const version).
const Equation_base & equation() const
Returns the reference to the equation pointed to by MorEqn::mon_equation.
virtual Entree & readOn(Entree &)
Reads an Objet_U from an input stream. Virtual method to override.
virtual Sortie & printOn(Sortie &) const
Writes the object to an output stream. Virtual method to override.
bool is_dilatable() const
Base class for output streams.
Classe Source_Reaction_Particules_VDF.
DoubleTab & ajouter(DoubleTab &) const override
Classe Source_Reaction_Particules Calcul du terme source a ajouter dans Navier_Stokes pour prendre en...
_SIZE_ dimension(int d) const