pub struct ActionGroupoid { /* private fields */ }Expand description
The action groupoid X ⫽ G: assignments over nv variables acted on by the group generated by
gens (literal permutations). Small nv only — it enumerates all 2^nv objects, which is the
point: it makes the orbit collapse visible and checkable.
Implementations§
Source§impl ActionGroupoid
impl ActionGroupoid
pub fn new(nv: usize, gens: Vec<Perm>) -> Self
Sourcepub fn orbits(&self) -> Vec<u32>
pub fn orbits(&self) -> Vec<u32>
The orbit id of every assignment — π₀(X ⫽ G), computed as the connected components of the
action via union-find. orbits()[a] is the canonical representative (smallest member) of a’s
orbit.
Sourcepub fn num_orbits(&self) -> usize
pub fn num_orbits(&self) -> usize
|π₀(X ⫽ G)| — the number of essentially-different worlds, i.e. exactly what symmetry breaking
reduces the search space to.
Sourcepub fn group_elements(&self, cap: usize) -> Vec<Perm>
pub fn group_elements(&self, cap: usize) -> Vec<Perm>
The full group G generated by gens (closed under composition, including the identity).
Bounded to cap elements so a pathological generating set can’t blow up; the caller’s small
examples are well within it.
Sourcepub fn stabilizer_size(&self, a: u32, group: &[Perm]) -> usize
pub fn stabilizer_size(&self, a: u32, group: &[Perm]) -> usize
π₁(X ⫽ G) at the assignment a — its stabilizer: the group elements that fix a
(g · a = a). These are the loops at a in the action groupoid; the fundamental-group data of
the homotopy type at that component.
Sourcepub fn orbit_size(&self, a: u32) -> usize
pub fn orbit_size(&self, a: u32) -> usize
The size of a’s orbit (the connected component of a).