IFPACK  Development
 All Classes Files Functions Variables Enumerations Friends
Ifpack_ValidParameters.cpp
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 // Redistribution and use in source and binary forms, with or without
00011 // modification, are permitted provided that the following conditions are
00012 // met:
00013 //
00014 // 1. Redistributions of source code must retain the above copyright
00015 // notice, this list of conditions and the following disclaimer.
00016 //
00017 // 2. Redistributions in binary form must reproduce the above copyright
00018 // notice, this list of conditions and the following disclaimer in the
00019 // documentation and/or other materials provided with the distribution.
00020 //
00021 // 3. Neither the name of the Corporation nor the names of the
00022 // contributors may be used to endorse or promote products derived from
00023 // this software without specific prior written permission.
00024 //
00025 // THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
00026 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
00027 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00028 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
00029 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
00030 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00031 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
00032 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
00033 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
00034 // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
00035 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00036 //
00037 // Questions? Contact Michael A. Heroux (maherou@sandia.gov)
00038 //
00039 // ***********************************************************************
00040 //@HEADER
00041 */
00042 
00043 #include "Ifpack_ValidParameters.h"
00044 
00045 Teuchos::ParameterList Ifpack_GetValidParameters()
00046 {
00047   Teuchos::ParameterList List; // empty list
00048 
00049   // ============================================================ //
00050   // Parameters are reported from each used file in IFPACK. Files //
00051   // are listed in alphabetical order, first all *.cpp, then *.h. //
00052   // Some options not very tested or documented anywhere          //
00053   // are not reported here.                                       //
00054   // ============================================================ //
00055   
00056   // Ifpack_Amesos.cpp
00057   List.set("amesos: solver type", "Amesos_Klu");
00058 
00059   // Ifpack_IC.cpp
00060   List.set("fact: level-of-fill", (int)1);
00061   List.set("fact: absolute threshold", (double)0.0);
00062   List.set("fact: relative threshold", (double)0.0);
00063   List.set("fact: drop tolerance", (double)0.0);
00064 
00065   // Ifpack_ICT.cpp
00066   List.set("fact: ict level-of-fill", (double)1.0);
00067   List.set("fact: absolute threshold", (double)0.0);
00068   List.set("fact: relative threshold", (double)1.0);
00069   List.set("fact: relax value", (double)0.0);
00070   List.set("fact: drop tolerance", (double)0.0);
00071 
00072   // Ifpack_ILU.cpp
00073   List.set("fact: level-of-fill", (int)0);
00074   List.set("fact: absolute threshold", (double)0.0);
00075   List.set("fact: relative threshold", (double)1.0);
00076   List.set("fact: relax value", (double)0.0);
00077 
00078   // Ifpack_ILUT.cpp
00079   List.set("fact: ilut level-of-fill", (double)1.0);
00080   List.set("fact: absolute threshold", (double)0.0);
00081   List.set("fact: relative threshold", (double)1.0);
00082   List.set("fact: relax value", (double)0.0);
00083 
00084 #ifdef HAVE_IFPACK_SUPERLU
00085   // Ifpack_SILU.cpp
00086   List.set("fact: drop tolerance",1e-4);
00087   List.set("fact: zero pivot threshold",1e-2);
00088   List.set("fact: maximum fill factor",10.0);
00089   List.set("fact: silu drop rule",9);
00090 #endif
00091 
00092   // Ifpack_METISPartitioner.cpp
00093   List.set("partitioner: local parts", (int)1);
00094   List.set("partitioner: overlap", (int)0);
00095   List.set("partitioner: print level", (int)0);
00096 
00097   // Ifpack_PointRelaxation.cpp
00098   List.set("relaxation: type", "Jacobi");
00099   List.set("relaxation: sweeps", (int)1);
00100   List.set("relaxation: damping factor", (double)1.0);
00101   List.set("relaxation: min diagonal value", (double)1.0);
00102   List.set("relaxation: zero starting solution", true);
00103   List.set("relaxation: backward mode",false);
00104   List.set("relaxation: use l1",false);
00105   List.set("relaxation: l1 eta",(double)1.5);
00106 
00107   // Ifpack_SPARSKIT.cpp
00108   List.set("fact: sparskit: lfil", (int)0);
00109   List.set("fact: sparskit: tol", (double)0.0);
00110   List.set("fact: sparskit: droptol", (double)0.0);
00111   List.set("fact: sparskit: permtol", (double)0.1);
00112   List.set("fact: sparskit: alph", (double)0.0);
00113   List.set("fact: sparskit: mbloc", (int)(-1));
00114   List.set("fact: sparskit: type", ("ILUT"));
00115 
00116   // Additive Schwarz preconditioner
00117   List.set("schwarz: compute condest", true);
00118   List.set("schwarz: combine mode", "Zero"); // use string mode for this
00119   List.set("schwarz: reordering type", "none");
00120   List.set("schwarz: filter singletons", false);
00121 
00122   // Ifpack_BlockRelaxation.h
00123   // List.set("relaxation: type", "Jacobi"); // already set
00124   // List.set("relaxation: sweeps", 1); // already set
00125   // List.get("relaxation: damping factor", 1.0); // already set
00126   // List.get("relaxation: zero starting solution", true); // already set
00127   List.set("partitioner: type", "greedy");
00128   List.set("partitioner: local parts", (int)1);
00129   List.set("partitioner: overlap", (int)0);
00130 
00131   // Ifpack_METISPartitioner.h
00132   List.set("partitioner: use symmetric graph", true);
00133 
00134   // Krylov smoother
00135   List.set("krylov: iterations",(int)5);
00136   List.set("krylov: tolerance",(double)0.001);
00137   List.set("krylov: solver",(int)1);
00138   List.set("krylov: preconditioner",(int)0);
00139   List.set("krylov: number of sweeps",(int)1);
00140   List.set("krylov: block size",(int)1);
00141   List.set("krylov: damping parameter",(double)1.0);
00142   List.set("krylov: zero starting solution",true);
00143 
00144   return(List);
00145 }
00146 
 All Classes Files Functions Variables Enumerations Friends