TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
Op_Diff_Flux_Chaleur_Turb_Base.h
1/****************************************************************************
2* Copyright (c) 2019, 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#ifndef Op_Diff_Flux_Chaleur_Turb_Base_included
17#define Op_Diff_Flux_Chaleur_Turb_Base_included
18
19#include <Operateur_Diff_base.h>
20#include <Operateur.h>
21#include <Operateur_negligeable.h>
22#include <Matrice_Morse.h>
23#include <Op_Diff_Flux_Chaleur_Turb_Base.h>
24#include <TRUST_Deriv.h>
25
26
27#include <TRUSTTabs_forward.h>
28
29/*! @brief class Op_Diff_Flux_Chaleur_Turb_Base Sert a modeliser le terme diffusif dans l'equation de transport
30 *
31 * des fluctuations thermiques
32 * On traite les deux equations de transport en une seule
33 * equation vectorielle.
34 * La viscosite_turbulente est a diviser par la constante Prdt_teta
35 * pour la diffusion de K et par la constante Prdt_epsteta pour la
36 * diffusion de Eps
37 *
38 */
40{
42
43public:
45
46};
47
48
49
50
52
53{
54 Declare_instanciable(Op_Diff_Flux_Chaleur_Turb_negligeable);
55
56public:
57
58 inline void associer(const Domaine_dis_base&, const Domaine_Cl_dis_base&, const Champ_Inc_base& ) override;
59 inline DoubleTab& ajouter(const DoubleTab& , DoubleTab& ) const override;
60 inline DoubleTab& calculer(const DoubleTab& , DoubleTab& ) const override;
61 inline void contribuer_a_avec(const DoubleTab&, Matrice_Morse&) const override;
62 inline void contribuer_au_second_membre(DoubleTab& ) const override;
63 inline void modifier_pour_Cl(Matrice_Morse&, DoubleTab&) const override;
64 inline void dimensionner(Matrice_Morse& ) const override;
65 inline void associer_diffusivite_turbulente() override;
66};
67
68
69//////////////////////////////////////////////////////////////////////////////
70//
71// CLASS: Op_Diff_Flux_Chaleur_Turb
72//
73//////////////////////////////////////////////////////////////////////////////
74
75
77 public OWN_PTR(Op_Diff_Flux_Chaleur_Turb_Base)
78{
79
80 Declare_instanciable(Op_Diff_Flux_Chaleur_Turb);
81
82public:
83
84 inline Operateur_base& l_op_base() override;
85 inline const Operateur_base& l_op_base() const override;
86 inline DoubleTab& ajouter(const DoubleTab& , DoubleTab& ) const override;
87 inline DoubleTab& calculer(const DoubleTab& , DoubleTab& ) const override;
88 void typer() override;
89 void completer() override;
90 inline int op_non_nul() const override;
91
92
93};
94
95///////////////////////////////////////////////////////////////
96// Fonctions inline de la classe Op_Diff_Flux_Chaleur_Turb_negligeable
97///////////////////////////////////////////////////////////////
98
100 const Domaine_Cl_dis_base& domaine_cl_dis,
101 const Champ_Inc_base& inco)
102{
103 Operateur_negligeable::associer(domaine_dis,domaine_cl_dis,inco);
104}
105
106inline DoubleTab& Op_Diff_Flux_Chaleur_Turb_negligeable::ajouter(const DoubleTab& x, DoubleTab& y) const
107{
109}
110
111inline DoubleTab& Op_Diff_Flux_Chaleur_Turb_negligeable::calculer(const DoubleTab& x, DoubleTab& y) const
112{
114}
115
116/*! @brief on assemble la matrice.
117 *
118 */
120 Matrice_Morse& matrice) const
121{
122}
123
124/*! @brief on ajoute la contribution du second membre.
125 *
126 */
130
131// Modification des Cl
133{
134}
135
139
143
145{
146 if(!this->operator bool())
147 Cerr << "Op_Diff_Flux_Chaleur_Turb n'a pas ete typer" << finl;
148 return valeur();
149}
150
152{
153 if(!this->operator bool())
154 Cerr << "Op_Diff_Flux_Chaleur_Turb n'a pas ete typer" << finl;
155 return valeur();
156}
157
158inline DoubleTab& Op_Diff_Flux_Chaleur_Turb::ajouter(const DoubleTab& inconnue, DoubleTab& resu) const
159{
160 return valeur().ajouter(inconnue, resu);
161}
162
163
164inline DoubleTab& Op_Diff_Flux_Chaleur_Turb::calculer(const DoubleTab& inconnue, DoubleTab& resu) const
165{
166 return valeur().calculer(inconnue, resu);
167}
168
170{
171 return this->operator bool();
172}
173
174#endif
175
Class Champ_Inc_base.
class Domaine_Cl_dis_base Domaine_Cl_dis_base objects represent discretized boundary conditions
class Domaine_dis_base This class is the base of the hierarchy of discretized domains.
Matrice_Morse class - Represents a (sparse) matrix M, not necessarily square,.
class Op_Diff_Flux_Chaleur_Turb_Base Sert a modeliser le terme diffusif dans l'equation de transport
virtual void associer_diffusivite_turbulente()=0
void modifier_pour_Cl(Matrice_Morse &, DoubleTab &) const override
DOES NOTHING - to override in derived classes.
void contribuer_au_second_membre(DoubleTab &) const override
on ajoute la contribution du second membre.
DoubleTab & calculer(const DoubleTab &, DoubleTab &) const override
void dimensionner(Matrice_Morse &) const override
DOES NOTHING - to override in derived classes.
DoubleTab & ajouter(const DoubleTab &, DoubleTab &) const override
void associer(const Domaine_dis_base &, const Domaine_Cl_dis_base &, const Champ_Inc_base &) override
void contribuer_a_avec(const DoubleTab &, Matrice_Morse &) const override
on assemble la matrice.
void completer() override
Updates the references of the objects associated with the operator.
DoubleTab & calculer(const DoubleTab &, DoubleTab &) const override
DoubleTab & ajouter(const DoubleTab &, DoubleTab &) const override
Operateur_base & l_op_base() override
class Operateur_base This class is the base of the hierarchy of objects representing an
Classe Opnegligeable This class defines the interface of a negligible operator.
DoubleTab & calculer(const DoubleTab &, DoubleTab &) const
Initializes the array parameter with the contribution of the negligible operator: initializes the arr...
void associer(const Domaine_dis_base &, const Domaine_Cl_dis_base &, const Champ_Inc_base &)
Associates various objects to a negligible operator: DOES NOTHING.
DoubleTab & ajouter(const DoubleTab &, DoubleTab &) const
Adds the contribution of a negligible operator to an array.
class Operateur Generic class of the operator hierarchy.
Definition Operateur.h:39