Reference documentation for deal.II version GIT 276cfaa7ee 2022-08-16 14:00:01+00:00
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
sparse_mic.h
Go to the documentation of this file.
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2002 - 2022 by the deal.II authors
4 //
5 // This file is part of the deal.II library.
6 //
7 // The deal.II library is free software; you can use it, redistribute
8 // it, and/or modify it under the terms of the GNU Lesser General
9 // Public License as published by the Free Software Foundation; either
10 // version 2.1 of the License, or (at your option) any later version.
11 // The full text of the license can be found in the file LICENSE.md at
12 // the top level directory of deal.II.
13 //
14 // ---------------------------------------------------------------------
15 
16 #ifndef dealii_sparse_mic_h
17 #define dealii_sparse_mic_h
18 
19 #include <deal.II/base/config.h>
20 
23 
25 
45 template <typename number>
46 class SparseMIC : public SparseLUDecomposition<number>
47 {
48 public:
53 
59 
63  virtual ~SparseMIC() override;
64 
69  virtual void
70  clear() override;
71 
77 
95  template <typename somenumber>
96  void
98  const AdditionalData & parameters = AdditionalData());
99 
106  template <typename somenumber>
107  void
108  vmult(Vector<somenumber> &dst, const Vector<somenumber> &src) const;
109 
118  template <typename somenumber>
119  void
121 
126  std::size_t
127  memory_consumption() const override;
128 
142  double,
143  << "The strengthening parameter " << arg1
144  << " is not greater or equal than zero!");
149  int,
150  double,
151  << "The diagonal element (" << arg1 << ',' << arg1 << ") is "
152  << arg2 << ", but must be positive");
153 
155 private:
159  std::vector<number> diag;
160 
164  std::vector<number> inv_diag;
165 
170  std::vector<number> inner_sums;
171 
175  number
176  get_rowsum(const size_type row) const;
177 };
178 
182 
183 #endif // dealii_
typename SparseMatrix< number >::size_type size_type
std::vector< number > inv_diag
Definition: sparse_mic.h:164
void initialize(const SparseMatrix< somenumber > &matrix, const AdditionalData &parameters=AdditionalData())
typename SparseLUDecomposition< number >::AdditionalData AdditionalData
Definition: sparse_mic.h:76
void vmult(Vector< somenumber > &dst, const Vector< somenumber > &src) const
std::size_t memory_consumption() const override
virtual ~SparseMIC() override
std::vector< number > diag
Definition: sparse_mic.h:159
virtual void clear() override
void Tvmult(Vector< somenumber > &dst, const Vector< somenumber > &src) const
number get_rowsum(const size_type row) const
std::vector< number > inner_sums
Definition: sparse_mic.h:170
Definition: vector.h:110
#define DEAL_II_NAMESPACE_OPEN
Definition: config.h:442
#define DEAL_II_NAMESPACE_CLOSE
Definition: config.h:443
#define DeclException0(Exception0)
Definition: exceptions.h:464
static ::ExceptionBase & ExcInvalidStrengthening(double arg1)
static ::ExceptionBase & ExcStrengthenDiagonalTooSmall()
#define DeclException2(Exception2, type1, type2, outsequence)
Definition: exceptions.h:532
static ::ExceptionBase & ExcDecompositionNotStable(int arg1, double arg2)
#define DeclException1(Exception1, type1, outsequence)
Definition: exceptions.h:509
@ matrix
Contents is actually a matrix.
unsigned int global_dof_index
Definition: types.h:76