TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
Transport_2eq_base.h
1/****************************************************************************
2* Copyright (c) 2025, 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#ifndef Transport_2eq_base_included
16#define Transport_2eq_base_included
17
18#include <Modele_turbulence_hyd_2_eq_base.h>
19#include <Equation_base.h>
20#include <Operateur_Conv.h>
21#include <Operateur_Diff.h>
22#include <TRUST_Ref.h>
23
25class Champ_Inc_base;
26class Milieu_base;
27
28/*! @brief Classe Transport_2eq_base Classe de base pour les equations
29 *
30 * de transport des modeles a deux equations type k-DISSIP
31 *
32 */
34{
35 Declare_base(Transport_2eq_base);
36
37public:
38
39 void set_param(Param&) const override;
40 void associer(const Equation_base&);
41 inline void associer_vitesse(const Champ_base&);
42 void associer_milieu_base(const Milieu_base&) override;
43 Milieu_base& milieu() override;
44 const Milieu_base& milieu() const override;
45 double calculer_pas_de_temps() const override;
49
50protected:
51 void get_position_cells(Nom&, int&);
52 void get_position_faces(Nom&, int&);
53
55
58
59
61
62 OBS_PTR(Milieu_base) le_fluide;
63 OBS_PTR(Champ_Inc_base) la_vitesse_transportante;
65};
66
68{
69 la_vitesse_transportante = ref_cast(Champ_Inc_base, vit);
70}
71
72/*! @brief Renvoie le modele de turbulence associe a l'equation.
73 *
74 * (version const)
75 *
76 * @return (Modele_turbulence_hyd_base&) le modele de turbulence associe a l'equation
77 */
79{
80 assert(mon_modele);
81 return mon_modele.valeur();
82}
83
84/*! @brief Renvoie le modele de turbulence associe a l'equation.
85 *
86 * @return (Modele_turbulence_hyd_base&) le modele de turbulence associe a l'equation
87 */
89{
90 assert(mon_modele);
91 return mon_modele.valeur();
92}
93
94#endif
Class Champ_Inc_base.
class Champ_base This class is the base of the fields hierarchy.
Definition Champ_base.h:43
class Equation_base The role of an equation is the calculation of one or more fields....
Milieu_base This class is the base of the (physical) medium hierarchy.
Definition Milieu_base.h:50
Classe Modele_turbulence_hyd_2_eq_base Classe de base des modeles de type RANS a deux equations.
class Nom: a character string for naming TRUST objects.
Definition Nom.h:31
friend class Entree
Definition Objet_U.h:71
Operateur_Conv Generic class of the hierarchy of operators representing a convection term.
Operateur_Diff Generic class of the hierarchy of operators representing a diffusion.
Helper class to factorize the readOn method of Objet_U classes.
Definition Param.h:112
Classe Transport_2eq_base Classe de base pour les equations.
Operateur_Conv terme_convectif
void set_param(Param &) const override
void associer_vitesse(const Champ_base &)
OBS_PTR(Modele_turbulence_hyd_2_eq_base) mon_modele
Milieu_base & milieu() override
Renvoie le milieu (fluide) associe a l'equation.
const Modele_turbulence_hyd_2_eq_base & modele_turbulence() const
Renvoie le modele de turbulence associe a l'equation.
virtual void associer_modele_turbulence(const Modele_turbulence_hyd_2_eq_base &)=0
Operateur_Diff terme_diffusif
void associer(const Equation_base &)
void get_position_cells(Nom &, int &)
void associer_milieu_base(const Milieu_base &) override
Associe un milieu physique a l'equation.
OBS_PTR(Champ_Inc_base) la_vitesse_transportante
OBS_PTR(Milieu_base) le_fluide
void get_position_faces(Nom &, int &)
double calculer_pas_de_temps() const override
Calculation of the next time step.
Entree & lire_op_diff_turbulent(Entree &is)