deal.II version GIT relicensing-2167-g9622207b8f 2024-11-21 12:40:00+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\}}\)
Loading...
Searching...
No Matches
sparse_mic.h
Go to the documentation of this file.
1// ------------------------------------------------------------------------
2//
3// SPDX-License-Identifier: LGPL-2.1-or-later
4// Copyright (C) 2002 - 2023 by the deal.II authors
5//
6// This file is part of the deal.II library.
7//
8// Part of the source code is dual licensed under Apache-2.0 WITH
9// LLVM-exception OR LGPL-2.1-or-later. Detailed license information
10// governing the source code and code contributions can be found in
11// LICENSE.md and CONTRIBUTING.md at the top level directory of deal.II.
12//
13// ------------------------------------------------------------------------
14
15#ifndef dealii_sparse_mic_h
16#define dealii_sparse_mic_h
17
18#include <deal.II/base/config.h>
19
22
24
44template <typename number>
45class SparseMIC : public SparseLUDecomposition<number>
46{
47public:
52
57 SparseMIC() = default;
58
62 virtual ~SparseMIC() override;
63
68 virtual void
69 clear() override;
70
76
94 template <typename somenumber>
95 void
97 const AdditionalData &parameters = AdditionalData());
98
105 template <typename somenumber>
106 void
108
117 template <typename somenumber>
118 void
120
125 std::size_t
126 memory_consumption() const override;
127
141 double,
142 << "The strengthening parameter " << arg1
143 << " is not greater or equal than zero!");
148 int,
149 double,
150 << "The diagonal element (" << arg1 << ',' << arg1 << ") is "
151 << arg2 << ", but must be positive");
152
154private:
158 std::vector<number> diag;
159
163 std::vector<number> inv_diag;
164
169 std::vector<number> inner_sums;
170
174 number
175 get_rowsum(const size_type row) const;
176};
177
181
182#endif // dealii_
std::vector< number > inv_diag
Definition sparse_mic.h:163
void initialize(const SparseMatrix< somenumber > &matrix, const AdditionalData &parameters=AdditionalData())
typename SparseLUDecomposition< number >::AdditionalData AdditionalData
Definition sparse_mic.h:75
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:158
SparseMIC()=default
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:169
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:498
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:499
#define DeclException0(Exception0)
Definition exceptions.h:466
#define DeclException2(Exception2, type1, type2, outsequence)
Definition exceptions.h:534
static ::ExceptionBase & ExcInvalidStrengthening(double arg1)
#define DeclException1(Exception1, type1, outsequence)
Definition exceptions.h:511
static ::ExceptionBase & ExcDecompositionNotStable(int arg1, double arg2)
static ::ExceptionBase & ExcStrengthenDiagonalTooSmall()
unsigned int global_dof_index
Definition types.h:81