Class AbstractForceField

    • Field Detail

      • mDim

        protected final int mDim
      • mPos

        protected double[] mPos
      • mNewpos

        protected double[] mNewpos
      • mGrad

        protected double[] mGrad
      • mFixedAtoms

        protected int[] mFixedAtoms
      • mTotalEnergy

        protected double mTotalEnergy
      • mTimeInterval

        protected long mTimeInterval
      • mIsInterrupted

        protected volatile boolean mIsInterrupted
    • Constructor Detail

      • AbstractForceField

        public AbstractForceField​(StereoMolecule mol)
    • Method Detail

      • addListener

        public void addListener​(ForceFieldChangeListener listener)
        Return the variance across all atoms in a molecule for the specified coordinate.
        Specified by:
        addListener in interface ForceField
        Parameters:
        listener -
      • addGradient

        public void addGradient​(double[] grad)
      • getState

        public void getState​(double[] pos)
      • setState

        public void setState​(double[] pos)
      • coordVariance

        public double coordVariance​(int c)
      • setFixedAtoms

        public void setFixedAtoms​(int[] fixedAtoms)
        Specified by:
        setFixedAtoms in interface ForceField
      • zeroGradient

        public void zeroGradient()
        Description copied from interface: ForceField
        zeroes out gradient for fixed atoms
        Specified by:
        zeroGradient in interface ForceField
      • minimise

        public int minimise​(int maxIts,
                            double gradTol,
                            double funcTol)
        Minimise the current molecule.
        Parameters:
        maxIts - The maximum number of iterations to run for.
        gradTol - The gradient tolerance.
        funcTol - The energy tolerance.
        Returns:
        Return code, 0 on success.
      • run_minimiser

        public int run_minimiser​(int maxIts,
                                 double gradTol,
                                 double funcTol)