[gecode-users] a help with matrix and a function for a constraint verification
Claudio Cesar de Sá
claudio at colmeia.udesc.br
Thu Apr 8 14:07:12 CEST 2010
Dear coleauges
The problem is easy in its formulation... however, it has been
difficult for me.
The output desired is a matrix NxN, filled with 0 and 1.
This matrix must be accepted by a checker function,
i.e., it is a constraint such:
f_checker( MATRIX , parameter_fix ) == TRUE
so, if this f_checker return TRUE, this solution admissible.
Questions:
Is possible to use something like
IntVarArray my_matrix; //
...................
public:
/// Actual model
My_problem(const SizeOptions& opt) :
my_matrix(*this, size*size, 0, 1)
{
Matrix<IntVarArray> MATRIX( my_matrix , size, size);
//How to post the constraint from a function, like:
f_checker( MATRIX , parameter_fix ) == TRUE
is it works?
// Install branching
branch(*this, my_matrix , INT_VAR_NONE, INT_VAL_MAX);
}
Is exist any alternative for directly to use matrix in Gecode?
Alternatives to work with matrix and constraints?
claudio
(
))
|""|-.
|__|-'
**********************************************************************
Skype: claudio_cesar_sa
Links:
http://laic.u-clermont1.fr/
http://www.colmeia.udesc.br/
http://www2.joinville.udesc.br/~coca/
http://www2.joinville.udesc.br/~esp7maratona/
Blog: http://claudiocesar.wordpress.com/
***********************************************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.gecode.org/pipermail/users/attachments/20100408/79ca1f23/attachment.html>
More information about the users
mailing list