Skip to content

Commit

Permalink
core orbitals can now be used in phaseless calculations
Browse files Browse the repository at this point in the history
  • Loading branch information
ankit76 committed Apr 6, 2022
1 parent 6060be5 commit a4aeb96
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DQMC/Multislater.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ void Multislater::forceBias(std::array<Eigen::MatrixXcd, 2>& psi, Hamiltonian& h
greenMulti[0] = greenMulti[0].transpose().eval();
greenMulti[1] = greenMulti[1].transpose().eval();
for (int i = 0; i < ham.chol.size(); i++)
fb(i) = (greenMulti[0].block(0, 0, norbs, nact)).cwiseProduct(ham.chol[i].block(0, 0, norbs, nact)).sum() + (greenMulti[1].block(0, 0, norbs, nact)).cwiseProduct(ham.chol[i].block(0, 0, norbs, nact)).sum();
fb(i) = (greenMulti[0].block(0, 0, norbs, ncore + nact)).cwiseProduct(ham.chol[i].block(0, 0, norbs, ncore + nact)).sum() + (greenMulti[1].block(0, 0, norbs, ncore + nact)).cwiseProduct(ham.chol[i].block(0, 0, norbs, ncore + nact)).sum();
//for (int i = 0; i < ham.chol.size(); i++)
// fb(i) = (greenMulti[0].block(0, 0, nact, norbs)).cwiseProduct(ham.chol[i].block(0, 0, nact, norbs)).sum() + (greenMulti[1].block(0, 0, nact, norbs)).cwiseProduct(ham.chol[i].block(0, 0, nact, norbs)).sum();
//fb(i) = (greenMulti[0]).cwiseProduct(ham.chol[i]).sum() + (greenMulti[1]).cwiseProduct(ham.chol[i]).sum();
Expand Down
4 changes: 4 additions & 0 deletions utils/input.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -654,6 +654,8 @@ void readDeterminants(std::string input, std::array<std::vector<int>, 2>& ref, s
for (int i = 0; i < ncore; i++) {
refDet.setoccA(i, true);
refDet.setoccB(i, true);
ref[0].push_back(i);
ref[1].push_back(i);
}
VectorXi sizes = VectorXi::Zero(10);
int numDets = 0;
Expand Down Expand Up @@ -770,6 +772,8 @@ void readDeterminantsBinary(std::string input, std::array<std::vector<int>, 2>&
for (int i = 0; i < ncore; i++) {
refDet.setoccA(i, true);
refDet.setoccB(i, true);
ref[0].push_back(i);
ref[1].push_back(i);
}
VectorXi sizes = VectorXi::Zero(10);
int numDets = 0;
Expand Down

0 comments on commit a4aeb96

Please sign in to comment.