#include <solver.hpp>
Class describes stop criterias used in gradient method minimization of Tikhonov regularization functional J_{alpha}(v) where J_{alpha}(v) = alpha * square_norm_{L2([0;H]x[t1;t2])}(v) + square_norm_{L2[0;H]}(qT) where v is source function, qT(x)=h(x,T)-h_obs(x) where h is result of solving forward linear problem.
Definition at line 135 of file solver.hpp.
Public Types | |
enum | stop_type { stop_max_iters, stop_max_iters_calc_func, stop_func } |
StopCriteria mode. More... | |
Public Member Functions | |
StopCriteria (unsigned max_iter, bool calc_func=false) | |
Initialized stop criteria by max_iters. | |
StopCriteria (double tol) | |
Initialized stop criteria by relative error of minimized functional. | |
void | Reset () |
Reset iterations to start. | |
stop_type | GetType () const |
Get type of stop criteria. | |
bool | IsStop () const |
Check is stop criteria satisfied. | |
void | UpdateCurIter () |
Update number of current iteration. | |
unsigned | GetCurIter () const |
Get number of current iteration. | |
bool | NeedCalcFunc () const |
Check is calculating functional is needed. | |
void | CalcFunc (unsigned N, double h, const double *qT, double alpha, double square_norm_v) |
Calculate functional J_{alpha}(v). | |
double | GetCurFunc () const |
Get value of functional on current iteration. | |
Classes | |
union | un_param |
|
StopCriteria mode.
Definition at line 138 of file solver.hpp. |
|
Initialized stop criteria by max_iters.
Definition at line 204 of file solver.cpp. |
|
Initialized stop criteria by relative error of minimized functional.
Definition at line 211 of file solver.cpp. |
|
Reset iterations to start.
Definition at line 217 of file solver.cpp. |
|
Get type of stop criteria.
Definition at line 224 of file solver.cpp. References stop_func, stop_max_iters, and stop_max_iters_calc_func. |
|
Check is stop criteria satisfied.
Definition at line 244 of file solver.cpp. References stop_func. |
|
Update number of current iteration.
Definition at line 162 of file solver.hpp. |
|
Get number of current iteration.
Definition at line 164 of file solver.hpp. |
|
Check is calculating functional is needed.
Definition at line 239 of file solver.cpp. References stop_max_iters. |
|
Calculate functional J_{alpha}(v). Calc J_{alpha}(v) = alpha * square_norm_{L2([0;H]x[t1;t2])}(v) + square_norm_{L2[0;H]}(qT) where qT(x)=h(x,T)-h_obs(x) where h is result of solving forward linear problem.
Definition at line 253 of file solver.cpp. |
|
Get value of functional on current iteration.
Definition at line 181 of file solver.hpp. |