Update Colvars library to version 2016-12-22

Significant code cleanup and several fixes (walls + extended Lagrangian)

New harmonicWalls bias to apply confining boundaries with time-dependent force
constant & integration
This commit is contained in:
Giacomo Fiorin
2016-12-27 13:17:34 -05:00
parent 6ab716164b
commit f553e230db
49 changed files with 2489 additions and 1358 deletions

View File

@ -1,5 +1,12 @@
// -*- c++ -*-
// This file is part of the Collective Variables module (Colvars).
// The original version of Colvars and its updates are located at:
// https://github.com/colvars/colvars
// Please update all Colvars source files before making any changes.
// If you wish to distribute your changes, please submit them to the
// Colvars repository at GitHub.
#include "colvarmodule.h"
#include "colvarvalue.h"
#include "colvar.h"
@ -154,15 +161,17 @@ void colvar::cvc::read_data()
void colvar::cvc::calc_force_invgrads()
{
cvm::fatal_error("Error: calculation of inverse gradients is not implemented "
"for colvar components of type \""+function_type+"\".\n");
cvm::error("Error: calculation of inverse gradients is not implemented "
"for colvar components of type \""+function_type+"\".\n",
COLVARS_NOT_IMPLEMENTED);
}
void colvar::cvc::calc_Jacobian_derivative()
{
cvm::fatal_error("Error: calculation of inverse gradients is not implemented "
"for colvar components of type \""+function_type+"\".\n");
cvm::error("Error: calculation of inverse gradients is not implemented "
"for colvar components of type \""+function_type+"\".\n",
COLVARS_NOT_IMPLEMENTED);
}
@ -281,6 +290,33 @@ void colvar::cvc::debug_gradients(cvm::atom_group *group)
}
cvm::real colvar::cvc::dist2(colvarvalue const &x1,
colvarvalue const &x2) const
{
return x1.dist2(x2);
}
colvarvalue colvar::cvc::dist2_lgrad(colvarvalue const &x1,
colvarvalue const &x2) const
{
return x1.dist2_grad(x2);
}
colvarvalue colvar::cvc::dist2_rgrad(colvarvalue const &x1,
colvarvalue const &x2) const
{
return x2.dist2_grad(x1);
}
void colvar::cvc::wrap(colvarvalue &x) const
{
return;
}
// Static members
std::vector<colvardeps::feature *> colvar::cvc::cvc_features;