90 bool isIdentity =
true;
109 for (
int j = 0; j < permlen; ++j)
111 if ( (
int) aut[j] != j )
123 for (
int j = 0; j < permlen; ++j)
160#define XSTR(x) STR(x)
165 return "dejavu " XSTR(DEJAVU_VERSION_MAJOR)
"." XSTR(DEJAVU_VERSION_MINOR);
171 return "Monte Carlo symmetry computation library by M. Anders (github.com/markusa4/dejavu)";
191 dejavu::static_graph* G,
207 assert( maxgenerators >= 0 );
235 dejavu::solver dejavu;
237 dejavu.set_prefer_dfs(
true);
240 dejavu.set_print(
false);
244 dejavu_hook dejavuhookglue = [&](
int n,
const int* p,
int nsupp,
const int* suppa) {
249 dejavu.automorphisms(G, &dejavuhookglue);
270 dejavu::big_number size = dejavu.get_automorphism_group_size();
271 *log10groupsize = (
SCIP_Real) size.exponent + log10(size.mantissa);
307 dejavu::static_graph dejavugraph;
313 dejavugraph.dump_dimacs(filename);
341 dejavu::static_graph dejavugraph;
356 for (
int p = 0; p <
nperms && ! success; ++p)
358 for (
int i = 0;
i < nnodesfromG1; ++
i)
360 if (
perms[p][
i] >= nnodesfromG1 )
368 for (
int p = 0; p <
nperms; ++p)
SCIP_RETCODE SYMbuildDejavuGraphCheck(SCIP *scip, dejavu::static_graph *dejavugraph, SYM_GRAPH *G1, SYM_GRAPH *G2, int *nnodes, int *nnodesfromG1, SCIP_Bool *success)
SCIP_RETCODE SYMbuildDejavuGraph(SCIP *scip, dejavu::static_graph *dejavugraph, SYM_GRAPH *graph, SCIP_Bool *success)
methods to build dejavu graph for symmetry detection
interface for symmetry computations
SCIP_Bool SYMcheckGraphsAreIdentical(SCIP *scip, SYM_SYMTYPE symtype, SYM_GRAPH *G1, SYM_GRAPH *G2)
const char * SYMsymmetryGetName(void)
static void dejavuhook(void *user_param, int n, const int *aut, int nsupp, const int *suppa)
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)
static SCIP_RETCODE computeAutomorphisms(SCIP *scip, SYM_SYMTYPE symtype, dejavu::static_graph *G, int nsymvars, int maxgenerators, int ***perms, int *nperms, int *nmaxperms, SCIP_Real *log10groupsize, SCIP_Bool restricttovars, SCIP_Real *symcodetime)
Constraint handler for linear constraints in their most general form, .
constraint handler for nonlinear constraints specified by algebraic expressions
#define SCIP_CALL_ABORT(x)
private functions to work with algebraic expressions
power and signed power expression handlers
variable expression handler
const char * SCIPgetProbName(SCIP *scip)
#define SCIPfreeBlockMemoryArray(scip, ptr, num)
int SCIPcalcMemGrowSize(SCIP *scip, int num)
#define SCIPallocBlockMemoryArray(scip, ptr, num)
#define SCIPreallocBlockMemoryArray(scip, ptr, oldnum, newnum)
#define SCIPfreeBlockMemoryArrayNull(scip, ptr, num)
SCIP_Real SCIPgetSolvingTime(SCIP *scip)
SYM_SYMTYPE SCIPgetSymgraphSymtype(SYM_GRAPH *graph)
int SCIPgetSymgraphNVars(SYM_GRAPH *graph)
assert(minobj< SCIPgetCutoffbound(scip))
public methods for memory management
methods for dealing with symmetry detection graphs
struct SYM_Graph SYM_GRAPH
enum SCIP_Retcode SCIP_RETCODE
enum SYM_Symtype SYM_SYMTYPE