MoochoPack_NLPAlgoConfigMamaJama.hpp

00001 // @HEADER
00002 // ***********************************************************************
00003 // 
00004 // Moocho: Multi-functional Object-Oriented arCHitecture for Optimization
00005 //                  Copyright (2003) Sandia Corporation
00006 // 
00007 // Under terms of Contract DE-AC04-94AL85000, there is a non-exclusive
00008 // license for use of this work by or on behalf of the U.S. Government.
00009 // 
00010 // This library is free software; you can redistribute it and/or modify
00011 // it under the terms of the GNU Lesser General Public License as
00012 // published by the Free Software Foundation; either version 2.1 of the
00013 // License, or (at your option) any later version.
00014 //  
00015 // This library is distributed in the hope that it will be useful, but
00016 // WITHOUT ANY WARRANTY; without even the implied warranty of
00017 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00018 // Lesser General Public License for more details.
00019 //  
00020 // You should have received a copy of the GNU Lesser General Public
00021 // License along with this library; if not, write to the Free Software
00022 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
00023 // USA
00024 // Questions? Contact Roscoe A. Bartlett (rabartl@sandia.gov) 
00025 // 
00026 // ***********************************************************************
00027 // @HEADER
00028 
00029 #ifndef RSQP_ALGO_CONFIG_MAMA_JAMA_H
00030 #define RSQP_ALGO_CONFIG_MAMA_JAMA_H
00031 
00032 #include "MoochoPack_NLPAlgoConfig.hpp"
00033 #include "MoochoPack_NLPAlgo.hpp"
00034 #include "MoochoPack_DecompositionSystemStateStepBuilderStd.hpp"
00035 #include "OptionsFromStreamPack_OptionsFromStream.hpp"
00036 
00037 namespace MoochoPack {
00038 
00056 class NLPAlgoConfigMamaJama : public NLPAlgoConfig {
00057 public:
00058 
00060   NLPAlgoConfigMamaJama();
00061 
00063   ~NLPAlgoConfigMamaJama();
00064 
00067 
00078   void set_options( const options_ptr_t& options );
00080   const options_ptr_t& get_options() const;
00082   void config_algo_cntr(NLPAlgoContainer* algo_cntr, std::ostream* trase_out);
00084   void init_algo(NLPAlgoInterface* algo);
00085 
00087 
00088 public:
00089 
00092 
00094   enum EQuasiNewton {
00095     QN_AUTO, QN_BFGS, QN_PBFGS, QN_LBFGS, QN_LPBFGS };
00097   enum EHessianInitialization {
00098     INIT_HESS_AUTO, INIT_HESS_SERIALIZE, INIT_HESS_IDENTITY, INIT_HESS_FIN_DIFF_SCALE_IDENTITY
00099     , INIT_HESS_FIN_DIFF_SCALE_DIAGONAL, INIT_HESS_FIN_DIFF_SCALE_DIAGONAL_ABS };
00101   enum EQPSolverType {
00102     QP_AUTO, QP_QPSOL, QP_QPOPT, QP_QPKWIK, QP_QPSCHUR };
00104   enum ELineSearchMethod {
00105     LINE_SEARCH_AUTO, LINE_SEARCH_NONE, LINE_SEARCH_DIRECT
00106     , LINE_SEARCH_2ND_ORDER_CORRECT, LINE_SEARCH_WATCHDOG
00107     , LINE_SEARCH_FILTER };
00109   enum EMeritFunctionType {
00110     MERIT_FUNC_AUTO, MERIT_FUNC_L1, MERIT_FUNC_MOD_L1
00111     , MERIT_FUNC_MOD_L1_INCR };
00113   enum EL1PenaltyParamUpdate {
00114     L1_PENALTY_PARAM_AUTO, L1_PENALTY_PARAM_WITH_MULT
00115     , L1_PENALTY_PARAM_MULT_FREE };
00116 
00118 
00121 
00123   struct SOptionValues {
00124     // Constructor (sets default values)
00125     SOptionValues();
00126     // Variable Reduction,  Range/Null space decompositions
00127     value_type              max_basis_cond_change_frac_;    // If < , don't change default
00128     // Reduced Hessian Approximations
00129     bool                    exact_reduced_hessian_;
00130     EQuasiNewton            quasi_newton_;
00131     int                     num_lbfgs_updates_stored_;      // If < 0, don't change default
00132     bool                    lbfgs_auto_scaling_;
00133     EHessianInitialization  hessian_initialization_;
00134     // QP subproblem solvers
00135     EQPSolverType           qp_solver_type_;
00136     bool                    reinit_hessian_on_qp_fail_;
00137     // Line search methods
00138     ELineSearchMethod       line_search_method_;
00139     EMeritFunctionType      merit_function_type_;
00140     EL1PenaltyParamUpdate   l1_penalty_param_update_;
00141     int                     full_steps_after_k_;            // If < 0, do not use this option at all.
00142   };
00143 
00145 
00146 private:
00147 
00149   DecompositionSystemStateStepBuilderStd   decomp_sys_step_builder_;
00150 
00152   options_ptr_t      options_;
00153 
00155   SOptionValues       uov_; // options set by user
00156   SOptionValues       cov_; // current option values actually used
00157 
00158   // ///////////////////////////////////////////////////////
00159   // Private member functions
00160 
00162   static void readin_options(
00163     const OptionsFromStreamPack::OptionsFromStream& options
00164     , SOptionValues *option_values, std::ostream* trase_out );
00165 
00167   static void set_default_options(
00168     const SOptionValues& user_option_values
00169     , SOptionValues *current_option_values
00170     , std::ostream* trase_out );
00171 
00172 };  // end class NLPAlgoConfigMamaJama
00173 
00183 } // end namespace MoochoPack 
00184 
00185 #endif  // RSQP_ALGO_CONFIG_MAMA_JAMA_H

Generated on Thu Sep 18 12:34:28 2008 for MoochoPack : Framework for Large-Scale Optimization Algorithms by doxygen 1.3.9.1