You're exactly right about what the problem reduces to; if you've read
the Jess manual and recall where it describes how rules may be split
into multiple subrules, each subrule corresponds to one branch of the
top-level OR Mihai mentions here. 

It's not actually a computationally hard problem, but it is tricky to
get it absolutely right. It's not so much getting the LHS into the
form you describe that's hard, it's correctly translating the
resulting tree into a Rete network that we're having troubles
with. NOT conditional elements have to be "wired up" differently than
other CEs, and there are special cases that arise.

I'm quite confident that all possible nestings will work correctly by
the 6.1 final release. The coverage is really quite good right now;
the O.P's particular combination of (not (and (or (not (and (or))))))
was one of the remaining exceptions.


I think Mihai Barbuceanu wrote:
> To solve this problem correctly in all cases, the Jess compiler would need the
> ability to
> convert any boolean formula into its DNF equivalent (an OR of AND-s with only
> positive or negative literals inside the AND-s).  The problem is that this
> conversion is NP-complete in general, therefore I'm not even sure if it's a
> good idea to have this feature in the first place.
> If  full DNF conversion is a goal of Jess, until this becomes available maybe
> we should not allow rules to use arbitrary nesting of and/or/not operators.
> 
> Mihai
> 
> 


---------------------------------------------------------
Ernest Friedman-Hill  
Distributed Systems Research        Phone: (925) 294-2154
Sandia National Labs                FAX:   (925) 294-2234
Org. 8920, MS 9012                  [EMAIL PROTECTED]
PO Box 969                  http://herzberg.ca.sandia.gov
Livermore, CA 94550

--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]
--------------------------------------------------------------------

Reply via email to