On Jun 19, 2007, at 2:07 AM, Wolfgang Laun wrote:

One other system I know of lets you write (adopting the Jess syntax)

(defrule crossover
?e <- (side {?e.occup == FALSE}) ; or some way of saying "this"?
?w <- (side {?w.occup == TRUE})
?br <- (bridge {?br.occup == FALSE}
{?br.east == ?e}
{?br.west == ?w})
=>
(printout t ?br.name " " ?e.name " " ?w.name crlf)

You have guessed (something very close to) the syntax that we're using in Jess 7.1 . I think the leading "?" won't be needed, and within a single pattern, you can leave off the fact reference and that will refer to the slot from the fact matching that pattern.


---------------------------------------------------------
Ernest Friedman-Hill
Advanced Software Research          Phone: (925) 294-2154
Sandia National Labs                FAX:   (925) 294-2234
PO Box 969, MS 9012                 [EMAIL PROTECTED]
Livermore, CA 94550                 http://www.jessrules.com

--------------------------------------------------------------------
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