Scippy

SCIP

Solving Constraint Integer Programs

probdata_binpacking.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-2019 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 visit scip.zib.de. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file probdata_binpacking.h
17  * @brief Problem data for binpacking problem
18  * @author Timo Berthold
19  * @author Stefan Heinz
20  *
21  * This file handles the main problem data used in that project. For more details see \ref BINPACKING_PROBLEMDATA page.
22  */
23 
24 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
25 
26 #ifndef __SCIP_PROBDATA_BINPACKING__
27 #define __SCIP_PROBDATA_BINPACKING__
28 
29 #include "scip/scip.h"
30 
31 /** sets up the problem data */
33  SCIP* scip, /**< SCIP data structure */
34  const char* probname, /**< problem name */
35  int* ids, /**< array of item ids */
36  SCIP_Longint* weights, /**< array containing the item weights */
37  int nitems, /**< number of items */
38  SCIP_Longint capacity /**< bin capacity */
39  );
40 
41 /** returns array of item ids */
43  SCIP_PROBDATA* probdata /**< problem data */
44  );
45 
46 /** returns array of item weights */
48  SCIP_PROBDATA* probdata /**< problem data */
49  );
50 
51 /** returns number of items */
53  SCIP_PROBDATA* probdata /**< problem data */
54  );
55 
56 /** returns bin capacity */
58  SCIP_PROBDATA* probdata /**< problem data */
59  );
60 
61 /** returns array of all variables ordered in the way they got generated */
63  SCIP_PROBDATA* probdata /**< problem data */
64  );
65 
66 /** returns number of variables */
68  SCIP_PROBDATA* probdata /**< problem data */
69  );
70 
71 /** returns array of set partitioning constrains */
73  SCIP_PROBDATA* probdata /**< problem data */
74  );
75 
76 /** adds given variable to the problem data */
78  SCIP* scip, /**< SCIP data structure */
79  SCIP_PROBDATA* probdata, /**< problem data */
80  SCIP_VAR* var /**< variables to add */
81  );
82 
83 #endif
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
SCIP_RETCODE SCIPprobdataCreate(SCIP *scip, const char *probname, int *ids, SCIP_Longint *weights, int nitems, SCIP_Longint capacity)
SCIP_Longint * SCIPprobdataGetWeights(SCIP_PROBDATA *probdata)
SCIP_VAR ** SCIPprobdataGetVars(SCIP_PROBDATA *probdata)
SCIP_Longint SCIPprobdataGetCapacity(SCIP_PROBDATA *probdata)
SCIP_CONS ** SCIPprobdataGetConss(SCIP_PROBDATA *probdata)
int * SCIPprobdataGetIds(SCIP_PROBDATA *probdata)
SCIP_RETCODE SCIPprobdataAddVar(SCIP *scip, SCIP_PROBDATA *probdata, SCIP_VAR *var)
int SCIPprobdataGetNItems(SCIP_PROBDATA *probdata)
int SCIPprobdataGetNVars(SCIP_PROBDATA *probdata)
struct SCIP_ProbData SCIP_PROBDATA
Definition: type_prob.h:44
#define SCIP_Longint
Definition: def.h:149
SCIP callable library.