CASM  1.1.0
A Clusters Approach to Statistical Mechanics
CASM::OccupantDoFIsEquivalent< OccType > Class Template Reference

#include <DoFIsEquivalent.hh>

Detailed Description

template<typename OccType>
class CASM::OccupantDoFIsEquivalent< OccType >

Class for checking equivalence of two OccupantDoF objects, with respect to symmetry transformations.

OccupantDoFs dofA and dofB are considered equivalent if

  • dofA and dofB have the same number of allowed occupants AND
  • each allowed occupant of dofA is also an allowed occupant of dofB AND
  • if compare_occupant is set to TRUE, the current occupant of dofA is equivalent to the current occupant of dofB

Definition at line 75 of file DoFIsEquivalent.hh.

Public Types

using OccDoFType = std::vector< OccType >
 

Public Member Functions

 OccupantDoFIsEquivalent (OccDoFType const &_dof, double tol=TOL)
 
bool operator() (OccDoFType const &_other) const
 
bool operator() (xtal::SymOp const &_op) const
 returns true if copy_apply(_op,m_dof) = P.permute(m_dof) More...
 
bool operator() (xtal::SymOp const &_op, OccDoFType const &_other) const
 returns true if copy_apply(_op,m_dof) = P.permute(_other) More...
 
Permutation const & perm () const
 

Private Attributes

OccDoFType m_dof
 
double m_tol
 
Permutation m_P
 

Member Typedef Documentation

◆ OccDoFType

template<typename OccType >
using CASM::OccupantDoFIsEquivalent< OccType >::OccDoFType = std::vector<OccType>

Definition at line 77 of file DoFIsEquivalent.hh.

Constructor & Destructor Documentation

◆ OccupantDoFIsEquivalent()

template<typename OccType >
CASM::OccupantDoFIsEquivalent< OccType >::OccupantDoFIsEquivalent ( OccDoFType const &  _dof,
double  tol = TOL 
)
inline

Definition at line 79 of file DoFIsEquivalent.hh.

Member Function Documentation

◆ operator()() [1/3]

template<typename OccType >
bool CASM::OccupantDoFIsEquivalent< OccType >::operator() ( OccDoFType const &  _other) const

returns true if m_dof and _other have matching labels, and m_dof = P.permute(_other)

Definition at line 8 of file DoFIsEquivalent_impl.hh.

◆ operator()() [2/3]

template<typename OccType >
bool CASM::OccupantDoFIsEquivalent< OccType >::operator() ( xtal::SymOp const &  _op) const

returns true if copy_apply(_op,m_dof) = P.permute(m_dof)

Definition at line 28 of file DoFIsEquivalent_impl.hh.

◆ operator()() [3/3]

template<typename OccType >
bool CASM::OccupantDoFIsEquivalent< OccType >::operator() ( xtal::SymOp const &  _op,
OccDoFType const &  _other 
) const

returns true if copy_apply(_op,m_dof) = P.permute(_other)

Definition at line 48 of file DoFIsEquivalent_impl.hh.

◆ perm()

template<typename OccType >
Permutation const& CASM::OccupantDoFIsEquivalent< OccType >::perm ( ) const
inline

return transformation permutation P calculated during last successful comparison

Definition at line 94 of file DoFIsEquivalent.hh.

Member Data Documentation

◆ m_dof

template<typename OccType >
OccDoFType CASM::OccupantDoFIsEquivalent< OccType >::m_dof
private

Definition at line 97 of file DoFIsEquivalent.hh.

◆ m_P

template<typename OccType >
Permutation CASM::OccupantDoFIsEquivalent< OccType >::m_P
mutableprivate

Definition at line 101 of file DoFIsEquivalent.hh.

◆ m_tol

template<typename OccType >
double CASM::OccupantDoFIsEquivalent< OccType >::m_tol
private

Definition at line 99 of file DoFIsEquivalent.hh.


The documentation for this class was generated from the following files: