# KEHOME/doc/ClassAndSubclass.txt
# Nov/13/2002

Class and Subclass
==================
Author: Richard H. McCullough
Date: November 13, 2002


Contents
========
Abstract
Class: meaning vs. programming
Subclass: exclusive vs. inclusive
Example: OWL Classes
Remarks
References


Abstract
========
The purpose of this document is to clarify the meaning
of "Class" and "Subclass".  These concepts are
introduced with a simple example, and then applied
to OWL Classes.


Class: meaning vs. programming
==============================
We start with a simple universe consisting of people and
dogs.  We initially identify two people, John and Mary,
and two dogs, Fido and Rover.

In the meaning view, we use this hierarchy to file
information about this universe:

existent
    person
	John
	Mary
    dog
	Fido
	Rover
    property

existent, person, dog and property are Classes.
John, Mary, Fido and Rover are Instances.
property is used to store specific Classes of
information about people and dogs.  (We will
discuss properties in the next section.)
As we identify more people, dogs and properties
they can be added to the hierarchy.

In the programming view, we identify the data
structures used to file information:

data structure
    class
	existent
	person
	dog
	property
    instance
	John
	Mary
	Fido
	Rover


Subclass: exclusive vs. inclusive
=================================
Two properties of people and dogs are sex and
weight.  We add them to the meaning hiearchy
as follows:

property
    sex
	John has sex=male
	Mary has sex=female
	Fido has sex=male
	Rover has sex=female
    weight
	John has weight=180 pounds
	Mary has weight=110 pounds
	Fide has weight=15 pounds
	Rover has weight=10 pounds

sex and weight are Subclasses of property.
Each "has" statement is an Instance of the
sex or weight property.

As we expand the meaning hierarchy, it is
useful to observe that some Classes are
Subclasses of other Classes.  (Subclass is
another property.)  Two different forms of
Subclass are commonly used, exclusive and
inclusive, which we will denote by "isa"
and "isa*".  For example:

sex isa property
property isa existent
sex isa* sex
sex isa* property
sex isa* existent

In other words:
"isa" denotes Classes separated by 1 level;
"isa*" denotes Classes separated by 0 or more levels.

The KR language [2] uses "isa".
The OWL language [1] uses "isa*" (subClassOf
and subPropertyOf).


Example: OWL Classes
====================
To get an overall view of the OWL vocabulary, we begin
with the programming hierarchy:

data structure
    class
	Class
	Datatype
	Thing
	Nothing
	Restriction
	ObjectProperty
	DatatypeProperty
	TransitiveProperty
	SymmetricProperty
	FunctionalProperty
	InverseFunctionalProperty
	Ontology
	Literal
	Property
    property
	equivalentTo
	sameClassAs
	samePropertyAs
	sameIndividualAs
	disjointWith
	differentIndividualFrom
	unionOf
	disjointUnionOf
	intersectionOf
	complementOf
	oneOf
	onProperty
	allValuesFrom
	hasValue
	someValuesFrom
	minCardinality
	maxCardinality
	cardinality
	inverseOf
	versionInfo
	imports
	subPropertyOf
	type
	value
	subClassOf
	domain
	range
	label
	comment
	seeAlso
	isDefinedBy
    instance

Here is the meaning lattice (it is not
a hierarchy because the Subclasses are
not mutually exclusive):

Nothing  # nonexistent

Thing  # existent
    Class  # entity
	Ontology
	Datatype
	Restriction
	Literal
    Property  # attribute
	ObjectProperty
	    SymmetricProperty
	    TransitiveProperty
	    InverseFunctionalProperty
	DatatypeProperty
	FunctionalProperty

	equivalentTo  # is
	    sameClassAs  # is
	    samePropertyAs  # is
	    sameIndividualAs  # is
	disjointWith
	differentIndividualFrom
	unionOf  # isall
	disjointUnionOf  # isall
	intersectionOf
	complementOf  # not
	oneOf  # isany
	onProperty
	allValuesFrom
	hasValue
	someValuesFrom
	minCardinality
	maxCardinality
	cardinality
	inverseOf
	versionInfo
	imports
	subPropertyOf  # isa*
	    samePropertyAs  # is
	type
	value
	subClassOf  # isa*
	    sameClassAs  # is
	domain
	range
	label
	comment
	seeAlso
	    isDefinedBy

Some of the Subclass relations are omitted.
For example:

subClassOf isa* TransitiveProperty
subPropertyOf isa* TransitiveProperty


Remarks
=======
The OWL Class is primarily a data structure
used to represent a concept; it is an essential
element in the programming hierarchy.

In the context of the meaning hierarchy, the
OWL Class simply denotes an entity.  The KR
version of OWL [2] omits statements such as

Property isa* Class
Thing isa* Class

because they are contradictions.

A more comprehensive meaning hierarchy,
tabula rasa, is given in [3],[4].
The KR language and its implementation
are described in [5],[6].


References
#=========
[1] OWL in RDF
    "http://www.w3.org/2002/07/owl"
[2] OWL in KR
    "http://rhm.cdepot.net/knowledge/application/SemanticWeb/OWL/owl.ku"
[3] tabula rasa hierarchy
    "http://rhm.cdepot.net/kb/tabrasa.ku"
[4] tabula rasa definitions
    "http://rhm.cdepot.net/kb/tabrasa.def"
[5] KR grammar
    "http://rhm.cdepot.net/doc/KRgrammar.txt"
[6] KR implementation
    "http://rhm.cdepot.net/doc/KEtutorial.txt"
