Simpatico
v1.10
|
A Bend calculates the angle between two vectors.
Models the angle between a pair of vectors b1 and b2 that are passed to the function computeAngle().
The scalar cosTheta is the cosine of the angle between b1 and b2.
#include <Bend.h>
Public Member Functions | |
void | computeAngle (const Vector &b1, const Vector &b2) |
Compute cosTheta. More... | |
double | sinTheta () const |
Return value of sin(theta) for precomputed cos(theta). More... | |
double | theta () const |
Return value of theta in radians for precomputed cos(theta). More... | |
Public Attributes | |
double | cosTheta |
Cosine of angle between vectors b1 and b2. More... | |
Compute cosTheta.
b1 | bond vector from atom 0 to 1. |
b2 | bond vector from atom 1 to 2. |
Definition at line 68 of file Bend.h.
References cosTheta, Util::Vector::dot(), and Util::Vector::square().
|
inline |
Return value of sin(theta) for precomputed cos(theta).
Definition at line 80 of file Bend.h.
References cosTheta.
Referenced by Simp::HarmonicAngle::force().
|
inline |
Return value of theta in radians for precomputed cos(theta).
Returns principal value, in range 0 < theta < Pi.
Definition at line 87 of file Bend.h.
References cosTheta.
Referenced by Simp::HarmonicAngle::force().
double Simp::Bend::cosTheta |
Cosine of angle between vectors b1 and b2.
Definition at line 38 of file Bend.h.
Referenced by computeAngle(), Simp::BendForce::computeDerivatives(), sinTheta(), and theta().