00001 /*@HEADER 00002 // *********************************************************************** 00003 // 00004 // Ifpack: Object-Oriented Algebraic Preconditioner Package 00005 // Copyright (2002) 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 Michael A. Heroux (maherou@sandia.gov) 00025 // 00026 // *********************************************************************** 00027 //@HEADER 00028 */ 00029 00030 #ifndef _ifp_parameters_h_ 00031 #define _ifp_parameters_h_ 00032 00033 #include "Ifpack_config.h" 00034 00035 #include <Ifpack_ConfigDefs.h> 00036 00037 #include <Teuchos_map.hpp> 00038 #include <Teuchos_ParameterList.hpp> 00039 #include <Epetra_CombineMode.h> 00040 00041 namespace Ifpack { 00042 00043 //define enum values to which parameter names will be mapped. 00044 enum parameter { 00045 //parameters of type double 00046 absolute_threshold, 00047 relative_threshold, 00048 drop_tolerance, 00049 fill_tolerance, 00050 relax_value, 00051 00052 //parameters of type int 00053 //(if you add or remove int parameters, be sure to 00054 //update FIRST_INT_PARAM and LAST_INT_PARAM macros below, as 00055 //they are used below and in ifp_parameters.cpp) 00056 level_fill, 00057 level_overlap, 00058 num_steps, 00059 00060 //mixed type parameters 00061 use_reciprocal, 00062 overlap_mode 00063 }; 00064 00065 #define FIRST_INT_PARAM Ifpack::level_fill 00066 #define LAST_INT_PARAM Ifpack::num_steps 00067 00068 //define struct with union of all Ifpack parameters 00069 struct param_struct { 00070 int int_params[LAST_INT_PARAM-FIRST_INT_PARAM+1]; 00071 double double_params[FIRST_INT_PARAM]; 00072 bool use_reciprocal; 00073 Epetra_CombineMode overlap_mode; 00074 }; 00075 00076 Teuchos::map<string,parameter>& key_map(); 00077 00078 IFPACK_DEPRECATED void initialize_string_map(); 00079 00080 string upper_case(const string& s); 00081 00082 IFPACK_DEPRECATED void set_parameters(const Teuchos::ParameterList& parameterlist, 00083 param_struct& params, 00084 bool cerr_warning_if_unused=false); 00085 00086 }//namespace Ifpack 00087 00088 #endif //_ifp_parameters_h_ 00089
1.7.6.1