00001 /************************************************************************* 00002 * 00003 * The Contents of this file are made available subject to 00004 * the terms of GNU Lesser General Public License Version 2.1. 00005 * 00006 * 00007 * GNU Lesser General Public License Version 2.1 00008 * ============================================= 00009 * Copyright 2008, by Kohei Yoshida. 00010 * 1039 Kingsway Dr., Apex, NC 27502, USA 00011 * 00012 * This library is free software; you can redistribute it and/or 00013 * modify it under the terms of the GNU Lesser General Public 00014 * License version 2.1, as published by the Free Software Foundation. 00015 * 00016 * This library is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00019 * Lesser General Public License for more details. 00020 * 00021 * You should have received a copy of the GNU Lesser General Public 00022 * License along with this library; if not, write to the Free Software 00023 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, 00024 * MA 02111-1307 USA 00025 * 00026 ************************************************************************/ 00027 00028 #ifndef _SCSOLVER_NUMERIC_BASELINESEARCH_HXX_ 00029 #define _SCSOLVER_NUMERIC_BASELINESEARCH_HXX_ 00030 00031 #include "numeric/type.hxx" 00032 00033 namespace scsolver { namespace numeric { 00034 00035 class SingleVarFuncObj; 00036 00037 class BaseLineSearch 00038 { 00039 public: 00040 BaseLineSearch(); 00041 explicit BaseLineSearch(SingleVarFuncObj* pFuncObj); 00042 virtual ~BaseLineSearch() = 0; 00043 00044 virtual double solve() = 0; 00045 00046 void setGoal(GoalType goal); 00047 GoalType getGoal() const; 00048 00049 void setDebug(bool b); 00050 bool isDebug() const; 00051 00052 void setFuncObj(SingleVarFuncObj* p); 00053 SingleVarFuncObj* getFuncObj() const; 00054 00055 private: 00056 00057 private: 00058 SingleVarFuncObj* m_pFuncObj; 00059 GoalType m_goal; 00060 bool m_debug; 00061 }; 00062 00063 }} 00064 00065 #endif
1.5.3