Hi,
I have written an ontology to represent a sudoku puzzle. I have the sudoku problem instance in a text file. I'm not sure how to attach the values in the problem to the ontology. This is the ontology. It is very basic and I do not need much inferencing as this is just being used as a test scenario to learn how to instantiate an ontology.
<owl:AnnotationProperty rdf:about="&rdfs;isDefinedBy"/>
<!-- http://www.w3.org/2002/07/owl#topDataProperty -->
<owl:DatatypeProperty rdf:about="&owl;topDataProperty"/>
<!--
///////////////////////////////////////////////////////////////////////////////////////
//
// Classes
//
///////////////////////////////////////////////////////////////////////////////////////
-->
<!-- http://www.semanticweb.org/ontologies/2010/5/Ontology1277199326108.owl#column -->
<owl:Class rdf:about="&Ontology1277199326108;column"/>
<!-- http://www.semanticweb.org/ontologies/2010/5/Ontology1277199326108.owl#row -->
<owl:Class rdf:about="&Ontology1277199326108;row">
<rdfs:isDefinedBy>column</rdfs:isDefinedBy>
</owl:Class>
<!-- http://www.semanticweb.org/ontologies/2010/5/Ontology1277199326108.owl#sudoku -->
<owl:Class rdf:about="&Ontology1277199326108;sudoku">
<rdfs:isDefinedBy>rows</rdfs:isDefinedBy>
</owl:Class>
<!--
///////////////////////////////////////////////////////////////////////////////////////
//
// Individuals
//
///////////////////////////////////////////////////////////////////////////////////////
-->
<!-- http://www.semanticweb.org/ontologies/2010/5/Ontology1277199326108.owl#rownum -->
<owl:NamedIndividual rdf:about="&Ontology1277199326108;rownum">
<rdf:type rdf:resource="&Ontology1277199326108;column"/>
<rdf:type rdf:resource="&Ontology1277199326108;row"/>
<owl:topDataProperty rdf:datatype="&xsd;integer"></owl:topDataProperty>
</owl:NamedIndividual>
<!-- http://www.semanticweb.org/ontologies/2010/5/Ontology1277199326108.owl#value -->
<owl:NamedIndividual rdf:about="&Ontology1277199326108;value">
<rdf:type rdf:resource="&Ontology1277199326108;column"/>
<owl:topDataProperty rdf:datatype="&xsd;integer"></owl:topDataProperty>
</owl:NamedIndividual>
and a problem instance is
0 0 3 1 2 0 0 9 0
1 0 2 0 0 3 6 0 0
7 0 0 9 6 8 2 1 0
0 0 0 8 0 0 7 0 0
6 0 5 4 7 1 8 0 0
0 8 0 0 0 9 5 0 0
0 0 6 7 1 2 0 0 0
0 0 0 0 0 0 0 0 6
2 1 8 0 9 5 0 7 4
If i'm using the Java API, is there some way to assign the appropriate values to the 'values' NamedIndividual of 'column' class?