17#ifndef dealii_sundials_kinsol_h
18#define dealii_sundials_kinsol_h
22#ifdef DEAL_II_WITH_SUNDIALS
34# include <boost/signals2.hpp>
36# include <kinsol/kinsol.h>
37# include <nvector/nvector_serial.h>
38# include <sundials/sundials_math.h>
39# include <sundials/sundials_types.h>
47# define AssertKINSOL(code) Assert(code >= 0, ExcKINSOLError(code))
180 template <
typename VectorType = Vector<
double>>
407 solve(VectorType &initial_guess_and_solution);
431 std::function<
int(
const VectorType &src, VectorType &dst)>
residual;
447 std::function<
int(
const VectorType &src, VectorType &dst)>
495 std::function<
int(
const VectorType ¤t_u,
const VectorType ¤t_f)>
556 std::function<
int(
const VectorType &ycur,
557 const VectorType &fcur,
558 const VectorType &rhs,
602 int(
const VectorType &rhs, VectorType &dst,
const double tolerance)>
666 <<
"One of the SUNDIALS KINSOL internal functions "
667 <<
"returned a negative error code: " << arg1
668 <<
". Please consult SUNDIALS manual.");
678 <<
"Please provide an implementation for the function \""
704# if DEAL_II_SUNDIALS_VERSION_GTE(6, 0, 0)
unsigned int maximum_setup_calls
double maximum_newton_step
SolutionStrategy strategy
unsigned int maximum_beta_failures
void add_parameters(ParameterHandler &prm)
unsigned int maximum_non_linear_iterations
unsigned int anderson_subspace_size
double function_tolerance
std::function< VectorType &()> get_solution_scaling
std::function< int(const VectorType &rhs, VectorType &dst, const double tolerance)> solve_with_jacobian
std::function< int(const VectorType ¤t_u, const VectorType ¤t_f)> setup_jacobian
void set_functions_to_trigger_an_assert()
MPI_Comm mpi_communicator
std::function< int(const VectorType &ycur, const VectorType &fcur, const VectorType &rhs, VectorType &dst)> solve_jacobian_system
unsigned int solve(VectorType &initial_guess_and_solution)
GrowingVectorMemory< VectorType > mem
std::function< int(const VectorType &src, VectorType &dst)> residual
std::function< VectorType &()> get_function_scaling
std::function< void(VectorType &)> reinit_vector
std::function< int(const VectorType &src, VectorType &dst)> iteration_function
#define DEAL_II_DEPRECATED
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
static ::ExceptionBase & ExcKINSOLError(int arg1)
static ::ExceptionBase & ExcFunctionNotProvided(std::string arg1)
#define DeclException1(Exception1, type1, outsequence)