iterator
Class AbstractInitialSampleBasedOptimizer<T extends BoundConstrainedProblem>

java.lang.Object
  extended by iterator.AbstractIterator
      extended by iterator.AbstractOptimizer<T>
          extended by iterator.AbstractInitialSampleBasedOptimizer<T>
Type Parameters:
T - A subclass of BoundConstrainedProblem.
All Implemented Interfaces:
DataListener, InitialSamplesSettable, Iterable, LoggableIterator, RepeatableLoggableIterator
Direct Known Subclasses:
AbstractPopulationOptimizer

public abstract class AbstractInitialSampleBasedOptimizer<T extends BoundConstrainedProblem>
extends AbstractOptimizer<T>
implements InitialSamplesSettable, RepeatableLoggableIterator

Abstract class for an optimizer that needs a set of initial samples, rather than a single initial point. Parametrized by the type of problem it handles.

Author:
dgorur

Field Summary
protected  LatinHypercube uniform
           
 
Fields inherited from class iterator.AbstractOptimizer
doubleFormat, funEvalCount, logWriter
 
Fields inherited from class iterator.AbstractIterator
diagnosticString, iter
 
Constructor Summary
AbstractInitialSampleBasedOptimizer()
           
 
Method Summary
 int getRandomSeed()
          Returns the random seed.
 void init()
          Initialization routine
 cern.colt.matrix.DoubleMatrix2D makeInitialSamples(int sampleCount)
          Makes the desired number of initial samples.
 void setRandomSeed(int randomSeed)
          Sets the randomSeed.
 
Methods inherited from class iterator.AbstractOptimizer
clear, dataAdded, dataAdded, dataRemoved, dataRemoved, getDataHandler, getFunEvalCount, getLogFileName, getMaxFunEval, getProblem, isTerminated, iterate, setDataHandler, setFunEvalCount, setLogFileName, setMaxFunEval, setProblem, updateDiagnostics, writeInitialRunLog
 
Methods inherited from class iterator.AbstractIterator
isVerbose, printDiagnostics, setVerbose
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface iterator.InitialSamplesSettable
setInitialSamples, setInitialSamples, setInitialSamples
 
Methods inherited from interface iterator.LoggableIterator
getLogFileName, setLogFileName
 
Methods inherited from interface iterator.Iterable
isTerminated, iterate, singleIteration
 

Field Detail

uniform

protected LatinHypercube uniform
Constructor Detail

AbstractInitialSampleBasedOptimizer

public AbstractInitialSampleBasedOptimizer()
Method Detail

getRandomSeed

public int getRandomSeed()
Description copied from interface: RepeatableLoggableIterator
Returns the random seed.

Specified by:
getRandomSeed in interface RepeatableLoggableIterator
Returns:
the random seed.

init

public void init()
Description copied from interface: Iterable
Initialization routine

Specified by:
init in interface Iterable
Overrides:
init in class AbstractOptimizer<T extends BoundConstrainedProblem>

makeInitialSamples

public cern.colt.matrix.DoubleMatrix2D makeInitialSamples(int sampleCount)
Description copied from interface: InitialSamplesSettable
Makes the desired number of initial samples.

Specified by:
makeInitialSamples in interface InitialSamplesSettable
Returns:
a matrix containing the x-values of the desired number of initial samples.

setRandomSeed

public void setRandomSeed(int randomSeed)
Sets the randomSeed.

Specified by:
setRandomSeed in interface InitialSamplesSettable
Specified by:
setRandomSeed in interface RepeatableLoggableIterator
Parameters:
randomSeed - the given randomSeed.