|
PSCF v1.4.0
|
Analyze averages and block averages of several real variables. More...
#include <AverageListAnalyzer.h>
Public Member Functions | |
| AverageListAnalyzer (Simulator< D > &simulator, System< D > &system) | |
| Constructor. | |
| Public Member Functions inherited from Pscf::Rp::AverageListAnalyzer< D, Types< D > > | |
| AverageListAnalyzer (typename Types< D >::Simulator &simulator, typename Types< D >::System &system) | |
| Constructor. | |
| void | readParameters (std::istream &in) override |
| Read interval, outputFileName and (optionally) nSamplePerOutput. | |
| void | setup () override |
| Setup before loop. | |
| void | sample (long iStep) override |
| Compute sampled values and update the accumulators. | |
| void | output () override |
| Write final results to file after a simulation. | |
| int | nSamplePerOutput () const |
| Get value of nSamplePerOutput. | |
| int | nValue () const |
| Get the number of variables. | |
| const std::string & | name (int i) const |
| Get name associated with a variable. | |
| const Average & | accumulator (int i) const |
| Get Average accumulator for a specific variable. | |
Additional Inherited Members | |
| Protected Member Functions inherited from Pscf::Rp::AverageListAnalyzer< D, Types< D > > | |
| void | initializeAccumulators (int nValue) |
| Initialize Average accumulators and set nValue. | |
| void | clearAccumulators () |
| Clear internal state of all accumulators. | |
| void | setName (int i, std::string name) |
| Set name of variable. | |
| void | setValue (int i, double value) |
| Set current value, used by compute function. | |
| virtual void | compute ()=0 |
| Compute values of sampled quantities. | |
| double | value (int i) const |
| Get current value of a specific variable. | |
| void | updateAccumulators (long iStep) |
| Add current value to accumulator, output block average if needed. | |
| void | outputAccumulators () |
| Write results of statistical analysis to files. | |
| Protected Attributes inherited from Pscf::Rp::AverageListAnalyzer< D, Types< D > > | |
| std::ofstream | outputFile_ |
| Output file stream. | |
Analyze averages and block averages of several real variables.
This class evaluates averages of several sampled real variables, and optionally writes block averages to a data file during a simulation. It is intended for use as a base class for Analyzers that evaluate averages and (optionally) block averages for several physical variables.
Specializations of this template with D=1, 2, and 3 are derived from specializations of the base class template Rp::AverageListAnalyzer, and inherit their public interface and almost all of their source code from this base class.
Definition at line 41 of file /fts/analyzer/AverageListAnalyzer.h.
| Pscf::Rpg::AverageListAnalyzer< D >::AverageListAnalyzer | ( | Simulator< D > & | simulator, |
| System< D > & | system ) |
Constructor.
Definition at line 17 of file AverageListAnalyzer.cu.
References AverageListAnalyzer().
Referenced by AverageListAnalyzer().