16 #ifndef QMCPLUSPLUS_BACKFLOW_ELEC_ION_H    17 #define QMCPLUSPLUS_BACKFLOW_ELEC_ION_H    64     for (
int i = 0; i < 
RadFun.size(); i++)
    71           clone->RadFun[i] = 
clone->uniqueRadFun[k].get();
    76         APP_ABORT(
"Error cloning Backflow_eI object. \n");
    84     std::cerr << 
RadFun.size() << std::endl;
   129       for (
int i = 0; i < num; i++)
   134       for (
int i = 0; i < num; i++)
   137       for (
int i = 0; i < num; i++)
   142       for (
int i = 0; i < num; i++)
   145       for (
int i = 0; i < num; i++)
   148       for (
int i = 0; i < num; i++)
   153       for (
int i = 0; i < num; i++)
   156       for (
int i = 0; i < num; i++)
   159       for (
int i = 0; i < num; i++)
   168   inline void restore(
int iat, 
int UpdateType)
 override   192     APP_ABORT(
"Backflow_eI.h::evaluate(P,QP) not implemented for SoA\n");
   209     APP_ABORT(
"Backflow_eI.h::evaluate(P,QP,Bmat_vec,Amat) not implemented for SoA\n");
   243       const auto& displ = myTable.getDisplRow(jel);
   250           QP.
R[jel] += (
UIJ(jel, iat) = -uij * displ[iat]);
   256           Amat(jel, jel) += hess;
   259           Bmat_full(jel, jel) += (
BIJ(jel, iat) = -(d2u + 4.0 * du) * displ[iat]);
   269                            const std::vector<int>& index)
 override   271     APP_ABORT(
"Backflow_eI.h::evaluatePbyP(P,QP,index_vec) not implemented for SoA\n");
   292     for (
int j = 0; j < maxI; j++)
   294       RealType uij = 
RadFun[j]->evaluate(myTable.getTempDists()[j], du, d2u);
   302                            const std::vector<int>& index,
   305     APP_ABORT(
"Backflow_eI.h::evaluatePbyP(P,QP,index_vec,Amat) not implemented for SoA\n");
   330     for (
int j = 0; j < maxI; j++)
   332       if (myTable.getTempDists()[j] > 0)
   334         RealType uij = 
RadFun[j]->evaluate(myTable.getTempDists()[j], du, d2u);
   338         hess = (du / myTable.getTempDists()[j]) * 
outerProduct(myTable.getTempDispls()[j], myTable.getTempDispls()[j]);
   343         Amat(iat, iat) += (hess - 
AIJ(iat, j));
   350                            const std::vector<int>& index,
   354     APP_ABORT(
"Backflow_eI.h::evaluatePbyP(P,QP,index_vec,Bmat,Amat) not implemented for SoA\n");
   382     APP_ABORT(
"Backflow_eI.h::evaluatePbyP(P,iat,QP,Bmat,Amat) not implemented for SoA\n");
   408     APP_ABORT(
"Backflow_eI.h::evaluateBmatOnly(P,QP,Bmat) not implemented for SoA\n");
   438       const auto& displ = myTable.getDisplRow(jel);
   444           int NPrms    = 
RadFun[iat]->NumParams;
   445           std::vector<TinyVector<RealType, 3>> derivsju(NPrms);
   446           RadFun[iat]->evaluateDerivatives(dist[iat], derivsju);
   448           QP.
R[jel] += (
UIJ(jel, iat) = -uij * displ[iat]);
   455           Amat(jel, jel) += hess;
   456           Bmat_full(jel, jel) += (
BIJ(jel, iat) = -(d2u + 4.0 * du) * displ[iat]);
   459             Cmat(la, jel) -= displ[iat] * derivsju[prm][0];
   460             Xmat(la, jel, jel) += (derivsju[prm][1] / dist[iat]) * op;
   461             Xmat(la, jel, jel)[0] += derivsju[prm][0];
   462             Xmat(la, jel, jel)[4] += derivsju[prm][0];
   463             Xmat(la, jel, jel)[8] += derivsju[prm][0];
   464             Ymat(la, jel) -= (derivsju[prm][2] + 4.0 * derivsju[prm][1] / dist[iat]) * displ[iat];
 
int NumTargets
number of quantum particles 
 
void evaluatePbyP(const ParticleSet &P, ParticleSet::ParticlePos &newQP, const std::vector< int > &index) override
calculate quasi-particle coordinates after pbyp move 
 
helper functions for EinsplineSetBuilder 
 
Backflow_eI(ParticleSet &ions, ParticleSet &els, FT *RF)
 
const DistRow & getDistRow(int iel) const
return a row of distances for a given target particle 
 
size_t getTotalNum() const
 
std::vector< int > offsetPrms
 
void resetParameters(const opt_variables_type &active) override
 
std::unique_ptr< BackflowFunctionBase > makeClone(ParticleSet &tqp) const override
 
Base class for backflow transformations. 
 
void evaluateBmatOnly(const ParticleSet &P, GradMatrix &Bmat_full) override
calculate only Bmat This is used in pbyp moves, in updateBuffer() 
 
bool isOptimizable() override
 
void evaluate(const ParticleSet &P, ParticleSet &QP) override
calculate quasi-particle coordinates only 
 
void evaluatePbyP(const ParticleSet &P, int iat, ParticleSet::ParticlePos &newQP, HessMatrix &Amat) override
calculate quasi-particle coordinates and Amat after pbyp move 
 
Attaches a unit to a Vector for IO. 
 
int indexOffset() override
 
void evaluate(const ParticleSet &P, ParticleSet &QP, GradMatrix &Bmat_full, HessMatrix &Amat) override
calculate quasi-particle coordinates, Bmat and Amat 
 
void evaluatePbyP(const ParticleSet &P, int iat, ParticleSet::ParticlePos &newQP, GradMatrix &Bmat_full, HessMatrix &Amat) override
calculate quasi-particle coordinates, Bmat and Amat after pbyp move 
 
int NumCenters
number of centers, e.g., ions 
 
void acceptMove(int iat, int UpdateMode) override
 
const DistanceTableAB & getDistTableAB(int table_ID) const
get a distance table by table_ID and dyanmic_cast to DistanceTableAB 
 
Specialized paritlce class for atomistic simulations. 
 
void checkOutVariables(const opt_variables_type &active) override
 
void registerData(WFBufferType &buf) override
 
Tensor< typename BinaryReturn< T1, T2, OpMultiply >::Type_t, D > outerProduct(const TinyVector< T1, D > &lhs, const TinyVector< T2, D > &rhs)
 
class to handle a set of variables that can be modified during optimizations 
 
void reportStatus(std::ostream &os) override
 
#define APP_ABORT(msg)
Widely used but deprecated fatal error macros from legacy code. 
 
std::vector< FT * > RadFun
 
Backflow_eI(ParticleSet &ions, ParticleSet &els)
 
ParticleSet & CenterSys
Reference to the center. 
 
size_t sources() const
returns the number of source particles 
 
void checkInVariables(opt_variables_type &active) override
 
const int myTableIndex_
distance table index 
 
void evaluatePbyP(const ParticleSet &P, int iat, ParticleSet::ParticlePos &newQP) override
calculate quasi-particle coordinates after pbyp move 
 
void restore(int iat, int UpdateType) override
 
void evaluateWithDerivatives(const ParticleSet &P, ParticleSet &QP, GradMatrix &Bmat_full, HessMatrix &Amat, GradMatrix &Cmat, GradMatrix &Ymat, HessArray &Xmat) override
calculate quasi-particle coordinates, Bmat and Amat calculate derivatives wrt to variational paramete...
 
void evaluatePbyP(const ParticleSet &P, ParticleSet::ParticlePos &newQP, const std::vector< int > &index, GradMatrix &Bmat_full, HessMatrix &Amat) override
calculate quasi-particle coordinates, Bmat and Amat after pbyp move 
 
std::vector< TinyVector< RealType, 3 > > derivs
 
void evaluate(const ParticleSet &P, ParticleSet &QP, GradVector &Bmat, HessMatrix &Amat)
 
void resize(int NT, int NC)
 
Vector< PosType > UIJ_temp
 
std::vector< std::unique_ptr< FT > > uniqueRadFun
 
void add(std::complex< T1 > &x)
 
void evaluatePbyP(const ParticleSet &P, ParticleSet::ParticlePos &newQP, const std::vector< int > &index, HessMatrix &Amat) override
calculate quasi-particle coordinates and Amat after pbyp move