Skip to content
6 changes: 3 additions & 3 deletions src/QMCHamiltonians/EwaldRef.h
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ real_t madelungSum(const RealMat& a, real_t tol = 1e-10)
real_t kconst = -1. / (4 * std::pow(kconv, 2));
real_t kfactor = 4 * M_PI / volume;

// Create real-/k-space fuctors for terms within the sums in formula 7
// Create real-/k-space functors for terms within the sums in formula 7
RspaceMadelungTerm rfunc(a, rconst);
KspaceMadelungTerm kfunc(b, kconst, kfactor);

Expand Down Expand Up @@ -340,7 +340,7 @@ real_t ewaldSum(const RealVec& r, const RealMat& a, real_t tol = 1e-10)
real_t kconst = -std::pow(kconv, 2) / 2;
real_t kfactor = 4 * M_PI / volume;

// Create real-/k-space fuctors for terms within the sums in formula 6
// Create real-/k-space functors for terms within the sums in formula 6
RspaceEwaldTerm rfunc(r, a, rconst);
KspaceEwaldTerm kfunc(r, b, kconst, kfactor);

Expand Down Expand Up @@ -416,7 +416,7 @@ real_t ewaldEnergy(const RealMat& a, const PosArray& R, const ChargeArray& Q, re

#pragma omp parallel for reduction(+ : ve)
for(size_t n=0; n<Npairs; ++n)
ve += qq[n]*ewaldSum(rr[n],a,tol/qq[n]);
ve += qq[n]*ewaldSum(rr[n],a,tol/qq[n]/Npairs);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If possible, please run clang-format on both files.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not time efficient. I'm waiting for the automatic part of #794 to be implemented.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The automatic part has been implemented; see https://github.com/QMCPACK/qmcpack/wiki/Source-formatting

This was a decision made as a project to not have a robot do formatting without supervision, but to provide various methods for different workflow preferences that everyone can choose for themselves, from assisted manual to full automatic.

}

return ve;
Expand Down
Loading