Re: how to bind a variable with multislots in the LHS?
"Johan Lindberg" <[email protected]> Mon, 24 Mar 2008 17:50:31 +0100
| Newsgroups | gmane.lisp.lisa.general |
|---|---|
| Message-ID | <[email protected]> |
Hi Pedro, I really meant to reply to your previous post earlier but I completely forgot, I am sorry. I ran into this (or at least a very similar) problem a few months ago when I was comparing CLIPS and Lisa. The problem, as you have already figured out, lies in that there are no multislots in Lisa. This will make it difficult for you to do a direct translation of the puzzle. If you assert a list in a slot you can either match it as-is or provide your own comparison function. See http://commentsarelies.blogspot.com/2007/10/another-clips-and-lisa-comparison.html for an example. Personally I think you should define a template for each of the implied facts, not only is it more readable, it is also faster. Mutlislots are terribly slow in CLIPS. I love them because they allow me to express a pattern match very clearly and concisely but I hate them because whenever I pour in a few thousand facts matching such a rule I might as well call it a day. Good luck Johan Lindberg [email protected] ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/