Suppose I have the following instance data and property axiom:
Mary hasChild John
Ben hasChild Tom
Mary hasHusband Ben
hasHusbandChild: hasHusband • hasChild
How can I create the property hasChilds such that:
hasChilds: hasChild ⊔ hasHusbandChild
is true?
OWL doesn't support union properties where you can say things like
p ≡ q ⊔ r
but you can get the effects of:
q ⊔ r ⊑ p
by doing two axioms:
q ⊑ p
r ⊑ p
Now, 2 is not the same as 1, because with 1, you know that if p(x,y), then either q(x,y) or r(x,y), whereas with 2, p(x,y) can be true without either q(x,y) or r(x,y) being true.
Similarly, you can't define property chains in OWL like:
q • r ≡ p
but you use property chains on the left-hand side of subproperty axioms:
q • r ⊑ p
The difference between the two, of course, is that with 6 you can have p(x,y) without x and y being connected by a q • r chain.
It's not quite clear what you're asking, but I think what you're trying to ask is whether there's a way to say that the child of x's spouse is also a child of x. You can do that in OWL2 using property chains, specifically that
hasSpouse • hasChild ⊑ hasChild
This is equivalent to the first-order axiom:
∀ x,y,z : (hasSpouse(x,y) ∧ hasChild(y,z)) → hasChild(x,z)
A number of other questions on Stack Overflow are relevant here and will provide more guidance about how to add this kind of axiom to your OWL ontology:
OWL2 modelling a subclass with one different axiom
Adding statements of knowledge to an OWL Ontology in Protege)
owl:ObjectProperty and reasoning
Using Property Chains to get inferred Knowledge in an OWL Ontology(Protege)
As an alternative, you could also encode the first-order axiom as a SWRL rule.
Related
First of all, my English is poor, so sorry if my writing is confusing.
I'm trying to create the following relationship between instances: if A propertyX B, and C propertyY A, then C propertyX B. In my case, I want to specify that if a ManagerA "manages" an employee, and ManagerB has the same job as ManagerA, then he also manages the same employee.
I tried to use chain properties to do that, but the reasoner (FaCT ++ 1.6.5) doesn't work when I activate it (the log says a non-simple property is being used as one). I think the problem is in the fact that the property "manages" is asymmetric and irreflexive and the property "sameJob" is transitive and symmetric, but I'm not sure if that's the case. I applied the chain property in the "manages" property, stating: sameJob o manages SubPropertyOf: manages.
I'm just starting with Protégé and will appreciate any help a lot.
The reason for the error is due to manages not being a simple role, i.e. if you have r1 o ... o rn subPropertyOf r where n>1 then r is a non-simple role. Non-simple roles cannot be used in IrreflexiveObjectProperty and AsymmetricObjectProperty. See section 11 of OWL 2 syntax. The reason for the constraint on roles is to maintain decidability.
However, you can achieve the desired result by adding a SWRL rule:
manages(?x, ?y) ^ sameJob(?x, ?z) -> manages(?z, ?y).
it is possible that a property has multiple 'inverseOf' characteristic simultaneously? For instance:
<prop1, owl:inverseOf, prop2>
<prop1, owl:inverseOf, prop3>
<prop1, owl:inverseOf, prop4>
There's no problem with asserting that a property p is the inverseOf more than one property, e.g., q, and r. It does mean, however, q and r end up being equivalent. Since
p inverseOf q
p inverseOf r
means that
p(x,y) implies q(y,x)
p(x,y) implies r(y,x)
q(y,x) implies p(x,y)
r(y,x) implies p(x,y)
we can infer that
q(y,x) implies r(y,x)
r(y,x) implies q(y,x)
which means that
q equivalentProperty r
Is the following TBox cyclic or acyclic? If it is a cyclic TBox, how could it be converted to an acyclic one?
A ⊑ ¬E
E ⊑ ¬A
A ⊑ ¬E
E ⊑ ¬A
This TBox doesn't really say anything except that the classes A and E are disjoint. The subclass relations could be read as implications:
If something is an A, then it is not an E.
If something is an E, then it is not an A.
To express disjointness in description logics, you'd typically say that the intersection of disjoint classes is equivalent, or a subclass, of the bottom concept, ⊥, which by definition has no instances. &bot is also the complement of the top concept, ⊤, which contains everything. Thus you could say any of the following:
A ⊓ E ⊑ ⊥
A ⊓ E ≡ ⊥
A ⊓ E ⊑ ¬⊤
A ⊓ E ≡ ¬⊤
To add what Joshua said, disjointedness representation depends upon the language you use. Example: EL doesnt support bottom and negation.
The axioms you have written is not cyclic.
Cycle: antecedent and consequent of an axiom should have at least one common predicate (Concept or role).
If an axiom contains a cycle, you have to adopt fixpoint semantics to make it unequivocal.
To the best of my knowledge, axioms are meant to get induced knowledge. Converting a cyclic axiom to an acylic axiom: It is difficult to produce similar semantics.
How to convert the following TBox axioms into an acyclic Tbox:
A \sqsubseteq \lnot E
\exists R.A \sqcap \lnot B \sqsubseteq C
C \sqsubseteq B \sqcup A
C = A \sqcup D
A \sqcap \exists R.E \sqsubseteq D
In an OWL-DL ontology, consider a property p with domain D and range R where D has a restriction over p to have cardinality of exactly one:
D SubClassOf p exactly 1 Thing
(D ⊑ =1 p.Thing)
Can we then infer that p is a functional property, since each d of type D will have exactly one value for p? If this is correct, can a reasoner infer this knowledge?
In OWL, a property is function when each individual has at most one value for the property. That "at most" is important; it is permitted for something to have no value for the property. (That means that a functional property in OWL is actually more like a possibly partial function in mathematics.) That said, if every individual has a exactly one value for a property, then it clearly has at most one value for the property, so the property would, as you suspect, be functional. We can walk though a specific case, though, to be sure that this is general, and because we need to make sure that the property p here actually has at most one value for every individual.
Proof: Suppose the property p has domain D, and D is a subclass of =1 p.Thing, so that every D has exactly one p
value. Is it the case that every individual x has at most one value
for p? There are two cases to consider:
x is a D. Then by the subclass axiom with the restriction, x must have exactly one value for p, and one is less than or equal to
one.
x is not a D. Then x has no values for p. If it did, then it would be in the domain of p, which is D, and that is a
contradiction. Then x has zero values for p, and zero is less
than or equal to one.
Then any individual x at most one value for the property p, which
is the definition of p being functional. Thus, p is functional.
QED
An OWL DL reasoner should be able to confirm this, and it shouldn't be hard to check.
Lots of commonly useful properties of functions have concise names. For example, associativity, commutativity, transitivity, etc.
I am making a library for use with QuickCheck that provides shorthand definitions of these properties and others.
The one I have a question about is idempotence of unary functions. A function f is idempotent iif ∀x . f x == f (f x).
There is an interesting generalization of this property for which I am struggling to find a similarly concise name. To avoid biasing peoples name choices by suggesting one, I'll name it P and provide the following definition:
A function f has the P property with respect to g iif ∀x . f x == f (g x). We can see this as a generalization of idempotence by redefining idempotence in terms of P. A function f is idempotent iif it has the P property with respect to itself.
To see that this is a useful property observe that it justifies a rewrite rule that can be used to implement a number of common optimizations. This often but not always arises when g is some sort of canonicalization function. Some examples:
length is P with respect to map f (for all choices of f)
Converting to CNF is P with respect to converting to DNF (and vice versa)
Unicode normalization to form NFC is P with respect to normalization to form NFD (and vice versa)
minimum is P with respect to nub
What would you name this property?
One can say that map f is length-preserving, or that length is invariant under map fing. So how about:
g is f-preserving.
f is invariant under (applying) g.