Class to compute the set of abstract permutations from ranking and shape. More...
#include <AbstractPermutations.h>
Public Member Functions | |
Constructors | |
Abstract ()=default | |
Empty initializer, all data members are nulled. | |
Abstract (const RankingInformation &ranking, Shapes::Shape shape) | |
Generates the set of abstract stereopermutations and intermediate data. More... | |
Data Fields | |
Data members | |
RankingInformation::RankedSitesType | canonicalSites |
Stably resorted (by set size) site ranking. | |
Stereopermutations::Stereopermutation::Occupation | occupation |
Abstract representation of bonding case. | |
Stereopermutations::Stereopermutation::OrderedLinks | selfReferentialLinks |
Self-referential representation of links. | |
Stereopermutations::Uniques | permutations |
Vector of rotationally unique stereopermutations with associated weights. | |
Class to compute the set of abstract permutations from ranking and shape.
Scine::Molassembler::Stereopermutators::Abstract::Abstract | ( | const RankingInformation & | ranking, |
Shapes::Shape | shape | ||
) |
Generates the set of abstract stereopermutations and intermediate data.
Complexity The generation of permutations dominates: \(\Theta(S!)\)
ranking | Ranking object indicating chemical differences between substituents and sites |
shape | Shape name |
|
static |
Stably re-sort ranked site indices in decreasing set size.
Necessary to avoid treating e.g. AAB and ABB separately, although the resulting assignments are identical.
Complexity \(N \log N\)
Example:
* rankedSites = {5, 8}, {3}, {1, 2, 4} * canonicalize(rankedSites) = {1, 2, 4}, {5, 8}, {3} *
|
static |
Generates the reduced character representation of sites at their current shape positions.
Complexity \(O(S^2)\) worst case
|
static |
Make site-index based links shape-vertex self-referential.
Complexity \(\Theta(L)\)
Example:
* links = {sites = {5, 8}} * * self-refential idx: 0 1 2 3 4 5 * canonicalSites = {1, 2, 4}, {5, 8}, {3} (this is output from canonicalize) * * selfReferentialTransform(links, canonicalSites) = {3, 4} *
|
static |
Condense site ranking information into abstract rank indices for symbolic computation.
Use the output of canonicalize here as input:
Complexity \(\Theta(N)\)
Example:
* rankedSites = {5, 8}, {3}, {1, 2, 4} * canonical = canonicalize(rankedSites) = {1, 2, 4}, {5, 8}, {3} * transferToOccupation(canonical) = {0, 0, 0, 1, 1, 2} * (= AAABBC) *