|
MGIS 3.1.0
|
an evaluator applying a binary operation to the values returned by two evaluators More...
#include </home/runner/work/MFrontGenericInterfaceSupport/MFrontGenericInterfaceSupport/include/MGIS/Function/BinaryOperation.hxx>
Public Member Functions | |
| MGIS_HOST_DEVICE constexpr | BinaryOperationModifier (const CallableType &, const FirstEvaluatorType &, const SecondEvaluatorType &) |
| constructor | |
| MGIS_HOST_DEVICE constexpr auto | apply (const evaluator_result< FirstEvaluatorType > &, const evaluator_result< SecondEvaluatorType > &) const |
| apply the modifier | |
| Public Member Functions inherited from mgis::function::BinaryOperationEvaluatorBase< BinaryOperationModifier< CallableType, FirstEvaluatorType, SecondEvaluatorType >, FirstEvaluatorType, SecondEvaluatorType > | |
| constexpr | BinaryOperationEvaluatorBase (const FirstEvaluatorType &, const SecondEvaluatorType &) |
| constructor | |
| constexpr decltype(auto) | getSpace () const |
| return the underlying space | |
| constexpr bool | check (AbstractErrorHandler &) const |
| perform consistency checks | |
| constexpr auto | operator() (const element_index< Space > &) const |
| call operator | |
an evaluator applying a binary operation to the values returned by two evaluators
Such an evaluator is usually built with the binary_operation function, which can either be applied to two evaluators at once or be partially applied to the second evaluator only, in which case a modifier is obtained and can be applied to the first evaluator using operator|:
The callable object is stored in the instance. The number of components of the returned values is the compile-time size of the type returned by the callable, which must thus be known at compile time. The two evaluators must be defined on the same space and must both be either element evaluators or quadrature evaluators, as stated by BinaryOperationEvaluatorBaseRequirement. Only the call operators which match the way both evaluators can be called are available.
| CallableType | type of the binary operation, which must be copy constructible and callable with the values returned by the two evaluators |
| FirstEvaluatorType | type of the evaluator used to compute the first argument of the operation |
| SecondEvaluatorType | type of the evaluator used to compute the second argument of the operation |
|
constexpr |
constructor
| [in] | c | binary operation, a copy of which is stored in the object |
| [in] | e1 | evaluator used to compute the first argument of the operation |
| [in] | e2 | evaluator used to compute the second argument of the operation |
|
nodiscardconstexpr |
apply the modifier
calls the stored callable object with the given values
| [in] | v1 | value computed by the evaluator of the first argument of the operation at a given integration point |
| [in] | v2 | value computed by the evaluator of the second argument of the operation at the same integration point |