New user self-registration is currently disabled. Please email eigen-core-team @ lists.tuxfamily.org if you need an account.
Bug 1358 - mat+=selfadjoint_view problem for sparse matrices
mat+=selfadjoint_view problem for sparse matrices
Status: RESOLVED FIXED
Product: Eigen
Classification: Unclassified
Component: Sparse
3.3 (current stable)
All All
: Normal Compilation Problem
Assigned To: Nobody
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2016-12-08 01:40 UTC by Yixuan Qiu
Modified: 2016-12-14 16:55 UTC (History)
2 users (show)



Attachments

Description Yixuan Qiu 2016-12-08 01:40:36 UTC
This is basically the same problem as in bug 1343 (http://eigen.tuxfamily.org/bz/show_bug.cgi?id=1343), but for sparse matrices.

A minimal example:

=====================================================================

#include <Eigen/SparseCore>

typedef Eigen::SparseMatrix<double> SpMat;

int main()
{
    SpMat m1(10, 10);
    
    SpMat m2 = m1.selfadjointView<Eigen::Lower>(); // Fine
    SpMat m3(10, 10);
    m3 += m1.selfadjointView<Eigen::Lower>();      // Fails on 3.3
    
    return 0;
}

=====================================================================

OS: Fedora 25 64-bit
Compiler: GCC 6.2/clang 3.8



Thank you.


Best,
Yixuan
Comment 1 Gael Guennebaud 2016-12-14 16:55:03 UTC
This had to be expected!

Fixed:
https://bitbucket.org/eigen/eigen/commits/0a9b971803ae/
Summary:     Bug 1358: fix compilation for sparse += sparse.selfadjointView();

3.3: https://bitbucket.org/eigen/eigen/commits/7895f20fc7f7/

Note You need to log in before you can comment on or make changes to this bug.