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

Function operator-

include/cppoptlib/function_expressions.h:421–430  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

419 typename = std::void_t<decltype(F::Differentiability),
420 decltype(G::Differentiability)>>
421auto operator-(const F& f, const G& g) {
422 static_assert(
423 std::is_same<typename F::ScalarType, typename G::ScalarType>::value,
424 "ScalarType must match in addition.");
425 static_assert(
426 F::Dimension == G::Dimension,
427 "Dimension mismatch: F and G must have the same compile-time dimension.");
428 constexpr auto TMode = MinDifferentiability<F, G>::value;
429 return SubExpression<F, G, TMode>(f, g);
430}
431
432// For multiplication (F * c and c * F).
433template <typename F>

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected