Object-oriented Scientific Computing Library: Version 0.910
Public Member Functions | Data Fields | Protected Member Functions | Protected Attributes | Private Member Functions
multi_min_fix< bool_vec_t > Class Template Reference

Multidimensional minimizer fixing some variables and varying others. More...

#include <multi_min_fix.h>

Inheritance diagram for multi_min_fix< bool_vec_t >:
multi_min< func_t, dfunc_t, vec_t >

Detailed Description

template<class bool_vec_t>
class multi_min_fix< bool_vec_t >

See an example for the usage of this class in Minimizer fixing variables .

Todo:

Generalize to all vector types

Generalize to minimizers which require derivatives

At the moment, the user has to change def_mmin::ntrial instead of multi_min_fix::ntrial, which is a bit confusing. Fix this.

Definition at line 46 of file multi_min_fix.h.

Public Member Functions

 multi_min_fix ()
 Specify the member function pointer.
virtual int mmin (size_t nvar, ovector_base &x, double &fmin, multi_funct<> &func)
 Calculate the minimum min of func w.r.t. the array x of size nvar.
virtual int mmin_fix (size_t nvar, ovector_base &x, double &fmin, bool_vec_t &fix, multi_funct<> &func)
 Calculate the minimum of func while fixing some parameters as specified in fix.
int set_mmin (multi_min< multi_funct_mfptr< multi_min_fix > > &min)
 Change the base minimizer.

Data Fields

gsl_mmin_simp2
< multi_funct_mfptr
< multi_min_fix > > 
def_mmin
 The default base minimizer.

Protected Member Functions

virtual double min_func (size_t nv, const ovector_base &x)
 The new function to send to the minimizer.

Protected Attributes

multi_min< multi_funct_mfptr
< multi_min_fix > > * 
mmp
 The minimizer.
multi_functfuncp
 The user-specified function.
size_t unv
 The user-specified number of variables.
size_t nv_new
 The new number of variables.
bool_vec_t * fixp
 Specify which parameters to fix.
ovector_basexp
 The user-specified initial vector.

Private Member Functions

 multi_min_fix (const multi_min_fix &)
multi_min_fixoperator= (const multi_min_fix &)

Member Function Documentation

template<class bool_vec_t>
virtual int multi_min_fix< bool_vec_t >::mmin_fix ( size_t  nvar,
ovector_base x,
double &  fmin,
bool_vec_t &  fix,
multi_funct<> &  func 
) [inline, virtual]

If all of entries fix[0], fix[1], ... fix[nvar-1] are true, then this function assumes all of the parameters are fixed and that there is no minimization to be performed. In this case, it will return 0 for success without calling the error handler.

Definition at line 107 of file multi_min_fix.h.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Documentation generated with Doxygen. Provided under the GNU Free Documentation License (see License Information).

Get Object-oriented Scientific Computing
Lib at SourceForge.net. Fast, secure and Free Open Source software
downloads.