namespace gpr::potentials¶
Overview¶
namespace potentials {
// global variables
double MULLER_BROWN_MINIMA[3][2] = { {-0.558224, 1.441726}, {0.623499, 0.028038}, {-0.050011, 0.466694}, };
double MULLER_BROWN_SADDLES[2][2] = { {-0.822002, 0.624313}, {0.212487, 0.292988}, };
double LEPS_REACTANT[2] = {0.742, 4.0};
double LEPS_PRODUCT[2] = {4.0, 0.742};
double LEPS_SADDLE[2] = {0.929, 0.929};
// global functions
std::pair<double, std::vector<double>> lj_energy_gradient(const std::vector<double>& x, double epsilon = 1.0, double sigma = 1.0);
std::pair<double, std::vector<double>> muller_brown_energy_gradient(const std::vector<double>& xy);
std::pair<double, std::vector<double>> leps_energy_gradient(const std::vector<double>& r);
} // namespace potentials
Detailed Documentation¶
Global Functions¶
std::pair<double, std::vector<double>> lj_energy_gradient(const std::vector<double>& x, double epsilon = 1.0, double sigma = 1.0)
Lennard-Jones energy and gradient for N atoms in 3D.
Parameters:
x |
Flat coordinate vector [x1,y1,z1,x2,y2,z2,…], size 3*N |
epsilon |
LJ well depth |
sigma |
LJ zero-crossing distance |
Returns:
(energy, gradient) pair
std::pair<double, std::vector<double>> muller_brown_energy_gradient(const std::vector<double>& xy)
Muller-Brown 2D potential.
Three minima and two saddle points on a 2D surface. Classic benchmark for NEB and dimer methods.
Parameters:
xy |
2-element vector [x, y] |
Returns:
(energy, gradient) pair
std::pair<double, std::vector<double>> leps_energy_gradient(const std::vector<double>& r)
LEPS (London-Eyring-Polanyi-Sato) potential for collinear A+BC.
2D potential in (r_AB, r_BC) coordinates for the collinear reaction A + BC -> AB + C. Classic benchmark for NEB and dimer methods.
Parameters:
r |
2-element vector [r_AB, r_BC] |
Returns:
(energy, gradient) pair