46 std::vector<RealType>::iterator Vit =
values_.begin();
82 xmlNodePtr tcur = cur->children;
85 std::string cname((
const char*)tcur->name);
86 if (cname ==
"Observable")
88 std::string tagName(
"none");
93 Tattrib.
add(tagName,
"name");
94 Tattrib.
add(blockSeries,
"max");
95 Tattrib.
add(blockFreq,
"frequency");
97 if (tagName.find(
"*") == std::string::npos)
102 if (tagName ==
"LocalPotential")
104 Hindex = WP::LOCALPOTENTIAL;
107 else if (tagName ==
"LocalEnergy")
109 Hindex = WP::LOCALENERGY;
112 else if (Hindex == (WP::NUMPROPERTIES - 1))
114 app_log() <<
"Not a valid H element(" << Hindex <<
") Valid names are:";
120 names_.push_back(tagName);
122 app_log() <<
" Hamiltonian Element " << tagName <<
" was found at " << Hindex << std::endl;
123 int numT = blockSeries / blockFreq;
126 app_log() <<
" " << numT <<
" values will be calculated every " << blockFreq <<
"*tau H^-1" << std::endl;
127 std::vector<int> pms(3);
130 pms[2] = blockSeries + 2;
132 int maxWsize = blockSeries + 2;
140 int found = tagName.rfind(
"*");
141 tagName.replace(found, 1,
"");
146 if (Hname.find(tagName) != std::string::npos)
149 app_log() <<
" Hamiltonian Element " << Hname <<
" was found at " << j << std::endl;
151 Hindex = j + WP::NUMPROPERTIES;
153 int numT = blockSeries / blockFreq;
156 app_log() <<
" " << numT <<
" values will be calculated every " << blockFreq <<
"*tau H^-1" << std::endl;
157 std::vector<int> pms(3);
160 pms[2] = blockSeries + 2;
162 int maxWsize = blockSeries + 2;
174 app_log() <<
"Not a valid H element(" << Hindex <<
") Valid names are:";
185 app_log() <<
"Total number of values calculated:" <<
nvalues_ << std::endl;
192 os <<
"ForwardWalking";
199 return std::make_unique<ForwardWalking>(*this);
214 std::stringstream sstr;
216 int id = plist.
add(sstr.str());
std::vector< int > p_ids_
std::vector< int > PHindex
std::vector< RealType > values_
std::string getObservableName(int i) const
return the name of the i-th observable
~ForwardWalking() override
destructor
int startIndex() const
retrun the starting index
helper functions for EinsplineSetBuilder
std::vector< std::vector< FullPrecRealType > > PropertyHistory
Property history vector.
ForwardWalking()
constructor
int my_index_
starting index of this object
bool put(xmlNodePtr cur)
assign attributes to the set
bool putSpecial(xmlNodePtr cur, QMCHamiltonian &h, ParticleSet &P)
rename it to avoid conflicts with put
RealType getObservable(int i) const
return the value of the i-th observable
Collection of Local Energy Operators.
std::vector< T >::iterator begin()
iterators to use std algorithms
void setParticlePropertyList(PropertySetType &plist, int offset) override
Vectorized record engine for scalar properties.
std::vector< int > h_ids_
Return_t evaluate(ParticleSet &P) override
Evaluate the local energy contribution of this component.
PropertySetType PropertyList
name-value map of Walker Properties
bool get(std::ostream &os) const override
write about the class
void copy(const Array< T1, 3 > &src, Array< T2, 3 > &dest)
std::vector< std::string > Names
Specialized paritlce class for atomistic simulations.
int add(const std::string &aname)
class to handle a set of attributes of an xmlNode
int addPropertyHistory(int leng)
int sizeOfObservables() const
return the size of observables
#define APP_ABORT(msg)
Widely used but deprecated fatal error macros from legacy code.
Return_t calculate(ParticleSet &P)
Declarations of ForwardWalking.
Walker_t * t_walker_
reference to the current walker
std::unique_ptr< OperatorBase > makeClone(ParticleSet &qp, TrialWaveFunction &psi) final
void setObservables(PropertySetType &plist) override
Set the values evaluated by this object to plist Default implementation is to assign Value which is u...
std::vector< std::string > names_
FullPrecRealType Return_t
type of return value of evaluate
bool put(xmlNodePtr cur) override
Read the input parameter.
Class to represent a many-body trial wave function.
Return_t rejectedMove(ParticleSet &P) override
TODO: add docs.
Indexes
an enum denoting index of physical properties
Declaraton of ParticleAttrib<T>
FullPrecRealType * getPropertyBase()
void add(PDT &aparam, const std::string &aname, std::vector< PDT > candidate_values={}, TagStatus status=TagStatus::OPTIONAL)
add a new attribute
void addPropertyHistoryPoint(int index, FullPrecRealType data)
std::bitset< 8 > update_mode_
set the current update mode
Declaration of QMCHamiltonian.
std::vector< std::vector< int > > walker_lengths_
void addObservables(PropertySetType &plist)