| Home | Trees | Indices | Help |
|
|---|
|
|
Box constrained minimization functions.
Contains amoeba.
Fit functions may be implemented in python or in C.
You can download the latest version from svn:
svn co svn://danse.us/boxmin/trunk
If you are installing from source, you will need a python environment with numpy. You will need a C compiler to build c lib. On Windows this may require installing MinGW and adding distutils.cfg to your distutils directory:
[build] compiler = mingw
Once you have the required supporting packages, use the following to build and install:
python setup.py install
Example using python function:
>>> from boxmin import amoeba >>> def quadratic(vec): >>> return vec[0]**2+vec[1]**2+1 >>> F = amoeba.amoeba(quadratic,[1,1]) >>> p = F.fit(1e-7)
p should now contain the vector [x_0, x_1, f(x_0,x_1)] = [0, 0, 1]
See cfitfn_example in boxmin/python/tests for an example of how to define a C function which is directly callable from the fit.
|
|||
| |||
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0.1 on Tue Mar 17 10:47:24 2009 | http://epydoc.sourceforge.net |