Hi All, I just found an issue that newly appeared in the 3.3 version. The problem is that a matrix-vector multiplication cannot be used to initialize an ArrayXd object. See the minimal example below: ===================================================================== #include <Eigen/Core> using Eigen::MatrixXd; using Eigen::VectorXd; using Eigen::ArrayXd; int main() { MatrixXd m1 = MatrixXd::Random(10, 10); VectorXd v1 = VectorXd::Random(10); ArrayXd a1 = v1; // This is fine ArrayXd a2 = m1 * v1; // OK on 3.2 but fails on 3.3 return 0; } ===================================================================== OS: Fedora 25 64-bit Compiler: GCC 6.2/clang 3.8 Thank you. Best, Yixuan
A possibly related one: ===================================================================== #include <Eigen/Core> using Eigen::MatrixXd; int main() { MatrixXd m1 = MatrixXd::Random(10, 10); MatrixXd m2 = m1.selfadjointView<Eigen::Lower>(); // Fine MatrixXd m3 = MatrixXd::Zero(10, 10); m3 += m1.selfadjointView<Eigen::Lower>(); // Fails on 3.3 return 0; } ===================================================================== Maybe coming from the new mechanism of expression evaluation? Best, Yixuan
For the 1st one, the problem is that in 3.2, the expression turned out to be evaluated as: ArrayXd a2 = (m1*v1).eval() (this was not the case if a2 is a VectorXf). In 3.3, the implementation is more general, and it thus reveals this issue. Fixed: https://bitbucket.org/eigen/eigen/commits/25c392fdbf64/ 3.3: https://bitbucket.org/eigen/eigen/commits/669d7bf13a67/ For the second one, the generic EigenBase2EigenBase assignment was lacking -= and +=, fixed: https://bitbucket.org/eigen/eigen/commits/0e78c04fea69/ 3.3: https://bitbucket.org/eigen/eigen/commits/9b63b9758a3f/
Thank you Gael!
-- GitLab Migration Automatic Message -- This bug has been migrated to gitlab.com's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.com/libeigen/eigen/issues/1343.