Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9118511
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T05:10:19+00:00 2026-06-17T05:10:19+00:00

I have a lower triangular matrix M (strict, with 0 on the diagonal). I

  • 0

I have a lower triangular matrix M (strict, with 0 on the diagonal).
I want to turn this unto a symmetric matrix, efficiently.
(e.g. i want to do M<-M+M'). I’m using Eigen.

My problem, is i’m doing:

U=U+U.transpose();

but reading the docs i have the feeling that, perhaps,
i should be taking advantage of some functions such
as .noalias() and/or .transposeInPlace(), but the
obvious candidate:

U+=U.transposeInPlace();

gives an error.

EDIT:

here is the error message:

.cpp:210:24: note: candidates are:
/eigen/Eigen/src/Core/MatrixBase.h:183:14: note: template<class OtherDerived> Derived& Eigen::MatrixBase::operator+=(const Eigen::MatrixBase<OtherDerived>&) [with OtherDerived = OtherDerived, Derived = Eigen::Matrix<float, -0x00000000000000001, -0x00000000000000001>]
/eigen/Eigen/src/Core/MatrixBase.h:517:46: note: template<class OtherDerived> Derived& Eigen::MatrixBase::operator+=(const Eigen::ArrayBase<OtherDerived>&) [with OtherDerived = OtherDerived, Derived = Eigen::Matrix<float, -0x00000000000000001, -0x00000000000000001>]
/eigen/Eigen/src/Core/DenseBase.h:266:14: note: template<class OtherDerived> Derived& Eigen::DenseBase::operator+=(const Eigen::EigenBase<OtherDerived>&) [with OtherDerived = OtherDerived, Derived = Eigen::Matrix<float, -0x00000000000000001, -0x00000000000000001>]
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T05:10:20+00:00Added an answer on June 17, 2026 at 5:10 am

    in Eigen, transposeInPlace() is declared as void. Thus, you can’t use the result of that method in a sum of matrices, because the result simply isn’t a matrix.

    Do

    V = U;
    V.transposeInPlace();
    U += V;
    

    instead.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a DATE column that I want to round to the next-lower 10
I have this piece of code for my images, so the opacity can lower
If I have a 32-bit binary number and I want to replace the lower
I have an upper bound and a lower bound and I want to return
I want dLower and dHigher to have the lower and higher of two double
I have images that have different size (lower than 200x200 px) I want them
There have been proposals for C++ delegates which have lower overhead than boost::function :
I have created mysql to delete table rows, which have lower DATETIME value than
I have an application that is developed for ios lower than ios 5.. it
I have a PNG image in an BufferedImage and I would like to lower

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.