/home/runner/work/DiFfRG_current/DiFfRG_current/DiFfRG/include/DiFfRG/timestepping/solver/kinsol.hh Source File#
|
DiFfRG
|
kinsol.hh
Go to the documentation of this file.
A newton solver, using local error estimates for each vector component.
Definition kinsol.hh:18
void set_ignore_nonconv(bool x)
Make the newton algorithm return a success even if the evolution did not fulfill the convergence crit...
std::function< void(VectorType &, const VectorType &)> lin_solve
Definition kinsol.hh:60
unsigned int num_newton_calls() const
const VectorType & get_initial() const
const VectorType & get_residual() const
void operator()(VectorType &iterate)
Perform a newton iteration on the input vector.
void reinit(const VectorType &u)
Should it be necessary, one can force a recalculation of the jacobian hereby.
std::shared_ptr< SUNDIALS::KINSOL< VectorType > > kinsol
Definition kinsol.hh:108
std::function< void(VectorType &, const VectorType &)> residual
Definition kinsol.hh:59
double average_time_newton() const
std::function< void(const VectorType &)> update_jacobian
Definition kinsol.hh:61
unsigned int get_jacobians()
Get the number of jacobians created in the latest iteration.
unsigned int get_step()
Get the number of steps taken in the latest iteration.
double threshold(const double thr)
Set the jacobian recalculation threshold, i.e. below which reduction we force a jacobian update.
KINSOL(double abstol_=1e-10, double reltol_=1e-6, double assemble_threshold_=0., unsigned int max_steps_=21, unsigned int n_stepsize_iterations_=21)
const VectorType & get_iterate() const
Definition complex_math.hh:10
Generated by