Scippy

SCIP

Solving Constraint Integer Programs

expr_abs.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-2022 Konrad-Zuse-Zentrum */
7 /* fuer Informationstechnik Berlin */
8 /* */
9 /* SCIP is distributed under the terms of the ZIB Academic License. */
10 /* */
11 /* You should have received a copy of the ZIB Academic License */
12 /* along with SCIP; see the file COPYING. If not email to scip@zib.de. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file expr_abs.h
17  * @ingroup EXPRHDLRS
18  * @brief absolute expression handler
19  * @author Stefan Vigerske
20  * @author Benjamin Mueller
21  */
22 
23 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
24 
25 #ifndef __SCIP_EXPR_ABS_H__
26 #define __SCIP_EXPR_ABS_H__
27 
28 
29 #include "scip/scip.h"
30 #include "scip/type_expr.h"
31 
32 #ifdef __cplusplus
33 extern "C" {
34 #endif
35 
36 /**@addtogroup EXPRHDLRS
37  *
38  * @{
39  *
40  * @name Absolute value expression
41  *
42  * This expression handler provides the absolute-value function, that is,
43  * \f[
44  * x \mapsto |x|.
45  * \f]
46  *
47  * @{
48  */
49 
50 /** creates an absolute value expression */
51 SCIP_EXPORT
53  SCIP* scip, /**< SCIP data structure */
54  SCIP_EXPR** expr, /**< pointer where to store expression */
55  SCIP_EXPR* child, /**< single child */
56  SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), /**< function to call to create ownerdata */
57  void* ownercreatedata /**< data to pass to ownercreate */
58  );
59 
60 /** indicates whether expression is of abs-type */
61 SCIP_EXPORT
63  SCIP* scip, /**< SCIP data structure */
64  SCIP_EXPR* expr /**< expression */
65  );
66 
67 /** @}
68  * @}
69  */
70 
71 /** creates the handler for absolute expression and includes it into SCIP
72  *
73  * @ingroup ExprhdlrIncludes
74  */
75 SCIP_EXPORT
77  SCIP* scip /**< SCIP data structure */
78  );
79 
80 #ifdef __cplusplus
81 }
82 #endif
83 
84 #endif /* __SCIP_EXPR_ABS_H__ */
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:54
#define SCIP_Bool
Definition: def.h:84
#define SCIP_DECL_EXPR_OWNERCREATE(x)
Definition: type_expr.h:131
SCIP_RETCODE SCIPcreateExprAbs(SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
Definition: expr_abs.c:519
type and macro definitions related to algebraic expressions
SCIP_Bool SCIPisExprAbs(SCIP *scip, SCIP_EXPR *expr)
Definition: expr_abs.c:537
SCIP_RETCODE SCIPincludeExprhdlrAbs(SCIP *scip)
Definition: expr_abs.c:493
SCIP callable library.