MCPcopy Create free account
hub / github.com/PatWie/CppNumericalSolvers / operator*

Function operator*

include/cppoptlib/function_expressions.h:434–439  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

432// For multiplication (F * c and c * F).
433template <typename F>
434auto operator*(const F& f, const typename F::ScalarType& c)
435 -> MulExpression<F, typename F::ScalarType, F::Differentiability> {
436 using ScalarType = typename F::ScalarType;
437 // Always return a MulExpression. Inside its operator() you can check if c==0.
438 return MulExpression<F, ScalarType, F::Differentiability>(c, f);
439}
440
441template <typename F>
442auto operator*(const typename F::ScalarType& c, const F& f)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected