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

Gauss-Seidel smoother. More...

#include <gauss_seidel.hpp>

Public Member Functions

 gauss_seidel (const Matrix &A)
template<typename VecX, typename VecB>
VecX & operator() (VecX &x, const VecB &b) const
 Forward sweep (rows 0..n-1). Default application.
template<typename VecX, typename VecB>
VecX & forward (VecX &x, const VecB &b) const
 Forward sweep: rows iterated in ascending order.
template<typename VecX, typename VecB>
VecX & backward (VecX &x, const VecB &b) const
 Backward sweep: rows iterated in descending order (n-1..0).

Detailed Description

template<FieldMatrix Matrix, typename Accumulator = void>
class mtl::itl::smoother::gauss_seidel< Matrix, Accumulator >

Gauss-Seidel smoother.

x[i] = dia_inv[i] * (b[i] - sum_{j!=i} A(i,j)*x[j]) operator() runs a forward (ascending-row) sweep; forward()/backward() expose the sweep direction explicitly (backward_gauss_seidel / symmetric_gauss_seidel build on them). All variants carry the optional Accumulator unchanged.

Constructor & Destructor Documentation

◆ gauss_seidel()

template<FieldMatrix Matrix, typename Accumulator = void>
mtl::itl::smoother::gauss_seidel< Matrix, Accumulator >::gauss_seidel ( const Matrix & A)
inlineexplicit

Member Function Documentation

◆ backward()

template<FieldMatrix Matrix, typename Accumulator = void>
template<typename VecX, typename VecB>
VecX & mtl::itl::smoother::gauss_seidel< Matrix, Accumulator >::backward ( VecX & x,
const VecB & b ) const
inline

Backward sweep: rows iterated in descending order (n-1..0).

◆ forward()

template<FieldMatrix Matrix, typename Accumulator = void>
template<typename VecX, typename VecB>
VecX & mtl::itl::smoother::gauss_seidel< Matrix, Accumulator >::forward ( VecX & x,
const VecB & b ) const
inline

Forward sweep: rows iterated in ascending order.

◆ operator()()

template<FieldMatrix Matrix, typename Accumulator = void>
template<typename VecX, typename VecB>
VecX & mtl::itl::smoother::gauss_seidel< Matrix, Accumulator >::operator() ( VecX & x,
const VecB & b ) const
inline

Forward sweep (rows 0..n-1). Default application.


The documentation for this class was generated from the following file: