Seldon
Installation
Overview
Vectors
Dense Vectors
Sparse Vectors
Distributed Vectors
Functions
Matrices
Dense Matrices
Sparse Matrices
Sparse Complex Matrices
Functions
Sub-Matrices
Distributed Matrices
Miscellaneous
Other Structures
Vector2
Vector3
3-D Array
4-D Array
N-D Array
Allocators
Exceptions
Computations
Blas
Lapack
Direct solvers
Iterative solvers
Eigenvalue solvers
Index
computation
solver
preconditioner
HypreInline.cxx
1
#ifndef SELDON_FILE_HYPRE_INLINE_CXX
2
3
namespace
Seldon
4
{
5
7
template
<
class
T>
8
inline
void
HyprePreconditioner<T>::SetPreconditioner
(
int
type)
9
{
10
type_preconditioner = type;
11
}
12
13
15
template
<
class
T>
16
inline
void
HyprePreconditioner<T>::SetSmoother
(
int
type)
17
{
18
amg_smoother = type;
19
}
20
21
23
template
<
class
T>
24
inline
void
HyprePreconditioner<T>::SetLevelEuclid
(
int
lvl)
25
{
26
euclid_level = lvl;
27
}
28
29
31
template
<
class
T>
32
inline
void
HyprePreconditioner<T>::ShowMessages
()
33
{
34
print_level = 3;
35
}
36
38
template
<
class
T>
39
inline
void
HyprePreconditioner<T>
40
::Solve
(
const
VirtualMatrix<T>
& A,
const
Vector<T>
& r,
Vector<T>
& z)
41
{
42
Solve(SeldonNoTrans, A, r, z);
43
}
44
45
47
template
<
class
T>
48
inline
void
HyprePreconditioner<T>
49
::TransSolve
(
const
VirtualMatrix<T>
& A,
const
Vector<T>
& r,
Vector<T>
& z)
50
{
51
Solve(SeldonTrans, A, r, z);
52
}
53
54
}
55
56
#define SELDON_FILE_HYPRE_INLINE_CXX
57
#endif
58
Seldon::HyprePreconditioner::TransSolve
void TransSolve(const VirtualMatrix< T > &A, const Vector< T > &r, Vector< T > &z)
applies transpose preconditioning
Definition:
HypreInline.cxx:49
Seldon::Vector< T >
Seldon::HyprePreconditioner::SetLevelEuclid
void SetLevelEuclid(int lvl)
sets the level k of ILU(k) factorization
Definition:
HypreInline.cxx:24
Seldon::HyprePreconditioner::Solve
void Solve(const SeldonTranspose &trans, const VirtualMatrix< T > &A, const Vector< T > &r, Vector< T > &z)
applies preconditioning z = M r (or its transpose z = M^T r)
Definition:
Hypre.cxx:324
Seldon::HyprePreconditioner::SetSmoother
void SetSmoother(int type)
sets smoother to use for AMG
Definition:
HypreInline.cxx:16
Seldon::HyprePreconditioner::SetPreconditioner
void SetPreconditioner(int type)
sets which preconditioning to use (among choices proposed in hypre)
Definition:
HypreInline.cxx:8
Seldon
Seldon namespace.
Definition:
Array.cxx:24
Seldon::HyprePreconditioner::ShowMessages
void ShowMessages()
shows informations about preconditioning
Definition:
HypreInline.cxx:32
Seldon::VirtualMatrix
Abstract base class for all matrices.
Definition:
Matrix_Base.hxx:42