Symmetry definitions and properties. More...
Namespaces | |
ConstexprProperties | |
Compile-time calculation of shape classes' properties. | |
Continuous | |
Symmetry element, point group, and polyhedral shape continuous metrics. | |
Data | |
All symmetry data classes and some minor helper functions. | |
Diophantine | |
Functions to help treat a particular linear diophantine equation. | |
Elements | |
Namespace for classes and data of point group symmetry elements. | |
Properties | |
Runtime-computed properties of shapes. | |
Data Structures | |
struct | CoordinateSystem |
Coordinate system axis data class. More... | |
struct | InertialMoments |
Inertial moments data struct. More... | |
class | Partitioner |
Given S * E distinguishable objects, this class helps enumerate all partitions into S groups of size E. More... | |
Typedefs | |
using | Vertex = Temple::StrongIndex< vertex_index_tag, unsigned > |
using | Permutation = std::vector< Vertex > |
Representation of a shape vertex permutation. | |
using | RotationsList = std::vector< Permutation > |
The type to store shape rotations. | |
using | AngleFunction = std::function< > |
Function returning angle between vertices. More... | |
using | Tetrahedron = std::array< boost::optional< Vertex >, 4 > |
This is a four-vertex tetrahedron definition. More... | |
using | TetrahedronList = std::vector< Tetrahedron > |
using | Coordinates = Eigen::Matrix< double, 3, Eigen::Dynamic > |
Representation of idealized shape coordinates (does not include centroid) | |
using | InertialPositionsType = Eigen::Matrix< double, 3, Eigen::Dynamic > |
Functions | |
Eigen::Matrix3d | rotationMatrix (const CoordinateSystem &a, const CoordinateSystem &b) |
Gives the rotation matrix tranforming points between coordinate systems. More... | |
const std::string & | name (const Shape shape) |
Fetch the string name of a shape. More... | |
Shape | nameFromString (const std::string &shapeNameString) |
Fetch the shape name from its string. More... | |
std::string | spaceFreeName (Shape shape) |
Fetch a space-free string of a shape for file naming. More... | |
unsigned | size (const Shape shape) |
Fetch the number of vertices of a shape. More... | |
const RotationsList & | rotations (const Shape shape) |
Fetches a shape's list of rotations. More... | |
const Permutation & | mirror (const Shape shape) |
Fetches the mirror index mapping for a particular shape. More... | |
AngleFunction | angleFunction (const Shape shape) |
Gets a shape's angle function. More... | |
Coordinates | coordinates (const Shape shape) |
Fetch a shape's idealized coordiantes. More... | |
PointGroup | pointGroup (const Shape shape) |
Get a shape's point group. More... | |
unsigned | nameIndex (Shape shape) |
Returns the index of a shape within allShapes. More... | |
const TetrahedronList & | tetrahedra (const Shape shape) |
Fetches the list of tetrahedra defined in a shape. More... | |
bool | threeDimensional (const Shape shape) |
Returns whether a shape is three dimensional. More... | |
InertialMoments | principalInertialMoments (const InertialPositionsType &positions) |
Determine the inertial moments of a set of positions. More... | |
Top | standardizeTop (Eigen::Ref< InertialPositionsType > normalizedPositions) |
Identifies the top of a set of positions and reorients the particle positions, aligning the main axis along z. More... | |
unsigned | reorientAsymmetricTop (Eigen::Ref< InertialPositionsType > normalizedPositions) |
Searches for Cn axes along the coordinate system axes, aligns the highest order Cn axis found along the z axis. More... | |
double | minimumAngle (Shape symmetryName) |
Calculate the minimum angle in a symmetry. More... | |
double | maximumAngle (Shape symmetryName) |
Calculate the maximum angle in a symmetry. More... | |
const boost::optional< const Properties::ShapeTransitionGroup & > | getMapping (Shape a, Shape b, const boost::optional< Vertex > &removedIndexOption=boost::none) |
Cached access to mappings. Populates the cache from constexpr if generated. More... | |
bool | hasMultipleUnlinkedStereopermutations (Shape symmetryName, unsigned nIdenticalLigands) |
Cached access to multiple unlinked values. More... | |
double | tau (const std::vector< double > &angles) |
Calculates the tau value for four and five angle symmetries. More... | |
Variables | |
constexpr unsigned | ORIGIN_PLACEHOLDER = std::numeric_limits<unsigned>::max() |
A placeholder value for constexpr tetrahedra specification of origin. | |
constexpr std::array< Shape, nShapes > | allShapes |
A list of all the enum class values. More... | |
const Temple::Array< std::pair < double, double >, nShapes > | symmetryAngleBounds |
Precomputed min and max angle values in radians for all symmetries. | |
constexpr double | smallestAngle [[gnu::unused]] |
The smallest angle between ligands in all symmetries. More... | |
Temple::MinimalCache < std::tuple< Shape, Shape, boost::optional< unsigned > >, Properties::ShapeTransitionGroup > | mappingsCache |
Cache for on-the-fly generated mappings between symmetries. More... | |
Temple::MinimalCache< Shape, std::vector< bool >> | hasMultipleUnlinkedCache |
Run-time cache. | |
constexpr unsigned | nShapes = 30 |
Total number of shapes. | |
Symmetry definitions and properties.
using Scine::Molassembler::Shapes::AngleFunction = typedef std::function< > |
Function returning angle between vertices.
All angle functions can be called with arbitrary (valid) parameters without failing. Valid here means that a != b and less than the size of the shape requested.
They return angles in radians.
using Scine::Molassembler::Shapes::Tetrahedron = typedef std::array<boost::optional<Vertex>, 4> |
This is a four-vertex tetrahedron definition.
All shapes use None to signal to replace this position with the central atom as it is not part of the vertex indexing scheme.
using Scine::Molassembler::Shapes::TetrahedronList = typedef std::vector<Tetrahedron> |
All shapes use boost::none to signal to replace this position with the central atom as it is not part of the vertex indexing scheme.
|
strong |
Enumeration of all contained symmetry names.
List is in order of the number of symmetry positions
Enumerator | |
---|---|
Line |
See Data::Line. |
Bent |
See Data::Bent. |
EquilateralTriangle | |
VacantTetrahedron | |
T |
See Data::T. |
Tetrahedron |
See Data::Tetrahedron. |
Square |
See Data::Square. |
Seesaw |
See Data::Seesaw. |
TrigonalPyramid | |
SquarePyramid |
See Data::SquarePyramid. |
TrigonalBipyramid | |
Pentagon |
See Data::Pentagon. |
Octahedron |
See Data::Octahedron. |
TrigonalPrism |
See Data::TrigonalPrism. |
PentagonalPyramid | |
Hexagon |
See Data::Hexagon. |
PentagonalBipyramid | |
CappedOctahedron | |
CappedTrigonalPrism | |
SquareAntiprism | |
Cube |
See Data::Cube. |
TrigonalDodecahedron | |
HexagonalBipyramid | |
TricappedTrigonalPrism | |
CappedSquareAntiprism |
See Data::CappedSquareAntiPrism. |
HeptagonalBipyramid | |
BicappedSquareAntiprism | |
EdgeContractedIcosahedron | |
Icosahedron |
See Data::Icosahedron. |
Cuboctahedron |
See Data::Cuboctahedron. |
|
strong |
AngleFunction Scine::Molassembler::Shapes::angleFunction | ( | const Shape | shape | ) |
Gets a shape's angle function.
Complexity \(\Theta(1)\)
Coordinates Scine::Molassembler::Shapes::coordinates | ( | const Shape | shape | ) |
Fetch a shape's idealized coordiantes.
Complexity \(\Theta(1)\)
const boost::optional<const Properties::ShapeTransitionGroup&> Scine::Molassembler::Shapes::getMapping | ( | Shape | a, |
Shape | b, | ||
const boost::optional< Vertex > & | removedIndexOption = boost::none |
||
) |
Cached access to mappings. Populates the cache from constexpr if generated.
Complexity \(\Theta(S!)\) where \(S\) is the size of the symmetry if the transition is not cached, \(\Theta(1)\) otherwise.
a | Source shape |
b | Target shape |
removedIndexOption | The symmetry position removed from source if the transition is to be a symmetry position loss. Necessary if the size of the target is one less than that of the source. Defaults to None. |
bool Scine::Molassembler::Shapes::hasMultipleUnlinkedStereopermutations | ( | Shape | symmetryName, |
unsigned | nIdenticalLigands | ||
) |
Cached access to multiple unlinked values.
Populates the cache with allHasMultipleUnlinkedStereopermutations if the constexpr number of unlinked stereopermutations was calculated at runtime. If not, calculates the value and stores it in the cache.
Complexity \(\Theta(S!)\) where \(S\) is the size of the symmetry if the symmetry and number of identical ligands is not cached, \(\Theta(1)\) otherwise
symmetryName | symmetry for which to check the value |
nIdenticalLigands | number of equivalent ligands |
double Scine::Molassembler::Shapes::maximumAngle | ( | Shape | symmetryName | ) |
Calculate the maximum angle in a symmetry.
Calculates the maximum angle between symmetry positions in a symmetry class
Complexity \(\Theta(S^2)\)
double Scine::Molassembler::Shapes::minimumAngle | ( | Shape | symmetryName | ) |
Calculate the minimum angle in a symmetry.
Calculates the minimum angle between symmetry positions in a symmetry class
Complexity \(\Theta(S^2)\)
const Permutation& Scine::Molassembler::Shapes::mirror | ( | const Shape | shape | ) |
Fetches the mirror index mapping for a particular shape.
Complexity \(\Theta(1)\)
const std::string& Scine::Molassembler::Shapes::name | ( | const Shape | shape | ) |
Fetch the string name of a shape.
Complexity \(\Theta(1)\)
Shape Scine::Molassembler::Shapes::nameFromString | ( | const std::string & | shapeNameString | ) |
Fetch the shape name from its string.
Complexity \(\Theta(S)\)
std::logic_error | if no matching shape can be found |
unsigned Scine::Molassembler::Shapes::nameIndex | ( | Shape | shape | ) |
Returns the index of a shape within allShapes.
Complexity \(\Theta(S)\)
PointGroup Scine::Molassembler::Shapes::pointGroup | ( | const Shape | shape | ) |
Get a shape's point group.
Complexity \(\Theta(1)\)
InertialMoments Scine::Molassembler::Shapes::principalInertialMoments | ( | const InertialPositionsType & | positions | ) |
Determine the inertial moments of a set of positions.
positions
are in an inertial frame (COM is origin) unsigned Scine::Molassembler::Shapes::reorientAsymmetricTop | ( | Eigen::Ref< InertialPositionsType > | normalizedPositions | ) |
Searches for Cn axes along the coordinate system axes, aligns the highest order Cn axis found along the z axis.
normalizedPositions | Particle positions |
Eigen::Matrix3d Scine::Molassembler::Shapes::rotationMatrix | ( | const CoordinateSystem & | a, |
const CoordinateSystem & | b | ||
) |
Gives the rotation matrix tranforming points between coordinate systems.
You can transform points from a
using the result of this function into coordinate system b
.
a | Source coordinate system |
b | Target coordinate system |
a
into b
const RotationsList& Scine::Molassembler::Shapes::rotations | ( | const Shape | shape | ) |
Fetches a shape's list of rotations.
Complexity \(\Theta(1)\)
unsigned Scine::Molassembler::Shapes::size | ( | const Shape | shape | ) |
Fetch the number of vertices of a shape.
Complexity \(\Theta(1)\)
std::string Scine::Molassembler::Shapes::spaceFreeName | ( | Shape | shape | ) |
Fetch a space-free string of a shape for file naming.
Complexity \(\Theta(1)\)
Top Scine::Molassembler::Shapes::standardizeTop | ( | Eigen::Ref< InertialPositionsType > | normalizedPositions | ) |
Identifies the top of a set of positions and reorients the particle positions, aligning the main axis along z.
normalizedPositions | Particle positions |
double Scine::Molassembler::Shapes::tau | ( | const std::vector< double > & | angles | ) |
Calculates the tau value for four and five angle symmetries.
Complexity \(\Theta(1)\)
angles | A sorted vector of the angles in your central symmetry. This must be of size four or five. |
const TetrahedronList& Scine::Molassembler::Shapes::tetrahedra | ( | const Shape | shape | ) |
Fetches the list of tetrahedra defined in a shape.
Complexity \(\Theta(1)\)
bool Scine::Molassembler::Shapes::threeDimensional | ( | const Shape | shape | ) |
Returns whether a shape is three dimensional.
Complexity \(\Theta(1)\)
A list of all the enum class values.
Temple::MinimalCache< std::tuple<Shape, Shape, boost::optional<unsigned> >, Properties::ShapeTransitionGroup> Scine::Molassembler::Shapes::mappingsCache |
Cache for on-the-fly generated mappings between symmetries.
Accesses allMappings if it was generated.
constexpr double Scine::Molassembler::Shapes::smallestAngle[[gnu::unused]] |
The smallest angle between ligands in all symmetries.
Stores the smallest angle between symmetry positions across all symmetries
Complexity \(\Theta(NS^2)\) where \(N\) is the number of largest symmetries and \(S\) is the size of the largest symmetry