solving system of inequalities
From: Alex Denisov (ad_at_nc.ru)
Date: 05/17/04
- Previous message: gai luron: "Re: it seems easy..."
- Next in thread: Markus Triska: "Re: solving system of inequalities"
- Reply: Markus Triska: "Re: solving system of inequalities"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 16 May 2004 20:35:15 -0700
this function is solving system of inequalities
mik(X,Y,Z,K,M):-
fd_domain([X,Y],0,20),
fd_domain(Z,3,20),
fd_domain(K,3,20),
fd_domain(M,5,15),
X - 2*Y - Z + K + M #> 20,
Y - X #> 2,
X #\= 16,
M - Y #< 12,
K - Z #> 0,
Z #\= 10.
And it do it very FAST. As I understand it doesn't use complete
enumeration. Does anybody know how does this algorithm work? The deal is I
have to write similar algotithm in C++. I'll be thankful for any help.
Alex Denisov.
- Previous message: gai luron: "Re: it seems easy..."
- Next in thread: Markus Triska: "Re: solving system of inequalities"
- Reply: Markus Triska: "Re: solving system of inequalities"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]