Check out the Tcl lib in subsites for a bunch of utilities. acs-subsite barely makes use of them but the work was never completed. One of my goals for 4.7 is to finish this up.
A "relational segment" is just a subset of a group. It was a bolt-on to the existing 4.x groups structure. A very useful one. I just mention this because if one were to start from scratch one could probably solve the groups and subsets of groups problem in a more elegant way. relsegs work, though, and are fairly easy to work with.
acs_rels is just a generalized object-to-object map (somewhat overblown, IMO, but we can live with it). In the context of groups and relational segments there are two predefined relation types for groups: membership_rel ("this person is a member of group foo") and composition_rel ("the members of group foo also belong to group bar").
A relational segment builds a subset of a group by referring to a relationship type that describes the subset (say "professor_rel") then inserting rows that read something like "User scotttiger, group foo, professor_rel").
Querying the acs_rels table for "group foo/professor_rel" will return the set of professers in group foo.
Querying the acs_rels table for "user scotttiger, professor_rel" will return all the groups that scotttiger is a professor of.
Etc etc etc
Does this help?