Warning:
This wiki has been archived and is now read-only.
PrimerExampleFunctional
From OWL
Namespace(=<http://example.com/owl/families#>) Namespace(f=<http://example.com/owl/families#>) Namespace(g=<http://example.com/owl2/families#>) Namespace(dc=<http://purl.org/dc/elements/1.1/#>) Namespace(xsd=<http://www.w3.org/2001/XMLSchema#>) Ontology(<http://example.com/owl/families> Import(<http://example.com/owl2/families.owl>) // Object property: http://example.com/owl/families#hasWife Declaration(ObjectProperty(hasWife)) ObjectPropertyDomain(hasWife Person) ObjectPropertyDomain(hasWife Man) ObjectPropertyRange(hasWife Person) ObjectPropertyRange(hasWife Woman) FunctionalObjectProperty(hasWife) InverseFunctionalObjectProperty(hasWife) IrreflexiveObjectProperty(hasWife) AsymmetricObjectProperty(hasWife) SubObjectPropertyOf(hasWife hasSpouse) SubObjectPropertyOf(hasWife loves) // Object property: http://example.com/owl/families#hasHusband Declaration(ObjectProperty(hasHusband)) InverseObjectProperties(hasHusband hasWife) // Object property: http://example.com/owl/families#hasSon Declaration(ObjectProperty(hasSon)) ObjectPropertyDomain(hasSon Person) ObjectPropertyDomain(hasSon Parent) ObjectPropertyRange(hasSon Person) ObjectPropertyRange(hasSon ObjectIntersectionOf(Person ObjectHasValue(hasGender male))) SubObjectPropertyOf(hasSon hasChild) DisjointObjectProperties(hasSon hasDaughter) SubObjectPropertyOf(SubObjectPropertyChain(hasSpouse hasSon) hasSon) // Object property: http://example.com/owl/families#hasDaughter Declaration(ObjectProperty(hasDaughter)) ObjectPropertyDomain(hasDaughter Person) ObjectPropertyDomain(hasDaughter Parent) ObjectPropertyRange(hasDaughter Person) ObjectPropertyRange(hasDaughter ObjectIntersectionOf(Person ObjectHasValue(hasGender female))) SubObjectPropertyOf(hasDaughter hasChild) SubObjectPropertyOf(SubObjectPropertyChain(hasSpouse hasDaughter) hasDaughter) // Object property: http://example.com/owl/families#hasGender Declaration(ObjectProperty(hasGender)) // Object property: http://example.com/owl/families#hasChild Declaration(ObjectProperty(hasChild)) ObjectPropertyDomain(hasChild Person) ObjectPropertyRange(hasChild Person) SubObjectPropertyOf(hasChild InverseObjectProperty(hasAncestor)) // Object property: http://example.com/owl/families#hasAncestor Declaration(ObjectProperty(hasAncestor)) TransitiveObjectProperty(hasAncestor) IrreflexiveObjectProperty(hasAncestor) // Object property: http://example.com/owl/families#hasSpouse Declaration(ObjectProperty(hasSpouse)) SymmetricObjectProperty(hasSpouse) IrreflexiveObjectProperty(hasSpouse) // Object property: http://example.com/owl/families#loves ObjectPropertyDomain(loves Person) Declaration(ObjectProperty(loves)) // Data property: http://example.com/owl/families#hasAge Declaration(DataProperty(hasAge)) DataPropertyDomain(hasAge Person) DataPropertyRange(hasAge xsd:integer) FunctionalDataProperty(hasAge) // Class: http://example.com/owl/families#Person Declaration(OWLClass(Person)) SubClassOf(Person ObjectIntersectionOf(DataExactCardinality(1 hasAge) ObjectExactCardinality(1 hasGender) ObjectAllValuesFrom(hasGender ObjectOneOf(female male)))) // Class: http://example.com/owl/families#Man Declaration(OWLClass(Man)) SubClassOf(Man Person) EquivalentClasses(Man ObjectIntersectionOf(Person ObjectHasValue(hasGender male))) // Class: http://example.com/owl/families#Woman Declaration(OWLClass(Woman)) SubClassOf(Woman Person) EquivalentClasses(Woman ObjectIntersectionOf(Person ObjectHasValue(hasGender female))) // Class: http://example.com/owl/families#Parent Declaration(OWLClass(Parent)) SubClassOf(Parent Person) EquivalentClasses(Parent ObjectIntersectionOf(Person ObjectMinCardinality(1 hasChild Person))) // Class: http://example.com/owl/families#Teenager Declaration(OWLClass(Teenager)) EquivalentClasses(Teenager ObjectIntersectionOf(Person DataSomeValuesFrom(hasAge DatatypeRestriction(xsd:integer minInclusive "13"^^xsd:int maxExclusive "20"^^xsd:int)))) // Class: http://example.com/owl/families#Adult Declaration(OWLClass(Adult)) EquivalentClasses(Adult ObjectIntersectionOf(Person DataSomeValuesFrom(hasAge DatatypeRestriction(xsd:integer minInclusive "21"^^xsd:int)))) // Class: http://example.com/owl/families#Child Declaration(OWLClass(Child)) EquivalentClasses(Child ObjectIntersectionOf(Person ObjectComplementOf( DataSomeValuesFrom(hasAge DatatypeRestriction(xsd:integer minInclusive "21"^^xsd:int))))) // Class: http://example.com/owl/families#YoungChild Declaration(OWLClass(YoungChild)) EquivalentClasses(YoungChild ObjectIntersectionOf(Person ObjectComplementOf(ObjectUnionOf(Teenager Adult)))) // Class: http://example.com/owl/families#Marriage Declaration(OWLClass(Marriage)) EquivalentClasses(Marriage ObjectUnionOf(CivilMarriage ReligiousMarriage)) // Class: http://example.com/owl/families#ReligiousMarriage Declaration(OWLClass(ReligiousMarriage)) DisjointClasses(CivilMarriage ReligiousMarriage) // Class: http://example.com/owl/families#CivilMarriage Declaration(OWLClass(CivilMarriage)) // Class: http://example.com/owl/families#Narcissist Declaration(OWLClass(Narcissist)) EquivalentClasses(Narcissist ObjectIntersectionOf(Person ObjectExistsSelf(loves))) // Individual: http://example.com/owl/families#male Declaration(Individual(male)) DifferentIndividuals(male female) // Individual: http://example.com/owl/families#female Declaration(Individual(female)) // Individual: http://example.com/owl/families#John Declaration(Individual(John)) ClassAssertion(Person John) ObjectPropertyAssertion(hasWife John Mary) ObjectPropertyAssertion(hasSon John Bill) ObjectPropertyAssertion(hasDaughter John Susan) DataPropertyAssertion(hasAge John "33"^^xsd:integer) ObjectPropertyAssertion(hasGender John male) SameIndividuals(John Jack) DifferentIndividuals(John Mary Bill Susan) // Individual: http://example.com/owl/families#Mary Declaration(Individual(Mary)) ObjectPropertyAssertion(hasSon Mary Bill) ObjectPropertyAssertion(hasDaughter Mary Susan) DataPropertyAssertion(hasAge Mary "31"^^xsd:integer) ObjectPropertyAssertion(hasGender Mary female) // Individual: http://example.com/owl/families#Bill Declaration(Individual(Bill)) ClassAssertion(ObjectComplementOf(Narcissist) Bill) DataPropertyAssertion(hasAge Bill "13"^^xsd:integer) ObjectPropertyAssertion(hasGender Bill male) // Individual: http://example.com/owl/families#Susan Declaration(Individual(Susan)) DataPropertyAssertion(hasAge Susan "8"^^xsd:integer) ObjectPropertyAssertion(hasGender Susan female) // Individual: http://example.com/owl/families#Jeff Declaration(Individual(Jeff)) ClassAssertion(ObjectExactCardinality(2 hasChild) Jeff) ObjectPropertyAssertion(hasWife Jeff Emily) ObjectPropertyAssertion(hasChild Jeff Ellen) ObjectPropertyAssertion(hasChild Jeff Jack) DataPropertyAssertion(hasAge Jeff "77"^^xsd:integer) ObjectPropertyAssertion(loves Jeff Jeff) DifferentIndividuals(Jeff Emily Jack Ellen Susan) // Individual: http://example.com/owl/families#Emily Declaration(Individual(Emily)) ClassAssertion(DataSomeValuesFrom(hasAge DataOneOf("39"^^xsd:integer "49"^^xsd:integer)) Emily) // Individual: http://example.com/owl/families#Ellen Declaration(Individual(Ellen)) ClassAssertion( DataSomeValuesFrom(hasAge DatatypeRestriction(xsd:integer minInclusive "15"^^xsd:int maxInclusive "21"^^xsd:int)) Ellen) // Individual: http://example.com/owl/families#Jack Declaration(Individual(Jack)) NegativeDataPropertyAssertion(hasAge Jack "53"^^xsd:integer) SameIndividuals(male g:masculine) SameIndividuals(female g:feminine) EquivalentClasses(Adult g:Grownup) EquivalentObjectProperties(hasChild g:child) EquivalentDataProperties(hasAge g:age) )