mirror of
https://gitlab.com/libeigen/eigen.git
synced 2024-12-21 07:19:46 +08:00
doc: Note that dm2 = sm1 + dm1 is not possible (see bug #632).
This commit is contained in:
parent
8b10081dea
commit
1046ea7a89
@ -253,12 +253,15 @@ SparseMatrix<double> A, B;
|
||||
B = SparseMatrix<double>(A.transpose()) + A;
|
||||
\endcode
|
||||
|
||||
Binary coefficient wise operators can also mix sparse and dense expressions:
|
||||
Some binary coefficient-wise operators can also mix sparse and dense expressions:
|
||||
\code
|
||||
sm2 = sm1.cwiseProduct(dm1);
|
||||
dm2 = sm1 + dm1;
|
||||
dm1 += sm1;
|
||||
\endcode
|
||||
|
||||
However, it is not yet possible to add a sparse and a dense matrix as in <tt>dm2 = sm1 + dm1</tt>.
|
||||
Please write this as the equivalent <tt>dm2 = dm1; dm2 += sm1</tt> (we plan to lift this restriction
|
||||
in the next release of %Eigen).
|
||||
|
||||
%Sparse expressions also support transposition:
|
||||
\code
|
||||
|
Loading…
Reference in New Issue
Block a user