Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Attributes
vnl_amoebaFit Struct Reference
Inheritance diagram for vnl_amoebaFit:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 vnl_amoebaFit (vnl_amoeba &a)
void set_up_simplex_relative (vcl_vector< vnl_amoeba_SimplexCorner > &simplex, const vnl_vector< double > &x)
 Initialise the simplex given one corner, x (scale each element to get other corners).
void set_up_simplex_absolute (vcl_vector< vnl_amoeba_SimplexCorner > &simplex, const vnl_vector< double > &x, const vnl_vector< double > &dx)
 Initialise the simplex given one corner, x and displacements of others.
void amoeba (vnl_vector< double > &x)
 Perform optimisation. Start simplex defined by scaling elements of x.
void amoeba (vnl_vector< double > &x, const vnl_vector< double > &dx)
 Perform optimisation. Start simplex defined by adding dx[i] to each x[i].
void amoeba (vnl_vector< double > &x, vcl_vector< vnl_amoeba_SimplexCorner > &simplex)
 Perform optimisation, given simplex to start.
double f (const vnl_vector< double > &x)
void set_corner (vnl_amoeba_SimplexCorner *s, const vnl_vector< double > &v)
void set_corner_a_plus_bl (vnl_amoeba_SimplexCorner *s, const vnl_vector< double > &vbar, const vnl_vector< double > &v, double lambda)
void set_max_iterations (int n)
 Define maximum number of iterations to use.
void set_x_tolerance (double tol)
 Define tolerance on elements of x.
void set_f_tolerance (double tol)
 Define tolerance on function evaluation.
void set_relative_diameter (double r)
 Define scaling used to select starting vertices relative to initial x0.
void minimize (vnl_vector< double > &x)
 Modify x to minimise function supplied in constructor.
void minimize (vnl_vector< double > &x, const vnl_vector< double > &dx)
 Perform optimisation.
int get_num_evaluations () const
 Number of evaluations used in last call to minimize.

Static Public Member Functions

static void minimize (vnl_cost_function &f, vnl_vector< double > &x)
 Modify x so as to minimise f(x).
static void minimize (vnl_cost_function &f, vnl_vector< double > &x, const vnl_vector< double > &dx)
 Modify x so as to minimise f(x).
static void minimize (vnl_cost_function &f, vnl_vector< double > &x, double delta)
 Modify x so as to minimise f(x).
static void minimize (vnl_least_squares_function &f, vnl_vector< double > &x)
 Modify x so as to minimise f(x).

Public Attributes

int cnt
int verbose
int maxiter
double X_tolerance
double F_tolerance
double relative_diameter
 Scaling used to select starting vertices relative to initial x0.

Static Public Attributes

static bool default_verbose = false

Protected Attributes

vnl_cost_functionfptr
int num_evaluations_

Detailed Description

Definition at line 34 of file vnl_amoeba.cxx.


Constructor & Destructor Documentation

vnl_amoebaFit::vnl_amoebaFit ( vnl_amoeba a) [inline]

Definition at line 38 of file vnl_amoeba.cxx.


Member Function Documentation

void vnl_amoebaFit::amoeba ( vnl_vector< double > &  x)

Perform optimisation. Start simplex defined by scaling elements of x.

FMINS Minimize a function of several variables.

FMINS('F',X0) attempts to return a vector x which is a local minimizer of F(x) near the starting vector X0. 'F' is a string containing the name of the objective function to be minimized. F(x) should be a scalar valued function of a vector variable.

FMINS('F',X0,OPTIONS) uses a vector of control parameters. If OPTIONS(1) is nonzero, intermediate steps in the solution are displayed; the default is OPTIONS(1) = 0. OPTIONS(2) is the termination tolerance for x; the default is 1.e-4. OPTIONS(3) is the termination tolerance for F(x); the default is 1.e-4. OPTIONS(14) is the maximum number of steps; the default is OPTIONS(14) = 500. The other components of OPTIONS are not used as input control parameters by FMIN. For more information, see FOPTIONS.

FMINS('F',X0,OPTIONS,[],P1,P2,...) provides for up to 10 additional arguments which are passed to the objective function, F(X,P1,P2,...)

FMINS uses a simplex search method.

See also FMIN.

Reference: J. E. Dennis, Jr. and D. J. Woods, New Computing Environments: Microcomputers in Large-Scale Computing, edited by A. Wouk, SIAM, 1987, pp. 116-122.

Definition at line 244 of file vnl_amoeba.cxx.

void vnl_amoebaFit::amoeba ( vnl_vector< double > &  x,
const vnl_vector< double > &  dx 
)

Perform optimisation. Start simplex defined by adding dx[i] to each x[i].

Definition at line 254 of file vnl_amoeba.cxx.

void vnl_amoebaFit::amoeba ( vnl_vector< double > &  x,
vcl_vector< vnl_amoeba_SimplexCorner > &  simplex 
)

Perform optimisation, given simplex to start.

Definition at line 265 of file vnl_amoeba.cxx.

double vnl_amoebaFit::f ( const vnl_vector< double > &  x) [inline]

Definition at line 60 of file vnl_amoeba.cxx.

int vnl_amoeba::get_num_evaluations ( ) const [inline, inherited]

Number of evaluations used in last call to minimize.

Definition at line 82 of file vnl_amoeba.h.

void vnl_amoeba::minimize ( vnl_vector< double > &  x) [inherited]

Modify x to minimise function supplied in constructor.

Start simplex defined by scaling elements of x

Definition at line 366 of file vnl_amoeba.cxx.

void vnl_amoeba::minimize ( vnl_vector< double > &  x,
const vnl_vector< double > &  dx 
) [inherited]

Perform optimisation.

Perform optimisation. Start simplex defined by adding dx[i] to each x[i].

Start simplex defined by adding dx[i] to each x[i]

Definition at line 374 of file vnl_amoeba.cxx.

void vnl_amoeba::minimize ( vnl_cost_function f,
vnl_vector< double > &  x 
) [static, inherited]

Modify x so as to minimise f(x).

Static method.

Definition at line 383 of file vnl_amoeba.cxx.

void vnl_amoeba::minimize ( vnl_cost_function f,
vnl_vector< double > &  x,
const vnl_vector< double > &  dx 
) [static, inherited]

Modify x so as to minimise f(x).

Static method.

Start simplex defined by adding dx[i] to each x[i]

Definition at line 400 of file vnl_amoeba.cxx.

void vnl_amoeba::minimize ( vnl_cost_function f,
vnl_vector< double > &  x,
double  delta 
) [static, inherited]

Modify x so as to minimise f(x).

Static method.

delta defines relative size of initial simplex ie the i'th vertex has xi[i] = x[i]*(1+delta)

Definition at line 389 of file vnl_amoeba.cxx.

void vnl_amoeba::minimize ( vnl_least_squares_function f,
vnl_vector< double > &  x 
) [static, inherited]

Modify x so as to minimise f(x).

Definition at line 427 of file vnl_amoeba.cxx.

void vnl_amoebaFit::set_corner ( vnl_amoeba_SimplexCorner s,
const vnl_vector< double > &  v 
) [inline]

Definition at line 64 of file vnl_amoeba.cxx.

void vnl_amoebaFit::set_corner_a_plus_bl ( vnl_amoeba_SimplexCorner s,
const vnl_vector< double > &  vbar,
const vnl_vector< double > &  v,
double  lambda 
) [inline]

Definition at line 71 of file vnl_amoeba.cxx.

void vnl_amoeba::set_f_tolerance ( double  tol) [inline, inherited]

Define tolerance on function evaluation.

Definition at line 60 of file vnl_amoeba.h.

void vnl_amoeba::set_max_iterations ( int  n) [inline, inherited]

Define maximum number of iterations to use.

Definition at line 54 of file vnl_amoeba.h.

void vnl_amoeba::set_relative_diameter ( double  r) [inline, inherited]

Define scaling used to select starting vertices relative to initial x0.

I.e. the i'th vertex has x[i] = x0[i]*(1+relative_diameter)

Definition at line 64 of file vnl_amoeba.h.

void vnl_amoebaFit::set_up_simplex_absolute ( vcl_vector< vnl_amoeba_SimplexCorner > &  simplex,
const vnl_vector< double > &  x,
const vnl_vector< double > &  dx 
)

Initialise the simplex given one corner, x and displacements of others.

Definition at line 198 of file vnl_amoeba.cxx.

void vnl_amoebaFit::set_up_simplex_relative ( vcl_vector< vnl_amoeba_SimplexCorner > &  simplex,
const vnl_vector< double > &  x 
)

Initialise the simplex given one corner, x (scale each element to get other corners).

Initialise the simplex given one corner, x.

Definition at line 171 of file vnl_amoeba.cxx.

void vnl_amoeba::set_x_tolerance ( double  tol) [inline, inherited]

Define tolerance on elements of x.

Definition at line 57 of file vnl_amoeba.h.


Member Data Documentation

Definition at line 36 of file vnl_amoeba.cxx.

bool vnl_amoeba::default_verbose = false [static, inherited]

Definition at line 102 of file vnl_amoeba.h.

double vnl_amoeba::F_tolerance [inherited]

Definition at line 51 of file vnl_amoeba.h.

vnl_cost_function* vnl_amoeba::fptr [protected, inherited]

Definition at line 105 of file vnl_amoeba.h.

int vnl_amoeba::maxiter [inherited]

Definition at line 49 of file vnl_amoeba.h.

int vnl_amoeba::num_evaluations_ [protected, inherited]

Definition at line 106 of file vnl_amoeba.h.

double vnl_amoeba::relative_diameter [inherited]

Scaling used to select starting vertices relative to initial x0.

I.e. the i'th vertex has x[i] = x0[i]*(1+relative_diameter)

Definition at line 68 of file vnl_amoeba.h.

int vnl_amoeba::verbose [inherited]

Definition at line 48 of file vnl_amoeba.h.

double vnl_amoeba::X_tolerance [inherited]

Definition at line 50 of file vnl_amoeba.h.


The documentation for this struct was generated from the following file: