Graph
Graph theory has provided an abstract view of information since used it was used to solve the Seven Bridges of Königsberg puzzle, but in information technology it is often viewed a purest way of transforming and storing information as Nodes and Edges between then. Node/Edge is powerful for visualization as everything can be viewed either as a Node
, Edge
or both.
Hiperspace uses low-latency navigation to forgo the need for extract/transformation and instead view Nodes & Edges as Euler intended, as a projection.
Consider the [Cousins Problem]https://github.com/channell/Hiperspace/tree/master/examples/CousinProblem) where you want to view a family tree as a a graph, but don't want duplicate data for all the implied relations that could and should be derivable only when needed
For this family tree of 11 people, there are 22 edges and 106 edges when you include all the derived relationships like Lucy has cousin Rob by "Mother->Mother->Child->Child".
Hiperspace only stores relational facts, but Person
provides a Node
and four Edge
entity Cousins.Person /* define Persion */
= Node (), /* Person has a Node View */
Edge (From = this, To = Mother, Name = Name, TypeName = "Mother"), /* Person provides Edge to Mother */
Edge2 (From = this, To = Father, Name = Name, TypeName = "Father"), /* Person provides Edge to Father */
Edge3 (From = Father, To = this, Name = Name, TypeName = "Child"), /* Person provides Edge from Father */
Edge4 (From = Mother, To = this, Name = Name, TypeName = "Child") /* Person provides Edge from Mother */
( /* Keys */
Name : String /* Person has Name as key */
)
{ /* Values */
Gender : Cousins.Gender, /* Person has Gender {}Female, Male */
Mother : Cousins.Person, /* Person has reference to Mother */
Father : Cousins.Person /* Person has reference to Father */
}
[ /* Extent properties not stored */
TypeName = "Person", /* TypeName for Node View */
FatherChild : Cousins.Person (Father = this), /* navigation to children */
MotherChild : Cousins.Person (Mother = this), /* navigation to children */
@Once
Relatives = relation (this) /* function to navigate to all relatives*/
];