Class ApacheCommonsCMAESOptimizer

    • Constructor Detail

      • ApacheCommonsCMAESOptimizer

        public ApacheCommonsCMAESOptimizer​(int populationSize,
                                           int maxIterations,
                                           double stopFitness,
                                           boolean isActiveCMA,
                                           int diagonalOnly,
                                           int checkFeasableCount,
                                           double precision)
        Parameters from org.apache.commons.math3.optim.nonlinear.scalar.noderiv.CMAESOptimizer:
        Parameters:
        populationSize - the population size
        maxIterations - Maximal number of iterations.
        stopFitness - Whether to stop if objective function value is smaller than stopFitness.
        isActiveCMA - Chooses the covariance matrix update method.
        diagonalOnly - Number of initial iterations, where the covariance matrix remains diagonal.
        checkFeasableCount - Determines how often new random objective variables are generated in case they are out of bounds.
        precision - the precision of the optimization
    • Method Detail

      • solve

        public java.util.Map<Variable,​Term> solve​(ConstraintSatisfactionProblem problem)
                                                 throws GeneralMathException
        Description copied from class: Solver
        Computes a solution to the given constraint satisfaction or optimization problem, i.e. a mapping from variables of the problem to terms.
        Specified by:
        solve in class Solver
        Parameters:
        problem - the actual problem
        Returns:
        a mapping from variables of the problem to terms.
        Throws:
        GeneralMathException - if something went wrong.
      • solve

        public java.util.Map<Variable,​Term> solve​(Term t,
                                                        int optimization_type)
                                                 throws GeneralMathException
        Returns the variable assignment that maximizes/minimizes the given term (which only contains variables with defined upper and lower bounds).
        Parameters:
        t - the term to be evaluated
        optimization_type - one of OptimizationProblem.MAXIMIZE, OptimizationProblem.MINIMIZE
        Returns:
        the optimal variable assignment
        Throws:
        GeneralMathException - if there is some issue in the computation
      • isInstalled

        public static boolean isInstalled()
                                   throws java.lang.UnsupportedOperationException
        Throws:
        java.lang.UnsupportedOperationException