27 Nov 2006 19:45
Re: datalog operations allowed
John Whaley <joewhaley <at> gmail.com>
2006-11-27 18:45:08 GMT
2006-11-27 18:45:08 GMT
Hi David, For operations like addition and multiplication, you will need to build up a BDD that implements that function and load it in. For example, for multiplication you will need to make your own BDD that contains the multiplication table, i.e. it should have these tuples: mult(1,1,1). mult(1,2,2). mult(2,1,2). mult(2,2,4). mult(3,1,3). mult(3,2,6). ... As you guessed, BDDs aren't too good at representing multiplication, but if you limit the number (up to say, 256x256) it should be tractable. Addition is no problem. Adding native support for addition would be pretty easy as the pieces are mostly there. Just need to edit the parser to parse it correctly: see parseRuleTerm() in DatalogParser.java, and then use buildAdd() in BDDDomain.java or add() in BDDBitVector.java to actually build the addition relation. Let me know if you have any more questions. -John On 11/16/06, David Brumley <dbrumley <at> cs.cmu.edu> wrote:(Continue reading)
RSS Feed