![]() |
Block-Structured AMR Software Framework
|
Jacobi smoother for AlgVector/SpMatrix linear systems. More...
#include <AMReX_Smoother_MV.H>
Public Member Functions | |
| JacobiSmoother (SpMatrix< T > const *a_A, bool a_l1=false) | |
Construct a smoother that operates on a_A. | |
| int | setNumIters (int a_niters) |
| Update how many Jacobi sweeps to perform per apply. | |
| void | setWeight (T w) |
| Set the relaxation weight. Call this after setL1(), which resets it. | |
| void | setL1 (bool b) |
| void | operator() (AlgVector< T > &xvec, AlgVector< T > const &bvec, bool with_initial_guess=false) |
Apply the smoother to solve approximately for xvec. | |
| AlgVector< T > const & | scaling () |
| Diagonal or l1 scaling vector. The first call is collective. | |
Jacobi smoother for AlgVector/SpMatrix linear systems.
Performs x += w * (b - A x) / d sweeps, where d is the diagonal of A (weighted Jacobi, weight 2/3 by default) or, with setL1(true), the l1 row norm sign(a_ii) * sum_j |a_ij| (l1-Jacobi, weight 1 by default), which converges for any symmetric positive definite matrix [Baker, Falgout, Kolev, Yang, SIAM J. Sci. Comput. 33 (2011), 2864-2887].
|
inlineexplicit |
Construct a smoother that operates on a_A.
| a_A | Sparse matrix supplying diagonal entries and SpMV. |
| a_l1 | Use l1-Jacobi scaling. |
|
inline |
Apply the smoother to solve approximately for xvec.
| xvec | Solution vector updated in place. |
| bvec | RHS vector. |
| with_initial_guess | True if xvec already holds an initial guess. |
|
inline |
Diagonal or l1 scaling vector. The first call is collective.
|
inline |
Switch between l1-Jacobi and weighted Jacobi, resetting the weight to the default of the new mode.
|
inline |
Update how many Jacobi sweeps to perform per apply.
| a_niters | Desired number of smoothing iterations (4 by default). |
|
inline |
Set the relaxation weight. Call this after setL1(), which resets it.