LOOS 4.1.0
The Lightweight Object Oriented Structural analysis library/toolkit
|
Interface for ENM spring functions. More...
#include <spring_functions.hpp>
Public Types | |
typedef std::vector< double > | Params |
Public Member Functions | |
virtual std::string | name () const =0 |
Name for this particular spring function. | |
virtual Params | setParams (const Params &konst)=0 |
Sets the internal constants, returning the unused ones. | |
virtual bool | validParams () const =0 |
Determines if the internal constants are "valid". | |
virtual uint | paramSize () const =0 |
How many internal constants there are. | |
virtual loos::DoubleMatrix | constant (const loos::GCoord &u, const loos::GCoord &v, const loos::GCoord &d)=0 |
Actually compute the spring constant as a 3x3 matrix. | |
Protected Member Functions | |
double | checkConstant (double d) |
Check for negative spring-constants. | |
Interface for ENM spring functions.
These classes define the various possible spring functions used in creating the Hessian. All derived from the SpringFunction base class. This class returns a 3x3 DoubleMatrix containing the spring constants...
The SpringFunction::constant() function takes the coords of the two nodes plus their difference vector (since it'll almost always be computed prior to calling SpringFunction, no sense in recomputing it).
=Misc notes=
setParams() takes a vector of doubles that represents the internal "constants" for the spring functions. It treats the vector as a LIFO stack and picks off the ones it neds, returning the rest.
|
inlineprotected |
Check for negative spring-constants.
Issues a one-time warning if a negative spring constant is found
|
pure virtual |
Actually compute the spring constant as a 3x3 matrix.
Implemented in ENM::UniformSpringFunction.
|
pure virtual |
Name for this particular spring function.
Implemented in ENM::DistanceCutoff, ENM::DistanceWeight, ENM::ExponentialDistance, ENM::HCA, and ENM::ConstBonded.
|
pure virtual |
How many internal constants there are.
Implemented in ENM::DistanceCutoff, ENM::DistanceWeight, ENM::ExponentialDistance, ENM::HCA, and ENM::ConstBonded.
|
pure virtual |
Sets the internal constants, returning the unused ones.
Implemented in ENM::DistanceCutoff, ENM::DistanceWeight, ENM::ExponentialDistance, ENM::HCA, and ENM::ConstBonded.
|
pure virtual |
Determines if the internal constants are "valid".
Implemented in ENM::DistanceCutoff, ENM::DistanceWeight, ENM::ExponentialDistance, ENM::HCA, and ENM::ConstBonded.