Scippy

SCIP

Solving Constraint Integer Programs

expr_erf.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-2023 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 expr_erf.h
26  * @brief handler for Gaussian error function expressions
27  * @author Benjamin Mueller
28  */
29 
30 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
31 
32 #ifndef __SCIP_EXPR_ERF_H__
33 #define __SCIP_EXPR_ERF_H__
34 
35 #include "scip/scip.h"
36 
37 #ifdef __cplusplus
38 extern "C" {
39 #endif
40 
41 /** @{
42  *
43  * @name Gaussian error function expression
44  *
45  * This expression handler provides the Gaussian error function, that is
46  *
47  * \f[
48  * x \mapsto \frac{2}{\sqrt{\pi}}\int_0^x \exp(-t^2) dt.
49  * \f]
50  *
51  * @attention The implementation of this expression handler is incomplete.
52  * It is not usable for most use cases so far.
53  * @{
54  */
55 
56 /** creates an erf expression
57  *
58  * @attention The implementation of `erf` expressions is incomplete.
59  * They are not usable for most use cases so far.
60  */
61 SCIP_EXPORT
63  SCIP* scip, /**< SCIP data structure */
64  SCIP_EXPR** expr, /**< pointer where to store expression */
65  SCIP_EXPR* child, /**< child expression */
66  SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), /**< function to call to create ownerdata */
67  void* ownercreatedata /**< data to pass to ownercreate */
68  );
69 
70 /** indicates whether expression is of erf-type */
71 SCIP_EXPORT
73  SCIP* scip, /**< SCIP data structure */
74  SCIP_EXPR* expr /**< expression */
75  );
76 
77 /** @}
78  * @}
79  */
80 
81 /** creates the handler for erf expressions and includes it into SCIP
82  *
83  * @attention The implementation of this expression handler is incomplete.
84  * It is not usable for most use cases so far.
85  */
86 SCIP_EXPORT
88  SCIP* scip /**< SCIP data structure */
89  );
90 
91 #ifdef __cplusplus
92 }
93 #endif
94 
95 #endif /* __SCIP_EXPR_ERF_H__ */
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:63
SCIP_RETCODE SCIPcreateExprErf(SCIP *scip, SCIP_EXPR **expr, SCIP_EXPR *child, SCIP_DECL_EXPR_OWNERCREATE((*ownercreate)), void *ownercreatedata)
Definition: expr_erf.c:257
#define SCIP_Bool
Definition: def.h:93
#define SCIP_DECL_EXPR_OWNERCREATE(x)
Definition: type_expr.h:140
SCIP_Bool SCIPisExprErf(SCIP *scip, SCIP_EXPR *expr)
Definition: expr_erf.c:285
SCIP_RETCODE SCIPincludeExprhdlrErf(SCIP *scip)
Definition: expr_erf.c:300
SCIP callable library.