libmesh解析
本工作只是尝试解析原libmesh的代码,供学习使用
 全部  命名空间 文件 函数 变量 类型定义 枚举 枚举值 友元 
Public 成员函数 | 静态 Public 成员函数 | Protected 类型 | Protected 成员函数 | Protected 属性 | 静态 Protected 属性 | 所有成员列表
libMesh::TrilinosPreconditioner< T > 模板类 参考

这个类提供了一个接口,用于使用Trilinos提供的预条件器套件。 所有重写的虚拟函数在preconditioner.h中有文档说明。 更多...

#include <trilinos_preconditioner.h>

类 libMesh::TrilinosPreconditioner< T > 继承关系图:
[图例]

Public 成员函数

 TrilinosPreconditioner (const libMesh::Parallel::Communicator &comm)
 构造函数。初始化 PetscPreconditioner 数据结构 更多...
 
virtual ~TrilinosPreconditioner ()
 析构函数。 更多...
 
virtual void apply (const NumericVector< T > &x, NumericVector< T > &y) override
 应用预条件器。 更多...
 
virtual void clear () override
 清除预条件器。 更多...
 
virtual void init () override
 初始化预条件器。 更多...
 
void set_params (Teuchos::ParameterList &list)
 存储 ParameterList list 的副本。 更多...
 
Epetra_FECrsMatrix * mat ()
 返回实际的 Trilinos 预条件器对象。 更多...
 
void set_preconditioner_type (const PreconditionerType &preconditioner_type)
 根据 libMesh PreconditionerType 设置 Trilinos 预条件器。 更多...
 
void compute ()
 计算预条件器。在 Trilinos 中,我们需要显式调用此函数。 更多...
 
bool initialized () const
 
virtual void setup ()
 每当 "操作可能已更改" 时都会调用此函数。 更多...
 
void set_matrix (SparseMatrix< Number > &mat)
 设置要进行预处理的矩阵。 更多...
 
PreconditionerType type () const
 
void set_type (const PreconditionerType pct)
 设置要使用的预处理器类型。 更多...
 

静态 Public 成员函数

static std::unique_ptr
< Preconditioner< T > > 
build_preconditioner (const libMesh::Parallel::Communicator &comm, const SolverPackage solver_package=libMesh::default_solver_package())
 构建一个 Preconditioner,使用由 solver_package 指定的线性求解器软件包, 并以 std::unique_ptr 包装结果以确保安全性。 更多...
 
static std::string get_info ()
 Gets a string containing the reference information. 更多...
 
static void print_info (std::ostream &out_stream=libMesh::out)
 Prints the reference information, by default to libMesh::out. 更多...
 
static unsigned int n_objects ()
 Prints the number of outstanding (created, but not yet destroyed) objects. 更多...
 
static void enable_print_counter_info ()
 Methods to enable/disable the reference counter output from print_info() 更多...
 
static void disable_print_counter_info ()
 

Protected 类型

typedef std::map< std::string,
std::pair< unsigned int,
unsigned int > > 
Counts
 Data structure to log the information. 更多...
 

Protected 成员函数

virtual int SetUseTranspose (bool UseTranspose) override
 
virtual int Apply (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const override
 
virtual int ApplyInverse (const Epetra_MultiVector &r, Epetra_MultiVector &z) const override
 
virtual double NormInf () const override
 
virtual const char * Label () const override
 
virtual bool UseTranspose () const override
 
virtual bool HasNormInf () const override
 
virtual const Epetra_Comm & Comm () const override
 
virtual const Epetra_Map & OperatorDomainMap () const override
 
virtual const Epetra_Map & OperatorRangeMap () const override
 
void increment_constructor_count (const std::string &name) noexcept
 Increments the construction counter. 更多...
 
void increment_destructor_count (const std::string &name) noexcept
 Increments the destruction counter. 更多...
 

Protected 属性

Epetra_Operator * _prec
 Trilinos 预条件器。 更多...
 
Epetra_FECrsMatrix * _mat
 从 _matrix 对象中提取出来的 Trilinos 矩阵。 更多...
 
Teuchos::ParameterList _param_list
 用于构建预条件器的参数列表。 更多...
 
SparseMatrix< T > * _matrix
 要进行预处理的矩阵 P... 更多...
 
PreconditionerType _preconditioner_type
 枚举类型,表示要使用的预处理器类型。 更多...
 
bool _is_initialized
 指示数据结构是否已初始化的标志。 更多...
 

静态 Protected 属性

static Counts _counts
 Actually holds the data. 更多...
 
static Threads::atomic
< unsigned int > 
_n_objects
 The number of objects. 更多...
 
static Threads::spin_mutex _mutex
 Mutual exclusion object to enable thread-safe reference counting. 更多...
 
static bool _enable_print_counter = true
 Flag to control whether reference count information is printed when print_info is called. 更多...
 

详细描述

template<typename T>
class libMesh::TrilinosPreconditioner< T >

这个类提供了一个接口,用于使用Trilinos提供的预条件器套件。 所有重写的虚拟函数在preconditioner.h中有文档说明。

作者
David Andrs
日期
2011

在文件 trilinos_preconditioner.h61 行定义.

成员类型定义说明

typedef std::map<std::string, std::pair<unsigned int, unsigned int> > libMesh::ReferenceCounter::Counts
protectedinherited

Data structure to log the information.

The log is identified by the class name.

在文件 reference_counter.h119 行定义.

构造及析构函数说明

template<typename T >
libMesh::TrilinosPreconditioner< T >::TrilinosPreconditioner ( const libMesh::Parallel::Communicator &  comm)
inline

构造函数。初始化 PetscPreconditioner 数据结构

参数
comm通信器对象,用于并行通信。

在文件 trilinos_preconditioner.h181 行定义.

181  :
182  Preconditioner<T>(comm),
183  _prec(nullptr),
184  _mat(nullptr)
185 {
186 }
Epetra_FECrsMatrix * _mat
从 _matrix 对象中提取出来的 Trilinos 矩阵。
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
libMesh::TrilinosPreconditioner< T >::~TrilinosPreconditioner ( )
inlinevirtual

析构函数。

在文件 trilinos_preconditioner.h192 行定义.

193 {
194  this->clear ();
195 }
virtual void clear() override
清除预条件器。

成员函数说明

template<typename T >
void libMesh::TrilinosPreconditioner< T >::apply ( const NumericVector< T > &  x,
NumericVector< T > &  y 
)
overridevirtual

应用预条件器。

参数
x输入向量。
y输出向量。

实现了 libMesh::Preconditioner< T >.

在文件 trilinos_preconditioner.C49 行定义.

51 {
52 }
template<typename T >
int libMesh::TrilinosPreconditioner< T >::Apply ( const Epetra_MultiVector &  X,
Epetra_MultiVector &  Y 
) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C197 行定义.

198 {
199  return _prec->Apply(X, Y);
200 }
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
int libMesh::TrilinosPreconditioner< T >::ApplyInverse ( const Epetra_MultiVector &  r,
Epetra_MultiVector &  z 
) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C204 行定义.

205 {
206  return _prec->ApplyInverse(r, z);
207 }
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
std::unique_ptr< Preconditioner< T > > libMesh::Preconditioner< T >::build_preconditioner ( const libMesh::Parallel::Communicator &  comm,
const SolverPackage  solver_package = libMesh::default_solver_package() 
)
staticinherited

构建一个 Preconditioner,使用由 solver_package 指定的线性求解器软件包, 并以 std::unique_ptr 包装结果以确保安全性。

参数
comm通信器对象
solver_package求解器软件包(默认为 libMesh 的默认求解器软件包)
返回
返回一个包含 Preconditioner 指针的 std::unique_ptr

在文件 preconditioner.C50 行定义.

参考 libMesh::EIGEN_SOLVERS, libMesh::libmesh_ignore() , 以及 libMesh::TRILINOS_SOLVERS.

52 {
53  // Avoid unused parameter warnings when no solver packages are enabled.
54  libmesh_ignore(comm);
55 
56  // Build and return the appropriate Preconditioner object.
57  switch (solver_package)
58  {
59 
60 #ifdef LIBMESH_HAVE_PETSC
61  case PETSC_SOLVERS:
62  {
63  return std::make_unique<PetscPreconditioner<T>>(comm);
64  }
65 #endif
66 
67 #ifdef LIBMESH_TRILINOS_HAVE_EPETRA
68  case TRILINOS_SOLVERS:
69  return std::make_unique<TrilinosPreconditioner<T>>(comm);
70 #endif
71 
72 #ifdef LIBMESH_HAVE_EIGEN
73  case EIGEN_SOLVERS:
74  return std::make_unique<EigenPreconditioner<T>>(comm);
75 #endif
76 
77  default:
78  libmesh_error_msg("ERROR: Unrecognized solver package: " << solver_package);
79  }
80 }
EIGEN_SOLVERS
Definition: libmesh.C:249
TRILINOS_SOLVERS
Definition: libmesh.C:247
void libmesh_ignore(const Args &...)
template<typename T >
virtual void libMesh::TrilinosPreconditioner< T >::clear ( )
inlineoverridevirtual

清除预条件器。

重载 libMesh::Preconditioner< T > .

在文件 trilinos_preconditioner.h90 行定义.

90 {}
template<typename T >
const Epetra_Comm & libMesh::TrilinosPreconditioner< T >::Comm ( ) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C239 行定义.

240 {
241  return _prec->Comm();
242 }
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
void libMesh::TrilinosPreconditioner< T >::compute ( )

计算预条件器。在 Trilinos 中,我们需要显式调用此函数。

在文件 trilinos_preconditioner.C85 行定义.

86 {
87 #ifdef LIBMESH_TRILINOS_HAVE_IFPACK
88  Ifpack_Preconditioner * ifpack = nullptr;
89 #endif
90 
91 #ifdef LIBMESH_TRILINOS_HAVE_ML
92  ML_Epetra::MultiLevelPreconditioner * ml = nullptr;
93 #endif
94 
95  switch (this->_preconditioner_type)
96  {
97 #ifdef LIBMESH_TRILINOS_HAVE_IFPACK
98  // IFPACK preconditioners
99  case ILU_PRECOND:
100  case SOR_PRECOND:
101  ifpack = dynamic_cast<Ifpack_Preconditioner *>(_prec);
102  ifpack->Compute();
103  break;
104 #endif
105 
106 #ifdef LIBMESH_TRILINOS_HAVE_ML
107  // ML preconditioners
108  case AMG_PRECOND:
109  ml = dynamic_cast<ML_Epetra::MultiLevelPreconditioner *>(_prec);
110  ml->ComputePreconditioner();
111  break;
112 #endif
113 
114  default:
115  // If we made it here, there were no TrilinosPreconditioners
116  // active, so that's probably an error.
117  libmesh_error_msg("ERROR: No valid TrilinosPreconditioners available!");
118  break;
119  }
120 }
PreconditionerType _preconditioner_type
枚举类型,表示要使用的预处理器类型。
Epetra_Operator * _prec
Trilinos 预条件器。
void libMesh::ReferenceCounter::disable_print_counter_info ( )
staticinherited

在文件 reference_counter.C100 行定义.

参考 libMesh::ReferenceCounter::_enable_print_counter.

101 {
102  _enable_print_counter = false;
103  return;
104 }
static bool _enable_print_counter
Flag to control whether reference count information is printed when print_info is called...
void libMesh::ReferenceCounter::enable_print_counter_info ( )
staticinherited

Methods to enable/disable the reference counter output from print_info()

在文件 reference_counter.C94 行定义.

参考 libMesh::ReferenceCounter::_enable_print_counter.

95 {
96  _enable_print_counter = true;
97  return;
98 }
static bool _enable_print_counter
Flag to control whether reference count information is printed when print_info is called...
std::string libMesh::ReferenceCounter::get_info ( )
staticinherited

Gets a string containing the reference information.

在文件 reference_counter.C47 行定义.

参考 libMesh::ReferenceCounter::_counts.

参考自 libMesh::ReferenceCounter::print_info().

48 {
49 #if defined(LIBMESH_ENABLE_REFERENCE_COUNTING) && defined(DEBUG)
50 
51  std::ostringstream oss;
52 
53  oss << '\n'
54  << " ---------------------------------------------------------------------------- \n"
55  << "| Reference count information |\n"
56  << " ---------------------------------------------------------------------------- \n";
57 
58  for (const auto & [name, cd] : _counts)
59  oss << "| " << name << " reference count information:\n"
60  << "| Creations: " << cd.first << '\n'
61  << "| Destructions: " << cd.second << '\n';
62 
63  oss << " ---------------------------------------------------------------------------- \n";
64 
65  return oss.str();
66 
67 #else
68 
69  return "";
70 
71 #endif
72 }
static Counts _counts
Actually holds the data.
template<typename T >
bool libMesh::TrilinosPreconditioner< T >::HasNormInf ( ) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C232 行定义.

233 {
234  return _prec->HasNormInf();
235 }
Epetra_Operator * _prec
Trilinos 预条件器。
void libMesh::ReferenceCounter::increment_constructor_count ( const std::string &  name)
inlineprotectednoexceptinherited

Increments the construction counter.

Should be called in the constructor of any derived class that will be reference counted.

在文件 reference_counter.h183 行定义.

参考 libMesh::err.

参考自 libMesh::ReferenceCountedObject< SparseMatrix< T > >::ReferenceCountedObject().

184 {
185  libmesh_try
186  {
187  Threads::spin_mutex::scoped_lock lock(Threads::spin_mtx);
188  std::pair<unsigned int, unsigned int> & p = _counts[name];
189  p.first++;
190  }
191  libmesh_catch (...)
192  {
193  auto stream = libMesh::err.get();
194  stream->exceptions(stream->goodbit); // stream must not throw
195  libMesh::err << "Encountered unrecoverable error while calling "
196  << "ReferenceCounter::increment_constructor_count() "
197  << "for a(n) " << name << " object." << std::endl;
198  std::terminate();
199  }
200 }
OStreamProxy err
static Counts _counts
Actually holds the data.
void libMesh::ReferenceCounter::increment_destructor_count ( const std::string &  name)
inlineprotectednoexceptinherited

Increments the destruction counter.

Should be called in the destructor of any derived class that will be reference counted.

在文件 reference_counter.h207 行定义.

参考 libMesh::err.

参考自 libMesh::ReferenceCountedObject< SparseMatrix< T > >::~ReferenceCountedObject().

208 {
209  libmesh_try
210  {
211  Threads::spin_mutex::scoped_lock lock(Threads::spin_mtx);
212  std::pair<unsigned int, unsigned int> & p = _counts[name];
213  p.second++;
214  }
215  libmesh_catch (...)
216  {
217  auto stream = libMesh::err.get();
218  stream->exceptions(stream->goodbit); // stream must not throw
219  libMesh::err << "Encountered unrecoverable error while calling "
220  << "ReferenceCounter::increment_destructor_count() "
221  << "for a(n) " << name << " object." << std::endl;
222  std::terminate();
223  }
224 }
OStreamProxy err
static Counts _counts
Actually holds the data.
template<typename T >
void libMesh::TrilinosPreconditioner< T >::init ( )
overridevirtual

初始化预条件器。

重载 libMesh::Preconditioner< T > .

在文件 trilinos_preconditioner.C58 行定义.

参考 libMesh::libMeshPrivateData::_is_initialized , 以及 libMesh::EpetraMatrix< T >::mat().

59 {
60  libmesh_error_msg_if(!this->_matrix, "ERROR: No matrix set for PetscPreconditioner, but init() called");
61 
62  // Clear the preconditioner in case it has been created in the past
63  if (!this->_is_initialized)
64  {
65  EpetraMatrix<T> * matrix = cast_ptr<EpetraMatrix<T> *, SparseMatrix<T>>(this->_matrix);
66  _mat = matrix->mat();
67  }
68 
70 
71  this->_is_initialized = true;
72 }
PreconditionerType _preconditioner_type
枚举类型,表示要使用的预处理器类型。
void set_preconditioner_type(const PreconditionerType &preconditioner_type)
根据 libMesh PreconditionerType 设置 Trilinos 预条件器。
Epetra_FECrsMatrix * _mat
从 _matrix 对象中提取出来的 Trilinos 矩阵。
bool _is_initialized
指示数据结构是否已初始化的标志。
SparseMatrix< T > * _matrix
要进行预处理的矩阵 P...
template<typename T >
bool libMesh::Preconditioner< T >::initialized ( ) const
inlineinherited
返回
如果数据结构已初始化,则返回 true,否则返回 false。

在文件 preconditioner.h87 行定义.

参考 libMesh::Preconditioner< T >::_is_initialized.

87 { return _is_initialized; }
bool _is_initialized
指示数据结构是否已初始化的标志。
template<typename T >
const char * libMesh::TrilinosPreconditioner< T >::Label ( ) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C218 行定义.

219 {
220  return _prec->Label();
221 }
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
Epetra_FECrsMatrix* libMesh::TrilinosPreconditioner< T >::mat ( )
inline

返回实际的 Trilinos 预条件器对象。

返回
Trilinos 预条件器对象的指针。

在文件 trilinos_preconditioner.h109 行定义.

参考 libMesh::TrilinosPreconditioner< T >::_mat.

109 { return _mat; }
Epetra_FECrsMatrix * _mat
从 _matrix 对象中提取出来的 Trilinos 矩阵。
static unsigned int libMesh::ReferenceCounter::n_objects ( )
inlinestaticinherited

Prints the number of outstanding (created, but not yet destroyed) objects.

在文件 reference_counter.h85 行定义.

参考 libMesh::ReferenceCounter::_n_objects.

参考自 libMesh::LibMeshInit::~LibMeshInit().

86  { return _n_objects; }
static Threads::atomic< unsigned int > _n_objects
The number of objects.
template<typename T >
double libMesh::TrilinosPreconditioner< T >::NormInf ( ) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C211 行定义.

212 {
213  return _prec->NormInf();
214 }
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
const Epetra_Map & libMesh::TrilinosPreconditioner< T >::OperatorDomainMap ( ) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C246 行定义.

247 {
248  return _prec->OperatorDomainMap();
249 }
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
const Epetra_Map & libMesh::TrilinosPreconditioner< T >::OperatorRangeMap ( ) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C253 行定义.

254 {
255  return _prec->OperatorRangeMap();
256 }
Epetra_Operator * _prec
Trilinos 预条件器。
void libMesh::ReferenceCounter::print_info ( std::ostream &  out_stream = libMesh::out)
staticinherited

Prints the reference information, by default to libMesh::out.

在文件 reference_counter.C81 行定义.

参考 libMesh::ReferenceCounter::_enable_print_counter , 以及 libMesh::ReferenceCounter::get_info().

参考自 libMesh::LibMeshInit::~LibMeshInit().

82 {
84  out_stream << ReferenceCounter::get_info();
85 }
static std::string get_info()
Gets a string containing the reference information.
static bool _enable_print_counter
Flag to control whether reference count information is printed when print_info is called...
template<typename T >
void libMesh::Preconditioner< T >::set_matrix ( SparseMatrix< Number > &  mat)
inherited

设置要进行预处理的矩阵。

参数
mat要进行预处理的稀疏矩阵
返回

在文件 preconditioner.h174 行定义.

参考 libMesh::libMeshPrivateData::_is_initialized.

175 {
176  //如果矩阵发生变化,那么(可能)需要重新初始化。
177  _is_initialized = false;
178  _matrix = &mat;
179 }
bool _is_initialized
指示数据结构是否已初始化的标志。
SparseMatrix< T > * _matrix
要进行预处理的矩阵 P...
template<typename T >
void libMesh::TrilinosPreconditioner< T >::set_params ( Teuchos::ParameterList &  list)

存储 ParameterList list 的副本。

参数
list参数列表对象。

在文件 trilinos_preconditioner.C77 行定义.

78 {
79  _param_list = list;
80 }
Teuchos::ParameterList _param_list
用于构建预条件器的参数列表。
template<typename T >
void libMesh::TrilinosPreconditioner< T >::set_preconditioner_type ( const PreconditionerType &  preconditioner_type)

根据 libMesh PreconditionerType 设置 Trilinos 预条件器。

参数
preconditioner_typelibMesh 预条件器类型。
注解
不是所有的 libMesh 预条件器类型都受支持。

在文件 trilinos_preconditioner.C125 行定义.

126 {
127 #ifdef LIBMESH_TRILINOS_HAVE_IFPACK
128  Ifpack_Preconditioner * pc = nullptr;
129 #endif
130 
131 #ifdef LIBMESH_TRILINOS_HAVE_ML
132  ML_Epetra::MultiLevelPreconditioner * ml = nullptr;
133 #endif
134 
135  switch (preconditioner_type)
136  {
137  case IDENTITY_PRECOND:
138  // pc = new Ifpack_DiagPreconditioner();
139  break;
140 
141  case CHOLESKY_PRECOND:
142  break;
143 
144  case ICC_PRECOND:
145  break;
146 
147 #ifdef LIBMESH_TRILINOS_HAVE_IFPACK
148  case ILU_PRECOND:
149  pc = new Ifpack_ILU(_mat);
150  pc->SetParameters(_param_list);
151  pc->Initialize();
152  _prec = pc;
153  break;
154 #endif
155 
156  case LU_PRECOND:
157  break;
158 
159  case ASM_PRECOND:
160  break;
161 
162  case JACOBI_PRECOND:
163  break;
164 
165  case BLOCK_JACOBI_PRECOND:
166  break;
167 
168  case SOR_PRECOND:
169  break;
170 
171  case EISENSTAT_PRECOND:
172  break;
173 
174 #ifdef LIBMESH_TRILINOS_HAVE_ML
175  case AMG_PRECOND:
176  ml = new ML_Epetra::MultiLevelPreconditioner(*_mat, _param_list, false);;
177  _prec = ml;
178  break;
179 #endif
180 
181  default:
182  libmesh_error_msg("ERROR: Unsupported Trilinos Preconditioner: " << preconditioner_type << "\nContinuing with Trilinos defaults");
183  }
184 
185 }
Teuchos::ParameterList _param_list
用于构建预条件器的参数列表。
Epetra_FECrsMatrix * _mat
从 _matrix 对象中提取出来的 Trilinos 矩阵。
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
void libMesh::Preconditioner< T >::set_type ( const PreconditionerType  pct)
inherited

设置要使用的预处理器类型。

参数
pct预处理器类型
返回

在文件 preconditioner.h183 行定义.

参考 libMesh::libMeshPrivateData::_is_initialized.

184 {
185  //如果前置条件类型改变,我们(可能)需要重新初始化。
186  _is_initialized = false;
187  _preconditioner_type = pct;
188 }
PreconditionerType _preconditioner_type
枚举类型,表示要使用的预处理器类型。
bool _is_initialized
指示数据结构是否已初始化的标志。
template<typename T >
virtual void libMesh::Preconditioner< T >::setup ( )
inlinevirtualinherited

每当 "操作可能已更改" 时都会调用此函数。

这是您需要填充预处理矩阵的地方。

返回

在文件 preconditioner.h120 行定义.

120 {}
template<typename T >
int libMesh::TrilinosPreconditioner< T >::SetUseTranspose ( bool  UseTranspose)
overrideprotectedvirtual

在文件 trilinos_preconditioner.C190 行定义.

191 {
192  return _prec->SetUseTranspose(UseTranspose);
193 }
virtual bool UseTranspose() const override
Epetra_Operator * _prec
Trilinos 预条件器。
template<typename T >
PreconditionerType libMesh::Preconditioner< T >::type ( ) const
inlineinherited
返回
要使用的预处理器类型。

在文件 preconditioner.h133 行定义.

参考 libMesh::Preconditioner< T >::_preconditioner_type.

133 { return _preconditioner_type; }
PreconditionerType _preconditioner_type
枚举类型,表示要使用的预处理器类型。
template<typename T >
bool libMesh::TrilinosPreconditioner< T >::UseTranspose ( ) const
overrideprotectedvirtual

在文件 trilinos_preconditioner.C225 行定义.

226 {
227  return _prec->UseTranspose();
228 }
Epetra_Operator * _prec
Trilinos 预条件器。

类成员变量说明

ReferenceCounter::Counts libMesh::ReferenceCounter::_counts
staticprotectedinherited

Actually holds the data.

在文件 reference_counter.h124 行定义.

参考自 libMesh::ReferenceCounter::get_info().

bool libMesh::ReferenceCounter::_enable_print_counter = true
staticprotectedinherited

Flag to control whether reference count information is printed when print_info is called.

在文件 reference_counter.h143 行定义.

参考自 libMesh::ReferenceCounter::disable_print_counter_info(), libMesh::ReferenceCounter::enable_print_counter_info() , 以及 libMesh::ReferenceCounter::print_info().

template<typename T >
bool libMesh::Preconditioner< T >::_is_initialized
protectedinherited

指示数据结构是否已初始化的标志。

在文件 preconditioner.h158 行定义.

参考自 libMesh::Preconditioner< T >::initialized().

template<typename T >
Epetra_FECrsMatrix* libMesh::TrilinosPreconditioner< T >::_mat
protected

从 _matrix 对象中提取出来的 Trilinos 矩阵。

在文件 trilinos_preconditioner.h135 行定义.

参考自 libMesh::TrilinosPreconditioner< T >::mat().

template<typename T >
SparseMatrix<T>* libMesh::Preconditioner< T >::_matrix
protectedinherited

要进行预处理的矩阵 P...

通常是线性系统的实际系统矩阵。

在文件 preconditioner.h148 行定义.

Threads::spin_mutex libMesh::ReferenceCounter::_mutex
staticprotectedinherited

Mutual exclusion object to enable thread-safe reference counting.

在文件 reference_counter.h137 行定义.

Threads::atomic< unsigned int > libMesh::ReferenceCounter::_n_objects
staticprotectedinherited

The number of objects.

Print the reference count information when the number returns to 0.

在文件 reference_counter.h132 行定义.

参考自 libMesh::ReferenceCounter::n_objects(), libMesh::ReferenceCounter::ReferenceCounter() , 以及 libMesh::ReferenceCounter::~ReferenceCounter().

template<typename T >
Teuchos::ParameterList libMesh::TrilinosPreconditioner< T >::_param_list
protected

用于构建预条件器的参数列表。

在文件 trilinos_preconditioner.h140 行定义.

template<typename T >
Epetra_Operator* libMesh::TrilinosPreconditioner< T >::_prec
protected

Trilinos 预条件器。

在文件 trilinos_preconditioner.h130 行定义.

template<typename T >
PreconditionerType libMesh::Preconditioner< T >::_preconditioner_type
protectedinherited

枚举类型,表示要使用的预处理器类型。

在文件 preconditioner.h153 行定义.

参考自 libMesh::Preconditioner< T >::type().


该类的文档由以下文件生成: