1

Let us suppose 3 kinds of entities:

  • Algorithm: whose instances are specific algorithms; -
  • Task: whose instances are specific tasks, for example “recognizing a specific texture in images”.
  • Parametrization: define a set of parameters and values for these parameters.

Let us consider the following cardinality constraints:

  • An algorithm can be used in several tasks.
  • A task can use several algorithms
  • An algorithm can have several parametrization.

This is not difficult to model in OWL. However, I have also the following constraint: -An algorithm, in a given task, have one and only one parametrization. That is, a given algorithm should be used in a task with a specific parametrization.

For clarifying the constraint, let us suppose the following. Let's assume A as Algorithm, T as Task and P as Parametrization. So, we have:

∀a,y A(a) ∧ T(t) ∧ usedIn(a,t) ⇒ ∃!p P(p) ∧ configures(p,a,t)

That is, for all algorithm a and for all task t, if a is used in t, them there is one and only one parametrization p which configures the algorithm a for the task t.

However, I don’t know how to represent this constraint in OWL. Is it possible to model this in OWL? How can we approach this problem?

I would like also to say that the axiom is a little weird, but this is a constraint provided by the customer. Also, I think that it would be interesting to discuss the case, just for discussing the limitations of OWL.

Juan
  • 95
  • 2
  • 5
  • What's the representation in FOL that you'd use? That would go a long way toward letting us know exactly what you're looking for. It might be possible to translate the FOL statement directly. – Joshua Taylor Mar 12 '17 at 21:44
  • @JoshuaTaylor is right. Because OWL is based on Description Logics (DL), which in fact is a decidable fragment of FOL, there exists a transformation from this subset to DL (resp. OWL). – UninformedUser Mar 13 '17 at 07:53
  • thank you for the interest. I have edited the original post, including the FOL formula for the constraint. – Juan Mar 14 '17 at 04:26
  • Where can I find some reference for study the transformation of FOL formulas to OWL? – Juan Mar 14 '17 at 04:27
  • I don't think your FOL formula captures what you want it to. **∀a,y A(a) ∧ T(t) ∧ usedIn(a,t) ⇒ ∃!p P(p) ∧ configures(p,a,t)** says that if an algorithm is used in a task, then there is *no* parameterization that configures a with t. You really need to capture the parameterization that you do expect in the antecedent: ∀a,y,q P(q) ∧ configures(q,a,t) A(a) ∧ T(t) ∧ usedIn(a,t) ⇒ ∃!p P(p) ∧ p ≠ q ∧ configures(p,a,t). Otherwise, there can't be *any* parameterization at all of the algorithm for the task, and you said there should be at most one (and probably at least one). – Joshua Taylor Mar 15 '17 at 20:24
  • I didn't understand why we should use your formula instead of mine. In my opinion, it is not necessary to have the parametrization in the antecedent. The existence of one, and one one, parametrization should be a necessary condition for using an algorithm a in a task t. – Juan Mar 17 '17 at 04:07

1 Answers1

1

If instances of Algorithm are particular algorithms, I imagine you have something like:

GraphSearchAlgorithm ⊑ Algorithm
depthFirstSearch ∈ GraphSearchAlgorithm
breadthFirstSearch ∈ GraphSearchAlgorithm

Then, you mention that tasks use a paramterization of an algorithm. I'd imagine that means that rather than

task72→uses breadthFirstSearch

you actually have something like:

task72 →uses parameterization83
parameterization83 →usesAlgorithm breadthFirstSearch
parameterization83 →usesParameters parameters24

That is, the task has a number of parameterizations (you could use a different name for this thing), each of which specifies an algorithm and the actual parameters. If that's the case, then I'd understand your constraint to be that an algorithm does not use multiple parameterizations that have the same algorithm. In FOL, you'd have something like:

∀ t,p,a [(uses(t,p) ∧ usesAlgorithm(p,a)) → ¬∃ q (p ≠ q ∧ uses(t,q) ∧ usesAlgorithm(q,a))]

If this is the intent, then this might be something that's past the limit of OWL. One of the usual rules-of-thumb (which isn't completely accurate, in the light of things like property chains, but still a useful rule of thumb) is whether you can write a formula using just two variables. In this case, the outer quantification requires three (the task, the parameterization, and the algorithm), and you can't really get around that.

Joshua Taylor
  • 84,998
  • 9
  • 154
  • 353