Skip to content

Commit d6b88b8

Browse files
committed
Merge remote-tracking branch 'origin/v9-minor'
2 parents f9e1b83 + 019c648 commit d6b88b8

File tree

6 files changed

+37
-54
lines changed

6 files changed

+37
-54
lines changed

Diff for: CHANGELOG

+1
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,7 @@ Fixed bugs
150150

151151
- apply same feasibility definition in PaPILO as SCIP to avoid numerical inconsistencies
152152
- check variable cancellation in SCIPvarAddVlb() and SCIPvarAddVub() to avert wrong infeasibility
153+
- SCIPfreeReoptSolve now also clears the partial solutions
153154

154155
Unit tests
155156
----------

Diff for: INSTALL.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@ make install #
5252
Note: For a full ctest run `ctest` instead of `make check` after compilation.
5353

5454
CMake checks for available third-party libraries like GMP or ZLIB and sets up the configuration accordingly.
55-
Note that the symmetry codes [Bliss](https://users.aalto.fi/~tjunttil/bliss/) and [Sassy](https://github.com/markusa4/sassy) are shipped with SCIP.
55+
Note that the symmetry codes [Nauty](https://pallini.di.uniroma1.it/) and [Sassy](https://github.com/markusa4/sassy) are shipped with SCIP.
56+
A version of Bliss that is compatible with SCIP is available at https://github.com/scipopt/bliss.
5657

5758
Note: Here is a list of apt package requirements for ubuntu or debian users that want to build the entire SCIP Optimization Suite from source tarball:
5859
```
@@ -185,7 +186,7 @@ e.g., `cmake </path/to/SCIP> -DSOPLEX_DIR=<path/to/SoPlex/build/or/install>`.
185186
| `IPOPT` | `on`, `off` | `IPOPT=[true,false]` | requires IPOPT version >= 3.12.0; specify `IPOPT_DIR` if not found automatically |
186187
| `LAPACK` | `on`, `off` | `LAPACK=[true,false]` | requires Lapack to be installed on the system |
187188
| `LPS` | `spx`, `cpx`, `grb`, `xprs`, ... | `LPS=...` | specify `SOPLEX_DIR`, `CPLEX_DIR`, `MOSEK_DIR`, ... if LP solver is not found automatically |
188-
| `SYM` | `bliss`, `sbliss`, `none`, ... | `SYM=[bliss, sbliss, none]`| choose symmetry handling |
189+
| `SYM` | `nauty`, `snauty`, `none`, ... | `SYM=[nauty, snauty, none]`| choose symmetry handling |
189190
| `WORHP` | `on`, `off` | `WORHP=[true,false]` | should worhp be linked; specify `WORHP_DIR` if not found automatically |
190191
| `ZIMPL` | `on`, `off` | `ZIMPL=[true, false]` | specify `ZIMPL_DIR` if not found automatically |
191192
| `AMPL` | `on`, `off` | `AMPL=[true, false]` | |
@@ -346,7 +347,7 @@ In your SCIP main directory, enter `make [options]` with the following options:
346347
| `PAPILO=false` | `[false, true]` | to disable or disable the MILP presolver based on the presolving library PaPILO |
347348
| `READLINE=true` | `[true, false]` | to enable or disable readline library for interactive shell |
348349
| `SHARED=false` | `[false, true]` | to suppress or create shared libraries (only Gnu compiler) |
349-
| `SYM=none` | `[none, bliss, sbliss, nauty, snauty]` | to choose method for computing symmetries in mixed nonlinear integer programs |
350+
| `SYM=none` | `[none, nauty, snauty, bliss, sbliss]` | to choose method for computing symmetries in mixed nonlinear integer programs |
350351
| `TPI=none` | `[none, omp, tny]` | to disable the task processing interface or use it with the openmp or tinycthreads interface for concurrent solves |
351352
| `VERBOSE=false` | `[false, true]` | to suppress or display of compiler and linker invocations |
352353
| `WORHP=false` | `[false, true]` | to disable or enable WORHP interface (needs WORHP >= 2.00) |

Diff for: doc/xternal.c

+4-6
Original file line numberDiff line numberDiff line change
@@ -8438,14 +8438,12 @@
84388438
* invariant. To detect such formulation symmetries, SCIP builds an auxiliary colored graph whose
84398439
* color-preserving automorphisms correspond to symmetries of the integer program. The symmetries of
84408440
* the graph, and thus of the integer program, are then computed by an external graph automorphism
8441-
* library that needs to be linked to SCIP. Currently, SCIP ships with two such libraries: The graph
8441+
* library that needs to be linked to SCIP. Currently, SCIP can use two such libraries: The graph
84428442
* automorphism libraries bliss or nauty/traces are the basic workhorses to detect symmetries. Moreover, one can use
84438443
* sassy, a graph symmetry preprocessor which passes the preprocessed graphs to bliss or nauty/traces.
8444-
* The current default is to use bliss in combination with sassy for symmetry detection.
8445-
*
8446-
* @note To detect symmetries, SCIP needs to be built with sassy/bliss, which can be achieved
8447-
* by using the options <code>SYM=sassy</code> and <code>-DSYM=sassy</code> in the Makefile and CMake
8448-
* system, respectively.
8444+
* The current default is to use nauty in combination with sassy for symmetry detection.
8445+
* To use other symmetry packages, options <code>SYM</code> and <code>-DSYM</code> in the Makefile and CMake
8446+
* system, respectively, need to be set.
84498447
*
84508448
* Besides purely integer linear problems, SCIP also supports symmetry detection for general
84518449
* constraint mixed-integer programs containing most of the constraint types that can be handled

Diff for: src/scip/primal.c

+26-43
Original file line numberDiff line numberDiff line change
@@ -162,34 +162,10 @@ SCIP_RETCODE SCIPprimalFree(
162162
BMS_BLKMEM* blkmem /**< block memory */
163163
)
164164
{
165-
int s;
166-
167165
assert(primal != NULL);
168166
assert(*primal != NULL);
169167

170-
/* free temporary solution for storing current solution */
171-
if( (*primal)->currentsol != NULL )
172-
{
173-
SCIP_CALL( SCIPsolFree(&(*primal)->currentsol, blkmem, *primal) );
174-
}
175-
176-
/* free solution for storing primal ray */
177-
if( (*primal)->primalray != NULL )
178-
{
179-
SCIP_CALL( SCIPsolFree(&(*primal)->primalray, blkmem, *primal) );
180-
}
181-
182-
/* free feasible primal CIP solutions */
183-
for( s = 0; s < (*primal)->nsols; ++s )
184-
{
185-
SCIP_CALL( SCIPsolFree(&(*primal)->sols[s], blkmem, *primal) );
186-
}
187-
/* free partial CIP solutions */
188-
for( s = 0; s < (*primal)->npartialsols; ++s )
189-
{
190-
SCIP_CALL( SCIPsolFree(&(*primal)->partialsols[s], blkmem, *primal) );
191-
}
192-
assert((*primal)->nexistingsols == 0);
168+
SCIP_CALL( SCIPprimalClear(*primal, blkmem) );
193169

194170
BMSfreeMemoryArrayNull(&(*primal)->sols);
195171
BMSfreeMemoryArrayNull(&(*primal)->partialsols);
@@ -201,43 +177,50 @@ SCIP_RETCODE SCIPprimalFree(
201177

202178
/** clears primal data */
203179
SCIP_RETCODE SCIPprimalClear(
204-
SCIP_PRIMAL** primal, /**< pointer to primal data */
180+
SCIP_PRIMAL* primal, /**< pointer to primal data */
205181
BMS_BLKMEM* blkmem /**< block memory */
206182
)
207183
{
208184
int s;
209185

210186
assert(primal != NULL);
211-
assert(*primal != NULL);
212187

213188
/* free temporary solution for storing current solution */
214-
if( (*primal)->currentsol != NULL )
189+
if( primal->currentsol != NULL )
215190
{
216-
SCIP_CALL( SCIPsolFree(&(*primal)->currentsol, blkmem, *primal) );
191+
SCIP_CALL( SCIPsolFree(&primal->currentsol, blkmem, primal) );
217192
}
218193

219194
/* free solution for storing primal ray */
220-
if( (*primal)->primalray != NULL )
195+
if( primal->primalray != NULL )
221196
{
222-
SCIP_CALL( SCIPsolFree(&(*primal)->primalray, blkmem, *primal) );
197+
SCIP_CALL( SCIPsolFree(&primal->primalray, blkmem, primal) );
223198
}
224199

225200
/* free feasible primal CIP solutions */
226-
for( s = 0; s < (*primal)->nsols; ++s )
201+
for( s = 0; s < primal->nsols; ++s )
227202
{
228-
SCIP_CALL( SCIPsolFree(&(*primal)->sols[s], blkmem, *primal) );
203+
SCIP_CALL( SCIPsolFree(&primal->sols[s], blkmem, primal) );
229204
}
230205

231-
(*primal)->currentsol = NULL;
232-
(*primal)->primalray = NULL;
233-
(*primal)->nsols = 0;
234-
(*primal)->nsolsfound = 0;
235-
(*primal)->nlimsolsfound = 0;
236-
(*primal)->nbestsolsfound = 0;
237-
(*primal)->nlimbestsolsfound = 0;
238-
(*primal)->upperbound = SCIP_INVALID;
239-
(*primal)->cutoffbound = SCIP_INVALID;
240-
(*primal)->updateviolations = TRUE;
206+
/* free partial CIP solutions */
207+
for( s = 0; s < primal->npartialsols; ++s )
208+
{
209+
SCIP_CALL( SCIPsolFree(&primal->partialsols[s], blkmem, primal) );
210+
}
211+
assert(primal->nexistingsols == 0);
212+
213+
primal->currentsol = NULL;
214+
primal->primalray = NULL;
215+
primal->nsols = 0;
216+
primal->nsolsfound = 0;
217+
primal->npartialsols = 0;
218+
primal->nlimsolsfound = 0;
219+
primal->nbestsolsfound = 0;
220+
primal->nlimbestsolsfound = 0;
221+
primal->upperbound = SCIP_INVALID;
222+
primal->cutoffbound = SCIP_INVALID;
223+
primal->updateviolations = TRUE;
241224

242225
return SCIP_OKAY;
243226
}

Diff for: src/scip/primal.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ SCIP_RETCODE SCIPprimalFree(
6767

6868
/** clears primal data */
6969
SCIP_RETCODE SCIPprimalClear(
70-
SCIP_PRIMAL** primal, /**< pointer to primal data */
70+
SCIP_PRIMAL* primal, /**< pointer to primal data */
7171
BMS_BLKMEM* blkmem /**< block memory */
7272
);
7373

Diff for: src/scip/scip_solve.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1812,7 +1812,7 @@ SCIP_RETCODE freeReoptSolve(
18121812
}
18131813

18141814
/* free the debug solution which might live in transformed primal data structure */
1815-
SCIP_CALL( SCIPprimalClear(&scip->primal, scip->mem->probmem) );
1815+
SCIP_CALL( SCIPprimalClear(scip->primal, scip->mem->probmem) );
18161816

18171817
if( scip->set->misc_resetstat )
18181818
{

0 commit comments

Comments
 (0)