Class ForceFieldMMFF94

    • Constructor Detail

      • ForceFieldMMFF94

        public ForceFieldMMFF94​(StereoMolecule m,
                                java.lang.String tablename,
                                java.util.Map<java.lang.String,​java.lang.Object> options)
        Forcefield constructor.
        Parameters:
        m - The molecule to construct the forcefield on.
        tablename - The string name for the Tables to be used. There must be a table with this name that has been loaded with "loadTable()".
        options - A Map containing the ForceField options and values. See class description of a list of options.
      • ForceFieldMMFF94

        public ForceFieldMMFF94​(StereoMolecule mol,
                                java.lang.String tablename)
        Forcefield constructor. Overloaded to pass the default (empty) options to a ForceField.
        Parameters:
        mol - The molecule to construct the forcefield on.
        tablename - The string name for the Tables to be used. There must be a table with this name that has been loaded with "loadTable()".
    • Method Detail

      • size

        public int size()
        Returns the total number of atoms in this force field.
        Returns:
        Total number of atoms.
      • updateGradient

        public double updateGradient()
        Minimise the current molecule using default parameter values for the number of iterations, energy tolerance and gradient tolerance.
        Returns:
        Return code, 0 on success.
      • getCurrentPositions

        public double[] getCurrentPositions()
      • getTotalEnergy

        public double getTotalEnergy​(double[] pos)
        Gets the total energy of the molecule as the sum of the energy terms.Requires the atomic positions to be in the correct order.
        Parameters:
        pos - The positions array representing the atoms positions in space.
        Returns:
        The total force field energy.
      • getTotalEnergy

        public double getTotalEnergy()
        Gets the total energy of the molecule as the sum of the energy terms. This function passes the force fields `pos` array to getTotalEnergy().
        Returns:
        The total force field energy.
      • initialize

        public static void initialize​(java.lang.String tableSet)
      • loadTable

        public static void loadTable​(java.lang.String name,
                                     Tables table)
        Loads and registers a tables object with the ForceField class so it can be used by new ForceField instances.
        Parameters:
        name - The string name used to identifiy the tables object.
        table - The tables object.
      • table

        public static Tables table​(java.lang.String name)
        Returns a table given a table name.
        Parameters:
        name - The string name of a table.
        Returns:
        The tables object.
      • addEnergyTerm

        public void addEnergyTerm​(EnergyTerm term)