Chombo + EB  3.2
ConstantScalarFunction.H
Go to the documentation of this file.
1 #ifdef CH_LANG_CC
2 /*
3  * _______ __
4  * / ___/ / ___ __ _ / / ___
5  * / /__/ _ \/ _ \/ V \/ _ \/ _ \
6  * \___/_//_/\___/_/_/_/_.__/\___/
7  * Please refer to Copyright.txt, in Chombo's root directory.
8  */
9 #endif
10 
11 #ifndef _CONSTANTSCALARFUNCTION_H_
12 #define _CONSTANTSCALARFUNCTION_H_
13 
14 #include "ScalarFunction.H"
15 #include "NamespaceHeader.H"
16 
17 //! \class ConstantScalarFunction
18 //! This ScalarFunction subclass represents a function that returns a
19 //! constant value everywhere in space and time.
21 {
22  public:
23 
24  //! Creates a constant scalar function returning the given value.
25  //! \param a_value The value returned by the function.
26  explicit ConstantScalarFunction(Real a_value);
27 
28  //! Destructor.
30 
31  // Overridden methods.
32  Real operator()(const RealVect& a_x, Real a_t) const;
33 
34  Real derivative(const IntVect& a_order,
35  const RealVect& a_x,
36  Real a_t) const;
37 
38  private:
39 
41 };
42 
43 #include "NamespaceFooter.H"
44 #endif
Definition: ScalarFunction.H:21
ConstantScalarFunction(Real a_value)
~ConstantScalarFunction()
Destructor.
double Real
Definition: REAL.H:33
Definition: ConstantScalarFunction.H:20
A Real vector in SpaceDim-dimensional space.
Definition: RealVect.H:41
Real m_value
Definition: ConstantScalarFunction.H:40
Real operator()(const RealVect &a_x, Real a_t) const
An integer Vector in SpaceDim-dimensional space.
Definition: CHArray.H:42
Real derivative(const IntVect &a_order, const RealVect &a_x, Real a_t) const