11 #ifndef INCLUDE_MOLASSEMBLER_BOND_STEREOPERMUTATOR_H
12 #define INCLUDE_MOLASSEMBLER_BOND_STEREOPERMUTATOR_H
19 namespace Molassembler {
22 namespace Stereopermutations {
30 class AngstromPositions;
32 class StereopermutatorList;
34 namespace DistanceGeometry {
36 struct ChiralConstraint;
61 BetweenEclipsedAndStaggered
92 static constexpr
double assignmentAcceptanceParameter = 0.1;
133 Alignment alignment = Alignment::Eclipsed
146 Alignment alignment = Alignment::Eclipsed
161 void assign(boost::optional<unsigned> assignment);
205 std::pair<FittingReferences, FittingReferences> fittingReferences,
212 std::pair<FittingReferences, FittingReferences> fittingReferences,
344 std::unique_ptr<Impl> pImpl_;
Handle arrangements of substituents at corners of an atom-centered shape.
A wrapper class around Utils' PositionCollection to emphasize that the positions stored therein are i...
Definition: AngstromPositions.h:25
Handles the steric permutation of substituents of a non-terminal central atom.
Definition: AtomStereopermutator.h:79
std::tuple< RankingInformation, ShapeMap > PropagatedState
Old state dumped upon propagation.
Definition: AtomStereopermutator.h:102
Handles specific relative arrangements of two atom stereopermutators joined by a bond.
Definition: BondStereopermutator.h:46
void fit(const SitePositionsPair &sitePositions, std::pair< FittingReferences, FittingReferences > fittingReferences, FittingMode mode=FittingMode::Thresholded)
Determines the assignment the permutator is in from positional information.
unsigned numAssignments() const
Returns the number of possible assignments.
void assign(boost::optional< unsigned > assignment)
Changes the assignment of the stereopermutator.
FittingMode
Differentiates how viable assignments are chosen during fitting.
Definition: BondStereopermutator.h:67
bool hasSameCompositeOrientation(const BondStereopermutator &other) const
Returns whether this stereopermutator has the same relative orientation as another stereopermutator.
boost::optional< unsigned > assigned() const
Returns the permutation index within the set of possible permutations, if set.
std::pair< SitePositions, SitePositions > SitePositionsPair
Spatial centroids of two atom stereopermutators' site atoms.
Definition: BondStereopermutator.h:77
BondStereopermutator()=delete
Constructs a bond stereopermutator on two atom stereopermutators without checking whether stereopermu...
double dihedral(const AtomStereopermutator &stereopermutatorA, SiteIndex siteIndexA, const AtomStereopermutator &stereopermutatorB, SiteIndex siteIndexB) const
Angle between sites at stereopermutators in the current assignment.
void propagateGraphChange(const AtomStereopermutator::PropagatedState &oldPermutator, const AtomStereopermutator &newPermutator, const PrivateGraph &inner, const StereopermutatorList &permutators)
Propagates the bond stereocenter's state through a possible ranking change on one of its constituting...
BondStereopermutator(const PrivateGraph &graph, const StereopermutatorList &stereopermutators, const BondIndex &edge, Alignment alignment=Alignment::Eclipsed)
Constructs a bond stereopermutator on two atom stereopermutators, removing obviously infeasible stere...
const Stereopermutations::Composite & composite() const
Gives read-only access to the underlying Composite object.
boost::optional< unsigned > indexOfPermutation() const
Returns the index of permutation.
BondIndex placement() const
Returns which bond this stereopermutator is placed on in the molecule.
unsigned numStereopermutations() const
Returns the number of possible stereopermutations.
std::pair< AtomIndex, AtomIndex > compositeAlignment() const
The atom identifier alignment of the permutational composite.
static std::vector< unsigned > notObviouslyInfeasibleStereopermutations(const PrivateGraph &graph, const AtomStereopermutator &stereopermutatorA, const AtomStereopermutator &stereopermutatorB, const Stereopermutations::Composite &composite)
Determine which stereopermutations aren't obviously infeasible.
Eigen::Matrix< double, 3, Eigen::Dynamic > SitePositions
Spatial centroids of atom stereopermutator site atoms.
Definition: BondStereopermutator.h:75
Alignment alignment() const
Returns alignment parameter this was constructed with.
std::string rankInfo() const
Returns an information for ranking equality checking purposes.
void fit(const AngstromPositions &angstromWrapper, std::pair< FittingReferences, FittingReferences > fittingReferences, FittingMode mode=FittingMode::Thresholded)
This is an overloaded member function, provided for convenience. It differs from the above function o...
void propagateVertexRemoval(AtomIndex removedIndex)
Propagates invalidated atom indices through the removal of an index.
void assignRandom(Random::Engine &engine)
Assign the Stereopermutator at random.
std::string info() const
Returns an information string for diagnostic purposes.
Alignment
How dihedrals are aligned in the generation of stereopermutations.
Definition: BondStereopermutator.h:53
BondStereopermutator(const AtomStereopermutator &stereopermutatorA, const AtomStereopermutator &stereopermutatorB, const BondIndex &edge, Alignment alignment=Alignment::Eclipsed)
Constructs a bond stereopermutator on two atom stereopermutators without checking whether stereopermu...
void applyPermutation(const std::vector< AtomIndex > &permutation)
Applies an atom index permutation.
Library internal graph class wrapping BGL types.
Definition: PrivateGraph.h:26
Drives a PRNG.
Definition: Prng.h:24
Represents the composite of two shapes joined by a bond at arbitrary shape vertices.
Definition: Composites.h:34
Manages all stereopermutators that are part of a Molecule.
Definition: StereopermutatorList.h:30
Type helper for creating strong index types that are type-level distinct from their fundamental types...
Definition: StrongIndex.h:37
std::size_t AtomIndex
Unsigned integer atom index type. Used to refer to particular atoms.
Definition: Types.h:51
Type used to refer to particular bonds. Orders first < second.
Definition: Types.h:54
Definition: BondStereopermutator.h:181
Definition: BondStereopermutatorImpl.h:23