File numerics/src/tools/Newton_methods.h¶
Go to the source code of this file
Data structure and function for using Newton based solvers
The reference used for the implementation is “Finite-Dimensional Variational
Inequalities and Complementarity Problems” by Facchinei and Pang.
More precisely, the function newton_LSA() is algorithm VFBLSA.
Typedefs
-
typedef void (*compute_F_ptr)(void *data_opaque, double *z, double *F)¶
-
typedef void (*compute_F_merit_ptr)(void *data_opaque, double *z, double *F, double *F_merit)¶
Enums
-
enum SICONOS_NEWTON_IPARAM¶
Values:
-
enumerator SICONOS_IPARAM_LSA_NONMONOTONE_LS¶
line search based algo use this
-
enumerator SICONOS_IPARAM_LSA_NONMONOTONE_LS_M¶
-
enumerator SICONOS_IPARAM_LSA_FORCE_ARCSEARCH¶
-
enumerator SICONOS_IPARAM_LSA_SEARCH_CRITERION¶
-
enumerator SICONOS_IPARAM_STOPPING_CRITERION¶
-
enumerator SICONOS_IPARAM_LSA_NONMONOTONE_LS¶
-
enum SICONOS_STOPPING_CRITERION¶
Values:
-
enumerator SICONOS_STOPPING_CRITERION_RESIDU¶
-
enumerator SICONOS_STOPPING_CRITERION_STATIONARITY¶
-
enumerator SICONOS_STOPPING_CRITERION_RESIDU_AND_STATIONARITY¶
-
enumerator SICONOS_STOPPING_CRITERION_USER_ROUTINE¶
-
enumerator SICONOS_STOPPING_CRITERION_RESIDU¶
-
enum SICONOS_NMS_IPARAM¶
Values:
-
enumerator SICONOS_IPARAM_NMS_WATCHDOG_TYPE¶
non-monotone specific part
-
enumerator SICONOS_IPARAM_NMS_PROJECTED_GRADIENT_TYPE¶
-
enumerator SICONOS_IPARAM_NMS_N_MAX¶
-
enumerator SICONOS_IPARAM_NMS_WATCHDOG_TYPE¶
-
enum SICONOS_NEWTON_DPARAM¶
Values:
-
enumerator SICONOS_DPARAM_LSA_ALPHA_MIN¶
line-search
-
enumerator SICONOS_DPARAM_GOLDSTEIN_C¶
-
enumerator SICONOS_DPARAM_GOLDSTEIN_ALPHAMAX¶
-
enumerator SICONOS_DPARAM_LSA_ALPHA_MIN¶
-
enum SICONOS_NMS_DPARAM¶
Values:
-
enumerator SICONOS_DPARAM_NMS_DELTA¶
non-monotone specific part
-
enumerator SICONOS_DPARAM_NMS_DELTA_VAR¶
-
enumerator SICONOS_DPARAM_NMS_SIGMA¶
-
enumerator SICONOS_DPARAM_NMS_ALPHA_MIN_WATCHDOG¶
-
enumerator SICONOS_DPARAM_NMS_ALPHA_MIN_PGRAD¶
-
enumerator SICONOS_DPARAM_NMS_MERIT_INCR¶
-
enumerator SICONOS_DPARAM_NMS_DELTA¶
Functions
-
void newton_LSA(unsigned n, double *z, double *w, int *info, void *data, SolverOptions *options, functions_LSA *functions)¶
Newton algorithm for finding the zero of a function with a line search.
Mainly used for equation-based reformulation of CP or VI.
- Parameters
n – size of the problem
z – variable
w – value of F(z)
info – solver-specific values
data – opaque problem definition
options – options for this solver
functions – struct of function pointers to compute F, H and the error
-
static inline void init_lsa_functions(functions_LSA *functions, compute_F_ptr compute_F, compute_F_merit_ptr merit_function)¶
Set the functions to compute F and F_merit and all the other pointers to NULL.
- Parameters
functions – structure to fill
compute_F – function to compute F
merit_function – function to compute F_merit
-
void set_lsa_params_data(SolverOptions *options, NumericsMatrix *mat)¶
Set the parameters and data for newton_LSA.
- Parameters
options – the solver option
mat – the
-
void newton_LSA_free_solverOptions(SolverOptions *options)¶
clear the solver-specific data
- Parameters
options – the SolverOption structure
-
void newton_lsa_set_default(SolverOptions *options)¶
Variables
-
const char *const SICONOS_NEWTON_LSA_STR¶
-
struct functions_LSA¶
- #include <>
Struct holding the necessary pointers to functions needed by the newton_LSA() procedure.
Public Members
-
compute_F_ptr compute_F¶
function to evaluate w = F(z)
-
compute_F_merit_ptr compute_F_merit¶
function to evaluate F_merit(z) (e.g.
F_FB, F_{min}, …)
-
void (*compute_H)(void *data_opaque, double *z, double *w, double *workV1, double *workV2, NumericsMatrix *H)¶
function to get an element H of T
-
void (*compute_error)(void *data_opaque, double *z, double *w, double *nabla_theta, double tol, double *err)¶
function to compute the error
-
void (*compute_RHS_desc)(void *data_opaque, double *z, double *w, double *F_desc)¶
function to evaluate F_desc(z) (e.g.
F_FB, F_{min}, …), optional
-
void (*compute_H_desc)(void *data_opaque, double *z, double *w, double *workV1, double *workV2, NumericsMatrix *H_desc)¶
function to get an element H_desc of T_desc, optional
-
int (*compute_descent_direction)(void *data_opaque, double *z, double *w, double *descent_dir, SolverOptions *options)¶
function to get the descent direction, used for instance in the Newton-Josephy method
-
void (*compute_JacTheta_merit)(void *data_opaque, double *z, double *w, double *F_merit, double *workV, double *JacThetaF_merit, SolverOptions *options)¶
function to get the descent direction, used for instance in the Newton-Josephy method
-
void *(*get_set_from_problem_data)(void *problem)¶
Function returning the set description from the
-
int (*ls_failure_fn)(void *problem, double *z, double *w, double *descent_dir, double err, size_t status)¶
Function to call when the line search fails.
-
compute_F_ptr compute_F¶
-
struct newton_stats¶
-
struct newton_LSA_param¶
Public Members
-
double p¶
p value for the acceptance test of the direction solution of the linear system
-
double sigma¶
ratio for the decrease in norm of the C-function ( \( gamma' \) in VFBLSA)
-
double rho¶
coefficient for the direction check
-
bool keep_H¶
keep the matrix H untouched.
Only used in the dense case, where a copy of the matrix is factorized
-
bool check_dir_quality¶
Check the quality of the descent direction (Eqn 9.1.6 p.
805 in Facchinei & Pang)
-
double p¶
-
struct newton_LSA_data¶
Public Members
-
NumericsMatrix *H¶
matrix
-
NumericsMatrix *H¶