CASM
AClustersApproachtoStatisticalMechanics
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules
SiteExchanger.hh
Go to the documentation of this file.
1 #ifndef CASM_SiteExchanger_HH
2 #define CASM_SiteExchanger_HH
3 
4 #include <vector>
6 
7 namespace CASM {
8 
9  class Supercell;
10 
11  class SiteExchanger {
12 
13  public:
14 
16  SiteExchanger(const Supercell &scel);
17 
19  const std::vector<Index> &variable_sites() const {
20  return m_variable_sites;
21  }
22 
24  const std::vector<int> &sublat() const {
25  return m_sublat;
26  }
27 
31  const std::vector< std::vector< std::vector<int> > > &possible_swap() const {
32  return m_possible_swap;
33  }
34 
38  const std::vector< std::vector<int> > &sublat_to_mol() const {
39  return m_sublat_to_mol;
40  }
41 
42  private:
43 
45  std::vector<Index> m_variable_sites;
46 
48  std::vector<int> m_sublat;
49 
52  std::vector< std::vector< std::vector<int> > > m_possible_swap;
53 
56  std::vector< std::vector<int> > m_sublat_to_mol;
57 
58  };
59 
60 
61 }
62 
63 #endif
64 
65 
SiteExchanger(const Supercell &scel)
Constructor determine possible swaps in the given Supercell.
std::vector< std::vector< std::vector< int > > > m_possible_swap
For a given sublattice with a particular occupant, show what OTHER occupants it could be m_possible_s...
Main CASM namespace.
Definition: complete.cpp:8
Represents a supercell of the primitive parent crystal structure.
Definition: Supercell.hh:37
const std::vector< std::vector< std::vector< int > > > & possible_swap() const
For a given sublattice with a particular occupant, show what OTHER occupants it could be...
const std::vector< int > & sublat() const
sublat()[i] is the sublattice index for site variable_sites()[i]
const std::vector< Index > & variable_sites() const
std::vector of indices into occupation array of ConfigDoF that have more than one allowed occupant ...
std::vector< Index > m_variable_sites
std::vector of indices into occupation array of m_confdof that have more than one allowed occupant ...
std::vector< int > m_sublat
m_sublat[i] is the sublattice index for site m_variable_sites[i]
std::vector< std::vector< int > > m_sublat_to_mol
Map the integer values from the possible swaps or variable sites arrays into actual species m_sublat_...
const std::vector< std::vector< int > > & sublat_to_mol() const
Map the integer values from the possible swaps or variable sites arrays into actual species...