PerturbDistance¶
-
class
PerturbDistance
: public feasst::PerturbMove¶ Put first site in selection in a sphere about the first site in anchor. For bond potentials, the equilibrium length and spring constant are as described in Random::bond_length Currently implemented for harmonic bonds (exponent: 2), but could add an optional exponent model parameter to generalize this.
Subclassed by feasst::PerturbDistanceAngle, feasst::PerturbReptate
Public Functions
-
void
precompute
(TrialSelect *select, System *system)¶ Compute and store the distance from the bond_length property in select. Also store the spring constant.
-
double
distance
() const¶ Return the equilibrium distance.
-
double
spring_constant
() const¶ Return the spring constant. If -1, the bond length is rigid.
-
double
random_distance
(Random *random, const double beta, const int dimension) const¶ Return the randomly selected distance from the bond potential.
- Parameters
dimension
: inverse temperature
-
void
move
(System *system, TrialSelect *select, Random *random)¶ Move the selection of the system.
-
void