20 #ifndef LIBMESH_FEM_FUNCTION_BASE_H
21 #define LIBMESH_FEM_FUNCTION_BASE_H
24 #include "libmesh/libmesh_common.h"
25 #include "libmesh/dense_vector.h"
26 #include "libmesh/fem_context.h"
42 template <
typename Output=Number>
79 virtual std::unique_ptr<FEMFunctionBase<Output>>
clone ()
const = 0;
93 const Real time = 0.) = 0;
133 virtual Output
component(
const FEMContext &,
139 template <
typename Output>
147 (*this)(context, p, time, outvec);
151 template <
typename Output>
158 this->operator()(context, p, 0., output);
162 #endif // LIBMESH_FEM_FUNCTION_BASE_H
FEMFunctionBase & operator=(const FEMFunctionBase &)=default
virtual void init_context(const FEMContext &)
准备上下文对象以供使用。
FEMFunctionBase()=default
默认构造函数。
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
virtual ~FEMFunctionBase()=default
virtual Output operator()(const FEMContext &, const Point &p, const Real time=0.)=0
计算坐标p和时间time(默认为0)处的标量函数值。
virtual Output component(const FEMContext &, unsigned int i, const Point &p, Real time=0.)
返回坐标p和时间time的向量分量i。
virtual std::unique_ptr< FEMFunctionBase< Output > > clone() const =0
创建并返回函数的新副本。