Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

minimizer.h

Go to the documentation of this file.
00001 //****************************************************
00002 //  April, 1993, University of Illinois
00003 // Copyright (C) 1993, 1994 Tianlin Wang
00004 /* Copyright (C) 1994-2003 Matvec Development Team. 
00005 
00006   This program is free software; you can redistribute it and/or
00007   modify it under the terms of the GNU Library General Public
00008   License as published by the Free Software Foundation; either
00009   version 2 of the License, or (at your option) any later version.
00010   
00011   This program is distributed in the hope that it will be useful,
00012   but WITHOUT ANY WARRANTY; without even the implied warranty of
00013   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014   Library General Public License for more details.
00015     
00016   You should have received a copy of the GNU Library General Public
00017   License along with this library; if not, write to the Free
00018   Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
00019   MA 02111-1307, USA 
00020 */
00021 
00022 #ifndef Minimizer_H
00023 #define Minimizer_H
00024 
00025 #include "matrix.h"
00026 
00027 /*!
00028    \class Minimizer Minimizer.h
00029    \brief a minimizer to minimize a function
00030 
00031 */
00032 namespace matvec {
00033 
00034 class Minimizer {
00035    private:
00036       int prtlevel;
00037       void    min_first_dir(const int j,const int nits,double* d2,double* x1,
00038                             double f1, const int fk,Vector<double> &x,const int n,
00039                             const Matrix<double> &v, Vector<double> &w,Matrix<double> &q01);
00040       void    quadratic(Vector<double> &x,const int n,const Matrix<double> &v,
00041                         Vector<double> &w,Matrix<double> &q01);
00042    protected:
00043       int minfun_indx;
00044 
00045    public:
00046       Minimizer(void)  {prtlevel = 2; minfun_indx = 0;}
00047       virtual ~Minimizer(void) {;}
00048 
00049       virtual double minfun(const Vector<double> &x, const int n) = 0;
00050       void    min_prtlevel(const int pl) {prtlevel = pl;}
00051       double  praxis(Vector<double> &x,const int n, int& maxfun,
00052                      const double tol=1.0e-16,
00053                      const double epsilon=1.0e-8,const int pl=2);
00054 };
00055 }
00056 #endif

Generated on Thu Jun 16 17:13:47 2005 for Matvec by doxygen1.2.16