Scippy

SCIP

Solving Constraint Integer Programs

scip_debug.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_debug.c
17  * @brief public methods for debugging
18  * @author Tobias Achterberg
19  * @author Timo Berthold
20  * @author Gerald Gamrath
21  * @author Robert Lion Gottwald
22  * @author Stefan Heinz
23  * @author Gregor Hendel
24  * @author Thorsten Koch
25  * @author Alexander Martin
26  * @author Marc Pfetsch
27  * @author Michael Winkler
28  * @author Kati Wolter
29  *
30  * @todo check all SCIP_STAGE_* switches, and include the new stages TRANSFORMED and INITSOLVE
31  */
32 
33 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
34 
35 #include "scip/debug.h"
36 #include "scip/pub_message.h"
37 #include "scip/scip_debug.h"
38 
39 /** enable debug solution mechanism
40  *
41  * the debug solution mechanism allows to trace back the invalidation of
42  * a debug solution during the solution process of SCIP. It must be explicitly
43  * enabled for the SCIP data structure.
44  *
45  * @see debug.h for more information on debug solution mechanism
46  */
48  SCIP* scip /**< SCIP data structure */
49  )
50 {
51  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPenableDebugSol", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
52 
53  SCIPdebugSolEnable(scip);
54 }
55 
56 /** disable solution debugging mechanism
57  *
58  * @see debug.h for more information on debug solution mechanism
59  */
61  SCIP* scip /**< SCIP data structure */
62  )
63 {
64  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPdisableDebugSol", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
65 
66  SCIPdebugSolDisable(scip);
67 }
#define FALSE
Definition: def.h:73
#define TRUE
Definition: def.h:72
SCIP_RETCODE SCIPcheckStage(SCIP *scip, const char *method, SCIP_Bool init, SCIP_Bool problem, SCIP_Bool transforming, SCIP_Bool transformed, SCIP_Bool initpresolve, SCIP_Bool presolving, SCIP_Bool exitpresolve, SCIP_Bool presolved, SCIP_Bool initsolve, SCIP_Bool solving, SCIP_Bool solved, SCIP_Bool exitsolve, SCIP_Bool freetrans, SCIP_Bool freescip)
Definition: debug.c:2010
void SCIPenableDebugSol(SCIP *scip)
Definition: scip_debug.c:47
methods for debugging
void SCIPdisableDebugSol(SCIP *scip)
Definition: scip_debug.c:60
public methods for debugging
public methods for message output
#define SCIPdebugSolDisable(scip)
Definition: debug.h:260
#define SCIP_CALL_ABORT(x)
Definition: def.h:344
#define SCIPdebugSolEnable(scip)
Definition: debug.h:259