21 static void fwd_i(IntervalMatrix& m,
const IntervalVector& x, Index i);
23 template<
typename... X>
24 requires (std::is_base_of_v<Domain,X> && ...)
25 static inline IntervalMatrix fwd(
const X&... x)
27 throw std::runtime_error(
"MatrixOp not fully implemented yet");
28 IntervalMatrix m(1,
sizeof...(X));
30 (MatrixOp::fwd_i(m, x, i++), ...);
34 template<
typename... X>
35 requires (std::is_base_of_v<VectorType,X> && ...)
36 static inline MatrixType fwd_natural(
const X&... x)
38 throw std::runtime_error(
"MatrixOp not fully implemented yet");
40 IntervalMatrix({x.a...}),
45 template<
typename... X>
46 requires (std::is_base_of_v<VectorType,X> && ...)
47 static inline MatrixType fwd_centered(
const X&... x)
49 throw std::runtime_error(
"MatrixOp not fully implemented yet");
51 IntervalMatrix({x.m...}),
52 IntervalMatrix({x.a...}),
58 template<
typename... X>
59 requires (std::is_base_of_v<IntervalVector,X> && ...)
60 static inline void bwd(
const IntervalMatrix& y, X&... x)
62 throw std::runtime_error(
"MatrixOp not fully implemented yet");
64 ((x &= y.col(i++)), ...);
73 template<
typename... X>
75 mat(
const std::shared_ptr<AnalyticExpr<X>>&... x)
77 return { std::make_shared<AnalyticOperationExpr<MatrixOp,MatrixType,X...>>(
78 AnalyticOperationExpr<MatrixOp,MatrixType,X...>(x...)) };
83 inline void MatrixOp::fwd_i(IntervalMatrix& m,
const IntervalVector& x, Index i)
85 assert(i >= 0 && i < m.cols());
86 m.resize(x.size(),m.cols());