Scippy

SCIP

Solving Constraint Integer Programs

struct_nlhdlr.h
Go to the documentation of this file.
1/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
2/* */
3/* This file is part of the program and library */
4/* SCIP --- Solving Constraint Integer Programs */
5/* */
6/* Copyright (c) 2002-2024 Zuse Institute Berlin (ZIB) */
7/* */
8/* Licensed under the Apache License, Version 2.0 (the "License"); */
9/* you may not use this file except in compliance with the License. */
10/* You may obtain a copy of the License at */
11/* */
12/* http://www.apache.org/licenses/LICENSE-2.0 */
13/* */
14/* Unless required by applicable law or agreed to in writing, software */
15/* distributed under the License is distributed on an "AS IS" BASIS, */
16/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
17/* See the License for the specific language governing permissions and */
18/* limitations under the License. */
19/* */
20/* You should have received a copy of the Apache-2.0 license */
21/* along with SCIP; see the file LICENSE. If not visit scipopt.org. */
22/* */
23/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
24
25/**@file struct_nlhdlr.h
26 * @ingroup INTERNALAPI
27 * @brief structure definitions related to nonlinear handlers of nonlinear constraints
28 * @author Ksenia Bestuzheva
29 * @author Benjamin Mueller
30 * @author Felipe Serrano
31 * @author Stefan Vigerske
32 */
33
34#ifndef SCIP_STRUCT_NLHLDR_H_
35#define SCIP_STRUCT_NLHLDR_H_
36
37#include "scip/def.h"
38#include "scip/type_scip.h"
39#include "scip/type_nlhdlr.h"
40#include "scip/type_clock.h"
41
42/** generic data and callback methods of a nonlinear handler */
44{
45 char* name; /**< nonlinear handler name */
46 char* desc; /**< nonlinear handler description (can be NULL) */
47 SCIP_NLHDLRDATA* data; /**< data of handler */
48
49 int detectpriority; /**< detection priority of nonlinear handler */
50 int enfopriority; /**< enforcement priority of nonlinear handler */
51 SCIP_Bool enabled; /**< whether the nonlinear handler should be used */
52
53 /* callbacks */
54 SCIP_DECL_NLHDLRFREEHDLRDATA((*freehdlrdata)); /**< callback to free data of handler (can be NULL) */
55 SCIP_DECL_NLHDLRFREEEXPRDATA((*freeexprdata)); /**< callback to free expression specific data (can be NULL) */
56 SCIP_DECL_NLHDLRCOPYHDLR((*copyhdlr)); /**< callback to copy nonlinear handler (can be NULL) */
57 SCIP_DECL_NLHDLRINIT((*init)); /**< initialization callback (can be NULL) */
58 SCIP_DECL_NLHDLREXIT((*exit)); /**< deinitialization callback (can be NULL) */
59 SCIP_DECL_NLHDLRDETECT((*detect)); /**< structure detection callback */
60 SCIP_DECL_NLHDLREVALAUX((*evalaux)); /**< auxiliary evaluation callback */
61 SCIP_DECL_NLHDLRINITSEPA((*initsepa)); /**< separation initialization callback (can be NULL) */
62 SCIP_DECL_NLHDLRENFO((*enfo)); /**< enforcement callback (can be NULL) */
63 SCIP_DECL_NLHDLRESTIMATE((*estimate)); /**< estimator callback (can be NULL) */
64 SCIP_DECL_NLHDLREXITSEPA((*exitsepa)); /**< separation deinitialization callback (can be NULL) */
65 SCIP_DECL_NLHDLRINTEVAL((*inteval)); /**< interval evaluation callback (can be NULL) */
66 SCIP_DECL_NLHDLRREVERSEPROP((*reverseprop)); /**< reverse propagation callback (can be NULL) */
67 SCIP_DECL_NLHDLRSOLLINEARIZE((*sollinearize)); /**< solution linearization callback (can be NULL) */
68
69 /* statistics */
70 SCIP_Longint nenfocalls; /**< number of times, the enforcement or estimation callback was called */
71 SCIP_Longint nintevalcalls; /**< number of times, the interval evaluation callback was called */
72 SCIP_Longint npropcalls; /**< number of times, the propagation callback was called */
73 SCIP_Longint nseparated; /**< number of times, the nonlinear handler enforced by separation */
74 SCIP_Longint ncutoffs; /**< number of cutoffs found so far by this nonlinear handler */
75 SCIP_Longint ndomreds; /**< number of domain reductions found so far by this nonlinear handler */
76 SCIP_Longint ndetections; /**< number of detect calls in which structure was detected (success returned by detect call) (over all runs) */
77 SCIP_Longint ndetectionslast; /**< number of detect calls in which structure was detected (success returned by detect call) (in last round) */
78 SCIP_Longint nbranchscores; /**< number of times, branching scores were added by this nonlinear handler */
79
80 SCIP_CLOCK* detecttime; /**< time used for detection */
81 SCIP_CLOCK* enfotime; /**< time used for enforcement or estimation */
82 SCIP_CLOCK* proptime; /**< time used for reverse propagation */
83 SCIP_CLOCK* intevaltime; /**< time used for interval evaluation */
84};
85
86#endif /* SCIP_STRUCT_NLHLDR_H_ */
common defines and data types used in all packages of SCIP
#define SCIP_Longint
Definition: def.h:158
#define SCIP_Bool
Definition: def.h:91
SCIP_Longint ndetections
Definition: struct_nlhdlr.h:76
SCIP_CLOCK * proptime
Definition: struct_nlhdlr.h:82
SCIP_DECL_NLHDLREVALAUX((*evalaux))
SCIP_CLOCK * detecttime
Definition: struct_nlhdlr.h:80
SCIP_DECL_NLHDLRESTIMATE((*estimate))
SCIP_Bool enabled
Definition: struct_nlhdlr.h:51
SCIP_DECL_NLHDLRDETECT((*detect))
SCIP_Longint npropcalls
Definition: struct_nlhdlr.h:72
SCIP_CLOCK * enfotime
Definition: struct_nlhdlr.h:81
SCIP_DECL_NLHDLRSOLLINEARIZE((*sollinearize))
SCIP_CLOCK * intevaltime
Definition: struct_nlhdlr.h:83
SCIP_DECL_NLHDLRCOPYHDLR((*copyhdlr))
SCIP_NLHDLRDATA * data
Definition: struct_nlhdlr.h:47
SCIP_Longint ndetectionslast
Definition: struct_nlhdlr.h:77
SCIP_Longint ncutoffs
Definition: struct_nlhdlr.h:74
int detectpriority
Definition: struct_nlhdlr.h:49
SCIP_DECL_NLHDLRENFO((*enfo))
SCIP_DECL_NLHDLRINITSEPA((*initsepa))
SCIP_DECL_NLHDLREXITSEPA((*exitsepa))
SCIP_Longint nseparated
Definition: struct_nlhdlr.h:73
SCIP_DECL_NLHDLRREVERSEPROP((*reverseprop))
SCIP_Longint nenfocalls
Definition: struct_nlhdlr.h:70
SCIP_DECL_NLHDLRFREEEXPRDATA((*freeexprdata))
SCIP_Longint ndomreds
Definition: struct_nlhdlr.h:75
SCIP_Longint nintevalcalls
Definition: struct_nlhdlr.h:71
SCIP_DECL_NLHDLREXIT((*exit))
SCIP_Longint nbranchscores
Definition: struct_nlhdlr.h:78
SCIP_DECL_NLHDLRINIT((*init))
SCIP_DECL_NLHDLRFREEHDLRDATA((*freehdlrdata))
SCIP_DECL_NLHDLRINTEVAL((*inteval))
type definitions for clocks and timing issues
type definitions related to nonlinear handlers of nonlinear constraints
struct SCIP_NlhdlrData SCIP_NLHDLRDATA
Definition: type_nlhdlr.h:452
type definitions for SCIP's main datastructure