Scippy

SCIP

Solving Constraint Integer Programs

src/main.c
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 scip/src/main.c
17  * @brief main file for C compilation
18  * @author Tobias Achterberg
19  */
20 
21 /* global todos: */
22 
23 /**@todo pricing for pseudo solutions */
24 /**@todo unboundness detection in presolving -> convert problem into feasibility problem to decide
25  * unboundness/infeasibility */
26 /**@todo variable event PSSOLCHANGED, update pseudo activities in constraints to speed up checking of pseudo solutions */
27 /**@todo branching rule acting as a filter by temporary changing the branching priority of variables and returning
28  * SCIP_DIDNOTFIND to let the next branching rule select the branching variable */
29 /**@todo try to not use the first but the shortest constraint as reason for a deduction */
30 
31 /*--+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
32 
33 #include <stdio.h>
34 #include <signal.h>
35 
36 #include "scip/scip.h"
37 #include "scip/scipshell.h"
38 #include "scip/interrupt.h"
39 
40 static
42  int signum /**< signal code */
43  )
44 { /*lint --e{715}*/
46 }
47 
48 /** main method starting SCIP */
49 int main(
50  int argc, /**< number of arguments from the shell */
51  char** argv /**< array of shell arguments */
52  )
53 {
54  SCIP_RETCODE retcode;
55 
56  (void)signal(SIGTERM, handleSigterm);
57  /* run interactive shell */
58  retcode = SCIPrunShell(argc, argv, "scip.set");
59 
60  /* evaluate retrun code of the SCIP process */
61  if( retcode != SCIP_OKAY )
62  {
63  /* write error back trace */
64  SCIPprintError(retcode);
65  return -1;
66  }
67 
68  return 0;
69 }
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
SCIP command line interface.
SCIP_RETCODE SCIPrunShell(int argc, char **argv, const char *defaultsetname)
Definition: scipshell.c:426
methods for catching the user CTRL-C interrupt
static void handleSigterm(int signum)
Definition: main.c:41
void SCIPtryTerminate(void)
Definition: interrupt.c:167
void SCIPprintError(SCIP_RETCODE retcode)
Definition: scip_general.c:266
int main(int argc, char **argv)
Definition: main.c:49
SCIP callable library.