57 int v0,
int k0,
int lambda0)
62 void parse(
int& argc,
char* argv[]) {
74 std::cerr <<
"\t(unsigned int) default: " <<
v << std::endl
75 <<
"\t\tparameter v" << std::endl
76 <<
"\t(unsigned int) default: " <<
k << std::endl
77 <<
"\t\tparameter k" << std::endl
78 <<
"\t(unsigned int) default: " <<
lambda << std::endl
79 <<
"\t\tparameter lambda" << std::endl;
116 for (
int j=0; j<
opt.
b; j++)
120 for (
int i1=0; i1<
opt.
v; i1++)
121 for (
int i2=i1+1; i2<
opt.
v; i2++) {
123 for (
int j=0; j<
opt.
b; j++)
124 row[j] =
expr(*
this,
p(j,i1) &&
p(j,i2));
137 for (
int j=1; j<
opt.
b; j++)
152 for (
int i = 0;
i<
opt.
v;
i++) {
154 for (
int j = 0; j<
opt.
b; j++)
170 return new BIBD(*
this);
194 Script::run<BIBD,DFS,BIBDOptions>(
opt);
struct Gecode::@603::NNF::@65::@66 b
For binary nodes (and, or, eqv)
int p
Number of positive literals for node type.
Options for BIBD problems
int lambda
Parameters to be given on command line.
virtual void help(void)
Print help message.
int r
Derived parameters Derive additional parameters.
void parse(int &argc, char *argv[])
Parse options from arguments argv (number is argc)
BIBDOptions(const char *s, int v0, int k0, int lambda0)
Initialize options for example with name s.
Example: Balanced incomplete block design (BIBD)
int main(int argc, char *argv[])
Main-function.
const BIBDOptions & opt
Options providing access to parameters.
BIBD(const BIBDOptions &o)
Actual model.
BoolVarArray _p
Matrix of Boolean variables.
virtual Space * copy(void)
Copy during cloning.
BIBD(BIBD &s)
Constructor for cloning s.
@ SYMMETRY_LEX
Lex-constraints on rows/columns.
@ SYMMETRY_LDSB
LDSB on rows/columns.
@ SYMMETRY_NONE
No symmetry breaking.
virtual void print(std::ostream &os) const
Print solution.
Passing Boolean variables.
Parametric base-class for scripts.
Matrix-interface for arrays.
void symmetry(int v)
Set default symmetry value.
Collection of symmetries.
void update(Space &home, VarArray< Var > &a)
Update array to be a clone of array a.
void parse(int argc, char *argv[])
Parse commandline arguments.
void linear(Home home, const FloatVarArgs &x, FloatRelType frt, FloatVal c)
Post propagator for .
void rel(Home home, FloatVar x0, FloatRelType frt, FloatVar x1)
Post propagator for .
@ IRT_GQ
Greater or equal ( )
GECODE_FLATZINC_EXPORT FlatZincSpace * parse(const std::string &fileName, Printer &p, std::ostream &err=std::cerr, FlatZincSpace *fzs=NULL, Rnd &rnd=defrnd)
Parse FlatZinc file fileName into fzs and return it.
void branch(Home home, const IntVarArgs &x, const BoolVarArgs &y, IntBoolVarBranch vars, IntValBranch vals)
Branch function for integer and Boolean variables.
Gecode toplevel namespace
IntVar expr(Home home, const LinIntExpr &e, const IntPropLevels &ipls=IntPropLevels::def)
Post linear expression and return its value.
BoolValBranch BOOL_VAL_MIN(void)
Select smallest value.
BoolVarBranch BOOL_VAR_NONE(void)
Select first unassigned variable.
SymmetryHandle rows_interchange(const Matrix< A > &m)
Interchangeable rows symmetry specification.
SymmetryHandle columns_interchange(const Matrix< A > &m)
Interchangeable columns symmetry specification.
Gecode::IntArgs i({1, 2, 3, 4})