# The specieshabitat pattern on the scenario the pattern asks about: which species have a
# demersal habitat in the western Baltic. Cod and flounder in the ICES Subdivision 22-24 stock
# live on or near the sea bed; herring in the same waters is pelagic. Habitat is a thing here,
# not a string, so two species can share one habitat individual.

@prefix aquaticresources: <http://www.ontologydesignpatterns.org/cp/owl/fsdas/aquaticresources.owl#> .
@prefix specieshabitat:   <http://www.ontologydesignpatterns.org/cp/owl/fsdas/specieshabitat.owl#> .
@prefix ex:               <https://w3id.org/ontoboard/example/specieshabitat#> .
@prefix owl:              <http://www.w3.org/2002/07/owl#> .
@prefix rdfs:             <http://www.w3.org/2000/01/rdf-schema#> .

ex:WesternBalticCodStock a owl:NamedIndividual , aquaticresources:AquaticResource ;
    rdfs:label "the western Baltic cod stock (ICES Subdivisions 22-24)" ;
    aquaticresources:hasSpecies ex:AtlanticCod , ex:EuropeanFlounder .

ex:WesternBalticHerringStock a owl:NamedIndividual , aquaticresources:AquaticResource ;
    rdfs:label "the western Baltic spring-spawning herring stock (ICES Subdivisions 22-24)" ;
    aquaticresources:hasSpecies ex:AtlanticHerring .

ex:AtlanticCod a owl:NamedIndividual , aquaticresources:AquaticSpecies ;
    rdfs:label "Atlantic cod (Gadus morhua)" ;
    specieshabitat:hasHabitat ex:DemersalHabitat .

ex:EuropeanFlounder a owl:NamedIndividual , aquaticresources:AquaticSpecies ;
    rdfs:label "European flounder (Platichthys flesus)" ;
    specieshabitat:hasHabitat ex:DemersalHabitat .

ex:AtlanticHerring a owl:NamedIndividual , aquaticresources:AquaticSpecies ;
    rdfs:label "Atlantic herring (Clupea harengus)" ;
    specieshabitat:hasHabitat ex:PelagicHabitat .

ex:DemersalHabitat a owl:NamedIndividual , specieshabitat:Habitat ;
    rdfs:label "demersal habitat: on or just above the sea bed" .

ex:PelagicHabitat a owl:NamedIndividual , specieshabitat:Habitat ;
    rdfs:label "pelagic habitat: the open water column" .

# Only one direction of each inverse pair is asserted: canOccurIn/isAreaOfOccurrenceOf, hasHabitat/isHabitatFor, hasSpecies/isSpeciesPresentIn. A reasoner adds the other.

