c

scalation.minima

IntegerLocalSearch

class IntegerLocalSearch extends AnyRef

The IntegerLocalSearch class performs local search to find minima of functions defined on integer vector domains (z^n).

minimize f(x) subject to g(x) <= 0, x in Z^n

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. IntegerLocalSearch
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new IntegerLocalSearch(f: (VectorI) => Double, g: (VectorI) => Double = null, maxStep: Int = 5)

    f

    the objective function to be minimize ('f' maps an integer vector to a double)

    g

    the constraint function to be satisfied, if any

    maxStep

    the maximum/starting step size (make larger for larger domains)

Type Members

  1. type Vec_Func = (VectorI, Double)

    Pair consisting of an integer vector and its functional value (a double)

Value Members

  1. def fg(x: VectorI): Double

    The objective function 'f' re-scaled by a weighted penalty, if constrained.

    The objective function 'f' re-scaled by a weighted penalty, if constrained.

    x

    the coordinate values of the current point

  2. def minNeighbor(x_f0: Vec_Func, i: Int, step: Int = 1): Vec_Func

    Find a minimal neighbor of the current point 'x' that is a distance step away.

    Find a minimal neighbor of the current point 'x' that is a distance step away. Let 'x' be the current point with 'y' being a step down and 'x' being a step up in dimension 'i'. Recurse to handle all of the dimensions.

    x_f0

    the current pair (the point and its functional value)

    i

    the 'i'th dimension or coordinate (facilitates recursion)

    step

    examine points that are this far away

  3. def solve(x: VectorI): Vec_Func

    Solve the minimization problem by repeatedly moving to a minimal neighbor until there is no improvement.

    Solve the minimization problem by repeatedly moving to a minimal neighbor until there is no improvement.

    x

    the starting point for the search