Classic social networks can be represented as a graph/matrix.
With a graph/matrix one can easily compute
- shortest path between 2 participants
- reachability from A -> B
- general statistics (reciprocity, avg connectivity, etc)
- etc
Is there an ideal data structure (or a modification to graph/matrix) that enables easy computation of the above while being time aware?
For example,
Input
t = 0...100
- A <-> B (while t = 0...10)
- B <-> C (while t = 5...100)
- C <-> A (while t = 50...100)
Sample Queries
- Is A associated with B at any time? (yes)
- Is A associated with B while B is associated with C? (yes. @t = 5...10)
- Is C ever reachable from A (yes. @ t=5 )