Dichotomies, Trichotomies, Implied Sets, and Maximal User Control - OpenPatternsInc/EntsDatabase GitHub Wiki
This page gives an overview of the nuances of a Taxonomical Hierarchy and how certain information implies additional information. Specifically, it goes over the case where an entity is required to be under two or more exclusive sets, and what we can assume about this.
Fundamentals of Taxonomical Hierarchies.
The fundamental aspect of a Taxonomical Hierarchy (TH) is that all entities "under" a category or set have the properties that set symbolizes. If a set includes all members of a second set, and others, then it is that sets parent. For instance, all mammals are animals.
In order to allow the user to create their own hierarchies of arbitrary information, and to handle it under all cases, we need to account for all possibilities.
Implied Dichotomies
Let set A denote all entities of a given area of information, and let set B denote another set as its direct child. To be clear, this means that all entities under B are also under A, and A contains ents that aren't under B (other wise A would equal B). This simple example implies that there is a theoretical set of everything under A that is not under B. We'll denote this as A!B (all things under A not under B). Then B and A!B are a dichotomy splitting all members of A into two exclusive groups.
Exponential growth of implied sets
We can further extend the example to say A has 3 children, B, C and D, and that these 3 children do not overlap. Thus, there is the theoretical set A!B, which is logically the parent of both C and D. Likewise, there is A!C, etc.
This raises a problem of complexity. Each entity/set is therefore theoretically accompanied with its inverse. Furthermore, if A is a child of X, then we can also construct X!B, X!C, X!D. Thus each entity comes along with a theoretical set for each of its ancestors (not exactly, but for this discussion). Thus size of a hierarchy can vary exponentially with the number of implied sets which represent actual information the user may find relevant.
What is implied can be rederived
Because inverse sets are implied, they don't need to be stored in save files unless there is information about it that is not implied. Implied information can be rederived again.
Lets say a situation arises where there is a situation where there is a true dichotomy, where a set is split into two subsets and these two subsets are both relevant (the set "all animals that aren't elephants" is not exactly important). For instance, under "normal shoes" we can have "shoes for left foot" and "shoes for right foot". We don't want "shoes for left foot" and "shoes not for left feet". Thus these two sets are defined positively, not via a negation (using not). Though this is a dichotomy, both sets are important to the user.
In a dichotomy like "all animals that are not elephants", the title of that ent can be rederived using regular rules of language and so the title doesn't need to be stored.
We need to be aware of when a set becomes more than just implied.
Example Situations
Lets say the user is adding information about Animals. First they add Animals under root. Next they add Mammals under Animals, then Reptiles also under Animals. At this point, it's useful for the software to know whether Animals and Reptiles overlap, thus the user is asked. The user replies that they do not overlap.
Now, lets say that the user is adding Dogs. The system can ask "Are dogs animals?", and the user says yes. Then, there are a few ways to proceed. One is to ask "Are dogs reptiles?". The user says no and then it asks "Are dogs mammals?", and the user says yes. It shouldn't assume that dogs are mammals just because it's the only other option, because what if the ent being added was actually fish, or birds, which are neither mammals nor reptiles. So, we should allow the user to explicitly input when a set of categories exhaust all possibilities.
Going back to the shoes example, the user should be able to say that left shoes and right shoes are two independent categories and that all ents under "normal shoes" must be under either one or the other. To extend this, there can be any number of sets which are all exclusive and exhaust their collective parent.
The pattern here is that there is one parent ent and a number of multiple ents which are exclusive and exhaust the parent.
Multiple Dichotomies under the same parent
One may also have any number of these dichotomies on the same "level". For instance under Animals we can have Fish, Reptiles, Birds and Mammals representing one group of sets, and also land animals, aquatic animals, and amphibious animals as another group. If an animal is not a mammal, that doesn't mean anything about where it lives primarily.