Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
  • Sign in / Register
eigen
eigen
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 597
    • Issues 597
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Custom Issue Tracker
    • Custom Issue Tracker
  • Merge Requests 21
    • Merge Requests 21
  • Requirements
    • Requirements
    • List
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Security & Compliance
    • Security & Compliance
    • Dependency List
    • License Compliance
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Code Review
    • Insights
    • Issue
    • Repository
    • Value Stream
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • libeigen
  • eigeneigen
  • Issues
  • #553

Closed
Open
Opened Dec 04, 2019 by Eigen Bugzilla@eigenbzMaintainer

Matrix-matrix product with sparse self-adjoint matrix doesn't compile

Submitted by Clemens Hofreither

Assigned to Desire NUENTSA

Link to original bugzilla bug (#553)

Description

I have a self-adjoint sparse matrix and want to multiply it with another sparse matrix. Compiling the following code produces a compiler error on gcc 4.5.4:


#include <Eigen/Core>
#include <Eigen/Sparse>

using namespace Eigen;

int main()
{
SparseMatrix<double> x(10,10);
SparseMatrix<double> y(10,10);
SparseMatrix<double> z(10,10);

z = x * y;                              // works  
z = x.selfadjointView&lt;Lower&gt;() * y;     // compiler error  

}


The error is the following:

testspmatrix.cpp:14:38: error: no match for 'operator*' in 'Eigen::SparseMatrixBase<Derived>::selfadjointView() with unsigned int UpLo = 1u, Derived = Eigen::SparseMatrix<double> * y'
Eigen/src/SparseCore/../plugins/CommonCwiseUnaryOps.h:80:1: note: candidates are: const Eigen::CwiseUnaryOp<Eigen::internal::scalar_multiple2_op<double, std::complex<double> >, const Eigen::SparseMatrix<double> > Eigen::operator*(const std::complex<double>&, const Eigen::SparseMatrixBase<Eigen::SparseMatrix<double> >::StorageBaseType&)
Eigen/src/SparseCore/../plugins/CommonCwiseUnaryOps.h:76:1: note: const Eigen::SparseMatrixBase<Eigen::SparseMatrix<double> >::ScalarMultipleReturnType Eigen::operator*(const Eigen::SparseMatrixBase<Eigen::SparseMatrix<double, 0, int> >::Scalar&, const Eigen::SparseMatrixBase<Eigen::SparseMatrix<double> >::StorageBaseType&)


This seems like very basic functionality to have and is an absolute blocker for me. Am I doing something wrong?

Blocking

#387 (closed)

Edited Dec 05, 2019 by Eigen Bugzilla
Assignee
Assign to
3.2
Milestone
3.2
Assign milestone
Time tracking
None
Due date
None
Reference: libeigen/eigen#553