MueLu
Version of the Day
Toggle main menu visibility
Loading...
Searching...
No Matches
MueLu_PgPFactory_decl.hpp
Go to the documentation of this file.
1
// @HEADER
2
// *****************************************************************************
3
// MueLu: A package for multigrid based preconditioning
4
//
5
// Copyright 2012 NTESS and the MueLu contributors.
6
// SPDX-License-Identifier: BSD-3-Clause
7
// *****************************************************************************
8
// @HEADER
9
10
#ifndef MUELU_PGPFACTORY_DECL_HPP_
11
#define MUELU_PGPFACTORY_DECL_HPP_
12
13
#include <Xpetra_Vector_fwd.hpp>
14
#include <Xpetra_VectorFactory_fwd.hpp>
15
#include <Xpetra_Matrix_fwd.hpp>
16
#include <Xpetra_Import_fwd.hpp>
17
#include <Xpetra_ImportFactory_fwd.hpp>
18
#include <Xpetra_Export_fwd.hpp>
19
#include <Xpetra_ExportFactory_fwd.hpp>
20
21
#include "
MueLu_ConfigDefs.hpp
"
22
23
#include "
MueLu_PerfUtils_fwd.hpp
"
24
#include "MueLu_PFactory.hpp"
25
#include "
MueLu_Utilities_fwd.hpp
"
26
27
namespace
MueLu
{
28
29
/* Options defining how to pick-up the next root node in the local aggregation procedure */
30
enum
MinimizationNorm
{
31
ANORM
= 0,
/* A norm */
32
L2NORM
= 1,
/* L2 norm */
33
DINVANORM
= 2
/* Dinv A norm */
34
};
35
41
42
template
<
class
Scalar
=
DefaultScalar
,
43
class
LocalOrdinal
=
DefaultLocalOrdinal
,
44
class
GlobalOrdinal
=
DefaultGlobalOrdinal
,
45
class
Node
=
DefaultNode
>
46
class
PgPFactory
:
public
PFactory
{
47
#undef MUELU_PGPFACTORY_SHORT
48
#include "
MueLu_UseShortNames.hpp
"
49
50
public
:
52
53
57
PgPFactory
() {}
58
60
virtual
~PgPFactory
() {}
61
63
65
66
67
RCP<const ParameterList>
GetValidParameterList
()
const
;
68
70
void
SetMinimizationMode
(
MinimizationNorm
minnorm);
71
73
MinimizationNorm
GetMinimizationMode
();
75
77
78
79
void
DeclareInput
(
Level
& fineLevel,
Level
& coarseLevel)
const
;
81
83
84
90
void
Build
(
Level
& fineLevel,
Level
& coarseLevel)
const
;
91
92
void
BuildP
(
Level
& fineLevel,
Level
& coarseLevel)
const
;
93
95
96
void
ReUseDampingParameters
(
bool
bReuse);
97
98
private
:
99
void
MultiplySelfAll
(
const
RCP<Matrix>& Op, Teuchos::RCP<Xpetra::Vector<Scalar, LocalOrdinal, GlobalOrdinal, Node> >& InnerProdVec)
const
;
100
101
void
MultiplyAll
(
const
RCP<Matrix>& left,
const
RCP<Matrix>& right, Teuchos::RCP<Xpetra::Vector<Scalar, LocalOrdinal, GlobalOrdinal, Node> >& InnerProdVec)
const
;
102
103
void
ComputeRowBasedOmega
(
Level
& fineLevel,
Level
& coarseLevel,
const
RCP<Matrix>& A,
const
RCP<Matrix>& P0,
const
RCP<Matrix>& DinvAP0, RCP<Xpetra::Vector<Scalar, LocalOrdinal, GlobalOrdinal, Node> >& RowBasedOmega)
const
;
104
105
private
:
107
std::string
diagonalView_
;
// TODO do we need this?
108
};
109
110
}
// namespace MueLu
111
112
#define MUELU_PGPFACTORY_SHORT
113
#endif
/* MUELU_PGPFACTORY_DECL_HPP_ */
MueLu_ConfigDefs.hpp
MueLu_PerfUtils_fwd.hpp
LocalOrdinal
MueLu::DefaultLocalOrdinal LocalOrdinal
Definition
MueLu_UseDefaultTypes.hpp:13
Scalar
MueLu::DefaultScalar Scalar
Definition
MueLu_UseDefaultTypes.hpp:12
GlobalOrdinal
MueLu::DefaultGlobalOrdinal GlobalOrdinal
Definition
MueLu_UseDefaultTypes.hpp:14
Node
MueLu::DefaultNode Node
Definition
MueLu_UseDefaultTypes.hpp:15
MueLu_UseShortNames.hpp
MueLu_Utilities_fwd.hpp
MueLu::Level
Class that holds all level-specific information.
Definition
MueLu_Level.hpp:63
MueLu::PFactory::PFactory
PFactory()
Constructor.
Definition
MueLu_PFactory_decl.hpp:37
MueLu::PgPFactory< Scalar, LocalOrdinal, GlobalOrdinal, Node >::diagonalView_
std::string diagonalView_
Definition
MueLu_PgPFactory_decl.hpp:107
MueLu::PgPFactory::GetValidParameterList
RCP< const ParameterList > GetValidParameterList() const
Return a const parameter list of valid parameters that setParameterList() will accept.
Definition
MueLu_PgPFactory_def.hpp:34
MueLu::PgPFactory::Build
void Build(Level &fineLevel, Level &coarseLevel) const
Build method.
Definition
MueLu_PgPFactory_def.hpp:91
MueLu::PgPFactory::~PgPFactory
virtual ~PgPFactory()
Destructor.
Definition
MueLu_PgPFactory_decl.hpp:60
MueLu::PgPFactory::ReUseDampingParameters
void ReUseDampingParameters(bool bReuse)
Definition
MueLu_PgPFactory_def.hpp:651
MueLu::PgPFactory::MultiplyAll
void MultiplyAll(const RCP< Matrix > &left, const RCP< Matrix > &right, Teuchos::RCP< Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > > &InnerProdVec) const
Definition
MueLu_PgPFactory_def.hpp:433
MueLu::PgPFactory::DeclareInput
void DeclareInput(Level &fineLevel, Level &coarseLevel) const
Input.
Definition
MueLu_PgPFactory_def.hpp:57
MueLu::PgPFactory::ComputeRowBasedOmega
void ComputeRowBasedOmega(Level &fineLevel, Level &coarseLevel, const RCP< Matrix > &A, const RCP< Matrix > &P0, const RCP< Matrix > &DinvAP0, RCP< Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > > &RowBasedOmega) const
Definition
MueLu_PgPFactory_def.hpp:211
MueLu::PgPFactory::PgPFactory
PgPFactory()
Constructor. User can supply a factory for generating the tentative prolongator.
Definition
MueLu_PgPFactory_decl.hpp:57
MueLu::PgPFactory::SetMinimizationMode
void SetMinimizationMode(MinimizationNorm minnorm)
Set minimization mode (L2NORM for cheapest, ANORM more expensive, DINVANORM = default).
Definition
MueLu_PgPFactory_def.hpp:46
MueLu::PgPFactory::GetMinimizationMode
MinimizationNorm GetMinimizationMode()
return minimization mode
Definition
MueLu_PgPFactory_def.hpp:51
MueLu::PgPFactory::BuildP
void BuildP(Level &fineLevel, Level &coarseLevel) const
Abstract Build method.
Definition
MueLu_PgPFactory_def.hpp:646
MueLu::PgPFactory::MultiplySelfAll
void MultiplySelfAll(const RCP< Matrix > &Op, Teuchos::RCP< Xpetra::Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > > &InnerProdVec) const
Definition
MueLu_PgPFactory_def.hpp:396
MueLu
Namespace for MueLu classes and methods.
Definition
MueLu_BrickAggregationFactory_decl.hpp:42
MueLu::DefaultNode
Tpetra::KokkosClassic::DefaultNode::DefaultNodeType DefaultNode
Definition
MueLu_Details_DefaultTypes.hpp:32
MueLu::DefaultGlobalOrdinal
int DefaultGlobalOrdinal
Definition
MueLu_Details_DefaultTypes.hpp:29
MueLu::DefaultLocalOrdinal
int DefaultLocalOrdinal
Definition
MueLu_Details_DefaultTypes.hpp:22
MueLu::DefaultScalar
Tpetra::Details::DefaultTypes::scalar_type DefaultScalar
Definition
MueLu_Details_DefaultTypes.hpp:20
MueLu::MinimizationNorm
MinimizationNorm
Definition
MueLu_PgPFactory_decl.hpp:30
MueLu::ANORM
@ ANORM
Definition
MueLu_PgPFactory_decl.hpp:31
MueLu::L2NORM
@ L2NORM
Definition
MueLu_PgPFactory_decl.hpp:32
MueLu::DINVANORM
@ DINVANORM
Definition
MueLu_PgPFactory_decl.hpp:33
src
Transfers
Petrov-Galerkin-SA
MueLu_PgPFactory_decl.hpp
Generated by
1.17.0