ADDED: support for lower and upper bounds on variable size
4 views
Skip to first unread message
Adam Kiezun
unread,
Dec 12, 2009, 12:16:10 AM12/12/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to hampi-devel
I just added support for min..max size of the string variable. So
stuff like this works:
var v : 1 .. 1000 ;
assert v contains "abc";
assert v contains "cde";
assert v contains "deg";
This feature will find the size that satisfies the constraints (if any does).
The implementation is currently naive (iterate through the size from
min to max). Ideas for optimizations are welcome - I'm sure there's
plenty of smart things to be done (heuristics and others).
./adam
Tim Hinrichs
unread,
Dec 13, 2009, 2:07:34 PM12/13/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to hampi...@googlegroups.com
I don't know if you're funneling bug reports somewhere else. If so,
I'm happy to redirect.
It looks like there's a bug with the NOT IN construct. It appeared
in one of my tests, and so I found the same bug among the tests
provided with Hampi.
Filename: testSolveNotIn1.hmp
-------------------
var v:1;
reg r1:= or("a", "b");
reg r2:= "a";
assert v in r1;
assert v not in r2;
//v="b" is the only solution
-------------------
hampi testSolveNotIn1.hmp
{VAR(v)=a}
The version of Hampi I'm using was the one available from google code
a few days ago.
Tim
Adam Kiezun
unread,
Dec 13, 2009, 2:18:27 PM12/13/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to hampi...@googlegroups.com
Yes, sending bug reports here is fine.
Have you used the latest from SVN or the download?
I think this bug was fixed a while back but we did not create an updated jar.
I checked, it works on the latest:
{VAR(v)=b}
./adam
Adam Kiezun
unread,
Dec 13, 2009, 2:47:06 PM12/13/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to hampi...@googlegroups.com
Tim,
I just updated the featured download on the hampi site
(http://code.google.com/p/hampi/). Please try to see if the problem
goes away.
./adam
Tim Hinrichs
unread,
Dec 13, 2009, 3:53:00 PM12/13/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to hampi...@googlegroups.com
Adam,
I had been downloading the zip file. I'll use svn in the future.
The problem disappeared with the new release. Thanks!