deal.II version GIT relicensing-6834-g5b78e6bcdf 2026-10-01 11:20: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\}}\)
Loading...
Searching...
No Matches
sparse_ilu.h
Go to the documentation of this file.
1// -----------------------------------------------------------------------------
2//
3// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception OR LGPL-2.1-or-later
4// Copyright (C) 1999 - 2025 by the deal.II authors
5//
6// This file is part of the deal.II library.
7//
8// Detailed license information governing the source code and contributions
9// can be found in LICENSE.md and CONTRIBUTING.md at the top level directory.
10//
11// -----------------------------------------------------------------------------
12
13
14#ifndef dealii_sparse_ilu_h
15#define dealii_sparse_ilu_h
16
17
18#include <deal.II/base/config.h>
19
23
25
56template <typename number>
57class SparseILU : public SparseLUDecomposition<number>
58{
59public:
64
71 SparseILU() = default;
72
78
96 template <typename somenumber>
97 void
99 const AdditionalData &parameters = AdditionalData());
100
107 template <typename somenumber>
108 void
110
111
118 template <typename somenumber>
119 void
121
122
127 std::size_t
128 memory_consumption() const override;
129
139 double,
140 << "The strengthening parameter " << arg1
141 << " is not greater or equal than zero!");
146 size_type,
147 << "While computing the ILU decomposition, the algorithm "
148 "found a zero entry on the diagonal of row "
149 << arg1
150 << ". The algorithm can not recover from this because it "
151 "wants to divide by this diagonal entry."
152 "\n\n"
153 "There are several reasons why this could be happening. "
154 "First, the matrix for which you try to compute a "
155 "decomposition might be singular. Second, the order in "
156 "which the algorithm considers might lead it to find "
157 "a zero diagonal entry even though different pivoting "
158 "strategies might not; the current implementation does "
159 "not do any pivoting (i.e., it works on rows/columns "
160 "in their natural order), and so you will trigger "
161 "this error if, for example, you have a zero in the "
162 "(0,0) entry of the matrix, even though this does "
163 "not imply that the matrix is singular."
164 "\n\n"
165 "It is possible that you can avoid the error if "
166 "you re-order degrees of freedom (using "
167 "the functions in namespace DoFRenumbering). You may "
168 "also want to consider \"strengthening the diagonal\", "
169 "using the AdditionalData::strengthen_diagonal parameter "
170 "you can set in the optional constructor argument of "
171 "this class.");
173};
174
176//---------------------------------------------------------------------------
177
178
180
181#endif // dealii_sparse_ilu_h
void Tvmult(Vector< somenumber > &dst, const Vector< somenumber > &src) const
typename SparseLUDecomposition< number >::size_type size_type
Definition sparse_ilu.h:63
void vmult(Vector< somenumber > &dst, const Vector< somenumber > &src) const
std::size_t memory_consumption() const override
typename SparseLUDecomposition< number >::AdditionalData AdditionalData
Definition sparse_ilu.h:77
void initialize(const SparseMatrix< somenumber > &matrix, const AdditionalData &parameters=AdditionalData())
SparseILU()=default
typename SparseMatrix< number >::size_type size_type
#define DEAL_II_NAMESPACE_OPEN
Definition config.h:38
#define DEAL_II_NAMESPACE_CLOSE
Definition config.h:39
static ::ExceptionBase & ExcInvalidStrengthening(double arg1)
static ::ExceptionBase & ExcZeroPivot(size_type arg1)
#define DeclException1(Exception1, type1, outsequence)