1

I want to model lots of flows across a lattice of nodes.

enter image description here

The simple way is to simply model flow as a series of a flowsTo b relations - but this raises a problem where different flows cross a common lattice point, and what should remain as two independent flows merges into something less helpful.

So using the example above,

b flowsTo e
e flowsTo g

and

c flowsTo e
e flowsTo f

Describe two flows (the orange and purple ones) - but if modelled simply like this in RDF, loses the distinction between these two flows.

An alternative might be to have flow-specific predicates, such as a flowsToNameX b, and a flowsToNameY c, but as the number of flows increases, what I need is a way to collect all of these as a single collection.

Again, referring to the diagram, this might look like:

a RedFlowTo d
d RefFlowTo h
b OrangeFlowTo e
e OrangeFlowTo g
c PurpleFlowTo e
e PurpleFlowTo f

One way of doing this might be to define flowsToNameX and flowsToNameY as instances of some flow class, but I've not come across this pattern anywhere in the literature.

This works fine for 3 flows, but I'm looking at modelling thousands of these separate paths, across a similar number of nodes. So named instance (i.e. flow) -level predicates are fine, but I'd like to be able to work with them using a common set of interfaces so I can express concepts like upstream and downstream etc, and query the RDF using as general a form as possible.

This must be a common pattern, are there any best-practice approaches to modelling it?

4
  • 3
    I'm not sure I understand well what you want to do, but can't you have flowToNameX rdfs:subPropertyOf flowsTo? Of course, you can also have flowToNameXY rdfs:subPropertyOf flowsToNameX and flowToNameXZ rdfs:subPropertyOf flowsToNameX, etc. Sep 18, 2018 at 19:22
  • Thanks for the comments, I've added a diagram to help outline the problem - rdfs:subPropertyOf might fit the bill, but I'd have to understand the implications - and yes, I've not come across A-Box vs T-Box, but it's very much an instance vs class type distinction - I'd like to treat these (and tbh ALL) links as describing general concepts, but can't escape the fact that each one is an instance of some kind - and I want to try and enjoy a cake-and-eat it compromise between the two. Normally, instances are treated as nodes, and it feels alien to apply that instantiation to predicates. Sep 18, 2018 at 19:56
  • 1
    With your edited question, I'm even more convinced that you could just have a property hierarchy. Sep 18, 2018 at 21:05
  • 1
    A statement A p B is sometimes described as an instance of p (because the extension of p is the set of all pairs (A, B) where A and B have types in the domain and range of p), so in a way instantiation works just the same way with predicates at the OWL level. At the RDF level, these look very different - so the OWL view might be better for your purposes.
    – Ignazio
    Sep 19, 2018 at 9:32

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.