69 dist = d_table.getDistRow(iat)[icent];
70 disp = -1.0 * d_table.getDisplRow(iat)[icent];
72 U[iat] += a * dist * dist;
73 G[iat] -= 2.0 * a * disp;
91 RealType newdist = d_table.getTempDists()[icent];
104 PosType newdisp = -1.0 * d_table.getTempDispls()[icent];
117 RealType newdist = d_table.getTempDists()[icent];
118 PosType newdisp = -1.0 * d_table.getTempDispls()[icent];
119 curVal = a * newdist * newdist;
151 dist = d_table.getDistRow(iat)[icent];
152 disp = -1.0 * d_table.getDisplRow(iat)[icent];
154 U[iat] += a * dist * dist;
155 dU[iat] -= 2.0 * a * disp;
157 dG[iat] -= 2.0 * a * disp;
176 bool fromscratch =
false)
200 auto j1copy = std::make_unique<LatticeGaussianProduct>(
CenterRef, tqp);
void resize(size_type n, Type_t val=Type_t())
Resize the container.
ParticleSet & CenterRef
orbital centers
void evaluateLogAndStore(const ParticleSet &P, ParticleSet::ParticleGradient &dG, ParticleSet::ParticleLaplacian &dL)
std::unique_ptr< WaveFunctionComponent > makeClone(ParticleSet &tqp) const override
make clone
WaveFunctionComponent::PsiValue PsiValue
helper functions for EinsplineSetBuilder
QTBase::GradType GradType
void registerData(ParticleSet &P, WFBufferType &buf) override
equivalent to evalaute with additional data management
LatticeGaussianProduct(ParticleSet ¢ers, ParticleSet &ptcls)
void restore(int iat) override
If a move for iat-th particle is rejected, restore to the content.
PsiValue ratioGrad(ParticleSet &P, int iat, GradType &grad_iat) override
evaluate the ratio of the new to old WaveFunctionComponent value and the new gradient ...
size_t getTotalNum() const
ParticleAttrib< RealType > U
LatticeGaussianProduct::GradType GradType
Attaches a unit to a Vector for IO.
ParticleLaplacian L
laplacians of the particles
std::complex< QTFull::RealType > LogValue
const DistanceTableAB & getDistTableAB(int table_ID) const
get a distance table by table_ID and dyanmic_cast to DistanceTableAB
int addTable(const ParticleSet &psrc, DTModes modes=DTModes::ALL_OFF)
add a distance table
Specialized paritlce class for atomistic simulations.
PsiValue ratio(ParticleSet &P, int iat) override
evaluate the ratio
ParticleAttrib< PosType > dU
QTBase::ValueType ValueType
void copyFromBuffer(ParticleSet &P, WFBufferType &buf) override
copy the current data from a buffer
RealType * LastAddressOfdU
ParticleGradient G
gradients of the particles
LogValue updateBuffer(ParticleSet &P, WFBufferType &buf, bool fromscratch) override
For particle-by-particle move.
LogValue evaluateLog(const ParticleSet &P, ParticleSet::ParticleGradient &G, ParticleSet::ParticleLaplacian &L) override
MakeReturn< UnaryNode< FnExp, typename CreateLeaf< Vector< T1, C1 > >::Leaf_t > >::Expression_t exp(const Vector< T1, C1 > &l)
QTFull::ValueType PsiValue
LogValue log_value_
Current .
RealType * FirstAddressOfdU
std::vector< int > ParticleCenter
std::vector< RealType > ParticleAlpha
GradType evalGrad(ParticleSet &P, int iat) override
return the current gradient for the iat-th particle
LatticeGaussianProduct::ValueType ValueType
Simple gaussian functions used for orbitals for ions.
ParticleAttrib< RealType > d2U
void acceptMove(ParticleSet &P, int iat, bool safe_to_delay=false) override
a move for iat-th particle is accepted.
~LatticeGaussianProduct() override
void put(std::complex< T1 > &x)
void add(std::complex< T1 > &x)
void get(std::complex< T1 > &x)