CASM
AClustersApproachtoStatisticalMechanics
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules
CASM::SupercellIterator< UnitType > Class Template Reference

#include <SupercellEnumerator.hh>

Detailed Description

template<typename UnitType>
class CASM::SupercellIterator< UnitType >

Iterators used with SupercellEnumerator.

Allows iterating over unique supercells of a UnitType object (may be Lattice, eventually BasicStructure, or Structure)

Definition at line 252 of file SupercellEnumerator.hh.

Public Types

typedef int difference_type
 
typedef UnitType value_type
 
typedef const UnitType & reference
 
typedef const UnitType * pointer
 

Public Member Functions

 SupercellIterator ()
 
 SupercellIterator (const SupercellEnumerator< UnitType > &enumerator, int volume, int dims)
 
SupercellIterator< UnitType > & operator= (const SupercellIterator< UnitType > &B)
 
bool operator== (const SupercellIterator< UnitType > &B) const
 Iterator comparison. More...
 
bool operator!= (const SupercellIterator< UnitType > &B) const
 Iterator comparison. More...
 
reference operator* () const
 Access the supercell. More...
 
pointer operator-> () const
 Access the supercell. More...
 
Eigen::Matrix3i matrix () const
 constructed supercell matrix More...
 
HermiteCounter::value_type volume () const
 current volume More...
 
const SupercellEnumerator
< UnitType > & 
enumerator () const
 const reference to the SupercellEnumerator this is iterating with More...
 
SupercellIterator< UnitType > & operator++ ()
 Prefix increment operator. Increment to next unique supercell. More...
 

Public Attributes

EIGEN_MAKE_ALIGNED_OPERATOR_NEW
typedef
std::forward_iterator_tag 
iterator_category
 fixes alignment of m_deformation More...
 

Private Member Functions

void _increment ()
 Postfix increment operator. Increment to next unique supercell. More...
 
void _try_increment ()
 Check if the current supercell matrix hermite normal form is in a canonical form. More...
 
void _update_super ()
 Update m_super when required. More...
 

Private Attributes

bool m_super_updated
 Indicates if m_super reflects the current m_current supercell matrix. More...
 
const SupercellEnumerator
< UnitType > * 
m_enum
 Pointer to SupercellEnumerator which holds the unit cell and point group. More...
 
notstd::cloneable_ptr
< HermiteCounter
m_current
 Current supercell matrix in HermitCounter form. More...
 
UnitType m_super
 A supercell, stored here so that iterator dereferencing will be OK. Only used when requested. More...
 
std::vector< Eigen::Matrix3i > m_canon_hist
 Keep track of the HNF matrices for the current determinant value. More...
 

Member Typedef Documentation

template<typename UnitType>
typedef int CASM::SupercellIterator< UnitType >::difference_type

Definition at line 260 of file SupercellEnumerator.hh.

template<typename UnitType>
typedef const UnitType* CASM::SupercellIterator< UnitType >::pointer

Definition at line 263 of file SupercellEnumerator.hh.

template<typename UnitType>
typedef const UnitType& CASM::SupercellIterator< UnitType >::reference

Definition at line 262 of file SupercellEnumerator.hh.

template<typename UnitType>
typedef UnitType CASM::SupercellIterator< UnitType >::value_type

Definition at line 261 of file SupercellEnumerator.hh.

Constructor & Destructor Documentation

template<typename UnitType>
CASM::SupercellIterator< UnitType >::SupercellIterator ( )
inline

Definition at line 265 of file SupercellEnumerator.hh.

Member Function Documentation

template<typename UnitType>
void CASM::SupercellIterator< UnitType >::_try_increment ( )
private

Check if the current supercell matrix hermite normal form is in a canonical form.

Increment the supercell matrix by one (maintaining hermite normal form)

template<typename UnitType>
void CASM::SupercellIterator< UnitType >::_update_super ( )
private

Update m_super when required.

Member Data Documentation

template<typename UnitType>
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef std::forward_iterator_tag CASM::SupercellIterator< UnitType >::iterator_category

fixes alignment of m_deformation

Definition at line 259 of file SupercellEnumerator.hh.

template<typename UnitType>
std::vector<Eigen::Matrix3i> CASM::SupercellIterator< UnitType >::m_canon_hist
private

Keep track of the HNF matrices for the current determinant value.

Definition at line 333 of file SupercellEnumerator.hh.

template<typename UnitType>
notstd::cloneable_ptr<HermiteCounter> CASM::SupercellIterator< UnitType >::m_current
private

Current supercell matrix in HermitCounter form.

Definition at line 327 of file SupercellEnumerator.hh.

template<typename UnitType>
const SupercellEnumerator<UnitType>* CASM::SupercellIterator< UnitType >::m_enum
private

Pointer to SupercellEnumerator which holds the unit cell and point group.

Definition at line 324 of file SupercellEnumerator.hh.

template<typename UnitType>
UnitType CASM::SupercellIterator< UnitType >::m_super
mutableprivate

A supercell, stored here so that iterator dereferencing will be OK. Only used when requested.

Definition at line 330 of file SupercellEnumerator.hh.

template<typename UnitType>
bool CASM::SupercellIterator< UnitType >::m_super_updated
mutableprivate

Indicates if m_super reflects the current m_current supercell matrix.

Definition at line 321 of file SupercellEnumerator.hh.


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