Skip to content

Commit dfda032

Browse files
robertodrarnfinn
authored andcommitted
Fix calculation of S matrix inverse (#156)
1 parent 787f9dd commit dfda032

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@
3939
are handled in the API functions.
4040
- Properly enforce `const`-correctness of the `Meddle` object and of its usage
4141
in the context API.
42+
- [Cholesky decomposition](http://eigen.tuxfamily.org/dox/classEigen_1_1LLT.html) is used
43+
in CPCMSolver to get the inverse of the S matrix. The robust Cholesky (LDLT)
44+
previously used is broken with the latest version of the Intel compilers.
4245

4346
## [Version 1.2.0-rc1] - 2018-03-02
4447

src/solver/CPCMSolver.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ Eigen::VectorXd CPCMSolver::computeCharge_impl(const Eigen::VectorXd & potential
7676
int nrBlocks = blockS_.size();
7777
int irrDim = fullDim / nrBlocks;
7878
charge.segment(irrep * irrDim, irrDim) =
79-
-blockS_[irrep].ldlt().solve(potential.segment(irrep * irrDim, irrDim));
79+
-blockS_[irrep].llt().solve(potential.segment(irrep * irrDim, irrDim));
8080

8181
return charge;
8282
}

0 commit comments

Comments
 (0)