TrioCFD 1.9.9_beta
TrioCFD documentation
Loading...
Searching...
No Matches
Champ_Fonc_Fonction.h
1/****************************************************************************
2* Copyright (c) 2024, 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 Champ_Fonc_Fonction_included
17#define Champ_Fonc_Fonction_included
18
19#include <Champ_Fonc_Tabule.h>
20
21/*! @brief Class Champ_Fonc_Fonction Derived class of Champ_Fonc_Tabule representing
22 *
23 * fields that are functions of another field via a function.
24 * The object carries a member of type OWN_PTR(Champ_Fonc_base) that stores
25 * the values of the tabulated field.
26 *
27 * @sa Champ_Fonc_base
28 */
30{
31 Declare_instanciable(Champ_Fonc_Fonction);
32};
33
35{
36 Declare_instanciable_sans_constructeur(Sutherland);
37
38public :
39 Sutherland();
40 void lire_expression();
41
42 // Inline methods
43 inline void set_val_params(const Nom& prob,const double A, const double C,const double Tref);
44 inline void set_prob(const Nom& prob) { prob_ = prob ;}
45 inline void set_A(const double A) { A_ = A; }
46 inline void set_C(const double C) { C_ = C; }
47 inline void set_Tref(const double Tref) { Tref_ = Tref; }
48 inline Nom& get_prob() { return prob_; }
49 inline const double& get_A() const { return A_; }
50 inline const double& get_C() const { return C_; }
51 inline const double& get_Tref() const { return Tref_; }
52
53protected:
54 double A_, C_, Tref_;
56};
57
58inline void Sutherland::set_val_params(const Nom& prob,const double A,const double C,const double Tref)
59{
60 set_prob(prob);
61 set_A(A);
62 set_C(C);
63 set_Tref(Tref);
64}
65
66#endif /* Champ_Fonc_Fonction_included */
Class Champ_Fonc_Fonction Derived class of Champ_Fonc_Tabule representing.
Class Champ_Fonc_Tabule Derived class of Champ_Fonc_base representing.
class Nom: a character string for naming TRUST objects.
Definition Nom.h:31
void set_A(const double A)
const double & get_A() const
void set_C(const double C)
void set_Tref(const double Tref)
void set_prob(const Nom &prob)
const double & get_C() const
const double & get_Tref() const
void set_val_params(const Nom &prob, const double A, const double C, const double Tref)