NelderMeadSimplex

scalation.optimization.NelderMeadSimplex
class NelderMeadSimplex(f: FunctionV2S, n: Int) extends Minimize

The NelderMeadSimplex solves Non-Linear Programming (NLP) problems using the Nelder-Mead Simplex algorithm. Given a function f and its dimension n, the algorithm moves a simplex defined by n + 1 points in order to find an optimal solution. The algorithm is derivative-free.

minimize f(x)

The algorithm requires between 1 to n+2 function evaluations per iteration

Value parameters

f

the vector-to-scalar objective function

n

the dimension of the search space

Attributes

Graph
Supertypes
trait Minimize
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def initSimplex(x0: VectorD, step: Double): Unit

Initialize the search simplex by setting n + 1 vertices and computing their functional values.

Initialize the search simplex by setting n + 1 vertices and computing their functional values.

Value parameters

step

the step size

x0

the given starting point

Attributes

def solve(x0: VectorD, step: Double): FuncVec

Solve the Non-Linear Programming (NLP) problem using the Nelder-Mead Simplex algorithm.

Solve the Non-Linear Programming (NLP) problem using the Nelder-Mead Simplex algorithm.

Value parameters

step

the initial step size

x0

the given starting point

Attributes

def transform(): Double

Transform/improve the simplex by replacing the worst/highest vertex (x_h) with a better one found on the line containing x_h and the centroid (x_c). Try the reflection, expansion, outer contraction and inner contraction points, in that order. If none succeeds, shrink the simplex and iterate. Return both distance between x_h (worst) and x_l (best).

Transform/improve the simplex by replacing the worst/highest vertex (x_h) with a better one found on the line containing x_h and the centroid (x_c). Try the reflection, expansion, outer contraction and inner contraction points, in that order. If none succeeds, shrink the simplex and iterate. Return both distance between x_h (worst) and x_l (best).

Attributes