Stratimikos Version of the Day
Loading...
Searching...
No Matches
Thyra_AmesosTypes.hpp
1// @HEADER
2// *****************************************************************************
3// Stratimikos: Thyra-based strategies for linear solvers
4//
5// Copyright 2006 NTESS and the Stratimikos contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8// @HEADER
9
10#ifndef THYRA_AMESOS_TYPES_HPP
11#define THYRA_AMESOS_TYPES_HPP
12
13#include "Amesos_ConfigDefs.h"
14#include "Teuchos_StringToIntMap.hpp"
15
16namespace Thyra {
17
18namespace Amesos {
19
23enum ESolverType {
24 LAPACK
25#ifdef HAVE_AMESOS_KLU
26 ,KLU
27#endif
28#ifdef HAVE_AMESOS_UMFPACK
29 ,UMFPACK
30#endif
31#ifdef HAVE_AMESOS_SUPERLU
32 ,SUPERLU
33#endif
34#ifdef HAVE_AMESOS_SUPERLUDIST
35 ,SUPERLUDIST
36#endif
37#ifdef HAVE_AMESOS_TAUCS
38 ,TAUCS
39#endif
40#ifdef HAVE_AMESOS_PARDISO
41 ,PARDISO
42#endif
43#ifdef HAVE_AMESOS_PASTIX
44 ,PASTIX
45#endif
46#ifdef HAVE_AMESOS_PARAKLETE
47 ,PARAKLETE
48#endif
49#ifdef HAVE_AMESOS_MUMPS
50 ,MUMPS
51#endif
52#ifdef HAVE_AMESOS_SCALAPACK
53 ,SCALAPACK
54#endif
55#ifdef HAVE_AMESOS_DSCPACK
56 ,DSCPACK
57#endif
58};
59
63const int numSolverTypes = 1 // LAPACK
64#ifdef HAVE_AMESOS_KLU
65+1
66#endif
67#ifdef HAVE_AMESOS_UMFPACK
68+1
69#endif
70#ifdef HAVE_AMESOS_SUPERLU
71+1
72#endif
73#ifdef HAVE_AMESOS_SUPERLUDIST
74+1
75#endif
76#ifdef HAVE_AMESOS_TAUCS
77+1
78#endif
79#ifdef HAVE_AMESOS_PARDISO
80+1
81#endif
82#ifdef HAVE_AMESOS_PASTIX
83+1
84#endif
85#ifdef HAVE_AMESOS_PARAKLETE
86+1
87#endif
88#ifdef HAVE_AMESOS_MUMPS
89+1
90#endif
91#ifdef HAVE_AMESOS_SCALAPACK
92+1
93#endif
94#ifdef HAVE_AMESOS_DSCPACK
95+1
96#endif
97;
98
102extern const ESolverType solverTypeValues[numSolverTypes];
103
107extern const char* solverTypeNames[numSolverTypes];
108
112extern const bool supportsUnsymmetric[numSolverTypes];
113
117inline const char* toString(const ESolverType solverType)
118{ return solverTypeNames[solverType]; }
119
123extern Teuchos::StringToIntMap solverTypeNameToEnumMap;
124
128enum ERefactorizationPolicy {
129 REPIVOT_ON_REFACTORIZATION
130 ,NO_PIVOT_ON_REFACTORIZATION
131};
132
136const int numRefactorizationPolices = 2;
137
141extern const ERefactorizationPolicy refactorizationPolicyValues[numRefactorizationPolices];
142
144extern const char* refactorizationPolicyNames[numRefactorizationPolices];
145
149inline const char* toString(const ERefactorizationPolicy refactorizationPolicy)
150{ return refactorizationPolicyNames[refactorizationPolicy]; }
151
155extern Teuchos::StringToIntMap refactorizationPolicyNameToEnumMap;
156
157} // namespace Amesos
158
159} // namespace Thyra
160
161#endif // THYRA_AMESOS_TYPES_HPP
std::string toString(const int &x)

Generated for Stratimikos by doxygen 1.9.8