[PPL-devel] a newbie question
Jie Ouyang
jouyang at oakland.edu
Mon Jun 13 03:09:52 CEST 2005
Sorry for this newbie question. I have a simple program as following
:-ensure_loaded('ppl_sicstus.pl').
main :-
ppl_initialize,
A='$VAR'(0),
B='$VAR'(1),
C='$VAR'(2),
ppl_new_Polyhedron_from_constraints(nnc,[A=0,B=C],H1),
ppl_new_Polyhedron_from_constraints(nnc,[A=1,B=C-1],H2),
ppl_Polyhedron_poly_hull_assign_and_minimize(H2,H1),
ppl_Polyhedron_get_constraints(H2,Cs),
write(Cs),
ppl_finalize.
The output is [-1*B+1*C>=0,1*B+ -1*C>= -1,1*A+1*B+ -1*C=0]. Although the
first two constraints are equivalent to A>=0 and A<=1, I am wondering if
there is a way to get the answer in the form [1*A>=0, -1*A>=-1, 1*A+1*B+
-1*C=0] instead of the previous one.
cheers,
Jie Ouyang
More information about the PPL-devel
mailing list