33 :
MPIObjectBase(c), curH(0), ptcl_pool_(pset_pool), psi_pool_(psi_pool), curDoc(0)
41 PoolType::iterator it(
myPool.begin());
52 std::string id(
"h0"), target(
"e"), role(
"extra");
54 hAttrib.
add(
id,
"id");
55 hAttrib.
add(
id,
"name");
56 hAttrib.
add(role,
"role");
57 hAttrib.
add(target,
"target");
63 PRE.
error(
"No target particle " + target +
" exists.");
66 bool set2Primary =
false;
68 if (
myPool.empty() || role ==
"primary")
71 PoolType::iterator hit(
myPool.find(
id));
80 bool success =
curH->put(cur);
88 for(
auto& [name, factory] :
myPool)
90 os <<
" Hamiltonian " << name << std::endl;
91 factory->getH()->get(os);
QMCHamiltonian * primaryH
pointer to the primary QMCHamiltonian
Base class for any object which needs to know about a MPI communicator.
helper functions for EinsplineSetBuilder
HamiltonianPool(ParticleSetPool &pset_pool, WaveFunctionPool &psi_pool, Communicate *c, const char *aname="hamiltonian")
bool put(xmlNodePtr cur)
assign attributes to the set
std::string myName
name of the object
Wrapping information on parallelism.
bool get(std::ostream &os) const
Specialized paritlce class for atomistic simulations.
WaveFunctionPool & psi_pool_
pointer to WaveFunctionPool
ParticleSet * getParticleSet(const std::string &pname)
get a named ParticleSet
Final class and should not be derived.
Communicate * myComm
pointer to Communicate
Declaration of WaveFunctionPool.
class to handle a set of attributes of an xmlNode
declaration of ProgressReportEngine
Factory class to build a many-body wavefunction.
Manage a collection of ParticleSet objects.
ParticleSetPool & ptcl_pool_
pointer to ParticleSetPool
std::string ClassName
class Name
QMCHamiltonian * curH
pointer to a current QMCHamiltonian to be built.
Declaration of HamiltonianPool.
void error(const std::string &msg, bool fatal=false)
const PoolType & getPool() const
get the Pool object
void add(PDT &aparam, const std::string &aname, std::vector< PDT > candidate_values={}, TagStatus status=TagStatus::OPTIONAL)
add a new attribute
PoolType myPool
storage for HamiltonianFactory
Manage a collection of TrialWaveFunction objects.
Declaration of ParticleSetPool.