TRUST 1.9.8
HPC thermohydraulic platform
Loading...
Searching...
No Matches
Perte_Charge_Directionnelle_PolyMAC_CDO_Face.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 <Perte_Charge_Directionnelle_PolyMAC_CDO_Face.h>
17#include <Motcle.h>
18#include <Param.h>
19
20Implemente_instanciable(Perte_Charge_Directionnelle_PolyMAC_CDO_Face, "Perte_Charge_Directionnelle_Face_PolyMAC_CDO", Perte_Charge_PolyMAC_CDO);
21
23
25{
27 if (v->nb_comp() != dimension)
28 {
29 Cerr << "Il faut definir le champ direction a " << dimension << " composantes" << finl;
31 }
32 return s;
33}
34
40
41void Perte_Charge_Directionnelle_PolyMAC_CDO_Face::coeffs_perte_charge(const DoubleVect& u, const DoubleVect& pos, double t, double norme_u,
42 double dh, double nu, double reynolds, double& coeff_ortho,
43 double& coeff_long, double& u_l, DoubleVect& v_valeur) const
44{
45 coeffs_perte_charge_impl(u, pos, t, norme_u, dh, nu, reynolds, K_, coeff_ortho, coeff_long, u_l, v_valeur, lambda);
46}
47
48/////////////////////////////////////////////////
49
50Implemente_instanciable(Perte_Charge_Directionnelle_PolyMAC_HFV_Face, "Perte_Charge_Directionnelle_Face_PolyMAC_HFV|Perte_Charge_Directionnelle_Face_PolyMAC_MPFA", Perte_Charge_PolyMAC_HFV);
51
53
55{
57 if (v->nb_comp() != dimension)
58 {
59 Cerr << "Il faut definir le champ direction a " << dimension << " composantes" << finl;
61 }
62 return s;
63}
64
70
71void Perte_Charge_Directionnelle_PolyMAC_HFV_Face::coeffs_perte_charge(const DoubleVect& u, const DoubleVect& pos, double t, double norme_u,
72 double dh, double nu, double reynolds, double& coeff_ortho,
73 double& coeff_long, double& u_l, DoubleVect& v_valeur) const
74{
75 coeffs_perte_charge_impl(u, pos, t, norme_u, dh, nu, reynolds, K_, coeff_ortho, coeff_long, u_l, v_valeur, lambda);
76}
Class defining operators and methods for all reading operation in an input flow (file,...
Definition Entree.h:42
virtual void set_param(Param &) const
Definition Objet_U.h:135
static int dimension
Definition Objet_U.h:99
const Nom & que_suis_je() const
renvoie la chaine identifiant la classe.
Definition Objet_U.cpp:104
virtual Entree & readOn(Entree &)
Lecture d'un Objet_U sur un flot d'entree Methode a surcharger.
Definition Objet_U.cpp:293
virtual Sortie & printOn(Sortie &) const
Ecriture de l'objet sur un flot de sortie Methode a surcharger.
Definition Objet_U.cpp:282
void coeffs_perte_charge_impl(const DoubleVect &, const DoubleVect &, double, double, double, double, double, double, double &, double &, double &, DoubleVect &, Parser_U &) const
Implemente le calcul effectif de la perte de charge pour un lieu donne.
Helper class to factorize the readOn method of Objet_U classes.
Definition Param.h:112
void ajouter(const char *keyword, const int *value, Param::Nature nat=Param::OPTIONAL)
Register an integer parameter.
Definition Param.cpp:364
@ REQUIRED
Definition Param.h:115
Perte de charge directionnelle (selon un vecteur unitaire v).
void coeffs_perte_charge(const DoubleVect &, const DoubleVect &, double, double, double, double, double, double &, double &, double &, DoubleVect &) const override
Appele pour chaque face par ajouter().
void coeffs_perte_charge(const DoubleVect &, const DoubleVect &, double, double, double, double, double, double &, double &, double &, DoubleVect &) const override
Appele pour chaque face par ajouter().
Factorise les fonctionnalites de plusieurs pertes de charge en VEF, vitesse aux faces.
static void exit(int exit_code=-1)
Routine de sortie de TRUST dans une region Kokkos.
Definition Process.cpp:455
Classe de base des flux de sortie.
Definition Sortie.h:52