net.sourceforge.cilib.functions.continuous.unconstrained.Bukin6 Maven / Gradle / Ivy
/** __ __
* _____ _/ /_/ /_ Computational Intelligence Library (CIlib)
* / ___/ / / / __ \ (c) CIRG @ UP
* / /__/ / / / /_/ / http://cilib.net
* \___/_/_/_/_.___/
*/
package net.sourceforge.cilib.functions.continuous.unconstrained;
import net.sourceforge.cilib.functions.ContinuousFunction;
import net.sourceforge.cilib.type.types.container.Vector;
import com.google.common.base.Preconditions;
/**
* Bukin 6 Function.
*
* Reference: S.K. Mishra, Some New Test Functions
* for Global Optimization and Performance of Repulsive Particle Swarm Methods
* North-Eastern Hill University, India, 2002
*
* Minimum:
*
* - ƒ(x*) = 0.0
* - x* = (-10,1)
* - for x1 in [-15,-5], x2 in [-3,3]
*
*
*
* Characteristics:
*
* - Only defined for 2 dimensions
* - Multimodal
* - Seperable
* - Nonregular
*
*
*
* R(-15,-5),R(-3,3)
*
*/
public class Bukin6 extends ContinuousFunction {
private static final long serialVersionUID = -5557883529972004157L;
/**
* {@inheritDoc}
*/
@Override
public Double f(Vector input) {
Preconditions.checkArgument(input.size() == 2, "Bukin 6 function is only defined for 2 dimensions");
double x1 = input.doubleValueOf(0);
double x2 = input.doubleValueOf(1);
return 100 * Math.sqrt(Math.abs(x2 - 0.01 * x1 * x1)) + 0.01 * Math.abs(x1 + 10);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy