When using IntervalVectors and standard types, for example doubles :
IntervalVector x(2);
double y = 0.3;
Binary operators & and | won't work with the mixed-type product as left-hand operand :
IntervalVector z_bad = (x * y) | x; // breaks
IntervalVector z_good = x | (x * y); // works
Compilation will output the following :
/codac/build_install/include/eigen3/Eigen/src/Core/functors/BinaryFunctors.h:573:3:
error: static assertion failed: BITWISE OPERATIONS MAY ONLY BE PERFORMED ON PLAIN DATA TYPES
573 | EIGEN_STATIC_ASSERT(!NumTraits<Scalar>::RequireInitialization,
| ^~~~~~~~~~~~~~~~~~~
Note : This can be resolved by casting the mixed prodcut to IntervalVector, but this issue can be tricky to detect.
When using IntervalVectors and standard types, for example doubles :
Binary operators
&and|won't work with the mixed-type product as left-hand operand :Compilation will output the following :
Note : This can be resolved by casting the mixed prodcut to
IntervalVector, but this issue can be tricky to detect.