Function that returns a single value that never changes. More...
#include <const_function.h>
Public Member Functions | |
ConstFunction (const Output &c) | |
ConstFunction (ConstFunction &&)=default | |
ConstFunction (const ConstFunction &)=default | |
ConstFunction & | operator= (const ConstFunction &)=default |
ConstFunction & | operator= (ConstFunction &&)=default |
virtual | ~ConstFunction ()=default |
virtual Output | operator() (const Point &, const Real=0) override |
virtual void | operator() (const Point &, const Real, DenseVector< Output > &output) override |
virtual std::unique_ptr< FunctionBase< Output > > | clone () const override |
virtual void | init () |
virtual void | clear () |
void | operator() (const Point &p, DenseVector< Output > &output) |
virtual Output | component (unsigned int i, const Point &p, Real time=0.) |
bool | initialized () const |
void | set_is_time_dependent (bool is_time_dependent) |
bool | is_time_dependent () const |
Protected Attributes | |
const FunctionBase * | _master |
bool | _initialized |
bool | _is_time_dependent |
Private Attributes | |
Output | _c |
Function that returns a single value that never changes.
Function that returns a single value that never changes. All overridden virtual functions are documented in function_base.h.
Definition at line 42 of file const_function.h.
|
inlineexplicit |
Definition at line 46 of file const_function.h.
References libMesh::FunctionBase< Output >::_initialized, and libMesh::FunctionBase< Output >::_is_time_dependent.
|
default |
The 5 special functions can be defaulted for this class.
|
default |
|
virtualdefault |
|
inlinevirtualinherited |
Clears the function.
Reimplemented in libMesh::ParsedFunction< Output, OutputGradient >, libMesh::ParsedFunction< T >, libMesh::MeshFunction, and libMesh::AnalyticFunction< Output >.
Definition at line 92 of file function_base.h.
|
inlineoverridevirtual |
The new copy should be as "deep" as necessary to allow independent destruction and simultaneous evaluations of the copies in different threads.
Implements libMesh::FunctionBase< Output >.
Reimplemented in libMesh::ZeroFunction< Output >.
Definition at line 74 of file const_function.h.
References libMesh::ConstFunction< Output >::_c.
|
inlinevirtualinherited |
i
at coordinate p
and time time
.Reimplemented in libMesh::CompositeFunction< Output >, libMesh::ParsedFunction< Output, OutputGradient >, libMesh::ParsedFunction< T >, and libMesh::WrappedFunction< Output >.
Definition at line 228 of file function_base.h.
|
inlinevirtualinherited |
The actual initialization process.
Reimplemented in libMesh::ParsedFunction< Output, OutputGradient >, libMesh::ParsedFunction< T >, libMesh::MeshFunction, and libMesh::AnalyticFunction< Output >.
Definition at line 87 of file function_base.h.
Referenced by libMesh::MeshFunction::clone().
|
inlineinherited |
true
when this object is properly initialized and ready for use, false
otherwise. Definition at line 206 of file function_base.h.
|
inlineinherited |
true
when the function this object represents is actually time-dependent, false
otherwise. Definition at line 220 of file function_base.h.
Referenced by libMesh::CompositeFunction< Output >::attach_subfunction().
|
inlineoverridevirtual |
p
and time time
, which defaults to zero.Pure virtual, so you have to override it.
Implements libMesh::FunctionBase< Output >.
Definition at line 61 of file const_function.h.
References libMesh::ConstFunction< Output >::_c.
|
inlineoverridevirtual |
Evaluation function for time-dependent vector-valued functions. Sets output values in the passed-in output
DenseVector.
Pure virtual, so you have to override it.
Implements libMesh::FunctionBase< Output >.
Definition at line 65 of file const_function.h.
References libMesh::ConstFunction< Output >::_c, and libMesh::DenseVector< T >::size().
|
inlineinherited |
Evaluation function for time-independent vector-valued functions. Sets output values in the passed-in output
DenseVector.
Definition at line 241 of file function_base.h.
|
default |
|
default |
|
inlineinherited |
Function to set whether this is a time-dependent function or not. This is intended to be only used by subclasses who cannot natively determine time-dependence. In such a case, this function should be used immediately following construction.
Definition at line 213 of file function_base.h.
|
private |
Definition at line 81 of file const_function.h.
Referenced by libMesh::ConstFunction< Output >::clone(), and libMesh::ConstFunction< Output >::operator()().
|
protectedinherited |
When init()
was called so that everything is ready for calls to operator()
(...), then this bool
is true.
Definition at line 180 of file function_base.h.
Referenced by libMesh::AnalyticFunction< Output >::AnalyticFunction(), libMesh::ConstFunction< Output >::ConstFunction(), and libMesh::WrappedFunction< Output >::WrappedFunction().
|
protectedinherited |
Cache whether or not this function is actually time-dependent.
Definition at line 185 of file function_base.h.
Referenced by libMesh::CompositeFunction< Output >::attach_subfunction(), and libMesh::ConstFunction< Output >::ConstFunction().
|
protectedinherited |
Const pointer to our master, initialized to nullptr
. There may be cases where multiple functions are required, but to save memory, one master handles some centralized data.
Definition at line 174 of file function_base.h.