|
dune-functions
2.5.0
|
Class storing differentiable functions using type erasure. More...
#include <dune/functions/common/differentiablefunction.hh>

Public Member Functions | |
| template<class F , disableCopyMove< DifferentiableFunction, F > = 0> | |
| DifferentiableFunction (F &&f) | |
| Construct from function. More... | |
| DifferentiableFunction ()=default | |
| Default constructor. More... | |
| Range | operator() (const Domain &x) const |
| Evaluation of wrapped function. More... | |
| Imp::DifferentiableFunctionTraits< Range(Domain), DerivativeTraits, bufferSize >::Concept & | asInterface () |
| Get mutable reference to wrapped object. More... | |
| const Imp::DifferentiableFunctionTraits< Range(Domain), DerivativeTraits, bufferSize >::Concept & | asInterface () const |
| Get reference to wrapped object. More... | |
| virtual const std::type_info & | target_type () const |
| Get type of stored object. More... | |
Protected Attributes | |
| PolymorphicSmallObject< Imp::TypeErasureWrapperInterface< Imp::DifferentiableFunctionTraits< Range(Domain), DerivativeTraits, bufferSize >::Concept >, 56 > | wrapped_ |
Friends | |
| DerivativeInterface | derivative (const DifferentiableFunction &t) |
| Get derivative of wrapped function. More... | |
Class storing differentiable functions using type erasure.
| Range | Range type |
| Domain | Domain type |
| DerivativeTraits | Traits class to determine range of derivative (defaults to DefaultDerivativeTraits) |
| bufferSize | Size of stack buffer for small object optimization (defaults to 56) |
This models the Concept::DifferentiableFunction<Range(Domain), DerivativeTraits> concept. Small object optimization is used to store the given function. If its size exceed bufferSize, memory will be allocated dynamically.
|
inline |
Construct from function.
| F | Function type |
| f | Function of type F |
Calling derivative(DifferentiableFunction) will result in an exception if the passed function does provide a free derivative() function found via ADL.
|
default |
Default constructor.
|
inlineinherited |
Get mutable reference to wrapped object.
|
inlineinherited |
Get reference to wrapped object.
|
inline |
Evaluation of wrapped function.
|
inlinevirtualinherited |
Get type of stored object.
|
protectedinherited |
1.8.12