RGForce¶
- class openmm.openmm.RGForce(*args)¶
This is a force whose energy equals the radius of gyration (Rg) of a set of particles. It is intended for use with CustomCVForce. You will not normally want a force that exactly equals the radius of gyration, but there are many situations where it is useful to have a restraining or biasing force that depends on Rg in some way.
- __init__(self, particles=std::vector< int >()) RGForce ¶
- __init__(self, other) RGForce
Create an RGForce.
- Parameters:
particles (Sequence[int]) – the indices of the particles to use when computing Rg. If this is empty (the default), all particles in the system will be used.
Methods
__init__
() -> RGForce)Create an RGForce.
getForceGroup
(self)Get the force group this Force belongs to.
getName
(self)Get the name of this Force.
getParticles
(self)Get the indices of the particles to use when computing Rg.
setForceGroup
(self, group)Set the force group this Force belongs to.
setName
(self, name)Set the name of this Force.
setParticles
(self, particles)Set the indices of the particles to use when computing Rg.
Returns whether or not this force makes use of periodic boundary conditions.
Attributes
The membership flag
- property thisown¶
The membership flag
- getParticles(self) tuple[int, ...] ¶
Get the indices of the particles to use when computing Rg. If this is empty, all particles in the system will be used.
- setParticles(self, particles)¶
Set the indices of the particles to use when computing Rg. If this is empty, all particles in the system will be used.
- usesPeriodicBoundaryConditions(self) bool ¶
Returns whether or not this force makes use of periodic boundary conditions.
- Returns:
true if force uses PBC and false otherwise
- Return type:
bool
- getForceGroup(self) int ¶
Get the force group this Force belongs to.
- getName(self) str ¶
Get the name of this Force. This is an arbitrary, user modifiable identifier. By default it equals the class name, but you can change it to anything useful.
- setForceGroup(self, group)¶
Set the force group this Force belongs to.
- Parameters:
group (int) – the group index. Legal values are between 0 and 31 (inclusive).
- setName(self, name)¶
Set the name of this Force. This is an arbitrary, user modifiable identifier. By default it equals the class name, but you can change it to anything useful.