# rules for establishing a class hierarchy # possible queries: # ?what a :x where :x is a class. This returns all possible instances of # a class. # ?what owl:subClassOf :x. Returns all subclasses of :x. # :x owl:subClassOf ?what. Returns all superclasses of :x. # ?what owl:subClassOf owl:Thing gives all classes. # all classes are subClassOf owl:Thing {:c a owl:Class.} log:implies {:c owl:subClassOf owl:Thing}; log:forAll :c. # definition of transitivity {:c owl:subClassOf :c1. :c1 owl:subClassOf :c2.}log:implies {:c owl:subClassOf :c2}; log:forAll :c, :c1, :c2. # an element of a subclass also belongs to the superclass {:c owl:subClassOf :c1. :x a :c } log:implies {:x a :c1}; log:forAll :c, :c1, :x. # if something is a subclass it is also a class {:c owl:subClassOf :c1} log:implies {:c a owl:Class}; log:forAll :c, :c1. # if something is a superclass it is also a class {:c owl:subClassOf :c1} log:implies {:c1 a owl:Class}; log:forAll :c, :c1. # if an item belongs to a list of classes it is a class {:x owl:oneOf :L} log:implies {:x a owl:Class}; log:forAll :x, :L. # owl:complementOf defines classes {:x owl:complementOf :y} log:implies {:x a owl:Class}; log:forAll :x, :y. {:x owl:complementOf :y} log:implies {:y a owl:Class}; log:forAll :x, :y.