为什么推理者推断这个类是这个类的子类

Ani*_*vid 0 rdf semantic-web owl ontology protege

这是我的第一堂课Ratings2016,它是一个等同的类:评级和createdOn的值大于2016.

<!-- http://semanticrecommender.com/rs#Ratings2016 -->

    <owl:Class rdf:about="http://semanticrecommender.com/rs#Ratings2016">
        <owl:equivalentClass>
            <owl:Class>
                <owl:intersectionOf rdf:parseType="Collection">
                    <rdf:Description rdf:about="http://semanticrecommender.com/rs#Rates"/>
                    <owl:Restriction>
                        <owl:onProperty rdf:resource="http://semanticrecommender.com/rs#createdOn"/>
                        <owl:someValuesFrom>
                            <rdfs:Datatype>
                                <owl:onDatatype rdf:resource="http://www.w3.org/2001/XMLSchema#dateTime"/>
                                <owl:withRestrictions rdf:parseType="Collection">
                                    <rdf:Description>
                                        <xsd:minInclusive rdf:datatype="http://www.w3.org/2001/XMLSchema#dateTime">2016-01-01T00:00:00</xsd:minInclusive>
                                    </rdf:Description>
                                </owl:withRestrictions>
                            </rdfs:Datatype>
                        </owl:someValuesFrom>
                    </owl:Restriction>
                </owl:intersectionOf>
            </owl:Class>
        </owl:equivalentClass>
    </owl:Class>
Run Code Online (Sandbox Code Playgroud)

这是另一个类,Ratings2015它相当于评级,并且比2015年更大

 <!-- http://semanticrecommender.com/rs#Ratings2015 -->

    <owl:Class rdf:about="http://semanticrecommender.com/rs#Ratings2015">
        <owl:equivalentClass>
            <owl:Class>
                <owl:intersectionOf rdf:parseType="Collection">
                    <rdf:Description rdf:about="http://semanticrecommender.com/rs#Rates"/>
                    <owl:Restriction>
                        <owl:onProperty rdf:resource="http://semanticrecommender.com/rs#createdOn"/>
                        <owl:someValuesFrom>
                            <rdfs:Datatype>
                                <owl:onDatatype rdf:resource="http://www.w3.org/2001/XMLSchema#dateTime"/>
                                <owl:withRestrictions rdf:parseType="Collection">
                                    <rdf:Description>
                                        <xsd:minInclusive rdf:datatype="http://www.w3.org/2001/XMLSchema#dateTime">2015-01-01T00:00:00</xsd:minInclusive>
                                    </rdf:Description>
                                </owl:withRestrictions>
                            </rdfs:Datatype>
                        </owl:someValuesFrom>
                    </owl:Restriction>
                </owl:intersectionOf>
            </owl:Class>
        </owl:equivalentClass>
    </owl:Class>
Run Code Online (Sandbox Code Playgroud)

当我运行推理器时,推理者称Ratings2016是2015年评级的子类

图片

这是不正确的,为什么会这样,如何解决?

Ren*_*nzo 6

原因是您xsd:minInclusive用于指定创建日期.但是,根据XMLSchema,xsdminInclusive仅指定可能值的下限.因此,由于Ratings2016创建日期大于日期Ratings2015,因此它包含在为Ratings2015(从2015年初开始并且不终止)指定的值中,并且属于该类.

解决这个问题的方法当然取决于你的问题,但也许它可能足以xsd:maxInclusive为你的评级声明值.