Skip to content

[eigen] Avoid using .template cast<Interval>() for mixed types operations #314

Description

@SimonRohou

In C++, the following operation cannot be written...

    Eigen::Matrix<Interval,-1,-1> A;
    Eigen::Matrix<double,-1,-1> B;
    Eigen::Matrix<Interval,-1,-1> C = A * B;

.. without casting B to an interval type:

    Eigen::Matrix<Interval,-1,-1> C = A * B.template cast<Interval>();

This could be simplified (maybe), based on:
https://libeigen.gitlab.io/eigen/docs-3.3/structEigen_1_1ScalarBinaryOpTraits.html

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions