Package ffx.openmm

Class AndersenThermostat

java.lang.Object
ffx.openmm.Force
ffx.openmm.AndersenThermostat

public class AndersenThermostat extends Force
This class uses the Andersen method to maintain constant temperature.
  • Constructor Details

    • AndersenThermostat

      public AndersenThermostat(double temperature, double frequency)
      OpenMM AndersenThermostat constructor.
      Parameters:
      temperature - the default temperature of the heat bath (in Kelvin).
      frequency - the default collision frequency (in 1/ps)
  • Method Details

    • setDefaultTemperature

      public void setDefaultTemperature(double temperature)
      Set the default temperature of the heat bath. This will affect any new Contexts you create, but not ones that already exist.
      Parameters:
      temperature - the default temperature of the heat bath (in Kelvin).
    • getDefaultTemperature

      public double getDefaultTemperature()
      Get the default temperature of the heat bath (in Kelvin).
      Returns:
      the default temperature of the heat bath, measured in Kelvin.
    • setDefaultCollisionFrequency

      public void setDefaultCollisionFrequency(double frequency)
      Set the default collision frequency. This will affect any new Contexts you create, but not ones that already exist.
      Parameters:
      frequency - the default collision frequency (in 1/ps).
    • getDefaultCollisionFrequency

      public double getDefaultCollisionFrequency()
      Get the default collision frequency (in 1/ps).
      Returns:
      the default collision frequency (in 1/ps).
    • setRandomNumberSeed

      public void setRandomNumberSeed(int seed)
      Set the random number seed. The precise meaning of this parameter is undefined, and is left up to each Platform to interpret in an appropriate way. It is guaranteed that if two simulations are run with different random number seeds, the sequence of collisions will be different. On the other hand, no guarantees are made about the behavior of simulations that use the same seed. In particular, Platforms are permitted to use non-deterministic algorithms which produce different results on successive runs, even if those runs were initialized identically.

      If seed is set to 0 (which is the default value assigned), a unique seed is chosen when a Context is created from this Force. This is done to ensure that each Context receives unique random seeds without you needing to set them explicitly.

      Parameters:
      seed - the random number seed.
    • getRandomNumberSeed

      public int getRandomNumberSeed()
      Get the random number seed. See setRandomNumberSeed() for details.
    • usesPeriodicBoundaryConditions

      public boolean usesPeriodicBoundaryConditions()
      Returns whether this force makes use of periodic boundary conditions.
      Overrides:
      usesPeriodicBoundaryConditions in class Force
      Returns:
      True if the force uses periodic boundary conditions.
    • destroy

      public void destroy()
      Destroy the force.