1 #ifndef CASM_MonteIO_HH
2 #define CASM_MonteIO_HH
4 #include <boost/filesystem/path.hpp>
14 template <
typename ValueType,
typename DataObject>
15 class GenericDatumFormatter;
16 template <
typename DataObject>
93 return conditions_dir(cond_index) /
"initial_state_firstruneq.json";
137 std::string prop_name);
141 std::string prop_name);
156 std::string prop_name1, std::string prop_name2);
168 template <
typename MonteType>
172 template <
typename MonteType>
176 template <
typename MonteType>
181 template <
typename MonteType>
183 const MonteType &mc,
int index);
186 template <
typename MonteType>
188 const MonteType &mc,
int index);
191 template <
typename MonteType>
193 const MonteType &mc,
int index);
196 template <
typename MonteType>
201 template <
typename MonteType>
203 std::string comp_var_i, std::string comp_var_j);
206 template <
typename MonteType>
208 std::string species_i, std::string species_j);
211 template <
typename MonteType>
216 template <
typename MonteType>
255 template <
typename MonteType>
260 template <
typename MonteType>
fs::path POSCAR_final(int cond_index)
"output_dir/conditions.cond_index/trajectory/POSCAR.final"
fs::path initial_state_json(int cond_index) const
"output_dir/conditions.cond_index/initial_state.json"
fs::path final_state_json(int cond_index) const
"output_dir/conditions.cond_index/final_state.json"
fs::path output_dir() const
"output_dir/"
fs::path trajectory_dir(int cond_index) const
"output_dir/conditions.cond_index/trajectory"
fs::path results_csv() const
Results summary: "output_dir/results.csv".
fs::path occupation_key_json() const
"output_dir/occupation_key.csv"
fs::path POSCAR_initial(int cond_index)
"output_dir/conditions.cond_index/trajectory/POSCAR.initial"
fs::path results_json() const
Results summary: "output_dir/results.json".
fs::path observations_csv(int cond_index) const
"output_dir/conditions.cond_index/observations.csv"
fs::path initial_state_firstruneq_json(int cond_index) const
"output_dir/conditions.cond_index/initial_state_firstruneq.json"
fs::path trajectory_csv(int cond_index) const
"output_dir/conditions.cond_index/trajectory.csv"
fs::path initial_state_runeq_json(int cond_index) const
"output_dir/conditions.cond_index/final_state.json"
fs::path conditions_json(int cond_index) const
"output_dir/conditions.cond_index/conditions.json"
fs::path trajectory_json(int cond_index) const
"output_dir/conditions.cond_index/trajectory.json"
fs::path occupation_key_csv() const
"output_dir/occupation_key.csv"
fs::path POSCAR_snapshot(int cond_index, size_type sample_index)
"output_dir/conditions.cond_index/trajectory/POSCAR.sample"
MonteCarloDirectoryStructure(fs::path output_dir)
fs::path observations_json(int cond_index) const
"output_dir/conditions.cond_index/observations.json"
fs::path conditions_dir(int cond_index) const
"output_dir/conditions.cond_index/"
Interface base class for all types of Monte Carlo simulations (not meant to be used polymorphically)
Settings for Monte Carlo calculations.
std::string to_string(ENUM val)
Return string representation of enum class.
GenericDatumFormatter< double, std::pair< ConstMonteCarloPtr, size_type > > MonteCarloObservationFormatter(std::string prop_name)
Print value of observation.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloPrecFormatter(std::string prop_name)
Print calculated precision of property values: prec(<prop_name>)
void write_observations(const MonteSettings &settings, const MonteCarlo &mc, size_type cond_index, Log &_log)
Will create (and possibly overwrite) new file with all observations from run with conditions....
void write_POSCAR_initial(const MonteCarlo &mc, size_type cond_index, Log &_log)
For the initial state, write a POSCAR file.
const MonteCarlo * ConstMonteCarloPtr
const pointer to const MonteCarlo
GenericDatumFormatter< size_type, std::pair< ConstMonteCarloPtr, size_type > > MonteCarloStepFormatter()
Print Step number of observation.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloSuscXFormatter(std::string comp_var_i, std::string comp_var_j)
Print parametric susceptibility, 'susc_x(a,b)'.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloParamChemPotFormatter(const MonteType &mc, int index)
Print param_chem_pot(x)
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloChemPotFormatter(const MonteType &mc, int index)
Print chem_pot(N)
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloTFormatter()
Print Temperature.
void write_POSCAR_final(const MonteCarlo &mc, size_type cond_index, Log &_log)
For the final state, write a POSCAR file.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloMeanFormatter(std::string prop_name)
Print mean property values: <prop_name>
DataFormatter< std::pair< ConstMonteCarloPtr, size_type > > make_observation_formatter(const MonteCarlo &mc)
Make a observation formatter.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloThermoChemSuscNFormatter(std::string species_i)
Print thermo-chemical susceptibility, 'susc_n(S,A)'.
GenericDatumFormatter< size_type, ConstMonteCarloPtr > MonteCarloNAvgSamplesFormatter()
Print number of samples used in calculating means.
GenericDatumFormatter< bool, ConstMonteCarloPtr > MonteCarloIsConvergedFormatter()
Print if converged.
void write_trajectory(const MonteSettings &settings, const MonteCarlo &mc, size_type cond_index, Log &_log)
Will create (and possibly overwrite) new file with all observations from run with conditions....
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloSuscNFormatter(std::string species_i, std::string species_j)
Print susceptibility, 'susc_n(A,B)'.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloBetaFormatter()
Print Beta.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloThermoChemSuscXFormatter(std::string comp_var_i)
Print parametric thermo-chemical susceptibility, 'susc_x(S,a)'.
GenericDatumFormatter< int, std::pair< ConstMonteCarloPtr, size_type > > MonteCarloOccFormatter(size_type occ_index)
Print value of a particular occupation variable.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloCompNFormatter(const MonteType &mc, int index)
Print comp_n(N)
void write_results(const MonteSettings &settings, const MonteType &mc, Log &_log)
Will create new file or append to existing file results of the latest run.
void write_conditions_json(const MonteSettings &settings, const MonteType &mc, size_type cond_index, Log &_log)
Write conditions to conditions.cond_index directory.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloHeatCapacityFormatter()
Print heat capacity, 'heat_capacity'.
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloCovFormatter(std::string prop_name1, std::string prop_name2)
Print covariance: cov(prop_name1, prop_name2)
GenericDatumFormatter< bool, ConstMonteCarloPtr > MonteCarloIsEquilibratedFormatter()
Print if equilibrated (not counting explicitly requested equilibration)
GenericDatumFormatter< double, ConstMonteCarloPtr > MonteCarloCompFormatter(const MonteType &mc, int index)
Print comp(x)
GenericDatumFormatter< size_type, ConstMonteCarloPtr > MonteCarloNEquilSamplesFormatter()
Print number of samples used for equilibration (not counting explicitly requested equilibration)
void write_POSCAR_trajectory(const MonteCarlo &mc, size_type cond_index, Log &_log)
For every snapshot taken, write a POSCAR file.
GenericDatumFormatter< size_type, std::pair< ConstMonteCarloPtr, size_type > > MonteCarloPassFormatter()
Print Pass number of observation.
DataFormatter< std::pair< ConstMonteCarloPtr, size_type > > make_trajectory_formatter(const MonteCarlo &mc)
Make a trajectory formatter.
Functor to help evaluate covariance.
double operator()(const ConstMonteCarloPtr &mc)
CovEvaluator(std::string _prop_name1, std::string _prop_name2)