2#ifndef STORMM_NML_REMD_H
3#define STORMM_NML_REMD_H
6#include "Constants/behavior.h"
7#include "Constants/symbol_values.h"
8#include "Parsing/textfile.h"
9#include "Potential/energy_enumerators.h"
10#include "Structure/structure_enumerators.h"
11#include "Trajectory/trajectory_enumerators.h"
13#include "namelist_emulator.h"
18using constants:: CartesianDimension;
19using constants::PrecisionModel;
20using constants::ExceptionResponse;
22using parse::WrapTextSearch;
23using structure::ApplyConstraints;
25constexpr int default_total_swaps = 0;
26constexpr char default_remd_type[] =
"Temperature";
27constexpr int default_freq_swaps = 500;
28constexpr char default_swap_store[] =
"Successful";
29constexpr char default_temp_distribution[] =
"Van Der Spoel";
30constexpr double default_exchange_probability = 0.2;
31constexpr double default_tolerance = 0.00001;
32constexpr int default_max_replicas = 1000;
33constexpr double default_low_temperature = 298.15;
34constexpr double default_high_temperature = 398.15;
51 RemdControls(ExceptionResponse policy_in = ExceptionResponse::DIE);
54 ExceptionResponse policy_in = ExceptionResponse::DIE,
55 WrapTextSearch wrap = WrapTextSearch::NO);
155 ExceptionResponse policy;
156 int total_swap_count;
157 std::string remd_type;
159 std::string swap_store;
161 std::string temperature_dist;
163 double exchange_probability;
171 double low_temperature;
175 double high_temperature;
182 void validateSwapCount();
185 void validateRemdKind();
188 void validateFreqOrTotalSwaps();
191 void validateSwapFrequency();
194 void validateSwapStore();
199 void validateTemperature();
202 void validateTemperatureDistribution();
205 void validateExchangeProbability();
208 void validateTolerance();
211 void validateMaxReplicas();
224 ExceptionResponse policy = ExceptionResponse::DIE,
225 WrapTextSearch wrap = WrapTextSearch::NO);
Collection of variables to transcribe information contained within a namelist.
Definition namelist_emulator.h:30
const NamelistEmulator & getTranscript() const
Get the original namelist emulator object as a transcript of the user input.
Definition nml_remd.cpp:117
std::string getSwapStore() const
Get the string encoding for the method of storage to use for swaps TODO: Storage methods need to be r...
Definition nml_remd.cpp:82
void setTotalSwapCount(int total_swap_count_in)
Set the total number of swaps to be performed in a REMD simulation.
Definition nml_remd.cpp:122
double getLowTemperature() const
Get the vector of initial temperature targets for all groups of atoms and systems.
Definition nml_remd.cpp:107
int getFrequencyOfSwaps() const
Get the frequency of steps to perform before a swap is attempted.
Definition nml_remd.cpp:77
void setRemdType(std::string remd_type_in)
Set the REMD Type: 1) Temperature, or 2) Hamiltonian.
Definition nml_remd.cpp:127
double getTolerance() const
Get the tolerance set between desired exchange probability and predicted probability.
Definition nml_remd.cpp:97
RemdControls(ExceptionResponse policy_in=ExceptionResponse::DIE)
The Constructors can prepare an object with default settings or read the corresponding namelist to ac...
Definition nml_remd.cpp:21
std::string getRemdType() const
Get the type of REMD to be performed in this simulation.
Definition nml_remd.cpp:72
void setLowTemperature(double low_temperature_in)
Set the initial temperature for the REMD simulation.
Definition nml_remd.cpp:162
void setTemperatureDistributionMethod(std::string temperature_dist_in)
Set the algorithm to be used to calculate the temperature distribution.
Definition nml_remd.cpp:142
void setSwapStore(std::string swap_store_in)
Set the amount of data to be stored for swap history.
Definition nml_remd.cpp:137
double getHighTemperature() const
Get the vector of final temperature targets for all groups of atoms and systems.
Definition nml_remd.cpp:112
int getMaxReplicas() const
Get the user input for Maximum Replicas allowed.
Definition nml_remd.cpp:102
std::string getTemperatureDistributionMethod() const
Get the string encoding for the type of temperature distribution in use TODO: This needs to be revisi...
Definition nml_remd.cpp:87
void setFrequencyOfSwaps(int frequency_swaps_in)
Set the frequency of steps to take before performing a swap.
Definition nml_remd.cpp:132
int getTotalSwapCount() const
Getters for the REMD Namelist.
Definition nml_remd.cpp:67
void setTolerance(double tolerance_in)
Set the tolerance between desired probability and poredicted probability.
Definition nml_remd.cpp:152
double getExchangeProbability() const
Get the user input Exchange Probability between 2 adjacent replicas.
Definition nml_remd.cpp:92
void setHighTemperature(double high_temperature_in)
Set the equilibrium temperature for the REMD simulation.
Definition nml_remd.cpp:167
RemdControls(const RemdControls &original)=default
Copy and Move Constructors, inspired from nml_mesh.h.
void setMaxReplicas(int max_replicas_in)
Set the maximum number of replicas the REMD algorithm is allowed to create.
Definition nml_remd.cpp:157
void setExchangeProbability(double exchange_probability_in)
Set the exchange probability between two adjacent replicas in REMD.
Definition nml_remd.cpp:147
Structure for translating a text file into a compact, rapidly parsable vector of characters in CPU RA...
Definition textfile.h:45