141#define PROP_NAME "symmetry"
142#define PROP_DESC "propagator for handling symmetry"
143#define PROP_TIMING SCIP_PROPTIMING_BEFORELP
144#define PROP_PRIORITY -1000000
146#define PROP_DELAY FALSE
148#define PROP_PRESOL_PRIORITY -10000000
149#define PROP_PRESOLTIMING SCIP_PRESOLTIMING_EXHAUSTIVE
150#define PROP_PRESOL_MAXROUNDS -1
154#define DEFAULT_MAXGENERATORS 1500
155#define DEFAULT_CHECKSYMMETRIES FALSE
156#define DEFAULT_DISPLAYNORBITVARS FALSE
157#define DEFAULT_USECOLUMNSPARSITY FALSE
158#define DEFAULT_DOUBLEEQUATIONS FALSE
159#define DEFAULT_COMPRESSSYMMETRIES TRUE
160#define DEFAULT_COMPRESSTHRESHOLD 0.5
161#define DEFAULT_SYMFIXNONBINARYVARS FALSE
162#define DEFAULT_ENFORCECOMPUTESYMMETRY FALSE
163#define DEFAULT_SYMTYPE (int) SYM_SYMTYPE_PERM
166#define DEFAULT_CONSSADDLP TRUE
167#define DEFAULT_ADDSYMRESACKS TRUE
168#define DEFAULT_DETECTDOUBLELEX TRUE
169#define DEFAULT_DETECTORBITOPES TRUE
170#define DEFAULT_DETECTSUBGROUPS TRUE
171#define DEFAULT_ADDWEAKSBCS TRUE
172#define DEFAULT_ADDSTRONGSBCS FALSE
173#define DEFAULT_ADDCONSSTIMING 2
174#define DEFAULT_MAXNCONSSSUBGROUP 500000
175#define DEFAULT_USEDYNAMICPROP TRUE
176#define DEFAULT_PREFERLESSROWS TRUE
179#define DEFAULT_SYMCOMPTIMING 2
180#define DEFAULT_PERFORMPRESOLVING 0
181#define DEFAULT_RECOMPUTERESTART 0
184#define DEFAULT_SSTTIEBREAKRULE 1
185#define DEFAULT_SSTLEADERRULE 0
186#define DEFAULT_SSTLEADERVARTYPE 14
188#define DEFAULT_ADDCONFLICTCUTS TRUE
189#define DEFAULT_SSTADDCUTS TRUE
190#define DEFAULT_SSTMIXEDCOMPONENTS TRUE
193#define TABLE_NAME_SYMMETRY "symmetry"
194#define TABLE_DESC_SYMMETRY "symmetry handling statistics"
195#define TABLE_POSITION_SYMMETRY 7001
196#define TABLE_EARLIEST_SYMMETRY SCIP_STAGE_SOLVING
200#define MAXGENNUMERATOR 64000000
201#define COMPRESSNVARSLB 25000
202#define DEFAULT_NAUTYMAXNCELLS 100000
204#define DEFAULT_NAUTYMAXNNODES 10000000
209#define ISSYMRETOPESACTIVE(x) (((unsigned) x & SYM_HANDLETYPE_SYMBREAK) != 0)
210#define ISORBITALREDUCTIONACTIVE(x) (((unsigned) x & SYM_HANDLETYPE_ORBITALREDUCTION) != 0)
211#define ISSSTACTIVE(x) (((unsigned) x & SYM_HANDLETYPE_SST) != 0)
213#define ISSSTBINACTIVE(x) (((unsigned) x & SCIP_SSTTYPE_BINARY) != 0)
214#define ISSSTINTACTIVE(x) (((unsigned) x & SCIP_SSTTYPE_INTEGER) != 0)
215#define ISSSTIMPLINTACTIVE(x) (((unsigned) x & SCIP_SSTTYPE_IMPLINT) != 0)
216#define ISSSTCONTACTIVE(x) (((unsigned) x & SCIP_SSTTYPE_CONTINUOUS) != 0)
219#define SYMMETRY_STATISTICS 1
234 int nmovedbinpermvars;
235 int nmovedintpermvars;
236 int nmovedimplintpermvars;
237 int nmovedcontpermvars;
248 int* componentbegins;
252 unsigned* componentblocked;
294 int maxnconsssubgroup;
299 int recomputerestart;
309 int sstleadervartype;
325struct SCIP_ConflictData
330 int nconflictinorbit;
347 else if ( elem1 > elem2 )
385 cmp = compfunc(arr1[it1], arr2[it2]);
391 if ( ++it1 >= narr1 )
400 if ( ++it2 >= narr2 )
413 assert( it1 >= narr1 || it2 >= narr2 );
446 if ( perm[baseidx] == baseidx || covered[baseidx] )
453 covered[baseidx] =
TRUE;
454 while ( j != baseidx )
484 assert( propdata->nperms > 0 );
486 assert( propdata->npermvars > 0 );
489 npermvars = propdata->npermvars;
497 for (p = 0; p < propdata->nperms; ++p)
500 perm = propdata->perms[p];
502 for (
i = 0;
i < permlen; ++
i)
507 for (
i = 0;
i < permlen; ++
i)
535 assert( propdata->nperms > 0 );
537 assert( propdata->npermvars > 0 );
538 assert( propdata->ncomponents > 0 );
541 npermvars = propdata->npermvars;
546 for (
c = 0;
c < propdata->ncomponents; ++
c)
551 if ( propdata->componenthassignedperm[
c] )
556 comppermlen = propdata->componenthassignedperm[
c] ? 2 * npermvars : npermvars;
558 for (p = propdata->componentbegins[
c], cnt = 0; p < propdata->componentbegins[
c + 1]; ++p, ++cnt)
561 perm = propdata->perms[propdata->components[p]];
563 for (
i = 0;
i < comppermlen; ++
i)
568 for (
i = 0;
i < comppermlen; ++
i)
590 if ( propdata->nperms == -1 )
594 else if ( propdata->nperms == 0 )
598 else if ( propdata->ncomponents < 0 )
641 if ( tabledata->propdata->orbitopalreddata || tabledata->propdata->orbitalreddata
642 || tabledata->propdata->lexreddata )
645 if ( tabledata->propdata->orbitopalreddata )
649 " %10d cutoffs\n", nred, ncutoff);
651 if ( tabledata->propdata->orbitalreddata )
655 " %10d cutoffs\n", nred, ncutoff);
657 if ( tabledata->propdata->lexreddata )
661 " %10d cutoffs\n", nred, ncutoff);
663 if ( tabledata->propdata->shadowtreeeventhdlr )
784 if ( G1->
lhs[perm1] < G2->
lhs[perm2] )
786 if ( G1->
lhs[perm1] > G2->
lhs[perm2] )
789 if ( G1->
rhs[perm1] < G2->
rhs[perm2] )
791 if ( G1->
rhs[perm1] > G2->
rhs[perm2] )
859 assert( propdata->ngenlinconss == 0 );
860 assert( propdata->ngenorbconss == 0 );
861 assert( propdata->genorbconsssize == 0 );
862 assert( propdata->genlinconsssize == 0 );
866 assert( propdata->permvardomaincenter ==
NULL );
870 assert( propdata->npermvars == 0 );
871 assert( propdata->nbinpermvars == 0 );
872 assert( propdata->nperms == -1 || propdata->nperms == 0 );
873 assert( propdata->nmaxperms == 0 );
874 assert( propdata->nmovedpermvars == -1 );
875 assert( propdata->nmovedbinpermvars == 0 );
876 assert( propdata->nmovedintpermvars == 0 );
877 assert( propdata->nmovedimplintpermvars == 0 );
878 assert( propdata->nmovedcontpermvars == 0 );
879 assert( propdata->nmovedvars == -1 );
883 assert( propdata->componenthassignedperm ==
NULL );
887 assert( propdata->ncomponents == -1 );
888 assert( propdata->ncompblocked == 0 );
906 if ( propdata->orbitalreddata !=
NULL )
910 if ( propdata->orbitopalreddata !=
NULL )
914 if ( propdata->lexreddata !=
NULL )
937 if ( propdata->permvarmap !=
NULL )
943 for (
i = 0;
i < propdata->npermvars; ++
i)
950 if ( propdata->permstrans !=
NULL )
952 assert( propdata->nperms > 0 );
954 assert( propdata->npermvars > 0 );
955 assert( propdata->nmaxperms > 0 );
957 for (
i = 0;
i < propdata->npermvars; ++
i)
965 if ( propdata->genorbconss !=
NULL )
967 assert( propdata->ngenorbconss > 0 );
970 while ( propdata->ngenorbconss > 0 )
972 assert( propdata->genorbconss[propdata->ngenorbconss - 1] !=
NULL );
975 assert( propdata->ngenorbconss == 0 );
979 propdata->genorbconsssize = 0;
983 if ( propdata->genlinconss !=
NULL )
986 for (
i = 0;
i < propdata->ngenlinconss; ++
i)
994 propdata->ngenlinconss = 0;
995 propdata->genlinconsssize = 0;
998 if ( propdata->sstconss !=
NULL )
1000 assert( propdata->nsstconss > 0 );
1003 for (
i = 0;
i < propdata->nsstconss; ++
i)
1011 propdata->sstconss =
NULL;
1012 propdata->nsstconss = 0;
1013 propdata->maxnsstconss = 0;
1016 if ( propdata->leaders !=
NULL )
1018 assert( propdata->maxnleaders > 0 );
1021 propdata->maxnleaders = 0;
1022 propdata->leaders =
NULL;
1023 propdata->nleaders = 0;
1027 if ( propdata->ncomponents > 0 )
1029 assert( propdata->componentblocked !=
NULL );
1040 propdata->ncomponents = -1;
1041 propdata->ncompblocked = 0;
1045 if ( propdata->nperms > 0 )
1052 permlen = 2 * propdata->npermvars;
1054 permlen = propdata->npermvars;
1059 if ( propdata->perms !=
NULL )
1061 for (
i = 0;
i < propdata->nperms; ++
i)
1070 propdata->npermvars = 0;
1071 propdata->nbinpermvars = 0;
1072 propdata->nmaxperms = 0;
1073 propdata->nmovedpermvars = -1;
1074 propdata->nmovedbinpermvars = 0;
1075 propdata->nmovedintpermvars = 0;
1076 propdata->nmovedimplintpermvars = 0;
1077 propdata->nmovedcontpermvars = 0;
1078 propdata->nmovedvars = -1;
1079 propdata->log10groupsize = -1.0;
1080 propdata->binvaraffected =
FALSE;
1081 propdata->isnonlinvar =
NULL;
1083 propdata->nperms = -1;
1087 propdata->computedsymmetry =
FALSE;
1088 propdata->compressed =
FALSE;
1099 int* consarrsizeptr,
1108 assert( consarrsizereq > 0 );
1109 assert( *consarrsizeptr >= 0 );
1110 assert( (*consarrsizeptr == 0) == (*consarrptr ==
NULL) );
1113 if ( consarrsizereq <= *consarrsizeptr )
1118 assert( newsize > *consarrsizeptr );
1121 if ( *consarrptr ==
NULL )
1130 *consarrsizeptr = newsize;
1178 *binvaraffected =
FALSE;
1179 *compressed =
FALSE;
1185 int* labelmovedvars;
1186 int* labeltopermvaridx;
1187 int nbinvarsaffected = 0;
1198 labelmovedvars[
i] = -1;
1200 for (p = 0; p < nperms; ++p)
1202 if ( perms[p][
i] !=
i )
1204 labeltopermvaridx[*nmovedvars] =
i;
1205 labelmovedvars[
i] = (*nmovedvars)++;
1214 if ( nbinvarsaffected > 0 )
1215 *binvaraffected =
TRUE;
1219 if ( *nmovedvars > 0 &&
SCIPisLE(
scip, percentagemovedvars, compressthreshold) )
1222 for (p = 0; p < nperms; ++p)
1225 for (
i = 0;
i < *nmovedvars; ++
i)
1227 assert(
i <= labeltopermvaridx[
i] );
1228 if ( perms[p][labeltopermvaridx[
i]] >=
nvars )
1234 imgvaridx = perms[p][labeltopermvaridx[
i]] -
nvars;
1235 perms[p][
i] = labelmovedvars[imgvaridx] + *nmovedvars;
1237 assert( 0 <= perms[p][
i] && perms[p][
i] < 2 * (*nmovedvars) );
1240 perms[p][
i] = labelmovedvars[perms[p][labeltopermvaridx[
i]]];
1255 for (
i = 0;
i < *nmovedvars; ++
i)
1257 (*permvars)[
i] =
vars[labeltopermvaridx[
i]];
1259 *npermvars = *nmovedvars;
1260 *nbinpermvars = nbinvarsaffected;
1273 for (p = 0; p < nperms && ! *binvaraffected; ++p)
1275 if ( perms[p][
i] !=
i )
1278 *binvaraffected =
TRUE;
1287 for (
i = 0;
i < *npermvars; ++
i)
1292 (*permvardomaincenter)[
i] = 0.5 * (ub + lb);
1333 for (
c = 0;
c < nconshdlrs; ++
c)
1335 conshdlr = conshdlrs[
c];
1348 " Symmetry detection interrupted: constraints of type %s do not provide symmetry information.\n"
1349 " If symmetries shall be detected, implement the %s callback.\n",
1391 "Computed symmetries might be incorrect if the expression uses different constants or assigns\n"
1428 *nconsnodes = nconss;
1433 for (
c = 0;
c < nconss; ++
c)
1461 depth = (int) log2((
double) num);
1462 expval = (int) exp2((
double) (
depth + 1));
1463 numnodes =
MIN(expval, 100);
1465 *nopnodes += numnodes;
1466 *nvalnodes +=
MAX((
int) 0.1 * numnodes, 1);
1481 *nopnodes += num - 1;
1490 if (
nvars <= 100000 )
1491 *nedges = 100 *
nvars;
1492 else if (
nvars <= 1000000 )
1493 *nedges = 32 *
nvars;
1494 else if (
nvars <= 16700000 )
1495 *nedges = 16 *
nvars;
1497 *nedges = INT_MAX / 10;
1525#ifdef SCIP_DISPLAY_SYM_CHECK
1542 assert( nsymvars == npermvars );
1546 for (
c = 0;
c < nconss; ++
c)
1569 for (
c = 0;
c < nconss; ++
c)
1574 SCIPsort(graphperm, SYMsortSymgraphs, graphs, nconss);
1577 for (
c = 1;
c < nconss; ++
c)
1580 groupbegins[ngroups++] =
c;
1582 groupbegins[ngroups] = nconss;
1585 for (
c = 0;
c < nconss; ++
c)
1590#ifdef SCIP_DISPLAY_SYM_CHECK
1596 for (p = 0; p < nperms; ++p)
1601#ifdef SCIP_DISPLAY_SYM_CHECK
1605 for (
i = 0;
i < permlen; ++
i)
1610 for (
i = 0;
i < permlen; ++
i)
1616 for (g = 0; g < ngroups; ++g)
1618 for (
c = groupbegins[g];
c < groupbegins[g+1]; ++
c)
1620#ifdef SCIP_DISPLAY_SYM_CHECK
1631#ifdef SCIP_DISPLAY_SYM_CHECK
1640 for (d = groupbegins[g]; d < groupbegins[g+1] && ! found; ++d)
1644#ifdef SCIP_DISPLAY_SYM_CHECK
1655#ifdef SCIP_DISPLAY_SYM_CHECK
1665#ifdef SCIP_DISPLAY_SYM_CHECK
1672 for (
c = nconss - 1;
c >= 0; --
c)
1739 *binvaraffected =
FALSE;
1740 *compressed =
FALSE;
1741 *log10groupsize = 0;
1767 nopnodes, nvalnodes, nconsnodes, nedges) );
1770 for (
c = 0;
c < nconss && *success; ++
c)
1805 perms, log10groupsize, symcodetime) );
1807 if ( checksymmetries && *nperms > 0 )
1822 permvardomaincenter, *perms, *nperms, nmovedvars, binvaraffected,
1823 compresssymmetries, compressthreshold, compressed) );
1847 for (v = 0; v <
nvars; ++v)
1850 if ( symmetry[v] >=
nvars )
1877 int* componentbegins;
1884 assert( propdata->ncomponents > 0 );
1889 componentbegins = propdata->componentbegins;
1890 ncomponents = propdata->ncomponents;
1899 for (
c = 0;
c < ncomponents; ++
c)
1901 for (
i = componentbegins[
c];
i < componentbegins[
c + 1]; ++
i)
1905 propdata->componenthassignedperm[
c] =
TRUE;
1925 assert( propdata->nperms >= 0 );
1928 if ( propdata->ncomponents >= 0 )
1932 assert( propdata->ncomponents == -1 );
1937#ifdef SCIP_OUTPUT_COMPONENT
1942 propdata->permvars, propdata->npermvars,
FALSE, &propdata->components, &propdata->componentbegins,
1943 &propdata->vartocomponent, &propdata->componentblocked, &propdata->ncomponents) );
1945#ifdef SCIP_OUTPUT_COMPONENT
1951 assert( propdata->ncomponents > 0 );
1955 assert( propdata->componenthassignedperm !=
NULL );
1974 assert( propdata->nperms >= 0 );
1977 if ( propdata->permvarmap !=
NULL )
1984 for (v = 0; v < propdata->npermvars; ++v)
2007 assert( propdata->nperms >= 0 );
2010 if ( propdata->permstrans !=
NULL )
2016 for (v = 0; v < propdata->npermvars; ++v)
2019 for (p = 0; p < propdata->nperms; ++p)
2020 propdata->permstrans[v][p] = propdata->perms[p][v];
2041 assert( propdata->nperms >= 0 );
2044 if ( propdata->nmovedpermvars >= 0 )
2046 assert( propdata->nmovedpermvars == -1 );
2048 propdata->nmovedpermvars = 0;
2049 propdata->nmovedbinpermvars = 0;
2050 propdata->nmovedintpermvars = 0;
2051 propdata->nmovedimplintpermvars = 0;
2052 propdata->nmovedcontpermvars = 0;
2054 for (v = 0; v < propdata->npermvars; ++v)
2056 for (p = 0; p < propdata->nperms; ++p)
2058 if ( propdata->perms[p][v] != v )
2060 ++propdata->nmovedpermvars;
2065 ++propdata->nmovedbinpermvars;
2068 ++propdata->nmovedintpermvars;
2071 ++propdata->nmovedimplintpermvars;
2074 ++propdata->nmovedcontpermvars;
2097 if ( propdata->enforcecomputesymmetry )
2150 unsigned int type = 0;
2156 assert( propdata->usesymmetry >= 0 );
2170 " Deactivated symmetry handling methods, since SCIP was built without symmetry detector (SYM=none).\n");
2198 if ( ! (type & symspecrequire) )
2201 " (%.1fs) symmetry computation skipped: type (bin %c, int %c, cont %c) does not match requirements (bin %c, int %c, cont %c).\n",
2214 if ( propdata->computedsymmetry )
2217 assert( propdata->npermvars == 0 );
2219 assert( propdata->nperms < 0 );
2220 assert( propdata->nmaxperms == 0 );
2225 " (%.1fs) symmetry computation started: requiring (bin %c, int %c, cont %c), (fixed: bin %c, int %c, cont %c)\n",
2232 (symspecrequirefixed & (
int)
SYM_SPEC_REAL) != 0 ?
'+' :
'-');
2235 if ( symspecrequire & symspecrequirefixed )
2239 maxgenerators = propdata->maxgenerators;
2244 propdata->compresssymmetries, propdata->compressthreshold,
2245 maxgenerators, symspecrequirefixed, propdata->checksymmetries, &propdata->permvars,
2246 &propdata->npermvars, &propdata->nbinpermvars, &propdata->permvardomaincenter,
2247 &propdata->perms, &propdata->nperms, &propdata->nmaxperms,
2248 &propdata->nmovedvars, &propdata->binvaraffected, &propdata->compressed,
2249 &propdata->log10groupsize, &symcodetime, &successful) );
2252 propdata->computedsymmetry =
TRUE;
2267 if ( propdata->nperms == 0 )
2274 assert( propdata->nperms > 0 );
2275 assert( propdata->npermvars > 0 );
2282 if ( maxgenerators == 0 )
2290 if ( propdata->displaynorbitvars )
2292 if ( propdata->nmovedvars == -1 )
2295 propdata->npermvars, &(propdata->nmovedvars)) );
2302 for (
i = 0;
i < propdata->npermvars; ++
i)
2338 int** orbitopevaridx,
2352 int ntestedperms = 0;
2364 assert( nactiveperms > 0 );
2365 assert( ntwocycles > 0 );
2367 assert( activevars ==
NULL || (0 <= nactiveperms && nactiveperms < npermvars) );
2370 if ( nusedcols !=
NULL )
2379 while ( ! foundperm )
2383 assert( ntestedperms < nactiveperms );
2385 permidx = activeperms[ntestedperms];
2387 for (j = 0; j < npermvars; ++j)
2389 if ( activevars !=
NULL && ! activevars[j] )
2392 assert( activevars ==
NULL || activevars[perms[permidx][j]] );
2395 if ( perms[permidx][j] > j )
2400 rowisbinary[row] =
TRUE;
2402 orbitopevaridx[row][0] = j;
2403 orbitopevaridx[row++][1] = perms[permidx][j];
2405 ++(nusedelems[perms[permidx][j]]);
2410 if ( row == ntwocycles )
2418 if ( row != ntwocycles )
2420 *isorbitope =
FALSE;
2425 usedperm[ntestedperms - 1] =
TRUE;
2435 for (j = ntestedperms; j < nactiveperms; ++j)
2440 if ( nusedperms == nactiveperms )
2447 perms[activeperms[j]],
TRUE, &nusedelems, permvars,
NULL, &success, &infeasible) );
2451 *isorbitope =
FALSE;
2458 coltoextend = nfilledcols;
2459 columnorder[nfilledcols++] = -1;
2464 if ( ! *isorbitope )
2471 for (j = ntestedperms; j < nactiveperms; ++j)
2476 if ( nusedperms == nactiveperms )
2483 perms[activeperms[j]],
FALSE, &nusedelems, permvars,
NULL, &success, &infeasible) );
2487 *isorbitope =
FALSE;
2494 coltoextend = nfilledcols;
2495 columnorder[nfilledcols] = 1;
2501 if ( activevars ==
NULL && nusedperms < nactiveperms )
2502 *isorbitope =
FALSE;
2504 if ( nusedcols !=
NULL )
2505 *nusedcols = nfilledcols;
2506 assert( ! *isorbitope || activevars ==
NULL || nusedperms < nfilledcols );
2525 int* componentbegins;
2534 assert( compidx < propdata->ncomponents );
2538 assert( propdata->computedsymmetry );
2539 assert( propdata->nperms > 0 );
2541 assert( propdata->npermvars > 0 );
2542 assert( propdata->ncomponents > 0 );
2546 perms = propdata->perms;
2547 npermvars = propdata->npermvars;
2549 componentbegins = propdata->componentbegins;
2550 npermsincomp = componentbegins[compidx + 1] - componentbegins[compidx];
2551 *ntwocycleperms = npermsincomp;
2555 for (
i = 0;
i < npermsincomp; ++
i)
2560 perm = perms[
components[componentbegins[compidx] +
i]];
2565 if ( ntwocycles[
i] == 0 )
2568 if ( propdata->preferlessrows )
2569 ntwocycles[
i] = npermvars;
2572 --(*ntwocycleperms);
2574 else if ( ! propdata->preferlessrows )
2575 ntwocycles[
i] = - ntwocycles[
i];
2599 int** graphcomponents,
2600 int** graphcompbegins,
2601 int** compcolorbegins,
2602 int* ngraphcomponents,
2615 int* componentbegins;
2616 int* componentslastperm;
2634 assert( usedpermssize > 0 );
2636 assert( ntwocycleperms >= 0 );
2638 assert( compidx < propdata->ncomponents );
2639 assert( propdata->computedsymmetry );
2640 assert( propdata->nperms > 0 );
2642 assert( propdata->npermvars > 0 );
2643 assert( propdata->ncomponents > 0 );
2646 assert( ! propdata->componentblocked[compidx] );
2648 perms = propdata->perms;
2649 npermvars = propdata->npermvars;
2651 componentbegins = propdata->componentbegins;
2654 assert( ntwocycleperms <= componentbegins[compidx + 1] - componentbegins[compidx] );
2660 for (k = 0; k < npermvars; ++k)
2661 componentslastperm[k] = -1;
2663 for (j = 0; j < ntwocycleperms; ++j)
2666 int firstcolor = -1;
2669 perm = perms[
components[componentbegins[compidx] + genorder[j]]];
2673 for (k = 0; k < npermvars; ++k)
2682 assert( perm[img] == k );
2690 if ( comp1 == comp2 )
2693 if ( firstcolor < 0 )
2698 componentslastperm[comp1] = j;
2705 if ( componentslastperm[comp1] == j || componentslastperm[comp2] == j )
2712 if ( color1 == color2 )
2715 componentslastperm[comp1] = j;
2716 componentslastperm[comp2] = j;
2718 if ( firstcolor < 0 )
2719 firstcolor = color1;
2723 if ( k < npermvars )
2727 if ( firstcolor == -1 )
2731 if ( *nusedperms >= usedpermssize )
2734 assert( newsize > usedpermssize );
2738 usedpermssize = newsize;
2741 (*usedperms)[*nusedperms] =
components[componentbegins[compidx] + genorder[j]];
2743 permused[genorder[j]] =
TRUE;
2746 for (k = 0; k < npermvars; ++k)
2755 assert( perm[img] == k );
2764 if ( comp1 == comp2 )
2770 if ( color1 != color2 )
2794 for (j = 0; j < npermvars; ++j)
2803 (*graphcomponents)[j] = j;
2807 SCIPsort(*graphcomponents, SYMsortGraphCompVars, (
void*) &graphcompvartype, npermvars);
2816 (*graphcompbegins)[0] = 0;
2817 (*compcolorbegins)[0] = 0;
2820 for (j = 1; j < npermvars; ++j)
2825 idx1 = (*graphcomponents)[j];
2826 idx2 = (*graphcomponents)[j-1];
2832 (*graphcompbegins)[nextcomp] = j;
2834 if ( graphcompvartype.
colors[idx1] > graphcompvartype.
colors[idx2] )
2836 (*compcolorbegins)[nextcolor] = nextcomp;
2843 assert( nextcomp == *ngraphcomponents );
2844 assert( nextcolor == *ncompcolors );
2846 (*compcolorbegins)[nextcolor] = *ngraphcomponents;
2847 (*graphcompbegins)[nextcomp] = npermvars;
2865 int* compcolorbegins,
2866 int* graphcompbegins,
2867 int* graphcomponents,
2872 int* compidxfirstrow,
2875 int* maxnvarslexorder,
2883 int** orbitopevaridx;
2890 int nactivevars = 0;
2901 assert( nusedperms > 0 );
2915 for (k = 0; k < nrows; ++k)
2922 for (k = 0; k < ncols; ++k)
2923 columnorder[k] = ncols + 1;
2929 for (k = compcolorbegins[graphcoloridx]; k < compcolorbegins[graphcoloridx+1]; ++k)
2935 compstart = graphcompbegins[k];
2936 firstvar = propdata->permvars[graphcomponents[compstart]];
2941 for (l = 0; l < ncols; ++l)
2945 varidx = graphcomponents[compstart + l];
2954 assert( nactivevars == nrows * ncols );
2966 propdata->perms, usedperms, nrows, nusedperms, orbitopevaridx, columnorder,
2967 nusedelems, &ngencols,
NULL, &isorbitope, activevars) );
2976 for (k = nrows - 1; k >= 0; --k)
2996 if ( firstvaridx !=
NULL )
2998 if ( columnorder[ngencols-1] > -1 )
2999 *firstvaridx = orbitopevaridx[0][ngencols-1];
3001 *firstvaridx = orbitopevaridx[0][1];
3005 if ( compidxfirstrow !=
NULL && firstvaridx !=
NULL )
3007 *compidxfirstrow = -1;
3009 for (k = compcolorbegins[graphcoloridx]; k < compcolorbegins[graphcoloridx+1] && (*compidxfirstrow) < 0; ++k)
3015 compstart = graphcompbegins[k];
3016 firstvar = propdata->permvars[graphcomponents[compstart]];
3024 for (l = 0; l < ncols; ++l)
3026 if ( graphcomponents[compstart + l] == *firstvaridx )
3028 *compidxfirstrow = k;
3033 assert( *compidxfirstrow > -1 );
3038 for (k = 0; k < nrows; ++k)
3045 propdata->permvars, propdata->npermvars, orbitopevaridx, columnorder,
3046 nusedelems,
NULL, &infeasible,
TRUE, lexorder, nvarslexorder, maxnvarslexorder) );
3049 assert( firstvaridx ==
NULL || propdata->permvars[*firstvaridx] == orbitopevarmatrix[0][0] );
3062 &propdata->genorbconsssize, propdata->ngenorbconss + 1) );
3063 propdata->genorbconss[propdata->ngenorbconss++] = cons;
3064 ++propdata->norbitopes;
3066 for (k = nrows - 1; k >= 0; --k)
3071 for (k = nrows - 1; k >= 0; --k)
3084 int* graphcompbegins,
3085 int* graphcomponents,
3099 assert( graphcompidx >= 0 );
3100 assert( ! storelexorder || lexorder !=
NULL );
3101 assert( ! storelexorder || nvarsorder !=
NULL );
3102 assert( ! storelexorder || maxnvarsorder !=
NULL );
3105 if ( storelexorder )
3107 if ( *maxnvarsorder == 0 )
3109 *maxnvarsorder = graphcompbegins[graphcompidx + 1] - graphcompbegins[graphcompidx];
3116 assert( *nvarsorder == *maxnvarsorder );
3118 *maxnvarsorder += graphcompbegins[graphcompidx + 1] - graphcompbegins[graphcompidx];
3123 (*lexorder)[*nvarsorder++] = graphcomponents[graphcompbegins[graphcompidx]];
3127 for (k = graphcompbegins[graphcompidx]+1; k < graphcompbegins[graphcompidx+1]; ++k)
3134 vars[0] = propdata->permvars[graphcomponents[k-1]];
3135 vars[1] = propdata->permvars[graphcomponents[k]];
3137 if ( storelexorder )
3138 (*lexorder)[*nvarsorder++] = graphcomponents[k];
3148#ifdef SCIP_MORE_DEBUG
3155 &propdata->genlinconsssize, propdata->ngenlinconss + 1) );
3156 propdata->genlinconss[propdata->ngenlinconss] = cons;
3157 ++propdata->ngenlinconss;
3168 int* compcolorbegins,
3169 int* graphcompbegins,
3170 int* graphcomponents,
3172 int* chosencomppercolor,
3173 int* firstvaridxpercolor,
3188 int orbitsize[2] = {1, 1};
3190 int chosencolor = -1;
3202 assert( symgrpcompidx >= 0 );
3203 assert( symgrpcompidx < propdata->ncomponents );
3204 assert( ! storelexorder || lexorder !=
NULL );
3205 assert( ! storelexorder || nvarsorder !=
NULL );
3206 assert( ! storelexorder || maxnvarsorder !=
NULL );
3216 if ( lexorder ==
NULL || *lexorder ==
NULL )
3219 varsinlexorder =
NULL;
3223 assert( *maxnvarsorder >= 0 );
3224 assert( *nvarsorder >= 0 );
3228 for (k = 0; k < *nvarsorder; ++k)
3232 assert((*lexorder)[k] >= 0);
3240 if ( ncompcolors > 0 )
3244 for (j = 0; j < ncompcolors; ++j)
3251 if ( chosencomppercolor[j] < 0 )
3254 assert( firstvaridxpercolor[j] >= 0 );
3256 graphcomp = chosencomppercolor[j];
3257 graphcompsize = graphcompbegins[graphcomp+1] - graphcompbegins[graphcomp];
3258 varidx = firstvaridxpercolor[j];
3263 if ( varfound[
varidx] || graphcompsize == propdata->npermvars )
3267 if ( varsinlexorder !=
NULL
3269 && lexorder !=
NULL && *lexorder !=
NULL && *maxnvarsorder > 0 && *nvarsorder > 0
3270 && (*lexorder)[0] !=
varidx )
3274 for (k = graphcompbegins[graphcomp]; k < graphcompbegins[graphcomp+1]; ++k)
3276 assert( 0 <= graphcomponents[k] && graphcomponents[k] < propdata->npermvars );
3278 usedvars[graphcomponents[k]] =
TRUE;
3282 propdata->permstrans, propdata->components, propdata->componentbegins,
3283 usedvars, varfound,
varidx, symgrpcompidx,
3284 orbit[activeorb], &orbitsize[activeorb]) );
3288 if ( orbitsize[activeorb] > orbitsize[1 - activeorb] )
3291 activeorb = 1 - activeorb;
3296 for (k = graphcompbegins[graphcomp]; k < graphcompbegins[graphcomp+1]; ++k)
3297 usedvars[graphcomponents[k]] =
FALSE;
3301 if ( chosencolor > -1 )
3304 activeorb = 1 - activeorb;
3306 assert( orbit[activeorb][0] == firstvaridxpercolor[chosencolor] );
3307 vars[0] = propdata->permvars[orbit[activeorb][0]];
3309 assert( chosencolor > -1 );
3310 SCIPdebugMsg(
scip,
" adding %d weak sbcs for enclosing orbit of color %d.\n", orbitsize[activeorb]-1, chosencolor);
3312 *naddedconss = orbitsize[activeorb] - 1;
3315 for (j = 1; j < orbitsize[activeorb]; ++j)
3320 vars[1] = propdata->permvars[orbit[activeorb][j]];
3330#ifdef SCIP_MORE_DEBUG
3337 &propdata->genlinconsssize, propdata->ngenlinconss + 1) );
3338 propdata->genlinconss[propdata->ngenlinconss] = cons;
3339 ++propdata->ngenlinconss;
3343 if ( storelexorder )
3347 varidx = orbit[activeorb][0];
3350 if ( *maxnvarsorder == 0 )
3356 (*lexorder)[(*nvarsorder)++] =
varidx;
3360 assert( *nvarsorder == *maxnvarsorder );
3366 if (
varidx == (*lexorder)[0] )
3383 for (k = *maxnvarsorder - 1; k >= 1; --k)
3384 (*lexorder)[k] = (*lexorder)[k - 1];
3396 if ( varsinlexorder !=
NULL )
3410 int** modifiedperms,
3441 for (
i = 0;
i < npermvars; ++
i)
3446 for (
i = 0;
i < npermvars; ++
i)
3447 posinpermvar[
i] =
i;
3451 for (l = 0; l < nleaders; ++l)
3453 leader = leaders[l];
3454 curposleader = posinpermvar[leader];
3455 varidx = permvaridx[curposleader];
3456 lidx = permvaridx[l];
3459 permvaridx[curposleader] = lidx;
3463 posinpermvar[lidx] = curposleader;
3464 posinpermvar[leader] = l;
3468 for (
i = 0;
i < npermvars; ++
i)
3469 modifiedpermvars[
i] = origpermvars[permvaridx[
i]];
3472 for (p = 0; p < nperms; ++p)
3474 for (
i = 0;
i < npermvars; ++
i)
3475 modifiedperms[p][
i] = posinpermvar[origperms[p][permvaridx[
i]]];
3491 int* graphcomponents,
3492 int* graphcompbegins,
3493 int* compcolorbegins,
3505 assert( ncompcolors >= 0 );
3506 assert( symcompsize > 0 );
3508 for (j = 0; j < ncompcolors; ++j)
3511 int largestcompsize = 0;
3516 if ( graphcompbegins[compcolorbegins[j+1]] - graphcompbegins[compcolorbegins[j]] < 2 )
3520 for (k = compcolorbegins[j]; k < compcolorbegins[j+1]; ++k)
3524 compsize = graphcompbegins[k+1] - graphcompbegins[k];
3527 if ( largestcompsize < 1 )
3532 largestcompsize = compsize;
3534 else if ( compsize != largestcompsize )
3537 firstvar = permvars[graphcomponents[graphcompbegins[k]]];
3545 if ( k == compcolorbegins[j+1] )
3551 ncols = graphcompbegins[compcolorbegins[j] + 1] - graphcompbegins[compcolorbegins[j]];
3553 threshold = 0.7 * (
SCIP_Real) symcompsize;
3556 if ( nbinrows <= 2 * ncols || (nbinrows <= 8 * ncols && nbinrows < 100) )
3557 multorbitopecriterion =
TRUE;
3558 else if ( nbinrows <= 3 * ncols || (
SCIP_Real) nbinrows * ncols >= threshold )
3559 oneorbitopecriterion =
TRUE;
3563 if ( (norbitopes == 1 && oneorbitopecriterion) || (norbitopes >= 2 && multorbitopecriterion) )
3582 int nstrongsbcs = 0;
3585 int** modifiedperms;
3587 int* nvarsincomponent;
3589 int* graphcomponents;
3590 int* graphcompbegins;
3591 int* compcolorbegins;
3592 int* chosencomppercolor =
NULL;
3593 int* firstvaridxpercolor =
NULL;
3596 int ngraphcomponents;
3601 int ntrivialcolors = 0;
3603 int* lexorder =
NULL;
3604 int nvarslexorder = 0;
3605 int maxnvarslexorder = 0;
3609 int norbitopesincomp;
3613 assert( propdata->computedsymmetry );
3614 assert( propdata->nperms >= 0 );
3615 assert( 0 <= cidx && cidx < propdata->ncomponents );
3620 if ( propdata->nperms == 0 || propdata->componentblocked[cidx] )
3627 assert( propdata->nperms > 0 );
3629 assert( propdata->npermvars > 0 );
3637 for (p = 0; p < propdata->nperms; ++p)
3644 for (p = 0; p < propdata->npermvars; ++p)
3646 if ( propdata->vartocomponent[p] >= 0 )
3647 ++nvarsincomponent[propdata->vartocomponent[p]];
3650 SCIPdebugMsg(
scip,
"starting subgroup detection routine for component %d\n", cidx);
3652 npermsincomp = propdata->componentbegins[cidx + 1] - propdata->componentbegins[cidx];
3655 for (j = 0; j < npermsincomp; ++j)
3660 assert( ntwocycleperms >= 0 );
3661 assert( ntwocycleperms <= npermsincomp );
3663 SCIPdebugMsg(
scip,
"component %d has %d permutations consisting of 2-cycles\n", cidx, ntwocycleperms);
3665#ifdef SCIP_MORE_DEBUG
3671 for (p = propdata->componentbegins[cidx]; p < propdata->componentbegins[cidx+1]; ++p)
3675 perm = propdata->components[p];
3677 for (k = 0; k < propdata->npermvars; ++k)
3682 for (k = 0; k < propdata->npermvars; ++k)
3687 j = propdata->perms[perm][k];
3699 j = propdata->perms[perm][j];
3709 if ( ntwocycleperms < 2 )
3715 usedpermssize = ntwocycleperms / 2;
3720 &graphcomponents, &graphcompbegins, &compcolorbegins, &ngraphcomponents,
3721 &ncompcolors, &usedperms, &nusedperms, usedpermssize, permused) );
3723 SCIPdebugMsg(
scip,
" created subgroup detection graph using %d of the permutations\n", nusedperms);
3725 if ( nusedperms == npermsincomp )
3726 allpermsused =
TRUE;
3731 assert( ngraphcomponents > 0 );
3732 assert( ncompcolors > 0 );
3733 assert( nusedperms <= ntwocycleperms );
3734 assert( ncompcolors < propdata->npermvars );
3736 if ( nusedperms == 0 )
3738 SCIPdebugMsg(
scip,
" -> skipping component, since less no permutation was used\n");
3746 SCIPdebugMsg(
scip,
" number of different colors in the graph: %d\n", ncompcolors);
3748 if ( propdata->addstrongsbcs || propdata->addweaksbcs )
3757 for (j = 0; j < ncompcolors; ++j)
3759 chosencomppercolor[j] = -1;
3760 firstvaridxpercolor[j] = -1;
3764 norbitopesincomp =
getNOrbitopesInComp(propdata->permvars, graphcomponents, graphcompbegins, compcolorbegins,
3765 ncompcolors, nvarsincomponent[cidx]);
3768 if ( norbitopesincomp == 1 )
3772 for (k = 0; k < npermsincomp; ++k)
3780 propdata->perms[propdata->components[propdata->componentbegins[cidx] + k]],
3781 propdata->permvars, propdata->npermvars,
FALSE,
3787 &propdata->genorbconsssize, propdata->ngenorbconss + 1) );
3788 propdata->genorbconss[propdata->ngenorbconss++] = cons;
3789 ++propdata->nsymresacks;
3791 if ( ! propdata->componentblocked[cidx] )
3794 ++propdata->ncompblocked;
3797 SCIPdebugMsg(
scip,
" add symresack for permutation %d of component %d\n", k, cidx);
3803 for (j = 0; j < ncompcolors; ++j)
3805 int nbinarycomps = 0;
3806 int largestcolorcomp = -1;
3807 int largestcompsize = 0;
3819 if ( graphcompbegins[compcolorbegins[j+1]] - graphcompbegins[compcolorbegins[j]] < 2 )
3821 if( chosencomppercolor !=
NULL )
3822 chosencomppercolor[j] = -1;
3828 SCIPdebugMsg(
scip,
" color %d has %d components with overall %d variables\n", j, compcolorbegins[j+1] - compcolorbegins[j],
3829 graphcompbegins[compcolorbegins[j+1]] - graphcompbegins[compcolorbegins[j]]);
3832 for (k = compcolorbegins[j]; k < compcolorbegins[j+1]; ++k)
3837 compsize = graphcompbegins[k+1] - graphcompbegins[k];
3840 if ( largestcompsize < 1 )
3848 largestcompsize = compsize;
3849 largestcolorcomp = k;
3851 else if ( compsize != largestcompsize )
3858 firstvar = propdata->permvars[graphcomponents[graphcompbegins[k]]];
3866 for (k = compcolorbegins[j]; k < compcolorbegins[j+1]; ++k)
3870 firstvar = propdata->permvars[graphcomponents[graphcompbegins[k]]];
3877 contaffected =
TRUE;
3880 SCIPdebugMsg(
scip,
" affected types (bin,int,cont): (%d,%d,%d)\n", binaffected, intaffected, contaffected);
3884 useorbitope =
FALSE;
3885 if ( norbitopesincomp > 0 && nbinarycomps > 0 )
3888 if ( isorbitope && useorbitope )
3893 SCIPdebugMsg(
scip,
" detected an orbitope with %d rows and %d columns\n", nbinarycomps, largestcompsize);
3895 assert( nbinarycomps > 0 );
3896 assert( largestcompsize > 2 );
3904 graphcompbegins, graphcomponents, j, nbinarycomps, largestcompsize, &firstvaridx, &chosencomp,
3905 &lexorder, &nvarslexorder, &maxnvarslexorder, allpermsused, &orbitopeadded) );
3907 if ( orbitopeadded )
3909 if ( propdata->addstrongsbcs || propdata->addweaksbcs )
3915 assert( compcolorbegins[j] <= chosencomp && chosencomp < compcolorbegins[j+1] );
3916 assert( 0 <= firstvaridx && firstvaridx < propdata->npermvars );
3918 chosencomppercolor[j] = chosencomp;
3919 firstvaridxpercolor[j] = firstvaridx;
3922 if ( ! propdata->componentblocked[cidx] )
3925 ++propdata->ncompblocked;
3935 if ( propdata->addstrongsbcs && ! orbitopeadded )
3937 assert( largestcolorcomp >= 0 );
3938 assert( largestcolorcomp < ngraphcomponents );
3939 assert( largestcompsize > 0 );
3941 if( propdata->addweaksbcs )
3946 chosencomppercolor[j] = largestcolorcomp;
3947 firstvaridxpercolor[j] = graphcomponents[graphcompbegins[largestcolorcomp]];
3950 SCIPdebugMsg(
scip,
" choosing component %d with %d variables and adding strong SBCs\n",
3951 largestcolorcomp, graphcompbegins[largestcolorcomp+1] - graphcompbegins[largestcolorcomp]);
3955 propdata->addsymresacks, &lexorder, &nvarslexorder, &maxnvarslexorder) );
3958 if ( !
SCIPvarIsBinary(propdata->permvars[graphcomponents[graphcompbegins[largestcolorcomp]]]) )
3959 handlednonbinarysymmetry =
TRUE;
3961 if ( ! propdata->componentblocked[cidx] )
3964 ++propdata->ncompblocked;
3968 nstrongsbcs += graphcompbegins[largestcolorcomp+1] - graphcompbegins[largestcolorcomp] - 1;
3971 else if ( ! orbitopeadded )
3976 if ( propdata->addweaksbcs )
3979 chosencomppercolor[j] = -1;
3987 if ( propdata->addweaksbcs && propdata->componentblocked[cidx] && nusedperms < npermsincomp )
3995 graphcomponents, ncompcolors, chosencomppercolor, firstvaridxpercolor,
3996 cidx, &naddedconss, propdata->addsymresacks, &lexorder, &nvarslexorder, &maxnvarslexorder) );
3998 assert( naddedconss < propdata->npermvars );
4001 nweaksbcs += naddedconss;
4005 SCIPdebugMsg(
scip,
" don't add weak sbcs because all generators were used or the settings forbid it\n");
4010 if ( nvarslexorder > 0 && propdata->addsymresacks && ! handlednonbinarysymmetry )
4015 propdata->permvars, modifiedpermvars, propdata->npermvars, lexorder, nvarslexorder) );
4017 for (k = 0; k < npermsincomp; ++k)
4029 symresackperm = modifiedperms[propdata->components[propdata->componentbegins[cidx] + k]];
4030 for (j = 0; j < propdata->nperms && !actsonbinary; ++j)
4033 actsonbinary =
TRUE;
4036 if ( ! actsonbinary )
4042 symresackperm, modifiedpermvars, propdata->npermvars,
FALSE,
4048 &propdata->genorbconsssize, propdata->ngenorbconss + 1) );
4049 propdata->genorbconss[propdata->ngenorbconss++] = cons;
4050 ++propdata->nsymresacks;
4052 if ( ! propdata->componentblocked[cidx] )
4055 ++propdata->ncompblocked;
4058 SCIPdebugMsg(
scip,
" add symresack for permutation %d of component %d adapted to suborbitope lexorder\n", k, cidx);
4074 SCIPdebugMsg(
scip,
"total number of added (sub-)orbitopes: %d\n", norbitopes);
4075 SCIPdebugMsg(
scip,
"total number of added strong sbcs: %d\n", nstrongsbcs);
4083 for (p = propdata->nperms - 1; p >= 0; --p)
4120 assert( nconflictvars > 0 );
4126 for (
i = 0;
i < nconflictvars; ++
i)
4129 varconflicts[
i].orbitidx = -1;
4130 varconflicts[
i].nconflictinorbit = 0;
4131 varconflicts[
i].orbitsize = -1;
4132 varconflicts[
i].posinorbit = -1;
4136 for (
r = 0;
r < norbits; ++
r)
4141 orbitsize = orbitbegins[
r + 1] - orbitbegins[
r];
4142 assert( orbitsize >= 0 );
4144 for (
i = orbitbegins[
r];
i < orbitbegins[
r + 1]; ++
i)
4150 assert( pos < nconflictvars );
4151 assert( varconflicts[pos].
var == conflictvars[pos] );
4153 varconflicts[pos].orbitidx =
r;
4154 varconflicts[pos].nconflictinorbit = 0;
4155 varconflicts[pos].orbitsize = orbitsize;
4156 varconflicts[pos].posinorbit = posinorbit++;
4166 for (
i = orbitbegins[
r];
i < orbitbegins[
r + 1]; ++
i)
4169 assert( varconflicts[ii].orbitidx ==
r );
4172 if ( ! varconflicts[ii].
active )
4175 for (j =
i + 1; j < orbitbegins[
r + 1]; ++j)
4178 assert( varconflicts[jj].orbitidx ==
r );
4181 if ( ! varconflicts[jj].
active )
4191 varconflicts[ii].ncliques, (
void**)varconflicts[jj].cliques, varconflicts[jj].ncliques,
4192 sortByPointerValue) )
4195 ++varconflicts[ii].nconflictinorbit;
4196 ++varconflicts[jj].nconflictinorbit;
4233 int varncliques = 0;
4239 assert( nconflictvars > 0 );
4242 *varconflicts =
NULL;
4248 if ( ncliques == 0 )
4250 SCIPdebugMsg(
scip,
"No cliques present --> construction of conflict structure aborted.\n");
4257 for (
i = 0;
i < nconflictvars; ++
i)
4259 (*varconflicts)[
i].ncliques = 0;
4260 (*varconflicts)[
i].active =
TRUE;
4261 (*varconflicts)[
i].var = conflictvars[
i];
4263 (*varconflicts)[
i].cliques =
NULL;
4264 (*varconflicts)[
i].orbitidx = -1;
4265 (*varconflicts)[
i].nconflictinorbit = 0;
4266 (*varconflicts)[
i].orbitsize = -1;
4267 (*varconflicts)[
i].posinorbit = -1;
4277 for (
c = 0;
c < ncliques; ++
c)
4279 clique = cliques[
c];
4285 assert( ncliquevars > 0 );
4291 for (
i = 0;
i < ncliquevars; ++
i)
4296 if ( node == INT_MAX )
4299 assert( node < nconflictvars );
4301 assert( (*varconflicts)[node].
var == cliquevars[
i] );
4302 (*varconflicts)[node].active =
TRUE;
4303 (*varconflicts)[node].ncliques++;
4308 for (
i = 0;
i < nconflictvars; ++
i)
4310 assert( (*varconflicts)[
i].ncliques >= 0 );
4312 if ( (*varconflicts)[
i].ncliques > 0 )
4320 for (
c = 0;
c < ncliques; ++
c)
4322 clique = cliques[
c];
4328 assert( ncliquevars > 0 );
4334 for (
i = 0;
i < ncliquevars; ++
i)
4339 if ( node == INT_MAX )
4343 assert( node < nconflictvars );
4344 assert( (*varconflicts)[node].
var == cliquevars[
i] );
4347 assert( tmpncliques[node] < (*varconflicts)[node].ncliques );
4348 assert( (*varconflicts)[node].cliques !=
NULL );
4349 (*varconflicts)[node].cliques[tmpncliques[node]++] = clique;
4358 for (
i = 0;
i < nconflictvars; ++
i)
4360 SCIPsortPtr((
void**)(*varconflicts)[
i].cliques, sortByPointerValue, (*varconflicts)[
i].ncliques);
4364 for (
i = 0;
i < nconflictvars; ++
i)
4366 assert( tmpncliques[
i] == (*varconflicts)[
i].ncliques );
4373 SCIPdebugMsg(
scip,
"Construction of conflict graph terminated; %d variable-clique combinations detected.\n",
4398 n = (*varconflicts)[
i].ncliques;
4416 int* componentbegins;
4419 int** modifiedperms =
NULL;
4422 int nsymresackcons = 0;
4430 assert( propdata->npermvars >= 0 );
4431 assert( propdata->nbinpermvars >= 0 );
4434 if ( propdata->nbinpermvars == 0 )
4436 assert( propdata->binvaraffected == 0 );
4440 perms = propdata->perms;
4441 nperms = propdata->nperms;
4442 permvars = propdata->permvars;
4443 npermvars = propdata->npermvars;
4444 conssaddlp = propdata->conssaddlp;
4446 componentbegins = propdata->componentbegins;
4453 assert( 0 <= cidx && cidx < propdata->ncomponents );
4468 if ( propdata->componenthassignedperm[cidx] )
4472 if ( propdata->nleaders > 0 &&
ISSSTBINACTIVE(propdata->sstleadervartype) )
4475 for (p = 0; p < nperms; ++p)
4481 for (
i = 0;
i < npermvars; ++
i)
4482 modifiedpermvars[
i] = permvars[
i];
4485 propdata->leaders, propdata->nleaders) );
4489 for (p = componentbegins[cidx]; p < componentbegins[cidx + 1]; ++p)
4500 if ( propdata->nleaders > 0 &&
ISSSTBINACTIVE(propdata->sstleadervartype) )
4519 &propdata->genorbconsssize, propdata->ngenorbconss + 1) );
4520 propdata->genorbconss[propdata->ngenorbconss++] = cons;
4521 ++propdata->nsymresacks;
4525 if ( propdata->nleaders > 0 &&
ISSSTBINACTIVE(propdata->sstleadervartype) )
4531 for (p = nperms - 1; p >= 0; --p)
4556 int norbitvarinconflict,
4580 assert( orbitleaderidx >= 0 );
4582 assert( norbitvarinconflict >= 0 );
4585 orbitsize = orbitbegins[orbitidx + 1] - orbitbegins[orbitidx];
4588 if ( propdata->sstaddcuts )
4592 addcuts = propdata->addconflictcuts;
4595 ncuts = orbitsize - norbitvarinconflict - 1;
4600 if ( propdata->nsstconss == 0 )
4603 assert( propdata->maxnsstconss == 0 );
4604 propdata->maxnsstconss = 2 * ncuts;
4607 else if ( propdata->nsstconss + ncuts > propdata->maxnsstconss )
4613 propdata->maxnsstconss, newsize) );
4614 propdata->maxnsstconss = newsize;
4618 if ( propdata->nleaders == 0 )
4620 propdata->maxnleaders =
MIN(propdata->nperms, propdata->npermvars);
4623 assert( propdata->nleaders < propdata->maxnleaders );
4626 posleader = orbitbegins[orbitidx] + orbitleaderidx;
4627 vars[0] = permvars[orbits[posleader]];
4630 propdata->leaders[propdata->nleaders++] = orbits[posleader];
4632 for (
i = 0, poscur = orbitbegins[orbitidx];
i < orbitsize; ++
i, ++poscur)
4634 if (
i == orbitleaderidx )
4636 assert( orbitvarinconflict ==
NULL || ! orbitvarinconflict[
i] );
4640 vars[1] = permvars[orbits[poscur]];
4642 for (j = 0; j < propdata->nleaders - 1; ++j)
4644 assert( propdata->leaders[j] != orbits[poscur] );
4649 if ( varconflicts !=
NULL )
4651 if ( orbitvarinconflict[
i] )
4665 varconflicts[orbits[poscur]].active =
FALSE;
4669 orbitvarinconflict[
i] =
FALSE;
4678 propdata->sstconss[propdata->nsstconss++] = cons;
4688 propdata->sstconss[propdata->nsstconss++] = cons;
4712 int* norbitvarinconflict,
4718 int curcriterion = INT_MIN;
4725 assert( nconflictvars > 0 );
4737 *norbitvarinconflict = 0;
4748 orbitcriterion = INT_MIN;
4751 for (
i = 0;
i < norbits; ++
i)
4755 if (
SCIPvarGetType(conflictvars[orbits[orbitbegins[
i]]]) != leadervartype )
4759 curcriterion = orbitbegins[
i] - orbitbegins[
i + 1];
4761 curcriterion = orbitbegins[
i + 1] - orbitbegins[
i];
4771 cnt = orbitbegins[
i];
4783 cnt = orbitbegins[
i + 1] - 1;
4798 curcriterion = varconflicts[
varidx].nconflictinorbit;
4802 if ( curcriterion > orbitcriterion )
4804 orbitcriterion = curcriterion;
4811 *leaderidx = orbitbegins[
i + 1] - orbitbegins[
i] - 1;
4816 if ( *success && varconflicts !=
NULL )
4818 leader = orbits[orbitbegins[*orbitidx] + *leaderidx];
4819 assert( leader < nconflictvars );
4822 && varconflicts[leader].ncliques > 0 )
4829 orbitsize = orbitbegins[*orbitidx + 1] - orbitbegins[*orbitidx];
4831 assert( leader >= 0 && leader < nconflictvars );
4835 for (
i = 0;
i < orbitsize; ++
i)
4838 if (
i == *leaderidx )
4842 varmapid = orbits[orbitbegins[*orbitidx] +
i];
4845 if ( ! varconflicts[varmapid].
active )
4850 varconflicts[leader].ncliques, (
void**)varconflicts[varmapid].cliques,
4851 varconflicts[varmapid].ncliques, sortByPointerValue) )
4854 orbitvarinconflict[
i] =
TRUE;
4855 ++(*norbitvarinconflict);
4872 for (
i = 0;
i < nconflictvars; ++
i)
4880 if ( varconflicts[
i].orbitidx == -1 )
4883 curcriterion = varconflicts[
i].nconflictinorbit;
4885 if ( curcriterion > orbitcriterion )
4887 orbitcriterion = curcriterion;
4888 *orbitidx = varconflicts[
i].orbitidx;
4889 *leaderidx = varconflicts[
i].posinorbit;
4895 leader = orbits[orbitbegins[*orbitidx] + *leaderidx];
4896 assert( leader < nconflictvars );
4899 if ( *success && varconflicts[leader].ncliques > 0 )
4904 orbitsize = orbitbegins[*orbitidx + 1] - orbitbegins[*orbitidx];
4906 assert( leader >= 0 && leader < nconflictvars );
4910 for (
i = 0;
i < orbitsize; ++
i)
4913 if (
i == *leaderidx )
4917 varmapid = orbits[orbitbegins[*orbitidx] +
i];
4919 if ( ! varconflicts[varmapid].
active )
4924 varconflicts[leader].ncliques, (
void**)varconflicts[varmapid].cliques,
4925 varconflicts[varmapid].ncliques, sortByPointerValue) )
4928 orbitvarinconflict[
i] =
TRUE;
4929 ++(*norbitvarinconflict);
4955 int nmovedbinpermvars;
4956 int nmovedintpermvars;
4957 int nmovedimplintpermvars;
4958 int nmovedcontpermvars;
4965 int* componentbegins;
4966 int* vartocomponent;
4968 unsigned* componentblocked;
4973 int norbitvarinconflict;
4981 int nvarsselectedtype;
4984 int norbitleadercomponent;
4995 assert( propdata->computedsymmetry );
4997 permvars = propdata->permvars;
4998 npermvars = propdata->npermvars;
4999 nperms = propdata->nperms;
5005 permvarmap = propdata->permvarmap;
5009 permstrans = propdata->permstrans;
5013 componentbegins = propdata->componentbegins;
5014 componentblocked = propdata->componentblocked;
5015 vartocomponent = propdata->vartocomponent;
5016 ncomponents = propdata->ncomponents;
5022 assert( ncomponents > 0 );
5023 assert( 0 <= cidx && cidx < ncomponents );
5026 if ( componentblocked[cidx] )
5030 if ( propdata->componenthassignedperm[cidx] )
5033 leaderrule = propdata->sstleaderrule;
5034 tiebreakrule = propdata->ssttiebreakrule;
5035 leadervartype = propdata->sstleadervartype;
5036 mixedcomponents = propdata->sstmixedcomponents;
5040 nmovedpermvars = propdata->nmovedpermvars;
5041 nmovedbinpermvars = propdata->nmovedbinpermvars;
5042 nmovedintpermvars = propdata->nmovedintpermvars;
5043 nmovedimplintpermvars = propdata->nmovedimplintpermvars;
5044 nmovedcontpermvars = propdata->nmovedcontpermvars;
5045 assert( nmovedpermvars > 0 );
5048 nvarsselectedtype = 0;
5049 if (
ISSSTBINACTIVE(leadervartype) && nmovedbinpermvars > nvarsselectedtype )
5052 nvarsselectedtype = nmovedbinpermvars;
5055 if (
ISSSTINTACTIVE(leadervartype) && nmovedintpermvars > nvarsselectedtype )
5058 nvarsselectedtype = nmovedintpermvars;
5061 if (
ISSSTIMPLINTACTIVE(leadervartype) && nmovedimplintpermvars > nvarsselectedtype )
5064 nvarsselectedtype = nmovedimplintpermvars;
5067 if (
ISSSTCONTACTIVE(leadervartype) && nmovedcontpermvars > nvarsselectedtype )
5070 nvarsselectedtype = nmovedcontpermvars;
5074 if ( nvarsselectedtype == 0 )
5078 if ( onlywithcontvars )
5080 for (p = componentbegins[cidx]; p < componentbegins[cidx + 1]; ++p)
5082 perm = propdata->perms[p];
5083 for (
i = 0;
i < propdata->npermvars; ++
i)
5105 conflictgraphcreated = varconflicts !=
NULL;
5113 if ( conflictgraphcreated )
5118 SCIPdebugMsg(
scip,
"Start selection of orbits and leaders for Schreier Sims constraints.\n");
5121 if ( nchgbds !=
NULL )
5125 for (
c = 0;
c < ncomponents; ++
c)
5127 for (p = componentbegins[
c]; p < componentbegins[
c + 1]; ++p)
5135 ninactiveperms = nperms - componentbegins[cidx + 1] + componentbegins[cidx];
5138 norbitleadercomponent = 0;
5139 while ( ninactiveperms < nperms )
5145 orbits, orbitbegins, &norbits,
components, componentbegins, vartocomponent,
5146 componentblocked, ncomponents, nmovedpermvars) );
5149 if ( ! mixedcomponents )
5151 for (p = 0; p < norbits; ++p)
5154 if (
SCIPvarGetType(permvars[orbits[orbitbegins[p]]]) != selectedtype )
5166 if ( conflictgraphcreated )
5184 norbits, propdata->sstleaderrule, propdata->ssttiebreakrule, selectedtype, &orbitidx, &orbitleaderidx,
5185 orbitvarinconflict, &norbitvarinconflict, &success) );
5190 assert( 0 <= orbitidx && orbitidx < norbits );
5191 assert( 0 <= orbitleaderidx && orbitleaderidx < orbitbegins[orbitidx + 1] - orbitbegins[orbitidx] );
5192 SCIPdebugMsg(
scip,
"%d\t\t%d\t\t%d\n", orbitidx, orbitleaderidx, orbitbegins[orbitidx + 1] - orbitbegins[orbitidx]);
5196 orbits, orbitbegins, orbitidx, orbitleaderidx, orbitvarinconflict, norbitvarinconflict, &nchanges) );
5198 ++norbitleadercomponent;
5200 if ( nchgbds !=
NULL )
5201 *nchgbds += nchanges;
5204 posleader = orbits[orbitbegins[orbitidx] + orbitleaderidx];
5205 for (p = 0; p < nperms; ++p)
5207 if ( inactiveperms[p] )
5210 if ( permstrans[posleader][p] != posleader )
5212 inactiveperms[p] =
TRUE;
5219 if ( norbitleadercomponent > 0 )
5222 if ( conflictgraphcreated )
5228 if ( varconflicts !=
NULL )
5263 assert( propdata->usedynamicprop );
5281 &propdata->genlinconsssize, propdata->ngenlinconss + ncols - 1) );
5282 for (
i = 0;
i < ncols - 1; ++
i)
5286 consvars[0] = propdata->permvars[varidxmatrix[0][
i]];
5287 consvars[1] = propdata->permvars[varidxmatrix[0][
i + 1]];
5293 propdata->genlinconss[propdata->ngenlinconss++] = cons;
5301 if ( ncols == 2 && propdata->lexreddata !=
NULL )
5306 orbisackperm = propdata->perms[propdata->components[propdata->componentbegins[id]]];
5309 propdata->permvars, propdata->npermvars, orbisackperm, (
SYM_SYMTYPE) propdata->symtype,
5310 propdata->permvardomaincenter,
TRUE, success) );
5317 for (
i = 0;
i < nrows; ++
i)
5320 for (j = 0; j < ncols; ++j)
5321 varmatrix[
i][j] = propdata->permvars[varidxmatrix[
i][j]];
5328 ispporbitope = npprows >= 3;
5342 for (
i = 0;
i < nrows; ++
i)
5347 ppvarsarrayonlypprows[
r++] = varmatrix[
i];
5361 &propdata->genlinconsssize, propdata->ngenlinconss + 1) );
5365 propdata->genlinconss[propdata->ngenlinconss++] = cons;
5379 nelem = nrows * ncols;
5381 for (
i = 0;
i < nrows; ++
i)
5383 for (j = 0; j < ncols; ++j)
5384 orbitopevarmatrix[pos++] = varmatrix[
i][j];
5393 orbitopevarmatrix, nrows, ncols, success) );
5401 for (
i = nrows - 1;
i >= 0; --
i)
5416 int** componentperms,
5435 int** pporbisackperms;
5436 int npporbisackperms;
5440 int* npermvarssetppcconss;
5441 int* maxnpermvarssetppcconss;
5448 assert( componentsize > 0 );
5455 if ( hassignedperm )
5459 if ( setppcconshdlr ==
NULL )
5463 if ( nsetppcconss == 0 )
5474 for (
c = 0;
c < nsetppcconss; ++
c)
5476 cons = setppcconss[
c];
5482 setppconsssort[nsetppconss++] = cons;
5484 SCIPsortPtr((
void**) setppconsssort, sortByPointerValue, nsetppconss);
5492 for (
c = 0;
c < nsetppconss; ++
c)
5496 cons = setppconsssort[
c];
5502 for (
i = 0;
i < nsetppcvars; ++
i)
5504 var = setppcvars[
i];
5507 assert( varid == INT_MAX || varid < propdata->npermvars );
5509 if ( varid < propdata->npermvars )
5512 &(permvarssetppcconss[varid]), &maxnpermvarssetppcconss[varid], npermvarssetppcconss[varid] + 1) );
5513 assert( npermvarssetppcconss[varid] < maxnpermvarssetppcconss[varid] );
5514 permvarssetppcconss[varid][npermvarssetppcconss[varid]++] = cons;
5522 npporbisackperms = 0;
5523 for (p = 0; p < componentsize; ++p)
5525 perm = componentperms[p];
5529 for (
i = 0;
i < propdata->npermvars; ++
i)
5548 (
void**) permvarssetppcconss[j], npermvarssetppcconss[j], sortByPointerValue) )
5557 if ( ntwocycles > 0 )
5559 pporbisackperms[npporbisackperms++] = perm;
5560 if ( ntwocycles > maxntwocycles )
5561 maxntwocycles = ntwocycles;
5569 if ( npporbisackperms * 2 >= componentsize )
5577 assert( npporbisackperms > 0 );
5578 assert( maxntwocycles > 0 );
5583 for (
i = 0;
i < maxntwocycles; ++
i)
5584 ppvarsmatrix[
i] = &(ppvarsblock[2 *
i]);
5587 for (p = 0; p < npporbisackperms; ++p)
5589 perm = pporbisackperms[p];
5593 for (
i = 0;
i < propdata->npermvars; ++
i)
5606 (
void**) permvarssetppcconss[j], npermvarssetppcconss[j], sortByPointerValue) );
5608 assert( nrows < maxntwocycles );
5609 row = ppvarsmatrix[nrows++];
5610 row[0] = propdata->permvars[
i];
5611 row[1] = propdata->permvars[j];
5612 assert( row[0] != row[1] );
5623 &propdata->genlinconsssize, propdata->ngenlinconss + 1) );
5627 propdata->genlinconss[propdata->ngenlinconss++] = cons;
5641 for (varid = 0; varid < propdata->npermvars; ++varid)
5643 assert( (permvarssetppcconss[varid] ==
NULL) == (maxnpermvarssetppcconss[varid] == 0) );
5644 assert( npermvarssetppcconss[varid] >= 0 );
5645 assert( maxnpermvarssetppcconss[varid] >= 0 );
5646 assert( npermvarssetppcconss[varid] <= maxnpermvarssetppcconss[varid] );
5647 if ( npermvarssetppcconss[varid] == 0 )
5650 permvarssetppcconss[varid] =
NULL;
5651 npermvarssetppcconss[varid] = 0;
5652 maxnpermvarssetppcconss[varid] = 0;
5672 int** componentperms;
5685 && propdata->usedynamicprop
5686 && propdata->addsymresacks
5688 assert( propdata->nperms > 0 );
5689 assert( 0 <= cidx && cidx < propdata->ncomponents );
5690 assert( propdata->componentblocked !=
NULL );
5693 if ( propdata->componentblocked[cidx] )
5698 checklexred =
ISSYMRETOPESACTIVE(propdata->usesymmetry) && propdata->usedynamicprop && propdata->addsymresacks;
5699 assert( checkorbired || checklexred );
5702 assert( propdata->nmovedpermvars );
5705 componentsize = propdata->componentbegins[cidx + 1] - propdata->componentbegins[cidx];
5707 for (p = 0; p < componentsize; ++p)
5708 componentperms[p] = propdata->perms[propdata->components[propdata->componentbegins[cidx] + p]];
5717 checkpporbisack =
SCIPgetParam(
scip,
"constraints/orbisack/checkpporbisack");
5721 componentperms, componentsize, propdata->componenthassignedperm[cidx], &success) );
5726 goto FINISHCOMPONENT;
5731 if ( checkorbired && !propdata->componenthassignedperm[cidx] )
5734 propdata->permvars, propdata->npermvars, componentperms, componentsize, &success) );
5743 for (p = 0; p < componentsize; ++p)
5747 propdata->permvars, propdata->npermvars, componentperms[p],
5748 (
SYM_SYMTYPE) propdata->symtype, propdata->permvardomaincenter,
TRUE, &success) );
5756 if ( propdata->componentblocked[cidx] )
5757 ++propdata->ncompblocked;
5772 int ncomponentshandled;
5779 if ( propdata->orbitopalreddata )
5783 if ( propdata->orbitalreddata )
5787 if ( propdata->lexreddata )
5791 if ( propdata->ncomponents >= 0 )
5798 ncomponentshandled = 0;
5799 for (
i = 0;
i < propdata->ncomponents; ++
i)
5801 if ( propdata->componentblocked[
i] )
5802 ++ncomponentshandled;
5804 assert( propdata->ncompblocked <= ncomponentshandled );
5805 assert( ncomponentshandled <= propdata->ncomponents );
5807 ncomponentshandled, propdata->ncomponents);
5835 if ( propdata->usedynamicprop )
5840 else if ( propdata->binvaraffected )
5852 for (
i = 0;
i < nrows; ++
i)
5859 for (j = 0; j < ncols; ++j)
5862 orbitopematrix[nbinrows][j] = propdata->permvars[varidxmatrix[
i][j]];
5877 &propdata->genorbconsssize, propdata->ngenorbconss + 1) );
5878 propdata->genorbconss[propdata->ngenorbconss++] = cons;
5879 ++propdata->norbitopes;
5884 for (
i = nbinrows - 1;
i >= 0; --
i)
5930 assert( nrowblocks > 0 );
5931 assert( ncolblocks > 0 );
5937 for (
i = 0;
i < nrows; ++
i)
5939 for (j = 0; j < ncols; ++j)
5951 &propdata->genorbconsssize, propdata->ngenorbconss + nrowblocks + ncolblocks) );
5953 maxdim =
MAX(nrows, ncols);
5955 for (
i = 0;
i < maxdim; ++
i)
5961 for (p = 0; p < ncolblocks; ++p)
5963 for (
i = 0;
i < nrows; ++
i)
5965 for (col = 0, j = colsbegin[p]; j < colsbegin[p + 1]; ++j, ++col)
5968 orbitopematrix[
i][col] = propdata->permvars[varidxmatrix[
i][j]];
5977 propdata->genorbconss[(propdata->ngenorbconss)++] = cons;
5982 for (p = 0; p < nrowblocks; ++p)
5984 for (
i = 0;
i < ncols; ++
i)
5986 for (col = 0, j = rowsbegin[p]; j < rowsbegin[p + 1]; ++j, ++col)
5989 orbitopematrix[
i][col] = propdata->permvars[varidxmatrix[j][
i]];
5998 propdata->genorbconss[(propdata->ngenorbconss)++] = cons;
6002 for (
i = maxdim - 1;
i >= 0; --
i)
6020 int** lexmatrix =
NULL;
6021 int* lexrowsbegin =
NULL;
6022 int* lexcolsbegin =
NULL;
6036 assert( 0 <= cidx && cidx < propdata->ncomponents );
6039 if ( propdata->componentblocked[cidx] )
6043 if ( propdata->componenthassignedperm[cidx] )
6051 compsize = propdata->componentbegins[cidx + 1] - propdata->componentbegins[cidx];
6053 for (p = 0,
i = propdata->componentbegins[cidx];
i < propdata->componentbegins[cidx + 1]; ++
i)
6054 perms[p++] = propdata->perms[propdata->components[
i]];
6057 &success, &isorbitope, &lexmatrix, &nrows, &ncols,
6058 &lexrowsbegin, &lexcolsbegin, &nrowmatrices, &ncolmatrices) );
6076 lexrowsbegin, lexcolsbegin, nrowmatrices, ncolmatrices, &success) );
6080 for (
i = nrows - 1;
i >= 0; --
i)
6085 if ( ncolmatrices > 0 )
6089 if ( nrowmatrices > 0 )
6098 ++(propdata->ncompblocked);
6114 assert( 0 <= cidx && cidx < propdata->ncomponents );
6117 if ( propdata->componentblocked[cidx] )
6121 if ( propdata->componenthassignedperm[cidx] )
6125 if ( !propdata->usedynamicprop &&
ISSYMRETOPESACTIVE(propdata->usesymmetry) && propdata->detectsubgroups
6126 && propdata->binvaraffected && propdata->ncompblocked < propdata->ncomponents )
6170 assert( propdata->ncomponents >= 0 );
6171 assert( 0 <= cidx && cidx < propdata->ncomponents );
6174 if ( propdata->componentblocked[cidx] )
6179 || (
ISSYMRETOPESACTIVE(propdata->usesymmetry) && propdata->usedynamicprop && propdata->addsymresacks );
6182 if ( propdata->detectdoublelex || propdata->detectorbitopes )
6186 detectsinglelex = propdata->detectdoublelex ?
FALSE :
TRUE;
6195 if ( useorbitalredorlexred )
6220 if ( nchgbds !=
NULL )
6222 if ( earlyterm !=
NULL )
6228 if ( earlyterm !=
NULL )
6235 assert( propdata->usesymmetry >= 0 );
6238 if ( propdata->usesymmetry == 0 )
6240 if ( earlyterm !=
NULL )
6246 if ( propdata->triedaddsymmethods )
6248 assert( propdata->nperms >= 0 );
6250 if ( earlyterm !=
NULL )
6255 assert( !propdata->triedaddsymmethods );
6258 if ( !propdata->computedsymmetry )
6266 if ( !propdata->computedsymmetry )
6270 propdata->triedaddsymmethods =
TRUE;
6271 assert( propdata->nperms >= 0 );
6274 if ( propdata->nperms == 0 )
6279 assert( propdata->ncomponents > 0 );
6282 for (
c = 0;
c < propdata->ncomponents; ++
c)
6290#ifdef SYMMETRY_STATISTICS
6317 *infeasible =
FALSE;
6362 if ( propdata->usesymmetry < 0 )
6366 assert( propdata->usesymmetry >= 0 );
6369 if ( propdata->usesymmetry == 0 )
6398 assert( propdata->usesymmetry >= 0 );
6401 if ( propdata->usesymmetry == 0 )
6456 assert( propdata->usesymmetry >= 0 );
6459 if ( propdata->usesymmetry == 0 )
6473 noldngenconns = propdata->ngenorbconss + propdata->nsstconss + propdata->ngenlinconss;
6485 *nchgbds += nchanges;
6489 if ( propdata->ngenorbconss > 0 || propdata->ngenlinconss > 0 || propdata->nsstconss > 0 )
6492 assert( propdata->nperms > 0 );
6493 assert( propdata->triedaddsymmethods );
6498 *naddconss += propdata->ngenorbconss + propdata->ngenlinconss + propdata->nsstconss - noldngenconns;
6499 SCIPdebugMsg(
scip,
"Added symmetry breaking constraints: %d.\n", *naddconss);
6502 for (
i = 0;
i < propdata->ngenorbconss; ++
i)
6505 nnewchgbds, nnewholes, nnewdelconss, nnewaddconss, nnewupgdconss, nnewchgcoefs, nnewchgsides, nfixedvars, naggrvars,
6506 nchgvartypes, nchgbds, naddholes, ndelconss, naddconss, nupgdconss, nchgcoefs, nchgsides,
result) );
6516 for (
i = 0;
i < propdata->ngenlinconss; ++
i)
6519 nnewchgbds, nnewholes, nnewdelconss, nnewaddconss, nnewupgdconss, nnewchgcoefs, nnewchgsides, nfixedvars, naggrvars,
6520 nchgvartypes, nchgbds, naddholes, ndelconss, naddconss, nupgdconss, nchgcoefs, nchgsides,
result) );
6530 propdata->ngenorbconss + propdata->ngenlinconss);
6532 for (
i = 0;
i < propdata->nsstconss; ++
i)
6535 nnewchgbds, nnewholes, nnewdelconss, nnewaddconss, nnewupgdconss, nnewchgcoefs, nnewchgsides, nfixedvars, naggrvars,
6536 nchgvartypes, nchgbds, naddholes, ndelconss, naddconss, nupgdconss, nchgcoefs, nchgsides,
result) );
6545 SCIPdebugMsg(
scip,
"Presolved %d generated Schreier Sims constraints.\n", propdata->nsstconss);
6576 if ( propdata->usesymmetry < 0 )
6584 propdata->symfoundreduction =
TRUE;
6591 propdata->symfoundreduction =
TRUE;
6618 propdata->usesymmetry = -1;
6619 propdata->triedaddsymmethods =
FALSE;
6620 propdata->nsymresacks = 0;
6621 propdata->norbitopes = 0;
6622 propdata->lastrestart = 0;
6623 propdata->symfoundreduction =
FALSE;
6662 assert( propdata->customsymopnodetypes !=
NULL );
6672 assert( propdata->orbitopalreddata !=
NULL );
6700 propdata->npermvars = 0;
6701 propdata->nbinpermvars = 0;
6702 propdata->permvars =
NULL;
6703 propdata->nperms = -1;
6704 propdata->nmaxperms = 0;
6705 propdata->perms =
NULL;
6706 propdata->permstrans =
NULL;
6707 propdata->permvarmap =
NULL;
6708 propdata->permvardomaincenter =
NULL;
6710 propdata->ncomponents = -1;
6711 propdata->ncompblocked = 0;
6712 propdata->components =
NULL;
6713 propdata->componentbegins =
NULL;
6714 propdata->vartocomponent =
NULL;
6715 propdata->componentblocked =
NULL;
6716 propdata->componenthassignedperm =
NULL;
6718 propdata->log10groupsize = -1.0;
6719 propdata->nmovedvars = -1;
6720 propdata->binvaraffected =
FALSE;
6721 propdata->computedsymmetry =
FALSE;
6722 propdata->conshdlr_nonlinear =
NULL;
6724 propdata->usesymmetry = -1;
6725 propdata->triedaddsymmethods =
FALSE;
6726 propdata->genorbconss =
NULL;
6727 propdata->genlinconss =
NULL;
6728 propdata->ngenorbconss = 0;
6729 propdata->ngenlinconss = 0;
6730 propdata->genorbconsssize = 0;
6731 propdata->genlinconsssize = 0;
6732 propdata->nsymresacks = 0;
6733 propdata->norbitopes = 0;
6734 propdata->isnonlinvar =
NULL;
6736 propdata->nmovedpermvars = -1;
6737 propdata->nmovedbinpermvars = 0;
6738 propdata->nmovedintpermvars = 0;
6739 propdata->nmovedimplintpermvars = 0;
6740 propdata->nmovedcontpermvars = 0;
6741 propdata->lastrestart = 0;
6742 propdata->symfoundreduction =
FALSE;
6744 propdata->sstconss =
NULL;
6745 propdata->nsstconss = 0;
6746 propdata->maxnsstconss = 0;
6747 propdata->leaders =
NULL;
6748 propdata->nleaders = 0;
6749 propdata->maxnleaders = 0;
6769 tabledata->propdata = propdata;
6776 if( rootdialog !=
NULL )
6786 "symmetry",
"display generators of symmetry group in cycle notation, if available",
6794 "propagating/" PROP_NAME "/maxgenerators",
6795 "limit on the number of generators that should be produced within symmetry detection (0 = no limit)",
6799 "propagating/" PROP_NAME "/checksymmetries",
6800 "Should all symmetries be checked after computation?",
6804 "propagating/" PROP_NAME "/displaynorbitvars",
6805 "Should the number of variables affected by some symmetry be displayed?",
6809 "propagating/" PROP_NAME "/doubleequations",
6810 "Double equations to positive/negative version?",
6816 "Should the symmetry breaking constraints be added to the LP?",
6820 "propagating/" PROP_NAME "/addsymresacks",
6821 "Add inequalities for symresacks for each generator?",
6825 "propagating/" PROP_NAME "/detectdoublelex",
6826 "Should we check whether the components of the symmetry group can be handled by double lex matrices?",
6830 "propagating/" PROP_NAME "/detectorbitopes",
6831 "Should we check whether the components of the symmetry group can be handled by orbitopes?",
6835 "propagating/" PROP_NAME "/detectsubgroups",
6836 "Should we try to detect symmetric subgroups of the symmetry group on binary variables?",
6840 "propagating/" PROP_NAME "/addweaksbcs",
6841 "Should we add weak SBCs for enclosing orbit of symmetric subgroups?",
6845 "propagating/" PROP_NAME "/addconsstiming",
6846 "timing of adding constraints (0 = before presolving, 1 = during presolving, 2 = after presolving) [disabled parameter]",
6851 "propagating/" PROP_NAME "/ofsymcomptiming",
6852 "timing of symmetry computation (0 = before presolving, 1 = during presolving, 2 = at first call) [disabled parameter]",
6856 "propagating/" PROP_NAME "/performpresolving",
6857 "run orbital fixing during presolving? (disabled)",
6861 "propagating/" PROP_NAME "/recomputerestart",
6862 "recompute symmetries after a restart has occurred? (0 = never)",
6866 "propagating/" PROP_NAME "/compresssymmetries",
6867 "Should non-affected variables be removed from permutation to save memory?",
6871 "propagating/" PROP_NAME "/compressthreshold",
6872 "Compression is used if percentage of moved vars is at most the threshold.",
6876 "propagating/" PROP_NAME "/usecolumnsparsity",
6877 "Should the number of conss a variable is contained in be exploited in symmetry detection?",
6881 "propagating/" PROP_NAME "/maxnconsssubgroup",
6882 "maximum number of constraints up to which subgroup structures are detected",
6886 "propagating/" PROP_NAME "/usedynamicprop",
6887 "whether dynamified symmetry handling constraint methods should be used",
6891 "propagating/" PROP_NAME "/addstrongsbcs",
6892 "Should strong SBCs for enclosing orbit of symmetric subgroups be added if orbitopes are not used?",
6896 "propagating/" PROP_NAME "/ssttiebreakrule",
6897 "rule to select the orbit in Schreier Sims inequalities (variable in 0: minimum size orbit; 1: maximum size orbit; 2: orbit with most variables in conflict with leader)",
6901 "propagating/" PROP_NAME "/sstleaderrule",
6902 "rule to select the leader in an orbit (0: first var; 1: last var; 2: var having most conflicting vars in orbit)",
6906 "propagating/" PROP_NAME "/sstleadervartype",
6907 "bitset encoding which variable types can be leaders (1: binary; 2: integer; 4: impl. int; 8: continuous);" \
6908 "if multiple types are allowed, take the one with most affected vars",
6912 "propagating/" PROP_NAME "/addconflictcuts",
6913 "Should Schreier Sims constraints be added if we use a conflict based rule?",
6918 "Should Schreier Sims constraints be added?",
6922 "propagating/" PROP_NAME "/sstmixedcomponents",
6923 "Should Schreier Sims constraints be added if a symmetry component contains variables of different types?",
6927 "propagating/" PROP_NAME "/symfixnonbinaryvars",
6928 "Whether all non-binary variables shall be not affected by symmetries if OF is active? (disabled)",
6932 "propagating/" PROP_NAME "/enforcecomputesymmetry",
6933 "Is only symmetry on binary variables used?",
6937 "propagating/" PROP_NAME "/preferlessrows",
6938 "Shall orbitopes with less rows be preferred in detection?",
6943 "Type of symmetries that shall be computed?",
6948 "timing of symmetry computation and handling (0 = before presolving, 1 = during presolving, 2 = after presolving)",
6955 "propagating/" PROP_NAME "/nautymaxncells",
6956 "terminate symmetry detection using Nauty when number of cells in color refinment is at least this number",
6960 "propagating/" PROP_NAME "/nautymaxnnodes",
6961 "terminate symmetry detection using Nauty when its search tree has at least this number of nodes",
6977 assert( propdata->shadowtreeeventhdlr !=
NULL );
6980 assert( propdata->orbitopalreddata !=
NULL );
7004 int** componentbegins,
7005 int** vartocomponent,
7032 *npermvars = propdata->npermvars;
7033 *permvars = propdata->permvars;
7035 if ( permvarmap !=
NULL )
7037 if ( propdata->nperms > 0 )
7041 *permvarmap = propdata->permvarmap;
7044 *nperms = propdata->nperms;
7045 if ( perms !=
NULL )
7047 *perms = propdata->perms;
7051 if ( permstrans !=
NULL )
7053 if ( propdata->nperms > 0 )
7057 *permstrans = propdata->permstrans;
7058 assert( *permstrans !=
NULL || *nperms <= 0 );
7061 if ( log10groupsize !=
NULL )
7062 *log10groupsize = propdata->log10groupsize;
7064 if ( binvaraffected !=
NULL )
7065 *binvaraffected = propdata->binvaraffected;
7069 if ( propdata->nperms > 0 )
7078 if ( componentbegins !=
NULL )
7079 *componentbegins = propdata->componentbegins;
7081 if ( vartocomponent )
7082 *vartocomponent = propdata->vartocomponent;
7085 *ncomponents = propdata->ncomponents;
7108 if ( propdata->nperms < 0 )
7111 return propdata->nperms;
7120 const char* opnodename,
7133 SCIPerrorMessage(
"Cannot create operator node type, symmetry propagator has not been included.\n");
7139 assert( propdata->customsymopnodetypes !=
NULL );
7143 SCIPerrorMessage(
"Cannot create operator node type %s, it already exists.\n", opnodename);
7148 *nodetype = propdata->nopnodetypes++;
7159 const char* opnodename,
7171 SCIPerrorMessage(
"Cannot return operator node type, symmetry propagator has not been included.\n");
7177 assert( propdata->customsymopnodetypes !=
NULL );
static GRAPHNODE ** active
interface for symmetry computations
SCIP_Bool SYMcheckGraphsAreIdentical(SCIP *scip, SYM_SYMTYPE symtype, SYM_GRAPH *G1, SYM_GRAPH *G2)
const char * SYMsymmetryGetName(void)
const char * SYMsymmetryGetAddName(void)
SCIP_RETCODE SYMcomputeSymmetryGenerators(SCIP *scip, int maxgenerators, SYM_GRAPH *graph, int *nperms, int *nmaxperms, int ***perms, SCIP_Real *log10groupsize, SCIP_Real *symcodetime)
SCIP_Bool SYMcanComputeSymmetry(void)
const char * SYMsymmetryGetDesc(void)
const char * SYMsymmetryGetAddDesc(void)
Constraint handler for AND constraints, .
constraint handler for bound disjunction constraints
constraint handler for indicator constraints
Constraint handler for knapsack constraints of the form , x binary and .
Constraint handler for linear constraints in their most general form, .
constraint handler for linking binary variables to a linking (continuous or integer) variable
Constraint handler for logicor constraints (equivalent to set covering, but algorithms are suited fo...
constraint handler for nonlinear constraints specified by algebraic expressions
Constraint handler for "or" constraints, .
constraint handler for (partitioning/packing/full) orbitope constraints w.r.t. the full symmetric gro...
Constraint handler for the set partitioning / packing / covering constraints .
constraint handler for SOS type 1 constraints
constraint handler for SOS type 2 constraints
constraint handler for symresack constraints
Constraint handler for variable bound constraints .
Constraint handler for XOR constraints, .
SCIP_Real SCIPgetShadowTreeEventHandlerExecutionTime(SCIP *scip, SCIP_EVENTHDLR *eventhdlr)
SCIP_RETCODE SCIPincludeEventHdlrShadowTree(SCIP *scip, SCIP_EVENTHDLR **eventhdlrptr)
power and signed power expression handlers
product expression handler
SCIP_RETCODE SCIPcreateSymbreakCons(SCIP *scip, SCIP_CONS **cons, const char *name, int *perm, SCIP_VAR **vars, int nvars, SCIP_Bool ismodelcons, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode)
int SCIPgetNVarsSetppc(SCIP *scip, SCIP_CONS *cons)
SCIP_VAR ** SCIPgetVarsSetppc(SCIP *scip, SCIP_CONS *cons)
SCIP_SETPPCTYPE SCIPgetTypeSetppc(SCIP *scip, SCIP_CONS *cons)
SCIP_RETCODE SCIPcreateConsLinear(SCIP *scip, SCIP_CONS **cons, const char *name, int nvars, SCIP_VAR **vars, SCIP_Real *vals, SCIP_Real lhs, SCIP_Real rhs, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode)
SCIP_RETCODE SCIPcreateConsOrbitope(SCIP *scip, SCIP_CONS **cons, const char *name, SCIP_VAR ***vars, SCIP_ORBITOPETYPE orbitopetype, int nspcons, int nblocks, SCIP_Bool usedynamicprop, SCIP_Bool mayinteract, SCIP_Bool resolveprop, SCIP_Bool ismodelcons, SCIP_Bool initial, SCIP_Bool separate, SCIP_Bool enforce, SCIP_Bool check, SCIP_Bool propagate, SCIP_Bool local, SCIP_Bool modifiable, SCIP_Bool dynamic, SCIP_Bool removable, SCIP_Bool stickingatnode)
@ SCIP_SETPPCTYPE_COVERING
int SCIPdisjointsetGetComponentCount(SCIP_DISJOINTSET *djset)
void SCIPfreeDisjointset(SCIP *scip, SCIP_DISJOINTSET **djset)
int SCIPdisjointsetFind(SCIP_DISJOINTSET *djset, int element)
void SCIPdisjointsetUnion(SCIP_DISJOINTSET *djset, int p, int q, SCIP_Bool forcerepofp)
SCIP_RETCODE SCIPcreateDisjointset(SCIP *scip, SCIP_DISJOINTSET **djset, int ncomponents)
SCIP_Bool SCIPisPresolveFinished(SCIP *scip)
SCIP_Bool SCIPisStopped(SCIP *scip)
SCIP_STATUS SCIPgetStatus(SCIP *scip)
SCIP_STAGE SCIPgetStage(SCIP *scip)
int SCIPgetNIntVars(SCIP *scip)
int SCIPgetNImplVars(SCIP *scip)
int SCIPgetNContVars(SCIP *scip)
SCIP_CONS ** SCIPgetConss(SCIP *scip)
int SCIPgetNVars(SCIP *scip)
SCIP_RETCODE SCIPaddCons(SCIP *scip, SCIP_CONS *cons)
int SCIPgetNConss(SCIP *scip)
SCIP_VAR ** SCIPgetVars(SCIP *scip)
int SCIPgetNBinVars(SCIP *scip)
void SCIPhashmapFree(SCIP_HASHMAP **hashmap)
int SCIPhashmapGetImageInt(SCIP_HASHMAP *hashmap, void *origin)
SCIP_RETCODE SCIPhashmapCreate(SCIP_HASHMAP **hashmap, BMS_BLKMEM *blkmem, int mapsize)
SCIP_Bool SCIPhashmapExists(SCIP_HASHMAP *hashmap, void *origin)
SCIP_RETCODE SCIPhashmapInsertInt(SCIP_HASHMAP *hashmap, void *origin, int image)
void SCIPinfoMessage(SCIP *scip, FILE *file, const char *formatstr,...)
void SCIPverbMessage(SCIP *scip, SCIP_VERBLEVEL msgverblevel, FILE *file, const char *formatstr,...)
void SCIPwarningMessage(SCIP *scip, const char *formatstr,...)
SCIP_RETCODE SCIPaddIntParam(SCIP *scip, const char *name, const char *desc, int *valueptr, SCIP_Bool isadvanced, int defaultvalue, int minvalue, int maxvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
SCIP_PARAM * SCIPgetParam(SCIP *scip, const char *name)
SCIP_RETCODE SCIPaddRealParam(SCIP *scip, const char *name, const char *desc, SCIP_Real *valueptr, SCIP_Bool isadvanced, SCIP_Real defaultvalue, SCIP_Real minvalue, SCIP_Real maxvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
SCIP_RETCODE SCIPaddBoolParam(SCIP *scip, const char *name, const char *desc, SCIP_Bool *valueptr, SCIP_Bool isadvanced, SCIP_Bool defaultvalue, SCIP_DECL_PARAMCHGD((*paramchgd)), SCIP_PARAMDATA *paramdata)
SCIP_RETCODE SCIPgetIntParam(SCIP *scip, const char *name, int *value)
int SCIPgetNActiveBenders(SCIP *scip)
int SCIPgetNConshdlrs(SCIP *scip)
SCIP_Bool SCIPconshdlrSupportsSignedPermsymDetection(SCIP_CONSHDLR *conshdlr)
int SCIPconshdlrGetNConss(SCIP_CONSHDLR *conshdlr)
const char * SCIPconshdlrGetName(SCIP_CONSHDLR *conshdlr)
SCIP_CONSHDLR * SCIPfindConshdlr(SCIP *scip, const char *name)
SCIP_Bool SCIPconshdlrSupportsPermsymDetection(SCIP_CONSHDLR *conshdlr)
int SCIPconshdlrGetNActiveConss(SCIP_CONSHDLR *conshdlr)
SCIP_CONS ** SCIPconshdlrGetConss(SCIP_CONSHDLR *conshdlr)
SCIP_CONSHDLR ** SCIPgetConshdlrs(SCIP *scip)
SCIP_RETCODE SCIPgetConsNVars(SCIP *scip, SCIP_CONS *cons, int *nvars, SCIP_Bool *success)
SCIP_RETCODE SCIPgetConsSignedPermsymGraph(SCIP *scip, SCIP_CONS *cons, SYM_GRAPH *graph, SCIP_Bool *success)
SCIP_CONSHDLR * SCIPconsGetHdlr(SCIP_CONS *cons)
SCIP_RETCODE SCIPpresolCons(SCIP *scip, SCIP_CONS *cons, int nrounds, SCIP_PRESOLTIMING presoltiming, int nnewfixedvars, int nnewaggrvars, int nnewchgvartypes, int nnewchgbds, int nnewholes, int nnewdelconss, int nnewaddconss, int nnewupgdconss, int nnewchgcoefs, int nnewchgsides, int *nfixedvars, int *naggrvars, int *nchgvartypes, int *nchgbds, int *naddholes, int *ndelconss, int *naddconss, int *nupgdconss, int *nchgcoefs, int *nchgsides, SCIP_RESULT *result)
SCIP_RETCODE SCIPprintCons(SCIP *scip, SCIP_CONS *cons, FILE *file)
SCIP_RETCODE SCIPgetConsPermsymGraph(SCIP *scip, SCIP_CONS *cons, SYM_GRAPH *graph, SCIP_Bool *success)
const char * SCIPconsGetName(SCIP_CONS *cons)
SCIP_RETCODE SCIPreleaseCons(SCIP *scip, SCIP_CONS **cons)
SCIP_RETCODE SCIPreleaseDialog(SCIP *scip, SCIP_DIALOG **dialog)
SCIP_DIALOG * SCIPdialoghdlrGetRoot(SCIP_DIALOGHDLR *dialoghdlr)
SCIP_Bool SCIPdialogHasEntry(SCIP_DIALOG *dialog, const char *entryname)
SCIP_RETCODE SCIPdialoghdlrAddHistory(SCIP_DIALOGHDLR *dialoghdlr, SCIP_DIALOG *dialog, const char *command, SCIP_Bool escapecommand)
SCIP_RETCODE SCIPincludeDialog(SCIP *scip, SCIP_DIALOG **dialog, SCIP_DECL_DIALOGCOPY((*dialogcopy)), SCIP_DECL_DIALOGEXEC((*dialogexec)), SCIP_DECL_DIALOGDESC((*dialogdesc)), SCIP_DECL_DIALOGFREE((*dialogfree)), const char *name, const char *desc, SCIP_Bool issubmenu, SCIP_DIALOGDATA *dialogdata)
SCIP_RETCODE SCIPaddDialogEntry(SCIP *scip, SCIP_DIALOG *dialog, SCIP_DIALOG *subdialog)
SCIP_DIALOGDATA * SCIPdialogGetData(SCIP_DIALOG *dialog)
SCIP_DIALOG * SCIPgetRootDialog(SCIP *scip)
int SCIPdialogFindEntry(SCIP_DIALOG *dialog, const char *entryname, SCIP_DIALOG **subdialog)
const char * SCIPexprhdlrGetName(SCIP_EXPRHDLR *exprhdlr)
int SCIPgetNExprhdlrs(SCIP *scip)
SCIP_Bool SCIPexprhdlrHasGetSymData(SCIP_EXPRHDLR *exprhdlr)
SCIP_EXPRHDLR ** SCIPgetExprhdlrs(SCIP *scip)
SCIP_RETCODE SCIPincludeExternalCodeInformation(SCIP *scip, const char *name, const char *description)
#define SCIPfreeCleanBufferArray(scip, ptr)
#define SCIPallocCleanBufferArray(scip, ptr, num)
#define SCIPfreeBlockMemoryArray(scip, ptr, num)
#define SCIPallocClearBlockMemoryArray(scip, ptr, num)
#define SCIPallocClearBufferArray(scip, ptr, num)
int SCIPcalcMemGrowSize(SCIP *scip, int num)
#define SCIPallocBufferArray(scip, ptr, num)
#define SCIPreallocBufferArray(scip, ptr, num)
#define SCIPfreeBufferArray(scip, ptr)
#define SCIPallocBlockMemoryArray(scip, ptr, num)
#define SCIPreallocBlockMemoryArray(scip, ptr, oldnum, newnum)
#define SCIPfreeBlockMemory(scip, ptr)
#define SCIPfreeBlockMemoryArrayNull(scip, ptr, num)
#define SCIPfreeBufferArrayNull(scip, ptr)
#define SCIPallocBlockMemory(scip, ptr)
#define SCIPduplicateBlockMemoryArray(scip, ptr, source, num)
int SCIPgetNActivePricers(SCIP *scip)
SCIP_PROP * SCIPfindProp(SCIP *scip, const char *name)
SCIP_RETCODE SCIPsetPropInitpre(SCIP *scip, SCIP_PROP *prop,)
SCIP_RETCODE SCIPsetPropExitpre(SCIP *scip, SCIP_PROP *prop,)
SCIP_PROPDATA * SCIPpropGetData(SCIP_PROP *prop)
SCIP_RETCODE SCIPsetPropPresol(SCIP *scip, SCIP_PROP *prop, SCIP_DECL_PROPPRESOL((*proppresol)), int presolpriority, int presolmaxrounds, SCIP_PRESOLTIMING presoltiming)
SCIP_RETCODE SCIPsetPropExitsol(SCIP *scip, SCIP_PROP *prop,)
const char * SCIPpropGetName(SCIP_PROP *prop)
SCIP_RETCODE SCIPsetPropResprop(SCIP *scip, SCIP_PROP *prop,)
SCIP_RETCODE SCIPsetPropFree(SCIP *scip, SCIP_PROP *prop,)
SCIP_RETCODE SCIPsetPropExit(SCIP *scip, SCIP_PROP *prop,)
SCIP_RETCODE SCIPincludePropBasic(SCIP *scip, SCIP_PROP **propptr, const char *name, const char *desc, int priority, int freq, SCIP_Bool delay, SCIP_PROPTIMING timingmask, SCIP_DECL_PROPEXEC((*propexec)), SCIP_PROPDATA *propdata)
SCIP_Bool SCIPisReoptEnabled(SCIP *scip)
int SCIPgetNRuns(SCIP *scip)
SCIP_RETCODE SCIPdetermineNVarsAffectedSym(SCIP *scip, int **perms, int nperms, SCIP_VAR **permvars, int npermvars, int *nvarsaffected)
SCIP_RETCODE SCIPcomputeComponentsSym(SCIP *scip, SYM_SYMTYPE symtype, int **perms, int nperms, SCIP_VAR **permvars, int npermvars, SCIP_Bool transposed, int **components, int **componentbegins, int **vartocomponent, unsigned **componentblocked, int *ncomponents)
SCIP_RETCODE SCIPcomputeOrbitVar(SCIP *scip, int npermvars, int **perms, int **permstrans, int *components, int *componentbegins, SCIP_Shortbool *ignoredvars, SCIP_Shortbool *varfound, int varidx, int component, int *orbit, int *orbitsize)
SCIP_RETCODE SCIPisInvolutionPerm(int *perm, SCIP_VAR **vars, int nvars, int *ntwocyclesperm, int *nbincyclesperm, SCIP_Bool earlytermination)
SCIP_RETCODE SCIPdetectSingleOrDoubleLexMatrices(SCIP *scip, SCIP_Bool detectsinglelex, int **perms, int nperms, int permlen, SCIP_Bool *success, SCIP_Bool *isorbitope, int ***lexmatrix, int *nrows, int *ncols, int **lexrowsbegin, int **lexcolsbegin, int *nrowmatrices, int *ncolmatrices)
SCIP_RETCODE SCIPgenerateOrbitopeVarsMatrix(SCIP *scip, SCIP_VAR ****vars, int nrows, int ncols, SCIP_VAR **permvars, int npermvars, int **orbitopevaridx, int *columnorder, int *nusedelems, SCIP_Shortbool *rowisbinary, SCIP_Bool *infeasible, SCIP_Bool storelexorder, int **lexorder, int *nvarsorder, int *maxnvarsorder)
SCIP_RETCODE SCIPisPackingPartitioningOrbitope(SCIP *scip, SCIP_VAR ***vars, int nrows, int ncols, SCIP_Bool **pprows, int *npprows, SCIP_ORBITOPETYPE *type)
SCIP_RETCODE SCIPcomputeOrbitsFilterSym(SCIP *scip, int npermvars, int **permstrans, int nperms, SCIP_Shortbool *inactiveperms, int *orbits, int *orbitbegins, int *norbits, int *components, int *componentbegins, int *vartocomponent, unsigned *componentblocked, int ncomponents, int nmovedpermvars)
SCIP_RETCODE SCIPextendSubOrbitope(int **suborbitope, int nrows, int nfilledcols, int coltoextend, int *perm, SCIP_Bool leftextension, int **nusedelems, SCIP_VAR **permvars, SCIP_Shortbool *rowisbinary, SCIP_Bool *success, SCIP_Bool *infeasible)
SCIP_TABLEDATA * SCIPtableGetData(SCIP_TABLE *table)
SCIP_RETCODE SCIPincludeTable(SCIP *scip, const char *name, const char *desc, SCIP_Bool active, SCIP_DECL_TABLECOPY((*tablecopy)), SCIP_DECL_TABLEFREE((*tablefree)), SCIP_DECL_TABLEINIT((*tableinit)), SCIP_DECL_TABLEEXIT((*tableexit)), SCIP_DECL_TABLEINITSOL((*tableinitsol)), SCIP_DECL_TABLEEXITSOL((*tableexitsol)), SCIP_DECL_TABLEOUTPUT((*tableoutput)), SCIP_TABLEDATA *tabledata, int position, SCIP_STAGE earlieststage)
SCIP_Real SCIPgetSolvingTime(SCIP *scip)
SCIP_Real SCIPinfinity(SCIP *scip)
SCIP_Bool SCIPisGE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisLE(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisGT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
SCIP_Bool SCIPisLT(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
int SCIPgetDepth(SCIP *scip)
SCIP_Bool SCIPvarIsBinary(SCIP_VAR *var)
SCIP_Real SCIPvarGetUbLocal(SCIP_VAR *var)
SCIP_RETCODE SCIPchgVarUb(SCIP *scip, SCIP_VAR *var, SCIP_Real newbound)
SCIP_CLIQUE ** SCIPgetCliques(SCIP *scip)
SCIP_VARTYPE SCIPvarGetType(SCIP_VAR *var)
SCIP_Real SCIPvarGetUbGlobal(SCIP_VAR *var)
int SCIPvarGetProbindex(SCIP_VAR *var)
const char * SCIPvarGetName(SCIP_VAR *var)
SCIP_RETCODE SCIPreleaseVar(SCIP *scip, SCIP_VAR **var)
SCIP_Bool SCIPvarIsIntegral(SCIP_VAR *var)
SCIP_Real SCIPvarGetLbLocal(SCIP_VAR *var)
int SCIPgetNCliques(SCIP *scip)
SCIP_Real SCIPvarGetLbGlobal(SCIP_VAR *var)
SCIP_Bool SCIPallowWeakDualReds(SCIP *scip)
SCIP_RETCODE SCIPcaptureVar(SCIP *scip, SCIP_VAR *var)
SCIP_Bool SCIPallowStrongDualReds(SCIP *scip)
void SCIPsortPtr(void **ptrarray, SCIP_DECL_SORTPTRCOMP((*ptrcomp)), int len)
void SCIPsortIntInt(int *intarray1, int *intarray2, int len)
void SCIPsort(int *perm, SCIP_DECL_SORTINDCOMP((*indcomp)), void *dataptr, int len)
int SCIPsnprintf(char *t, int len, const char *s,...)
SCIP_RETCODE SCIPfreeSymgraph(SCIP *scip, SYM_GRAPH **graph)
SCIP_RETCODE SCIPcreateSymgraph(SCIP *scip, SYM_SYMTYPE symtype, SYM_GRAPH **graph, SCIP_VAR **symvars, int nsymvars, int nopnodes, int nvalnodes, int nconsnodes, int nedges)
SCIP_RETCODE SCIPcomputeSymgraphColors(SCIP *scip, SYM_GRAPH *graph, SYM_SPEC fixedtype)
SCIP_RETCODE SCIPcreateSymgraphConsnodeperm(SCIP *scip, SYM_GRAPH *graph)
SCIP_RETCODE SCIPfreeSymgraphConsnodeperm(SCIP *scip, SYM_GRAPH *graph)
SCIP_RETCODE SCIPcopySymgraph(SCIP *scip, SYM_GRAPH **graph, SYM_GRAPH *origgraph, int *perm, SYM_SPEC fixedtype)
int SCIPgetSymgraphNVarcolors(SYM_GRAPH *graph)
assert(minobj< SCIPgetCutoffbound(scip))
SCIP_VAR ** SCIPcliqueGetVars(SCIP_CLIQUE *clique)
int SCIPcliqueGetNVars(SCIP_CLIQUE *clique)
int SCIPcliqueGetIndex(SCIP_CLIQUE *clique)
unsigned int SCIPcliqueGetId(SCIP_CLIQUE *clique)
internal miscellaneous methods
BMS_BLKMEM * SCIPblkmem(SCIP *scip)
SCIP_Bool SCIPparamGetBool(SCIP_PARAM *param)
#define PROP_PRESOL_MAXROUNDS
#define PROP_PRESOLTIMING
#define PROP_PRESOL_PRIORITY
#define DEFAULT_CONSSADDLP
static SCIP_Bool conshdlrCanProvideSymInformation(SCIP_CONSHDLR *conshdlr, SYM_SYMTYPE symtype)
#define DEFAULT_MAXGENERATORS
static SCIP_RETCODE tryAddSymmetryHandlingMethodsComponent(SCIP *scip, SCIP_PROPDATA *propdata, int cidx, int *nchgbds)
#define DEFAULT_DETECTSUBGROUPS
#define DEFAULT_SSTLEADERRULE
#define DEFAULT_PREFERLESSROWS
#define ISSSTINTACTIVE(x)
static SCIP_RETCODE tryAddSymmetryHandlingMethods(SCIP *scip, SCIP_PROP *prop, int *nchgbds, SCIP_Bool *earlyterm)
#define TABLE_POSITION_SYMMETRY
#define DEFAULT_ADDWEAKSBCS
static SCIP_Bool checkSortedArraysHaveOverlappingEntry(void **arr1, int narr1, void **arr2, int narr2,)
static SCIP_RETCODE buildSubgroupGraph(SCIP *scip, SCIP_PROPDATA *propdata, int *genorder, int ntwocycleperms, int compidx, int **graphcomponents, int **graphcompbegins, int **compcolorbegins, int *ngraphcomponents, int *ncompcolors, int **usedperms, int *nusedperms, int usedpermssize, SCIP_Shortbool *permused)
#define DEFAULT_ADDSTRONGSBCS
static SCIP_RETCODE propagateSymmetry(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_Bool *infeasible, int *nred, SCIP_Bool *didrun)
#define DEFAULT_SYMCOMPTIMING
SCIP_RETCODE SCIPgetSymmetry(SCIP *scip, int *npermvars, SCIP_VAR ***permvars, SCIP_HASHMAP **permvarmap, int *nperms, int ***perms, int ***permstrans, SCIP_Real *log10groupsize, SCIP_Bool *binvaraffected, int **components, int **componentbegins, int **vartocomponent, int *ncomponents)
static SCIP_RETCODE ensureSymmetryPermvarmapComputed(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE createConflictGraphSST(SCIP *scip, SCIP_CONFLICTDATA **varconflicts, SCIP_VAR **conflictvars, int nconflictvars, SCIP_HASHMAP *conflictvarmap)
static SCIP_RETCODE ensureDynamicConsArrayAllocatedAndSufficientlyLarge(SCIP *scip, SCIP_CONS ***consarrptr, int *consarrsizeptr, int consarrsizereq)
#define DEFAULT_SSTLEADERVARTYPE
static SCIP_RETCODE tryHandleSingleOrDoubleLexMatricesComponent(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_Bool detectsinglelex, int cidx)
#define DEFAULT_COMPRESSSYMMETRIES
static SCIP_RETCODE adaptSymmetryDataSST(SCIP *scip, int **origperms, int **modifiedperms, int nperms, SCIP_VAR **origpermvars, SCIP_VAR **modifiedpermvars, int npermvars, int *leaders, int nleaders)
#define ISSYMRETOPESACTIVE(x)
static SCIP_RETCODE determineSymmetry(SCIP *scip, SCIP_PROPDATA *propdata, SYM_SPEC symspecrequire, SYM_SPEC symspecrequirefixed)
static SCIP_RETCODE addWeakSBCsSubgroup(SCIP *scip, SCIP_PROPDATA *propdata, int *compcolorbegins, int *graphcompbegins, int *graphcomponents, int ncompcolors, int *chosencomppercolor, int *firstvaridxpercolor, int symgrpcompidx, int *naddedconss, SCIP_Bool storelexorder, int **lexorder, int *nvarsorder, int *maxnvarsorder)
#define DEFAULT_ADDSYMRESACKS
static SCIP_RETCODE setSymmetryData(SCIP *scip, SYM_SYMTYPE symtype, SCIP_VAR **vars, int nvars, int nbinvars, SCIP_VAR ***permvars, int *npermvars, int *nbinpermvars, SCIP_Real **permvardomaincenter, int **perms, int nperms, int *nmovedvars, SCIP_Bool *binvaraffected, SCIP_Bool usecompression, SCIP_Real compressthreshold, SCIP_Bool *compressed)
static int getNOrbitopesInComp(SCIP_VAR **permvars, int *graphcomponents, int *graphcompbegins, int *compcolorbegins, int ncompcolors, int symcompsize)
#define DEFAULT_SSTTIEBREAKRULE
#define DEFAULT_DOUBLEEQUATIONS
#define DEFAULT_SSTMIXEDCOMPONENTS
SCIP_RETCODE SCIPcreateSymOpNodeType(SCIP *scip, const char *opnodename, int *nodetype)
static SCIP_RETCODE displaySymmetriesWithComponents(SCIP *scip, SCIP_PROPDATA *propdata)
#define DEFAULT_ADDCONFLICTCUTS
static SCIP_RETCODE updateSymInfoConflictGraphSST(SCIP *scip, SCIP_CONFLICTDATA *varconflicts, SCIP_VAR **conflictvars, int nconflictvars, int *orbits, int *orbitbegins, int norbits)
#define ISSSTBINACTIVE(x)
static SCIP_RETCODE estimateSymgraphSize(SCIP *scip, int *nopnodes, int *nvalnodes, int *nconsnodes, int *nedges)
static SCIP_RETCODE addSymresackConss(SCIP *scip, SCIP_PROPDATA *propdata, int cidx)
#define DEFAULT_DETECTDOUBLELEX
static SCIP_Bool isNonstandardPerm(SCIP *scip, int *symmetry, SCIP_VAR **vars, int nvars)
static SCIP_RETCODE chooseOrderOfGenerators(SCIP *scip, SCIP_PROPDATA *propdata, int compidx, int **genorder, int *ntwocycleperms)
static SCIP_RETCODE tryHandleSubgroups(SCIP *scip, SCIP_PROPDATA *propdata, int cidx)
static SCIP_Bool testSymmetryComputationRequired(SCIP *scip, SCIP_PROPDATA *propdata)
#define ISSSTIMPLINTACTIVE(x)
static int compareSymgraphs(SCIP *scip, SYM_GRAPH *G1, SYM_GRAPH *G2)
struct SCIP_ConflictData SCIP_CONFLICTDATA
static SCIP_RETCODE resetDynamicSymmetryHandling(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE selectOrbitLeaderSSTConss(SCIP *scip, SCIP_CONFLICTDATA *varconflicts, SCIP_VAR **conflictvars, int nconflictvars, int *orbits, int *orbitbegins, int norbits, int leaderrule, int tiebreakrule, SCIP_VARTYPE leadervartype, int *orbitidx, int *leaderidx, SCIP_Shortbool *orbitvarinconflict, int *norbitvarinconflict, SCIP_Bool *success)
#define DEFAULT_COMPRESSTHRESHOLD
#define TABLE_EARLIEST_SYMMETRY
#define DEFAULT_DETECTORBITOPES
static SCIP_RETCODE freeSymmetryData(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE SCIPdisplaySymmetryStatistics(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE computeSymmetryGroup(SCIP *scip, SYM_SYMTYPE symtype, SCIP_Bool compresssymmetries, SCIP_Real compressthreshold, int maxgenerators, SYM_SPEC fixedtype, SCIP_Bool checksymmetries, SCIP_VAR ***permvars, int *npermvars, int *nbinpermvars, SCIP_Real **permvardomaincenter, int ***perms, int *nperms, int *nmaxperms, int *nmovedvars, SCIP_Bool *binvaraffected, SCIP_Bool *compressed, SCIP_Real *log10groupsize, SCIP_Real *symcodetime, SCIP_Bool *success)
static SCIP_RETCODE handleDoublelLexMatrix(SCIP *scip, SCIP_PROPDATA *propdata, int id, int **varidxmatrix, int nrows, int ncols, int *rowsbegin, int *colsbegin, int nrowblocks, int ncolblocks, SCIP_Bool *success)
#define DEFAULT_ADDCONSSTIMING
#define DEFAULT_SSTADDCUTS
static SCIP_RETCODE checkSymmetriesAreSymmetries(SCIP *scip, SYM_SYMTYPE symtype, int **perms, int nperms, int npermvars, SYM_SPEC fixedtype)
static SCIP_Bool checkSymmetryDataFree(SCIP_PROPDATA *propdata)
#define TABLE_NAME_SYMMETRY
#define DEFAULT_CHECKSYMMETRIES
static SCIP_RETCODE addOrbitopeSubgroup(SCIP *scip, SCIP_PROPDATA *propdata, int *usedperms, int nusedperms, int *compcolorbegins, int *graphcompbegins, int *graphcomponents, int graphcoloridx, int nrows, int ncols, int *firstvaridx, int *compidxfirstrow, int **lexorder, int *nvarslexorder, int *maxnvarslexorder, SCIP_Bool mayinteract, SCIP_Bool *success)
static SCIP_RETCODE addOrbitopesDynamic(SCIP *scip, SCIP_PROPDATA *propdata, int id, int **varidxmatrix, int nrows, int ncols, SCIP_Bool *success)
#define DEFAULT_USEDYNAMICPROP
#define DEFAULT_RECOMPUTERESTART
static SCIP_RETCODE checkComponentsForNonstandardPerms(SCIP *scip, SCIP_PROPDATA *propdata)
#define DEFAULT_NAUTYMAXNCELLS
#define DEFAULT_MAXNCONSSSUBGROUP
static SCIP_RETCODE ensureSymmetryMovedpermvarscountsComputed(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE tryAddOrbitalRedLexRed(SCIP *scip, SCIP_PROPDATA *propdata, int cidx)
struct SYM_Sortgraphcompvars SYM_SORTGRAPHCOMPVARS
#define TABLE_DESC_SYMMETRY
static SCIP_RETCODE freeConflictGraphSST(SCIP *scip, SCIP_CONFLICTDATA **varconflicts, int nvars)
static SCIP_RETCODE addStrongSBCsSubgroup(SCIP *scip, SCIP_PROPDATA *propdata, int *graphcompbegins, int *graphcomponents, int graphcompidx, SCIP_Bool storelexorder, int **lexorder, int *nvarsorder, int *maxnvarsorder)
#define DEFAULT_ENFORCECOMPUTESYMMETRY
#define ISORBITALREDUCTIONACTIVE(x)
static SCIP_RETCODE addSSTConss(SCIP *scip, SCIP_PROPDATA *propdata, SCIP_Bool onlywithcontvars, int *nchgbds, int cidx)
#define DEFAULT_PERFORMPRESOLVING
static SCIP_RETCODE checkTwoCyclePermsAreOrbitope(SCIP *scip, SCIP_VAR **permvars, int npermvars, int **perms, int *activeperms, int ntwocycles, int nactiveperms, int **orbitopevaridx, int *columnorder, int *nusedelems, int *nusedcols, SCIP_Shortbool *rowisbinary, SCIP_Bool *isorbitope, SCIP_Shortbool *activevars)
static SCIP_RETCODE ensureSymmetryPermstransComputed(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE displaySymmetriesWithoutComponents(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE addSSTConssOrbitAndUpdateSST(SCIP *scip, SCIP_CONFLICTDATA *varconflicts, SCIP_PROPDATA *propdata, SCIP_VAR **permvars, int *orbits, int *orbitbegins, int orbitidx, int orbitleaderidx, SCIP_Shortbool *orbitvarinconflict, int norbitvarinconflict, int *nchgbds)
SCIP_RETCODE SCIPincludePropSymmetry(SCIP *scip)
static SCIP_RETCODE displayCycleOfSymmetry(SCIP *scip, int *perm, SYM_SYMTYPE symtype, int baseidx, SCIP_Bool *covered, int nvars, SCIP_VAR **vars)
static SCIP_RETCODE componentPackingPartitioningOrbisackUpgrade(SCIP *scip, SCIP_PROPDATA *propdata, int **componentperms, int componentsize, SCIP_Bool hassignedperm, SCIP_Bool *success)
int SCIPgetSymmetryNGenerators(SCIP *scip)
#define DEFAULT_SYMFIXNONBINARYVARS
static SCIP_RETCODE handleOrbitope(SCIP *scip, SCIP_PROPDATA *propdata, int id, int **varidxmatrix, int nrows, int ncols, SCIP_Bool *success)
static SCIP_RETCODE ensureSymmetryComponentsComputed(SCIP *scip, SCIP_PROPDATA *propdata)
static SCIP_RETCODE detectAndHandleSubgroups(SCIP *scip, SCIP_PROPDATA *propdata, int cidx)
#define ISSSTCONTACTIVE(x)
#define DEFAULT_DISPLAYNORBITVARS
SCIP_RETCODE SCIPgetSymOpNodeType(SCIP *scip, const char *opnodename, int *nodetype)
static SCIP_Bool conshdlrsCanProvideSymInformation(SCIP *scip, SYM_SYMTYPE symtype)
#define DEFAULT_NAUTYMAXNNODES
#define DEFAULT_USECOLUMNSPARSITY
propagator for symmetry handling
public functions to work with algebraic expressions
public methods for data structures
methods for handling symmetries
methods for dealing with symmetry detection graphs
SCIP_RETCODE SCIPlexicographicReductionPropagate(SCIP *scip, SCIP_LEXREDDATA *masterdata, SCIP_Bool *infeasible, int *nred, SCIP_Bool *didrun)
SCIP_RETCODE SCIPlexicographicReductionGetStatistics(SCIP *scip, SCIP_LEXREDDATA *masterdata, int *nred, int *ncutoff)
SCIP_RETCODE SCIPlexicographicReductionReset(SCIP *scip, SCIP_LEXREDDATA *masterdata)
SCIP_RETCODE SCIPlexicographicReductionPrintStatistics(SCIP *scip, SCIP_LEXREDDATA *masterdata)
SCIP_RETCODE SCIPlexicographicReductionFree(SCIP *scip, SCIP_LEXREDDATA **masterdata)
SCIP_RETCODE SCIPlexicographicReductionAddPermutation(SCIP *scip, SCIP_LEXREDDATA *masterdata, SCIP_VAR **permvars, int npermvars, int *perm, SYM_SYMTYPE symtype, SCIP_Real *permvardomaincenter, SCIP_Bool usedynamicorder, SCIP_Bool *success)
SCIP_RETCODE SCIPincludeLexicographicReduction(SCIP *scip, SCIP_LEXREDDATA **masterdata, SCIP_EVENTHDLR *shadowtreeeventhdlr)
methods for handling symmetries by dynamic lexicographic ordering reduction
struct SCIP_LexRedData SCIP_LEXREDDATA
SCIP_RETCODE SCIPorbitalReductionFree(SCIP *scip, SCIP_ORBITALREDDATA **orbireddata)
SCIP_RETCODE SCIPorbitalReductionGetStatistics(SCIP *scip, SCIP_ORBITALREDDATA *orbireddata, int *nred, int *ncutoff)
SCIP_RETCODE SCIPincludeOrbitalReduction(SCIP *scip, SCIP_ORBITALREDDATA **orbireddata, SCIP_EVENTHDLR *shadowtreeeventhdlr)
SCIP_RETCODE SCIPorbitalReductionPrintStatistics(SCIP *scip, SCIP_ORBITALREDDATA *orbireddata)
SCIP_RETCODE SCIPorbitalReductionAddComponent(SCIP *scip, SCIP_ORBITALREDDATA *orbireddata, SCIP_VAR **permvars, int npermvars, int **perms, int nperms, SCIP_Bool *success)
SCIP_RETCODE SCIPorbitalReductionReset(SCIP *scip, SCIP_ORBITALREDDATA *orbireddata)
SCIP_RETCODE SCIPorbitalReductionPropagate(SCIP *scip, SCIP_ORBITALREDDATA *orbireddata, SCIP_Bool *infeasible, int *nred, SCIP_Bool *didrun)
struct SCIP_OrbitalReductionData SCIP_ORBITALREDDATA
SCIP_RETCODE SCIPincludeOrbitopalReduction(SCIP *scip, SCIP_ORBITOPALREDDATA **orbireddata)
SCIP_RETCODE SCIPorbitopalReductionFree(SCIP *scip, SCIP_ORBITOPALREDDATA **orbireddata)
SCIP_RETCODE SCIPorbitopalReductionReset(SCIP *scip, SCIP_ORBITOPALREDDATA *orbireddata)
SCIP_RETCODE SCIPorbitopalReductionAddOrbitope(SCIP *scip, SCIP_ORBITOPALREDDATA *orbireddata, SCIP_ROWORDERING rowordering, SCIP_COLUMNORDERING colordering, SCIP_VAR **vars, int nrows, int ncols, SCIP_Bool *success)
SCIP_RETCODE SCIPorbitopalReductionPropagate(SCIP *scip, SCIP_ORBITOPALREDDATA *orbireddata, SCIP_Bool *infeasible, int *nred, SCIP_Bool *didrun)
SCIP_RETCODE SCIPorbitopalReductionGetStatistics(SCIP *scip, SCIP_ORBITOPALREDDATA *orbireddata, int *nred, int *ncutoff)
SCIP_RETCODE SCIPorbitopalReductionPrintStatistics(SCIP *scip, SCIP_ORBITOPALREDDATA *orbireddata)
SCIP_COLUMNORDERING SCIPorbitopalReductionGetDefaultColumnOrdering(SCIP_ORBITOPALREDDATA *orbireddata)
enum SCIP_ColumnOrdering SCIP_COLUMNORDERING
@ SCIP_ROWORDERING_BRANCHING
struct SCIP_OrbitopalReductionData SCIP_ORBITOPALREDDATA
struct SCIP_Cons SCIP_CONS
struct SYM_Graph SYM_GRAPH
struct SCIP_Conshdlr SCIP_CONSHDLR
struct SCIP_Dialog SCIP_DIALOG
#define SCIP_DECL_DIALOGEXEC(x)
struct SCIP_DialogData SCIP_DIALOGDATA
struct SCIP_Eventhdlr SCIP_EVENTHDLR
struct SCIP_Exprhdlr SCIP_EXPRHDLR
struct SCIP_Clique SCIP_CLIQUE
struct SCIP_HashMap SCIP_HASHMAP
#define SCIP_DECL_SORTPTRCOMP(x)
#define SCIP_DECL_SORTINDCOMP(x)
struct SCIP_DisjointSet SCIP_DISJOINTSET
struct SCIP_Param SCIP_PARAM
#define SCIP_DECL_PROPEXITPRE(x)
#define SCIP_DECL_PROPFREE(x)
#define SCIP_DECL_PROPEXITSOL(x)
#define SCIP_DECL_PROPEXIT(x)
struct SCIP_Prop SCIP_PROP
#define SCIP_DECL_PROPPRESOL(x)
#define SCIP_DECL_PROPINITPRE(x)
#define SCIP_DECL_PROPRESPROP(x)
struct SCIP_PropData SCIP_PROPDATA
#define SCIP_DECL_PROPEXEC(x)
enum SCIP_Retcode SCIP_RETCODE
@ SCIP_ORBITOPETYPE_PACKING
enum SYM_Symtype SYM_SYMTYPE
@ SCIP_LEADERRULE_LASTINORBIT
@ SCIP_LEADERRULE_MAXCONFLICTSINORBIT
@ SCIP_LEADERRULE_FIRSTINORBIT
#define SYM_TIMING_DURINGPRESOL
@ SCIP_LEADERTIEBREAKRULE_MAXORBIT
@ SCIP_LEADERTIEBREAKRULE_MINORBIT
@ SCIP_LEADERTIEBREAKRULE_MAXCONFLICTSINORBIT
#define SYM_TIMING_AFTERPRESOL
#define SYM_TIMING_BEFOREPRESOL
#define SYM_HANDLETYPE_SYMBREAK
enum SCIP_OrbitopeType SCIP_ORBITOPETYPE
#define SYM_HANDLETYPE_SST
#define SYM_HANDLETYPE_ORBITALREDUCTION
#define SCIP_DECL_TABLEFREE(x)
struct SCIP_TableData SCIP_TABLEDATA
#define SCIP_DECL_TABLEOUTPUT(x)
#define SCIP_PROPTIMING_ALWAYS
@ SCIP_VARTYPE_CONTINUOUS
enum SCIP_Vartype SCIP_VARTYPE