= Person Entity Model = [[TOC]] The Person Entity Model defines a framework for the modelling of person-related entities like organisations, teams and other groups - and of course persons. It includes a generic model for affiliation, which shall be introduced here. == Introduction == We start with an obviously simple (read: ''small'') set of person entities: [[Image(pe_hierarchy1.png)]] === Roles === Each of these entities can define a number of roles by which other entities can be ''affiliated'' with them: [[Image(pe_hierarchy2.png)]] === Affiliation === If we link the ''affiliated'' entities to these roles, then we get an already pretty complex network of relationships: [[Image(pe_hierarchy3.png)]] === Hierarchy === Some affiliations define a hierarchy (in the sense of "reporting units" or "organisational units"), while others don't: [[Image(pe_hierarchy4.png)]] === Ancestor Paths === To analyze this hierarchy, we look at the ancestor paths from one entity to another entity: [[Image(pe_hierarchy5.png)]] It becomes a little bit more obvious if we remove the roles from the diagram: [[Image(pe_hierarchy6.png)]] These paths can easily be expressed as tuples of IDs, e.g. for Person Y we have two paths (4,1) and (5,2), and for Person X we have (5,2) and (2). Apparently, Person Y is affiliated with two different organisations here. === Hierarchy Levels === To make the actual "hierarchy" visible, we need to move each entity to a particular "hierarchy level": [[Image(pe_hierarchy7.png)]] Due to the heterogenous nature of this network, the "hierarchy" is not universal, but rather limited to each path - i.e. it is not universally definable whether a "team" ranks higher in the hierarchy than a "facility" - or vice versa. But within each path it becomes explicit.