38namespace Integrators {
61 context()->parallel_try_catch([&]() {
62 m_instance = std::make_shared<::NptIsoParameters>(
ext_pressure, piston,
63 direction, cubic_box);
68 context()->parallel_try_catch(
69 [
this]() { m_instance->coulomb_dipole_sanity_checks(get_system()); });
70 get_system().
nptiso = m_instance;
71 if (m_barostat ==
"Andersen") {
73 }
else if (m_barostat ==
"MTK") {
76 throw std::invalid_argument(
77 "Parameter 'barostat' must be 'Andersen' or 'MTK'.");
@ INTEG_METHOD_NPT_ISO_AND
@ INTEG_METHOD_NPT_ISO_MTK
Vector implementation and trait types for boost qvm interoperability.
void add_parameters(std::vector< AutoParameter > &¶ms)
void do_construct(VariantMap const ¶ms) override
::NptIsoParameters const & get_instance() const
void on_thermostat_param_change()
std::shared_ptr< NptIsoParameters > nptiso
std::shared_ptr< Propagation > propagation
static DEVICE_QUALIFIER constexpr Vector< T, N > broadcast(typename Base::value_type const &value) noexcept
Create a vector that has all entries set to the same value.
T get_value(Variant const &v)
Extract value of specific type T from a Variant.
std::unordered_map< std::string, Variant > VariantMap
Exports for the NpT code.
static SteepestDescentParameters params
Currently active steepest descent instance.
double p_ext
desired pressure to which the algorithm strives to
bool cubic_box
Set this flag if you want all box dimensions to be identical.
Utils::Vector< bool, 3 > get_direction() const
double piston
mass of a virtual piston representing the shaken box
static constexpr const ReadOnly read_only