Ifpack.h

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 IFPACK_H
00031 #define IFPACK_H
00032 
00033 #include "Ifpack_ConfigDefs.h"
00034 #include "Ifpack_Preconditioner.h"
00035 
00037 
00117 class Ifpack {
00118 public:
00119 
00121   enum EPrecType {
00122     POINT_RELAXATION
00123     ,POINT_RELAXATION_STAND_ALONE
00124     ,BLOCK_RELAXATION
00125     ,BLOCK_RELAXATION_STAND_ALONE
00126     ,BLOCK_RELAXATION_STAND_ALONE_ILU
00127 #ifdef HAVE_IFPACK_AMESOS
00128     ,BLOCK_RELAXATION_STAND_ALONE_AMESOS
00129     ,BLOCK_RELAXATION_AMESOS
00130     ,AMESOS
00131     ,AMESOS_STAND_ALONE
00132 #endif // HAVE_IFPACK_AMESOS
00133     ,IC
00134     ,IC_STAND_ALONE
00135     ,ICT
00136     ,ICT_STAND_ALONE
00137     ,ILU
00138     ,ILU_STAND_ALONE
00139     ,ILUT
00140     ,ILUT_STAND_ALONE
00141 #ifdef HAVE_IFPACK_SPARSKIT
00142     ,SPARSKIT
00143 #endif // HAVE_IFPACK_SPARSKIT
00144     ,CHEBYSHEV
00145   };
00146 
00148   static const int numPrecTypes =
00149     +5
00150 #ifdef HAVE_IFPACK_AMESOS
00151     +4
00152 #endif
00153     +8
00154 #ifdef HAVE_IFPACK_SPARSKIT
00155     +1
00156 #endif
00157     +1
00158     ;
00159 
00161   static const EPrecType precTypeValues[numPrecTypes];
00162 
00164   static const char* precTypeNames[numPrecTypes];
00165 
00168   static const bool supportsUnsymmetric[numPrecTypes];
00169 
00172   static const char* toString(const EPrecType precType)
00173       { return precTypeNames[precType]; }
00174 
00184   static Ifpack_Preconditioner* Create(
00185     EPrecType PrecType, Epetra_RowMatrix* Matrix, const int overlap = 0
00186     );
00187 
00202   Ifpack_Preconditioner* Create(const string PrecType,
00203                 Epetra_RowMatrix* Matrix,
00204                 const int overlap = 0);
00205 
00213   int SetParameters(int argc, char* argv[],
00214                     Teuchos::ParameterList& List, string& PrecType,
00215                     int& Overlap);
00216 
00217 };
00218 
00219 #endif

Generated on Wed May 12 21:46:02 2010 for IFPACK by  doxygen 1.4.7