Basic structure for iterative methods. More...
#include <mirml_meschach.h>
Data Fields | |
| int | shared_x |
| if TRUE then x is shared and it will not be free'd | |
| int | shared_b |
| if TRUE then b is shared and it will not be free'd | |
| unsigned int | k |
| no. of direction (search) vectors; =0 - none | |
| int | limit |
| upper bound on the no. of iter. steps | |
| int | steps |
| no. of iter. steps done | |
| double | eps |
| accuracy required | |
| mirml_mh_vector_t * | x |
| input: initial guess; output: approximate solution | |
| mirml_mh_vector_t * | b |
| right hand side of the equation A*x = b | |
| mirml_mh_Fun_Ax | Ax |
| function computing y = A*x | |
| void * | A_par |
| parameters for Ax | |
| mirml_mh_Fun_Ax | ATx |
| function computing y = A^T*x; T = transpose | |
| void * | AT_par |
| parameters for ATx | |
| mirml_mh_Fun_Ax | Bx |
| function computing y = B*x; B - preconditioner | |
| void * | B_par |
| parameters for Bx | |
| mirml_mh_Fun_Ax | BTx |
| function computing y = B^T*x; B - preconditioner | |
| void * | BT_par |
| parameters for BTx | |
| void(* | info )(struct mirml_mh_iter_t_ *ip, double nres, mirml_mh_vector_t *res, mirml_mh_vector_t *Bres) |
| function giving some information for a user. | |
| int(* | stop_crit )(struct mirml_mh_iter_t_ *ip, double nres, mirml_mh_vector_t *res, mirml_mh_vector_t *Bres) |
| stopping criterion | |
| double | init_res |
| the norm of the initial residual | |
Basic structure for iterative methods.
| void(* mirml_mh_iter_t_::info) (struct mirml_mh_iter_t_ *ip, double nres, mirml_mh_vector_t *res, mirml_mh_vector_t *Bres) |
function giving some information for a user.
nres - a norm of a residual res.
| int(* mirml_mh_iter_t_::stop_crit) (struct mirml_mh_iter_t_ *ip, double nres, mirml_mh_vector_t *res, mirml_mh_vector_t *Bres) |
stopping criterion
nres - a norm of res; res - residual; if returned value == 1 then stop; if returned value == 0 then continue.