Skip to content

Commit

Permalink
Fix some FlatZinc builtins for SCIP to be 1D
Browse files Browse the repository at this point in the history
  • Loading branch information
cyderize committed Nov 27, 2023
1 parent 53f2eac commit 210f589
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions share/minizinc/linear/fzn_circuit.mzn
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ predicate fzn_circuit(array[int] of var int: x) =
constraint assert( l==min( index_set_2of2( eq_x ) ), "circuit: index set mismatch" ), %% self-mapping
constraint assert( u==max( index_set_2of2( eq_x ) ), "circuit: index set mismatch" ),
} in
circuit__SECcuts( eq_x )
circuit__SECcuts(array1d(eq_x))
else true endif /\
if nMZN__fSECcuts<2 then
%%% MTZ model. Note that INTEGER order vars seem better!:
Expand All @@ -38,5 +38,5 @@ predicate fzn_circuit(array[int] of var int: x) =
endif;

%-----------------------------------------------------------------------------%
predicate circuit__SECcuts(array[int,int] of var int: x); %% passed on
predicate circuit__SECcuts(array[int] of var int: x); %% passed on
%-----------------------------------------------------------------------------%
2 changes: 1 addition & 1 deletion share/minizinc/linear/fzn_lex_chain_lesseq_int.mzn
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ include "fzn_lex_chain_lesseq_orbitope.mzn";

predicate fzn_lex_chain_lesseq_int(array[int, int] of var int: a) =
if MZN__Orbitope /\ dom_array(a) subset 0..1 then
fzn_lex_chain_lesseq__orbitope( a,
fzn_lex_chain_lesseq__orbitope( array1d(a),
card(index_set_1of2(a)), 0, true,
not mzn_in_symmetry_breaking_constraint()
)
Expand Down
4 changes: 2 additions & 2 deletions share/minizinc/linear/fzn_lex_chain_lesseq_orbitope.mzn
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ include "lex_lesseq.mzn";
predicate fzn_lex_chain_lesseq_orbitope(
array[int, int] of var int: a, int: kind) =
if MZN__Orbitope then
fzn_lex_chain_lesseq__orbitope( a,
fzn_lex_chain_lesseq__orbitope( array1d(a),
card(index_set_1of2(a)), kind, true,
not mzn_in_symmetry_breaking_constraint()
)
Expand All @@ -13,7 +13,7 @@ predicate fzn_lex_chain_lesseq_orbitope(


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SCIP 7.0.2, binary matrix, columns sorted
predicate fzn_lex_chain_lesseq__orbitope(array[int, int] of var int: matr,
predicate fzn_lex_chain_lesseq__orbitope(array[int] of var int: matr,
int: m, int: orbType, bool: resolveprop, bool: isModelCons);


Expand Down

0 comments on commit 210f589

Please sign in to comment.