#include "cs_defs.h"#include <stdarg.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include <assert.h>#include <math.h>#include "cs_sles_it.h"#include "cs_sles_it_priv.h"#include "cs_multigrid_smoother.h"Functions | |
| cs_sles_it_t * | cs_multigrid_smoother_create (cs_sles_it_type_t smoother_type, int poly_degree, int n_iter) |
| Create iterative sparse linear system solver info and context used as a smoother in a multigrid solver. | |
| void | cs_multigrid_smoother_setup (void *context, const char *name, const cs_matrix_t *a, int verbosity) |
| Setup iterative sparse linear equation solver in case of used as a multigrid smoother. | |
| cs_sles_convergence_state_t | cs_multigrid_smoother_solve (void *context, const char *name, const cs_matrix_t *a, int verbosity, double precision, double r_norm, int *n_iter, double *residual, const cs_real_t *rhs, cs_real_t *vx_ini, cs_real_t *vx, size_t aux_size, void *aux_vectors) |
| Call iterative sparse linear equation solver. | |
| cs_sles_it_t * cs_multigrid_smoother_create | ( | cs_sles_it_type_t | smoother_type, |
| int | poly_degree, | ||
| int | n_iter ) |
Create iterative sparse linear system solver info and context used as a smoother in a multigrid solver.
parameters:
| [in] | smoother_type | type of smoother (CG, Jacobi, ...) |
| [in] | poly_degree | preconditioning polynomial degree (0: diagonal; -1: non-preconditioned; see Iterative linear solvers. for details) |
| [in] | n_iter | number of iterations to perform |
| void cs_multigrid_smoother_setup | ( | void * | context, |
| const char * | name, | ||
| const cs_matrix_t * | a, | ||
| int | verbosity ) |
Setup iterative sparse linear equation solver in case of used as a multigrid smoother.
| [in,out] | context | pointer to iterative solver info and context (actual type: cs_sles_it_t *) |
| [in] | name | pointer to system name |
| [in] | a | associated matrix |
| [in] | verbosity | associated verbosity |
| cs_sles_convergence_state_t cs_multigrid_smoother_solve | ( | void * | context, |
| const char * | name, | ||
| const cs_matrix_t * | a, | ||
| int | verbosity, | ||
| double | precision, | ||
| double | r_norm, | ||
| int * | n_iter, | ||
| double * | residual, | ||
| const cs_real_t * | rhs, | ||
| cs_real_t * | vx_ini, | ||
| cs_real_t * | vx, | ||
| size_t | aux_size, | ||
| void * | aux_vectors ) |
Call iterative sparse linear equation solver.
| [in,out] | context | pointer to iterative solver info and context (actual type: cs_sles_it_t *) |
| [in] | name | pointer to system name |
| [in] | a | matrix |
| [in] | verbosity | associated verbosity |
| [in] | precision | solver precision |
| [in] | r_norm | residual normalization |
| [out] | n_iter | number of "equivalent" iterations |
| [out] | residual | residual |
| [in] | rhs | right hand side |
| [in] | vx_ini | initial system solution (vx if nonzero, nullptr if zero) |
| [in,out] | vx | system solution |
| [in] | aux_size | number of elements in aux_vectors (in bytes) |
| aux_vectors | optional working area (internal allocation if NULL) |