Scippy

SCIP

Solving Constraint Integer Programs

scip_solvingstats.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_solvingstats.c
17  * @brief public methods for querying solving statistics
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 "blockmemshell/memory.h"
36 #include "scip/branch.h"
37 #include "scip/clock.h"
38 #include "scip/concsolver.h"
39 #include "scip/concurrent.h"
40 #include "scip/conflict.h"
41 #include "scip/conflictstore.h"
42 #include "scip/debug.h"
43 #include "scip/disp.h"
44 #include "scip/history.h"
45 #include "scip/pricestore.h"
46 #include "scip/primal.h"
47 #include "scip/prob.h"
48 #include "scip/pub_benderscut.h"
49 #include "scip/pub_benders.h"
50 #include "scip/pub_branch.h"
51 #include "scip/pub_compr.h"
52 #include "scip/pub_cons.h"
53 #include "scip/pub_cutpool.h"
54 #include "scip/pub_heur.h"
55 #include "scip/pub_history.h"
56 #include "scip/pub_message.h"
57 #include "scip/pub_misc.h"
58 #include "scip/pub_misc_sort.h"
59 #include "scip/pub_presol.h"
60 #include "scip/pub_pricer.h"
61 #include "scip/pub_prop.h"
62 #include "scip/pub_reader.h"
63 #include "scip/pub_relax.h"
64 #include "scip/pub_reopt.h"
65 #include "scip/pub_sepa.h"
66 #include "scip/pub_sol.h"
67 #include "scip/pub_table.h"
68 #include "scip/pub_var.h"
69 #include "scip/reader.h"
70 #include "scip/reopt.h"
71 #include "scip/scip_benders.h"
72 #include "scip/scip_general.h"
73 #include "scip/scip_mem.h"
74 #include "scip/scip_message.h"
75 #include "scip/scip_numerics.h"
76 #include "scip/scip_sol.h"
77 #include "scip/scip_solvingstats.h"
78 #include "scip/scip_table.h"
79 #include "scip/scip_timing.h"
80 #include "scip/scip_var.h"
81 #include "scip/sepastore.h"
82 #include "scip/set.h"
83 #include "scip/sol.h"
84 #include "scip/stat.h"
85 #include "scip/struct_mem.h"
86 #include "scip/struct_primal.h"
87 #include "scip/struct_prob.h"
88 #include "scip/struct_scip.h"
89 #include "scip/struct_set.h"
90 #include "scip/struct_stat.h"
91 #include "scip/syncstore.h"
92 #include "scip/table.h"
93 #include "scip/tree.h"
94 #include "scip/var.h"
95 #include <string.h>
96 
97 /** gets number of branch and bound runs performed, including the current run
98  *
99  * @return the number of branch and bound runs performed, including the current run
100  *
101  * @pre This method can be called if SCIP is in one of the following stages:
102  * - \ref SCIP_STAGE_PROBLEM
103  * - \ref SCIP_STAGE_TRANSFORMING
104  * - \ref SCIP_STAGE_TRANSFORMED
105  * - \ref SCIP_STAGE_INITPRESOLVE
106  * - \ref SCIP_STAGE_PRESOLVING
107  * - \ref SCIP_STAGE_EXITPRESOLVE
108  * - \ref SCIP_STAGE_PRESOLVED
109  * - \ref SCIP_STAGE_INITSOLVE
110  * - \ref SCIP_STAGE_SOLVING
111  * - \ref SCIP_STAGE_SOLVED
112  * - \ref SCIP_STAGE_EXITSOLVE
113  * - \ref SCIP_STAGE_FREETRANS
114  */
116  SCIP* scip /**< SCIP data structure */
117  )
118 {
119  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNRuns", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
120 
121  return scip->stat->nruns;
122 }
123 
124 /** gets number of reoptimization runs performed, including the current run
125  *
126  * @return the number of reoptimization runs performed, including the current run
127  *
128  * @pre This method can be called if SCIP is in one of the following stages:
129  * - \ref SCIP_STAGE_PROBLEM
130  * - \ref SCIP_STAGE_TRANSFORMING
131  * - \ref SCIP_STAGE_TRANSFORMED
132  * - \ref SCIP_STAGE_INITPRESOLVE
133  * - \ref SCIP_STAGE_PRESOLVING
134  * - \ref SCIP_STAGE_EXITPRESOLVE
135  * - \ref SCIP_STAGE_PRESOLVED
136  * - \ref SCIP_STAGE_INITSOLVE
137  * - \ref SCIP_STAGE_SOLVING
138  * - \ref SCIP_STAGE_SOLVED
139  * - \ref SCIP_STAGE_EXITSOLVE
140  * - \ref SCIP_STAGE_FREETRANS
141  */
143  SCIP* scip /**< SCIP data structure */
144  )
145 {
146  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNReoptRuns", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
147 
148  return scip->stat->nreoptruns;
149 }
150 
151 /** add given number to the number of processed nodes in current run and in all runs, including the focus node
152  *
153  * @return the number of processed nodes in current run, including the focus node
154  *
155  * @pre This method can be called if SCIP is in one of the following stages:
156  * - \ref SCIP_STAGE_PROBLEM
157  * - \ref SCIP_STAGE_TRANSFORMING
158  * - \ref SCIP_STAGE_TRANSFORMED
159  * - \ref SCIP_STAGE_INITPRESOLVE
160  * - \ref SCIP_STAGE_PRESOLVING
161  * - \ref SCIP_STAGE_EXITPRESOLVE
162  * - \ref SCIP_STAGE_PRESOLVED
163  * - \ref SCIP_STAGE_INITSOLVE
164  * - \ref SCIP_STAGE_SOLVING
165  * - \ref SCIP_STAGE_SOLVED
166  * - \ref SCIP_STAGE_EXITSOLVE
167  * - \ref SCIP_STAGE_FREETRANS
168  */
170  SCIP* scip, /**< SCIP data structure */
171  SCIP_Longint nnodes /**< number of processed nodes to add to the statistics */
172  )
173 {
174  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPaddNNodes", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
175 
176  scip->stat->nnodes += nnodes;
177  scip->stat->ntotalnodes += nnodes;
178 }
179 
180 /** gets number of processed nodes in current run, including the focus node
181  *
182  * @return the number of processed nodes in current run, including the focus node
183  *
184  * @pre This method can be called if SCIP is in one of the following stages:
185  * - \ref SCIP_STAGE_PROBLEM
186  * - \ref SCIP_STAGE_TRANSFORMING
187  * - \ref SCIP_STAGE_TRANSFORMED
188  * - \ref SCIP_STAGE_INITPRESOLVE
189  * - \ref SCIP_STAGE_PRESOLVING
190  * - \ref SCIP_STAGE_EXITPRESOLVE
191  * - \ref SCIP_STAGE_PRESOLVED
192  * - \ref SCIP_STAGE_INITSOLVE
193  * - \ref SCIP_STAGE_SOLVING
194  * - \ref SCIP_STAGE_SOLVED
195  * - \ref SCIP_STAGE_EXITSOLVE
196  * - \ref SCIP_STAGE_FREETRANS
197  */
199  SCIP* scip /**< SCIP data structure */
200  )
201 {
202  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNNodes", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
203 
204  return scip->stat->nnodes;
205 }
206 
207 /** gets total number of processed nodes in all runs, including the focus node
208  *
209  * @return the total number of processed nodes in all runs, including the focus node
210  *
211  * @pre This method can be called if SCIP is in one of the following stages:
212  * - \ref SCIP_STAGE_PROBLEM
213  * - \ref SCIP_STAGE_TRANSFORMING
214  * - \ref SCIP_STAGE_TRANSFORMED
215  * - \ref SCIP_STAGE_INITPRESOLVE
216  * - \ref SCIP_STAGE_PRESOLVING
217  * - \ref SCIP_STAGE_EXITPRESOLVE
218  * - \ref SCIP_STAGE_PRESOLVED
219  * - \ref SCIP_STAGE_INITSOLVE
220  * - \ref SCIP_STAGE_SOLVING
221  * - \ref SCIP_STAGE_SOLVED
222  * - \ref SCIP_STAGE_EXITSOLVE
223  * - \ref SCIP_STAGE_FREETRANS
224  */
226  SCIP* scip /**< SCIP data structure */
227  )
228 {
229  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNTotalNodes", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
230 
231  return scip->stat->ntotalnodes;
232 }
233 
234 /** gets number of leaf nodes processed with feasible relaxation solution
235  *
236  * @return number of leaf nodes processed with feasible relaxation solution
237  *
238  * @pre This method can be called if SCIP is in one of the following stages:
239  * - \ref SCIP_STAGE_PROBLEM
240  * - \ref SCIP_STAGE_TRANSFORMING
241  * - \ref SCIP_STAGE_TRANSFORMED
242  * - \ref SCIP_STAGE_INITPRESOLVE
243  * - \ref SCIP_STAGE_PRESOLVING
244  * - \ref SCIP_STAGE_EXITPRESOLVE
245  * - \ref SCIP_STAGE_PRESOLVED
246  * - \ref SCIP_STAGE_INITSOLVE
247  * - \ref SCIP_STAGE_SOLVING
248  * - \ref SCIP_STAGE_SOLVED
249  * - \ref SCIP_STAGE_EXITSOLVE
250  * - \ref SCIP_STAGE_FREETRANS
251  */
253  SCIP* scip /**< SCIP data structure */
254  )
255 {
256  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNFeasibleLeaves", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
257 
258  return scip->stat->nfeasleaves;
259 }
260 
261 /** gets number of infeasible leaf nodes processed
262  *
263  * @return number of infeasible leaf nodes processed
264  *
265  * @pre This method can be called if SCIP is in one of the following stages:
266  * - \ref SCIP_STAGE_PROBLEM
267  * - \ref SCIP_STAGE_TRANSFORMING
268  * - \ref SCIP_STAGE_TRANSFORMED
269  * - \ref SCIP_STAGE_INITPRESOLVE
270  * - \ref SCIP_STAGE_PRESOLVING
271  * - \ref SCIP_STAGE_EXITPRESOLVE
272  * - \ref SCIP_STAGE_PRESOLVED
273  * - \ref SCIP_STAGE_INITSOLVE
274  * - \ref SCIP_STAGE_SOLVING
275  * - \ref SCIP_STAGE_SOLVED
276  * - \ref SCIP_STAGE_EXITSOLVE
277  * - \ref SCIP_STAGE_FREETRANS
278  */
280  SCIP* scip /**< SCIP data structure */
281  )
282 {
283  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNInfeasibleLeaves", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
284 
285  return scip->stat->ninfeasleaves;
286 }
287 
288 /** gets number of processed leaf nodes that hit LP objective limit
289  *
290  * @return number of processed leaf nodes that hit LP objective limit
291  *
292  * @pre This method can be called if SCIP is in one of the following stages:
293  * - \ref SCIP_STAGE_PROBLEM
294  * - \ref SCIP_STAGE_TRANSFORMING
295  * - \ref SCIP_STAGE_TRANSFORMED
296  * - \ref SCIP_STAGE_INITPRESOLVE
297  * - \ref SCIP_STAGE_PRESOLVING
298  * - \ref SCIP_STAGE_EXITPRESOLVE
299  * - \ref SCIP_STAGE_PRESOLVED
300  * - \ref SCIP_STAGE_INITSOLVE
301  * - \ref SCIP_STAGE_SOLVING
302  * - \ref SCIP_STAGE_SOLVED
303  * - \ref SCIP_STAGE_EXITSOLVE
304  * - \ref SCIP_STAGE_FREETRANS
305  */
307  SCIP* scip /**< Scip data structure */
308  )
309 {
310  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNObjlimLeaves", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
311 
312  return scip->stat->nobjleaves;
313 }
314 
315 
316 /** gets number of times a selected node was from a cut off subtree
317  *
318  * @return number of times a selected node was from a cut off subtree
319  *
320  * @pre This method can be called if SCIP is in one of the following stages:
321  * - \ref SCIP_STAGE_PROBLEM
322  * - \ref SCIP_STAGE_TRANSFORMING
323  * - \ref SCIP_STAGE_TRANSFORMED
324  * - \ref SCIP_STAGE_INITPRESOLVE
325  * - \ref SCIP_STAGE_PRESOLVING
326  * - \ref SCIP_STAGE_EXITPRESOLVE
327  * - \ref SCIP_STAGE_PRESOLVED
328  * - \ref SCIP_STAGE_INITSOLVE
329  * - \ref SCIP_STAGE_SOLVING
330  * - \ref SCIP_STAGE_SOLVED
331  * - \ref SCIP_STAGE_EXITSOLVE
332  * - \ref SCIP_STAGE_FREETRANS
333  */
335  SCIP* scip /**< SCIP data structure */
336  )
337 {
338  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNDelayedCutoffs", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
339 
340  return scip->stat->ndelayedcutoffs;
341 }
342 
343 /** gets total number of LPs solved so far
344  *
345  * @return the total number of LPs solved so far
346  *
347  * @pre This method can be called if SCIP is in one of the following stages:
348  * - \ref SCIP_STAGE_PROBLEM
349  * - \ref SCIP_STAGE_TRANSFORMING
350  * - \ref SCIP_STAGE_TRANSFORMED
351  * - \ref SCIP_STAGE_INITPRESOLVE
352  * - \ref SCIP_STAGE_PRESOLVING
353  * - \ref SCIP_STAGE_EXITPRESOLVE
354  * - \ref SCIP_STAGE_PRESOLVED
355  * - \ref SCIP_STAGE_INITSOLVE
356  * - \ref SCIP_STAGE_SOLVING
357  * - \ref SCIP_STAGE_SOLVED
358  * - \ref SCIP_STAGE_EXITSOLVE
359  * - \ref SCIP_STAGE_FREETRANS
360  */
362  SCIP* scip /**< SCIP data structure */
363  )
364 {
365  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNLPs", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
366 
367  return scip->stat->nlps;
368 }
369 
370 /** gets total number of iterations used so far in primal and dual simplex and barrier algorithm
371  *
372  * @return the total number of iterations used so far in primal and dual simplex and barrier algorithm
373  *
374  * @pre This method can be called if SCIP is in one of the following stages:
375  * - \ref SCIP_STAGE_PRESOLVING
376  * - \ref SCIP_STAGE_PRESOLVED
377  * - \ref SCIP_STAGE_SOLVING
378  * - \ref SCIP_STAGE_SOLVED
379  */
381  SCIP* scip /**< SCIP data structure */
382  )
383 {
384  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
385 
386  return scip->stat->nlpiterations;
387 }
388 
389 /** gets number of active non-zeros in the current transformed problem
390  *
391  * @return the number of active non-zeros in the current transformed problem
392  *
393  * @pre This method can be called if SCIP is in one of the following stages:
394  * - \ref SCIP_STAGE_PROBLEM
395  * - \ref SCIP_STAGE_TRANSFORMING
396  * - \ref SCIP_STAGE_TRANSFORMED
397  * - \ref SCIP_STAGE_INITPRESOLVE
398  * - \ref SCIP_STAGE_PRESOLVING
399  * - \ref SCIP_STAGE_EXITPRESOLVE
400  * - \ref SCIP_STAGE_PRESOLVED
401  * - \ref SCIP_STAGE_INITSOLVE
402  * - \ref SCIP_STAGE_SOLVING
403  * - \ref SCIP_STAGE_SOLVED
404  * - \ref SCIP_STAGE_EXITSOLVE
405  */
407  SCIP* scip /**< SCIP data structure */
408  )
409 {
410  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNNZs", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
411 
412  return scip->stat->nnz;
413 }
414 
415 /** gets total number of iterations used so far in primal and dual simplex and barrier algorithm for the root node
416  *
417  * @return the total number of iterations used so far in primal and dual simplex and barrier algorithm for the root node
418  *
419  * @pre This method can be called if SCIP is in one of the following stages:
420  * - \ref SCIP_STAGE_PRESOLVED
421  * - \ref SCIP_STAGE_SOLVING
422  * - \ref SCIP_STAGE_SOLVED
423  */
425  SCIP* scip /**< SCIP data structure */
426  )
427 {
428  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNRootLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
429 
430  return scip->stat->nrootlpiterations;
431 }
432 
433 /** gets total number of iterations used in primal and dual simplex and barrier algorithm for the first LP at the root
434  * node
435  *
436  * @return the total number of iterations used in primal and dual simplex and barrier algorithm for the first root LP
437  *
438  * @pre This method can be called if SCIP is in one of the following stages:
439  * - \ref SCIP_STAGE_PRESOLVED
440  * - \ref SCIP_STAGE_SOLVING
441  * - \ref SCIP_STAGE_SOLVED
442  */
444  SCIP* scip /**< SCIP data structure */
445  )
446 {
447  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNRootFirstLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
448 
449  return scip->stat->nrootfirstlpiterations;
450 }
451 
452 /** gets total number of primal LPs solved so far
453  *
454  * @return the total number of primal LPs solved so far
455  *
456  * @pre This method can be called if SCIP is in one of the following stages:
457  * - \ref SCIP_STAGE_PRESOLVED
458  * - \ref SCIP_STAGE_SOLVING
459  * - \ref SCIP_STAGE_SOLVED
460  */
462  SCIP* scip /**< SCIP data structure */
463  )
464 {
465  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPrimalLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
466 
467  return scip->stat->nprimallps;
468 }
469 
470 /** gets total number of iterations used so far in primal simplex
471  *
472  * @return total number of iterations used so far in primal simplex
473  *
474  * @pre This method can be called if SCIP is in one of the following stages:
475  * - \ref SCIP_STAGE_PRESOLVED
476  * - \ref SCIP_STAGE_SOLVING
477  * - \ref SCIP_STAGE_SOLVED
478  */
480  SCIP* scip /**< SCIP data structure */
481  )
482 {
483  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPrimalLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
484 
485  return scip->stat->nprimallpiterations;
486 }
487 
488 /** gets total number of dual LPs solved so far
489  *
490  * @return the total number of dual LPs solved so far
491  *
492  * @pre This method can be called if SCIP is in one of the following stages:
493  * - \ref SCIP_STAGE_PRESOLVED
494  * - \ref SCIP_STAGE_SOLVING
495  * - \ref SCIP_STAGE_SOLVED
496  */
498  SCIP* scip /**< SCIP data structure */
499  )
500 {
501  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNDualLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
502 
503  return scip->stat->nduallps;
504 }
505 
506 /** gets total number of iterations used so far in dual simplex
507  *
508  * @return the total number of iterations used so far in dual simplex
509  *
510  * @pre This method can be called if SCIP is in one of the following stages:
511  * - \ref SCIP_STAGE_PRESOLVED
512  * - \ref SCIP_STAGE_SOLVING
513  * - \ref SCIP_STAGE_SOLVED
514  */
516  SCIP* scip /**< SCIP data structure */
517  )
518 {
519  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNDualLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
520 
521  return scip->stat->nduallpiterations;
522 }
523 
524 /** gets total number of barrier LPs solved so far
525  *
526  * @return the total number of barrier LPs solved so far
527  *
528  * @pre This method can be called if SCIP is in one of the following stages:
529  * - \ref SCIP_STAGE_PRESOLVED
530  * - \ref SCIP_STAGE_SOLVING
531  * - \ref SCIP_STAGE_SOLVED
532  */
534  SCIP* scip /**< SCIP data structure */
535  )
536 {
537  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNBarrierLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
538 
539  return scip->stat->nbarrierlps;
540 }
541 
542 /** gets total number of iterations used so far in barrier algorithm
543  *
544  * @return the total number of iterations used so far in barrier algorithm
545  *
546  * @pre This method can be called if SCIP is in one of the following stages:
547  * - \ref SCIP_STAGE_PRESOLVED
548  * - \ref SCIP_STAGE_SOLVING
549  * - \ref SCIP_STAGE_SOLVED
550  */
552  SCIP* scip /**< SCIP data structure */
553  )
554 {
555  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNBarrierLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
556 
557  return scip->stat->nbarrierlpiterations;
558 }
559 
560 /** gets total number of LPs solved so far that were resolved from an advanced start basis
561  *
562  * @return the total number of LPs solved so far that were resolved from an advanced start basis
563  *
564  * @pre This method can be called if SCIP is in one of the following stages:
565  * - \ref SCIP_STAGE_PRESOLVED
566  * - \ref SCIP_STAGE_SOLVING
567  * - \ref SCIP_STAGE_SOLVED
568  */
570  SCIP* scip /**< SCIP data structure */
571  )
572 {
573  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNResolveLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
574 
575  return scip->stat->nprimalresolvelps + scip->stat->ndualresolvelps;
576 }
577 
578 /** gets total number of simplex iterations used so far in primal and dual simplex calls where an advanced start basis
579  * was available
580  *
581  * @return the total number of simplex iterations used so far in primal and dual simplex calls where an advanced start
582  * basis was available
583  *
584  * @pre This method can be called if SCIP is in one of the following stages:
585  * - \ref SCIP_STAGE_PRESOLVED
586  * - \ref SCIP_STAGE_SOLVING
587  * - \ref SCIP_STAGE_SOLVED
588  */
590  SCIP* scip /**< SCIP data structure */
591  )
592 {
593  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNResolveLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
594 
596 }
597 
598 /** gets total number of primal LPs solved so far that were resolved from an advanced start basis
599  *
600  * @return the total number of primal LPs solved so far that were resolved from an advanced start basis
601  *
602  * @pre This method can be called if SCIP is in one of the following stages:
603  * - \ref SCIP_STAGE_PRESOLVED
604  * - \ref SCIP_STAGE_SOLVING
605  * - \ref SCIP_STAGE_SOLVED
606  */
608  SCIP* scip /**< SCIP data structure */
609  )
610 {
611  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPrimalResolveLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
612 
613  return scip->stat->nprimalresolvelps;
614 }
615 
616 /** gets total number of simplex iterations used so far in primal simplex calls where an advanced start basis
617  * was available
618  *
619  * @return the total number of simplex iterations used so far in primal simplex calls where an advanced start
620  * basis was available
621  *
622  * @pre This method can be called if SCIP is in one of the following stages:
623  * - \ref SCIP_STAGE_PRESOLVED
624  * - \ref SCIP_STAGE_SOLVING
625  * - \ref SCIP_STAGE_SOLVED
626  */
628  SCIP* scip /**< SCIP data structure */
629  )
630 {
631  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPrimalResolveLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
632 
633  return scip->stat->nprimalresolvelpiterations;
634 }
635 
636 /** gets total number of dual LPs solved so far that were resolved from an advanced start basis
637  *
638  * @return the total number of dual LPs solved so far that were resolved from an advanced start basis
639  *
640  * @pre This method can be called if SCIP is in one of the following stages:
641  * - \ref SCIP_STAGE_PRESOLVED
642  * - \ref SCIP_STAGE_SOLVING
643  * - \ref SCIP_STAGE_SOLVED
644  */
646  SCIP* scip /**< SCIP data structure */
647  )
648 {
649  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNDualResolveLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
650 
651  return scip->stat->ndualresolvelps;
652 }
653 
654 /** gets total number of simplex iterations used so far in dual simplex calls where an advanced start basis
655  * was available
656  *
657  * @return the total number of simplex iterations used so far in dual simplex calls where an advanced start
658  * basis was available
659  *
660  * @pre This method can be called if SCIP is in one of the following stages:
661  * - \ref SCIP_STAGE_PRESOLVED
662  * - \ref SCIP_STAGE_SOLVING
663  * - \ref SCIP_STAGE_SOLVED
664  */
666  SCIP* scip /**< SCIP data structure */
667  )
668 {
669  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNDualResolveLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
670 
671  return scip->stat->ndualresolvelpiterations;
672 }
673 
674 /** gets total number of LPs solved so far for node relaxations
675  *
676  * @return the total number of LPs solved so far for node relaxations
677  *
678  * @pre This method can be called if SCIP is in one of the following stages:
679  * - \ref SCIP_STAGE_PRESOLVED
680  * - \ref SCIP_STAGE_SOLVING
681  * - \ref SCIP_STAGE_SOLVED
682  */
684  SCIP* scip /**< SCIP data structure */
685  )
686 {
687  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNNodeLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
688 
689  return scip->stat->nnodelps;
690 }
691 
692 /** gets total number of simplex iterations used so far for node relaxations
693  *
694  * @return the total number of simplex iterations used so far for node relaxations
695  *
696  * @pre This method can be called if SCIP is in one of the following stages:
697  * - \ref SCIP_STAGE_PRESOLVED
698  * - \ref SCIP_STAGE_SOLVING
699  * - \ref SCIP_STAGE_SOLVED
700  */
702  SCIP* scip /**< SCIP data structure */
703  )
704 {
705  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNNodeLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
706 
707  return scip->stat->nnodelpiterations;
708 }
709 
710 /** gets total number of LPs solved so far for initial LP in node relaxations
711  *
712  * @return the total number of LPs solved so far for initial LP in node relaxations
713  *
714  * @pre This method can be called if SCIP is in one of the following stages:
715  * - \ref SCIP_STAGE_PRESOLVED
716  * - \ref SCIP_STAGE_SOLVING
717  * - \ref SCIP_STAGE_SOLVED
718  */
720  SCIP* scip /**< SCIP data structure */
721  )
722 {
723  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNNodeInitLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
724 
725  return scip->stat->ninitlps;
726 }
727 
728 /** gets total number of simplex iterations used so far for initial LP in node relaxations
729  *
730  * @return the total number of simplex iterations used so far for initial LP in node relaxations
731  *
732  * @pre This method can be called if SCIP is in one of the following stages:
733  * - \ref SCIP_STAGE_PRESOLVED
734  * - \ref SCIP_STAGE_SOLVING
735  * - \ref SCIP_STAGE_SOLVED
736  */
738  SCIP* scip /**< SCIP data structure */
739  )
740 {
741  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNNodeInitLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
742 
743  return scip->stat->ninitlpiterations;
744 }
745 
746 /** gets total number of LPs solved so far during diving and probing
747  *
748  * @return total number of LPs solved so far during diving and probing
749  *
750  * @pre This method can be called if SCIP is in one of the following stages:
751  * - \ref SCIP_STAGE_PRESOLVED
752  * - \ref SCIP_STAGE_SOLVING
753  * - \ref SCIP_STAGE_SOLVED
754  */
756  SCIP* scip /**< SCIP data structure */
757  )
758 {
759  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNDivingLPs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
760 
761  return scip->stat->ndivinglps;
762 }
763 
764 /** gets total number of simplex iterations used so far during diving and probing
765  *
766  * @return the total number of simplex iterations used so far during diving and probing
767  *
768  * @pre This method can be called if SCIP is in one of the following stages:
769  * - \ref SCIP_STAGE_PRESOLVED
770  * - \ref SCIP_STAGE_SOLVING
771  * - \ref SCIP_STAGE_SOLVED
772  */
774  SCIP* scip /**< SCIP data structure */
775  )
776 {
777  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNDivingLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
778 
779  return scip->stat->ndivinglpiterations;
780 }
781 
782 /** gets total number of times, strong branching was called (each call represents solving two LPs)
783  *
784  * @return the total number of times, strong branching was called (each call represents solving two LPs)
785  *
786  * @pre This method can be called if SCIP is in one of the following stages:
787  * - \ref SCIP_STAGE_PRESOLVED
788  * - \ref SCIP_STAGE_SOLVING
789  * - \ref SCIP_STAGE_SOLVED
790  */
792  SCIP* scip /**< SCIP data structure */
793  )
794 {
795  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNStrongbranchs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
796 
797  return scip->stat->nstrongbranchs;
798 }
799 
800 /** gets total number of simplex iterations used so far in strong branching
801  *
802  * @return the total number of simplex iterations used so far in strong branching
803  *
804  * @pre This method can be called if SCIP is in one of the following stages:
805  * - \ref SCIP_STAGE_PRESOLVED
806  * - \ref SCIP_STAGE_SOLVING
807  * - \ref SCIP_STAGE_SOLVED
808  */
810  SCIP* scip /**< SCIP data structure */
811  )
812 {
813  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNStrongbranchLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
814 
815  return scip->stat->nsblpiterations;
816 }
817 
818 /** gets total number of times, strong branching was called at the root node (each call represents solving two LPs)
819  *
820  * @return the total number of times, strong branching was called at the root node (each call represents solving two LPs)
821  *
822  * @pre This method can be called if SCIP is in one of the following stages:
823  * - \ref SCIP_STAGE_PRESOLVED
824  * - \ref SCIP_STAGE_SOLVING
825  * - \ref SCIP_STAGE_SOLVED
826  */
828  SCIP* scip /**< SCIP data structure */
829  )
830 {
831  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNRootStrongbranchs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
832 
833  return scip->stat->nrootstrongbranchs;
834 }
835 
836 /** gets total number of simplex iterations used so far in strong branching at the root node
837  *
838  * @return the total number of simplex iterations used so far in strong branching at the root node
839  *
840  * @pre This method can be called if SCIP is in one of the following stages:
841  * - \ref SCIP_STAGE_PRESOLVED
842  * - \ref SCIP_STAGE_SOLVING
843  * - \ref SCIP_STAGE_SOLVED
844  */
846  SCIP* scip /**< SCIP data structure */
847  )
848 {
849  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNRootStrongbranchLPIterations", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
850 
851  return scip->stat->nrootsblpiterations;
852 }
853 
854 /** gets number of pricing rounds performed so far at the current node
855  *
856  * @return the number of pricing rounds performed so far at the current node
857  *
858  * @pre This method can be called if SCIP is in one of the following stages:
859  * - \ref SCIP_STAGE_SOLVING
860  */
862  SCIP* scip /**< SCIP data structure */
863  )
864 {
865  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPriceRounds", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE) );
866 
867  return scip->stat->npricerounds;
868 }
869 
870 /** get current number of variables in the pricing store
871  *
872  * @return the current number of variables in the pricing store
873  *
874  * @pre This method can be called if SCIP is in one of the following stages:
875  * - \ref SCIP_STAGE_PRESOLVED
876  * - \ref SCIP_STAGE_SOLVING
877  * - \ref SCIP_STAGE_SOLVED
878  */
880  SCIP* scip /**< SCIP data structure */
881  )
882 {
883  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPricevars", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
884 
885  return SCIPpricestoreGetNVars(scip->pricestore);
886 }
887 
888 /** get total number of pricing variables found so far
889  *
890  * @return the total number of pricing variables found so far
891  *
892  * @pre This method can be called if SCIP is in one of the following stages:
893  * - \ref SCIP_STAGE_PRESOLVED
894  * - \ref SCIP_STAGE_SOLVING
895  * - \ref SCIP_STAGE_SOLVED
896  */
898  SCIP* scip /**< SCIP data structure */
899  )
900 {
901  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPricevarsFound", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
902 
904 }
905 
906 /** get total number of pricing variables applied to the LPs
907  *
908  * @return the total number of pricing variables applied to the LPs
909  *
910  * @pre This method can be called if SCIP is in one of the following stages:
911  * - \ref SCIP_STAGE_PRESOLVED
912  * - \ref SCIP_STAGE_SOLVING
913  * - \ref SCIP_STAGE_SOLVED
914  */
916  SCIP* scip /**< SCIP data structure */
917  )
918 {
919  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNPricevarsApplied", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
920 
922 }
923 
924 /** gets number of separation rounds performed so far at the current node
925  *
926  * @return the number of separation rounds performed so far at the current node
927  *
928  * @pre This method can be called if SCIP is in one of the following stages:
929  * - \ref SCIP_STAGE_SOLVING
930  */
932  SCIP* scip /**< SCIP data structure */
933  )
934 {
935  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNSepaRounds", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE) );
936 
937  return scip->stat->nseparounds;
938 }
939 
940 /** get total number of cuts found so far
941  *
942  * @return the total number of cuts found so far
943  *
944  * @pre This method can be called if SCIP is in one of the following stages:
945  * - \ref SCIP_STAGE_PRESOLVED
946  * - \ref SCIP_STAGE_SOLVING
947  * - \ref SCIP_STAGE_SOLVED
948  */
950  SCIP* scip /**< SCIP data structure */
951  )
952 {
953  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNCutsFound", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
954 
956 }
957 
958 /** get number of cuts found so far in current separation round
959  *
960  * @return the number of cuts found so far in current separation round
961  *
962  * @pre This method can be called if SCIP is in one of the following stages:
963  * - \ref SCIP_STAGE_PRESOLVED
964  * - \ref SCIP_STAGE_SOLVING
965  * - \ref SCIP_STAGE_SOLVED
966  */
968  SCIP* scip /**< SCIP data structure */
969  )
970 {
971  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNCutsFoundRound", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
972 
974 }
975 
976 /** get total number of cuts applied to the LPs
977  *
978  * @return the total number of cuts applied to the LPs
979  *
980  * @pre This method can be called if SCIP is in one of the following stages:
981  * - \ref SCIP_STAGE_PRESOLVED
982  * - \ref SCIP_STAGE_SOLVING
983  * - \ref SCIP_STAGE_SOLVED
984  */
986  SCIP* scip /**< SCIP data structure */
987  )
988 {
989  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNCutsApplied", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
990 
992 }
993 
994 /** get total number of constraints found in conflict analysis (conflict, reconvergence constraints, and dual proofs)
995  *
996  * @return the total number of constraints found in conflict analysis (conflict, reconvergence constraints, and dual proofs)
997  *
998  * @pre This method can be called if SCIP is in one of the following stages:
999  * - \ref SCIP_STAGE_TRANSFORMED
1000  * - \ref SCIP_STAGE_INITPRESOLVE
1001  * - \ref SCIP_STAGE_PRESOLVING
1002  * - \ref SCIP_STAGE_EXITPRESOLVE
1003  * - \ref SCIP_STAGE_PRESOLVED
1004  * - \ref SCIP_STAGE_INITSOLVE
1005  * - \ref SCIP_STAGE_SOLVING
1006  * - \ref SCIP_STAGE_SOLVED
1007  * - \ref SCIP_STAGE_EXITSOLVE
1008  */
1010  SCIP* scip /**< SCIP data structure */
1011  )
1012 {
1013  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNConflictConssFound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1014 
1027 }
1028 
1029 /** get number of conflict constraints found so far at the current node
1030  *
1031  * @return the number of conflict constraints found so far at the current node
1032  *
1033  * @pre This method can be called if SCIP is in one of the following stages:
1034  * - \ref SCIP_STAGE_TRANSFORMED
1035  * - \ref SCIP_STAGE_INITPRESOLVE
1036  * - \ref SCIP_STAGE_PRESOLVING
1037  * - \ref SCIP_STAGE_EXITPRESOLVE
1038  * - \ref SCIP_STAGE_PRESOLVED
1039  * - \ref SCIP_STAGE_INITSOLVE
1040  * - \ref SCIP_STAGE_SOLVING
1041  * - \ref SCIP_STAGE_SOLVED
1042  * - \ref SCIP_STAGE_EXITSOLVE
1043  */
1045  SCIP* scip /**< SCIP data structure */
1046  )
1047 {
1048  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNConflictConssFoundNode", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1049 
1050  return SCIPconflictGetNConflicts(scip->conflict);
1051 }
1052 
1053 /** get total number of conflict constraints added to the problem
1054  *
1055  * @return the total number of conflict constraints added to the problem
1056  *
1057  * @pre This method can be called if SCIP is in one of the following stages:
1058  * - \ref SCIP_STAGE_TRANSFORMED
1059  * - \ref SCIP_STAGE_INITPRESOLVE
1060  * - \ref SCIP_STAGE_PRESOLVING
1061  * - \ref SCIP_STAGE_EXITPRESOLVE
1062  * - \ref SCIP_STAGE_PRESOLVED
1063  * - \ref SCIP_STAGE_INITSOLVE
1064  * - \ref SCIP_STAGE_SOLVING
1065  * - \ref SCIP_STAGE_SOLVED
1066  * - \ref SCIP_STAGE_EXITSOLVE
1067  */
1069  SCIP* scip /**< SCIP data structure */
1070  )
1071 {
1072  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNConflictConssApplied", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1073 
1074  return SCIPconflictGetNAppliedConss(scip->conflict);
1075 }
1076 
1077 /** gets maximal depth of all processed nodes in current branch and bound run (excluding probing nodes)
1078  *
1079  * @return the maximal depth of all processed nodes in current branch and bound run (excluding probing nodes)
1080  *
1081  * @pre This method can be called if SCIP is in one of the following stages:
1082  * - \ref SCIP_STAGE_TRANSFORMED
1083  * - \ref SCIP_STAGE_INITPRESOLVE
1084  * - \ref SCIP_STAGE_PRESOLVING
1085  * - \ref SCIP_STAGE_EXITPRESOLVE
1086  * - \ref SCIP_STAGE_PRESOLVED
1087  * - \ref SCIP_STAGE_INITSOLVE
1088  * - \ref SCIP_STAGE_SOLVING
1089  * - \ref SCIP_STAGE_SOLVED
1090  * - \ref SCIP_STAGE_EXITSOLVE
1091  */
1093  SCIP* scip /**< SCIP data structure */
1094  )
1095 {
1096  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetMaxDepth", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1097 
1098  return scip->stat->maxdepth;
1099 }
1100 
1101 /** gets maximal depth of all processed nodes over all branch and bound runs
1102  *
1103  * @return the maximal depth of all processed nodes over all branch and bound runs
1104  *
1105  * @pre This method can be called if SCIP is in one of the following stages:
1106  * - \ref SCIP_STAGE_TRANSFORMED
1107  * - \ref SCIP_STAGE_INITPRESOLVE
1108  * - \ref SCIP_STAGE_PRESOLVING
1109  * - \ref SCIP_STAGE_EXITPRESOLVE
1110  * - \ref SCIP_STAGE_PRESOLVED
1111  * - \ref SCIP_STAGE_INITSOLVE
1112  * - \ref SCIP_STAGE_SOLVING
1113  * - \ref SCIP_STAGE_SOLVED
1114  * - \ref SCIP_STAGE_EXITSOLVE
1115  */
1117  SCIP* scip /**< SCIP data structure */
1118  )
1119 {
1120  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetMaxTotalDepth", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1121 
1122  return scip->stat->maxtotaldepth;
1123 }
1124 
1125 /** gets total number of backtracks, i.e. number of times, the new node was selected from the leaves queue
1126  *
1127  * @return the total number of backtracks, i.e. number of times, the new node was selected from the leaves queue
1128  *
1129  * @pre This method can be called if SCIP is in one of the following stages:
1130  * - \ref SCIP_STAGE_TRANSFORMED
1131  * - \ref SCIP_STAGE_INITPRESOLVE
1132  * - \ref SCIP_STAGE_PRESOLVING
1133  * - \ref SCIP_STAGE_EXITPRESOLVE
1134  * - \ref SCIP_STAGE_PRESOLVED
1135  * - \ref SCIP_STAGE_INITSOLVE
1136  * - \ref SCIP_STAGE_SOLVING
1137  * - \ref SCIP_STAGE_SOLVED
1138  * - \ref SCIP_STAGE_EXITSOLVE
1139  */
1141  SCIP* scip /**< SCIP data structure */
1142  )
1143 {
1144  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNBacktracks", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1145 
1146  return scip->stat->nbacktracks;
1147 }
1148 
1149 /** gets total number of active constraints at the current node
1150  *
1151  * @return the total number of active constraints at the current node
1152  *
1153  * @pre This method can be called if SCIP is in one of the following stages:
1154  * - \ref SCIP_STAGE_INITPRESOLVE
1155  * - \ref SCIP_STAGE_PRESOLVING
1156  * - \ref SCIP_STAGE_EXITPRESOLVE
1157  * - \ref SCIP_STAGE_PRESOLVED
1158  * - \ref SCIP_STAGE_SOLVING
1159  */
1161  SCIP* scip /**< SCIP data structure */
1162  )
1163 {
1164  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNActiveConss", FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE) );
1165 
1166  return scip->stat->nactiveconss;
1167 }
1168 
1169 /** gets total number of enabled constraints at the current node
1170  *
1171  * @return the total number of enabled constraints at the current node
1172  *
1173  * @pre This method can be called if SCIP is in one of the following stages:
1174  * - \ref SCIP_STAGE_PRESOLVED
1175  * - \ref SCIP_STAGE_SOLVING
1176  */
1178  SCIP* scip /**< SCIP data structure */
1179  )
1180 {
1181  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNEnabledConss", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE) );
1182 
1183  return scip->stat->nenabledconss;
1184 }
1185 
1186 /** gets average dual bound of all unprocessed nodes for original problem
1187  *
1188  * @return the average dual bound of all unprocessed nodes for original problem
1189  *
1190  * @pre This method can be called if SCIP is in one of the following stages:
1191  * - \ref SCIP_STAGE_PRESOLVED
1192  * - \ref SCIP_STAGE_SOLVING
1193  * - \ref SCIP_STAGE_SOLVED
1194  */
1196  SCIP* scip /**< SCIP data structure */
1197  )
1198 {
1199  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgDualbound", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1200 
1201  return SCIPprobExternObjval(scip->transprob, scip->origprob, scip->set,
1203 }
1204 
1205 /** gets average lower (dual) bound of all unprocessed nodes in transformed problem
1206  *
1207  * @return the average lower (dual) bound of all unprocessed nodes in transformed problem
1208  *
1209  * @pre This method can be called if SCIP is in one of the following stages:
1210  * - \ref SCIP_STAGE_PRESOLVED
1211  * - \ref SCIP_STAGE_SOLVING
1212  * - \ref SCIP_STAGE_SOLVED
1213  */
1215  SCIP* scip /**< SCIP data structure */
1216  )
1217 {
1218  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgLowerbound", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1219 
1220  return SCIPtreeGetAvgLowerbound(scip->tree, scip->primal->cutoffbound);
1221 }
1222 
1223 /** gets global dual bound
1224  *
1225  * @return the global dual bound
1226  *
1227  * @pre This method can be called if SCIP is in one of the following stages:
1228  * - \ref SCIP_STAGE_TRANSFORMED
1229  * - \ref SCIP_STAGE_INITPRESOLVE
1230  * - \ref SCIP_STAGE_PRESOLVING
1231  * - \ref SCIP_STAGE_EXITPRESOLVE
1232  * - \ref SCIP_STAGE_PRESOLVED
1233  * - \ref SCIP_STAGE_INITSOLVE
1234  * - \ref SCIP_STAGE_SOLVING
1235  * - \ref SCIP_STAGE_SOLVED
1236  * - \ref SCIP_STAGE_EXITSOLVE
1237  */
1239  SCIP* scip /**< SCIP data structure */
1240  )
1241 {
1242  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetDualbound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1243 
1244  /* in case we are in presolving we use the stored dual bound if it exits */
1245  if( scip->set->stage <= SCIP_STAGE_INITSOLVE && scip->transprob->dualbound < SCIP_INVALID )
1246  return scip->transprob->dualbound;
1247 
1248  return SCIPprobExternObjval(scip->transprob, scip->origprob, scip->set, SCIPgetLowerbound(scip));
1249 }
1250 
1251 /** gets global lower (dual) bound in transformed problem
1252  *
1253  * @return the global lower (dual) bound in transformed problem
1254  *
1255  * @pre This method can be called if SCIP is in one of the following stages:
1256  * - \ref SCIP_STAGE_TRANSFORMED
1257  * - \ref SCIP_STAGE_INITPRESOLVE
1258  * - \ref SCIP_STAGE_PRESOLVING
1259  * - \ref SCIP_STAGE_EXITPRESOLVE
1260  * - \ref SCIP_STAGE_PRESOLVED
1261  * - \ref SCIP_STAGE_INITSOLVE
1262  * - \ref SCIP_STAGE_SOLVING
1263  * - \ref SCIP_STAGE_SOLVED
1264  */
1266  SCIP* scip /**< SCIP data structure */
1267  )
1268 {
1269  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetLowerbound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1270 
1271  if( scip->set->stage <= SCIP_STAGE_INITSOLVE )
1272  return -SCIPinfinity(scip);
1274  {
1275  /* in case we could not prove whether the problem is unbounded or infeasible, we want to terminate with lower
1276  * bound = -inf instead of lower bound = upper bound = +inf also in case we prove that the problem is unbounded,
1277  * it seems to make sense to return with lower bound = -inf, since -infinity is the only valid lower bound
1278  */
1279  return -SCIPinfinity(scip);
1280  }
1281  else
1282  {
1283  SCIP_Real treelowerbound;
1284 
1285  /* it may happen that the remaining tree is empty or all open nodes have a lower bound above the cutoff bound, but
1286  * have not yet been cut off, e.g., when the user calls SCIPgetDualbound() in some event handler; in this case,
1287  * the global lower bound is given by the upper bound value
1288  */
1289  treelowerbound = SCIPtreeGetLowerbound(scip->tree, scip->set);
1290 
1291  if( treelowerbound < scip->primal->upperbound)
1292  return treelowerbound;
1293  else
1294  return scip->primal->upperbound;
1295  }
1296 }
1297 
1298 /** gets dual bound of the root node for the original problem
1299  *
1300  * @return the dual bound of the root node for the original problem
1301  *
1302  * @pre This method can be called if SCIP is in one of the following stages:
1303  * - \ref SCIP_STAGE_PRESOLVING
1304  * - \ref SCIP_STAGE_EXITPRESOLVE
1305  * - \ref SCIP_STAGE_PRESOLVED
1306  * - \ref SCIP_STAGE_INITSOLVE
1307  * - \ref SCIP_STAGE_SOLVING
1308  * - \ref SCIP_STAGE_SOLVED
1309  */
1311  SCIP* scip /**< SCIP data structure */
1312  )
1313 {
1314  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetDualboundRoot", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1315 
1316  if( SCIPsetIsInfinity(scip->set, scip->stat->rootlowerbound) )
1317  return SCIPgetPrimalbound(scip);
1318  else
1319  return SCIPprobExternObjval(scip->transprob, scip->origprob, scip->set, scip->stat->rootlowerbound);
1320 }
1321 
1322 /** gets lower (dual) bound in transformed problem of the root node
1323  *
1324  * @return the lower (dual) bound in transformed problem of the root node
1325  *
1326  * @pre This method can be called if SCIP is in one of the following stages:
1327  * - \ref SCIP_STAGE_PRESOLVING
1328  * - \ref SCIP_STAGE_EXITPRESOLVE
1329  * - \ref SCIP_STAGE_PRESOLVED
1330  * - \ref SCIP_STAGE_INITSOLVE
1331  * - \ref SCIP_STAGE_SOLVING
1332  * - \ref SCIP_STAGE_SOLVED
1333  */
1335  SCIP* scip /**< SCIP data structure */
1336  )
1337 {
1338  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetLowerboundRoot", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1339 
1340  if( SCIPsetIsInfinity(scip->set, scip->stat->rootlowerbound) )
1341  return SCIPgetUpperbound(scip);
1342  else
1343  return scip->stat->rootlowerbound;
1344 }
1345 
1346 /** gets dual bound for the original problem obtained by the first LP solve at the root node
1347  *
1348  * @return the dual bound for the original problem of the first LP solve at the root node
1349  *
1350  * @pre This method can be called if SCIP is in one of the following stages:
1351  * - \ref SCIP_STAGE_PRESOLVING
1352  * - \ref SCIP_STAGE_EXITPRESOLVE
1353  * - \ref SCIP_STAGE_PRESOLVED
1354  * - \ref SCIP_STAGE_INITSOLVE
1355  * - \ref SCIP_STAGE_SOLVING
1356  * - \ref SCIP_STAGE_SOLVED
1357  */
1359  SCIP* scip /**< SCIP data structure */
1360  )
1361 {
1362  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetFirstLPDualboundRoot", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1363 
1364  return scip->stat->firstlpdualbound;
1365 }
1366 
1367 /** gets lower (dual) bound in transformed problem obtained by the first LP solve at the root node
1368  *
1369  * @return the lower (dual) bound in transformed problem obtained by first LP solve at the root node
1370  *
1371  * @pre This method can be called if SCIP is in one of the following stages:
1372  * - \ref SCIP_STAGE_PRESOLVING
1373  * - \ref SCIP_STAGE_EXITPRESOLVE
1374  * - \ref SCIP_STAGE_PRESOLVED
1375  * - \ref SCIP_STAGE_INITSOLVE
1376  * - \ref SCIP_STAGE_SOLVING
1377  * - \ref SCIP_STAGE_SOLVED
1378  */
1380  SCIP* scip /**< SCIP data structure */
1381  )
1382 {
1383  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetFirstLPLowerboundRoot", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1384 
1385  if( scip->stat->firstlpdualbound == SCIP_INVALID ) /*lint !e777*/
1386  return -SCIPinfinity(scip);
1387  else
1388  return SCIPprobInternObjval(scip->transprob, scip->origprob, scip->set, scip->stat->firstlpdualbound);
1389 }
1390 
1391 /** the primal bound of the very first solution */
1393  SCIP* scip /**< SCIP data structure */
1394  )
1395 {
1396  return scip->stat->firstprimalbound;
1397 }
1398 
1399 /** gets global primal bound (objective value of best solution or user objective limit) for the original problem
1400  *
1401  * @return the global primal bound (objective value of best solution or user objective limit) for the original problem
1402  *
1403  * @pre This method can be called if SCIP is in one of the following stages:
1404  * - \ref SCIP_STAGE_TRANSFORMED
1405  * - \ref SCIP_STAGE_INITPRESOLVE
1406  * - \ref SCIP_STAGE_PRESOLVING
1407  * - \ref SCIP_STAGE_EXITPRESOLVE
1408  * - \ref SCIP_STAGE_PRESOLVED
1409  * - \ref SCIP_STAGE_INITSOLVE
1410  * - \ref SCIP_STAGE_SOLVING
1411  * - \ref SCIP_STAGE_SOLVED
1412  * - \ref SCIP_STAGE_EXITSOLVE
1413  */
1415  SCIP* scip /**< SCIP data structure */
1416  )
1417 {
1418  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetPrimalbound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1419 
1420  return SCIPprobExternObjval(scip->transprob, scip->origprob, scip->set, SCIPgetUpperbound(scip));
1421 }
1422 
1423 /** gets global upper (primal) bound in transformed problem (objective value of best solution or user objective limit)
1424  *
1425  * @return the global upper (primal) bound in transformed problem (objective value of best solution or user objective limit)
1426  *
1427  * @pre This method can be called if SCIP is in one of the following stages:
1428  * - \ref SCIP_STAGE_TRANSFORMED
1429  * - \ref SCIP_STAGE_INITPRESOLVE
1430  * - \ref SCIP_STAGE_PRESOLVING
1431  * - \ref SCIP_STAGE_EXITPRESOLVE
1432  * - \ref SCIP_STAGE_PRESOLVED
1433  * - \ref SCIP_STAGE_INITSOLVE
1434  * - \ref SCIP_STAGE_SOLVING
1435  * - \ref SCIP_STAGE_SOLVED
1436  * - \ref SCIP_STAGE_EXITSOLVE
1437  */
1439  SCIP* scip /**< SCIP data structure */
1440  )
1441 {
1442  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetUpperbound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1443 
1444  if( SCIPgetStatus(scip) == SCIP_STATUS_UNBOUNDED )
1445  return -SCIPinfinity(scip);
1446  else
1447  return scip->primal->upperbound;
1448 }
1449 
1450 /** gets global cutoff bound in transformed problem: a sub problem with lower bound larger than the cutoff
1451  * cannot contain a better feasible solution; usually, this bound is equal to the upper bound, but if the
1452  * objective value is always integral, the cutoff bound is (nearly) one less than the upper bound;
1453  * additionally, due to objective function domain propagation, the cutoff bound can be further reduced
1454  *
1455  * @return global cutoff bound in transformed problem
1456  *
1457  * @pre This method can be called if SCIP is in one of the following stages:
1458  * - \ref SCIP_STAGE_TRANSFORMED
1459  * - \ref SCIP_STAGE_INITPRESOLVE
1460  * - \ref SCIP_STAGE_PRESOLVING
1461  * - \ref SCIP_STAGE_EXITPRESOLVE
1462  * - \ref SCIP_STAGE_PRESOLVED
1463  * - \ref SCIP_STAGE_INITSOLVE
1464  * - \ref SCIP_STAGE_SOLVING
1465  * - \ref SCIP_STAGE_SOLVED
1466  * - \ref SCIP_STAGE_EXITSOLVE
1467  */
1469  SCIP* scip /**< SCIP data structure */
1470  )
1471 {
1472  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetCutoffbound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1473 
1474  return scip->primal->cutoffbound;
1475 }
1476 
1477 /** updates the cutoff bound
1478  *
1479  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1480  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1481  *
1482  * @note using this method in the solving stage can lead to an erroneous SCIP solving status; in particular,
1483  * if a solution not respecting the cutoff bound was found before installing a cutoff bound which
1484  * renders the remaining problem infeasible, this solution may be reported as optimal
1485  *
1486  * @pre This method can be called if SCIP is in one of the following stages:
1487  * - \ref SCIP_STAGE_TRANSFORMED
1488  * - \ref SCIP_STAGE_PRESOLVING
1489  * - \ref SCIP_STAGE_PRESOLVED
1490  * - \ref SCIP_STAGE_INITSOLVE
1491  * - \ref SCIP_STAGE_SOLVING
1492  *
1493  * @note the given cutoff bound has to better or equal to known one (SCIPgetCutoffbound())
1494  * @note a given cutoff bound is also used for updating the objective limit, if possible
1495  */
1497  SCIP* scip, /**< SCIP data structure */
1498  SCIP_Real cutoffbound /**< new cutoff bound */
1499  )
1500 {
1501  SCIP_CALL( SCIPcheckStage(scip, "SCIPupdateCutoffbound", FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE) );
1502 
1503  assert(cutoffbound <= SCIPgetCutoffbound(scip));
1504 
1505  SCIP_CALL( SCIPprimalSetCutoffbound(scip->primal, scip->mem->probmem, scip->set, scip->stat, scip->eventqueue,
1506  scip->transprob, scip->origprob, scip->tree, scip->reopt, scip->lp, cutoffbound, FALSE) );
1507 
1508  return SCIP_OKAY;
1509 }
1510 
1511 
1512 /** returns whether the current primal bound is justified with a feasible primal solution; if not, the primal bound
1513  * was set from the user as objective limit
1514  *
1515  * @return TRUE if the current primal bound is justified with a feasible primal solution, otherwise FALSE
1516  *
1517  * @pre This method can be called if SCIP is in one of the following stages:
1518  * - \ref SCIP_STAGE_TRANSFORMED
1519  * - \ref SCIP_STAGE_INITPRESOLVE
1520  * - \ref SCIP_STAGE_PRESOLVING
1521  * - \ref SCIP_STAGE_EXITPRESOLVE
1522  * - \ref SCIP_STAGE_PRESOLVED
1523  * - \ref SCIP_STAGE_INITSOLVE
1524  * - \ref SCIP_STAGE_SOLVING
1525  * - \ref SCIP_STAGE_SOLVED
1526  * - \ref SCIP_STAGE_EXITSOLVE
1527  */
1529  SCIP* scip /**< SCIP data structure */
1530  )
1531 {
1532  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPisPrimalboundSol", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1533 
1534  return SCIPprimalUpperboundIsSol(scip->primal, scip->set, scip->transprob, scip->origprob);
1535 }
1536 
1537 /** gets current gap |(primalbound - dualbound)/min(|primalbound|,|dualbound|)| if both bounds have same sign,
1538  * or infinity, if they have opposite sign
1539  *
1540  * @return the current gap |(primalbound - dualbound)/min(|primalbound|,|dualbound|)| if both bounds have same sign,
1541  * or infinity, if they have opposite sign
1542  *
1543  * @pre This method can be called if SCIP is in one of the following stages:
1544  * - \ref SCIP_STAGE_PRESOLVING
1545  * - \ref SCIP_STAGE_EXITPRESOLVE
1546  * - \ref SCIP_STAGE_PRESOLVED
1547  * - \ref SCIP_STAGE_INITSOLVE
1548  * - \ref SCIP_STAGE_SOLVING
1549  * - \ref SCIP_STAGE_SOLVED
1550  */
1552  SCIP* scip /**< SCIP data structure */
1553  )
1554 {
1556 
1557  /* in case we could not prove whether the problem is unbounded or infeasible, we want to terminate with gap = +inf;
1558  * if the problem was proven to be unbounded or proven to be infeasible we return gap = 0
1559  */
1560  if( SCIPgetStatus(scip) == SCIP_STATUS_INFORUNBD )
1561  return SCIPsetInfinity(scip->set);
1563  return 0.0;
1564 
1565  /* the lowerbound is infinity, but SCIP may not have updated the status; in this case, the problem was already solved
1566  * so we return gap = 0
1567  */
1568  if( SCIPsetIsInfinity(scip->set, SCIPgetLowerbound(scip)) )
1569  return 0.0;
1570 
1572 }
1573 
1574 /** gets current gap |(upperbound - lowerbound)/min(|upperbound|,|lowerbound|)| in transformed problem if both bounds
1575  * have same sign, or infinity, if they have opposite sign
1576  *
1577  * @return current gap |(upperbound - lowerbound)/min(|upperbound|,|lowerbound|)| in transformed problem if both bounds
1578  * have same sign, or infinity, if they have opposite sign
1579  *
1580  * @pre This method can be called if SCIP is in one of the following stages:
1581  * - \ref SCIP_STAGE_PRESOLVED
1582  * - \ref SCIP_STAGE_SOLVING
1583  * - \ref SCIP_STAGE_SOLVED
1584  */
1586  SCIP* scip /**< SCIP data structure */
1587  )
1588 {
1589  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetTransGap", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1590 
1591  /* in case we could not prove whether the problem is unbounded or infeasible, we want to terminate with gap = +inf;
1592  * if the problem was proven to be unbounded or proven to be infeasible we return gap = 0
1593  */
1594  if( SCIPgetStatus(scip) == SCIP_STATUS_INFORUNBD )
1595  return SCIPsetInfinity(scip->set);
1597  return 0.0;
1598 
1599  /* the lowerbound is infinity, but SCIP may not have updated the status; in this case, the problem was already solved
1600  * so we return gap = 0
1601  */
1602  if( SCIPsetIsInfinity(scip->set, SCIPgetLowerbound(scip)) )
1603  return 0.0;
1604 
1606 }
1607 
1608 /** gets number of feasible primal solutions found so far
1609  *
1610  * @return the number of feasible primal solutions found so far
1611  *
1612  * @pre This method can be called if SCIP is in one of the following stages:
1613  * - \ref SCIP_STAGE_TRANSFORMED
1614  * - \ref SCIP_STAGE_INITPRESOLVE
1615  * - \ref SCIP_STAGE_PRESOLVING
1616  * - \ref SCIP_STAGE_EXITPRESOLVE
1617  * - \ref SCIP_STAGE_PRESOLVED
1618  * - \ref SCIP_STAGE_INITSOLVE
1619  * - \ref SCIP_STAGE_SOLVING
1620  * - \ref SCIP_STAGE_SOLVED
1621  * - \ref SCIP_STAGE_EXITSOLVE
1622  */
1624  SCIP* scip /**< SCIP data structure */
1625  )
1626 {
1627  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNSolsFound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1628 
1629  return scip->primal->nsolsfound;
1630 }
1631 
1632 /** gets number of feasible primal solutions respecting the objective limit found so far
1633  *
1634  * @return the number of feasible primal solutions respecting the objective limit found so far
1635  *
1636  * @pre This method can be called if SCIP is in one of the following stages:
1637  * - \ref SCIP_STAGE_INIT
1638  * - \ref SCIP_STAGE_PROBLEM
1639  * - \ref SCIP_STAGE_TRANSFORMING
1640  * - \ref SCIP_STAGE_TRANSFORMED
1641  * - \ref SCIP_STAGE_INITPRESOLVE
1642  * - \ref SCIP_STAGE_PRESOLVING
1643  * - \ref SCIP_STAGE_EXITPRESOLVE
1644  * - \ref SCIP_STAGE_PRESOLVED
1645  * - \ref SCIP_STAGE_INITSOLVE
1646  * - \ref SCIP_STAGE_SOLVING
1647  * - \ref SCIP_STAGE_SOLVED
1648  * - \ref SCIP_STAGE_EXITSOLVE
1649  */
1651  SCIP* scip /**< SCIP data structure */
1652  )
1653 {
1655  return 0;
1656 
1657  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNLimSolsFound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1658 
1659  return scip->primal->nlimsolsfound;
1660 }
1661 
1662 /** gets number of feasible primal solutions found so far, that improved the primal bound at the time they were found
1663  *
1664  * @return the number of feasible primal solutions found so far, that improved the primal bound at the time they were found
1665  *
1666  * @pre This method can be called if SCIP is in one of the following stages:
1667  * - \ref SCIP_STAGE_TRANSFORMED
1668  * - \ref SCIP_STAGE_INITPRESOLVE
1669  * - \ref SCIP_STAGE_PRESOLVING
1670  * - \ref SCIP_STAGE_EXITPRESOLVE
1671  * - \ref SCIP_STAGE_PRESOLVED
1672  * - \ref SCIP_STAGE_INITSOLVE
1673  * - \ref SCIP_STAGE_SOLVING
1674  * - \ref SCIP_STAGE_SOLVED
1675  * - \ref SCIP_STAGE_EXITSOLVE
1676  */
1678  SCIP* scip /**< SCIP data structure */
1679  )
1680 {
1681  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNBestSolsFound", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE) );
1682 
1683  return scip->primal->nbestsolsfound;
1684 }
1685 
1686 /** gets the average pseudo cost value for the given direction over all variables
1687  *
1688  * @return the average pseudo cost value for the given direction over all variables
1689  *
1690  * @pre This method can be called if SCIP is in one of the following stages:
1691  * - \ref SCIP_STAGE_SOLVING
1692  * - \ref SCIP_STAGE_SOLVED
1693  */
1695  SCIP* scip, /**< SCIP data structure */
1696  SCIP_Real solvaldelta /**< difference of variable's new LP value - old LP value */
1697  )
1698 {
1699  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgPseudocost", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1700 
1701  return SCIPhistoryGetPseudocost(scip->stat->glbhistory, solvaldelta);
1702 }
1703 
1704 /** gets the average pseudo cost value for the given direction over all variables,
1705  * only using the pseudo cost information of the current run
1706  *
1707  * @return the average pseudo cost value for the given direction over all variables,
1708  * only using the pseudo cost information of the current run
1709  *
1710  * @pre This method can be called if SCIP is in one of the following stages:
1711  * - \ref SCIP_STAGE_SOLVING
1712  * - \ref SCIP_STAGE_SOLVED
1713  */
1715  SCIP* scip, /**< SCIP data structure */
1716  SCIP_Real solvaldelta /**< difference of variable's new LP value - old LP value */
1717  )
1718 {
1719  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgPseudocostCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1720 
1721  return SCIPhistoryGetPseudocost(scip->stat->glbhistorycrun, solvaldelta);
1722 }
1723 
1724 /** gets the average number of pseudo cost updates for the given direction over all variables
1725  *
1726  * @return the average number of pseudo cost updates for the given direction over all variables
1727  *
1728  * @pre This method can be called if SCIP is in one of the following stages:
1729  * - \ref SCIP_STAGE_SOLVING
1730  * - \ref SCIP_STAGE_SOLVED
1731  */
1733  SCIP* scip, /**< SCIP data structure */
1734  SCIP_BRANCHDIR dir /**< branching direction (downwards, or upwards) */
1735  )
1736 {
1737  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgPseudocostCount", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1738 
1739  return SCIPhistoryGetPseudocostCount(scip->stat->glbhistory, dir)
1740  / MAX(scip->transprob->nbinvars + scip->transprob->nintvars, 1);
1741 }
1742 
1743 /** gets the average number of pseudo cost updates for the given direction over all variables,
1744  * only using the pseudo cost information of the current run
1745  *
1746  * @return the average number of pseudo cost updates for the given direction over all variables,
1747  * only using the pseudo cost information of the current run
1748  *
1749  * @pre This method can be called if SCIP is in one of the following stages:
1750  * - \ref SCIP_STAGE_SOLVING
1751  * - \ref SCIP_STAGE_SOLVED
1752  */
1754  SCIP* scip, /**< SCIP data structure */
1755  SCIP_BRANCHDIR dir /**< branching direction (downwards, or upwards) */
1756  )
1757 {
1758  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgPseudocostCountCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1759 
1761  / MAX(scip->transprob->nbinvars + scip->transprob->nintvars, 1);
1762 }
1763 
1764 /** gets the average pseudo cost score value over all variables, assuming a fractionality of 0.5
1765  *
1766  * @return the average pseudo cost score value over all variables, assuming a fractionality of 0.5
1767  *
1768  * @pre This method can be called if SCIP is in one of the following stages:
1769  * - \ref SCIP_STAGE_SOLVING
1770  * - \ref SCIP_STAGE_SOLVED
1771  */
1773  SCIP* scip /**< SCIP data structure */
1774  )
1775 {
1776  SCIP_Real pscostdown;
1777  SCIP_Real pscostup;
1778 
1779  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgPseudocostScore", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1780 
1781  pscostdown = SCIPhistoryGetPseudocost(scip->stat->glbhistory, -0.5);
1782  pscostup = SCIPhistoryGetPseudocost(scip->stat->glbhistory, +0.5);
1783 
1784  return SCIPbranchGetScore(scip->set, NULL, pscostdown, pscostup);
1785 }
1786 
1787 /** returns the variance of pseudo costs for all variables in the requested direction
1788  *
1789  * @return the variance of pseudo costs for all variables in the requested direction
1790  *
1791  * @pre This method can be called if SCIP is in one of the following stages:
1792  * - \ref SCIP_STAGE_SOLVING
1793  * - \ref SCIP_STAGE_SOLVED
1794  */
1796  SCIP* scip, /**< SCIP data structure */
1797  SCIP_BRANCHDIR branchdir, /**< the branching direction, up or down */
1798  SCIP_Bool onlycurrentrun /**< use only history of current run? */
1799  )
1800 {
1801  SCIP_HISTORY* history;
1802 
1803  assert(scip != NULL);
1804  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetPseudocostVariance", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1805 
1806  history = (onlycurrentrun ? scip->stat->glbhistorycrun : scip->stat->glbhistory);
1807  assert(history != NULL);
1808 
1809  return SCIPhistoryGetPseudocostVariance(history, branchdir);
1810 }
1811 
1812 /** gets the number of pseudo cost updates for the given direction over all variables
1813  *
1814  * @return the number of pseudo cost updates for the given direction over all variables
1815  *
1816  * @pre This method can be called if SCIP is in one of the following stages:
1817  * - \ref SCIP_STAGE_SOLVING
1818  * - \ref SCIP_STAGE_SOLVED
1819  */
1821  SCIP* scip, /**< SCIP data structure */
1822  SCIP_BRANCHDIR dir, /**< branching direction (downwards, or upwards) */
1823  SCIP_Bool onlycurrentrun /**< use only history of current run? */
1824  )
1825 {
1826  SCIP_HISTORY* history;
1827 
1828  assert(scip != NULL);
1829  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetPseudocostCount", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1830 
1831  history = (onlycurrentrun ? scip->stat->glbhistorycrun : scip->stat->glbhistory);
1832 
1833  return SCIPhistoryGetPseudocostCount(history, dir);
1834 }
1835 
1836 /** gets the average pseudo cost score value over all variables, assuming a fractionality of 0.5,
1837  * only using the pseudo cost information of the current run
1838  *
1839  * @return the average pseudo cost score value over all variables, assuming a fractionality of 0.5,
1840  * only using the pseudo cost information of the current run
1841  *
1842  * @pre This method can be called if SCIP is in one of the following stages:
1843  * - \ref SCIP_STAGE_SOLVING
1844  * - \ref SCIP_STAGE_SOLVED
1845  */
1847  SCIP* scip /**< SCIP data structure */
1848  )
1849 {
1850  SCIP_Real pscostdown;
1851  SCIP_Real pscostup;
1852 
1853  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgPseudocostScoreCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1854 
1855  pscostdown = SCIPhistoryGetPseudocost(scip->stat->glbhistorycrun, -0.5);
1856  pscostup = SCIPhistoryGetPseudocost(scip->stat->glbhistorycrun, +0.5);
1857 
1858  return SCIPbranchGetScore(scip->set, NULL, pscostdown, pscostup);
1859 }
1860 
1861 /** gets the average conflict score value over all variables
1862  *
1863  * @return the average conflict score value over all variables
1864  *
1865  * @pre This method can be called if SCIP is in one of the following stages:
1866  * - \ref SCIP_STAGE_SOLVING
1867  * - \ref SCIP_STAGE_SOLVED
1868  */
1870  SCIP* scip /**< SCIP data structure */
1871  )
1872 {
1873  SCIP_Real conflictscoredown;
1874  SCIP_Real conflictscoreup;
1875  SCIP_Real scale;
1876 
1877  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgConflictScore", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1878 
1879  scale = scip->transprob->nvars * scip->stat->vsidsweight;
1880  conflictscoredown = SCIPhistoryGetVSIDS(scip->stat->glbhistory, SCIP_BRANCHDIR_DOWNWARDS) / scale;
1881  conflictscoreup = SCIPhistoryGetVSIDS(scip->stat->glbhistory, SCIP_BRANCHDIR_UPWARDS) / scale;
1882 
1883  return SCIPbranchGetScore(scip->set, NULL, conflictscoredown, conflictscoreup);
1884 }
1885 
1886 /** gets the average conflict score value over all variables, only using the conflict score information of the current run
1887  *
1888  * @return the average conflict score value over all variables, only using the conflict score information of the current run
1889  *
1890  * @pre This method can be called if SCIP is in one of the following stages:
1891  * - \ref SCIP_STAGE_SOLVING
1892  * - \ref SCIP_STAGE_SOLVED
1893  */
1895  SCIP* scip /**< SCIP data structure */
1896  )
1897 {
1898  SCIP_Real conflictscoredown;
1899  SCIP_Real conflictscoreup;
1900  SCIP_Real scale;
1901 
1902  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgConflictScoreCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1903 
1904  scale = scip->transprob->nvars * scip->stat->vsidsweight;
1905  conflictscoredown = SCIPhistoryGetVSIDS(scip->stat->glbhistorycrun, SCIP_BRANCHDIR_DOWNWARDS) / scale;
1906  conflictscoreup = SCIPhistoryGetVSIDS(scip->stat->glbhistorycrun, SCIP_BRANCHDIR_UPWARDS) / scale;
1907 
1908  return SCIPbranchGetScore(scip->set, NULL, conflictscoredown, conflictscoreup);
1909 }
1910 
1911 /** gets the average inference score value over all variables
1912  *
1913  * @return the average inference score value over all variables
1914  *
1915  * @pre This method can be called if SCIP is in one of the following stages:
1916  * - \ref SCIP_STAGE_SOLVING
1917  * - \ref SCIP_STAGE_SOLVED
1918  */
1920  SCIP* scip /**< SCIP data structure */
1921  )
1922 {
1923  SCIP_Real conflictlengthdown;
1924  SCIP_Real conflictlengthup;
1925 
1926  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgConflictlengthScore", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1927 
1930 
1931  return SCIPbranchGetScore(scip->set, NULL, conflictlengthdown, conflictlengthup);
1932 }
1933 
1934 /** gets the average conflictlength score value over all variables, only using the conflictlength information of the
1935  * current run
1936  *
1937  * @return the average conflictlength score value over all variables, only using the conflictlength information of the
1938  * current run
1939  *
1940  * @pre This method can be called if SCIP is in one of the following stages:
1941  * - \ref SCIP_STAGE_SOLVING
1942  * - \ref SCIP_STAGE_SOLVED
1943  */
1945  SCIP* scip /**< SCIP data structure */
1946  )
1947 {
1948  SCIP_Real conflictlengthdown;
1949  SCIP_Real conflictlengthup;
1950 
1951  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgConflictlengthScoreCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1952 
1955 
1956  return SCIPbranchGetScore(scip->set, NULL, conflictlengthdown, conflictlengthup);
1957 }
1958 
1959 /** returns the average number of inferences found after branching in given direction over all variables
1960  *
1961  * @return the average number of inferences found after branching in given direction over all variables
1962  *
1963  * @pre This method can be called if SCIP is in one of the following stages:
1964  * - \ref SCIP_STAGE_SOLVING
1965  * - \ref SCIP_STAGE_SOLVED
1966  */
1968  SCIP* scip, /**< SCIP data structure */
1969  SCIP_BRANCHDIR dir /**< branching direction (downwards, or upwards) */
1970  )
1971 {
1972  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgInferences", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1973 
1974  return SCIPhistoryGetAvgInferences(scip->stat->glbhistory, dir);
1975 }
1976 
1977 /** returns the average number of inferences found after branching in given direction over all variables,
1978  * only using the inference information of the current run
1979  *
1980  * @return the average number of inferences found after branching in given direction over all variables,
1981  * only using the inference information of the current run
1982  *
1983  * @pre This method can be called if SCIP is in one of the following stages:
1984  * - \ref SCIP_STAGE_SOLVING
1985  * - \ref SCIP_STAGE_SOLVED
1986  */
1988  SCIP* scip, /**< SCIP data structure */
1989  SCIP_BRANCHDIR dir /**< branching direction (downwards, or upwards) */
1990  )
1991 {
1992  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgInferencesCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
1993 
1994  return SCIPhistoryGetAvgInferences(scip->stat->glbhistorycrun, dir);
1995 }
1996 
1997 /** gets the average inference score value over all variables
1998  *
1999  * @return the average inference score value over all variables
2000  *
2001  * @pre This method can be called if SCIP is in one of the following stages:
2002  * - \ref SCIP_STAGE_SOLVING
2003  * - \ref SCIP_STAGE_SOLVED
2004  */
2006  SCIP* scip /**< SCIP data structure */
2007  )
2008 {
2009  SCIP_Real inferencesdown;
2010  SCIP_Real inferencesup;
2011 
2012  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgInferenceScore", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2013 
2016 
2017  return SCIPbranchGetScore(scip->set, NULL, inferencesdown, inferencesup);
2018 }
2019 
2020 /** gets the average inference score value over all variables, only using the inference information of the
2021  * current run
2022  *
2023  * @return the average inference score value over all variables, only using the inference information of the
2024  * current run
2025  *
2026  * @pre This method can be called if SCIP is in one of the following stages:
2027  * - \ref SCIP_STAGE_SOLVING
2028  * - \ref SCIP_STAGE_SOLVED
2029  */
2031  SCIP* scip /**< SCIP data structure */
2032  )
2033 {
2034  SCIP_Real inferencesdown;
2035  SCIP_Real inferencesup;
2036 
2037  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgInferenceScoreCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2038 
2041 
2042  return SCIPbranchGetScore(scip->set, NULL, inferencesdown, inferencesup);
2043 }
2044 
2045 /** returns the average number of cutoffs found after branching in given direction over all variables
2046  *
2047  * @return the average number of cutoffs found after branching in given direction over all variables
2048  *
2049  * @pre This method can be called if SCIP is in one of the following stages:
2050  * - \ref SCIP_STAGE_SOLVING
2051  * - \ref SCIP_STAGE_SOLVED
2052  */
2054  SCIP* scip, /**< SCIP data structure */
2055  SCIP_BRANCHDIR dir /**< branching direction (downwards, or upwards) */
2056  )
2057 {
2058  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgCutoffs", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2059 
2060  return SCIPhistoryGetAvgCutoffs(scip->stat->glbhistory, dir);
2061 }
2062 
2063 /** returns the average number of cutoffs found after branching in given direction over all variables,
2064  * only using the cutoff information of the current run
2065  *
2066  * @return the average number of cutoffs found after branching in given direction over all variables,
2067  * only using the cutoff information of the current run
2068  *
2069  * @pre This method can be called if SCIP is in one of the following stages:
2070  * - \ref SCIP_STAGE_SOLVING
2071  * - \ref SCIP_STAGE_SOLVED
2072  */
2074  SCIP* scip, /**< SCIP data structure */
2075  SCIP_BRANCHDIR dir /**< branching direction (downwards, or upwards) */
2076  )
2077 {
2078  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgCutoffsCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2079 
2080  return SCIPhistoryGetAvgCutoffs(scip->stat->glbhistorycrun, dir);
2081 }
2082 
2083 /** gets the average cutoff score value over all variables
2084  *
2085  * @return the average cutoff score value over all variables
2086  *
2087  * @pre This method can be called if SCIP is in one of the following stages:
2088  * - \ref SCIP_STAGE_SOLVING
2089  * - \ref SCIP_STAGE_SOLVED
2090  */
2092  SCIP* scip /**< SCIP data structure */
2093  )
2094 {
2095  SCIP_Real cutoffsdown;
2096  SCIP_Real cutoffsup;
2097 
2098  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgCutoffScore", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2099 
2102 
2103  return SCIPbranchGetScore(scip->set, NULL, cutoffsdown, cutoffsup);
2104 }
2105 
2106 /** gets the average cutoff score value over all variables, only using the cutoff score information of the current run
2107  *
2108  * @return the average cutoff score value over all variables, only using the cutoff score information of the current run
2109  *
2110  * @pre This method can be called if SCIP is in one of the following stages:
2111  * - \ref SCIP_STAGE_SOLVING
2112  * - \ref SCIP_STAGE_SOLVED
2113  */
2115  SCIP* scip /**< SCIP data structure */
2116  )
2117 {
2118  SCIP_Real cutoffsdown;
2119  SCIP_Real cutoffsup;
2120 
2121  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetAvgCutoffScoreCurrentRun", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2122 
2125 
2126  return SCIPbranchGetScore(scip->set, NULL, cutoffsdown, cutoffsup);
2127 }
2128 
2129 /** computes a deterministic measure of time from statistics
2130  *
2131  * @return the deterministic time
2132  *
2133  * @pre This method can be called if SCIP is in one of the following stages:
2134  * - \ref SCIP_STAGE_PRESOLVING
2135  * - \ref SCIP_STAGE_PRESOLVED
2136  * - \ref SCIP_STAGE_SOLVING
2137  * - \ref SCIP_STAGE_SOLVED
2138  */
2140  SCIP* scip /**< SCIP data structure */
2141  )
2142 {
2143 /* TODO: SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetDeterministicTime", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) ); */
2144  if(scip->stat == NULL)
2145  return 0.0;
2146 
2147  return 1e-6 * scip->stat->nnz * (
2148  0.00328285264101 * scip->stat->nprimalresolvelpiterations +
2149  0.00531625104146 * scip->stat->ndualresolvelpiterations +
2150  0.000738719124051 * scip->stat->nprobboundchgs +
2151  0.0011123144764 * scip->stat->nisstoppedcalls );
2152 }
2153 
2154 /** outputs problem to file stream */
2155 static
2157  SCIP* scip, /**< SCIP data structure */
2158  SCIP_PROB* prob, /**< problem data */
2159  FILE* file, /**< output file (or NULL for standard output) */
2160  const char* extension, /**< file format (or NULL for default CIP format) */
2161  SCIP_Bool genericnames /**< using generic variable and constraint names? */
2162  )
2163 {
2164  SCIP_RESULT result;
2165  int i;
2166  assert(scip != NULL);
2167  assert(prob != NULL);
2168 
2169  /* try all readers until one could read the file */
2170  result = SCIP_DIDNOTRUN;
2171  for( i = 0; i < scip->set->nreaders && result == SCIP_DIDNOTRUN; ++i )
2172  {
2173  SCIP_RETCODE retcode;
2174 
2175  if( extension != NULL )
2176  retcode = SCIPreaderWrite(scip->set->readers[i], prob, scip->set, file, extension, genericnames, &result);
2177  else
2178  retcode = SCIPreaderWrite(scip->set->readers[i], prob, scip->set, file, "cip", genericnames, &result);
2179 
2180  /* check for reader errors */
2181  if( retcode == SCIP_WRITEERROR )
2182  return retcode;
2183 
2184  SCIP_CALL( retcode );
2185  }
2186 
2187  switch( result )
2188  {
2189  case SCIP_DIDNOTRUN:
2190  return SCIP_PLUGINNOTFOUND;
2191 
2192  case SCIP_SUCCESS:
2193  return SCIP_OKAY;
2194 
2195  default:
2196  assert(i < scip->set->nreaders);
2197  SCIPerrorMessage("invalid result code <%d> from reader <%s> writing <%s> format\n",
2198  result, SCIPreaderGetName(scip->set->readers[i]), extension);
2199  return SCIP_READERROR;
2200  } /*lint !e788*/
2201 }
2202 
2203 /** outputs original problem to file stream
2204  *
2205  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
2206  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
2207  *
2208  * @pre This method can be called if SCIP is in one of the following stages:
2209  * - \ref SCIP_STAGE_PROBLEM
2210  * - \ref SCIP_STAGE_TRANSFORMING
2211  * - \ref SCIP_STAGE_TRANSFORMED
2212  * - \ref SCIP_STAGE_INITPRESOLVE
2213  * - \ref SCIP_STAGE_PRESOLVING
2214  * - \ref SCIP_STAGE_EXITPRESOLVE
2215  * - \ref SCIP_STAGE_PRESOLVED
2216  * - \ref SCIP_STAGE_INITSOLVE
2217  * - \ref SCIP_STAGE_SOLVING
2218  * - \ref SCIP_STAGE_SOLVED
2219  * - \ref SCIP_STAGE_EXITSOLVE
2220  * - \ref SCIP_STAGE_FREETRANS
2221  */
2223  SCIP* scip, /**< SCIP data structure */
2224  FILE* file, /**< output file (or NULL for standard output) */
2225  const char* extension, /**< file format (or NULL for default CIP format)*/
2226  SCIP_Bool genericnames /**< using generic variable and constraint names? */
2227  )
2228 {
2229  SCIP_RETCODE retcode;
2230 
2231  SCIP_CALL( SCIPcheckStage(scip, "SCIPprintOrigProblem", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
2232 
2233  assert(scip != NULL);
2234  assert( scip->origprob != NULL );
2235 
2236  retcode = printProblem(scip, scip->origprob, file, extension, genericnames);
2237 
2238  /* check for write errors */
2239  if( retcode == SCIP_WRITEERROR || retcode == SCIP_PLUGINNOTFOUND )
2240  return retcode;
2241  else
2242  {
2243  SCIP_CALL( retcode );
2244  }
2245 
2246  return SCIP_OKAY;
2247 }
2248 
2249 /** outputs transformed problem of the current node to file stream
2250  *
2251  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
2252  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
2253  *
2254  * @pre This method can be called if SCIP is in one of the following stages:
2255  * - \ref SCIP_STAGE_TRANSFORMED
2256  * - \ref SCIP_STAGE_INITPRESOLVE
2257  * - \ref SCIP_STAGE_PRESOLVING
2258  * - \ref SCIP_STAGE_EXITPRESOLVE
2259  * - \ref SCIP_STAGE_PRESOLVED
2260  * - \ref SCIP_STAGE_INITSOLVE
2261  * - \ref SCIP_STAGE_SOLVING
2262  * - \ref SCIP_STAGE_SOLVED
2263  * - \ref SCIP_STAGE_EXITSOLVE
2264  * - \ref SCIP_STAGE_FREETRANS
2265  */
2267  SCIP* scip, /**< SCIP data structure */
2268  FILE* file, /**< output file (or NULL for standard output) */
2269  const char* extension, /**< file format (or NULL for default CIP format)*/
2270  SCIP_Bool genericnames /**< using generic variable and constraint names? */
2271  )
2272 {
2273  SCIP_RETCODE retcode;
2274 
2275  SCIP_CALL( SCIPcheckStage(scip, "SCIPprintTransProblem", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
2276 
2277  assert(scip != NULL);
2278  assert(scip->transprob != NULL );
2279 
2280  retcode = printProblem(scip, scip->transprob, file, extension, genericnames);
2281 
2282  /* check for write errors */
2283  if( retcode == SCIP_WRITEERROR || retcode == SCIP_PLUGINNOTFOUND )
2284  return retcode;
2285  else
2286  {
2287  SCIP_CALL( retcode );
2288  }
2289 
2290  return SCIP_OKAY;
2291 }
2292 
2293 /** outputs status statistics
2294  *
2295  * @note If limits have been changed between the solution and the call to this function, the status is recomputed and
2296  * thus may to correspond to the original status.
2297  *
2298  * @pre This method can be called if SCIP is in one of the following stages:
2299  * - \ref SCIP_STAGE_INIT
2300  * - \ref SCIP_STAGE_PROBLEM
2301  * - \ref SCIP_STAGE_TRANSFORMED
2302  * - \ref SCIP_STAGE_INITPRESOLVE
2303  * - \ref SCIP_STAGE_PRESOLVING
2304  * - \ref SCIP_STAGE_EXITPRESOLVE
2305  * - \ref SCIP_STAGE_PRESOLVED
2306  * - \ref SCIP_STAGE_SOLVING
2307  * - \ref SCIP_STAGE_SOLVED
2308  */
2310  SCIP* scip, /**< SCIP data structure */
2311  FILE* file /**< output file */
2312  )
2313 {
2314  assert(scip != NULL);
2315  assert(scip->set != NULL);
2316 
2317  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintStatusStatistics", TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2318 
2319  SCIPmessageFPrintInfo(scip->messagehdlr, file, "SCIP Status : ");
2320  SCIP_CALL_ABORT( SCIPprintStage(scip, file) );
2321  SCIPmessageFPrintInfo(scip->messagehdlr, file, "\n");
2322 }
2323 
2324 /** outputs statistics for original problem
2325  *
2326  * @pre This method can be called if SCIP is in one of the following stages:
2327  * - \ref SCIP_STAGE_PROBLEM
2328  * - \ref SCIP_STAGE_TRANSFORMED
2329  * - \ref SCIP_STAGE_INITPRESOLVE
2330  * - \ref SCIP_STAGE_PRESOLVING
2331  * - \ref SCIP_STAGE_EXITPRESOLVE
2332  * - \ref SCIP_STAGE_PRESOLVED
2333  * - \ref SCIP_STAGE_SOLVING
2334  * - \ref SCIP_STAGE_SOLVED
2335  */
2337  SCIP* scip, /**< SCIP data structure */
2338  FILE* file /**< output file */
2339  )
2340 {
2341  assert(scip != NULL);
2342  assert(scip->set != NULL);
2343 
2344  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintOrigProblemStatistics", FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2345 
2346  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Original Problem :\n");
2347  SCIPprobPrintStatistics(scip->origprob, scip->set, scip->messagehdlr, file);
2348 }
2349 
2350 /** outputs statistics for transformed problem
2351  *
2352  * @pre This method can be called if SCIP is in one of the following stages:
2353  * - \ref SCIP_STAGE_PROBLEM
2354  * - \ref SCIP_STAGE_TRANSFORMED
2355  * - \ref SCIP_STAGE_INITPRESOLVE
2356  * - \ref SCIP_STAGE_PRESOLVING
2357  * - \ref SCIP_STAGE_EXITPRESOLVE
2358  * - \ref SCIP_STAGE_PRESOLVED
2359  * - \ref SCIP_STAGE_SOLVING
2360  * - \ref SCIP_STAGE_SOLVED
2361  */
2363  SCIP* scip, /**< SCIP data structure */
2364  FILE* file /**< output file */
2365  )
2366 {
2367  assert(scip != NULL);
2368  assert(scip->set != NULL);
2369 
2370  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintTransProblemStatistics", FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2371 
2372  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Presolved Problem :\n");
2373  SCIPprobPrintStatistics(scip->transprob, scip->set, scip->messagehdlr, file);
2374 }
2375 
2376 /** outputs presolver statistics
2377  *
2378  * @pre This method can be called if SCIP is in one of the following stages:
2379  * - \ref SCIP_STAGE_TRANSFORMED
2380  * - \ref SCIP_STAGE_INITPRESOLVE
2381  * - \ref SCIP_STAGE_PRESOLVING
2382  * - \ref SCIP_STAGE_EXITPRESOLVE
2383  * - \ref SCIP_STAGE_PRESOLVED
2384  * - \ref SCIP_STAGE_SOLVING
2385  * - \ref SCIP_STAGE_SOLVED
2386  */
2388  SCIP* scip, /**< SCIP data structure */
2389  FILE* file /**< output file */
2390  )
2391 {
2392  int i;
2393 
2394  assert(scip != NULL);
2395  assert(scip->set != NULL);
2396 
2397  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintPresolverStatistics", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2398 
2399  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Presolvers : ExecTime SetupTime Calls FixedVars AggrVars ChgTypes ChgBounds AddHoles DelCons AddCons ChgSides ChgCoefs\n");
2400 
2401  /* sort presolvers w.r.t. their name */
2402  SCIPsetSortPresolsName(scip->set);
2403 
2404  /* presolver statistics */
2405  for( i = 0; i < scip->set->npresols; ++i )
2406  {
2407  SCIP_PRESOL* presol;
2408  presol = scip->set->presols[i];
2409  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s:", SCIPpresolGetName(presol));
2410  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10.2f %6d %10d %10d %10d %10d %10d %10d %10d %10d %10d\n",
2411  SCIPpresolGetTime(presol),
2412  SCIPpresolGetSetupTime(presol),
2413  SCIPpresolGetNCalls(presol),
2414  SCIPpresolGetNFixedVars(presol),
2415  SCIPpresolGetNAggrVars(presol),
2416  SCIPpresolGetNChgVarTypes(presol),
2417  SCIPpresolGetNChgBds(presol),
2418  SCIPpresolGetNAddHoles(presol),
2419  SCIPpresolGetNDelConss(presol),
2420  SCIPpresolGetNAddConss(presol),
2421  SCIPpresolGetNChgSides(presol),
2422  SCIPpresolGetNChgCoefs(presol));
2423  }
2424 
2425  /* sort propagators w.r.t. their name */
2426  SCIPsetSortPropsName(scip->set);
2427 
2428  for( i = 0; i < scip->set->nprops; ++i )
2429  {
2430  SCIP_PROP* prop;
2431  prop = scip->set->props[i];
2432  if( SCIPpropDoesPresolve(prop) )
2433  {
2434  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s:", SCIPpropGetName(prop));
2435  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10.2f %6d %10d %10d %10d %10d %10d %10d %10d %10d %10d\n",
2436  SCIPpropGetPresolTime(prop),
2437  SCIPpropGetSetupTime(prop),
2439  SCIPpropGetNFixedVars(prop),
2440  SCIPpropGetNAggrVars(prop),
2442  SCIPpropGetNChgBds(prop),
2443  SCIPpropGetNAddHoles(prop),
2444  SCIPpropGetNDelConss(prop),
2445  SCIPpropGetNAddConss(prop),
2446  SCIPpropGetNChgSides(prop),
2447  SCIPpropGetNChgCoefs(prop));
2448  }
2449  }
2450 
2451  /* constraint handler presolving methods statistics */
2452  for( i = 0; i < scip->set->nconshdlrs; ++i )
2453  {
2454  SCIP_CONSHDLR* conshdlr;
2455  int maxnactiveconss;
2456 
2457  conshdlr = scip->set->conshdlrs[i];
2458  maxnactiveconss = SCIPconshdlrGetMaxNActiveConss(conshdlr);
2459  if( SCIPconshdlrDoesPresolve(conshdlr)
2460  && (maxnactiveconss > 0 || !SCIPconshdlrNeedsCons(conshdlr)
2461  || SCIPconshdlrGetNFixedVars(conshdlr) > 0
2462  || SCIPconshdlrGetNAggrVars(conshdlr) > 0
2463  || SCIPconshdlrGetNChgVarTypes(conshdlr) > 0
2464  || SCIPconshdlrGetNChgBds(conshdlr) > 0
2465  || SCIPconshdlrGetNAddHoles(conshdlr) > 0
2466  || SCIPconshdlrGetNDelConss(conshdlr) > 0
2467  || SCIPconshdlrGetNAddConss(conshdlr) > 0
2468  || SCIPconshdlrGetNChgSides(conshdlr) > 0
2469  || SCIPconshdlrGetNChgCoefs(conshdlr) > 0
2470  || SCIPconshdlrGetNUpgdConss(conshdlr) > 0) )
2471  {
2472  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s:", SCIPconshdlrGetName(conshdlr));
2473  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10.2f %6d %10d %10d %10d %10d %10d %10d %10d %10d %10d\n",
2474  SCIPconshdlrGetPresolTime(conshdlr),
2475  SCIPconshdlrGetSetupTime(conshdlr),
2476  SCIPconshdlrGetNPresolCalls(conshdlr),
2477  SCIPconshdlrGetNFixedVars(conshdlr),
2478  SCIPconshdlrGetNAggrVars(conshdlr),
2479  SCIPconshdlrGetNChgVarTypes(conshdlr),
2480  SCIPconshdlrGetNChgBds(conshdlr),
2481  SCIPconshdlrGetNAddHoles(conshdlr),
2482  SCIPconshdlrGetNDelConss(conshdlr),
2483  SCIPconshdlrGetNAddConss(conshdlr),
2484  SCIPconshdlrGetNChgSides(conshdlr),
2485  SCIPconshdlrGetNChgCoefs(conshdlr));
2486  }
2487  }
2488 
2489  /* root node bound changes */
2490  SCIPmessageFPrintInfo(scip->messagehdlr, file, " root node : - - - %10d - - %10d - - - - -\n",
2491  scip->stat->nrootintfixings, scip->stat->nrootboundchgs);
2492 }
2493 
2494 /** outputs constraint statistics
2495  *
2496  * @pre This method can be called if SCIP is in one of the following stages:
2497  * - \ref SCIP_STAGE_TRANSFORMED
2498  * - \ref SCIP_STAGE_INITPRESOLVE
2499  * - \ref SCIP_STAGE_PRESOLVING
2500  * - \ref SCIP_STAGE_EXITPRESOLVE
2501  * - \ref SCIP_STAGE_PRESOLVED
2502  * - \ref SCIP_STAGE_SOLVING
2503  * - \ref SCIP_STAGE_SOLVED
2504  */
2506  SCIP* scip, /**< SCIP data structure */
2507  FILE* file /**< output file */
2508  )
2509 {
2510  int i;
2511 
2512  assert(scip != NULL);
2513  assert(scip->set != NULL);
2514 
2515  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintConstraintStatistics", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2516 
2517  /* Add maximal number of constraints of the same type? So far this information is not added because of lack of space. */
2518  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Constraints : Number MaxNumber #Separate #Propagate #EnfoLP #EnfoRelax #EnfoPS #Check #ResProp Cutoffs DomReds Cuts Applied Conss Children\n");
2519 
2520  for( i = 0; i < scip->set->nconshdlrs; ++i )
2521  {
2522  SCIP_CONSHDLR* conshdlr;
2523  int startnactiveconss;
2524  int maxnactiveconss;
2525 
2526  conshdlr = scip->set->conshdlrs[i];
2527  startnactiveconss = SCIPconshdlrGetStartNActiveConss(conshdlr);
2528  maxnactiveconss = SCIPconshdlrGetMaxNActiveConss(conshdlr);
2529  if( maxnactiveconss > 0 || !SCIPconshdlrNeedsCons(conshdlr) )
2530  {
2531  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s:", SCIPconshdlrGetName(conshdlr));
2533  startnactiveconss,
2534  maxnactiveconss > startnactiveconss ? '+' : ' ',
2535  maxnactiveconss,
2536  SCIPconshdlrGetNSepaCalls(conshdlr),
2537  SCIPconshdlrGetNPropCalls(conshdlr),
2538  SCIPconshdlrGetNEnfoLPCalls(conshdlr),
2540  SCIPconshdlrGetNEnfoPSCalls(conshdlr),
2541  SCIPconshdlrGetNCheckCalls(conshdlr),
2542  SCIPconshdlrGetNRespropCalls(conshdlr),
2543  SCIPconshdlrGetNCutoffs(conshdlr),
2544  SCIPconshdlrGetNDomredsFound(conshdlr),
2545  SCIPconshdlrGetNCutsFound(conshdlr),
2546  SCIPconshdlrGetNCutsApplied(conshdlr),
2547  SCIPconshdlrGetNConssFound(conshdlr),
2548  SCIPconshdlrGetNChildren(conshdlr));
2549  }
2550  }
2551 }
2552 
2553 /** outputs constraint timing statistics
2554  *
2555  * @pre This method can be called if SCIP is in one of the following stages:
2556  * - \ref SCIP_STAGE_TRANSFORMED
2557  * - \ref SCIP_STAGE_INITPRESOLVE
2558  * - \ref SCIP_STAGE_PRESOLVING
2559  * - \ref SCIP_STAGE_EXITPRESOLVE
2560  * - \ref SCIP_STAGE_PRESOLVED
2561  * - \ref SCIP_STAGE_SOLVING
2562  * - \ref SCIP_STAGE_SOLVED
2563  */
2565  SCIP* scip, /**< SCIP data structure */
2566  FILE* file /**< output file */
2567  )
2568 {
2569  int i;
2570 
2571  assert(scip != NULL);
2572  assert(scip->set != NULL);
2573 
2574  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintConstraintTimingStatistics", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2575 
2576  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Constraint Timings : TotalTime SetupTime Separate Propagate EnfoLP EnfoPS EnfoRelax Check ResProp SB-Prop\n");
2577 
2578  for( i = 0; i < scip->set->nconshdlrs; ++i )
2579  {
2580  SCIP_CONSHDLR* conshdlr;
2581  int maxnactiveconss;
2582 
2583  conshdlr = scip->set->conshdlrs[i];
2584  maxnactiveconss = SCIPconshdlrGetMaxNActiveConss(conshdlr);
2585  if( maxnactiveconss > 0 || !SCIPconshdlrNeedsCons(conshdlr) )
2586  {
2587  SCIP_Real totaltime;
2588 
2589  totaltime = SCIPconshdlrGetSepaTime(conshdlr) + SCIPconshdlrGetPropTime(conshdlr)
2591  + SCIPconshdlrGetEnfoLPTime(conshdlr)
2592  + SCIPconshdlrGetEnfoPSTime(conshdlr)
2593  + SCIPconshdlrGetEnfoRelaxTime(conshdlr)
2594  + SCIPconshdlrGetCheckTime(conshdlr)
2595  + SCIPconshdlrGetRespropTime(conshdlr)
2596  + SCIPconshdlrGetSetupTime(conshdlr);
2597 
2598  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s:", SCIPconshdlrGetName(conshdlr));
2599  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10.2f %10.2f %10.2f %10.2f %10.2f %10.2f %10.2f %10.2f %10.2f\n",
2600  totaltime,
2601  SCIPconshdlrGetSetupTime(conshdlr),
2602  SCIPconshdlrGetSepaTime(conshdlr),
2603  SCIPconshdlrGetPropTime(conshdlr),
2604  SCIPconshdlrGetEnfoLPTime(conshdlr),
2605  SCIPconshdlrGetEnfoPSTime(conshdlr),
2606  SCIPconshdlrGetEnfoRelaxTime(conshdlr),
2607  SCIPconshdlrGetCheckTime(conshdlr),
2608  SCIPconshdlrGetRespropTime(conshdlr),
2610  }
2611  }
2612 }
2613 
2614 /** outputs propagator statistics
2615  *
2616  * @pre This method can be called if SCIP is in one of the following stages:
2617  * - \ref SCIP_STAGE_TRANSFORMED
2618  * - \ref SCIP_STAGE_INITPRESOLVE
2619  * - \ref SCIP_STAGE_PRESOLVING
2620  * - \ref SCIP_STAGE_EXITPRESOLVE
2621  * - \ref SCIP_STAGE_PRESOLVED
2622  * - \ref SCIP_STAGE_SOLVING
2623  * - \ref SCIP_STAGE_SOLVED
2624  */
2626  SCIP* scip, /**< SCIP data structure */
2627  FILE* file /**< output file */
2628  )
2629 {
2630  int i;
2631 
2632  assert(scip != NULL);
2633  assert(scip->set != NULL);
2634 
2635  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintPropagatorStatistics", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2636 
2637  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Propagators : #Propagate #ResProp Cutoffs DomReds\n");
2638 
2639  /* sort propagaters w.r.t. their name */
2640  SCIPsetSortPropsName(scip->set);
2641 
2642  for( i = 0; i < scip->set->nprops; ++i )
2643  {
2644  SCIP_PROP* prop;
2645  prop = scip->set->props[i];
2646 
2648  SCIPpropGetName(prop),
2649  SCIPpropGetNCalls(prop),
2651  SCIPpropGetNCutoffs(prop),
2652  SCIPpropGetNDomredsFound(prop));
2653  }
2654 
2655  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Propagator Timings : TotalTime SetupTime Presolve Propagate ResProp SB-Prop\n");
2656 
2657  for( i = 0; i < scip->set->nprops; ++i )
2658  {
2659  SCIP_PROP* prop;
2660  SCIP_Real totaltime;
2661 
2662  prop = scip->set->props[i];
2663  totaltime = SCIPpropGetPresolTime(prop) + SCIPpropGetTime(prop) + SCIPpropGetRespropTime(prop)
2665 
2666  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s:", SCIPpropGetName(prop));
2667  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10.2f %10.2f %10.2f %10.2f %10.2f\n",
2668  totaltime,
2669  SCIPpropGetSetupTime(prop),
2670  SCIPpropGetPresolTime(prop),
2671  SCIPpropGetTime(prop),
2672  SCIPpropGetRespropTime(prop),
2674  }
2675 }
2676 
2677 /** outputs conflict statistics
2678  *
2679  * @pre This method can be called if SCIP is in one of the following stages:
2680  * - \ref SCIP_STAGE_TRANSFORMED
2681  * - \ref SCIP_STAGE_INITPRESOLVE
2682  * - \ref SCIP_STAGE_PRESOLVING
2683  * - \ref SCIP_STAGE_EXITPRESOLVE
2684  * - \ref SCIP_STAGE_PRESOLVED
2685  * - \ref SCIP_STAGE_SOLVING
2686  * - \ref SCIP_STAGE_SOLVED
2687  */
2689  SCIP* scip, /**< SCIP data structure */
2690  FILE* file /**< output file */
2691  )
2692 {
2693  char initstoresize[SCIP_MAXSTRLEN];
2694  char maxstoresize[SCIP_MAXSTRLEN];
2695 
2696  assert(scip != NULL);
2697  assert(scip->set != NULL);
2698 
2699  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintConflictStatistics", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2700 
2701  if( scip->set->conf_maxstoresize == 0 )
2702  {
2703  (void)SCIPsnprintf(initstoresize, SCIP_MAXSTRLEN, "inf");
2704  (void)SCIPsnprintf(maxstoresize, SCIP_MAXSTRLEN, "inf");
2705  }
2706  else
2707  {
2708  int initsize = SCIPconflictstoreGetInitPoolSize(scip->conflictstore);
2709  int maxsize = SCIPconflictstoreGetMaxPoolSize(scip->conflictstore);
2710 
2711  if( maxsize == -1 )
2712  {
2713  (void)SCIPsnprintf(initstoresize, SCIP_MAXSTRLEN, "--");
2714  (void)SCIPsnprintf(maxstoresize, SCIP_MAXSTRLEN, "--");
2715  }
2716  else
2717  {
2718  assert(initsize >= 0);
2719  assert(maxsize >= 0);
2720 
2721  (void)SCIPsnprintf(initstoresize, SCIP_MAXSTRLEN, "%d", initsize);
2722  (void)SCIPsnprintf(maxstoresize, SCIP_MAXSTRLEN, "%d", maxsize);
2723  }
2724  }
2725  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Conflict Analysis : Time Calls Success DomReds Conflicts Literals Reconvs ReconvLits Dualrays Nonzeros LP Iters (pool size: [%s,%s])\n", initstoresize, maxstoresize);
2726  SCIPmessageFPrintInfo(scip->messagehdlr, file, " propagation : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " - %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT " %10.1f - - -\n",
2738  SCIPmessageFPrintInfo(scip->messagehdlr, file, " infeasible LP : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " - %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT "\n",
2755  SCIPmessageFPrintInfo(scip->messagehdlr, file, " bound exceed. LP : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " - %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT "\n",
2772  SCIPmessageFPrintInfo(scip->messagehdlr, file, " strong branching : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " - %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT " %10.1f - - %10" SCIP_LONGINT_FORMAT "\n",
2785  SCIPmessageFPrintInfo(scip->messagehdlr, file, " pseudo solution : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " - %10" SCIP_LONGINT_FORMAT " %10.1f %10" SCIP_LONGINT_FORMAT " %10.1f - - -\n",
2797  SCIPmessageFPrintInfo(scip->messagehdlr, file, " applied globally : %10.2f - - %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.1f - - %10" SCIP_LONGINT_FORMAT " - -\n",
2805  SCIPmessageFPrintInfo(scip->messagehdlr, file, " applied locally : - - - %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.1f - - %10" SCIP_LONGINT_FORMAT " - -\n",
2813 }
2814 
2815 /** outputs separator statistics
2816  *
2817  * @pre This method can be called if SCIP is in one of the following stages:
2818  * - \ref SCIP_STAGE_SOLVING
2819  * - \ref SCIP_STAGE_SOLVED
2820  */
2822  SCIP* scip, /**< SCIP data structure */
2823  FILE* file /**< output file */
2824  )
2825 {
2826  int i;
2827 
2828  assert(scip != NULL);
2829  assert(scip->set != NULL);
2830 
2831  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintSeparatorStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2832 
2833  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Separators : ExecTime SetupTime Calls Cutoffs DomReds Cuts Applied Conss\n");
2834  SCIPmessageFPrintInfo(scip->messagehdlr, file, " cut pool : %10.2f %10" SCIP_LONGINT_FORMAT " - - %10" SCIP_LONGINT_FORMAT " - - (maximal pool size: %d)\n",
2835  SCIPcutpoolGetTime(scip->cutpool),
2839 
2840  /* sort separators w.r.t. their name */
2841  SCIPsetSortSepasName(scip->set);
2842 
2843  for( i = 0; i < scip->set->nsepas; ++i )
2844  {
2845  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s: %10.2f %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
2846  SCIPsepaGetName(scip->set->sepas[i]),
2847  SCIPsepaGetTime(scip->set->sepas[i]),
2848  SCIPsepaGetSetupTime(scip->set->sepas[i]),
2849  SCIPsepaGetNCalls(scip->set->sepas[i]),
2850  SCIPsepaGetNCutoffs(scip->set->sepas[i]),
2851  SCIPsepaGetNDomredsFound(scip->set->sepas[i]),
2852  SCIPsepaGetNCutsFound(scip->set->sepas[i]),
2853  SCIPsepaGetNCutsApplied(scip->set->sepas[i]),
2854  SCIPsepaGetNConssFound(scip->set->sepas[i]));
2855  }
2856 }
2857 
2858 /** outputs pricer statistics
2859  *
2860  * @pre This method can be called if SCIP is in one of the following stages:
2861  * - \ref SCIP_STAGE_SOLVING
2862  * - \ref SCIP_STAGE_SOLVED
2863  */
2865  SCIP* scip, /**< SCIP data structure */
2866  FILE* file /**< output file */
2867  )
2868 {
2869  int i;
2870 
2871  assert(scip != NULL);
2872  assert(scip->set != NULL);
2873 
2874  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintPricerStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2875 
2876  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Pricers : ExecTime SetupTime Calls Vars\n");
2877  SCIPmessageFPrintInfo(scip->messagehdlr, file, " problem variables: %10.2f - %10d %10d\n",
2881 
2882  /* sort pricers w.r.t. their name */
2883  SCIPsetSortPricersName(scip->set);
2884 
2885  for( i = 0; i < scip->set->nactivepricers; ++i )
2886  {
2887  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s: %10.2f %10.2f %10d %10d\n",
2888  SCIPpricerGetName(scip->set->pricers[i]),
2889  SCIPpricerGetTime(scip->set->pricers[i]),
2890  SCIPpricerGetSetupTime(scip->set->pricers[i]),
2891  SCIPpricerGetNCalls(scip->set->pricers[i]),
2892  SCIPpricerGetNVarsFound(scip->set->pricers[i]));
2893  }
2894 }
2895 
2896 /** outputs branching rule statistics
2897  *
2898  * @pre This method can be called if SCIP is in one of the following stages:
2899  * - \ref SCIP_STAGE_SOLVING
2900  * - \ref SCIP_STAGE_SOLVED
2901  */
2903  SCIP* scip, /**< SCIP data structure */
2904  FILE* file /**< output file */
2905  )
2906 {
2907  int i;
2908 
2909  assert(scip != NULL);
2910  assert(scip->set != NULL);
2911 
2912  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintBranchruleStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2913 
2914  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Branching Rules : ExecTime SetupTime BranchLP BranchExt BranchPS Cutoffs DomReds Cuts Conss Children\n");
2915 
2916  /* sort branching rules w.r.t. their name */
2918 
2919  for( i = 0; i < scip->set->nbranchrules; ++i )
2920  {
2933  }
2934 }
2935 
2936 /** outputs heuristics statistics
2937  *
2938  * @pre This method can be called if SCIP is in one of the following stages:
2939  * - \ref SCIP_STAGE_PRESOLVING
2940  * - \ref SCIP_STAGE_EXITPRESOLVE
2941  * - \ref SCIP_STAGE_PRESOLVED
2942  * - \ref SCIP_STAGE_SOLVING
2943  * - \ref SCIP_STAGE_SOLVED
2944  */
2946  SCIP* scip, /**< SCIP data structure */
2947  FILE* file /**< output file */
2948  )
2949 {
2950  int ndivesets = 0;
2951  int i;
2952 
2953  assert(scip != NULL);
2954  assert(scip->set != NULL);
2955  assert(scip->tree != NULL);
2956 
2957  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintHeuristicStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
2958 
2959  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Primal Heuristics : ExecTime SetupTime Calls Found Best\n");
2960  SCIPmessageFPrintInfo(scip->messagehdlr, file, " LP solutions : %10.2f - - %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
2962  scip->stat->nlpsolsfound, scip->stat->nlpbestsolsfound);
2963  SCIPmessageFPrintInfo(scip->messagehdlr, file, " relax solutions : %10.2f - - %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
2965  scip->stat->nrelaxsolsfound, scip->stat->nrelaxbestsolsfound);
2966  SCIPmessageFPrintInfo(scip->messagehdlr, file, " pseudo solutions : %10.2f - - %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
2968  scip->stat->npssolsfound, scip->stat->npsbestsolsfound);
2969  SCIPmessageFPrintInfo(scip->messagehdlr, file, " strong branching : %10.2f - - %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
2971  scip->stat->nsbsolsfound, scip->stat->nsbbestsolsfound);
2972 
2973  /* sort heuristics w.r.t. their names */
2974  SCIPsetSortHeursName(scip->set);
2975 
2976  for( i = 0; i < scip->set->nheurs; ++i )
2977  {
2978  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s: %10.2f %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
2979  SCIPheurGetName(scip->set->heurs[i]),
2980  SCIPheurGetTime(scip->set->heurs[i]),
2981  SCIPheurGetSetupTime(scip->set->heurs[i]),
2982  SCIPheurGetNCalls(scip->set->heurs[i]),
2983  SCIPheurGetNSolsFound(scip->set->heurs[i]),
2984  SCIPheurGetNBestSolsFound(scip->set->heurs[i]));
2985 
2986  /* count heuristics that use diving; needed to determine output later */
2987  ndivesets += SCIPheurGetNDivesets(scip->set->heurs[i]);
2988  }
2989 
2990  SCIPmessageFPrintInfo(scip->messagehdlr, file, " other solutions : - - - %10" SCIP_LONGINT_FORMAT " -\n",
2991  scip->stat->nexternalsolsfound);
2992 
2993  if ( ndivesets > 0 )
2994  {
2995  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Diving Statistics : Calls Nodes LP Iters Backtracks Conflicts MinDepth MaxDepth AvgDepth RoundSols NLeafSols MinSolDpt MaxSolDpt AvgSolDpt\n");
2996  for( i = 0; i < scip->set->nheurs; ++i )
2997  {
2998  int s;
2999  for( s = 0; s < SCIPheurGetNDivesets(scip->set->heurs[i]); ++s )
3000  {
3001  SCIP_DIVESET* diveset = SCIPheurGetDivesets(scip->set->heurs[i])[s];
3002  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s: %10d", SCIPdivesetGetName(diveset), SCIPdivesetGetNCalls(diveset));
3003  if( SCIPdivesetGetNCalls(diveset) > 0 )
3004  {
3005  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10d %10d %10.1f %10" SCIP_LONGINT_FORMAT,
3006  SCIPdivesetGetNProbingNodes(diveset),
3007  SCIPdivesetGetNLPIterations(diveset),
3008  SCIPdivesetGetNBacktracks(diveset),
3009  SCIPdivesetGetNConflicts(diveset),
3010  SCIPdivesetGetMinDepth(diveset),
3011  SCIPdivesetGetMaxDepth(diveset),
3012  SCIPdivesetGetAvgDepth(diveset),
3014 
3015  if( SCIPdivesetGetNSolutionCalls(diveset) > 0 )
3016  {
3017  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10d %10d %10d %10.1f\n",
3022  }
3023  else
3024  SCIPmessageFPrintInfo(scip->messagehdlr, file, " - - - -\n");
3025  }
3026  else
3027  SCIPmessageFPrintInfo(scip->messagehdlr, file, " - - - - - - - - - - - -\n");
3028  }
3029  }
3030  }
3031 }
3032 
3033 /** outputs compression statistics
3034  *
3035  * @pre This method can be called if SCIP is in one of the following stages:
3036  * - \ref SCIP_STAGE_PRESOLVING
3037  * - \ref SCIP_STAGE_EXITPRESOLVE
3038  * - \ref SCIP_STAGE_PRESOLVED
3039  * - \ref SCIP_STAGE_SOLVING
3040  * - \ref SCIP_STAGE_SOLVED
3041  */
3043  SCIP* scip, /**< SCIP data structure */
3044  FILE* file /**< output file */
3045  )
3046 {
3047  int i;
3048 
3049  assert(scip != NULL);
3050 
3051  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintCompressionStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3052 
3053  /* only print compression statistics if tree reoptimization is enabled */
3054  if( !scip->set->reopt_enable )
3055  return;
3056 
3057  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Tree Compressions : ExecTime SetupTime Calls Found\n");
3058 
3059  /* sort compressions w.r.t. their names */
3060  SCIPsetSortComprsName(scip->set);
3061 
3062  for( i = 0; i < scip->set->ncomprs; ++i )
3063  {
3064  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s: %10.2f %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
3065  SCIPcomprGetName(scip->set->comprs[i]),
3066  SCIPcomprGetTime(scip->set->comprs[i]),
3067  SCIPcomprGetSetupTime(scip->set->comprs[i]),
3068  SCIPcomprGetNCalls(scip->set->comprs[i]),
3069  SCIPcomprGetNFound(scip->set->comprs[i]));
3070  }
3071 }
3072 
3073 /** outputs LP statistics
3074  *
3075  * @pre This method can be called if SCIP is in one of the following stages:
3076  * - \ref SCIP_STAGE_SOLVING
3077  * - \ref SCIP_STAGE_SOLVED
3078  */
3080  SCIP* scip, /**< SCIP data structure */
3081  FILE* file /**< output file */
3082  )
3083 {
3084  assert(scip != NULL);
3085  assert(scip->stat != NULL);
3086  assert(scip->lp != NULL);
3087 
3088  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintLPStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3089 
3090  SCIPmessageFPrintInfo(scip->messagehdlr, file, "LP : Time Calls Iterations Iter/call Iter/sec Time-0-It Calls-0-It ItLimit\n");
3091 
3092  SCIPmessageFPrintInfo(scip->messagehdlr, file, " primal LP : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3094  scip->stat->nprimallps + scip->stat->nprimalzeroitlps,
3095  scip->stat->nprimallpiterations,
3096  scip->stat->nprimallps > 0 ? (SCIP_Real)scip->stat->nprimallpiterations/(SCIP_Real)scip->stat->nprimallps : 0.0);
3097  if( SCIPclockGetTime(scip->stat->primallptime) >= 0.01 )
3099  else
3100  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -");
3101  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10" SCIP_LONGINT_FORMAT "\n",
3102  scip->stat->primalzeroittime,
3103  scip->stat->nprimalzeroitlps);
3104 
3105  SCIPmessageFPrintInfo(scip->messagehdlr, file, " dual LP : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3107  scip->stat->nduallps + scip->stat->ndualzeroitlps,
3108  scip->stat->nduallpiterations,
3109  scip->stat->nduallps > 0 ? (SCIP_Real)scip->stat->nduallpiterations/(SCIP_Real)scip->stat->nduallps : 0.0);
3110  if( SCIPclockGetTime(scip->stat->duallptime) >= 0.01 )
3112  else
3113  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -");
3114  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10" SCIP_LONGINT_FORMAT "\n",
3115  scip->stat->dualzeroittime,
3116  scip->stat->ndualzeroitlps);
3117 
3118  SCIPmessageFPrintInfo(scip->messagehdlr, file, " lex dual LP : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3120  scip->stat->nlexduallps,
3121  scip->stat->nlexduallpiterations,
3122  scip->stat->nlexduallps > 0 ? (SCIP_Real)scip->stat->nlexduallpiterations/(SCIP_Real)scip->stat->nlexduallps : 0.0);
3123  if( SCIPclockGetTime(scip->stat->lexduallptime) >= 0.01 )
3125  else
3126  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -\n");
3127 
3128  SCIPmessageFPrintInfo(scip->messagehdlr, file, " barrier LP : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3130  scip->stat->nbarrierlps,
3131  scip->stat->nbarrierlpiterations,
3132  scip->stat->nbarrierlps > 0 ? (SCIP_Real)scip->stat->nbarrierlpiterations/(SCIP_Real)scip->stat->nbarrierlps : 0.0);
3133  if( SCIPclockGetTime(scip->stat->barrierlptime) >= 0.01 )
3135  else
3136  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -");
3137  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %10.2f %10" SCIP_LONGINT_FORMAT "\n",
3138  scip->stat->barrierzeroittime,
3139  scip->stat->nbarrierzeroitlps);
3140 
3141  SCIPmessageFPrintInfo(scip->messagehdlr, file, " resolve instable : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3143  scip->stat->nresolveinstablelps,
3146  if( SCIPclockGetTime(scip->stat->resolveinstablelptime) >= 0.01 )
3148  else
3149  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -\n");
3150 
3151  SCIPmessageFPrintInfo(scip->messagehdlr, file, " diving/probing LP: %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3153  scip->stat->ndivinglps,
3154  scip->stat->ndivinglpiterations,
3155  scip->stat->ndivinglps > 0 ? (SCIP_Real)scip->stat->ndivinglpiterations/(SCIP_Real)scip->stat->ndivinglps : 0.0);
3156  if( SCIPclockGetTime(scip->stat->divinglptime) >= 0.01 )
3158  else
3159  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -\n");
3160 
3161  SCIPmessageFPrintInfo(scip->messagehdlr, file, " strong branching : %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3163  scip->stat->nstrongbranchs,
3164  scip->stat->nsblpiterations,
3165  scip->stat->nstrongbranchs > 0 ? (SCIP_Real)scip->stat->nsblpiterations/(SCIP_Real)scip->stat->nstrongbranchs : 0.0);
3166  if( SCIPclockGetTime(scip->stat->strongbranchtime) >= 0.01 )
3168  else
3169  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -");
3170  SCIPmessageFPrintInfo(scip->messagehdlr, file, " - - %10d\n", scip->stat->nsbtimesiterlimhit);
3171 
3172  SCIPmessageFPrintInfo(scip->messagehdlr, file, " (at root node) : - %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f -\n",
3173  scip->stat->nrootstrongbranchs,
3174  scip->stat->nrootsblpiterations,
3175  scip->stat->nrootstrongbranchs > 0
3177 
3178  SCIPmessageFPrintInfo(scip->messagehdlr, file, " conflict analysis: %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10.2f",
3180  scip->stat->nconflictlps,
3181  scip->stat->nconflictlpiterations,
3182  scip->stat->nconflictlps > 0 ? (SCIP_Real)scip->stat->nconflictlpiterations/(SCIP_Real)scip->stat->nconflictlps : 0.0);
3183  if( SCIPclockGetTime(scip->stat->conflictlptime) >= 0.01 )
3185  else
3186  SCIPmessageFPrintInfo(scip->messagehdlr, file, " -\n");
3187 }
3188 
3189 /** outputs NLP statistics
3190  *
3191  * @pre This method can be called if SCIP is in one of the following stages:
3192  * - \ref SCIP_STAGE_SOLVING
3193  * - \ref SCIP_STAGE_SOLVED
3194  */
3196  SCIP* scip, /**< SCIP data structure */
3197  FILE* file /**< output file */
3198  )
3199 {
3200  assert(scip != NULL);
3201  assert(scip->stat != NULL);
3202 
3203  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintNLPStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3204 
3205  if( scip->nlp == NULL )
3206  return;
3207 
3208  SCIPmessageFPrintInfo(scip->messagehdlr, file, "NLP : Time Calls\n");
3209 
3210  SCIPmessageFPrintInfo(scip->messagehdlr, file, " all NLPs : %10.2f %10" SCIP_LONGINT_FORMAT "\n",
3212  scip->stat->nnlps);
3213 }
3214 
3215 /** outputs relaxator statistics
3216  *
3217  * @pre This method can be called if SCIP is in one of the following stages:
3218  * - \ref SCIP_STAGE_SOLVING
3219  * - \ref SCIP_STAGE_SOLVED
3220  */
3222  SCIP* scip, /**< SCIP data structure */
3223  FILE* file /**< output file */
3224  )
3225 {
3226  int i;
3227 
3228  assert(scip != NULL);
3229  assert(scip->set != NULL);
3230 
3231  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintRelaxatorStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3232 
3233  if( scip->set->nrelaxs == 0 )
3234  return;
3235 
3236  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Relaxators : Time Calls\n");
3237 
3238  /* sort relaxators w.r.t. their name */
3239  SCIPsetSortRelaxsName(scip->set);
3240 
3241  for( i = 0; i < scip->set->nrelaxs; ++i )
3242  {
3243  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s: %10.2f %10" SCIP_LONGINT_FORMAT "\n",
3244  SCIPrelaxGetName(scip->set->relaxs[i]),
3245  SCIPrelaxGetTime(scip->set->relaxs[i]),
3246  SCIPrelaxGetNCalls(scip->set->relaxs[i]));
3247  }
3248 }
3249 
3250 /** outputs tree statistics
3251  *
3252  * @pre This method can be called if SCIP is in one of the following stages:
3253  * - \ref SCIP_STAGE_SOLVING
3254  * - \ref SCIP_STAGE_SOLVED
3255  */
3257  SCIP* scip, /**< SCIP data structure */
3258  FILE* file /**< output file */
3259  )
3260 {
3261  assert(scip != NULL);
3262  assert(scip->stat != NULL);
3263  assert(scip->tree != NULL);
3264 
3265  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintTreeStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3266 
3267  SCIPmessageFPrintInfo(scip->messagehdlr, file, "B&B Tree :\n");
3268  SCIPmessageFPrintInfo(scip->messagehdlr, file, " number of runs : %10d\n", scip->stat->nruns);
3269  SCIPmessageFPrintInfo(scip->messagehdlr, file,
3270  " nodes : %10" SCIP_LONGINT_FORMAT " (%" SCIP_LONGINT_FORMAT " internal, %" SCIP_LONGINT_FORMAT " leaves)\n",
3271  scip->stat->nnodes, scip->stat->ninternalnodes, scip->stat->nnodes - scip->stat->ninternalnodes );
3272  SCIPmessageFPrintInfo(scip->messagehdlr, file, " feasible leaves : %10d\n", scip->stat->nfeasleaves);
3273  SCIPmessageFPrintInfo(scip->messagehdlr, file, " infeas. leaves : %10d\n", scip->stat->ninfeasleaves);
3274  SCIPmessageFPrintInfo(scip->messagehdlr, file, " objective leaves : %10d\n", scip->stat->nobjleaves);
3275  SCIPmessageFPrintInfo(scip->messagehdlr, file,
3276  " nodes (total) : %10" SCIP_LONGINT_FORMAT " (%" SCIP_LONGINT_FORMAT " internal, %" SCIP_LONGINT_FORMAT " leaves)\n",
3278  SCIPmessageFPrintInfo(scip->messagehdlr, file, " nodes left : %10d\n", SCIPtreeGetNNodes(scip->tree));
3279  SCIPmessageFPrintInfo(scip->messagehdlr, file, " max depth : %10d\n", scip->stat->maxdepth);
3280  SCIPmessageFPrintInfo(scip->messagehdlr, file, " max depth (total): %10d\n", scip->stat->maxtotaldepth);
3281  SCIPmessageFPrintInfo(scip->messagehdlr, file, " backtracks : %10" SCIP_LONGINT_FORMAT " (%.1f%%)\n", scip->stat->nbacktracks,
3282  scip->stat->nnodes > 0 ? 100.0 * (SCIP_Real)scip->stat->nbacktracks / (SCIP_Real)scip->stat->nnodes : 0.0);
3283  SCIPmessageFPrintInfo(scip->messagehdlr, file, " early backtracks : %10" SCIP_LONGINT_FORMAT " (%.1f%%)\n", scip->stat->nearlybacktracks,
3284  scip->stat->nbacktracks > 0 ? 100.0 * (SCIP_Real)scip->stat->nearlybacktracks / (SCIP_Real)scip->stat->nbacktracks : 0.0);
3285  SCIPmessageFPrintInfo(scip->messagehdlr, file, " nodes exc. ref. : %10" SCIP_LONGINT_FORMAT " (%.1f%%)\n", scip->stat->nnodesaboverefbound,
3286  scip->stat->nnodes > 0 ? 100.0 * (SCIP_Real)scip->stat->nnodesaboverefbound / (SCIP_Real)scip->stat->nnodes : 0.0);
3287 
3288  SCIPmessageFPrintInfo(scip->messagehdlr, file, " delayed cutoffs : %10" SCIP_LONGINT_FORMAT "\n", scip->stat->ndelayedcutoffs);
3289  SCIPmessageFPrintInfo(scip->messagehdlr, file, " repropagations : %10" SCIP_LONGINT_FORMAT " (%" SCIP_LONGINT_FORMAT " domain reductions, %" SCIP_LONGINT_FORMAT " cutoffs)\n",
3290  scip->stat->nreprops, scip->stat->nrepropboundchgs, scip->stat->nrepropcutoffs);
3291  SCIPmessageFPrintInfo(scip->messagehdlr, file, " avg switch length: %10.2f\n",
3292  scip->stat->nnodes > 0
3293  ? (SCIP_Real)(scip->stat->nactivatednodes + scip->stat->ndeactivatednodes) / (SCIP_Real)scip->stat->nnodes : 0.0);
3294  SCIPmessageFPrintInfo(scip->messagehdlr, file, " switching time : %10.2f\n", SCIPclockGetTime(scip->stat->nodeactivationtime));
3295 }
3296 
3297 /** outputs solution statistics
3298  *
3299  * @pre This method can be called if SCIP is in one of the following stages:
3300  * - \ref SCIP_STAGE_PRESOLVING
3301  * - \ref SCIP_STAGE_EXITPRESOLVE
3302  * - \ref SCIP_STAGE_PRESOLVED
3303  * - \ref SCIP_STAGE_SOLVING
3304  * - \ref SCIP_STAGE_SOLVED
3305  */
3307  SCIP* scip, /**< SCIP data structure */
3308  FILE* file /**< output file */
3309  )
3310 {
3311  SCIP_Real primalbound;
3312  SCIP_Real dualbound;
3313  SCIP_Real gap;
3314  SCIP_Real firstprimalbound;
3315  SCIP_Bool objlimitreached;
3316  char limsolstring[SCIP_MAXSTRLEN];
3317 
3318  assert(scip != NULL);
3319  assert(scip->stat != NULL);
3320  assert(scip->primal != NULL);
3321 
3322  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintSolutionStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3323 
3324  primalbound = SCIPgetPrimalbound(scip);
3325  dualbound = SCIPgetDualbound(scip);
3326  gap = SCIPgetGap(scip);
3327 
3328  /* We output that the objective limit has been reached if the problem has been solved, no solution respecting the
3329  * objective limit has been found (nlimsolsfound == 0) and the primal bound is finite. Note that it still might be
3330  * that the original problem is infeasible, even without the objective limit, i.e., we cannot be sure that we
3331  * actually reached the objective limit. */
3332  objlimitreached = FALSE;
3333  if( SCIPgetStage(scip) == SCIP_STAGE_SOLVED && scip->primal->nlimsolsfound == 0 && !SCIPisInfinity(scip, primalbound) )
3334  objlimitreached = TRUE;
3335 
3336  if( scip->primal->nsolsfound != scip->primal->nlimsolsfound )
3337  (void) SCIPsnprintf(limsolstring, SCIP_MAXSTRLEN, ", %" SCIP_LONGINT_FORMAT " respecting the objective limit", scip->primal->nlimsolsfound);
3338  else
3339  limsolstring[0] = '\0';
3340 
3341  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Solution :\n");
3342  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Solutions found : %10" SCIP_LONGINT_FORMAT " (%" SCIP_LONGINT_FORMAT " improvements%s)\n",
3343  scip->primal->nsolsfound, scip->primal->nbestsolsfound, limsolstring);
3344 
3345  if( SCIPsetIsInfinity(scip->set, REALABS(primalbound)) )
3346  {
3347  if( scip->set->stage == SCIP_STAGE_SOLVED )
3348  {
3349  if( scip->primal->nlimsolsfound == 0 )
3350  {
3351  if( SCIPgetStatus(scip) == SCIP_STATUS_INFORUNBD )
3352  {
3353  assert(!objlimitreached);
3354  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Primal Bound : infeasible or unbounded\n");
3355  }
3356  else
3357  {
3358  assert(SCIPgetStatus(scip) == SCIP_STATUS_INFEASIBLE);
3359  if( objlimitreached )
3360  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Primal Bound : infeasible (objective limit reached)\n");
3361  else
3362  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Primal Bound : infeasible\n");
3363  }
3364  }
3365  else
3366  {
3367  assert(!objlimitreached);
3368  assert(SCIPgetStatus(scip) == SCIP_STATUS_UNBOUNDED);
3369  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Primal Bound : unbounded\n");
3370  }
3371  }
3372  else
3373  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Primal Bound : -\n");
3374  }
3375  else
3376  {
3377  if( scip->primal->nlimsolsfound == 0 )
3378  {
3379  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Primal Bound : %+21.14e (objective limit)\n", primalbound);
3380 
3381  /* display (best) primal bound */
3382  if( scip->primal->nsolsfound > 0 )
3383  {
3384  SCIP_Real bestsol;
3385  bestsol = SCIPsolGetObj(scip->primal->sols[0], scip->set, scip->transprob, scip->origprob);
3386  bestsol = SCIPretransformObj(scip, bestsol);
3387 
3388  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Best Solution : %+21.14e\n", bestsol);
3389  }
3390  }
3391  else
3392  {
3393  /* display first primal bound line */
3394  firstprimalbound = scip->stat->firstprimalbound;
3395  SCIPmessageFPrintInfo(scip->messagehdlr, file, " First Solution : %+21.14e", firstprimalbound);
3396 
3397  SCIPmessageFPrintInfo(scip->messagehdlr, file, " (in run %d, after %" SCIP_LONGINT_FORMAT " nodes, %.2f seconds, depth %d, found by <%s>)\n",
3398  scip->stat->nrunsbeforefirst,
3399  scip->stat->nnodesbeforefirst,
3400  scip->stat->firstprimaltime,
3401  scip->stat->firstprimaldepth,
3402  ( scip->stat->firstprimalheur != NULL )
3403  ? ( SCIPheurGetName(scip->stat->firstprimalheur) )
3404  : (( scip->stat->nrunsbeforefirst == 0 ) ? "initial" : "relaxation"));
3405 
3406  if( SCIPisInfinity(scip, scip->stat->firstsolgap) )
3407  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Gap First Sol. : infinite\n");
3408  else
3409  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Gap First Sol. : %10.2f %%\n", 100.0 * scip->stat->firstsolgap);
3410 
3411  if( SCIPisInfinity(scip, scip->stat->lastsolgap) )
3412  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Gap Last Sol. : infinite\n");
3413  else
3414  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Gap Last Sol. : %10.2f %%\n", 100.0 * scip->stat->lastsolgap);
3415 
3416  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Primal Bound : %+21.14e", primalbound);
3417 
3418  SCIPmessageFPrintInfo(scip->messagehdlr, file, " (in run %d, after %" SCIP_LONGINT_FORMAT " nodes, %.2f seconds, depth %d, found by <%s>)\n",
3419  SCIPsolGetRunnum(scip->primal->sols[0]),
3420  SCIPsolGetNodenum(scip->primal->sols[0]),
3421  SCIPsolGetTime(scip->primal->sols[0]),
3422  SCIPsolGetDepth(scip->primal->sols[0]),
3423  SCIPsolGetHeur(scip->primal->sols[0]) != NULL
3425  : (SCIPsolGetRunnum(scip->primal->sols[0]) == 0 ? "initial" : "relaxation"));
3426  }
3427  }
3428 
3429  if( SCIPsetIsInfinity(scip->set, REALABS(dualbound)) )
3430  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Dual Bound : -\n");
3431  else
3432  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Dual Bound : %+21.14e\n", dualbound);
3433 
3434  if( SCIPsetIsInfinity(scip->set, gap) )
3435  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Gap : infinite\n");
3436  else
3437  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Gap : %10.2f %%\n", 100.0 * gap);
3438 
3439  if( scip->set->misc_calcintegral )
3440  {
3441  if( SCIPgetStatus(scip) == SCIP_STATUS_INFEASIBLE && ! objlimitreached )
3442  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Avg. Gap : - (problem infeasible)\n");
3443  else
3444  {
3445  SCIP_Real avggap;
3446  SCIP_Real primaldualintegral;
3447 
3448  if( !SCIPisFeasZero(scip, SCIPgetSolvingTime(scip)) )
3449  {
3450  primaldualintegral = SCIPstatGetPrimalDualIntegral(scip->stat, scip->set, scip->transprob, scip->origprob);
3451  avggap = primaldualintegral/SCIPgetSolvingTime(scip);
3452  }
3453  else
3454  {
3455  avggap = 0.0;
3456  primaldualintegral = 0.0;
3457  }
3458 
3459  /* caution: this assert is non-deterministic since it depends on the solving time */
3460  assert(0.0 <= avggap && SCIPisLE(scip, avggap, 100.0));
3461 
3462  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Avg. Gap : %10.2f %% (%.2f primal-dual integral)\n",
3463  avggap, primaldualintegral);
3464  }
3465  }
3466  else
3467  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Avg. Gap : - (not evaluated)\n");
3468 }
3469 
3470 /** outputs concurrent solver statistics
3471  *
3472  * @pre This method can be called if SCIP is in one of the following stages:
3473  * - \ref SCIP_STAGE_TRANSFORMED
3474  * - \ref SCIP_STAGE_INITPRESOLVE
3475  * - \ref SCIP_STAGE_PRESOLVING
3476  * - \ref SCIP_STAGE_EXITPRESOLVE
3477  * - \ref SCIP_STAGE_PRESOLVED
3478  * - \ref SCIP_STAGE_SOLVING
3479  * - \ref SCIP_STAGE_SOLVED
3480  */
3482  SCIP* scip, /**< SCIP data structure */
3483  FILE* file /**< output file */
3484  )
3485 {
3486  SCIP_CONCSOLVER** concsolvers;
3487  int nconcsolvers;
3488  int i;
3489  int winner;
3490 
3491  assert(scip != NULL);
3492  assert(scip->set != NULL);
3493 
3494  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintConcsolverStatistics", FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3495 
3497  return;
3498 
3499  nconcsolvers = SCIPgetNConcurrentSolvers(scip);
3500  concsolvers = SCIPgetConcurrentSolvers(scip);
3501  winner = SCIPsyncstoreGetWinner(scip->syncstore);
3502 
3503  if( nconcsolvers > 0 )
3504  {
3505  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Concurrent Solvers : SolvingTime SyncTime Nodes LP Iters SolsShared SolsRecvd TighterBnds TighterIntBnds\n");
3506  for( i = 0; i < nconcsolvers; ++i )
3507  {
3508  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %c%-16s: %11.2f %11.2f %11" SCIP_LONGINT_FORMAT " %11" SCIP_LONGINT_FORMAT "%11i %11i %11" SCIP_LONGINT_FORMAT " %14" SCIP_LONGINT_FORMAT "\n",
3509  winner == i ? '*' : ' ',
3510  SCIPconcsolverGetName(concsolvers[i]),
3511  SCIPconcsolverGetSolvingTime(concsolvers[i]),
3512  SCIPconcsolverGetSyncTime(concsolvers[i]),
3513  SCIPconcsolverGetNNodes(concsolvers[i]),
3514  SCIPconcsolverGetNLPIterations(concsolvers[i]),
3515  SCIPconcsolverGetNSolsShared(concsolvers[i]),
3516  SCIPconcsolverGetNSolsRecvd(concsolvers[i]),
3517  SCIPconcsolverGetNTighterBnds(concsolvers[i]),
3518  SCIPconcsolverGetNTighterIntBnds(concsolvers[i])
3519  );
3520  }
3521  }
3522 }
3523 
3524 /** display Benders' decomposition statistics */
3526  SCIP* scip, /**< SCIP data structure */
3527  FILE* file /**< output file */
3528  )
3529 {
3530  SCIP_BENDERS** benders;
3531  int nbenders;
3532  int i;
3533 
3534  assert(scip != NULL);
3535  assert(scip->set != NULL);
3536 
3537  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintBendersStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3538 
3539  if( SCIPgetNActiveBenders(scip) == 0 )
3540  return;
3541 
3542  nbenders = SCIPgetNBenders(scip);
3543  benders = SCIPgetBenders(scip);
3544 
3545  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Benders Decomp : ExecTime SetupTime Calls Found Transfer\n");
3546  for( i = 0; i < nbenders; ++i )
3547  {
3548  if( SCIPbendersIsActive(benders[i]) )
3549  {
3550  SCIP_BENDERSCUT** benderscuts;
3551  int nbenderscuts;
3552  int j;
3553 
3554  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-17.17s: %10.2f %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT "\n",
3555  SCIPbendersGetName(scip->set->benders[i]),
3556  SCIPbendersGetTime(scip->set->benders[i]),
3557  SCIPbendersGetSetupTime(scip->set->benders[i]),
3558  SCIPbendersGetNCalls(scip->set->benders[i]),
3561 
3562  nbenderscuts = SCIPbendersGetNBenderscuts(scip->set->benders[i]);
3563  benderscuts = SCIPbendersGetBenderscuts(scip->set->benders[i]);
3564 
3565  for( j = 0; j < nbenderscuts; j++ )
3566  {
3567  SCIPmessageFPrintInfo(scip->messagehdlr, file, " %-15.17s: %10.2f %10.2f %10" SCIP_LONGINT_FORMAT " %10" SCIP_LONGINT_FORMAT " -\n",
3568  SCIPbenderscutGetName(benderscuts[j]),
3569  SCIPbenderscutGetTime(benderscuts[j]),
3570  SCIPbenderscutGetSetupTime(benderscuts[j]),
3571  SCIPbenderscutGetNCalls(benderscuts[j]),
3572  SCIPbenderscutGetNFound(benderscuts[j]));
3573  }
3574  }
3575  }
3576 }
3577 
3578 /** outputs root statistics
3579  *
3580  * @pre This method can be called if SCIP is in one of the following stages:
3581  * - \ref SCIP_STAGE_SOLVING
3582  * - \ref SCIP_STAGE_SOLVED
3583  */
3585  SCIP* scip, /**< SCIP data structure */
3586  FILE* file /**< output file */
3587  )
3588 {
3589  SCIP_Real dualboundroot;
3590  SCIP_Real firstdualboundroot;
3591  SCIP_Real firstlptime;
3592  SCIP_Real firstlpspeed;
3593 
3594  assert(scip != NULL);
3595  assert(scip->stat != NULL);
3596  assert(scip->primal != NULL);
3597 
3598  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintRootStatistics", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3599 
3600  dualboundroot = SCIPgetDualboundRoot(scip);
3601  firstdualboundroot = SCIPgetFirstLPDualboundRoot(scip);
3602  firstlptime = SCIPgetFirstLPTime(scip);
3603 
3604  if( firstlptime > 0.0 )
3605  firstlpspeed = (SCIP_Real)scip->stat->nrootfirstlpiterations/firstlptime;
3606  else
3607  firstlpspeed = 0.0;
3608 
3609  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Root Node :\n");
3610  if( SCIPsetIsInfinity(scip->set, REALABS(firstdualboundroot)) )
3611  SCIPmessageFPrintInfo(scip->messagehdlr, file, " First LP value : -\n");
3612  else
3613  SCIPmessageFPrintInfo(scip->messagehdlr, file, " First LP value : %+21.14e\n", firstdualboundroot);
3614  if( firstlpspeed > 0.0 )
3615  SCIPmessageFPrintInfo(scip->messagehdlr, file, " First LP Iters : %10" SCIP_LONGINT_FORMAT " (%.2f Iter/sec)\n",
3617  (SCIP_Real)scip->stat->nrootfirstlpiterations/firstlptime);
3618  else
3619  SCIPmessageFPrintInfo(scip->messagehdlr, file, " First LP Iters : %10" SCIP_LONGINT_FORMAT "\n", scip->stat->nrootfirstlpiterations);
3620  SCIPmessageFPrintInfo(scip->messagehdlr, file, " First LP Time : %10.2f\n", firstlptime);
3621 
3622  if( SCIPsetIsInfinity(scip->set, REALABS(dualboundroot)) )
3623  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Final Dual Bound : -\n");
3624  else
3625  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Final Dual Bound : %+21.14e\n", dualboundroot);
3626  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Final Root Iters : %10" SCIP_LONGINT_FORMAT "\n", scip->stat->nrootlpiterations);
3627 
3628  SCIPmessageFPrintInfo(scip->messagehdlr, file, " Root LP Estimate : ");
3629  if( scip->stat->rootlpbestestimate != SCIP_INVALID ) /*lint !e777*/
3630  {
3631  SCIPmessageFPrintInfo(scip->messagehdlr, file, "%+21.14e\n", SCIPretransformObj(scip, scip->stat->rootlpbestestimate));
3632  }
3633  else
3634  SCIPmessageFPrintInfo(scip->messagehdlr, file, "%21s\n","-");
3635 }
3636 
3637 /** outputs timing statistics
3638  *
3639  * @pre This method can be called if SCIP is in one of the following stages:
3640  * - \ref SCIP_STAGE_PROBLEM
3641  * - \ref SCIP_STAGE_TRANSFORMED
3642  * - \ref SCIP_STAGE_INITPRESOLVE
3643  * - \ref SCIP_STAGE_PRESOLVING
3644  * - \ref SCIP_STAGE_EXITPRESOLVE
3645  * - \ref SCIP_STAGE_PRESOLVED
3646  * - \ref SCIP_STAGE_SOLVING
3647  * - \ref SCIP_STAGE_SOLVED
3648  */
3650  SCIP* scip, /**< SCIP data structure */
3651  FILE* file /**< output file */
3652  )
3653 {
3654  SCIP_Real readingtime;
3655 
3656  assert(scip != NULL);
3657  assert(scip->set != NULL);
3658 
3659  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPprintTimingStatistics", FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3660 
3661  readingtime = SCIPgetReadingTime(scip);
3662 
3663  if( SCIPgetStage(scip) == SCIP_STAGE_PROBLEM )
3664  {
3665  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Total Time : %10.2f\n", readingtime);
3666  SCIPmessageFPrintInfo(scip->messagehdlr, file, " reading : %10.2f\n", readingtime);
3667  }
3668  else
3669  {
3670  SCIP_Real totaltime;
3671  SCIP_Real solvingtime;
3672 
3673  solvingtime = SCIPclockGetTime(scip->stat->solvingtime);
3674 
3675  if( scip->set->time_reading )
3676  totaltime = solvingtime;
3677  else
3678  totaltime = solvingtime + readingtime;
3679 
3680  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Total Time : %10.2f\n", totaltime);
3681  SCIPmessageFPrintInfo(scip->messagehdlr, file, " solving : %10.2f\n", solvingtime);
3682  SCIPmessageFPrintInfo(scip->messagehdlr, file, " presolving : %10.2f (included in solving)\n", SCIPclockGetTime(scip->stat->presolvingtime));
3683  SCIPmessageFPrintInfo(scip->messagehdlr, file, " reading : %10.2f%s\n", readingtime, scip->set->time_reading ? " (included in solving)" : "");
3684 
3685  if( scip->stat->ncopies > 0 )
3686  {
3687  SCIP_Real copytime;
3688 
3689  copytime = SCIPclockGetTime(scip->stat->copyclock);
3690 
3691  SCIPmessageFPrintInfo(scip->messagehdlr, file, " copying : %10.2f (%d #copies) (minimal %.2f, maximal %.2f, average %.2f)\n",
3692  copytime, scip->stat->ncopies, scip->stat->mincopytime, scip->stat->maxcopytime, copytime / scip->stat->ncopies);
3693  }
3694  else
3695  SCIPmessageFPrintInfo(scip->messagehdlr, file, " copying : %10.2f %s\n", 0.0, "(0 times copied the problem)");
3696  }
3697 }
3698 
3699 /** comparison method for statistics tables */
3700 static
3702 { /*lint --e{715}*/
3703  return (SCIPtableGetPosition((SCIP_TABLE*)elem1) - (SCIPtableGetPosition((SCIP_TABLE*)elem2)));
3704 }
3705 
3706 /** outputs solving statistics
3707  *
3708  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
3709  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
3710  *
3711  * @note If limits have been changed between the solution and the call to this function, the status is recomputed and
3712  * thus may to correspond to the original status.
3713  *
3714  * @pre This method can be called if SCIP is in one of the following stages:
3715  * - \ref SCIP_STAGE_INIT
3716  * - \ref SCIP_STAGE_PROBLEM
3717  * - \ref SCIP_STAGE_TRANSFORMED
3718  * - \ref SCIP_STAGE_INITPRESOLVE
3719  * - \ref SCIP_STAGE_PRESOLVING
3720  * - \ref SCIP_STAGE_EXITPRESOLVE
3721  * - \ref SCIP_STAGE_PRESOLVED
3722  * - \ref SCIP_STAGE_SOLVING
3723  * - \ref SCIP_STAGE_SOLVED
3724  */
3726  SCIP* scip, /**< SCIP data structure */
3727  FILE* file /**< output file (or NULL for standard output) */
3728  )
3729 {
3730  SCIP_TABLE** tables;
3731  int ntables;
3732  int i;
3733 
3734  assert(scip != NULL);
3735  assert(scip->set != NULL);
3736 
3737  SCIP_CALL( SCIPcheckStage(scip, "SCIPprintStatistics", TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3738 
3739  ntables = SCIPgetNTables(scip);
3740  tables = SCIPgetTables(scip);
3741 
3742  /* sort all tables by position unless this has already been done */
3743  if( ! scip->set->tablessorted )
3744  {
3745  SCIPsortPtr((void**)tables, tablePosComp, ntables);
3746 
3747  scip->set->tablessorted = TRUE;
3748  }
3749 
3750  for( i = 0; i < ntables; ++i )
3751  {
3752  /* skip tables which are not active or only used in later stages */
3753  if( ( ! SCIPtableIsActive(tables[i]) ) || SCIPtableGetEarliestStage(tables[i]) > SCIPgetStage(scip) )
3754  continue;
3755 
3756  SCIP_CALL( SCIPtableOutput(tables[i], scip->set, file) );
3757  }
3758 
3759  return SCIP_OKAY;
3760 }
3761 
3762 /** outputs reoptimization statistics
3763  *
3764  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
3765  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
3766  *
3767  * @pre This method can be called if SCIP is in one of the following stages:
3768  * - \ref SCIP_STAGE_INIT
3769  * - \ref SCIP_STAGE_PROBLEM
3770  * - \ref SCIP_STAGE_TRANSFORMED
3771  * - \ref SCIP_STAGE_INITPRESOLVE
3772  * - \ref SCIP_STAGE_PRESOLVING
3773  * - \ref SCIP_STAGE_EXITPRESOLVE
3774  * - \ref SCIP_STAGE_PRESOLVED
3775  * - \ref SCIP_STAGE_SOLVING
3776  * - \ref SCIP_STAGE_SOLVED
3777  */
3779  SCIP* scip, /**< SCIP data structure */
3780  FILE* file /**< output file (or NULL for standard output) */
3781  )
3782 {
3783  SCIP_Real solving;
3784  SCIP_Real presolving;
3785  SCIP_Real updatetime;
3786 
3787  SCIP_CALL( SCIPcheckStage(scip, "SCIPprintReoptStatistics", TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3788 
3789  /* skip if reoptimization is disabled */
3790  if( !scip->set->reopt_enable )
3791  return SCIP_OKAY;
3792 
3793  solving = SCIPclockGetTime(scip->stat->solvingtimeoverall);
3794  presolving = SCIPclockGetTime(scip->stat->presolvingtimeoverall);
3795  updatetime = SCIPclockGetTime(scip->stat->reoptupdatetime);
3796 
3797  SCIPmessageFPrintInfo(scip->messagehdlr, file, "SCIP Reopt Status : finish after %d runs.\n", scip->stat->nreoptruns);
3798  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Time (sec) :\n");
3799  SCIPmessageFPrintInfo(scip->messagehdlr, file, " solving : %10.2f\n", solving);
3800  SCIPmessageFPrintInfo(scip->messagehdlr, file, " presolving : %10.2f (included in solving)\n", presolving);
3801  SCIPmessageFPrintInfo(scip->messagehdlr, file, " save time : %10.2f\n", SCIPreoptGetSavingtime(scip->reopt));
3802  SCIPmessageFPrintInfo(scip->messagehdlr, file, " update time : %10.2f\n", updatetime);
3803  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Nodes : feas infeas pruned cutoff\n");
3804  SCIPmessageFPrintInfo(scip->messagehdlr, file, " total : %10d %10d %10d %10d\n",
3807  SCIPmessageFPrintInfo(scip->messagehdlr, file, " avg : %10.2f %10.2f %10.2f %10.2f\n",
3812 
3813  SCIPmessageFPrintInfo(scip->messagehdlr, file, "Restarts : global local\n");
3814  SCIPmessageFPrintInfo(scip->messagehdlr, file, " first : %10d --\n", SCIPreoptGetFirstRestarts(scip->reopt));
3815  SCIPmessageFPrintInfo(scip->messagehdlr, file, " last : %10d --\n", SCIPreoptGetLastRestarts(scip->reopt));
3816  SCIPmessageFPrintInfo(scip->messagehdlr, file, " total : %10d %10d\n", SCIPreoptGetNRestartsGlobal(scip->reopt),
3818  SCIPmessageFPrintInfo(scip->messagehdlr, file, " avg : -- %10.2f\n",
3820 
3821  return SCIP_OKAY;
3822 }
3823 
3824 /** outputs history statistics about branchings on variables
3825  *
3826  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
3827  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
3828  *
3829  * @pre This method can be called if SCIP is in one of the following stages:
3830  * - \ref SCIP_STAGE_INIT
3831  * - \ref SCIP_STAGE_PROBLEM
3832  * - \ref SCIP_STAGE_TRANSFORMED
3833  * - \ref SCIP_STAGE_INITPRESOLVE
3834  * - \ref SCIP_STAGE_PRESOLVING
3835  * - \ref SCIP_STAGE_EXITPRESOLVE
3836  * - \ref SCIP_STAGE_PRESOLVED
3837  * - \ref SCIP_STAGE_SOLVING
3838  * - \ref SCIP_STAGE_SOLVED
3839  */
3841  SCIP* scip, /**< SCIP data structure */
3842  FILE* file /**< output file (or NULL for standard output) */
3843  )
3844 {
3845  SCIP_VAR** vars;
3846  int totalnstrongbranchs;
3847  int v;
3848 
3849  SCIP_CALL( SCIPcheckStage(scip, "SCIPprintBranchingStatistics", TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3850 
3851  switch( scip->set->stage )
3852  {
3853  case SCIP_STAGE_INIT:
3854  case SCIP_STAGE_PROBLEM:
3855  SCIPmessageFPrintInfo(scip->messagehdlr, file, "problem not yet solved. branching statistics not available.\n");
3856  return SCIP_OKAY;
3857 
3860  case SCIP_STAGE_PRESOLVING:
3862  case SCIP_STAGE_PRESOLVED:
3863  case SCIP_STAGE_SOLVING:
3864  case SCIP_STAGE_SOLVED:
3865  SCIP_CALL( SCIPallocBufferArray(scip, &vars, scip->transprob->nvars) );
3866  for( v = 0; v < scip->transprob->nvars; ++v )
3867  {
3868  SCIP_VAR* var;
3869  int i;
3870 
3871  var = scip->transprob->vars[v];
3872  for( i = v; i > 0 && strcmp(SCIPvarGetName(var), SCIPvarGetName(vars[i-1])) < 0; i-- )
3873  vars[i] = vars[i-1];
3874  vars[i] = var;
3875  }
3876 
3877  SCIPmessageFPrintInfo(scip->messagehdlr, file, " locks branchings inferences cutoffs LP gain pscostcount gain variance \n");
3878  SCIPmessageFPrintInfo(scip->messagehdlr, file, "variable prio factor down up depth down up sb down up down up down up down up down up\n");
3879 
3880  totalnstrongbranchs = 0;
3881  for( v = 0; v < scip->transprob->nvars; ++v )
3882  {
3885  || SCIPgetVarNStrongbranchs(scip, vars[v]) > 0 )
3886  {
3887  int nstrongbranchs;
3888 
3889  nstrongbranchs = SCIPgetVarNStrongbranchs(scip, vars[v]);
3890  totalnstrongbranchs += nstrongbranchs;
3891  SCIPmessageFPrintInfo(scip->messagehdlr, file, "%-16s %5d %8.1f %6d %6d %6.1f %7" SCIP_LONGINT_FORMAT " %7" SCIP_LONGINT_FORMAT " %5d %8.1f %8.1f %5.1f%% %5.1f%% %15.4f %15.4f %7.1f %7.1f %15.2f %15.2f\n",
3892  SCIPvarGetName(vars[v]),
3893  SCIPvarGetBranchPriority(vars[v]),
3894  SCIPvarGetBranchFactor(vars[v]),
3898  + SCIPvarGetAvgBranchdepth(vars[v], SCIP_BRANCHDIR_UPWARDS))/2.0 - 1.0,
3901  nstrongbranchs,
3904  100.0 * SCIPvarGetAvgCutoffs(vars[v], scip->stat, SCIP_BRANCHDIR_DOWNWARDS),
3905  100.0 * SCIPvarGetAvgCutoffs(vars[v], scip->stat, SCIP_BRANCHDIR_UPWARDS),
3906  SCIPvarGetPseudocost(vars[v], scip->stat, -1.0),
3907  SCIPvarGetPseudocost(vars[v], scip->stat, +1.0),
3912  }
3913  }
3914  SCIPmessageFPrintInfo(scip->messagehdlr, file, "total %7" SCIP_LONGINT_FORMAT " %7" SCIP_LONGINT_FORMAT " %5d %8.1f %8.1f %5.1f%% %5.1f%% %15.4f %15.4f %7.1f %7.1f %15.2f %15.2f\n",
3917  totalnstrongbranchs,
3936 
3937  SCIPfreeBufferArray(scip, &vars);
3938 
3939  return SCIP_OKAY;
3940 
3941  default:
3942  SCIPerrorMessage("invalid SCIP stage <%d>\n", scip->set->stage);
3943  return SCIP_INVALIDCALL;
3944  } /*lint !e788*/
3945 }
3946 
3947 /** outputs node information display line
3948  *
3949  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
3950  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
3951  *
3952  * @pre This method can be called if SCIP is in one of the following stages:
3953  * - \ref SCIP_STAGE_SOLVING
3954  */
3956  SCIP* scip, /**< SCIP data structure */
3957  FILE* file, /**< output file (or NULL for standard output) */
3958  SCIP_VERBLEVEL verblevel, /**< minimal verbosity level to actually display the information line */
3959  SCIP_Bool endline /**< should the line be terminated with a newline symbol? */
3960  )
3961 {
3962  SCIP_CALL( SCIPcheckStage(scip, "SCIPprintDisplayLine", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, FALSE, FALSE, FALSE, FALSE) );
3963 
3964  if( (SCIP_VERBLEVEL)scip->set->disp_verblevel >= verblevel )
3965  {
3966  SCIP_CALL( SCIPdispPrintLine(scip->set, scip->messagehdlr, scip->stat, file, TRUE, endline) );
3967  }
3968 
3969  return SCIP_OKAY;
3970 }
3971 
3972 /** gets total number of implications between variables that are stored in the implication graph
3973  *
3974  * @return the total number of implications between variables that are stored in the implication graph
3975  *
3976  * @pre This method can be called if SCIP is in one of the following stages:
3977  * - \ref SCIP_STAGE_INITPRESOLVE
3978  * - \ref SCIP_STAGE_PRESOLVING
3979  * - \ref SCIP_STAGE_EXITPRESOLVE
3980  * - \ref SCIP_STAGE_PRESOLVED
3981  * - \ref SCIP_STAGE_INITSOLVE
3982  * - \ref SCIP_STAGE_SOLVING
3983  * - \ref SCIP_STAGE_SOLVED
3984  */
3986  SCIP* scip /**< SCIP data structure */
3987  )
3988 {
3989  SCIP_CALL_ABORT( SCIPcheckStage(scip, "SCIPgetNImplications", FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE) );
3990 
3991  return scip->stat->nimplications;
3992 }
3993 
3994 /** stores conflict graph of binary variables' implications into a file, which can be used as input for the DOT tool
3995  *
3996  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
3997  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
3998  *
3999  * @pre This method can be called if SCIP is in one of the following stages:
4000  * - \ref SCIP_STAGE_TRANSFORMED
4001  * - \ref SCIP_STAGE_INITPRESOLVE
4002  * - \ref SCIP_STAGE_PRESOLVING
4003  * - \ref SCIP_STAGE_EXITPRESOLVE
4004  * - \ref SCIP_STAGE_PRESOLVED
4005  * - \ref SCIP_STAGE_INITSOLVE
4006  * - \ref SCIP_STAGE_SOLVING
4007  * - \ref SCIP_STAGE_SOLVED
4008  * - \ref SCIP_STAGE_EXITSOLVE
4009  *
4010  * @deprecated because binary implications are now stored as cliques, please use SCIPwriteCliqueGraph() instead
4011  *
4012  */
4014  SCIP* scip, /**< SCIP data structure */
4015  const char* filename /**< file name, or NULL for stdout */
4016  )
4017 { /*lint --e{715}*/
4018  SCIPwarningMessage(scip, "SCIPwriteImplicationConflictGraph() is deprecated and does not do anything anymore. All binary to binary implications are now stored in the clique data structure, which can be written to a GML formatted file via SCIPwriteCliqueGraph().\n");
4019 
4020  return SCIP_OKAY;
4021 }
4022 
4023 /** update statistical information when a new solution was found */
4025  SCIP* scip /**< SCIP data structure */
4026  )
4027 {
4029 
4030  if( scip->primal->nsols == 1 )
4031  scip->stat->firstsolgap = scip->stat->lastsolgap;
4032 
4033  if( scip->set->stage == SCIP_STAGE_SOLVING && scip->set->misc_calcintegral )
4034  {
4036  }
4037 }
enum SCIP_Result SCIP_RESULT
Definition: type_result.h:52
SCIP_Real SCIPhistoryGetAvgConflictlength(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:554
SCIP_Real cutoffbound
Definition: struct_primal.h:46
SCIP_Longint SCIPbranchruleGetNConssFound(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2142
SCIP_Longint nlexduallps
Definition: struct_stat.h:182
SCIP_EXPORT SCIP_Real SCIPsepaGetSetupTime(SCIP_SEPA *sepa)
Definition: sepa.c:793
SCIP_Longint nprimallps
Definition: struct_stat.h:178
SCIP_Longint SCIPconflictGetNStrongbranchSuccess(SCIP_CONFLICT *conflict)
Definition: conflict.c:8733
SCIP_STAT * stat
Definition: struct_scip.h:69
int SCIPpresolGetNDelConss(SCIP_PRESOL *presol)
Definition: presol.c:757
void SCIPsetSortPropsName(SCIP_SET *set)
Definition: set.c:4272
SCIP_Longint ndualresolvelpiterations
Definition: struct_stat.h:61
int SCIPpropGetNAddConss(SCIP_PROP *prop)
Definition: prop.c:1216
SCIP_Longint SCIPgetNStrongbranchs(SCIP *scip)
SCIP_Longint SCIPgetNSolsFound(SCIP *scip)
SCIP_Longint SCIPheurGetNCalls(SCIP_HEUR *heur)
Definition: heur.c:1380
SCIP_EXPORT const char * SCIPreaderGetName(SCIP_READER *reader)
Definition: reader.c:547
SCIP_Longint SCIPbranchruleGetNLPCalls(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2090
SCIP_Real SCIPcomprGetSetupTime(SCIP_COMPR *compr)
Definition: compr.c:530
SCIP_Longint SCIPconflictGetNLocalChgBds(SCIP_CONFLICT *conflict)
Definition: conflict.c:3650
SCIP_Bool SCIPsetIsInfinity(SCIP_SET *set, SCIP_Real val)
Definition: set.c:5953
SCIP_Longint ninfeasleaves
Definition: struct_stat.h:77
SCIP_Real firstlpdualbound
Definition: struct_stat.h:118
void SCIPprintConflictStatistics(SCIP *scip, FILE *file)
#define NULL
Definition: def.h:253
SCIP_RETCODE SCIPprintDisplayLine(SCIP *scip, FILE *file, SCIP_VERBLEVEL verblevel, SCIP_Bool endline)
SCIP_Longint SCIPconflictGetNPropConflictConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:5585
SCIP_Bool SCIPconshdlrNeedsCons(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:5107
SCIP_READER ** readers
Definition: struct_set.h:68
SCIP_Longint nnodelpiterations
Definition: struct_stat.h:63
SCIP_EXPORT SCIP_Bool SCIPtableIsActive(SCIP_TABLE *table)
Definition: table.c:339
SCIP_Longint SCIPheurGetNSolsFound(SCIP_HEUR *heur)
Definition: heur.c:1390
SCIP_Longint nlpsolsfound
Definition: struct_stat.h:92
internal methods for storing primal CIP solutions
SCIP_Longint SCIPbenderscutGetNCalls(SCIP_BENDERSCUT *benderscut)
Definition: benderscut.c:549
const char * SCIPheurGetName(SCIP_HEUR *heur)
Definition: heur.c:1254
SCIP_Longint nlpiterations
Definition: struct_stat.h:53
public methods for branching and inference history structure
SCIP_RETCODE SCIPprintStage(SCIP *scip, FILE *file)
Definition: scip_general.c:377
SCIP_Real SCIPpricerGetSetupTime(SCIP_PRICER *pricer)
Definition: pricer.c:652
internal methods for branch and bound tree
SCIP_Real SCIPpropGetSetupTime(SCIP_PROP *prop)
Definition: prop.c:1024
SCIP_Longint nfeasleaves
Definition: struct_stat.h:76
SCIP_CONFLICT * conflict
Definition: struct_scip.h:85
SCIP_Real SCIPconshdlrGetSepaTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4687
SCIP_EXPORT SCIP_Real SCIPsepaGetTime(SCIP_SEPA *sepa)
Definition: sepa.c:803
SCIP_Longint ndeactivatednodes
Definition: struct_stat.h:84
SCIP_Longint SCIPconflictGetNPropSuccess(SCIP_CONFLICT *conflict)
Definition: conflict.c:5575
SCIP_Longint SCIPpropGetNRespropCalls(SCIP_PROP *prop)
Definition: prop.c:1096
int SCIPgetNConcurrentSolvers(SCIP *scip)
Definition: concurrent.c:107
SCIP_EXPORT int SCIPvarGetNLocksUpType(SCIP_VAR *var, SCIP_LOCKTYPE locktype)
Definition: var.c:3241
public methods for memory management
SCIP_Real SCIPgetAvgInferences(SCIP *scip, SCIP_BRANCHDIR dir)
int npricerounds
Definition: struct_stat.h:216
int SCIPpricestoreGetNVars(SCIP_PRICESTORE *pricestore)
Definition: pricestore.c:602
SCIP_Longint SCIPbranchruleGetNChildren(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2162
SCIP_STATUS SCIPgetStatus(SCIP *scip)
Definition: scip_general.c:466
SCIP_Longint SCIPconshdlrGetNChildren(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4907
int SCIPgetNCutsApplied(SCIP *scip)
SCIP_Longint SCIPconflictGetNBoundexceedingLPConflictConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:8359
int SCIPpricestoreGetNProbvarsFound(SCIP_PRICESTORE *pricestore)
Definition: pricestore.c:644
SCIP_Longint SCIPgetNDualResolveLPIterations(SCIP *scip)
SCIP_BENDERS ** SCIPgetBenders(SCIP *scip)
Definition: scip_benders.c:470
SCIP_RETCODE SCIPdispPrintLine(SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, SCIP_STAT *stat, FILE *file, SCIP_Bool forcedisplay, SCIP_Bool endline)
Definition: disp.c:405
SCIP_Longint nlps
Definition: struct_stat.h:176
SCIP_Longint SCIPconflictGetNAppliedGlobalConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:3630
SCIP_Longint nbarrierlpiterations
Definition: struct_stat.h:59
SCIP_Real SCIPpricestoreGetProbPricingTime(SCIP_PRICESTORE *pricestore)
Definition: pricestore.c:624
SCIP_Longint SCIPconflictGetNBoundexceedingLPIterations(SCIP_CONFLICT *conflict)
Definition: conflict.c:8399
SCIP_CLOCK * conflictlptime
Definition: struct_stat.h:155
int nrunsbeforefirst
Definition: struct_stat.h:254
#define SCIP_MAXSTRLEN
Definition: def.h:274
SCIP_RETCODE SCIPwriteImplicationConflictGraph(SCIP *scip, const char *filename)
SCIP_Real SCIPbenderscutGetSetupTime(SCIP_BENDERSCUT *benderscut)
Definition: benderscut.c:579
const char * SCIPbranchruleGetName(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:1970
SCIP_Real rootlowerbound
Definition: struct_stat.h:119
SCIP_Longint SCIPconshdlrGetNEnfoPSCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4787
SCIP_EXPORT SCIP_Longint SCIPvarGetNBranchings(SCIP_VAR *var, SCIP_BRANCHDIR dir)
Definition: var.c:15187
SCIP_Longint SCIPgetNFeasibleLeaves(SCIP *scip)
SCIP_Longint SCIPconshdlrGetNEnfoRelaxCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4797
SCIP_Longint SCIPconflictGetNPseudoReconvergenceLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:9010
void SCIPwarningMessage(SCIP *scip, const char *formatstr,...)
Definition: scip_message.c:122
internal methods for clocks and timing issues
SCIP_Longint ntotalnodes
Definition: struct_stat.h:78
SCIP_Real SCIPgetAvgLowerbound(SCIP *scip)
SCIP_Longint SCIPconflictGetNGlobalChgBds(SCIP_CONFLICT *conflict)
Definition: conflict.c:3620
int SCIPpricerGetNVarsFound(SCIP_PRICER *pricer)
Definition: pricer.c:642
SCIP_EXPORT SCIP_Real SCIPvarGetBranchFactor(SCIP_VAR *var)
Definition: var.c:17512
int SCIPgetNConflictConssFoundNode(SCIP *scip)
SCIP_Longint nrootfirstlpiterations
Definition: struct_stat.h:55
int nprops
Definition: struct_set.h:112
SCIP_Longint SCIPconflictGetNPseudoConflictLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:8990
SCIP_EXPORT int SCIPreoptGetNTotalPrunedNodes(SCIP_REOPT *reopt)
Definition: reopt.c:4984
SCIP_Longint ndivinglps
Definition: struct_stat.h:190
int SCIPconshdlrGetNChgBds(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4967
SCIP_Longint SCIPconflictGetNInfeasibleLPSuccess(SCIP_CONFLICT *conflict)
Definition: conflict.c:8269
static SCIP_DECL_SORTPTRCOMP(tablePosComp)
void SCIPsetSortComprsName(SCIP_SET *set)
Definition: set.c:4551
SCIP_EVENTQUEUE * eventqueue
Definition: struct_scip.h:78
SCIP_Longint nsbtimesiterlimhit
Definition: struct_stat.h:112
void SCIPprintLPStatistics(SCIP *scip, FILE *file)
SCIP_EXPORT SCIP_Longint SCIPsepaGetNCutsFound(SCIP_SEPA *sepa)
Definition: sepa.c:843
SCIP_Longint SCIPconflictGetNPropCalls(SCIP_CONFLICT *conflict)
Definition: conflict.c:5565
SCIP_Longint SCIPconflictGetNDualrayInfSuccess(SCIP_CONFLICT *conflict)
Definition: conflict.c:8663
SCIP_Real SCIPgetGap(SCIP *scip)
SCIP_EXPORT int SCIPreoptGetNTotalCutoffReoptnodes(SCIP_REOPT *reopt)
Definition: reopt.c:5004
int nintvars
Definition: struct_prob.h:63
SCIP_Longint SCIPdivesetGetNLPIterations(SCIP_DIVESET *diveset)
Definition: heur.c:468
public methods for timing
SCIP_PRIMAL * primal
Definition: struct_scip.h:83
SCIP_Longint SCIPgetNNodeInitLPIterations(SCIP *scip)
int SCIPcutpoolGetMaxNCuts(SCIP_CUTPOOL *cutpool)
Definition: cutpool.c:1060
SCIP_Longint SCIPpropGetNDomredsFound(SCIP_PROP *prop)
Definition: prop.c:1116
int SCIPgetNEnabledConss(SCIP *scip)
SCIP_Real lastsolgap
Definition: struct_stat.h:124
int SCIPgetNCutsFoundRound(SCIP *scip)
SCIP_Longint SCIPconflictGetNStrongbranchIterations(SCIP_CONFLICT *conflict)
Definition: conflict.c:8783
SCIP_Longint nrootstrongbranchs
Definition: struct_stat.h:195
int SCIPpresolGetNCalls(SCIP_PRESOL *presol)
Definition: presol.c:807
SCIP_Real SCIPsetInfinity(SCIP_SET *set)
Definition: set.c:5813
SCIP_Bool time_reading
Definition: struct_set.h:552
internal methods for displaying statistics tables
int nreoptruns
Definition: struct_stat.h:257
SCIP_EXPORT SCIP_Longint SCIPrelaxGetNCalls(SCIP_RELAX *relax)
Definition: relax.c:566
SCIP_SOL ** sols
Definition: struct_primal.h:48
SCIP_Real SCIPbranchGetScore(SCIP_SET *set, SCIP_VAR *var, SCIP_Real downgain, SCIP_Real upgain)
Definition: branch.c:2189
SCIP_Real SCIPgetReadingTime(SCIP *scip)
Definition: scip_timing.c:386
SCIP_Longint SCIPgetNLimSolsFound(SCIP *scip)
SCIP_Longint nstrongbranchs
Definition: struct_stat.h:194
void SCIPstoreSolutionGap(SCIP *scip)
int SCIPsepastoreGetNCutsApplied(SCIP_SEPASTORE *sepastore)
Definition: sepastore.c:1116
SCIP_Real SCIPgetAvgCutoffScoreCurrentRun(SCIP *scip)
SCIP_Bool tablessorted
Definition: struct_set.h:162
SCIP_Real SCIPgetSolvingTime(SCIP *scip)
Definition: scip_timing.c:359
SCIP_Longint nrootsblpiterations
Definition: struct_stat.h:69
SCIP_Longint SCIPconflictGetNInfeasibleLPReconvergenceConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:8299
SCIP_Longint SCIPconflictGetNInfeasibleLPReconvergenceLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:8309
#define FALSE
Definition: def.h:73
SCIP_SEPA ** sepas
Definition: struct_set.h:77
SCIP_Longint SCIPbenderscutGetNFound(SCIP_BENDERSCUT *benderscut)
Definition: benderscut.c:559
public methods for Benders&#39; decomposition
int SCIPdivesetGetMaxSolutionDepth(SCIP_DIVESET *diveset)
Definition: heur.c:448
char * SCIPconcsolverGetName(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:290
SCIP_EXPORT SCIP_HEUR * SCIPsolGetHeur(SCIP_SOL *sol)
Definition: sol.c:2553
SCIP_STAGE stage
Definition: struct_set.h:63
#define TRUE
Definition: def.h:72
void SCIPprintBranchruleStatistics(SCIP *scip, FILE *file)
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
SCIP_Longint SCIPconflictGetNPropConflictLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:5595
void SCIPprintSeparatorStatistics(SCIP *scip, FILE *file)
int nenabledconss
Definition: struct_stat.h:223
SCIP_Longint SCIPconcsolverGetNSolsShared(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:582
SCIP_Longint nnlps
Definition: struct_stat.h:197
SCIP_Real SCIPprobInternObjval(SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_SET *set, SCIP_Real objval)
Definition: prob.c:2096
SCIP_Longint nbacktracks
Definition: struct_stat.h:87
void SCIPprintConcsolverStatistics(SCIP *scip, FILE *file)
enum SCIP_VerbLevel SCIP_VERBLEVEL
Definition: type_message.h:48
internal methods for branching rules and branching candidate storage
SCIP_Real SCIPconshdlrGetStrongBranchPropTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4737
SCIP_Real SCIPconshdlrGetEnfoRelaxTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4717
datastructures for concurrent solvers
public methods for problem variables
SCIP_Longint nsolsfound
Definition: struct_primal.h:39
int nheurs
Definition: struct_set.h:114
int maxtotaldepth
Definition: struct_stat.h:220
SCIP_Real SCIPvarGetAvgInferences(SCIP_VAR *var, SCIP_STAT *stat, SCIP_BRANCHDIR dir)
Definition: var.c:15555
public methods for reoptimization
SCIP_CLOCK * barrierlptime
Definition: struct_stat.h:151
SCIP_Real SCIPhistoryGetVSIDS(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:512
public methods for branching rules
SCIP_Longint SCIPconshdlrGetNSepaCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4767
SCIP_Longint nnodesaboverefbound
Definition: struct_stat.h:86
SCIP_Real SCIPgetUpperbound(SCIP *scip)
SCIP_Longint SCIPgetNBarrierLPs(SCIP *scip)
SCIP_Longint SCIPgetNStrongbranchLPIterations(SCIP *scip)
SCIP_PROB * transprob
Definition: struct_scip.h:87
SCIP_EXPORT SCIP_STAGE SCIPtableGetEarliestStage(SCIP_TABLE *table)
Definition: table.c:329
int SCIPconshdlrGetNAddHoles(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4977
SCIP_Longint SCIPgetNNodeLPIterations(SCIP *scip)
SCIP_PRESOL ** presols
Definition: struct_set.h:75
const char * SCIPcomprGetName(SCIP_COMPR *compr)
Definition: compr.c:446
SCIP_CLOCK * copyclock
Definition: struct_stat.h:162
int SCIPpropGetNChgSides(SCIP_PROP *prop)
Definition: prop.c:1246
SCIP_Real rootlpbestestimate
Definition: struct_stat.h:139
#define SCIPfreeBufferArray(scip, ptr)
Definition: scip_mem.h:123
SCIP_RELAX ** relaxs
Definition: struct_set.h:76
SCIP_Real SCIPconflictGetGlobalApplTime(SCIP_CONFLICT *conflict)
Definition: conflict.c:5545
SCIP_EXPORT int SCIPsolGetRunnum(SCIP_SOL *sol)
Definition: sol.c:2523
int maxdepth
Definition: struct_stat.h:219
SCIP_Real SCIPgetFirstLPTime(SCIP *scip)
Definition: scip_timing.c:449
public methods for SCIP variables
SCIP_Real SCIPconshdlrGetSetupTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4667
int SCIPconshdlrGetMaxNActiveConss(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4917
SCIP_Real SCIPhistoryGetAvgCutoffs(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:667
SCIP_Longint SCIPconflictGetNStrongbranchReconvergenceLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:8773
int SCIPgetNReoptRuns(SCIP *scip)
SCIP_Real SCIPconflictGetPseudoTime(SCIP_CONFLICT *conflict)
Definition: conflict.c:8950
SCIP_CLOCK * nlpsoltime
Definition: struct_stat.h:161
SCIP_Longint SCIPconflictGetNInfeasibleLPConflictLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:8289
SCIP_Longint SCIPconflictGetNPropReconvergenceConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:5605
SCIP_Real SCIPgetCutoffbound(SCIP *scip)
SCIP_Longint nlpbestsolsfound
Definition: struct_stat.h:96
SCIP_Real dualzeroittime
Definition: struct_stat.h:126
void SCIPsetSortHeursName(SCIP_SET *set)
Definition: set.c:4477
int nbranchrules
Definition: struct_set.h:122
SCIP_PROB * origprob
Definition: struct_scip.h:70
SCIP_Longint nexternalsolsfound
Definition: struct_stat.h:100
SCIP_Longint SCIPheurGetNBestSolsFound(SCIP_HEUR *heur)
Definition: heur.c:1400
SCIP_Real SCIPgetAvgInferencesCurrentRun(SCIP *scip, SCIP_BRANCHDIR dir)
SCIP_Real SCIPhistoryGetPseudocost(SCIP_HISTORY *history, SCIP_Real solvaldelta)
Definition: history.c:422
SCIP_Bool SCIPconshdlrDoesPresolve(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:5117
void SCIPprintCompressionStatistics(SCIP *scip, FILE *file)
SCIP_Bool SCIPisInfinity(SCIP *scip, SCIP_Real val)
internal methods for branching and inference history
SCIP_Longint SCIPgetNPrimalLPIterations(SCIP *scip)
SCIP_Longint SCIPgetNDualLPIterations(SCIP *scip)
int nrootintfixings
Definition: struct_stat.h:207
SCIP_Real SCIPconflictGetStrongbranchTime(SCIP_CONFLICT *conflict)
Definition: conflict.c:8653
SCIP_Longint SCIPconflictGetNAppliedLocalLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:3670
public methods for numerical tolerances
internal methods for collecting primal CIP solutions and primal informations
SCIP_Longint SCIPconflictGetNDualrayBndNonzeros(SCIP_CONFLICT *conflict)
Definition: conflict.c:8713
SCIP_Longint SCIPconflictGetNPseudoConflictConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:8980
SCIP_Bool reopt_enable
Definition: struct_set.h:468
SCIP_Longint SCIPconflictGetNDualrayInfGlobal(SCIP_CONFLICT *conflict)
Definition: conflict.c:8673
SCIP_Longint SCIPgetNLPs(SCIP *scip)
SCIP_Longint nsblpiterations
Definition: struct_stat.h:68
SCIP_Real primalzeroittime
Definition: struct_stat.h:125
SCIP_Real SCIPgetFirstLPDualboundRoot(SCIP *scip)
SCIP_Real SCIPpropGetTime(SCIP_PROP *prop)
Definition: prop.c:1046
int nrootboundchgs
Definition: struct_stat.h:205
SCIP_Real SCIPdivesetGetAvgSolutionDepth(SCIP_DIVESET *diveset)
Definition: heur.c:458
public methods for querying solving statistics
SCIP_HISTORY * glbhistorycrun
Definition: struct_stat.h:166
SCIP_Bool SCIPisLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Real dualbound
Definition: struct_prob.h:45
void SCIPaddNNodes(SCIP *scip, SCIP_Longint nnodes)
SCIP_PRICESTORE * pricestore
Definition: struct_scip.h:90
void SCIPprobPrintStatistics(SCIP_PROB *prob, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, FILE *file)
Definition: prob.c:2178
enum SCIP_BranchDir SCIP_BRANCHDIR
Definition: type_history.h:39
const char * SCIPbenderscutGetName(SCIP_BENDERSCUT *benderscut)
Definition: benderscut.c:508
int SCIPdivesetGetMinSolutionDepth(SCIP_DIVESET *diveset)
Definition: heur.c:438
SCIP_Real SCIPbendersGetTime(SCIP_BENDERS *benders)
Definition: benders.c:4307
void SCIPprintPresolverStatistics(SCIP *scip, FILE *file)
SCIP_Real SCIPconshdlrGetPresolTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4677
SCIP_Longint SCIPgetNNodes(SCIP *scip)
SCIP_Longint nlexduallpiterations
Definition: struct_stat.h:58
int SCIPpresolGetNFixedVars(SCIP_PRESOL *presol)
Definition: presol.c:707
SCIP_MEM * mem
Definition: struct_scip.h:61
public methods for managing constraints
SCIP_Real SCIPhistoryGetPseudocostVariance(SCIP_HISTORY *history, SCIP_BRANCHDIR direction)
Definition: history.c:436
SCIP_Real barrierzeroittime
Definition: struct_stat.h:127
int SCIPgetMaxDepth(SCIP *scip)
SCIP_Real SCIPvarGetPseudocost(SCIP_VAR *var, SCIP_STAT *stat, SCIP_Real solvaldelta)
Definition: var.c:13965
SCIP_Real SCIPgetPseudocostCount(SCIP *scip, SCIP_BRANCHDIR dir, SCIP_Bool onlycurrentrun)
int SCIPpresolGetNChgVarTypes(SCIP_PRESOL *presol)
Definition: presol.c:727
SCIP_Bool SCIPpropDoesPresolve(SCIP_PROP *prop)
Definition: prop.c:1276
SCIP_Longint nobjleaves
Definition: struct_stat.h:75
SCIP_Longint SCIPconcsolverGetNSolsRecvd(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:572
SCIP_EXPORT int SCIPreoptGetNRestartsGlobal(SCIP_REOPT *reopt)
Definition: reopt.c:4904
SCIP_Real SCIPsolGetObj(SCIP_SOL *sol, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob)
Definition: sol.c:1498
SCIP_Longint npssolsfound
Definition: struct_stat.h:94
SCIP_Real SCIPconcsolverGetSolvingTime(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:532
SCIP_Longint SCIPconflictGetNInfeasibleLPConflictConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:8279
SCIP_TABLE ** SCIPgetTables(SCIP *scip)
Definition: scip_table.c:97
int SCIPpricestoreGetNVarsApplied(SCIP_PRICESTORE *pricestore)
Definition: pricestore.c:664
SCIP_EXPORT const char * SCIPvarGetName(SCIP_VAR *var)
Definition: var.c:16738
public methods for displaying statistic tables
SCIP_Real SCIPgetAvgPseudocostCountCurrentRun(SCIP *scip, SCIP_BRANCHDIR dir)
SCIP_Real SCIPgetAvgPseudocostScore(SCIP *scip)
SCIP_Real mincopytime
Definition: struct_stat.h:129
SCIP_Longint SCIPbranchruleGetNExternCalls(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2100
SCIP_Longint SCIPgetNRootFirstLPIterations(SCIP *scip)
int SCIPbendersGetNTransferredCuts(SCIP_BENDERS *benders)
Definition: benders.c:4737
SCIP_EXPORT int SCIPtableGetPosition(SCIP_TABLE *table)
Definition: table.c:319
public methods for Benders decomposition
internal methods for storing and manipulating the main problem
#define SCIPerrorMessage
Definition: pub_message.h:45
SCIP_Real SCIPpropGetRespropTime(SCIP_PROP *prop)
Definition: prop.c:1066
SCIP_Bool SCIPsyncstoreIsInitialized(SCIP_SYNCSTORE *syncstore)
Definition: syncstore.c:775
SCIP_Longint SCIPconshdlrGetNEnfoLPCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4777
SCIP_Real SCIPpropGetStrongBranchPropTime(SCIP_PROP *prop)
Definition: prop.c:1056
int SCIPheurGetNDivesets(SCIP_HEUR *heur)
Definition: heur.c:1462
SCIP_Longint nbestsolsfound
Definition: struct_primal.h:42
SCIP_Longint SCIPgetNTotalNodes(SCIP *scip)
SCIP_Longint SCIPconflictGetNBoundexceedingLPReconvergenceConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:8379
SCIP_SYNCSTORE * syncstore
Definition: struct_scip.h:98
SCIP_Longint SCIPgetNNZs(SCIP *scip)
SCIP_Real SCIPcutpoolGetTime(SCIP_CUTPOOL *cutpool)
Definition: cutpool.c:1070
SCIP_Longint SCIPconflictGetNDualrayBndGlobal(SCIP_CONFLICT *conflict)
Definition: conflict.c:8703
int SCIPdivesetGetNSolutionCalls(SCIP_DIVESET *diveset)
Definition: heur.c:398
SCIP_Real SCIPgetAvgConflictScoreCurrentRun(SCIP *scip)
int SCIPpresolGetNAddConss(SCIP_PRESOL *presol)
Definition: presol.c:767
SCIP_Longint nconflictlpiterations
Definition: struct_stat.h:70
SCIP_EXPORT int SCIPvarGetBranchPriority(SCIP_VAR *var)
Definition: var.c:17524
SCIP_CLOCK * pseudosoltime
Definition: struct_stat.h:158
SCIP_Longint nrelaxbestsolsfound
Definition: struct_stat.h:97
SCIP_Longint SCIPconflictGetNPseudoReconvergenceConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:9000
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
SCIP_HEUR * firstprimalheur
Definition: struct_stat.h:169
int SCIPconshdlrGetStartNActiveConss(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4927
SCIP_Real SCIPpresolGetSetupTime(SCIP_PRESOL *presol)
Definition: presol.c:687
SCIP_CONSHDLR ** conshdlrs
Definition: struct_set.h:70
SCIP_Longint SCIPconflictGetNAppliedLocalConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:3660
const char * SCIPpropGetName(SCIP_PROP *prop)
Definition: prop.c:931
SCIP_Longint ninitlpiterations
Definition: struct_stat.h:64
SCIP_CONFLICTSTORE * conflictstore
Definition: struct_scip.h:93
SCIP_CLOCK * solvingtimeoverall
Definition: struct_stat.h:145
int SCIPpropGetNAddHoles(SCIP_PROP *prop)
Definition: prop.c:1196
SCIP_Longint SCIPgetNNodeLPs(SCIP *scip)
SCIP_EXPORT int SCIPsolGetDepth(SCIP_SOL *sol)
Definition: sol.c:2543
int SCIPbendersGetNCutsFound(SCIP_BENDERS *benders)
Definition: benders.c:4287
SCIP_Longint SCIPdivesetGetNProbingNodes(SCIP_DIVESET *diveset)
Definition: heur.c:478
int SCIPgetNActiveConss(SCIP *scip)
SCIP_RETCODE SCIPtableOutput(SCIP_TABLE *table, SCIP_SET *set, FILE *file)
Definition: table.c:262
SCIP_Bool SCIPisPrimalboundSol(SCIP *scip)
SCIP_Real SCIPgetFirstPrimalBound(SCIP *scip)
SCIP_Real SCIPconflictGetBoundexceedingLPTime(SCIP_CONFLICT *conflict)
Definition: conflict.c:8329
SCIP_Real SCIPgetAvgInferenceScore(SCIP *scip)
SCIP_Real SCIPclockGetTime(SCIP_CLOCK *clck)
Definition: clock.c:428
SCIP_REOPT * reopt
Definition: struct_scip.h:74
SCIP_RETCODE SCIPprintBranchingStatistics(SCIP *scip, FILE *file)
SCIP_EXPORT SCIP_Real SCIPrelaxGetTime(SCIP_RELAX *relax)
Definition: relax.c:556
int SCIPgetNPriceRounds(SCIP *scip)
const char * SCIPdivesetGetName(SCIP_DIVESET *diveset)
Definition: heur.c:354
SCIP_Real SCIPcomprGetTime(SCIP_COMPR *compr)
Definition: compr.c:540
SCIP_Longint SCIPdivesetGetNSols(SCIP_DIVESET *diveset)
Definition: heur.c:508
SCIP_Longint nprimalresolvelpiterations
Definition: struct_stat.h:60
SCIP_Longint SCIPconflictGetNStrongbranchReconvergenceConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:8763
int nrelaxs
Definition: struct_set.h:108
SCIP_Longint SCIPgetNDelayedCutoffs(SCIP *scip)
int nseparounds
Definition: struct_stat.h:217
SCIP_HISTORY * glbhistory
Definition: struct_stat.h:165
#define REALABS(x)
Definition: def.h:188
SCIP_Real SCIPdivesetGetAvgDepth(SCIP_DIVESET *diveset)
Definition: heur.c:428
int SCIPpropGetNPresolCalls(SCIP_PROP *prop)
Definition: prop.c:1256
SCIP_Longint nconflictlps
Definition: struct_stat.h:196
SCIP_RETCODE SCIPprintOrigProblem(SCIP *scip, FILE *file, const char *extension, SCIP_Bool genericnames)
SCIP_Longint SCIPcutpoolGetNCutsFound(SCIP_CUTPOOL *cutpool)
Definition: cutpool.c:1090
SCIP_Real SCIPgetPseudocostVariance(SCIP *scip, SCIP_BRANCHDIR branchdir, SCIP_Bool onlycurrentrun)
SCIP_Real SCIPgetAvgConflictlengthScoreCurrentRun(SCIP *scip)
SCIP_Longint SCIPbranchruleGetNCutsFound(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2130
public methods for primal CIP solutions
SCIP_Longint SCIPconflictGetNStrongbranchConflictLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:8753
SCIP_Longint SCIPgetNObjlimLeaves(SCIP *scip)
internal methods for global SCIP settings
internal methods for storing conflicts
#define SCIP_CALL(x)
Definition: def.h:365
int SCIPconshdlrGetNAddConss(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4997
int SCIPpropGetNChgVarTypes(SCIP_PROP *prop)
Definition: prop.c:1176
int SCIPconflictstoreGetInitPoolSize(SCIP_CONFLICTSTORE *conflictstore)
SCIP main data structure.
int SCIPgetNBenders(SCIP *scip)
Definition: scip_benders.c:483
SCIP_Longint nsbbestsolsfound
Definition: struct_stat.h:99
SCIP_Real SCIPvarGetPseudocostCount(SCIP_VAR *var, SCIP_BRANCHDIR dir)
Definition: var.c:14061
SCIP_Longint nduallpiterations
Definition: struct_stat.h:57
SCIP_Longint nbarrierzeroitlps
Definition: struct_stat.h:184
SCIP_Longint SCIPconflictGetNPseudoSuccess(SCIP_CONFLICT *conflict)
Definition: conflict.c:8970
SCIP_EXPORT const char * SCIPsepaGetName(SCIP_SEPA *sepa)
Definition: sepa.c:696
internal methods for storing priced variables
int SCIPpropGetNFixedVars(SCIP_PROP *prop)
Definition: prop.c:1156
SCIP_Real SCIPhistoryGetPseudocostCount(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:460
SCIP_Longint SCIPpropGetNCalls(SCIP_PROP *prop)
Definition: prop.c:1086
SCIP_Real vsidsweight
Definition: struct_stat.h:120
int nsepas
Definition: struct_set.h:110
SCIP_Real SCIPpropGetPresolTime(SCIP_PROP *prop)
Definition: prop.c:1076
int SCIPconshdlrGetNUpgdConss(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:5007
void SCIPprintTransProblemStatistics(SCIP *scip, FILE *file)
SCIP_Longint SCIPconflictGetNInfeasibleLPCalls(SCIP_CONFLICT *conflict)
Definition: conflict.c:8259
void SCIPprintPropagatorStatistics(SCIP *scip, FILE *file)
internal methods for storing separated cuts
SCIP_EXPORT void SCIPsortPtr(void **ptrarray, SCIP_DECL_SORTPTRCOMP((*ptrcomp)), int len)
SCIP_RETCODE SCIPreaderWrite(SCIP_READER *reader, SCIP_PROB *prob, SCIP_SET *set, FILE *file, const char *extension, SCIP_Bool genericnames, SCIP_RESULT *result)
Definition: reader.c:260
void SCIPsetSortPresolsName(SCIP_SET *set)
Definition: set.c:4032
SCIP_Real SCIPpresolGetTime(SCIP_PRESOL *presol)
Definition: presol.c:697
SCIP_Longint nprimalresolvelps
Definition: struct_stat.h:185
SCIP_Longint nresolveinstablelps
Definition: struct_stat.h:71
SCIP_Longint SCIPconcsolverGetNNodes(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:562
SCIP_Longint SCIPconcsolverGetNTighterIntBnds(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:602
int SCIPgetNPricevarsApplied(SCIP *scip)
SCIP_CLOCK * divinglptime
Definition: struct_stat.h:153
SCIP_Longint nprobboundchgs
Definition: struct_stat.h:108
SCIP_Longint SCIPconshdlrGetNRespropCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4827
SCIP_CLOCK * presolvingtimeoverall
Definition: struct_stat.h:147
SCIP_CUTPOOL * cutpool
Definition: struct_scip.h:94
SCIP_Longint SCIPgetNRootStrongbranchs(SCIP *scip)
SCIP_BRANCHRULE ** branchrules
Definition: struct_set.h:85
SCIP_Real SCIPtreeGetAvgLowerbound(SCIP_TREE *tree, SCIP_Real cutoffbound)
Definition: tree.c:7250
SCIP_Longint nduallps
Definition: struct_stat.h:180
SCIP_Longint SCIPgetNDivingLPIterations(SCIP *scip)
SCIP_Bool SCIPisFeasZero(SCIP *scip, SCIP_Real val)
SCIP_Real SCIPbendersGetSetupTime(SCIP_BENDERS *benders)
Definition: benders.c:4297
SCIP_RETCODE SCIPprimalSetCutoffbound(SCIP_PRIMAL *primal, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_EVENTQUEUE *eventqueue, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_TREE *tree, SCIP_REOPT *reopt, SCIP_LP *lp, SCIP_Real cutoffbound, SCIP_Bool useforobjlimit)
Definition: primal.c:268
SCIP_EXPORT SCIP_Longint SCIPsepaGetNCutsApplied(SCIP_SEPA *sepa)
Definition: sepa.c:853
void SCIPprintHeuristicStatistics(SCIP *scip, FILE *file)
internal methods for problem variables
data structures and methods for collecting reoptimization information
the function declarations for the synchronization store
#define SCIPallocBufferArray(scip, ptr, num)
Definition: scip_mem.h:111
SCIP_SEPASTORE * sepastore
Definition: struct_scip.h:91
SCIP_Bool SCIPbendersIsActive(SCIP_BENDERS *benders)
Definition: benders.c:1931
SCIP_Real SCIPinfinity(SCIP *scip)
SCIP_Longint nisstoppedcalls
Definition: struct_stat.h:198
SCIP_Real SCIPconshdlrGetEnfoLPTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4697
void SCIPprintRootStatistics(SCIP *scip, FILE *file)
public data structures and miscellaneous methods
SCIP_DIVESET ** SCIPheurGetDivesets(SCIP_HEUR *heur)
Definition: heur.c:1452
void SCIPprintSolutionStatistics(SCIP *scip, FILE *file)
#define SCIP_Bool
Definition: def.h:70
int SCIPconshdlrGetNFixedVars(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4937
int SCIPpropGetNChgBds(SCIP_PROP *prop)
Definition: prop.c:1186
void SCIPsetSortSepasName(SCIP_SET *set)
Definition: set.c:4180
SCIP_Longint ndualresolvelps
Definition: struct_stat.h:186
SCIP_EXPORT int SCIPreoptGetNTotalFeasNodes(SCIP_REOPT *reopt)
Definition: reopt.c:4964
SCIP_CLOCK * sbsoltime
Definition: struct_stat.h:159
SCIP_Longint SCIPgetNPrimalLPs(SCIP *scip)
SCIP_Longint SCIPgetNDualResolveLPs(SCIP *scip)
public methods for storing cuts in a cut pool
SCIP_CLOCK * presolvingtime
Definition: struct_stat.h:146
SCIP_Real SCIPgetDeterministicTime(SCIP *scip)
SCIP_Real SCIPgetAvgPseudocostCurrentRun(SCIP *scip, SCIP_Real solvaldelta)
SCIP_Longint SCIPconflictGetNDualrayInfNonzeros(SCIP_CONFLICT *conflict)
Definition: conflict.c:8683
int nbinvars
Definition: struct_prob.h:62
SCIP_Longint nearlybacktracks
Definition: struct_stat.h:85
int SCIPconshdlrGetNAggrVars(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4947
SCIP_Longint SCIPgetNBacktracks(SCIP *scip)
SCIP_Longint SCIPgetNDivingLPs(SCIP *scip)
public methods for statistics table plugins
internal methods for input file readers
SCIP_Real SCIPgetTransGap(SCIP *scip)
int SCIPpresolGetNChgSides(SCIP_PRESOL *presol)
Definition: presol.c:797
const char * SCIPpresolGetName(SCIP_PRESOL *presol)
Definition: presol.c:589
SCIP_HEUR ** heurs
Definition: struct_set.h:80
SCIP_Longint nrepropcutoffs
Definition: struct_stat.h:91
SCIP_Longint SCIPcomprGetNCalls(SCIP_COMPR *compr)
Definition: compr.c:500
int SCIPgetNActiveBenders(SCIP *scip)
Definition: scip_benders.c:494
public methods for variable pricers
int nreaders
Definition: struct_set.h:97
SCIP_EXPORT SCIP_Real SCIPvarGetAvgBranchdepth(SCIP_VAR *var, SCIP_BRANCHDIR dir)
Definition: var.c:15275
methods for debugging
SCIP_Longint SCIPgetNConflictConssFound(SCIP *scip)
SCIP_Real SCIPbranchruleGetSetupTime(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2070
datastructures for block memory pools and memory buffers
SCIP_BENDERS ** benders
Definition: struct_set.h:92
SCIP_Longint SCIPgetNDualLPs(SCIP *scip)
const char * SCIPpricerGetName(SCIP_PRICER *pricer)
Definition: pricer.c:588
SCIP_RETCODE SCIPupdateCutoffbound(SCIP *scip, SCIP_Real cutoffbound)
SCIP_EXPORT int SCIPreoptGetFirstRestarts(SCIP_REOPT *reopt)
Definition: reopt.c:4934
int SCIPpropGetNAggrVars(SCIP_PROP *prop)
Definition: prop.c:1166
SCIP_Longint SCIPconflictGetNStrongbranchConflictConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:8743
int SCIPgetMaxTotalDepth(SCIP *scip)
SCIP_Real SCIPconshdlrGetPropTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4727
SCIP_RETCODE SCIPprintStatistics(SCIP *scip, FILE *file)
int SCIPsyncstoreGetWinner(SCIP_SYNCSTORE *syncstore)
Definition: syncstore.c:516
SCIP_Longint SCIPgetNResolveLPIterations(SCIP *scip)
int SCIPconshdlrGetNDelConss(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4987
SCIP_Longint nresolveinstablelpiters
Definition: struct_stat.h:72
void SCIPprintConstraintStatistics(SCIP *scip, FILE *file)
void SCIPprintConstraintTimingStatistics(SCIP *scip, FILE *file)
SCIP_Real maxcopytime
Definition: struct_stat.h:128
int SCIPconflictGetNConflicts(SCIP_CONFLICT *conflict)
Definition: conflict.c:3590
SCIP_Real SCIPgetLowerboundRoot(SCIP *scip)
SCIP_Longint SCIPconflictGetNBoundexceedingLPCalls(SCIP_CONFLICT *conflict)
Definition: conflict.c:8339
SCIP_Longint SCIPbranchruleGetNDomredsFound(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2152
SCIP_CLOCK * resolveinstablelptime
Definition: struct_stat.h:152
int SCIPgetNSepaRounds(SCIP *scip)
SCIP_Longint SCIPcomprGetNFound(SCIP_COMPR *compr)
Definition: compr.c:510
datastructures for problem statistics
int SCIPpresolGetNAggrVars(SCIP_PRESOL *presol)
Definition: presol.c:717
SCIP_Longint SCIPhistoryGetNBranchings(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:615
int SCIPconflictstoreGetMaxPoolSize(SCIP_CONFLICTSTORE *conflictstore)
SCIP_Real SCIPcomputeGap(SCIP_Real eps, SCIP_Real inf, SCIP_Real primalbound, SCIP_Real dualbound)
Definition: misc.c:10589
SCIP_EXPORT int SCIPreoptGetLastRestarts(SCIP_REOPT *reopt)
Definition: reopt.c:4944
SCIP_Longint SCIPconflictGetNBoundexceedingLPReconvergenceLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:8389
SCIP_RETCODE SCIPprintTransProblem(SCIP *scip, FILE *file, const char *extension, SCIP_Bool genericnames)
SCIP_CLOCK * relaxsoltime
Definition: struct_stat.h:157
SCIP_Longint SCIPgetNPrimalResolveLPIterations(SCIP *scip)
SCIP_Longint nnz
Definition: struct_stat.h:173
int SCIPgetNCutsFound(SCIP *scip)
helper functions for concurrent scip solvers
SCIP_Real SCIPstatGetPrimalDualIntegral(SCIP_STAT *stat, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob)
Definition: stat.c:493
SCIP_CLOCK * lexduallptime
Definition: struct_stat.h:150
SCIP_EXPORT SCIP_Longint SCIPsepaGetNDomredsFound(SCIP_SEPA *sepa)
Definition: sepa.c:913
SCIP_Longint nnodesbeforefirst
Definition: struct_stat.h:113
SCIP_EXPORT int SCIPvarGetNLocksDownType(SCIP_VAR *var, SCIP_LOCKTYPE locktype)
Definition: var.c:3184
SCIP_Longint SCIPconflictGetNPseudoCalls(SCIP_CONFLICT *conflict)
Definition: conflict.c:8960
SCIP_Longint nrootlpiterations
Definition: struct_stat.h:54
public methods for Benders&#39; decomposition cuts
SCIP_Longint SCIPconflictGetNDualrayBndSuccess(SCIP_CONFLICT *conflict)
Definition: conflict.c:8693
SCIP_RETCODE SCIPprintReoptStatistics(SCIP *scip, FILE *file)
SCIP_Real SCIPhistoryGetCutoffSum(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:654
SCIP_COMPR ** comprs
Definition: struct_set.h:81
datastructures for storing and manipulating the main problem
SCIP_CLOCK * strongbranchtime
Definition: struct_stat.h:154
SCIP_Longint SCIPbranchruleGetNCutoffs(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2120
methods for sorting joint arrays of various types
#define SCIP_LONGINT_FORMAT
Definition: def.h:156
SCIP_Real SCIPbenderscutGetTime(SCIP_BENDERSCUT *benderscut)
Definition: benderscut.c:589
int SCIPdivesetGetNCalls(SCIP_DIVESET *diveset)
Definition: heur.c:388
SCIP_EXPORT SCIP_Real SCIPsolGetTime(SCIP_SOL *sol)
Definition: sol.c:2513
SCIP_Longint SCIPgetNResolveLPs(SCIP *scip)
SCIP_Real firstsolgap
Definition: struct_stat.h:123
int SCIPsepastoreGetNCutsFound(SCIP_SEPASTORE *sepastore)
Definition: sepastore.c:1096
public methods for presolvers
SCIP_Real SCIPconflictGetInfeasibleLPTime(SCIP_CONFLICT *conflict)
Definition: conflict.c:8249
SCIP_Longint SCIPdivesetGetNConflicts(SCIP_DIVESET *diveset)
Definition: heur.c:498
general public methods
#define MAX(x, y)
Definition: def.h:222
SCIP_EXPORT SCIP_Longint SCIPsepaGetNConssFound(SCIP_SEPA *sepa)
Definition: sepa.c:903
int nactiveconss
Definition: struct_stat.h:222
BMS_BLKMEM * probmem
Definition: struct_mem.h:40
SCIP_Real SCIPconcsolverGetSyncTime(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:542
SCIP_Real SCIPheurGetTime(SCIP_HEUR *heur)
Definition: heur.c:1442
SCIP_Longint SCIPconflictGetNBoundexceedingLPSuccess(SCIP_CONFLICT *conflict)
Definition: conflict.c:8349
int SCIPpricestoreGetNVarsFound(SCIP_PRICESTORE *pricestore)
Definition: pricestore.c:654
SCIP_Real SCIPhistoryGetInferenceSum(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:628
SCIP_Longint SCIPgetNLPIterations(SCIP *scip)
int SCIPbendersGetNBenderscuts(SCIP_BENDERS *benders)
Definition: benders.c:4855
SCIP_Longint SCIPconshdlrGetNCheckCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4817
public methods for solutions
internal methods for conflict analysis
SCIP_EXPORT SCIP_Longint SCIPsepaGetNCutoffs(SCIP_SEPA *sepa)
Definition: sepa.c:833
SCIP_Bool SCIPprimalUpperboundIsSol(SCIP_PRIMAL *primal, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob)
Definition: primal.c:545
int SCIPconshdlrGetNChgSides(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:5027
void SCIPsetSortRelaxsName(SCIP_SET *set)
Definition: set.c:4106
SCIP_VERBLEVEL disp_verblevel
Definition: struct_set.h:261
SCIP_Longint SCIPgetNRootStrongbranchLPIterations(SCIP *scip)
int nactivepricers
Definition: struct_set.h:100
void SCIPprintOrigProblemStatistics(SCIP *scip, FILE *file)
SCIP_Real SCIPgetLowerbound(SCIP *scip)
SCIP_Real SCIPgetFirstLPLowerboundRoot(SCIP *scip)
SCIP_Real SCIPbranchruleGetTime(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2080
SCIP_CLOCK * solvingtime
Definition: struct_stat.h:144
SCIP_Longint nbarrierlps
Definition: struct_stat.h:183
public methods for tree compressions
SCIP_Longint nprimalzeroitlps
Definition: struct_stat.h:179
SCIP_Real SCIPgetAvgPseudocostCount(SCIP *scip, SCIP_BRANCHDIR dir)
SCIP_CLOCK * primallptime
Definition: struct_stat.h:148
int conf_maxstoresize
Definition: struct_set.h:197
SCIP_EXPORT SCIP_Longint SCIPsolGetNodenum(SCIP_SOL *sol)
Definition: sol.c:2533
void SCIPprintPricerStatistics(SCIP *scip, FILE *file)
SCIP_SET * set
Definition: struct_scip.h:62
SCIP_Longint npsbestsolsfound
Definition: struct_stat.h:98
SCIP_PROP ** props
Definition: struct_set.h:78
public methods for message output
SCIP_Longint SCIPconshdlrGetNConssFound(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4887
SCIP_Longint SCIPgetNRootLPIterations(SCIP *scip)
int SCIPpresolGetNChgCoefs(SCIP_PRESOL *presol)
Definition: presol.c:787
SCIP_Real upperbound
Definition: struct_primal.h:45
SCIP_EXPORT int SCIPreoptGetNTotalInfNodes(SCIP_REOPT *reopt)
Definition: reopt.c:5024
int SCIPsnprintf(char *t, int len, const char *s,...)
Definition: misc.c:10263
void SCIPmessageFPrintInfo(SCIP_MESSAGEHDLR *messagehdlr, FILE *file, const char *formatstr,...)
Definition: message.c:608
SCIP_Longint SCIPgetNPrimalResolveLPs(SCIP *scip)
int ncomprs
Definition: struct_set.h:116
SCIP_Real SCIPpricerGetTime(SCIP_PRICER *pricer)
Definition: pricer.c:662
SCIP_Longint SCIPconshdlrGetNPropCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4807
SCIP_MESSAGEHDLR * messagehdlr
Definition: struct_scip.h:65
SCIP_EXPORT const char * SCIPrelaxGetName(SCIP_RELAX *relax)
Definition: relax.c:480
int SCIPdivesetGetMinDepth(SCIP_DIVESET *diveset)
Definition: heur.c:408
#define SCIP_Real
Definition: def.h:164
int SCIPpresolGetNChgBds(SCIP_PRESOL *presol)
Definition: presol.c:737
internal methods for problem statistics
SCIP_VAR ** vars
Definition: struct_prob.h:55
void SCIPstatUpdatePrimalDualIntegral(SCIP_STAT *stat, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_Real upperbound, SCIP_Real lowerbound)
Definition: stat.c:402
SCIP_PRICER ** pricers
Definition: struct_set.h:69
public methods for relaxation handlers
int SCIPgetVarNStrongbranchs(SCIP *scip, SCIP_VAR *var)
Definition: scip_var.c:4167
SCIP_Real firstprimaltime
Definition: struct_stat.h:122
public methods for input file readers
int SCIPpropGetNChgCoefs(SCIP_PROP *prop)
Definition: prop.c:1236
SCIP_Longint SCIPbranchruleGetNPseudoCalls(SCIP_BRANCHRULE *branchrule)
Definition: branch.c:2110
SCIP_Longint SCIPconcsolverGetNTighterBnds(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:592
SCIP_Real SCIPretransformObj(SCIP *scip, SCIP_Real obj)
Definition: scip_sol.c:1567
SCIP_Longint nrepropboundchgs
Definition: struct_stat.h:90
SCIP_Longint SCIPconflictGetNStrongbranchCalls(SCIP_CONFLICT *conflict)
Definition: conflict.c:8723
SCIP_Longint SCIPconflictGetNInfeasibleLPIterations(SCIP_CONFLICT *conflict)
Definition: conflict.c:8319
int SCIPsepastoreGetNCutsFoundRound(SCIP_SEPASTORE *sepastore)
Definition: sepastore.c:1106
SCIP_Real SCIPgetAvgPseudocost(SCIP *scip, SCIP_Real solvaldelta)
SCIP_NLP * nlp
Definition: struct_scip.h:81
SCIP_Real firstprimalbound
Definition: struct_stat.h:121
datastructures for collecting primal CIP solutions and primal informations
public methods for message handling
SCIP_Longint ntotalinternalnodes
Definition: struct_stat.h:79
SCIP_Longint SCIPconshdlrGetNCutoffs(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4837
SCIP_Real SCIPgetAvgCutoffsCurrentRun(SCIP *scip, SCIP_BRANCHDIR dir)
SCIP_Real SCIPheurGetSetupTime(SCIP_HEUR *heur)
Definition: heur.c:1432
#define SCIP_INVALID
Definition: def.h:184
SCIP_Real SCIPgetPrimalbound(SCIP *scip)
SCIP_Longint SCIPconshdlrGetNDomredsFound(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4897
SCIP_Longint SCIPconflictGetNAppliedGlobalLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:3640
SCIP_CLOCK * duallptime
Definition: struct_stat.h:149
int SCIPpresolGetNAddHoles(SCIP_PRESOL *presol)
Definition: presol.c:747
SCIP_Real SCIPconshdlrGetEnfoPSTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4707
SCIP_Real SCIPgetAvgPseudocostScoreCurrentRun(SCIP *scip)
SCIP_Longint SCIPgetNNodeInitLPs(SCIP *scip)
SCIP_CLOCK * reoptupdatetime
Definition: struct_stat.h:164
#define SCIP_Longint
Definition: def.h:149
const char * SCIPconshdlrGetName(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4191
int SCIPdivesetGetMaxDepth(SCIP_DIVESET *diveset)
Definition: heur.c:418
SCIP_Longint nactivatednodes
Definition: struct_stat.h:83
SCIP_Longint nprimallpiterations
Definition: struct_stat.h:56
SCIP_Real SCIPvarGetAvgCutoffs(SCIP_VAR *var, SCIP_STAT *stat, SCIP_BRANCHDIR dir)
Definition: var.c:15753
SCIP_Longint nreprops
Definition: struct_stat.h:89
SCIP_Longint SCIPcutpoolGetNCalls(SCIP_CUTPOOL *cutpool)
Definition: cutpool.c:1080
SCIP_Longint nsbsolsfound
Definition: struct_stat.h:95
SCIP_TREE * tree
Definition: struct_scip.h:84
SCIP_Real SCIPconshdlrGetCheckTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4747
int SCIPconshdlrGetNChgCoefs(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:5017
SCIP_Longint SCIPconcsolverGetNLPIterations(SCIP_CONCSOLVER *concsolver)
Definition: concsolver.c:552
SCIP_CLOCK * nodeactivationtime
Definition: struct_stat.h:160
SCIP_Real SCIPgetAvgDualbound(SCIP *scip)
SCIP_Longint ndualzeroitlps
Definition: struct_stat.h:181
int SCIPgetNPricevars(SCIP *scip)
SCIP_Real SCIPsetEpsilon(SCIP_SET *set)
Definition: set.c:5835
SCIP_Real SCIPhistoryGetAvgInferences(SCIP_HISTORY *history, SCIP_BRANCHDIR dir)
Definition: history.c:641
SCIP_Longint SCIPgetNBestSolsFound(SCIP *scip)
SCIP_Longint SCIPconflictGetNAppliedConss(SCIP_CONFLICT *conflict)
Definition: conflict.c:3600
void SCIPprintNLPStatistics(SCIP *scip, FILE *file)
SCIP_Longint ninternalnodes
Definition: struct_stat.h:74
SCIP_Real SCIPprobExternObjval(SCIP_PROB *transprob, SCIP_PROB *origprob, SCIP_SET *set, SCIP_Real objval)
Definition: prob.c:2074
#define nnodes
Definition: gastrans.c:65
SCIP_Longint SCIPconflictGetNBoundexceedingLPConflictLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:8369
SCIP_Real SCIPtreeGetLowerbound(SCIP_TREE *tree, SCIP_SET *set)
Definition: tree.c:7160
SCIP_Real SCIPgetAvgCutoffs(SCIP *scip, SCIP_BRANCHDIR dir)
SCIP_Real SCIPgetAvgCutoffScore(SCIP *scip)
int nconshdlrs
Definition: struct_set.h:102
SCIP_Longint SCIPconflictGetNPropReconvergenceLiterals(SCIP_CONFLICT *conflict)
Definition: conflict.c:5615
public methods for separators
void SCIPprintTreeStatistics(SCIP *scip, FILE *file)
const char * SCIPbendersGetName(SCIP_BENDERS *benders)
Definition: benders.c:4211
SCIP_Longint nnodelps
Definition: struct_stat.h:188
public methods for primal heuristics
SCIP_Real SCIPconflictGetPropTime(SCIP_CONFLICT *conflict)
Definition: conflict.c:5555
SCIP_Longint nnodes
Definition: struct_stat.h:73
SCIP_Bool misc_calcintegral
Definition: struct_set.h:371
SCIP_EXPORT SCIP_Longint SCIPsepaGetNCalls(SCIP_SEPA *sepa)
Definition: sepa.c:813
SCIP_CONCSOLVER ** SCIPgetConcurrentSolvers(SCIP *scip)
Definition: concurrent.c:118
int SCIPconshdlrGetNChgVarTypes(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4957
int SCIPgetNImplications(SCIP *scip)
int SCIPgetNTables(SCIP *scip)
Definition: scip_table.c:108
#define SCIP_CALL_ABORT(x)
Definition: def.h:344
void SCIPprintTimingStatistics(SCIP *scip, FILE *file)
SCIP_STAGE SCIPgetStage(SCIP *scip)
Definition: scip_general.c:355
SCIP_Longint SCIPdivesetGetNBacktracks(SCIP_DIVESET *diveset)
Definition: heur.c:488
int SCIPconshdlrGetNPresolCalls(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:5037
SCIP_Longint nrelaxsolsfound
Definition: struct_stat.h:93
int npresols
Definition: struct_set.h:106
SCIP_LP * lp
Definition: struct_scip.h:80
int firstprimaldepth
Definition: struct_stat.h:255
SCIP_BENDERSCUT ** SCIPbendersGetBenderscuts(SCIP_BENDERS *benders)
Definition: benders.c:4838
SCIP_Longint SCIPgetNBarrierLPIterations(SCIP *scip)
int SCIPtreeGetNNodes(SCIP_TREE *tree)
Definition: tree.c:8162
int SCIPbendersGetNCalls(SCIP_BENDERS *benders)
Definition: benders.c:4277
static SCIP_RETCODE printProblem(SCIP *scip, SCIP_PROB *prob, FILE *file, const char *extension, SCIP_Bool genericnames)
SCIP_Real SCIPgetDualbound(SCIP *scip)
SCIP_Real SCIPgetAvgInferenceScoreCurrentRun(SCIP *scip)
SCIP_Real SCIPreoptGetSavingtime(SCIP_REOPT *reopt)
Definition: reopt.c:7601
SCIP_Longint nlimsolsfound
Definition: struct_primal.h:40
datastructures for global SCIP settings
SCIP_Real SCIPconshdlrGetRespropTime(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4757
SCIP_Real SCIPgetAvgConflictlengthScore(SCIP *scip)
void SCIPprintBendersStatistics(SCIP *scip, FILE *file)
SCIP_Longint SCIPpropGetNCutoffs(SCIP_PROP *prop)
Definition: prop.c:1106
int SCIPpricerGetNCalls(SCIP_PRICER *pricer)
Definition: pricer.c:632
int SCIPpropGetNDelConss(SCIP_PROP *prop)
Definition: prop.c:1206
SCIP_Real SCIPgetAvgConflictScore(SCIP *scip)
SCIP_Longint SCIPgetNConflictConssApplied(SCIP *scip)
SCIP_Longint ninitlps
Definition: struct_stat.h:189
SCIP_Longint SCIPconshdlrGetNCutsApplied(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4857
int SCIPreoptGetNTotalRestartsLocal(SCIP_REOPT *reopt)
Definition: reopt.c:4924
void SCIPprintStatusStatistics(SCIP *scip, FILE *file)
SCIP_Real SCIPvarGetPseudocostVariance(SCIP_VAR *var, SCIP_BRANCHDIR dir, SCIP_Bool onlycurrentrun)
Definition: var.c:14180
SCIP_Longint ndelayedcutoffs
Definition: struct_stat.h:88
void SCIPsetSortBranchrulesName(SCIP_SET *set)
Definition: set.c:4757
SCIP_CLOCK * lpsoltime
Definition: struct_stat.h:156
public methods for propagators
void SCIPprintRelaxatorStatistics(SCIP *scip, FILE *file)
SCIP_Longint SCIPconshdlrGetNCutsFound(SCIP_CONSHDLR *conshdlr)
Definition: cons.c:4847
internal methods for displaying runtime statistics
int SCIPgetNPricevarsFound(SCIP *scip)
int nimplications
Definition: struct_stat.h:224
void SCIPsetSortPricersName(SCIP_SET *set)
Definition: set.c:3653
SCIP_Longint SCIPgetNInfeasibleLeaves(SCIP *scip)
int SCIPgetNRuns(SCIP *scip)
SCIP_Longint ndivinglpiterations
Definition: struct_stat.h:65
int SCIPpricestoreGetNProbPricings(SCIP_PRICESTORE *pricestore)
Definition: pricestore.c:634
memory allocation routines
SCIP_Real SCIPgetDualboundRoot(SCIP *scip)