Skip to content

Commit

Permalink
[pre-commit.ci lite] apply automatic fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
pre-commit-ci-lite[bot] authored Jul 11, 2024
1 parent 8a85bda commit 393c637
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
12 changes: 8 additions & 4 deletions source/module_hsolver/hsolver_lcaopw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,16 +123,20 @@ namespace hsolver
auto& exx_lip = dynamic_cast<hamilt::HamiltLIP<T>*>(pHamilt)->exx_lip;
auto add_exx_to_subspace_hamilt = [&ik, &exx_lip](T* hcc, const int naos) -> void
{
if (GlobalC::exx_info.info_global.cal_exx)
for (int n = 0; n < naos; ++n)
for (int m = 0; m < naos; ++m)
if (GlobalC::exx_info.info_global.cal_exx) {
for (int n = 0; n < naos; ++n) {
for (int m = 0; m < naos; ++m) {
hcc[n * naos + m] += (T)GlobalC::exx_info.info_global.hybrid_alpha *
exx_lip.get_exx_matrix()[ik][m][n];
}
}
}
};
auto set_exxlip_lcaowfc = [&ik, &exx_lip](const T* const vcc, const int naos, const int nbands) -> void
{
if (GlobalC::exx_info.info_global.cal_exx)
if (GlobalC::exx_info.info_global.cal_exx) {
exx_lip.set_hvec(ik, vcc, naos, nbands);
}
};
#endif
hsolver::DiagoIterAssist<T>::diagH_subspace_init(
Expand Down
3 changes: 2 additions & 1 deletion source/module_io/write_Vxc.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -304,8 +304,9 @@ void write_Vxc(int nspin,
// R (the number of hR: 1 for nspin=1, 4; 2 for nspin=2)
int nspin0 = (nspin == 2) ? 2 : 1;
std::vector<hamilt::HContainer<TR>> vxcs_R_ao(nspin0, hamilt::HContainer<TR>(pv));
for (int is = 0; is < nspin0; ++is)
for (int is = 0; is < nspin0; ++is) {
vxcs_R_ao[is].set_zero();
}
// k (size for each k-point)
hamilt::HS_Matrix_K<TK> vxc_k_ao(pv, 1); // only hk is needed, sk is skipped

Expand Down

0 comments on commit 393c637

Please sign in to comment.