MTL5 -- Matrix Template Library C++ API
mtl:: -- C++20 header-only linear algebra for mixed-precision algorithm design
Loading...
Searching...
No Matches
mtl::itl::pc::ildl< Value, Parameters, Accumulator > Class Template Reference

ILDL preconditioner: incomplete L*D*L^T factorization. More...

#include <ildl.hpp>

Public Member Functions

 ildl (const matrix_type &A)
 Throws (through throw_or_abort) for a non-square A, and for a zero or missing pivot d_i (issue 925).
template<typename VecX, typename VecB>
void solve (VecX &x, const VecB &b) const
 Solve (L*D*L^T)*x = b.
template<typename VecX, typename VecB>
void adjoint_solve (VecX &x, const VecB &b) const
 Solve (L*D*L^T)^H * x = b.

Detailed Description

template<Field Value, typename Parameters = mat::parameters<>, typename Accumulator = void>
class mtl::itl::pc::ildl< Value, Parameters, Accumulator >

ILDL preconditioner: incomplete L*D*L^T factorization.

D is diagonal (may have negative entries), L is unit lower triangular. A must be symmetric; only the sparsity pattern of the lower triangle is preserved. For a complex Value that means complex SYMMETRIC (A^T == A), not Hermitian: the factorization reads only the lower triangle and conjugates nothing.

Accumulator selects how the factorization and the triangular solves accumulate (see math/accumulator_traits.hpp and the header note). The default void keeps the naive value_type arithmetic unchanged.

Constructor & Destructor Documentation

◆ ildl()

template<Field Value, typename Parameters = mat::parameters<>, typename Accumulator = void>
mtl::itl::pc::ildl< Value, Parameters, Accumulator >::ildl ( const matrix_type & A)
inlineexplicit

Throws (through throw_or_abort) for a non-square A, and for a zero or missing pivot d_i (issue 925).

A negative one is fine: ILDL is for symmetric indefinite matrices.

Member Function Documentation

◆ adjoint_solve()

template<Field Value, typename Parameters = mat::parameters<>, typename Accumulator = void>
template<typename VecX, typename VecB>
void mtl::itl::pc::ildl< Value, Parameters, Accumulator >::adjoint_solve ( VecX & x,
const VecB & b ) const
inline

Solve (L*D*L^T)^H * x = b.

This used to delegate to solve(), commented "L*D*L^T is symmetric". It is – but symmetric is self-adjoint only for a REAL Value. For a complex one M^T == M gives M^H = conj(M), so M^-H is the same three solves with L and D conjugated. Delegating applied M^-1 instead: the adjoint identity <M^-1 b, c> == <b, M^-H c> was violated by 3.7e-02 on a complex-symmetric tridiagonal and 1.2e+00 on a dense one (#394's defect, for complex only). For a real Value conj is the identity, and this is solve() operation for operation.

◆ solve()

template<Field Value, typename Parameters = mat::parameters<>, typename Accumulator = void>
template<typename VecX, typename VecB>
void mtl::itl::pc::ildl< Value, Parameters, Accumulator >::solve ( VecX & x,
const VecB & b ) const
inline

Solve (L*D*L^T)*x = b.


The documentation for this class was generated from the following file:
  • /home/runner/work/mtl5/mtl5/include/mtl/itl/pc/ildl.hpp