#include <colvarcomp.h>
Inheritance diagram for colvar::h_bond:
Public Methods | |||
h_bond (std::string const &conf) | |||
h_bond (cvm::atom const &acceptor, cvm::atom const &donor, cvm::real r0, int en, int ed) | |||
Constructor for atoms already allocated. More... | |||
h_bond () | |||
virtual | ~h_bond () | ||
virtual void | calc_value () | ||
\brief Calculate the variable. More... | |||
virtual void | calc_gradients () | ||
\brief Calculate the atomic gradients, to be reused later in order to apply forces. More... | |||
virtual void | apply_force (colvarvalue const &force) | ||
\brief Apply the collective variable force, by communicating the atomic forces to the simulation program (Note: the ft member is not altered by this function) Note: multiple calls to this function within the same simulation step will add the forces altogether
| |||
virtual cvm::real | dist2 (colvarvalue const &x1, colvarvalue const &x2) const | ||
\brief Square distance between x1 and x2 (can be redefined to transparently implement constraints, symmetries and periodicities) colvar::cvc::dist2() and the related functions are declared as "const" functions, but not "static", because additional parameters defining the metrics (e.g. the periodicity) may be specific to each colvar::cvc object. If symmetries or periodicities are present, the colvar::cvc::dist2() should be redefined to return the "closest distance" value and colvar::cvc::dist2_lgrad(), colvar::cvc::dist2_rgrad() to return its gradients. If constraints are present (and not already implemented by any of the colvarvalue types), the colvar::cvc::dist2_lgrad() and colvar::cvc::dist2_rgrad() functions should be redefined to provide a gradient which is compatible with the constraint, i.e. already deprived of its component normal to the constraint hypersurface. Finally, another useful application, if you are performing very many operations with these functions, could be to override the colvarvalue member functions and access directly its member data. For instance: to define dist2(x1,x2) as (x2.real_value-x1.real_value)*(x2.real_value-x1.real_value) in case of a scalar colvarvalue type. More... | |||
virtual colvarvalue | dist2_lgrad (colvarvalue const &x1, colvarvalue const &x2) const | ||
\brief Gradient(with respect to x1) of the square distance (can be redefined to transparently implement constraints, symmetries and periodicities). More... | |||
virtual colvarvalue | dist2_rgrad (colvarvalue const &x1, colvarvalue const &x2) const | ||
\brief Gradient(with respect to x2) of the square distance (can be redefined to transparently implement constraints, symmetries and periodicities). More... | |||
Protected Attributes | |||
cvm::real | r0 | ||
\brief "Cutoff" distance between acceptor and donor. More... | |||
int | en | ||
Integer exponent of the function numerator. More... | |||
int | ed | ||
Integer exponent of the function denominator. More... |
Definition at line 1054 of file colvarcomp.h.
|
|
|
Constructor for atoms already allocated.
Definition at line 350 of file colvarcomp_coordnums.C. References colvar::cvc::atom_groups, colvar::cvc::init_scalar_boundaries, colvar::cvc::register_atom_group, colvar::cvc::set_function_type, colvarvalue::type, colvarvalue::type_scalar, and colvar::cvc::x. |
|
|
|
Definition at line 1071 of file colvarcomp.h. |
|
\brief Apply the collective variable force, by communicating the atomic forces to the simulation program (Note: the ft member is not altered by this function) Note: multiple calls to this function within the same simulation step will add the forces altogether
Implements colvar::cvc. Definition at line 388 of file colvarcomp_coordnums.C. References colvar::cvc::atom_groups, and force. |
|
\brief Calculate the atomic gradients, to be reused later in order to apply forces.
Reimplemented from colvar::cvc. Definition at line 377 of file colvarcomp_coordnums.C. References colvar::cvc::atom_groups, ed, en, NULL, and r0. |
|
\brief Calculate the variable.
Implements colvar::cvc. Definition at line 365 of file colvarcomp_coordnums.C. References colvar::cvc::atom_groups, ed, en, NULL, r0, colvarvalue::real_value, and colvar::cvc::x. |
|
\brief Square distance between x1 and x2 (can be redefined to transparently implement constraints, symmetries and periodicities) colvar::cvc::dist2() and the related functions are declared as "const" functions, but not "static", because additional parameters defining the metrics (e.g. the periodicity) may be specific to each colvar::cvc object. If symmetries or periodicities are present, the colvar::cvc::dist2() should be redefined to return the "closest distance" value and colvar::cvc::dist2_lgrad(), colvar::cvc::dist2_rgrad() to return its gradients. If constraints are present (and not already implemented by any of the colvarvalue types), the colvar::cvc::dist2_lgrad() and colvar::cvc::dist2_rgrad() functions should be redefined to provide a gradient which is compatible with the constraint, i.e. already deprived of its component normal to the constraint hypersurface. Finally, another useful application, if you are performing very many operations with these functions, could be to override the colvarvalue member functions and access directly its member data. For instance: to define dist2(x1,x2) as (x2.real_value-x1.real_value)*(x2.real_value-x1.real_value) in case of a scalar colvarvalue type.
Reimplemented from colvar::cvc. |
|
\brief Gradient(with respect to x1) of the square distance (can be redefined to transparently implement constraints, symmetries and periodicities).
Reimplemented from colvar::cvc. |
|
\brief Gradient(with respect to x2) of the square distance (can be redefined to transparently implement constraints, symmetries and periodicities).
Reimplemented from colvar::cvc. |
|
Integer exponent of the function denominator.
Definition at line 1063 of file colvarcomp.h. Referenced by calc_gradients, and calc_value. |
|
Integer exponent of the function numerator.
Definition at line 1061 of file colvarcomp.h. Referenced by calc_gradients, and calc_value. |
|
\brief "Cutoff" distance between acceptor and donor.
Definition at line 1059 of file colvarcomp.h. Referenced by calc_gradients, and calc_value. |