Retrieve question

View: New views
2 Messages — Rating Filter:   Alert me  

Retrieve question

by Lucas :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Please,

With the knowledge base below:

(defconcept(starship ?st))
(assert (starship ST0))
(assert (starship ST1))
(assert (starship ST2))

I need recover all starships don't equal to ST1 (ST0 and ST2).
I try use the retrieve command but don't can't build the correct statement.
 
thanks. (sorry for my poor english).

_______________________________________________
powerloom-forum mailing list
powerloom-forum@...
http://mailman.isi.edu/mailman/listinfo/powerloom-forum

Re: Retrieve question

by Thomas Russ :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


On Dec 27, 2007, at 3:49 AM, Laecio Lima wrote:

> Please,
>
> With the knowledge base below:
>
> (defconcept(starship ?st))
>
The proper syntax for a concept definition with no superclass would be

   (defconcept starship)

or

   (defconcept starship (?st))

>
> (assert (starship ST0))
> (assert (starship ST1))
> (assert (starship ST2))
>
> I need recover all starships don't equal to ST1 (ST0 and ST2).
> I try use the retrieve command but don't can't build the correct  
> statement.

(retrieve all (and (starship ?s) (not (= ?s st1))))


PL-USER |= (retrieve all (and (starship ?s) (not (= ?s st1))))

There are 2 solutions:
   #1: ?S=ST2
   #2: ?S=ST0

>
> thanks. (sorry for my poor english).
> _______________________________________________
> powerloom-forum mailing list
> powerloom-forum@...
> http://mailman.isi.edu/mailman/listinfo/powerloom-forum

_______________________________________________
powerloom-forum mailing list
powerloom-forum@...
http://mailman.isi.edu/mailman/listinfo/powerloom-forum
LightInTheBox - Buy quality products at wholesale price