Trait qsym2::group::class::ClassProperties
source · pub trait ClassProperties: GroupPropertieswhere
Self::ClassSymbol: CollectionSymbol<CollectionElement = Self::GroupElement>,
<Self as GroupProperties>::GroupElement: Inv<Output = <Self as GroupProperties>::GroupElement>,{
type ClassSymbol;
// Required methods
fn compute_class_structure(&mut self) -> Result<(), Error>;
fn get_cc_index(&self, cc_idx: usize) -> Option<&HashSet<usize>>;
fn get_cc_of_element_index(&self, e_idx: usize) -> Option<usize>;
fn get_cc_transversal(&self, cc_idx: usize) -> Option<Self::GroupElement>;
fn get_index_of_cc_symbol(
&self,
cc_sym: &Self::ClassSymbol,
) -> Option<usize>;
fn get_cc_symbol_of_index(&self, cc_idx: usize) -> Option<Self::ClassSymbol>;
fn filter_cc_symbols<P: FnMut(&Self::ClassSymbol) -> bool>(
&self,
predicate: P,
) -> Vec<Self::ClassSymbol>;
fn set_class_symbols(&mut self, cc_symbols: &[Self::ClassSymbol]);
fn get_inverse_cc(&self, cc_idx: usize) -> Option<usize>;
fn class_number(&self) -> usize;
fn class_size(&self, cc_idx: usize) -> Option<usize>;
// Provided method
fn class_matrix(
&self,
ctb_opt: Option<&Array2<usize>>,
r: usize,
) -> Array2<usize> { ... }
}
Expand description
Trait for conjugacy class properties of a finite group.
Required Associated Types§
sourcetype ClassSymbol
type ClassSymbol
The type of class symbols.
Required Methods§
sourcefn compute_class_structure(&mut self) -> Result<(), Error>
fn compute_class_structure(&mut self) -> Result<(), Error>
Computes the class structure of the group and store the result.
sourcefn get_cc_index(&self, cc_idx: usize) -> Option<&HashSet<usize>>
fn get_cc_index(&self, cc_idx: usize) -> Option<&HashSet<usize>>
Given a class index, returns an optional shared reference to the set containing the indices of all elements in that class.
§Arguments
cc_idx
- A class index.
§Returns
Returns a shared reference to the set containing the indices of all elements in that class, or
None
if cc_idx
is not a valid class index of the group.
sourcefn get_cc_of_element_index(&self, e_idx: usize) -> Option<usize>
fn get_cc_of_element_index(&self, e_idx: usize) -> Option<usize>
Given an element index, returns an optional index of the conjugacy class to which the element belongs.
§Arguments
e_idx
- An element index.
§Returns
Returns an index of the conjugacy class to which the element belongs, or None
if either
the element does not have a conjugacy class, or the index is out of range.
sourcefn get_cc_transversal(&self, cc_idx: usize) -> Option<Self::GroupElement>
fn get_cc_transversal(&self, cc_idx: usize) -> Option<Self::GroupElement>
sourcefn get_index_of_cc_symbol(&self, cc_sym: &Self::ClassSymbol) -> Option<usize>
fn get_index_of_cc_symbol(&self, cc_sym: &Self::ClassSymbol) -> Option<usize>
sourcefn get_cc_symbol_of_index(&self, cc_idx: usize) -> Option<Self::ClassSymbol>
fn get_cc_symbol_of_index(&self, cc_idx: usize) -> Option<Self::ClassSymbol>
sourcefn filter_cc_symbols<P: FnMut(&Self::ClassSymbol) -> bool>(
&self,
predicate: P,
) -> Vec<Self::ClassSymbol>
fn filter_cc_symbols<P: FnMut(&Self::ClassSymbol) -> bool>( &self, predicate: P, ) -> Vec<Self::ClassSymbol>
sourcefn set_class_symbols(&mut self, cc_symbols: &[Self::ClassSymbol])
fn set_class_symbols(&mut self, cc_symbols: &[Self::ClassSymbol])
Sets the conjugacy class symbols for this group.
§Arguments
cc_symbols
- A sliced of owned conjugacy class symbols.
sourcefn get_inverse_cc(&self, cc_idx: usize) -> Option<usize>
fn get_inverse_cc(&self, cc_idx: usize) -> Option<usize>
sourcefn class_number(&self) -> usize
fn class_number(&self) -> usize
Returns the number of conjugacy classes in the group.
Provided Methods§
sourcefn class_matrix(
&self,
ctb_opt: Option<&Array2<usize>>,
r: usize,
) -> Array2<usize>
fn class_matrix( &self, ctb_opt: Option<&Array2<usize>>, r: usize, ) -> Array2<usize>
The class matrix $\mathbf{N}_r
$ for the conjugacy classes in the group.
Let $K_i
$ be the $i^{\textrm{th}}
$ conjugacy class of the group. The
elements of the class matrix $\mathbf{N}_r
$ are given by
N_{r, st} = \lvert \{ (x, y) \in K_r \times K_s : xy = z \in K_t \} \rvert,
independent of any $z \in K_t
$.
§Arguments
ctb_opt
- An optional Cayley table.r
- The index $r
$.
§Returns
The class matrix $\mathbf{N}_r
$.