|
IBSimu 1.0.4
|
Gauss-Seidel based solver implementation. More...
#include <gs_solver.hpp>
Public Member Functions | |
| GSSolver (double w=1.66, double eps=1.0e-6, uint32_t imax=10000, double newton_Reps=1.0e-5, double newton_dXeps=1.0e-6, uint32_t newton_imax=10) | |
| Constructor. | |
| ~GSSolver () | |
| Destructor. | |
| virtual void | solve (const Problem &p, Vector &X) |
| Solve problem p defined in geometry g. Initial guess and solution are in vector X. | |
| virtual void | reset (void) |
| Reset solver. | |
| void | set_newton_imax (uint32_t newton_imax) |
| Sets maximum iteration count for Newton-Raphson steps. | |
| void | set_newton_residual_eps (double newton_Reps) |
| Sets the accuracy request for Newton-Raphson residual. | |
| void | set_newton_step_eps (double newton_dXeps) |
| Sets the accuracy request for Newton-Raphson step size. | |
Static Public Member Functions | |
| static bool | gauss_seidel (const CRowMatrix &mat, const Vector &rhs, Vector &sol, uint32_t &imax, double &eps, double w) |
| Direct interface to gauss_seidel matrix solver. | |
Gauss-Seidel based solver implementation.
An implementation of virtual class Solver using Gauss-Seidel/Successive over relaxation method for solving matrix equation. Linear and nonlinear solvers. Nonlinear solver not implemented.
The Gauss-Seidel solver has special limitations for the problem type because of convergence issues. The problem has to have first order neumann edges and the edge smoothing must be switched off.
| GSSolver::GSSolver | ( | double | w = 1.66, |
| double | eps = 1.0e-6, |
||
| uint32_t | imax = 10000, |
||
| double | newton_Reps = 1.0e-5, |
||
| double | newton_dXeps = 1.0e-6, |
||
| uint32_t | newton_imax = 10 |
||
| ) |
Constructor.
| GSSolver::~GSSolver | ( | ) | [inline] |
Destructor.
| static bool GSSolver::gauss_seidel | ( | const CRowMatrix & | mat, |
| const Vector & | rhs, | ||
| Vector & | sol, | ||
| uint32_t & | imax, | ||
| double & | eps, | ||
| double | w | ||
| ) | [static] |
Direct interface to gauss_seidel matrix solver.
Solves matrix problem mat * sol = rhs. The matrix is sorted to be on the ascending order as required by the GAUSS_SEIDEL library.
| virtual void GSSolver::reset | ( | void | ) | [virtual] |
Reset solver.
This is a signal from the problem that the problem has changed and internal caches (if they exist) in the solver should be resetted.
Implements Solver.
| void GSSolver::set_newton_imax | ( | uint32_t | newton_imax | ) | [inline] |
Sets maximum iteration count for Newton-Raphson steps.
| void GSSolver::set_newton_residual_eps | ( | double | newton_Reps | ) | [inline] |
Sets the accuracy request for Newton-Raphson residual.
| void GSSolver::set_newton_step_eps | ( | double | newton_dXeps | ) | [inline] |
Sets the accuracy request for Newton-Raphson step size.
Solve problem p defined in geometry g. Initial guess and solution are in vector X.
1.7.4