Scippy

SCIP

Solving Constraint Integer Programs

reader_diff.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-2017 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 reader_diff.h
17  * @ingroup FILEREADERS
18  * @brief diff file reader
19  * @author Jakob Witzig
20  *
21  * This reader allows to parse a new objective function the style of CPLEX .lp files.
22  *
23  * The lp format is defined within the CPLEX documentation.
24  */
25 
26 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
27 
28 #ifndef __SCIP_READER_DIFF_H__
29 #define __SCIP_READER_DIFF_H__
30 
31 
32 #include "scip/scip.h"
33 
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
37 
38 /** includes the diff file reader into SCIP
39  *
40  * @ingroup FileReaderIncludes
41  */
42 extern
44  SCIP* scip /**< SCIP data structure */
45  );
46 
47 /**@addtogroup FILEREADERS
48  *
49  * @{
50  */
51 
52 /** reads problem from file */
53 extern
55  SCIP* scip, /**< SCIP data structure */
56  SCIP_READER* reader, /**< the file reader itself */
57  const char* filename, /**< full path and name of file to read, or NULL if stdin should be used */
58  SCIP_RESULT* result /**< pointer to store the result of the file reading call */
59  );
60 
61 /** writes problem to file */
62 extern
64  SCIP* scip, /**< SCIP data structure */
65  FILE* file, /**< output file, or NULL if standard output should be used */
66  const char* name, /**< problem name */
67  SCIP_Bool transformed, /**< TRUE iff problem is the transformed problem */
68  SCIP_OBJSENSE objsense, /**< objective sense */
69  SCIP_Real objscale, /**< scalar applied to objective function; external objective value is
70  * extobj = objsense * objscale * (intobj + objoffset) */
71  SCIP_Real objoffset, /**< objective offset from bound shifting and fixing */
72  SCIP_VAR** vars, /**< array with active variables ordered binary, integer, implicit, continuous */
73  int nvars, /**< number of mutable variables in the problem */
74  int nbinvars, /**< number of binary variables */
75  int nintvars, /**< number of general integer variables */
76  int nimplvars, /**< number of implicit integer variables */
77  int ncontvars, /**< number of continuous variables */
78  SCIP_CONS** conss, /**< array with constraints of the problem */
79  int nconss, /**< number of constraints in the problem */
80  SCIP_RESULT* result /**< pointer to store the result of the file writing call */
81  );
82 
83 /* @} */
84 
85 #ifdef __cplusplus
86 }
87 #endif
88 
89 #endif
enum SCIP_Result SCIP_RESULT
Definition: type_result.h:52
SCIP_RETCODE SCIPreadDiff(SCIP *scip, SCIP_READER *reader, const char *filename, SCIP_RESULT *result)
Definition: reader_diff.c:1016
SCIP_RETCODE SCIPincludeReaderDiff(SCIP *scip)
Definition: reader_diff.c:997
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
SCIP_RETCODE SCIPwriteDiff(SCIP *scip, FILE *file, const char *name, SCIP_Bool transformed, SCIP_OBJSENSE objsense, SCIP_Real objscale, SCIP_Real objoffset, SCIP_VAR **vars, int nvars, int nbinvars, int nintvars, int nimplvars, int ncontvars, SCIP_CONS **conss, int nconss, SCIP_RESULT *result)
#define SCIP_Bool
Definition: def.h:61
enum SCIP_Objsense SCIP_OBJSENSE
Definition: type_prob.h:41
#define SCIP_Real
Definition: def.h:135
SCIP callable library.