Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

colvar::distance_dir Class Reference

\brief Colvar component: distance unit vector (direction) between centers of mass of two groups (colvarvalue::type_unit3vector type, range [-1:1]x[-1:1]x[-1:1]). More...

#include <colvarcomp.h>

Inheritance diagram for colvar::distance_dir:

colvar::distance colvar::cvc colvarparse colvardeps colvarparams List of all members.

Public Methods

 distance_dir (std::string const &conf)
 distance_dir ()
virtual ~distance_dir ()
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
Parameters:
cvforce  The collective variable force, usually coming from the biases and eventually manipulated by the parent colvar object.
More...


virtual cvm::real dist2 (colvarvalue const &x1, colvarvalue const &x2) const
 Redefined to override the distance ones. More...

virtual colvarvalue dist2_lgrad (colvarvalue const &x1, colvarvalue const &x2) const
 Redefined to override the distance ones. More...

virtual colvarvalue dist2_rgrad (colvarvalue const &x1, colvarvalue const &x2) const
 Redefined to override the distance ones. More...


Detailed Description

\brief Colvar component: distance unit vector (direction) between centers of mass of two groups (colvarvalue::type_unit3vector type, range [-1:1]x[-1:1]x[-1:1]).

Definition at line 408 of file colvarcomp.h.


Constructor & Destructor Documentation

colvar::distance_dir::distance_dir std::string const &    conf
 

colvar::distance_dir::distance_dir  
 

Definition at line 492 of file colvarcomp_distances.C.

References colvardeps::disable, colvardeps::enable, colvardeps::f_cvc_com_based, colvardeps::f_cvc_explicit_gradient, colvar::cvc::set_function_type, colvarvalue::type, colvarvalue::type_unit3vector, and colvar::cvc::x.

virtual colvar::distance_dir::~distance_dir   [inline, virtual]
 

Definition at line 414 of file colvarcomp.h.


Member Function Documentation

void colvar::distance_dir::apply_force colvarvalue const &    force [virtual]
 

\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

Parameters:
cvforce  The collective variable force, usually coming from the biases and eventually manipulated by the parent colvar object.

Reimplemented from colvar::distance.

Definition at line 524 of file colvarcomp_distances.C.

References force, colvar::distance::group1, colvar::distance::group2, colvarvalue::rvector_value, and colvar::cvc::x.

void colvar::distance_dir::calc_gradients   [virtual]
 

\brief Calculate the atomic gradients, to be reused later in order to apply forces.

Reimplemented from colvar::distance.

Definition at line 514 of file colvarcomp_distances.C.

void colvar::distance_dir::calc_value   [virtual]
 

\brief Calculate the variable.

Reimplemented from colvar::distance.

Definition at line 502 of file colvarcomp_distances.C.

References colvar::distance::dist_v, colvardeps::f_cvc_pbc_minimum_image, colvar::distance::group1, colvar::distance::group2, colvardeps::is_enabled, colvarmodule::position_distance, colvarvalue::rvector_value, and colvar::cvc::x.

cvm::real colvar::distance_dir::dist2 colvarvalue const &    x1,
colvarvalue const &    x2
const [virtual]
 

Redefined to override the distance ones.

Reimplemented from colvar::distance.

Definition at line 538 of file colvarcomp_distances.C.

References colvarvalue::rvector_value.

colvarvalue colvar::distance_dir::dist2_lgrad colvarvalue const &    x1,
colvarvalue const &    x2
const [virtual]
 

Redefined to override the distance ones.

Reimplemented from colvar::distance.

Definition at line 545 of file colvarcomp_distances.C.

References colvarvalue::rvector_value, and colvarvalue::type_unit3vectorderiv.

colvarvalue colvar::distance_dir::dist2_rgrad colvarvalue const &    x1,
colvarvalue const &    x2
const [virtual]
 

Redefined to override the distance ones.

Reimplemented from colvar::distance.

Definition at line 552 of file colvarcomp_distances.C.

References colvarvalue::rvector_value, and colvarvalue::type_unit3vectorderiv.


The documentation for this class was generated from the following files:
Generated on Fri Nov 8 02:46:35 2024 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002