OWL (4. Übung SWebT1 WS07/08)
Aus Semantic-Web-Grundlagen
Version vom 14:26, 7. Jan. 2008 bei Markus Krötzsch (Diskussion | Beiträge)
Übung | |
---|---|
OWL
| |
Dozent | Markus Krötzsch |
Datum | Jan 7 2008 |
von | 11:30 |
bis | 13:00 |
Ort | Gebäude 11.40 Raum 231 |
Veranstaltungsreihe SWebT1 WS07/08
| |
Nummer | 4 |
Diese Übung umfasst Stoff aus den vorangegangenen beiden Vorlesungen zu OWL-Syntax und der OWL-Semantik.
Download: Übungsblatt (PDF)
Lösungen
Aufgabe 4.2
<rdf:RDF
xmlns = "http<nowiki>://</nowiki>example.org/"
xmlns:rdf ="http<nowiki>://</nowiki>www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:rdfs ="http<nowiki>://</nowiki>www.w3.org/2000/01/rdf-schema#"
xmlns:owl ="http<nowiki>://</nowiki>www.w3.org/2002/07/owl#"
>
<!-- Aussage 1 -->
<owl:Class rdf:about="Gemüse">
<rdfs:subClassOf rdf:resource="PizzaBelag" />
</owl:Class>
<!-- Aussage 2 -->
<owl:Class rdf:about="PizzaBelag">
<owl:disjointWith rdf:resource="Pizza" />
</owl:Class>
<!-- Aussage 3 -->
<Gemüse rdf:about="Aubergine" />
<!-- Aussage 4 -->
<owl:ObjectProperty rdf:about="hatBelag">
<rdfs:range rdf:resource="PizzaBelag" />
<rdfs:domain rdf:resource="Pizza" />
</owl:ObjectProperty>
<!-- Aussage 5 -->
<owl:Class rdf:about="Pizza">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:minCardinality
rdf:datatype="http<nowiki>://</nowiki>www.w3.org/2001/XMLSchema#nonNegativeInteger">
2
</owl:minCardinality>
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- Aussage 6 -->
<owl:Class rdf:about="PizzaMargarita">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:hasValue rdf:resouce="tomate" />
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- Aussage 6 (alternativ) -->
<owl:Class rdf:about="PizzaMargarita">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:someValuesFrom rdf:resource="Tomate" />
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- Aussage 7 -->
<owl:Class rdf:about="VegetarischePizza">
<owl:equivalentClass>
<owl:intersectionOf rdf:parseType="Collection">
<owl:Class rdf:about="PizzaOhneFleisch" />
<owl:Class rdf:about="PizzaOhneFisch" />
</owl:intersectionOf>
</owl:equivalentClass>
</owl:Class>
<!-- Aussage 8 -->
<owl:Class rdf:about="PizzaMargarita">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:allValuesFrom>
<owl:complementOf rdf:resource="Fleisch"/>
</owl:allValuesFrom>
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
</rdf:RDF>
xmlns = "http<nowiki>://</nowiki>example.org/"
xmlns:rdf ="http<nowiki>://</nowiki>www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:rdfs ="http<nowiki>://</nowiki>www.w3.org/2000/01/rdf-schema#"
xmlns:owl ="http<nowiki>://</nowiki>www.w3.org/2002/07/owl#"
>
<!-- Aussage 1 -->
<owl:Class rdf:about="Gemüse">
<rdfs:subClassOf rdf:resource="PizzaBelag" />
</owl:Class>
<!-- Aussage 2 -->
<owl:Class rdf:about="PizzaBelag">
<owl:disjointWith rdf:resource="Pizza" />
</owl:Class>
<!-- Aussage 3 -->
<Gemüse rdf:about="Aubergine" />
<!-- Aussage 4 -->
<owl:ObjectProperty rdf:about="hatBelag">
<rdfs:range rdf:resource="PizzaBelag" />
<rdfs:domain rdf:resource="Pizza" />
</owl:ObjectProperty>
<!-- Aussage 5 -->
<owl:Class rdf:about="Pizza">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:minCardinality
rdf:datatype="http<nowiki>://</nowiki>www.w3.org/2001/XMLSchema#nonNegativeInteger">
2
</owl:minCardinality>
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- Aussage 6 -->
<owl:Class rdf:about="PizzaMargarita">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:hasValue rdf:resouce="tomate" />
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- Aussage 6 (alternativ) -->
<owl:Class rdf:about="PizzaMargarita">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:someValuesFrom rdf:resource="Tomate" />
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
<!-- Aussage 7 -->
<owl:Class rdf:about="VegetarischePizza">
<owl:equivalentClass>
<owl:intersectionOf rdf:parseType="Collection">
<owl:Class rdf:about="PizzaOhneFleisch" />
<owl:Class rdf:about="PizzaOhneFisch" />
</owl:intersectionOf>
</owl:equivalentClass>
</owl:Class>
<!-- Aussage 8 -->
<owl:Class rdf:about="PizzaMargarita">
<rdfs:subClassOf>
<owl:Restriction>
<owl:onProperty rdf:resource="hatBelag" />
<owl:allValuesFrom>
<owl:complementOf rdf:resource="Fleisch"/>
</owl:allValuesFrom>
</owl:Restriction>
</rdfs:subClassOf>
</owl:Class>
</rdf:RDF>
Aufgabe 4.4
- Gemüse PizzaBelag
- PizzaBelag Pizza
- Gemüse(Aubergine)
- hatBelag Pizza (Domain), hatBelag.PizzaBelag (Range)
- Pizza 2 hatBelag
- PizzaMargarita hatBelag.{tomate}
- Alternativ: PizzaMargarita hatBelag.Tomate
- VegetarischePizza PizzaOhneFleisch PizzaOhneFisch
- PizzaMargarita hatBelag. Fleisch
Fakten zu OWL (4. Übung SWebT1 WS07/08)RDF-Feed
Datum | 7. Januar 2008 + |
Dozent | Markus Krötzsch + |
Endzeit | 7. Januar 2008 13:00 + |
Nummer | 4 + |
Ort | Gebäude 11.40 Raum 231 + |
Serie | SWebT1 WS07/08 + |
Startzeit | 7. Januar 2008 11:30 + |
Titel | OWL + |
Unterlagen | Uebung4 owl.pdf + |