Huh, this might solve loyalty cascades by making the dwarfs who kill someone renegades (enemes of civ and group) right off the bat, so the person who kills them will face no repercussions.
It would be an easy way to solve it, yes, but the set system by itself won't. Currently, the problem- translated into set theory- is that if a dwarf is a member of the set of your civilization, he will neither attack nor be attacked by other members of the set. A random critter- say, a badger- is most definitely not a member of the set; it can attack and can be attacked by members of the set.
In a loyalty cascade, a problem arises where the dwarf attacking the caravan guards is suddenly both inside and outside the set of your civilization. The way to solve this- which under the set system will have to be addressed anyways- is that all sets, or most sets, will contain in their constitutions conditions under which a member of that set can be expelled from that set. These conditions will not always be crimes- if a mason dies, he might be removed from the set of the mason's guild. This works on the seemingly obvious but, as we've seen with loyalty cascades, no means active assumption that a member can either be a member of a set or not a member of a set- it cannot be both outside and inside. Suddenly, a loyalty cascade becomes that much easier to solve; simply, if a member of a dwarf civilization attacks another member of that same civilization, it is expelled from the set, and-no longer being a member- can be dispatched easily; its killer will not have killed a countryman, and will not be at fault.
I must say at this point that fuzzy set theory is incredibly tempting. If you're not familiar with it, in classical set theory, something is either in a set, or it is out of a set; it cannot be both. Under fuzzy set theory, every member has a
degree of membership, represented as a number between 0 and 1. For example, one member of a fuzzy set might have 25% membership, and another might have 75% membership; the latter is more of a member than the former, but it is incorrect to say that either is or is not a member of the set. This is an extremely tempting proposition for a set system in Dwarf Fortress. For example, you might have a constitution for the mason's guild wherein deceased members of the guild are afforded a funeral at the guild's expense. However, a dead mason is, from the point of view of fuzzy set theory, "not as much" of a member of the mason's guild as the still-living head mason.
As tempting as this is, I would propose that anything that fuzzy set theory can do, the hierarchy and subset system can do just as well- just have a constitution where dead masons are still members of the mason's guild, but the lowest rung on the hierarchy. Or, alternatively, anyone who has ever been in the guild is a full member of the mason's guild set- call it Guild A- but those still alive are in a subset, call it Guild B, within Guild A, and death constitutes expulsion from Guild B but not from Guild A. Or, in the loyalty cascade version, the berserk soldier who killed the caravan guard may still be a member of Civilization A- and is thus afforded a funeral and tomb by the civilization when he dies- but by killing the caravan guard expels himself from Civilization A's subset Civilization B, the set of all objects and subsets that are "active" members of the civilization and are thus not considered enemies.
I really should make a suggestions thread about this system.
Also: suddenly, uncountably infinite clowns.