13#ifndef OPTIMIST_SCALAR_ROOT_FINDER_HH
14#define OPTIMIST_SCALAR_ROOT_FINDER_HH
44 template <
typename Real,
typename DerivedSolver>
72 std::string
name()
const {
return static_cast<const DerivedSolver *
>(
this)->name_impl();}
83 return static_cast<DerivedSolver *
>(
this)->solve_impl(function, x_ini, x_sol);
97 return static_cast<DerivedSolver *
>(
this)->solve_impl(function, first_derivative, x_ini, x_sol);
109 second_derivate, Real x_ini, Real & x_sol)
111 return static_cast<DerivedSolver *
>(
this)->solve_impl(function, first_derivative,
112 second_derivate, x_ini, x_sol);
#define OPTIMIST_BASIC_CONSTANTS(Real)
Definition Optimist.hh:70
Class container for the scalar scalar root-finder.
Definition ScalarRootFinder.hh:46
static constexpr bool requires_second_derivative
Definition ScalarRootFinder.hh:55
static constexpr bool is_rootfinder
Definition ScalarRootFinder.hh:50
bool solve(FunctionWrapper function, Real x_ini, Real &x_sol)
Definition ScalarRootFinder.hh:81
ScalarRootFinder()
Definition ScalarRootFinder.hh:66
std::string name() const
Definition ScalarRootFinder.hh:72
bool solve(FunctionWrapper function, FirstDerivativeWrapper first_derivative, Real x_ini, Real &x_sol)
Definition ScalarRootFinder.hh:94
static constexpr bool requires_function
Definition ScalarRootFinder.hh:53
typename Solver< Real, 1, 1, DerivedSolver >::FirstDerivativeWrapper FirstDerivativeWrapper
Definition ScalarRootFinder.hh:60
typename Solver< Real, 1, 1, DerivedSolver >::FunctionWrapper FunctionWrapper
Definition ScalarRootFinder.hh:59
static constexpr bool requires_first_derivative
Definition ScalarRootFinder.hh:54
bool solve(FunctionWrapper function, FirstDerivativeWrapper first_derivative, SecondDerivativeWrapper second_derivate, Real x_ini, Real &x_sol)
Definition ScalarRootFinder.hh:108
typename Solver< Real, 1, 1, DerivedSolver >::SecondDerivativeWrapper SecondDerivativeWrapper
Definition ScalarRootFinder.hh:61
static constexpr bool is_optimizer
Definition ScalarRootFinder.hh:51
Solver()
Definition Solver.hh:106
Namespace for the Optimist library.
Definition Optimist.hh:87