47 static constexpr int num = 1;
62inline std::optional<Utils::Vector3d>
64 auto const dist = dx.
norm();
70 auto const dr = dist -
r;
77 "This is most likely an error in the system setup.";
86inline std::optional<double>
88 auto const dist = dx.
norm();
Vector implementation and trait types for boost qvm interoperability.
This file contains the defaults for ESPResSo.
#define ROUND_ERROR_PREC
Precision for capture of round off errors.
This file contains the errorhandling code for severe errors, like a broken bond or illegal parameter ...
#define runtimeErrorMsg()
DEVICE_QUALIFIER constexpr T sqr(T x)
Calculates the SQuaRe of x.
Parameters for harmonic bond Potential.
std::optional< Utils::Vector3d > force(Utils::Vector3d const &dx) const
Compute the harmonic bond force.
std::optional< double > energy(Utils::Vector3d const &dx) const
Compute the harmonic bond energy.
double r
equilibrium bond length
double r_cut
cutoff length
HarmonicBond(double k, double r, double r_cut)