# SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.misc.algorithm.iterative

## Interface IterativeMethod<S>

• ### Method Summary

All Methods
Modifier and Type Method and Description
S search(S... initials)
Search for a solution that optimizes the objective function from the given starting points.
void setInitials(S... initials)
Supply the starting points for the search.
Object step()
Do the next iteration.
• ### Method Detail

• #### setInitials

void setInitials(S... initials)
Supply the starting points for the search. This can also initialize the state of the algorithm for a new search.
Parameters:
initials - the initial guesses
• #### step

Object step()
throws Exception
Do the next iteration.
Returns:
Throws:
Exception - when an error occurs during the search
• #### search

S search(S... initials)
throws Exception
Search for a solution that optimizes the objective function from the given starting points. This method typically calls first #setInitials(S...) and then iteratively step(). It implements a default convergence criterion.
Parameters:
initials - the initial guesses
Returns:
an (approximate) optimizer
Throws:
Exception - when an error occurs during the search