# A weekly shop, which is what a bag is for: three items, and two of them have the same
# content, because a bag - unlike a set - may hold several copies of one thing. Each item
# is the membership, and its content is the product the membership refers to.

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

ex:WeeklyShop a owl:NamedIndividual , bag:Bag ;
    rdfs:label "the weekly shop" ;
    bag:size 3 ;
    bag:hasItem ex:FirstTinOfTomatoes ,
        ex:SecondTinOfTomatoes ,
        ex:TheLoaf .

ex:FirstTinOfTomatoes a owl:NamedIndividual , bag:Item ;
    rdfs:label "first tin of tomatoes in the shop" ;
    bag:itemContent ex:ChoppedTomatoes400g .

ex:SecondTinOfTomatoes a owl:NamedIndividual , bag:Item ;
    rdfs:label "second tin of tomatoes in the shop, the same product again" ;
    bag:itemContent ex:ChoppedTomatoes400g .

ex:TheLoaf a owl:NamedIndividual , bag:Item ;
    rdfs:label "the loaf in the shop" ;
    bag:itemContent ex:SourdoughLoaf .

ex:ChoppedTomatoes400g a owl:NamedIndividual ;
    rdfs:label "chopped tomatoes, 400 g tin - the product, not the item" .

ex:SourdoughLoaf a owl:NamedIndividual ;
    rdfs:label "sourdough loaf - the product, not the item" .

# Only one direction of each inverse pair is asserted: hasItem/itemOf, hasMember/isMemberOf. A reasoner adds the other.

