Class SolverFactory<T>

  • Type Parameters:
    T - The type of solver that is constructed.
    Direct Known Subclasses:
    AKPFactoryArraySimple

    public abstract class SolverFactory<T>
    extends java.lang.Object
    An abstract class that contains basic functionality every class that sets up a solver needs.

    Building a factory of this type also means to set up a context in which the following solver are build in e.g. a common ground distance and if needed a tolerance for being optimal. Furthermore, common data as a value for additional information to the solver building process is abstracted.

    Author:
    brockhoff
    • Field Detail

      • additionalInfo

        protected int additionalInfo
        Some additional data for the initialization
      • groundDist

        protected DistanceMatrix<?,​?> groundDist
        Ground distance that will be used to compute costs
    • Constructor Detail

      • SolverFactory

        public SolverFactory​(DistanceMatrix<?,​?> groundDist)
        Constructor in case that the solver does not
        Parameters:
        groundDist -
      • SolverFactory

        public SolverFactory​(DistanceMatrix<?,​?> groundDist,
                             double tol)
        Parameters:
        groundDist -
        tol -
      • SolverFactory

        public SolverFactory​(DistanceMatrix<?,​?> groundDist,
                             int additionalInfo)
        Parameters:
        groundDist -
        additionalInfo -
      • SolverFactory

        public SolverFactory​(DistanceMatrix<?,​?> groundDist,
                             double tol,
                             int additionalInfo)
        This constructor is used by IPM.
        Parameters:
        additionalInfo -
        groundDist -
        tol -
    • Method Detail

      • setupNewSolver

        public abstract void setupNewSolver​(StochasticLanguage<?> s1,
                                            StochasticLanguage<?> s2,
                                            org.processmining.framework.plugin.ProMCanceller canceller)
        Sets up a new solver of the given type.
        Parameters:
        s1 - StochasticLanguage "from"
        s2 - StochasticLanguage "to"
        costs - Cost matrix
        deltaBound - "DeltaBound" needed for IM initialization
      • getSolver

        public abstract T getSolver()
        Returns:
        Current solver instance
      • getGroundDist

        public DistanceMatrix<?,​?> getGroundDist()
        Returns:
        the groundDist
      • getTol

        public double getTol()
        Returns:
        the tol
      • getAdditionalInfo

        public int getAdditionalInfo()
        Returns:
        The additional information stored
      • setAdditionalInfo

        public void setAdditionalInfo​(int additionalInfo)
        Set the additional information.
        Parameters:
        additionalInfo - The additional information value to store