Scippy

SCIP

Solving Constraint Integer Programs

scip_sol.h
Go to the documentation of this file.
1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
2 /* */
3 /* This file is part of the program and library */
4 /* SCIP --- Solving Constraint Integer Programs */
5 /* */
6 /* Copyright (C) 2002-2018 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_sol.h
17  * @ingroup PUBLICCOREAPI
18  * @brief public methods for solutions
19  * @author Tobias Achterberg
20  * @author Timo Berthold
21  * @author Thorsten Koch
22  * @author Alexander Martin
23  * @author Marc Pfetsch
24  * @author Kati Wolter
25  * @author Gregor Hendel
26  * @author Robert Lion Gottwald
27  */
28 
29 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
30 
31 #ifndef __SCIP_SCIP_SOL_H__
32 #define __SCIP_SCIP_SOL_H__
33 
34 
35 #include "scip/def.h"
36 #include "scip/type_cons.h"
37 #include "scip/type_heur.h"
38 #include "scip/type_retcode.h"
39 #include "scip/type_scip.h"
40 #include "scip/type_sol.h"
41 #include "scip/type_var.h"
42 
43 /* In debug mode, we include the SCIP's structure in scip.c, such that no one can access
44  * this structure except the interface methods in scip.c.
45  * In optimized mode, the structure is included in scip.h, because some of the methods
46  * are implemented as defines for performance reasons (e.g. the numerical comparisons).
47  * Additionally, the internal "set.h" is included, such that the defines in set.h are
48  * available in optimized mode.
49  */
50 #ifdef NDEBUG
51 #include "scip/struct_scip.h"
52 #include "scip/struct_stat.h"
53 #include "scip/set.h"
54 #include "scip/tree.h"
55 #include "scip/misc.h"
56 #include "scip/var.h"
57 #include "scip/cons.h"
58 #include "scip/solve.h"
59 #include "scip/debug.h"
60 #endif
61 
62 #ifdef __cplusplus
63 extern "C" {
64 #endif
65 
66 /**@addtogroup PublicSolutionMethods
67  *
68  * @{
69  */
70 
71 /** creates a primal solution, initialized to zero
72  *
73  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
74  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
75  *
76  * @pre This method can be called if SCIP is in one of the following stages:
77  * - \ref SCIP_STAGE_PROBLEM
78  * - \ref SCIP_STAGE_TRANSFORMING
79  * - \ref SCIP_STAGE_TRANSFORMED
80  * - \ref SCIP_STAGE_INITPRESOLVE
81  * - \ref SCIP_STAGE_PRESOLVING
82  * - \ref SCIP_STAGE_EXITPRESOLVE
83  * - \ref SCIP_STAGE_PRESOLVED
84  * - \ref SCIP_STAGE_INITSOLVE
85  * - \ref SCIP_STAGE_SOLVING
86  */
87 extern
89  SCIP* scip, /**< SCIP data structure */
90  SCIP_SOL** sol, /**< pointer to store the solution */
91  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
92  );
93 
94 /** creates a primal solution, initialized to the current LP solution
95  *
96  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
97  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
98  *
99  * @pre This method can be called if SCIP is in one of the following stages:
100  * - \ref SCIP_STAGE_SOLVING
101  */
102 extern
104  SCIP* scip, /**< SCIP data structure */
105  SCIP_SOL** sol, /**< pointer to store the solution */
106  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
107  );
108 
109 /** creates a primal solution, initialized to the current NLP solution
110  *
111  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
112  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
113  *
114  * @pre This method can be called if SCIP is in one of the following stages:
115  * - \ref SCIP_STAGE_SOLVING
116  */
117 extern
119  SCIP* scip, /**< SCIP data structure */
120  SCIP_SOL** sol, /**< pointer to store the solution */
121  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
122  );
123 
124 /** creates a primal solution, initialized to the current relaxation solution
125  *
126  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
127  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
128  *
129  * @pre This method can be called if SCIP is in one of the following stages:
130  * - \ref SCIP_STAGE_SOLVING
131  */
132 extern
134  SCIP* scip, /**< SCIP data structure */
135  SCIP_SOL** sol, /**< pointer to store the solution */
136  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
137  );
138 
139 /** creates a primal solution, initialized to the current pseudo solution
140  *
141  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
142  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
143  *
144  * @pre This method can be called if SCIP is in one of the following stages:
145  * - \ref SCIP_STAGE_SOLVING
146  */
147 extern
149  SCIP* scip, /**< SCIP data structure */
150  SCIP_SOL** sol, /**< pointer to store the solution */
151  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
152  );
153 
154 /** creates a primal solution, initialized to the current LP or pseudo solution, depending on whether the LP was solved
155  * at the current node
156  *
157  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
158  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
159  *
160  * @pre This method can be called if SCIP is in one of the following stages:
161  * - \ref SCIP_STAGE_SOLVING
162  */
163 extern
165  SCIP* scip, /**< SCIP data structure */
166  SCIP_SOL** sol, /**< pointer to store the solution */
167  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
168  );
169 
170 /** creates a partial primal solution, initialized to unknown values
171  *
172  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
173  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
174  *
175  * @pre This method can be called if SCIP is in one of the following stages:
176  * - \ref SCIP_STAGE_PROBLEM
177  */
178 extern
180  SCIP* scip, /**< SCIP data structure */
181  SCIP_SOL** sol, /**< pointer to store the solution */
182  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
183  );
184 
185 /** creates a primal solution, initialized to unknown values
186  *
187  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
188  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
189  *
190  * @pre This method can be called if SCIP is in one of the following stages:
191  * - \ref SCIP_STAGE_TRANSFORMING
192  * - \ref SCIP_STAGE_TRANSFORMED
193  * - \ref SCIP_STAGE_INITPRESOLVE
194  * - \ref SCIP_STAGE_PRESOLVING
195  * - \ref SCIP_STAGE_EXITPRESOLVE
196  * - \ref SCIP_STAGE_PRESOLVED
197  * - \ref SCIP_STAGE_INITSOLVE
198  * - \ref SCIP_STAGE_SOLVING
199  */
200 extern
202  SCIP* scip, /**< SCIP data structure */
203  SCIP_SOL** sol, /**< pointer to store the solution */
204  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
205  );
206 
207 /** creates a primal solution living in the original problem space, initialized to zero;
208  * a solution in original space allows to set original variables to values that would be invalid in the
209  * transformed problem due to preprocessing fixings or aggregations
210  *
211  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
212  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
213  *
214  * @pre This method can be called if SCIP is in one of the following stages:
215  * - \ref SCIP_STAGE_PROBLEM
216  * - \ref SCIP_STAGE_TRANSFORMING
217  * - \ref SCIP_STAGE_TRANSFORMED
218  * - \ref SCIP_STAGE_INITPRESOLVE
219  * - \ref SCIP_STAGE_PRESOLVING
220  * - \ref SCIP_STAGE_EXITPRESOLVE
221  * - \ref SCIP_STAGE_PRESOLVED
222  * - \ref SCIP_STAGE_INITSOLVE
223  * - \ref SCIP_STAGE_SOLVING
224  */
225 extern
227  SCIP* scip, /**< SCIP data structure */
228  SCIP_SOL** sol, /**< pointer to store the solution */
229  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
230  );
231 
232 /** creates a copy of a primal solution; note that a copy of a linked solution is also linked and needs to be unlinked
233  * if it should stay unaffected from changes in the LP or pseudo solution
234  *
235  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
236  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
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  */
249 extern
251  SCIP* scip, /**< SCIP data structure */
252  SCIP_SOL** sol, /**< pointer to store the solution */
253  SCIP_SOL* sourcesol /**< primal CIP solution to copy */
254  );
255 
256 /** creates a copy of a solution in the original primal solution space
257  *
258  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
259  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
260  *
261  * @pre This method can be called if SCIP is in one of the following stages:
262  * - \ref SCIP_STAGE_PROBLEM
263  * - \ref SCIP_STAGE_TRANSFORMING
264  * - \ref SCIP_STAGE_TRANSFORMED
265  * - \ref SCIP_STAGE_INITPRESOLVE
266  * - \ref SCIP_STAGE_PRESOLVING
267  * - \ref SCIP_STAGE_EXITPRESOLVE
268  * - \ref SCIP_STAGE_PRESOLVED
269  * - \ref SCIP_STAGE_INITSOLVE
270  * - \ref SCIP_STAGE_SOLVING
271  * - \ref SCIP_STAGE_SOLVED
272  * - \ref SCIP_STAGE_EXITSOLVE
273  * - \ref SCIP_STAGE_FREETRANS
274  */
275 extern
277  SCIP* scip, /**< SCIP data structure */
278  SCIP_SOL** sol, /**< pointer to store the solution */
279  SCIP_SOL* sourcesol /**< primal CIP solution to copy */
280  );
281 
282 /** creates a copy of a primal solution, thereby replacing infinite fixings of variables by finite values;
283  * the copy is always defined in the original variable space;
284  * success indicates whether the objective value of the solution was changed by removing infinite values
285  *
286  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
287  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
288  *
289  * @pre This method can be called if SCIP is in one of the following stages:
290  * - \ref SCIP_STAGE_PROBLEM
291  * - \ref SCIP_STAGE_TRANSFORMING
292  * - \ref SCIP_STAGE_TRANSFORMED
293  * - \ref SCIP_STAGE_INITPRESOLVE
294  * - \ref SCIP_STAGE_PRESOLVING
295  * - \ref SCIP_STAGE_EXITPRESOLVE
296  * - \ref SCIP_STAGE_PRESOLVED
297  * - \ref SCIP_STAGE_INITSOLVE
298  * - \ref SCIP_STAGE_SOLVING
299  * - \ref SCIP_STAGE_SOLVED
300  * - \ref SCIP_STAGE_EXITSOLVE
301  */
302 extern
304  SCIP* scip, /**< SCIP data structure */
305  SCIP_SOL** sol, /**< pointer to store the solution */
306  SCIP_SOL* sourcesol, /**< primal CIP solution to copy */
307  SCIP_Bool* success /**< does the finite solution have the same objective value? */
308  );
309 
310 /** frees primal CIP solution
311  *
312  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
313  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
314  *
315  * @pre This method can be called if SCIP is in one of the following stages:
316  * - \ref SCIP_STAGE_PROBLEM
317  * - \ref SCIP_STAGE_TRANSFORMING
318  * - \ref SCIP_STAGE_TRANSFORMED
319  * - \ref SCIP_STAGE_INITPRESOLVE
320  * - \ref SCIP_STAGE_PRESOLVING
321  * - \ref SCIP_STAGE_EXITPRESOLVE
322  * - \ref SCIP_STAGE_PRESOLVED
323  * - \ref SCIP_STAGE_INITSOLVE
324  * - \ref SCIP_STAGE_SOLVING
325  * - \ref SCIP_STAGE_SOLVED
326  * - \ref SCIP_STAGE_EXITSOLVE
327  * - \ref SCIP_STAGE_FREETRANS
328  */
329 extern
331  SCIP* scip, /**< SCIP data structure */
332  SCIP_SOL** sol /**< pointer to the solution */
333  );
334 
335 /** links a primal solution to the current LP solution
336  *
337  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
338  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
339  *
340  * @pre This method can be called if SCIP is in one of the following stages:
341  * - \ref SCIP_STAGE_SOLVING
342  */
343 extern
345  SCIP* scip, /**< SCIP data structure */
346  SCIP_SOL* sol /**< primal solution */
347  );
348 
349 /** links a primal solution to the current NLP solution
350  *
351  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
352  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
353  *
354  * @pre This method can be called if SCIP is in one of the following stages:
355  * - \ref SCIP_STAGE_SOLVING
356  */
357 extern
359  SCIP* scip, /**< SCIP data structure */
360  SCIP_SOL* sol /**< primal solution */
361  );
362 
363 /** links a primal solution to the current relaxation solution
364  *
365  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
366  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
367  *
368  * @pre This method can be called if SCIP is in one of the following stages:
369  * - \ref SCIP_STAGE_SOLVING
370  */
371 extern
373  SCIP* scip, /**< SCIP data structure */
374  SCIP_SOL* sol /**< primal solution */
375  );
376 
377 /** links a primal solution to the current pseudo solution
378  *
379  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
380  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
381  *
382  * @pre This method can be called if SCIP is in one of the following stages:
383  * - \ref SCIP_STAGE_PRESOLVING
384  * - \ref SCIP_STAGE_SOLVING
385  */
386 extern
388  SCIP* scip, /**< SCIP data structure */
389  SCIP_SOL* sol /**< primal solution */
390  );
391 
392 /** links a primal solution to the current LP or pseudo solution
393  *
394  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
395  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
396  *
397  * @pre This method can be called if SCIP is in one of the following stages:
398  * - \ref SCIP_STAGE_SOLVING
399  */
400 extern
402  SCIP* scip, /**< SCIP data structure */
403  SCIP_SOL* sol /**< primal solution */
404  );
405 
406 /** clears a primal solution
407  *
408  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
409  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
410  *
411  * @pre This method can be called if SCIP is in one of the following stages:
412  * - \ref SCIP_STAGE_PROBLEM
413  * - \ref SCIP_STAGE_TRANSFORMING
414  * - \ref SCIP_STAGE_TRANSFORMED
415  * - \ref SCIP_STAGE_INITPRESOLVE
416  * - \ref SCIP_STAGE_PRESOLVING
417  * - \ref SCIP_STAGE_EXITPRESOLVE
418  * - \ref SCIP_STAGE_PRESOLVED
419  * - \ref SCIP_STAGE_INITSOLVE
420  * - \ref SCIP_STAGE_SOLVING
421  * - \ref SCIP_STAGE_SOLVED
422  * - \ref SCIP_STAGE_EXITSOLVE
423  * - \ref SCIP_STAGE_FREETRANS
424  */
425 extern
427  SCIP* scip, /**< SCIP data structure */
428  SCIP_SOL* sol /**< primal solution */
429  );
430 
431 /** stores solution values of variables in solution's own array
432  *
433  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
434  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
435  *
436  * @pre This method can be called if SCIP is in one of the following stages:
437  * - \ref SCIP_STAGE_TRANSFORMING
438  * - \ref SCIP_STAGE_TRANSFORMED
439  * - \ref SCIP_STAGE_PRESOLVING
440  * - \ref SCIP_STAGE_PRESOLVED
441  * - \ref SCIP_STAGE_INITSOLVE
442  * - \ref SCIP_STAGE_SOLVING
443  * - \ref SCIP_STAGE_SOLVED
444  * - \ref SCIP_STAGE_EXITSOLVE
445  * - \ref SCIP_STAGE_FREETRANS
446  */
447 extern
449  SCIP* scip, /**< SCIP data structure */
450  SCIP_SOL* sol /**< primal solution */
451  );
452 
453 /** sets value of variable in primal CIP solution
454  *
455  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
456  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
457  *
458  * @pre This method can be called if SCIP is in one of the following stages:
459  * - \ref SCIP_STAGE_PROBLEM
460  * - \ref SCIP_STAGE_TRANSFORMING
461  * - \ref SCIP_STAGE_TRANSFORMED
462  * - \ref SCIP_STAGE_INITPRESOLVE
463  * - \ref SCIP_STAGE_PRESOLVING
464  * - \ref SCIP_STAGE_EXITPRESOLVE
465  * - \ref SCIP_STAGE_PRESOLVED
466  * - \ref SCIP_STAGE_INITSOLVE
467  * - \ref SCIP_STAGE_SOLVING
468  * - \ref SCIP_STAGE_SOLVED
469  * - \ref SCIP_STAGE_EXITSOLVE
470  * - \ref SCIP_STAGE_FREETRANS
471  */
472 extern
474  SCIP* scip, /**< SCIP data structure */
475  SCIP_SOL* sol, /**< primal solution */
476  SCIP_VAR* var, /**< variable to add to solution */
477  SCIP_Real val /**< solution value of variable */
478  );
479 
480 /** sets values of multiple variables in primal CIP solution
481  *
482  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
483  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
484  *
485  * @pre This method can be called if SCIP is in one of the following stages:
486  * - \ref SCIP_STAGE_PROBLEM
487  * - \ref SCIP_STAGE_TRANSFORMING
488  * - \ref SCIP_STAGE_TRANSFORMED
489  * - \ref SCIP_STAGE_INITPRESOLVE
490  * - \ref SCIP_STAGE_PRESOLVING
491  * - \ref SCIP_STAGE_EXITPRESOLVE
492  * - \ref SCIP_STAGE_PRESOLVED
493  * - \ref SCIP_STAGE_INITSOLVE
494  * - \ref SCIP_STAGE_SOLVING
495  * - \ref SCIP_STAGE_SOLVED
496  * - \ref SCIP_STAGE_EXITSOLVE
497  * - \ref SCIP_STAGE_FREETRANS
498  */
499 extern
501  SCIP* scip, /**< SCIP data structure */
502  SCIP_SOL* sol, /**< primal solution */
503  int nvars, /**< number of variables to set solution value for */
504  SCIP_VAR** vars, /**< array with variables to add to solution */
505  SCIP_Real* vals /**< array with solution values of variables */
506  );
507 
508 /** increases value of variable in primal CIP solution
509  *
510  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
511  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
512  *
513  * @pre This method can be called if SCIP is in one of the following stages:
514  * - \ref SCIP_STAGE_PROBLEM
515  * - \ref SCIP_STAGE_TRANSFORMING
516  * - \ref SCIP_STAGE_TRANSFORMED
517  * - \ref SCIP_STAGE_INITPRESOLVE
518  * - \ref SCIP_STAGE_PRESOLVING
519  * - \ref SCIP_STAGE_EXITPRESOLVE
520  * - \ref SCIP_STAGE_PRESOLVED
521  * - \ref SCIP_STAGE_INITSOLVE
522  * - \ref SCIP_STAGE_SOLVING
523  * - \ref SCIP_STAGE_SOLVED
524  * - \ref SCIP_STAGE_EXITSOLVE
525  * - \ref SCIP_STAGE_FREETRANS
526  */
527 extern
529  SCIP* scip, /**< SCIP data structure */
530  SCIP_SOL* sol, /**< primal solution */
531  SCIP_VAR* var, /**< variable to increase solution value for */
532  SCIP_Real incval /**< increment for solution value of variable */
533  );
534 
535 /** returns value of variable in primal CIP solution, or in current LP/pseudo solution
536  *
537  * @return value of variable in primal CIP solution, or in current LP/pseudo solution
538  *
539  * @pre In case the solution pointer @p sol is @b NULL, that means it is asked for the LP or pseudo solution, this method
540  * can only be called if @p scip is in the solving stage \ref SCIP_STAGE_SOLVING. In any other case, this method
541  * can be called if @p scip is in one of the following stages:
542  * - \ref SCIP_STAGE_PROBLEM
543  * - \ref SCIP_STAGE_TRANSFORMING
544  * - \ref SCIP_STAGE_TRANSFORMED
545  * - \ref SCIP_STAGE_INITPRESOLVE
546  * - \ref SCIP_STAGE_PRESOLVING
547  * - \ref SCIP_STAGE_EXITPRESOLVE
548  * - \ref SCIP_STAGE_PRESOLVED
549  * - \ref SCIP_STAGE_INITSOLVE
550  * - \ref SCIP_STAGE_SOLVING
551  * - \ref SCIP_STAGE_SOLVED
552  * - \ref SCIP_STAGE_EXITSOLVE
553  * - \ref SCIP_STAGE_FREETRANS
554  */
555 extern
557  SCIP* scip, /**< SCIP data structure */
558  SCIP_SOL* sol, /**< primal solution, or NULL for current LP/pseudo solution */
559  SCIP_VAR* var /**< variable to get value for */
560  );
561 
562 /** gets values of multiple variables in primal CIP solution
563  *
564  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
565  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
566  *
567  * @pre This method can be called if SCIP is in one of the following stages:
568  * - \ref SCIP_STAGE_PROBLEM
569  * - \ref SCIP_STAGE_TRANSFORMING
570  * - \ref SCIP_STAGE_TRANSFORMED
571  * - \ref SCIP_STAGE_INITPRESOLVE
572  * - \ref SCIP_STAGE_PRESOLVING
573  * - \ref SCIP_STAGE_EXITPRESOLVE
574  * - \ref SCIP_STAGE_PRESOLVED
575  * - \ref SCIP_STAGE_INITSOLVE
576  * - \ref SCIP_STAGE_SOLVING
577  * - \ref SCIP_STAGE_SOLVED
578  * - \ref SCIP_STAGE_EXITSOLVE
579  * - \ref SCIP_STAGE_FREETRANS
580  */
581 extern
583  SCIP* scip, /**< SCIP data structure */
584  SCIP_SOL* sol, /**< primal solution, or NULL for current LP/pseudo solution */
585  int nvars, /**< number of variables to get solution value for */
586  SCIP_VAR** vars, /**< array with variables to get value for */
587  SCIP_Real* vals /**< array to store solution values of variables */
588  );
589 
590 /** returns objective value of primal CIP solution w.r.t. original problem, or current LP/pseudo objective value
591  *
592  * @return objective value of primal CIP solution w.r.t. original problem, or current LP/pseudo objective value
593  *
594  * @pre This method can be called if SCIP is in one of the following stages:
595  * - \ref SCIP_STAGE_PROBLEM
596  * - \ref SCIP_STAGE_TRANSFORMING
597  * - \ref SCIP_STAGE_TRANSFORMED
598  * - \ref SCIP_STAGE_INITPRESOLVE
599  * - \ref SCIP_STAGE_PRESOLVING
600  * - \ref SCIP_STAGE_EXITPRESOLVE
601  * - \ref SCIP_STAGE_PRESOLVED
602  * - \ref SCIP_STAGE_INITSOLVE
603  * - \ref SCIP_STAGE_SOLVING
604  * - \ref SCIP_STAGE_SOLVED
605  * - \ref SCIP_STAGE_EXITSOLVE
606  * - \ref SCIP_STAGE_FREETRANS
607  */
608 extern
610  SCIP* scip, /**< SCIP data structure */
611  SCIP_SOL* sol /**< primal solution, or NULL for current LP/pseudo objective value */
612  );
613 
614 /** returns transformed objective value of primal CIP solution, or transformed current LP/pseudo objective value
615  *
616  * @return transformed objective value of primal CIP solution, or transformed current LP/pseudo objective value
617  *
618  * @pre This method can be called if SCIP is in one of the following stages:
619  * - \ref SCIP_STAGE_TRANSFORMING
620  * - \ref SCIP_STAGE_TRANSFORMED
621  * - \ref SCIP_STAGE_INITPRESOLVE
622  * - \ref SCIP_STAGE_PRESOLVING
623  * - \ref SCIP_STAGE_EXITPRESOLVE
624  * - \ref SCIP_STAGE_PRESOLVED
625  * - \ref SCIP_STAGE_INITSOLVE
626  * - \ref SCIP_STAGE_SOLVING
627  * - \ref SCIP_STAGE_SOLVED
628  * - \ref SCIP_STAGE_EXITSOLVE
629  * - \ref SCIP_STAGE_FREETRANS
630  */
631 extern
633  SCIP* scip, /**< SCIP data structure */
634  SCIP_SOL* sol /**< primal solution, or NULL for current LP/pseudo objective value */
635  );
636 
637 /** recomputes the objective value of an original solution, e.g., when transferring solutions
638  * from the solution pool (objective coefficients might have changed in the meantime)
639  *
640  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
641  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
642  *
643  * @pre This method can be called if SCIP is in one of the following stages:
644  * - \ref SCIP_STAGE_PRESOLVING
645  * - \ref SCIP_STAGE_SOLVING
646  *
647  */
648 extern
650  SCIP* scip,
651  SCIP_SOL* sol
652  );
653 
654 /** maps original space objective value into transformed objective value
655  *
656  * @return transformed objective value
657  *
658  * @pre This method can be called if SCIP is in one of the following stages:
659  * - \ref SCIP_STAGE_TRANSFORMING
660  * - \ref SCIP_STAGE_TRANSFORMED
661  * - \ref SCIP_STAGE_INITPRESOLVE
662  * - \ref SCIP_STAGE_PRESOLVING
663  * - \ref SCIP_STAGE_EXITPRESOLVE
664  * - \ref SCIP_STAGE_PRESOLVED
665  * - \ref SCIP_STAGE_INITSOLVE
666  * - \ref SCIP_STAGE_SOLVING
667  * - \ref SCIP_STAGE_SOLVED
668  */
669 extern
671  SCIP* scip, /**< SCIP data structure */
672  SCIP_Real obj /**< original space objective value to transform */
673  );
674 
675 /** maps transformed objective value into original space
676  *
677  * @return objective value into original space
678  *
679  * @pre This method can be called if SCIP is in one of the following stages:
680  * - \ref SCIP_STAGE_TRANSFORMING
681  * - \ref SCIP_STAGE_TRANSFORMED
682  * - \ref SCIP_STAGE_INITPRESOLVE
683  * - \ref SCIP_STAGE_PRESOLVING
684  * - \ref SCIP_STAGE_EXITPRESOLVE
685  * - \ref SCIP_STAGE_PRESOLVED
686  * - \ref SCIP_STAGE_INITSOLVE
687  * - \ref SCIP_STAGE_SOLVING
688  * - \ref SCIP_STAGE_SOLVED
689  */
690 extern
692  SCIP* scip, /**< SCIP data structure */
693  SCIP_Real obj /**< transformed objective value to retransform in original space */
694  );
695 
696 /** gets clock time, when this solution was found
697  *
698  * @return clock time, when this solution was found
699  *
700  * @pre This method can be called if SCIP is in one of the following stages:
701  * - \ref SCIP_STAGE_TRANSFORMING
702  * - \ref SCIP_STAGE_TRANSFORMED
703  * - \ref SCIP_STAGE_INITPRESOLVE
704  * - \ref SCIP_STAGE_PRESOLVING
705  * - \ref SCIP_STAGE_EXITPRESOLVE
706  * - \ref SCIP_STAGE_PRESOLVED
707  * - \ref SCIP_STAGE_INITSOLVE
708  * - \ref SCIP_STAGE_SOLVING
709  * - \ref SCIP_STAGE_SOLVED
710  * - \ref SCIP_STAGE_EXITSOLVE
711  * - \ref SCIP_STAGE_FREETRANS
712  */
713 extern
715  SCIP* scip, /**< SCIP data structure */
716  SCIP_SOL* sol /**< primal solution */
717  );
718 
719 /** gets branch and bound run number, where this solution was found
720  *
721  * @return branch and bound run number, where this solution was found
722  *
723  * @pre This method can be called if SCIP is in one of the following stages:
724  * - \ref SCIP_STAGE_TRANSFORMING
725  * - \ref SCIP_STAGE_TRANSFORMED
726  * - \ref SCIP_STAGE_INITPRESOLVE
727  * - \ref SCIP_STAGE_PRESOLVING
728  * - \ref SCIP_STAGE_EXITPRESOLVE
729  * - \ref SCIP_STAGE_PRESOLVED
730  * - \ref SCIP_STAGE_INITSOLVE
731  * - \ref SCIP_STAGE_SOLVING
732  * - \ref SCIP_STAGE_SOLVED
733  * - \ref SCIP_STAGE_EXITSOLVE
734  * - \ref SCIP_STAGE_FREETRANS
735  */
736 extern
737 int SCIPgetSolRunnum(
738  SCIP* scip, /**< SCIP data structure */
739  SCIP_SOL* sol /**< primal solution */
740  );
741 
742 /** gets node number of the specific branch and bound run, where this solution was found
743  *
744  * @return node number of the specific branch and bound run, where this solution was found
745  *
746  * @pre This method can be called if SCIP is in one of the following stages:
747  * - \ref SCIP_STAGE_TRANSFORMING
748  * - \ref SCIP_STAGE_TRANSFORMED
749  * - \ref SCIP_STAGE_INITPRESOLVE
750  * - \ref SCIP_STAGE_PRESOLVING
751  * - \ref SCIP_STAGE_EXITPRESOLVE
752  * - \ref SCIP_STAGE_PRESOLVED
753  * - \ref SCIP_STAGE_INITSOLVE
754  * - \ref SCIP_STAGE_SOLVING
755  * - \ref SCIP_STAGE_SOLVED
756  * - \ref SCIP_STAGE_EXITSOLVE
757  * - \ref SCIP_STAGE_FREETRANS
758  */
759 extern
761  SCIP* scip, /**< SCIP data structure */
762  SCIP_SOL* sol /**< primal solution */
763  );
764 
765 /** gets heuristic, that found this solution (or NULL if it's from the tree)
766  *
767  * @return heuristic, that found this solution (or NULL if it's from the tree)
768  *
769  * @pre This method can be called if SCIP is in one of the following stages:
770  * - \ref SCIP_STAGE_TRANSFORMING
771  * - \ref SCIP_STAGE_TRANSFORMED
772  * - \ref SCIP_STAGE_INITPRESOLVE
773  * - \ref SCIP_STAGE_PRESOLVING
774  * - \ref SCIP_STAGE_EXITPRESOLVE
775  * - \ref SCIP_STAGE_PRESOLVED
776  * - \ref SCIP_STAGE_INITSOLVE
777  * - \ref SCIP_STAGE_SOLVING
778  * - \ref SCIP_STAGE_SOLVED
779  * - \ref SCIP_STAGE_EXITSOLVE
780  * - \ref SCIP_STAGE_FREETRANS
781  */
782 extern
784  SCIP* scip, /**< SCIP data structure */
785  SCIP_SOL* sol /**< primal solution */
786  );
787 
788 /** returns whether two given solutions are exactly equal
789  *
790  * @return returns whether two given solutions are exactly equal
791  *
792  * @pre This method can be called if SCIP is in one of the following stages:
793  * - \ref SCIP_STAGE_PROBLEM
794  * - \ref SCIP_STAGE_TRANSFORMING
795  * - \ref SCIP_STAGE_TRANSFORMED
796  * - \ref SCIP_STAGE_INITPRESOLVE
797  * - \ref SCIP_STAGE_PRESOLVING
798  * - \ref SCIP_STAGE_EXITPRESOLVE
799  * - \ref SCIP_STAGE_PRESOLVED
800  * - \ref SCIP_STAGE_INITSOLVE
801  * - \ref SCIP_STAGE_SOLVING
802  * - \ref SCIP_STAGE_SOLVED
803  * - \ref SCIP_STAGE_EXITSOLVE
804  * - \ref SCIP_STAGE_FREETRANS
805  */
806 extern
808  SCIP* scip, /**< SCIP data structure */
809  SCIP_SOL* sol1, /**< first primal CIP solution */
810  SCIP_SOL* sol2 /**< second primal CIP solution */
811  );
812 
813 /** adjusts solution values of implicit integer variables in handed solution. Solution objective value is not
814  * deteriorated by this method.
815  *
816  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
817  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
818  *
819  * @pre This method can be called if SCIP is in one of the following stages:
820  * - \ref SCIP_STAGE_SOLVING
821  */
822 extern
824  SCIP* scip, /**< SCIP data structure */
825  SCIP_SOL* sol, /**< primal CIP solution */
826  SCIP_Bool uselprows /**< should LP row information be considered for none-objective variables */
827  );
828 
829 /** outputs non-zero variables of solution in original problem space to the given file stream
830  *
831  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
832  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
833  *
834  * @pre In case the solution pointer @p sol is NULL (askinking for the current LP/pseudo solution), this method can be
835  * called if @p scip is in one of the following stages:
836  * - \ref SCIP_STAGE_PRESOLVING
837  * - \ref SCIP_STAGE_EXITPRESOLVE
838  * - \ref SCIP_STAGE_PRESOLVED
839  * - \ref SCIP_STAGE_INITSOLVE
840  * - \ref SCIP_STAGE_SOLVING
841  * - \ref SCIP_STAGE_SOLVED
842  * - \ref SCIP_STAGE_EXITSOLVE
843  *
844  * @pre In case the solution pointer @p sol is @b not NULL, this method can be called if @p scip is in one of the
845  * following stages:
846  * - \ref SCIP_STAGE_PROBLEM
847  * - \ref SCIP_STAGE_TRANSFORMED
848  * - \ref SCIP_STAGE_INITPRESOLVE
849  * - \ref SCIP_STAGE_PRESOLVING
850  * - \ref SCIP_STAGE_EXITPRESOLVE
851  * - \ref SCIP_STAGE_PRESOLVED
852  * - \ref SCIP_STAGE_INITSOLVE
853  * - \ref SCIP_STAGE_SOLVING
854  * - \ref SCIP_STAGE_SOLVED
855  * - \ref SCIP_STAGE_EXITSOLVE
856  */
857 extern
859  SCIP* scip, /**< SCIP data structure */
860  SCIP_SOL* sol, /**< primal solution, or NULL for current LP/pseudo solution */
861  FILE* file, /**< output file (or NULL for standard output) */
862  SCIP_Bool printzeros /**< should variables set to zero be printed? */
863  );
864 
865 /** outputs non-zero variables of solution in transformed problem space to file stream
866  *
867  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
868  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
869  *
870  * @pre This method can be called if SCIP is in one of the following stages:
871  * - \ref SCIP_STAGE_TRANSFORMED
872  * - \ref SCIP_STAGE_INITPRESOLVE
873  * - \ref SCIP_STAGE_PRESOLVING
874  * - \ref SCIP_STAGE_EXITPRESOLVE
875  * - \ref SCIP_STAGE_PRESOLVED
876  * - \ref SCIP_STAGE_INITSOLVE
877  * - \ref SCIP_STAGE_SOLVING
878  * - \ref SCIP_STAGE_SOLVED
879  * - \ref SCIP_STAGE_EXITSOLVE
880  */
881 extern
883  SCIP* scip, /**< SCIP data structure */
884  SCIP_SOL* sol, /**< primal solution, or NULL for current LP/pseudo solution */
885  FILE* file, /**< output file (or NULL for standard output) */
886  SCIP_Bool printzeros /**< should variables set to zero be printed? */
887  );
888 
889 /** outputs discrete variables of solution in original problem space to the given file stream
890  *
891  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
892  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
893  *
894  * @pre This method can be called if @p scip is in one of the following stages:
895  * - \ref SCIP_STAGE_PROBLEM
896  * - \ref SCIP_STAGE_TRANSFORMED
897  * - \ref SCIP_STAGE_INITPRESOLVE
898  * - \ref SCIP_STAGE_PRESOLVING
899  * - \ref SCIP_STAGE_EXITPRESOLVE
900  * - \ref SCIP_STAGE_PRESOLVED
901  * - \ref SCIP_STAGE_INITSOLVE
902  * - \ref SCIP_STAGE_SOLVING
903  * - \ref SCIP_STAGE_SOLVED
904  * - \ref SCIP_STAGE_EXITSOLVE
905  */
906 extern
908  SCIP* scip, /**< SCIP data structure */
909  SCIP_SOL* sol, /**< primal solution */
910  FILE* file /**< output file (or NULL for standard output) */
911  );
912 
913 /** returns dual solution value of a constraint */
914 extern
916  SCIP* scip, /**< SCIP data structure */
917  SCIP_CONS* cons, /**< constraint for which the dual solution should be returned */
918  SCIP_Real* dualsolval, /**< pointer to store the dual solution value */
919  SCIP_Bool* boundconstraint /**< pointer to store whether the constraint is a bound constraint (or NULL) */
920  );
921 
922 /** check whether the dual solution is available
923  *
924  * @note This is used when calling \ref SCIPprintDualSol()
925  *
926  * @return is dual solution available?
927  *
928  * @pre This method can be called if SCIP is in one of the following stages:
929  * - \ref SCIP_STAGE_SOLVED
930  */
931 extern
933  SCIP* scip, /**< SCIP data structure */
934  SCIP_Bool printreason /**< print warning message if dualsol is not available? */
935  );
936 
937 /** outputs dual solution from LP solver to file stream
938  *
939  * @note This only works if no presolving has been performed, which can be checked by calling method \ref
940  * SCIPhasPerformedPresolve().
941  *
942  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
943  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
944  *
945  * @pre This method can be called if SCIP is in one of the following stages:
946  * - \ref SCIP_STAGE_SOLVED
947  */
948 extern
950  SCIP* scip, /**< SCIP data structure */
951  FILE* file, /**< output file (or NULL for standard output) */
952  SCIP_Bool printzeros /**< should variables set to zero be printed? */
953  );
954 
955 
956 /** outputs non-zero variables of solution representing a ray in original problem space to file stream
957  *
958  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
959  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
960  *
961  * @pre This method can be called if SCIP is in one of the following stages:
962  * - \ref SCIP_STAGE_PROBLEM
963  * - \ref SCIP_STAGE_TRANSFORMED
964  * - \ref SCIP_STAGE_INITPRESOLVE
965  * - \ref SCIP_STAGE_PRESOLVING
966  * - \ref SCIP_STAGE_EXITPRESOLVE
967  * - \ref SCIP_STAGE_PRESOLVED
968  * - \ref SCIP_STAGE_INITSOLVE
969  * - \ref SCIP_STAGE_SOLVING
970  * - \ref SCIP_STAGE_SOLVED
971  * - \ref SCIP_STAGE_EXITSOLVE
972  */
973 extern
975  SCIP* scip, /**< SCIP data structure */
976  SCIP_SOL* sol, /**< primal solution representing ray */
977  FILE* file, /**< output file (or NULL for standard output) */
978  SCIP_Bool printzeros /**< should variables set to zero be printed? */
979  );
980 
981 /** gets number of feasible primal solutions stored in the solution storage in case the problem is transformed;
982  * in case the problem stage is SCIP_STAGE_PROBLEM, the number of solution in the original solution candidate
983  * storage is returned
984  *
985  * @return number of feasible primal solutions stored in the solution storage in case the problem is transformed; or
986  * number of solution in the original solution candidate storage if the problem stage is SCIP_STAGE_PROBLEM
987  *
988  * @pre This method can be called if SCIP is in one of the following stages:
989  * - \ref SCIP_STAGE_PROBLEM
990  * - \ref SCIP_STAGE_TRANSFORMED
991  * - \ref SCIP_STAGE_INITPRESOLVE
992  * - \ref SCIP_STAGE_PRESOLVING
993  * - \ref SCIP_STAGE_EXITPRESOLVE
994  * - \ref SCIP_STAGE_PRESOLVED
995  * - \ref SCIP_STAGE_INITSOLVE
996  * - \ref SCIP_STAGE_SOLVING
997  * - \ref SCIP_STAGE_SOLVED
998  * - \ref SCIP_STAGE_EXITSOLVE
999  */
1000 extern
1001 int SCIPgetNSols(
1002  SCIP* scip /**< SCIP data structure */
1003  );
1004 
1005 /** gets array of feasible primal solutions stored in the solution storage in case the problem is transformed; in case
1006  * if the problem stage is in SCIP_STAGE_PROBLEM, it returns the number array of solution candidate stored
1007  *
1008  * @return array of feasible primal solutions
1009  *
1010  * @pre This method can be called if SCIP is in one of the following stages:
1011  * - \ref SCIP_STAGE_PROBLEM
1012  * - \ref SCIP_STAGE_TRANSFORMED
1013  * - \ref SCIP_STAGE_INITPRESOLVE
1014  * - \ref SCIP_STAGE_PRESOLVING
1015  * - \ref SCIP_STAGE_EXITPRESOLVE
1016  * - \ref SCIP_STAGE_PRESOLVED
1017  * - \ref SCIP_STAGE_INITSOLVE
1018  * - \ref SCIP_STAGE_SOLVING
1019  * - \ref SCIP_STAGE_SOLVED
1020  * - \ref SCIP_STAGE_EXITSOLVE
1021  */
1022 extern
1024  SCIP* scip /**< SCIP data structure */
1025  );
1026 
1027 /** gets best feasible primal solution found so far if the problem is transformed; in case the problem is in
1028  * SCIP_STAGE_PROBLEM it returns the best solution candidate, or NULL if no solution has been found or the candidate
1029  * store is empty;
1030  *
1031  * @return best feasible primal solution so far
1032  *
1033  * @pre This method can be called if SCIP is in one of the following stages:
1034  * - \ref SCIP_STAGE_PROBLEM
1035  * - \ref SCIP_STAGE_TRANSFORMED
1036  * - \ref SCIP_STAGE_INITPRESOLVE
1037  * - \ref SCIP_STAGE_PRESOLVING
1038  * - \ref SCIP_STAGE_EXITPRESOLVE
1039  * - \ref SCIP_STAGE_PRESOLVED
1040  * - \ref SCIP_STAGE_INITSOLVE
1041  * - \ref SCIP_STAGE_SOLVING
1042  * - \ref SCIP_STAGE_SOLVED
1043  * - \ref SCIP_STAGE_EXITSOLVE
1044  */
1045 extern
1047  SCIP* scip /**< SCIP data structure */
1048  );
1049 
1050 /** outputs best feasible primal solution found so far to file stream
1051  *
1052  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1053  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1054  *
1055  * @pre This method can be called if SCIP is in one of the following stages:
1056  * - \ref SCIP_STAGE_INIT
1057  * - \ref SCIP_STAGE_PROBLEM
1058  * - \ref SCIP_STAGE_TRANSFORMING
1059  * - \ref SCIP_STAGE_TRANSFORMED
1060  * - \ref SCIP_STAGE_INITPRESOLVE
1061  * - \ref SCIP_STAGE_PRESOLVING
1062  * - \ref SCIP_STAGE_EXITPRESOLVE
1063  * - \ref SCIP_STAGE_PRESOLVED
1064  * - \ref SCIP_STAGE_INITSOLVE
1065  * - \ref SCIP_STAGE_SOLVING
1066  * - \ref SCIP_STAGE_SOLVED
1067  * - \ref SCIP_STAGE_EXITSOLVE
1068  * - \ref SCIP_STAGE_FREE
1069  */
1070 extern
1072  SCIP* scip, /**< SCIP data structure */
1073  FILE* file, /**< output file (or NULL for standard output) */
1074  SCIP_Bool printzeros /**< should variables set to zero be printed? */
1075  );
1076 
1077 /** outputs best feasible primal solution found so far in transformed variables to file stream
1078  *
1079  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1080  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1081  *
1082  * @pre This method can be called if SCIP is in one of the following stages:
1083  * - \ref SCIP_STAGE_INIT
1084  * - \ref SCIP_STAGE_PROBLEM
1085  * - \ref SCIP_STAGE_TRANSFORMING
1086  * - \ref SCIP_STAGE_TRANSFORMED
1087  * - \ref SCIP_STAGE_INITPRESOLVE
1088  * - \ref SCIP_STAGE_PRESOLVING
1089  * - \ref SCIP_STAGE_EXITPRESOLVE
1090  * - \ref SCIP_STAGE_PRESOLVED
1091  * - \ref SCIP_STAGE_INITSOLVE
1092  * - \ref SCIP_STAGE_SOLVING
1093  * - \ref SCIP_STAGE_SOLVED
1094  * - \ref SCIP_STAGE_EXITSOLVE
1095  * - \ref SCIP_STAGE_FREE
1096  */
1097 extern
1099  SCIP* scip, /**< SCIP data structure */
1100  FILE* file, /**< output file (or NULL for standard output) */
1101  SCIP_Bool printzeros /**< should variables set to zero be printed? */
1102  );
1103 
1104 /** try to round given solution
1105  *
1106  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1107  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1108  *
1109  * @pre This method can be called if SCIP is in one of the following stages:
1110  * - \ref SCIP_STAGE_SOLVING
1111  */
1112 extern
1114  SCIP* scip, /**< SCIP data structure */
1115  SCIP_SOL* sol, /**< primal solution */
1116  SCIP_Bool* success /**< pointer to store whether rounding was successful */
1117  );
1118 
1119 /** retransforms solution to original problem space
1120  *
1121  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1122  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1123  *
1124  * @pre This method can be called if SCIP is in one of the following stages:
1125  * - \ref SCIP_STAGE_PROBLEM
1126  * - \ref SCIP_STAGE_TRANSFORMING
1127  * - \ref SCIP_STAGE_TRANSFORMED
1128  * - \ref SCIP_STAGE_INITPRESOLVE
1129  * - \ref SCIP_STAGE_PRESOLVING
1130  * - \ref SCIP_STAGE_EXITPRESOLVE
1131  * - \ref SCIP_STAGE_PRESOLVED
1132  * - \ref SCIP_STAGE_INITSOLVE
1133  * - \ref SCIP_STAGE_SOLVING
1134  * - \ref SCIP_STAGE_SOLVED
1135  * - \ref SCIP_STAGE_EXITSOLVE
1136  * - \ref SCIP_STAGE_FREETRANS
1137  */
1138 extern
1140  SCIP* scip, /**< SCIP data structure */
1141  SCIP_SOL* sol /**< primal CIP solution */
1142  );
1143 
1144 /** reads a given solution file, problem has to be transformed in advance
1145  *
1146  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1147  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1148  *
1149  * @pre This method can be called if SCIP is in one of the following stages:
1150  * - \ref SCIP_STAGE_PROBLEM
1151  * - \ref SCIP_STAGE_TRANSFORMED
1152  * - \ref SCIP_STAGE_INITPRESOLVE
1153  * - \ref SCIP_STAGE_PRESOLVING
1154  * - \ref SCIP_STAGE_EXITPRESOLVE
1155  * - \ref SCIP_STAGE_PRESOLVED
1156  * - \ref SCIP_STAGE_INITSOLVE
1157  * - \ref SCIP_STAGE_SOLVING
1158  */
1159 extern
1161  SCIP* scip, /**< SCIP data structure */
1162  const char* filename /**< name of the input file */
1163  );
1164 
1165 /** reads a given solution file and store the solution values in the given solution pointer
1166  *
1167  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1168  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1169  *
1170  * @pre This method can be called if SCIP is in one of the following stages:
1171  * - \ref SCIP_STAGE_PROBLEM
1172  * - \ref SCIP_STAGE_TRANSFORMED
1173  * - \ref SCIP_STAGE_INITPRESOLVE
1174  * - \ref SCIP_STAGE_PRESOLVING
1175  * - \ref SCIP_STAGE_EXITPRESOLVE
1176  * - \ref SCIP_STAGE_PRESOLVED
1177  * - \ref SCIP_STAGE_INITSOLVE
1178  * - \ref SCIP_STAGE_SOLVING
1179  */
1180 extern
1182  SCIP* scip, /**< SCIP data structure */
1183  const char* filename, /**< name of the input file */
1184  SCIP_SOL* sol, /**< solution pointer */
1185  SCIP_Bool xml, /**< true, iff the given solution in written in XML */
1186  SCIP_Bool* partial, /**< pointer to store if the solution is partial */
1187  SCIP_Bool* error /**< pointer store if an error occured */
1188  );
1189 
1190 /** adds feasible primal solution to solution storage by copying it
1191  *
1192  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1193  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1194  *
1195  * @pre This method can be called if SCIP is in one of the following stages:
1196  * - \ref SCIP_STAGE_PROBLEM
1197  * - \ref SCIP_STAGE_TRANSFORMED
1198  * - \ref SCIP_STAGE_INITPRESOLVE
1199  * - \ref SCIP_STAGE_PRESOLVING
1200  * - \ref SCIP_STAGE_EXITPRESOLVE
1201  * - \ref SCIP_STAGE_PRESOLVED
1202  * - \ref SCIP_STAGE_SOLVING
1203  * - \ref SCIP_STAGE_FREETRANS
1204  *
1205  * @note Do not call during propagation, use heur_trysol instead.
1206  */
1207 extern
1209  SCIP* scip, /**< SCIP data structure */
1210  SCIP_SOL* sol, /**< primal CIP solution */
1211  SCIP_Bool* stored /**< stores whether given solution was good enough to keep */
1212  );
1213 
1214 /** adds primal solution to solution storage, frees the solution afterwards
1215  *
1216  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1217  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1218  *
1219  * @pre This method can be called if SCIP is in one of the following stages:
1220  * - \ref SCIP_STAGE_PROBLEM
1221  * - \ref SCIP_STAGE_TRANSFORMED
1222  * - \ref SCIP_STAGE_INITPRESOLVE
1223  * - \ref SCIP_STAGE_PRESOLVING
1224  * - \ref SCIP_STAGE_EXITPRESOLVE
1225  * - \ref SCIP_STAGE_PRESOLVED
1226  * - \ref SCIP_STAGE_SOLVING
1227  * - \ref SCIP_STAGE_FREETRANS
1228  *
1229  * @note Do not call during propagation, use heur_trysol instead.
1230  */
1231 extern
1233  SCIP* scip, /**< SCIP data structure */
1234  SCIP_SOL** sol, /**< pointer to primal CIP solution; is cleared in function call */
1235  SCIP_Bool* stored /**< stores whether given solution was good enough to keep */
1236  );
1237 
1238 /** adds current LP/pseudo solution to solution storage
1239  *
1240  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1241  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1242  *
1243  * @pre This method can be called if SCIP is in one of the following stages:
1244  * - \ref SCIP_STAGE_PRESOLVED
1245  * - \ref SCIP_STAGE_SOLVING
1246  */
1247 extern
1249  SCIP* scip, /**< SCIP data structure */
1250  SCIP_HEUR* heur, /**< heuristic that found the solution */
1251  SCIP_Bool* stored /**< stores whether given solution was good enough to keep */
1252  );
1253 
1254 /** checks solution for feasibility; if possible, adds it to storage by copying
1255  *
1256  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1257  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1258  *
1259  * @pre This method can be called if SCIP is in one of the following stages:
1260  * - \ref SCIP_STAGE_TRANSFORMED
1261  * - \ref SCIP_STAGE_INITPRESOLVE
1262  * - \ref SCIP_STAGE_PRESOLVING
1263  * - \ref SCIP_STAGE_EXITPRESOLVE
1264  * - \ref SCIP_STAGE_PRESOLVED
1265  * - \ref SCIP_STAGE_SOLVING
1266  *
1267  * @note Do not call during propagation, use heur_trysol instead.
1268  */
1269 extern
1271  SCIP* scip, /**< SCIP data structure */
1272  SCIP_SOL* sol, /**< primal CIP solution */
1273  SCIP_Bool printreason, /**< Should all reasons of violations be printed? */
1274  SCIP_Bool completely, /**< Should all violations be checked? */
1275  SCIP_Bool checkbounds, /**< Should the bounds of the variables be checked? */
1276  SCIP_Bool checkintegrality, /**< Has integrality to be checked? */
1277  SCIP_Bool checklprows, /**< Do constraints represented by rows in the current LP have to be checked? */
1278  SCIP_Bool* stored /**< stores whether given solution was feasible and good enough to keep */
1279  );
1280 
1281 /** checks primal solution; if feasible, adds it to storage; solution is freed afterwards
1282  *
1283  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1284  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1285  *
1286  * @pre This method can be called if SCIP is in one of the following stages:
1287  * - \ref SCIP_STAGE_TRANSFORMED
1288  * - \ref SCIP_STAGE_INITPRESOLVE
1289  * - \ref SCIP_STAGE_PRESOLVING
1290  * - \ref SCIP_STAGE_EXITPRESOLVE
1291  * - \ref SCIP_STAGE_PRESOLVED
1292  * - \ref SCIP_STAGE_SOLVING
1293  *
1294  * @note Do not call during propagation, use heur_trysol instead.
1295  */
1296 extern
1298  SCIP* scip, /**< SCIP data structure */
1299  SCIP_SOL** sol, /**< pointer to primal CIP solution; is cleared in function call */
1300  SCIP_Bool printreason, /**< Should all reasons of violations be printed? */
1301  SCIP_Bool completely, /**< Should all violation be checked? */
1302  SCIP_Bool checkbounds, /**< Should the bounds of the variables be checked? */
1303  SCIP_Bool checkintegrality, /**< Has integrality to be checked? */
1304  SCIP_Bool checklprows, /**< Do constraints represented by rows in the current LP have to be checked? */
1305  SCIP_Bool* stored /**< stores whether solution was feasible and good enough to keep */
1306  );
1307 
1308 /** checks current LP/pseudo solution for feasibility; if possible, adds it to storage
1309  *
1310  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1311  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1312  *
1313  * @pre This method can be called if SCIP is in one of the following stages:
1314  * - \ref SCIP_STAGE_PRESOLVED
1315  * - \ref SCIP_STAGE_SOLVING
1316  */
1317 extern
1319  SCIP* scip, /**< SCIP data structure */
1320  SCIP_HEUR* heur, /**< heuristic that found the solution */
1321  SCIP_Bool printreason, /**< Should all reasons of violations be printed? */
1322  SCIP_Bool completely, /**< Should all violation be checked? */
1323  SCIP_Bool checkintegrality, /**< Has integrality to be checked? */
1324  SCIP_Bool checklprows, /**< Do constraints represented by rows in the current LP have to be checked? */
1325  SCIP_Bool* stored /**< stores whether given solution was feasible and good enough to keep */
1326  );
1327 
1328 /** returns all partial solutions
1329  *
1330  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1331  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1332  *
1333  * @pre This method can be called if SCIP is in one of the following stages:
1334  * - \ref SCIP_STAGE_PROBLEM
1335  * - \ref SCIP_STAGE_PRESOLVING
1336  * - \ref SCIP_STAGE_SOLVING
1337  * - \ref SCIP_STAGE_SOLVED
1338  */
1339 extern
1341  SCIP* scip /**< SCIP data structure */
1342  );
1343 
1344 /** returns number of partial solutions
1345  *
1346  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1347  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1348  *
1349  * @pre This method can be called if SCIP is in one of the following stages:
1350  * - \ref SCIP_STAGE_PROBLEM
1351  * - \ref SCIP_STAGE_PRESOLVING
1352  * - \ref SCIP_STAGE_SOLVING
1353  * - \ref SCIP_STAGE_SOLVED
1354  */
1356  SCIP* scip /**< SCIP data structure */
1357  );
1358 
1359 /** checks solution for feasibility without adding it to the solution store
1360  *
1361  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1362  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1363  *
1364  * @pre This method can be called if SCIP is in one of the following stages:
1365  * - \ref SCIP_STAGE_PROBLEM
1366  * - \ref SCIP_STAGE_TRANSFORMED
1367  * - \ref SCIP_STAGE_INITPRESOLVE
1368  * - \ref SCIP_STAGE_PRESOLVING
1369  * - \ref SCIP_STAGE_EXITPRESOLVE
1370  * - \ref SCIP_STAGE_PRESOLVED
1371  * - \ref SCIP_STAGE_INITSOLVE
1372  * - \ref SCIP_STAGE_SOLVING
1373  * - \ref SCIP_STAGE_SOLVED
1374  */
1375 extern
1377  SCIP* scip, /**< SCIP data structure */
1378  SCIP_SOL* sol, /**< primal CIP solution */
1379  SCIP_Bool printreason, /**< Should all reasons of violations be printed? */
1380  SCIP_Bool completely, /**< Should all violation be checked? */
1381  SCIP_Bool checkbounds, /**< Should the bounds of the variables be checked? */
1382  SCIP_Bool checkintegrality, /**< Has integrality to be checked? */
1383  SCIP_Bool checklprows, /**< Do constraints represented by rows in the current LP have to be checked? */
1384  SCIP_Bool* feasible /**< stores whether given solution is feasible */
1385  );
1386 
1387 /** checks solution for feasibility in original problem without adding it to the solution store;
1388  * this method is used to double check a solution in order to validate the presolving process
1389  *
1390  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1391  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1392  *
1393  * @pre This method can be called if SCIP is in one of the following stages:
1394  * - \ref SCIP_STAGE_PROBLEM
1395  * - \ref SCIP_STAGE_TRANSFORMED
1396  * - \ref SCIP_STAGE_INITPRESOLVE
1397  * - \ref SCIP_STAGE_PRESOLVING
1398  * - \ref SCIP_STAGE_EXITPRESOLVE
1399  * - \ref SCIP_STAGE_PRESOLVED
1400  * - \ref SCIP_STAGE_INITSOLVE
1401  * - \ref SCIP_STAGE_SOLVING
1402  * - \ref SCIP_STAGE_SOLVED
1403  */
1404 extern
1406  SCIP* scip, /**< SCIP data structure */
1407  SCIP_SOL* sol, /**< primal CIP solution */
1408  SCIP_Bool* feasible, /**< stores whether given solution is feasible */
1409  SCIP_Bool printreason, /**< should the reason for the violation be printed? */
1410  SCIP_Bool completely /**< should all violations be checked? */
1411  );
1412 
1413 /** update integrality violation of a solution */
1414 extern
1416  SCIP* scip, /**< SCIP data structure */
1417  SCIP_SOL* sol, /**< primal CIP solution */
1418  SCIP_Real absviol /**< absolute violation */
1419  );
1420 
1421 /** update bound violation of a solution */
1422 extern
1424  SCIP* scip, /**< SCIP data structure */
1425  SCIP_SOL* sol, /**< primal CIP solution */
1426  SCIP_Real absviol, /**< absolute violation */
1427  SCIP_Real relviol /**< relative violation */
1428  );
1429 
1430 /** update LP row violation of a solution */
1431 extern
1433  SCIP* scip, /**< SCIP data structure */
1434  SCIP_SOL* sol, /**< primal CIP solution */
1435  SCIP_Real absviol, /**< absolute violation */
1436  SCIP_Real relviol /**< relative violation */
1437  );
1438 
1439 /** update constraint violation of a solution */
1440 extern
1442  SCIP* scip, /**< SCIP data structure */
1443  SCIP_SOL* sol, /**< primal CIP solution */
1444  SCIP_Real absviol, /**< absolute violation */
1445  SCIP_Real relviol /**< relative violation */
1446  );
1447 
1448 /** update LP row and constraint violations of a solution */
1449 extern
1451  SCIP* scip, /**< SCIP data structure */
1452  SCIP_SOL* sol, /**< primal CIP solution */
1453  SCIP_Real absviol, /**< absolute violation */
1454  SCIP_Real relviol /**< relative violation */
1455  );
1456 
1457 /** allow violation updates */
1458 extern
1460  SCIP* scip /**< SCIP data structure */
1461  );
1462 
1463 /** disallow violation updates */
1464 extern
1466  SCIP* scip /**< SCIP data structure */
1467  );
1468 
1469 /** return whether a primal ray is stored that proves unboundedness of the LP relaxation
1470  *
1471  * @return return whether a primal ray is stored that proves unboundedness of the LP relaxation
1472  *
1473  * @pre This method can be called if SCIP is in one of the following stages:
1474  * - \ref SCIP_STAGE_SOLVING
1475  * - \ref SCIP_STAGE_SOLVED
1476  */
1477 extern
1479  SCIP* scip /**< SCIP data structure */
1480  );
1481 
1482 /** gets value of given variable in primal ray causing unboundedness of the LP relaxation;
1483  * should only be called if such a ray is stored (check with SCIPhasPrimalRay())
1484  *
1485  * @return value of given variable in primal ray causing unboundedness of the LP relaxation
1486  *
1487  * @pre This method can be called if SCIP is in one of the following stages:
1488  * - \ref SCIP_STAGE_SOLVING
1489  * - \ref SCIP_STAGE_SOLVED
1490  */
1491 extern
1493  SCIP* scip, /**< SCIP data structure */
1494  SCIP_VAR* var /**< variable to get value for */
1495  );
1496 
1497 /** updates the primal ray thats proves unboundedness
1498  *
1499  * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
1500  * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
1501  *
1502  * @pre This method can be called if @p scip is in one of the following stages:
1503  * - \ref SCIP_STAGE_PRESOLVING
1504  * - \ref SCIP_STAGE_PRESOLVED
1505  * - \ref SCIP_STAGE_SOLVING
1506  * - \ref SCIP_STAGE_SOLVED
1507  *
1508  * See \ref SCIP_Stage "SCIP_STAGE" for a complete list of all possible solving stages.
1509  */
1510 extern
1512  SCIP* scip, /**< SCIP data structure */
1513  SCIP_SOL* primalray /**< the new primal ray */
1514  );
1515 
1516 /**@} */
1517 
1518 #ifdef __cplusplus
1519 }
1520 #endif
1521 
1522 #endif
SCIP_RETCODE SCIPcreatePartialSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:554
SCIP_RETCODE SCIPprintBestSol(SCIP *scip, FILE *file, SCIP_Bool printzeros)
Definition: scip_sol.c:2445
SCIP_RETCODE SCIPlinkLPSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1075
SCIP_RETCODE SCIPlinkCurrentSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1180
int SCIPgetSolRunnum(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1679
SCIP_RETCODE SCIPincSolVal(SCIP *scip, SCIP_SOL *sol, SCIP_VAR *var, SCIP_Real incval)
Definition: scip_sol.c:1367
internal methods for branch and bound tree
SCIP_RETCODE SCIPadjustImplicitSolVals(SCIP *scip, SCIP_SOL *sol, SCIP_Bool uselprows)
Definition: scip_sol.c:1781
SCIP_RETCODE SCIPaddSolFree(SCIP *scip, SCIP_SOL **sol, SCIP_Bool *stored)
Definition: scip_sol.c:3087
SCIP_RETCODE SCIPrecomputeSolObj(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1571
void SCIPdeactivateSolViolationUpdates(SCIP *scip)
Definition: scip_sol.c:354
SCIP_SOL ** SCIPgetSols(SCIP *scip)
Definition: scip_sol.c:2329
int SCIPgetNPartialSols(SCIP *scip)
Definition: scip_sol.c:3449
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
SCIP_Real SCIPgetSolTime(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1652
type definitions for return codes for SCIP methods
SCIP_RETCODE SCIPcreateLPSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:419
SCIP_RETCODE SCIPaddCurrentSol(SCIP *scip, SCIP_HEUR *heur, SCIP_Bool *stored)
Definition: scip_sol.c:3157
SCIP_SOL ** SCIPgetPartialSols(SCIP *scip)
Definition: scip_sol.c:3427
SCIP_RETCODE SCIPcreateOrigSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:614
void SCIPupdateSolBoundViolation(SCIP *scip, SCIP_SOL *sol, SCIP_Real absviol, SCIP_Real relviol)
Definition: scip_sol.c:298
SCIP_RETCODE SCIPlinkNLPSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1101
SCIP_RETCODE SCIPcreateSolCopy(SCIP *scip, SCIP_SOL **sol, SCIP_SOL *sourcesol)
Definition: scip_sol.c:667
void SCIPupdateSolLPRowViolation(SCIP *scip, SCIP_SOL *sol, SCIP_Real absviol, SCIP_Real relviol)
Definition: scip_sol.c:310
type definitions for primal heuristics
SCIP_RETCODE SCIPtryCurrentSol(SCIP *scip, SCIP_HEUR *heur, SCIP_Bool printreason, SCIP_Bool completely, SCIP_Bool checkintegrality, SCIP_Bool checklprows, SCIP_Bool *stored)
Definition: scip_sol.c:3384
SCIP_RETCODE SCIPgetSolVals(SCIP *scip, SCIP_SOL *sol, int nvars, SCIP_VAR **vars, SCIP_Real *vals)
Definition: scip_sol.c:1447
SCIP_RETCODE SCIPreadSol(SCIP *scip, const char *filename)
Definition: scip_sol.c:2615
SCIP_RETCODE SCIPlinkPseudoSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1160
type definitions for SCIP&#39;s main datastructure
SCIP_Bool SCIPisDualSolAvailable(SCIP *scip, SCIP_Bool printreason)
Definition: scip_sol.c:2148
SCIP_RETCODE SCIPprintTransSol(SCIP *scip, SCIP_SOL *sol, FILE *file, SCIP_Bool printzeros)
Definition: scip_sol.c:1906
SCIP_RETCODE SCIPcheckSolOrig(SCIP *scip, SCIP_SOL *sol, SCIP_Bool *feasible, SCIP_Bool printreason, SCIP_Bool completely)
Definition: scip_sol.c:3533
internal miscellaneous methods
void SCIPupdateSolIntegralityViolation(SCIP *scip, SCIP_SOL *sol, SCIP_Real absviol)
Definition: scip_sol.c:287
SCIP_Real SCIPgetSolTransObj(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1540
SCIP_Bool SCIPareSolsEqual(SCIP *scip, SCIP_SOL *sol1, SCIP_SOL *sol2)
Definition: scip_sol.c:1761
internal methods for global SCIP settings
SCIP main data structure.
type definitions for problem variables
void SCIPupdateSolLPConsViolation(SCIP *scip, SCIP_SOL *sol, SCIP_Real absviol, SCIP_Real relviol)
Definition: scip_sol.c:334
SCIP_Bool SCIPhasPrimalRay(SCIP *scip)
Definition: scip_sol.c:3571
internal methods for problem variables
SCIP_RETCODE SCIPsetSolVal(SCIP *scip, SCIP_SOL *sol, SCIP_VAR *var, SCIP_Real val)
Definition: scip_sol.c:1270
SCIP_RETCODE SCIPclearSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1211
SCIP_RETCODE SCIPcheckSol(SCIP *scip, SCIP_SOL *sol, SCIP_Bool printreason, SCIP_Bool completely, SCIP_Bool checkbounds, SCIP_Bool checkintegrality, SCIP_Bool checklprows, SCIP_Bool *feasible)
Definition: scip_sol.c:3476
#define SCIP_Bool
Definition: def.h:62
SCIP_RETCODE SCIPcreateSolCopyOrig(SCIP *scip, SCIP_SOL **sol, SCIP_SOL *sourcesol)
Definition: scip_sol.c:707
SCIP_RETCODE SCIPprintRay(SCIP *scip, SCIP_SOL *sol, FILE *file, SCIP_Bool printzeros)
Definition: scip_sol.c:2244
SCIP_RETCODE SCIPprintBestTransSol(SCIP *scip, FILE *file, SCIP_Bool printzeros)
Definition: scip_sol.c:2485
SCIP_RETCODE SCIProundSol(SCIP *scip, SCIP_SOL *sol, SCIP_Bool *success)
Definition: scip_sol.c:2521
SCIP_RETCODE SCIPtrySolFree(SCIP *scip, SCIP_SOL **sol, SCIP_Bool printreason, SCIP_Bool completely, SCIP_Bool checkbounds, SCIP_Bool checkintegrality, SCIP_Bool checklprows, SCIP_Bool *stored)
Definition: scip_sol.c:3291
void SCIPactivateSolViolationUpdates(SCIP *scip)
Definition: scip_sol.c:346
methods for debugging
SCIP_RETCODE SCIPfreeSol(SCIP *scip, SCIP_SOL **sol)
Definition: scip_sol.c:1034
SCIP_RETCODE SCIPprintDualSol(SCIP *scip, FILE *file, SCIP_Bool printzeros)
Definition: scip_sol.c:2211
int SCIPgetNSols(SCIP *scip)
Definition: scip_sol.c:2280
SCIP_RETCODE SCIPgetDualSolVal(SCIP *scip, SCIP_CONS *cons, SCIP_Real *dualsolval, SCIP_Bool *boundconstraint)
Definition: scip_sol.c:2005
SCIP_RETCODE SCIPretransformSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:2557
SCIP_Real SCIPgetSolOrigObj(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1493
SCIP_RETCODE SCIPcreateUnknownSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:582
datastructures for problem statistics
SCIP_RETCODE SCIPcreateRelaxSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:482
SCIP_RETCODE SCIPtrySol(SCIP *scip, SCIP_SOL *sol, SCIP_Bool printreason, SCIP_Bool completely, SCIP_Bool checkbounds, SCIP_Bool checkintegrality, SCIP_Bool checklprows, SCIP_Bool *stored)
Definition: scip_sol.c:3197
type definitions for storing primal CIP solutions
SCIP_RETCODE SCIPcreatePseudoSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:509
SCIP_RETCODE SCIPaddSol(SCIP *scip, SCIP_SOL *sol, SCIP_Bool *stored)
Definition: scip_sol.c:2997
SCIP_RETCODE SCIPreadSolFile(SCIP *scip, const char *filename, SCIP_SOL *sol, SCIP_Bool xml, SCIP_Bool *partial, SCIP_Bool *error)
Definition: scip_sol.c:2957
SCIP_RETCODE SCIPcreateNLPSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:447
SCIP_SOL * SCIPgetBestSol(SCIP *scip)
Definition: scip_sol.c:2379
SCIP_RETCODE SCIPprintMIPStart(SCIP *scip, SCIP_SOL *sol, FILE *file)
Definition: scip_sol.c:1963
internal methods for main solving loop and node processing
SCIP_Real SCIPtransformObj(SCIP *scip, SCIP_Real obj)
Definition: scip_sol.c:1600
void SCIPupdateSolConsViolation(SCIP *scip, SCIP_SOL *sol, SCIP_Real absviol, SCIP_Real relviol)
Definition: scip_sol.c:322
SCIP_Real SCIPretransformObj(SCIP *scip, SCIP_Real obj)
Definition: scip_sol.c:1625
SCIP_HEUR * SCIPgetSolHeur(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1733
SCIP_RETCODE SCIPupdatePrimalRay(SCIP *scip, SCIP_SOL *primalray)
Definition: scip_sol.c:3616
#define SCIP_Real
Definition: def.h:150
internal methods for constraints and constraint handlers
SCIP_RETCODE SCIPlinkRelaxSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1133
#define SCIP_Longint
Definition: def.h:135
SCIP_RETCODE SCIPcreateCurrentSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:532
SCIP_RETCODE SCIPunlinkSol(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1239
SCIP_RETCODE SCIPsetSolVals(SCIP *scip, SCIP_SOL *sol, int nvars, SCIP_VAR **vars, SCIP_Real *vals)
Definition: scip_sol.c:1312
common defines and data types used in all packages of SCIP
SCIP_Real SCIPgetSolVal(SCIP *scip, SCIP_SOL *sol, SCIP_VAR *var)
Definition: scip_sol.c:1410
SCIP_Real SCIPgetPrimalRayVal(SCIP *scip, SCIP_VAR *var)
Definition: scip_sol.c:3589
type definitions for constraints and constraint handlers
SCIP_RETCODE SCIPcreateFiniteSolCopy(SCIP *scip, SCIP_SOL **sol, SCIP_SOL *sourcesol, SCIP_Bool *success)
Definition: scip_sol.c:898
SCIP_RETCODE SCIPcreateSol(SCIP *scip, SCIP_SOL **sol, SCIP_HEUR *heur)
Definition: scip_sol.c:377
SCIP_Longint SCIPgetSolNodenum(SCIP *scip, SCIP_SOL *sol)
Definition: scip_sol.c:1706
SCIP_RETCODE SCIPprintSol(SCIP *scip, SCIP_SOL *sol, FILE *file, SCIP_Bool printzeros)
Definition: scip_sol.c:1824