16#include <Fluide_Dilatable_base.h>
17#include <Loi_Etat_TPPI_QC_base.h>
18#include <Champ_Uniforme.h>
19#include <Domaine_VF.h>
32 if (!vec_press_filled_) init_vec_press();
35void Loi_Etat_TPPI_QC_base::init_vec_press()
37 const double Pth = le_fluide->pression_th();
38 vec_press_.resize(le_fluide->inco_chaleur().valeurs().dimension(0));
39 for (
auto &itr : vec_press_) itr = Pth;
40 vec_press_filled_ =
true;
54 if (!vec_press_filled_) init_vec_press();
55 const DoubleTab& tab_ICh = le_fluide->inco_chaleur().valeurs();
56 SpanD temp_span = tab_ICh.
get_span(), p_span = SpanD(vec_press_);
60 DoubleTab& tab_mu = mu.
valeurs();
67 DoubleTab& tab_lambda = lambda.
valeurs();
68 TPPI_->tppi_get_lambda_pT(p_span, temp_span, tab_lambda.
get_span());
73 DoubleTab& tab_alpha = alpha.
valeurs();
74 const DoubleTab& tab_rho = le_fluide->masse_volumique().valeurs();
76 const bool isVDF = (alpha.
que_suis_je() ==
"Champ_Fonc_P0_VDF") ? true :
false;
79 for (
int i = 0; i < tab_alpha.
dimension(0); i++)
80 tab_alpha(i, 0) = tab_lambda(i, 0) / (tab_rho(i, 0) *
Cp_);
83 const IntTab& elem_faces = ref_cast(
Domaine_VF, le_fluide->vitesse().domaine_dis_base()).elem_faces();
85 for (
int i = 0; i < tab_alpha.
dimension(0); i++)
88 for (
int face = 0; face < nfe; face++)
89 rhoelem += tab_rho(elem_faces(i, face), 0);
91 tab_alpha(i, 0) = tab_lambda(i, 0) / (rhoelem *
Cp_);
99 if (!vec_press_filled_) init_vec_press();
100 const DoubleTab& tab_ICh = le_fluide->inco_chaleur().valeurs();
101 DoubleTab& tab_rho = le_fluide->masse_volumique().valeurs();
102 SpanD temp_span = tab_ICh.
get_span(), p_span = SpanD(vec_press_), rho_span =
tab_rho_np1.get_span();
103 TPPI_->tppi_get_rho_pT(p_span, temp_span, rho_span);
classe Champ_Don_base classe de base des Champs donnes (non calcules)
void mettre_a_jour(double temps) override
Mise a jour en temps.
DoubleTab & valeurs() override
Surcharge Champ_base::valeurs() Renvoie le tableau des valeurs.
Class defining operators and methods for all reading operation in an input flow (file,...
void preparer_calcul() override
Prepare le fluide au calcul.
void calculer_masse_volumique() override
Recalcule la masse volumique.
void calculer_Cp() override
Calcule le Cp NE FAIT RIEN : le Cp est constant.
void preparer_calcul() override
Prepare le fluide au calcul.
std::shared_ptr< TPPI > TPPI_
const Nom & que_suis_je() const
renvoie la chaine identifiant la classe.
virtual Entree & readOn(Entree &)
Lecture d'un Objet_U sur un flot d'entree Methode a surcharger.
virtual Sortie & printOn(Sortie &) const
Ecriture de l'objet sur un flot de sortie Methode a surcharger.
Classe de base des flux de sortie.
_SIZE_ dimension(int d) const
Span_ get_span() override
virtual void echange_espace_virtuel(IsExchangeBlocking exchange_type=IsExchangeBlocking::DefaultBlocking, const std::string kernel_name="noname")