Scippy

SCIP

Solving Constraint Integer Programs

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 email to scip@zib.de. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file sol.h
17  * @ingroup INTERNALAPI
18  * @brief internal methods for storing primal CIP solutions
19  * @author Tobias Achterberg
20  */
21 
22 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
23 
24 #ifndef __SCIP_SOL_H__
25 #define __SCIP_SOL_H__
26 
27 
28 #include <stdio.h>
29 
30 #include "scip/def.h"
31 #include "blockmemshell/memory.h"
32 #include "scip/type_retcode.h"
33 #include "scip/type_set.h"
34 #include "scip/type_stat.h"
35 #include "scip/type_lp.h"
36 #include "scip/type_nlp.h"
37 #include "scip/type_var.h"
38 #include "scip/type_prob.h"
39 #include "scip/type_sol.h"
40 #include "scip/type_primal.h"
41 #include "scip/type_tree.h"
42 #include "scip/type_heur.h"
43 #include "scip/pub_sol.h"
44 
45 #ifdef __cplusplus
46 extern "C" {
47 #endif
48 
49 /** creates primal CIP solution, initialized to zero */
50 extern
52  SCIP_SOL** sol, /**< pointer to primal CIP solution */
53  BMS_BLKMEM* blkmem, /**< block memory */
54  SCIP_SET* set, /**< global SCIP settings */
55  SCIP_STAT* stat, /**< problem statistics data */
56  SCIP_PRIMAL* primal, /**< primal data */
57  SCIP_TREE* tree, /**< branch and bound tree, or NULL */
58  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
59  );
60 
61 /** creates primal CIP solution in original problem space, initialized to the offset in the original problem */
62 extern
64  SCIP_SOL** sol, /**< pointer to primal CIP solution */
65  BMS_BLKMEM* blkmem, /**< block memory */
66  SCIP_SET* set, /**< global SCIP settings */
67  SCIP_STAT* stat, /**< problem statistics data */
68  SCIP_PROB* origprob, /**< original problem data */
69  SCIP_PRIMAL* primal, /**< primal data */
70  SCIP_TREE* tree, /**< branch and bound tree */
71  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
72  );
73 
74 /** creates a copy of a primal CIP solution */
75 extern
77  SCIP_SOL** sol, /**< pointer to store the copy of the primal CIP solution */
78  BMS_BLKMEM* blkmem, /**< block memory */
79  SCIP_SET* set, /**< global SCIP settings */
80  SCIP_STAT* stat, /**< problem statistics data */
81  SCIP_PRIMAL* primal, /**< primal data */
82  SCIP_SOL* sourcesol /**< primal CIP solution to copy */
83  );
84 
85 /** transformes given original solution to the transformed space; a corresponding transformed solution has to be given
86  * which is copied into the existing solution and freed afterwards
87  */
88 extern
90  SCIP_SOL* sol, /**< primal CIP solution to change, living in original space */
91  SCIP_SOL** transsol, /**< pointer to corresponding transformed primal CIP solution */
92  BMS_BLKMEM* blkmem, /**< block memory */
93  SCIP_SET* set, /**< global SCIP settings */
94  SCIP_PRIMAL* primal /**< primal data */
95  );
96 
97 /** adjusts solution values of implicit integer variables in handed solution. Solution objective value is not
98  * deteriorated by this method.
99  */
100 extern
102  SCIP_SOL* sol, /**< primal CIP solution */
103  SCIP_SET* set, /**< global SCIP settings */
104  SCIP_STAT* stat, /**< problem statistics data */
105  SCIP_PROB* prob, /**< either original or transformed problem, depending on sol origin */
106  SCIP_TREE* tree, /**< branch and bound tree */
107  SCIP_Bool uselprows /**< should LP row information be considered for none-objective variables */
108  );
109 
110 /** creates primal CIP solution, initialized to the current LP solution */
111 extern
113  SCIP_SOL** sol, /**< pointer to primal CIP solution */
114  BMS_BLKMEM* blkmem, /**< block memory */
115  SCIP_SET* set, /**< global SCIP settings */
116  SCIP_STAT* stat, /**< problem statistics data */
117  SCIP_PROB* prob, /**< transformed problem data */
118  SCIP_PRIMAL* primal, /**< primal data */
119  SCIP_TREE* tree, /**< branch and bound tree */
120  SCIP_LP* lp, /**< current LP data */
121  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
122  );
123 
124 /** creates primal CIP solution, initialized to the current NLP solution */
125 extern
127  SCIP_SOL** sol, /**< pointer to primal CIP solution */
128  BMS_BLKMEM* blkmem, /**< block memory */
129  SCIP_SET* set, /**< global SCIP settings */
130  SCIP_STAT* stat, /**< problem statistics data */
131  SCIP_PRIMAL* primal, /**< primal data */
132  SCIP_TREE* tree, /**< branch and bound tree */
133  SCIP_NLP* nlp, /**< current NLP data */
134  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
135  );
136 
137 /** creates primal CIP solution, initialized to the current relaxation solution */
138 extern
140  SCIP_SOL** sol, /**< pointer to primal CIP solution */
141  BMS_BLKMEM* blkmem, /**< block memory */
142  SCIP_SET* set, /**< global SCIP settings */
143  SCIP_STAT* stat, /**< problem statistics data */
144  SCIP_PRIMAL* primal, /**< primal data */
145  SCIP_TREE* tree, /**< branch and bound tree */
146  SCIP_RELAXATION* relaxation, /**< global relaxation data */
147  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
148  );
149 
150 /** creates primal CIP solution, initialized to the current pseudo solution */
151 extern
153  SCIP_SOL** sol, /**< pointer to primal CIP solution */
154  BMS_BLKMEM* blkmem, /**< block memory */
155  SCIP_SET* set, /**< global SCIP settings */
156  SCIP_STAT* stat, /**< problem statistics data */
157  SCIP_PROB* prob, /**< transformed problem data */
158  SCIP_PRIMAL* primal, /**< primal data */
159  SCIP_TREE* tree, /**< branch and bound tree, or NULL */
160  SCIP_LP* lp, /**< current LP data */
161  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
162  );
163 
164 /** creates primal CIP solution, initialized to the current solution */
165 extern
167  SCIP_SOL** sol, /**< pointer to primal CIP solution */
168  BMS_BLKMEM* blkmem, /**< block memory */
169  SCIP_SET* set, /**< global SCIP settings */
170  SCIP_STAT* stat, /**< problem statistics data */
171  SCIP_PROB* prob, /**< transformed problem data */
172  SCIP_PRIMAL* primal, /**< primal data */
173  SCIP_TREE* tree, /**< branch and bound tree */
174  SCIP_LP* lp, /**< current LP data */
175  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
176  );
177 
178 /** creates partial primal CIP solution, initialized to unknown values */
179 extern
181  SCIP_SOL** sol, /**< pointer to primal CIP solution */
182  BMS_BLKMEM* blkmem, /**< block memory */
183  SCIP_SET* set, /**< global SCIP settings */
184  SCIP_STAT* stat, /**< problem statistics data */
185  SCIP_PRIMAL* primal, /**< primal data */
186  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
187  );
188 
189 /** creates primal CIP solution, initialized to unknown values */
190 extern
192  SCIP_SOL** sol, /**< pointer to primal CIP solution */
193  BMS_BLKMEM* blkmem, /**< block memory */
194  SCIP_SET* set, /**< global SCIP settings */
195  SCIP_STAT* stat, /**< problem statistics data */
196  SCIP_PRIMAL* primal, /**< primal data */
197  SCIP_TREE* tree, /**< branch and bound tree */
198  SCIP_HEUR* heur /**< heuristic that found the solution (or NULL if it's from the tree) */
199  );
200 
201 /** frees primal CIP solution */
202 extern
204  SCIP_SOL** sol, /**< pointer to primal CIP solution */
205  BMS_BLKMEM* blkmem, /**< block memory */
206  SCIP_PRIMAL* primal /**< primal data */
207  );
208 
209 /** copies current LP solution into CIP solution by linking */
210 extern
212  SCIP_SOL* sol, /**< primal CIP solution */
213  SCIP_SET* set, /**< global SCIP settings */
214  SCIP_STAT* stat, /**< problem statistics data */
215  SCIP_PROB* prob, /**< transformed problem data */
216  SCIP_TREE* tree, /**< branch and bound tree */
217  SCIP_LP* lp /**< current LP data */
218  );
219 
220 /** copies current NLP solution into CIP solution by linking */
221 extern
223  SCIP_SOL* sol, /**< primal CIP solution */
224  SCIP_STAT* stat, /**< problem statistics data */
225  SCIP_TREE* tree, /**< branch and bound tree */
226  SCIP_NLP* nlp /**< current NLP data */
227  );
228 
229 /** copies current relaxation solution into CIP solution by linking */
230 extern
232  SCIP_SOL* sol, /**< primal CIP solution */
233  SCIP_SET* set, /**< global SCIP settings */
234  SCIP_STAT* stat, /**< problem statistics data */
235  SCIP_TREE* tree, /**< branch and bound tree */
236  SCIP_RELAXATION* relaxation /**< global relaxation data */
237  );
238 
239 /** copies current pseudo solution into CIP solution by linking */
240 extern
242  SCIP_SOL* sol, /**< primal CIP solution */
243  SCIP_SET* set, /**< global SCIP settings */
244  SCIP_STAT* stat, /**< problem statistics data */
245  SCIP_PROB* prob, /**< transformed problem data */
246  SCIP_TREE* tree, /**< branch and bound tree, or NULL */
247  SCIP_LP* lp /**< current LP data */
248  );
249 
250 /** copies current solution (LP or pseudo solution) into CIP solution by linking */
251 extern
253  SCIP_SOL* sol, /**< primal CIP solution */
254  SCIP_SET* set, /**< global SCIP settings */
255  SCIP_STAT* stat, /**< problem statistics data */
256  SCIP_PROB* prob, /**< transformed problem data */
257  SCIP_TREE* tree, /**< branch and bound tree */
258  SCIP_LP* lp /**< current LP data */
259  );
260 
261 /** clears primal CIP solution */
262 extern
264  SCIP_SOL* sol, /**< primal CIP solution */
265  SCIP_STAT* stat, /**< problem statistics data */
266  SCIP_TREE* tree /**< branch and bound tree */
267  );
268 
269 /** declares all entries in the primal CIP solution to be unknown */
270 extern
272  SCIP_SOL* sol, /**< primal CIP solution */
273  SCIP_STAT* stat, /**< problem statistics data */
274  SCIP_TREE* tree /**< branch and bound tree */
275  );
276 
277 /** stores solution values of variables in solution's own array */
278 extern
280  SCIP_SOL* sol, /**< primal CIP solution */
281  SCIP_SET* set, /**< global SCIP settings */
282  SCIP_PROB* prob /**< transformed problem data */
283  );
284 
285 /** sets value of variable in primal CIP solution */
286 extern
288  SCIP_SOL* sol, /**< primal CIP solution */
289  SCIP_SET* set, /**< global SCIP settings */
290  SCIP_STAT* stat, /**< problem statistics data */
291  SCIP_TREE* tree, /**< branch and bound tree */
292  SCIP_VAR* var, /**< variable to add to solution */
293  SCIP_Real val /**< solution value of variable */
294  );
295 
296 /** increases value of variable in primal CIP solution */
297 extern
299  SCIP_SOL* sol, /**< primal CIP solution */
300  SCIP_SET* set, /**< global SCIP settings */
301  SCIP_STAT* stat, /**< problem statistics data */
302  SCIP_TREE* tree, /**< branch and bound tree */
303  SCIP_VAR* var, /**< variable to increase solution value for */
304  SCIP_Real incval /**< increment for solution value of variable */
305  );
306 
307 /** returns value of variable in primal CIP solution */
308 extern
310  SCIP_SOL* sol, /**< primal CIP solution */
311  SCIP_SET* set, /**< global SCIP settings */
312  SCIP_STAT* stat, /**< problem statistics data */
313  SCIP_VAR* var /**< variable to get value for */
314  );
315 
316 /** returns value of variable in primal ray represented by primal CIP solution */
317 extern
319  SCIP_SOL* sol, /**< primal CIP solution, representing a primal ray */
320  SCIP_SET* set, /**< global SCIP settings */
321  SCIP_STAT* stat, /**< problem statistics data */
322  SCIP_VAR* var /**< variable to get value for */
323  );
324 
325 
326 /** gets objective value of primal CIP solution in transformed problem */
327 extern
329  SCIP_SOL* sol, /**< primal CIP solution */
330  SCIP_SET* set, /**< global SCIP settings */
331  SCIP_PROB* transprob, /**< tranformed problem data */
332  SCIP_PROB* origprob /**< original problem data */
333  );
334 
335 /** updates primal solutions after a change in a variable's objective value */
336 extern
338  SCIP_SOL* sol, /**< primal CIP solution */
339  SCIP_VAR* var, /**< problem variable */
340  SCIP_Real oldobj, /**< old objective value */
341  SCIP_Real newobj /**< new objective value */
342  );
343 
344 /* mark the given solution as partial solution */
345 extern
347  SCIP_SOL* sol, /**< primal CIP solution */
348  SCIP_SET* set, /**< global SCIP settings */
349  SCIP_STAT* stat, /**< problem statistics */
350  SCIP_VAR** vars, /**< problem variables */
351  int nvars /**< number of problem variables */
352  );
353 
354 /** checks primal CIP solution for feasibility
355  *
356  * @note The difference between SCIPsolCheck() and SCIPcheckSolOrig() is that modifiable constraints are handled
357  * differently. There might be some variables which do not have an original counter part (e.g. in
358  * branch-and-price). Therefore, modifiable constraints can not be double-checked in the original space.
359  */
360 extern
362  SCIP_SOL* sol, /**< primal CIP solution */
363  SCIP_SET* set, /**< global SCIP settings */
364  SCIP_MESSAGEHDLR* messagehdlr, /**< message handler */
365  BMS_BLKMEM* blkmem, /**< block memory */
366  SCIP_STAT* stat, /**< problem statistics */
367  SCIP_PROB* prob, /**< transformed problem data */
368  SCIP_Bool printreason, /**< Should all reasons of violations be printed? */
369  SCIP_Bool completely, /**< Should all violations be checked? */
370  SCIP_Bool checkbounds, /**< Should the bounds of the variables be checked? */
371  SCIP_Bool checkintegrality, /**< Has integrality to be checked? */
372  SCIP_Bool checklprows, /**< Do constraints represented by rows in the current LP have to be checked? */
373  SCIP_Bool* feasible /**< stores whether solution is feasible */
374  );
375 
376 /** try to round given solution */
377 extern
379  SCIP_SOL* sol, /**< primal solution */
380  SCIP_SET* set, /**< global SCIP settings */
381  SCIP_STAT* stat, /**< problem statistics data */
382  SCIP_PROB* prob, /**< transformed problem data */
383  SCIP_TREE* tree, /**< branch and bound tree */
384  SCIP_Bool* success /**< pointer to store whether rounding was successful */
385  );
386 
387 /** updates the solution value sums in variables by adding the value in the given solution */
388 extern
390  SCIP_SOL* sol, /**< primal CIP solution */
391  SCIP_SET* set, /**< global SCIP settings */
392  SCIP_STAT* stat, /**< problem statistics data */
393  SCIP_PROB* prob, /**< transformed problem data */
394  SCIP_Real weight /**< weight of solution in weighted average */
395  );
396 
397 /** retransforms solution to original problem space */
398 extern
400  SCIP_SOL* sol, /**< primal CIP solution */
401  SCIP_SET* set, /**< global SCIP settings */
402  SCIP_STAT* stat, /**< problem statistics data */
403  SCIP_PROB* origprob, /**< original problem */
404  SCIP_PROB* transprob, /**< transformed problem */
405  SCIP_Bool* hasinfval /**< pointer to store whether the solution has infinite values */
406  );
407 
408 /** recomputes the objective value of an original solution, e.g., when transferring solutions
409  * from the solution pool (objective coefficients might have changed in the meantime)
410  */
411 extern
413  SCIP_SOL* sol, /**< primal CIP solution */
414  SCIP_SET* set, /**< global SCIP settings */
415  SCIP_STAT* stat, /**< problem statistics data */
416  SCIP_PROB* origprob /**< original problem */
417  );
418 
419 
420 /** returns whether the given solutions in transformed space are equal */
421 extern
423  SCIP_SOL* sol1, /**< first primal CIP solution */
424  SCIP_SOL* sol2, /**< second primal CIP solution */
425  SCIP_SET* set, /**< global SCIP settings */
426  SCIP_STAT* stat, /**< problem statistics data */
427  SCIP_PROB* origprob, /**< original problem */
428  SCIP_PROB* transprob /**< transformed problem after presolve */
429  );
430 
431 /** outputs non-zero elements of solution to file stream */
432 extern
434  SCIP_SOL* sol, /**< primal CIP solution */
435  SCIP_SET* set, /**< global SCIP settings */
436  SCIP_MESSAGEHDLR* messagehdlr, /**< message handler */
437  SCIP_STAT* stat, /**< problem statistics data */
438  SCIP_PROB* prob, /**< problem data (original or transformed) */
439  SCIP_PROB* transprob, /**< transformed problem data or NULL (to display priced variables) */
440  FILE* file, /**< output file (or NULL for standard output) */
441  SCIP_Bool mipstart, /**< should only discrete variables be printed? */
442  SCIP_Bool printzeros /**< should variables set to zero be printed? */
443  );
444 
445 /** outputs non-zero elements of solution representing a ray to file stream */
446 extern
448  SCIP_SOL* sol, /**< primal CIP solution */
449  SCIP_SET* set, /**< global SCIP settings */
450  SCIP_MESSAGEHDLR* messagehdlr, /**< message handler */
451  SCIP_STAT* stat, /**< problem statistics data */
452  SCIP_PROB* prob, /**< problem data (original or transformed) */
453  SCIP_PROB* transprob, /**< transformed problem data or NULL (to display priced variables) */
454  FILE* file, /**< output file (or NULL for standard output) */
455  SCIP_Bool printzeros /**< should variables set to zero be printed? */
456  );
457 
458 
459 /** reset violations of a solution */
460 extern
462  SCIP_SOL* sol /**< primal CIP solution */
463  );
464 
465 /** update integrality violation of a solution */
466 extern
468  SCIP_SOL* sol, /**< primal CIP solution */
469  SCIP_Real absviolintegrality /**< absolute violation of integrality */
470  );
471 
472 /** update bound violation of a solution */
473 extern
475  SCIP_SOL* sol, /**< primal CIP solution */
476  SCIP_Real absviolbounds, /**< absolute violation of bounds */
477  SCIP_Real relviolbounds /**< relative violation of bounds */
478  );
479 
480 /** update LP row violation of a solution */
481 extern
483  SCIP_SOL* sol, /**< primal CIP solution */
484  SCIP_Real absviollprows, /**< absolute violation of LP rows */
485  SCIP_Real relviollprows /**< relative violation of LP rows */
486  );
487 
488 /** update constraint violation of a solution */
489 extern
491  SCIP_SOL* sol, /**< primal CIP solution */
492  SCIP_Real absviolcons, /**< absolute violation of constraint */
493  SCIP_Real relviolcons /**< relative violation of constraint */
494  );
495 
496 /** update violation of a constraint that is represented in the LP */
497 extern
499  SCIP_SOL* sol, /**< primal CIP solution */
500  SCIP_Real absviol, /**< absolute violation of constraint */
501  SCIP_Real relviol /**< relative violation of constraint */
502  );
503 
504 
505 
506 /* In debug mode, the following methods are implemented as function calls to ensure
507  * type validity.
508  */
509 
510 /** adds value to the objective value of a given original primal CIP solution */
511 extern
513  SCIP_SOL* sol, /**< primal CIP solution */
514  SCIP_Real addval /**< offset value to add */
515  );
516 
517 /** gets current position of solution in array of existing solutions of primal data */
518 extern
520  SCIP_SOL* sol /**< primal CIP solution */
521  );
522 
523 /** sets current position of solution in array of existing solutions of primal data */
524 extern
526  SCIP_SOL* sol, /**< primal CIP solution */
527  int primalindex /**< new primal index of solution */
528  );
529 
530 #ifdef NDEBUG
531 
532 /* In optimized mode, the function calls are overwritten by defines to reduce the number of function calls and
533  * speed up the algorithms.
534  */
535 
536 #define SCIPsolOrigAddObjval(sol, addval) ((sol)->obj += (addval))
537 #define SCIPsolGetPrimalIndex(sol) ((sol)->primalindex)
538 #define SCIPsolSetPrimalIndex(sol,idx) { (sol)->primalindex = idx; }
539 
540 #endif
541 
542 #ifdef __cplusplus
543 }
544 #endif
545 
546 #endif
SCIP_RETCODE SCIPsolSetUnknown(SCIP_SOL *sol, SCIP_STAT *stat, SCIP_TREE *tree)
Definition: sol.c:981
SCIP_RETCODE SCIPsolAdjustImplicitSolVals(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_TREE *tree, SCIP_Bool uselprows)
Definition: sol.c:435
SCIP_RETCODE SCIPsolCopy(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_SOL *sourcesol)
Definition: sol.c:344
type definitions for NLP management
SCIP_RETCODE SCIPsolClear(SCIP_SOL *sol, SCIP_STAT *stat, SCIP_TREE *tree)
Definition: sol.c:964
SCIP_RETCODE SCIPsolLinkRelaxSol(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_TREE *tree, SCIP_RELAXATION *relaxation)
Definition: sol.c:879
void SCIPsolUpdateConsViolation(SCIP_SOL *sol, SCIP_Real absviolcons, SCIP_Real relviolcons)
Definition: sol.c:2335
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:53
SCIP_Real SCIPsolGetObj(SCIP_SOL *sol, SCIP_SET *set, SCIP_PROB *transprob, SCIP_PROB *origprob)
Definition: sol.c:1492
void SCIPsolUpdateVarsum(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_Real weight)
Definition: sol.c:1787
type definitions for global SCIP settings
void SCIPsolUpdateLPConsViolation(SCIP_SOL *sol, SCIP_Real absviol, SCIP_Real relviol)
Definition: sol.c:2348
SCIP_RETCODE SCIPsolCreateCurrentSol(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_LP *lp, SCIP_HEUR *heur)
Definition: sol.c:657
type definitions for return codes for SCIP methods
SCIP_RETCODE SCIPsolRetransform(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *origprob, SCIP_PROB *transprob, SCIP_Bool *hasinfval)
Definition: sol.c:1815
SCIP_RETCODE SCIPsolMarkPartial(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_VAR **vars, int nvars)
Definition: sol.c:1528
SCIP_RETCODE SCIPsolSetVal(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_TREE *tree, SCIP_VAR *var, SCIP_Real val)
Definition: sol.c:1027
type definitions for problem statistics
SCIP_RETCODE SCIPsolCreateRelaxSol(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_RELAXATION *relaxation, SCIP_HEUR *heur)
Definition: sol.c:614
SCIP_RETCODE SCIPsolCreateOriginal(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *origprob, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_HEUR *heur)
Definition: sol.c:310
type definitions for LP management
void SCIPsolUpdateVarObj(SCIP_SOL *sol, SCIP_VAR *var, SCIP_Real oldobj, SCIP_Real newobj)
Definition: sol.c:1509
void SCIPsolUpdateBoundViolation(SCIP_SOL *sol, SCIP_Real absviolbounds, SCIP_Real relviolbounds)
Definition: sol.c:2309
SCIP_RETCODE SCIPsolTransform(SCIP_SOL *sol, SCIP_SOL **transsol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_PRIMAL *primal)
Definition: sol.c:389
SCIP_RETCODE SCIPsolUnlink(SCIP_SOL *sol, SCIP_SET *set, SCIP_PROB *prob)
Definition: sol.c:998
SCIP_RETCODE SCIPsolRound(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_TREE *tree, SCIP_Bool *success)
Definition: sol.c:1715
SCIP_RETCODE SCIPsolLinkCurrentSol(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_TREE *tree, SCIP_LP *lp)
Definition: sol.c:938
SCIP_RETCODE SCIPsolFree(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_PRIMAL *primal)
Definition: sol.c:751
void SCIPsolUpdateIntegralityViolation(SCIP_SOL *sol, SCIP_Real absviolintegrality)
Definition: sol.c:2298
void SCIPsolUpdateLPRowViolation(SCIP_SOL *sol, SCIP_Real absviollprows, SCIP_Real relviollprows)
Definition: sol.c:2322
type definitions for primal heuristics
SCIP_RETCODE SCIPsolPrint(SCIP_SOL *sol, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_PROB *transprob, FILE *file, SCIP_Bool mipstart, SCIP_Bool printzeros)
Definition: sol.c:2037
public methods for primal CIP solutions
SCIP_RETCODE SCIPsolPrintRay(SCIP_SOL *sol, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_PROB *transprob, FILE *file, SCIP_Bool printzeros)
Definition: sol.c:2170
type definitions for problem variables
SCIP_RETCODE SCIPsolCreatePseudoSol(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_LP *lp, SCIP_HEUR *heur)
Definition: sol.c:636
SCIP_RETCODE SCIPsolCreateUnknown(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_HEUR *heur)
Definition: sol.c:718
int SCIPsolGetPrimalIndex(SCIP_SOL *sol)
Definition: sol.c:2558
#define SCIP_Bool
Definition: def.h:61
SCIP_Real SCIPsolGetRayVal(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_VAR *var)
Definition: sol.c:1423
SCIP_RETCODE SCIPsolCheck(SCIP_SOL *sol, SCIP_SET *set, SCIP_MESSAGEHDLR *messagehdlr, BMS_BLKMEM *blkmem, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_Bool printreason, SCIP_Bool completely, SCIP_Bool checkbounds, SCIP_Bool checkintegrality, SCIP_Bool checklprows, SCIP_Bool *feasible)
Definition: sol.c:1593
type definitions for branch and bound tree
SCIP_RETCODE SCIPsolLinkLPSol(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_TREE *tree, SCIP_LP *lp)
Definition: sol.c:770
type definitions for storing primal CIP solutions
type definitions for storing and manipulating the main problem
SCIP_RETCODE SCIPsolCreatePartial(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_HEUR *heur)
Definition: sol.c:684
SCIP_RETCODE SCIPsolLinkPseudoSol(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_TREE *tree, SCIP_LP *lp)
Definition: sol.c:909
void SCIPsolRecomputeObj(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *origprob)
Definition: sol.c:1942
SCIP_RETCODE SCIPsolIncVal(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_TREE *tree, SCIP_VAR *var, SCIP_Real incval)
Definition: sol.c:1222
void SCIPsolResetViolations(SCIP_SOL *sol)
Definition: sol.c:2282
#define SCIP_Real
Definition: def.h:149
SCIP_Real SCIPsolGetVal(SCIP_SOL *sol, SCIP_SET *set, SCIP_STAT *stat, SCIP_VAR *var)
Definition: sol.c:1298
SCIP_RETCODE SCIPsolCreate(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_HEUR *heur)
Definition: sol.c:276
type definitions for collecting primal CIP solutions and primal informations
common defines and data types used in all packages of SCIP
SCIP_RETCODE SCIPsolCreateLPSol(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *prob, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_LP *lp, SCIP_HEUR *heur)
Definition: sol.c:570
struct BMS_BlkMem BMS_BLKMEM
Definition: memory.h:419
SCIP_Bool SCIPsolsAreEqual(SCIP_SOL *sol1, SCIP_SOL *sol2, SCIP_SET *set, SCIP_STAT *stat, SCIP_PROB *origprob, SCIP_PROB *transprob)
Definition: sol.c:1977
void SCIPsolOrigAddObjval(SCIP_SOL *sol, SCIP_Real addval)
Definition: sol.c:2496
SCIP_RETCODE SCIPsolLinkNLPSol(SCIP_SOL *sol, SCIP_STAT *stat, SCIP_TREE *tree, SCIP_NLP *nlp)
Definition: sol.c:828
SCIP_RETCODE SCIPsolCreateNLPSol(SCIP_SOL **sol, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_STAT *stat, SCIP_PRIMAL *primal, SCIP_TREE *tree, SCIP_NLP *nlp, SCIP_HEUR *heur)
Definition: sol.c:593
void SCIPsolSetPrimalIndex(SCIP_SOL *sol, int primalindex)
Definition: sol.c:2568
memory allocation routines