mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-13 20:26:03 +08:00
fix twisted selfadjoint to selfadjoint (conjugation issue)
This commit is contained in:
parent
f5d0f115b4
commit
9ccd16609c
@ -367,6 +367,7 @@ void permute_symm_to_symm(const MatrixType& mat, SparseMatrix<typename MatrixTyp
|
||||
typedef SparseMatrix<Scalar,DestOrder,Index> Dest;
|
||||
Dest& dest(_dest.derived());
|
||||
typedef Matrix<Index,Dynamic,1> VectorI;
|
||||
internal::conj_if<SrcUpLo!=DstUpLo> cj;
|
||||
|
||||
Index size = mat.rows();
|
||||
VectorI count(size);
|
||||
@ -404,7 +405,7 @@ void permute_symm_to_symm(const MatrixType& mat, SparseMatrix<typename MatrixTyp
|
||||
Index ip = perm? perm[i] : i;
|
||||
Index k = count[DstUpLo==Lower ? std::min(ip,jp) : std::max(ip,jp)]++;
|
||||
dest._innerIndexPtr()[k] = DstUpLo==Lower ? std::max(ip,jp) : std::min(ip,jp);
|
||||
dest._valuePtr()[k] = it.value();
|
||||
dest._valuePtr()[k] = cj(it.value());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user