TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
Op_Conv_Amont_PolyMAC_CDO_Elem.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 <Op_Conv_Amont_PolyMAC_CDO_Elem.h>
17#include <Champ_Elem_PolyMAC_CDO.h>
18#include <Champ_Face_PolyMAC_CDO.h>
19
20Implemente_instanciable_sans_constructeur(Op_Conv_Amont_PolyMAC_CDO_Elem, "Op_Conv_Amont_PolyMAC_CDO_Elem", Op_Conv_PolyMAC_CDO_iterateur_base);
21
23{
24 return s << que_suis_je();
25}
26
28{
29 return s;
30}
31
32void Op_Conv_Amont_PolyMAC_CDO_Elem::associer(const Domaine_dis_base& domaine_dis, const Domaine_Cl_dis_base& domaine_cl_dis, const Champ_Inc_base& ch_transporte)
33{
34 const Domaine_PolyMAC_CDO& zvdf = ref_cast(Domaine_PolyMAC_CDO, domaine_dis);
35 const Domaine_Cl_PolyMAC_family& zclvdf = ref_cast(Domaine_Cl_PolyMAC_family, domaine_cl_dis);
36 const Champ_Elem_PolyMAC_CDO& inco = ref_cast(Champ_Elem_PolyMAC_CDO, ch_transporte);
37
38 iter_->associer(zvdf, zclvdf, *this);
39
40 Eval_Amont_PolyMAC_CDO_Elem& eval_conv = (Eval_Amont_PolyMAC_CDO_Elem&) iter_->evaluateur();
41 eval_conv.associer_domaines(zvdf, zclvdf); // Evaluateur_PolyMAC_CDO::associer
42 eval_conv.associer_inconnue(inco); // Eval_PolyMAC_CDO_Elem::associer_inconnue
43}
44
45/*! @brief Associates the velocity field to the evaluator.
46 *
47 * @param ch_vit The velocity field to associate (must be of type Champ_Face_PolyMAC_CDO).
48 */
50{
51 const Champ_Face_PolyMAC_CDO& vit = ref_cast(Champ_Face_PolyMAC_CDO, ch_vit);
52
53 Eval_Amont_PolyMAC_CDO_Elem& eval_conv = (Eval_Amont_PolyMAC_CDO_Elem&) iter_->evaluateur();
54 eval_conv.associer(vit); // Eval_Conv_PolyMAC_CDO::associer
55}
56
58{
59 Eval_Amont_PolyMAC_CDO_Elem& eval_conv = (Eval_Amont_PolyMAC_CDO_Elem&) iter_->evaluateur();
60 return eval_conv.vitesse();
61}
62
64{
65 Eval_Amont_PolyMAC_CDO_Elem& eval_conv = (Eval_Amont_PolyMAC_CDO_Elem&) iter_->evaluateur();
66 return eval_conv.vitesse();
67}
68
Class Champ_Inc_base.
class Champ_base This class is the base of the fields hierarchy.
Definition Champ_base.h:43
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.
Class defining operators and methods for all reading operation in an input flow (file,...
Definition Entree.h:42
class Eval_Amont_PolyMAC_CDO_Elem
const Champ_Inc_base & vitesse() const
void associer(const Champ_Face_PolyMAC_CDO &)
void associer_inconnue(const Champ_base &)
virtual void associer_domaines(const Domaine_PolyMAC_CDO &, const Domaine_Cl_PolyMAC_family &)
const Nom & que_suis_je() const
Returns the string identifying the class.
Definition Objet_U.cpp:104
virtual Entree & readOn(Entree &)
Reads an Objet_U from an input stream. Virtual method to override.
Definition Objet_U.cpp:289
virtual Sortie & printOn(Sortie &) const
Writes the object to an output stream. Virtual method to override.
Definition Objet_U.cpp:278
class Op_Conv_Amont_PolyMAC_CDO_Elem
const Champ_base & vitesse() const override
void associer_vitesse(const Champ_base &) override
Associates the velocity field to the evaluator.
void associer(const Domaine_dis_base &, const Domaine_Cl_dis_base &, const Champ_Inc_base &) override
Op_Conv_PolyMAC_CDO_iterateur_base(const Iterateur_PolyMAC_CDO_base &iter_base)
Base class for output streams.
Definition Sortie.h:52