CASM  1.1.0
A Clusters Approach to Statistical Mechanics
SiteExchanger.hh
Go to the documentation of this file.
1 #ifndef CASM_SiteExchanger_HH
2 #define CASM_SiteExchanger_HH
3 
4 #include <vector>
5 
7 
8 namespace CASM {
9 
10 class Supercell;
11 
12 }
13 
14 namespace CASM {
15 namespace Monte {
16 
18  public:
20  SiteExchanger(const Supercell &scel);
21 
24  const std::vector<Index> &variable_sites() const { return m_variable_sites; }
25 
28  const std::vector<int> &sublattice() const { return m_sublat; }
29 
35  const std::vector<std::vector<std::vector<int> > > &possible_swap() const {
36  return m_possible_swap;
37  }
38 
43  const std::vector<std::vector<int> > &sublat_to_mol() const {
44  return m_sublat_to_mol;
45  }
46 
47  private:
50  std::vector<Index> m_variable_sites;
51 
53  std::vector<int> m_sublat;
54 
58  std::vector<std::vector<std::vector<int> > > m_possible_swap;
59 
63  std::vector<std::vector<int> > m_sublat_to_mol;
64 };
65 
66 } // namespace Monte
67 } // namespace CASM
68 
69 #endif
std::vector< int > m_sublat
m_sublat[i] is the sublattice index for site m_variable_sites[i]
SiteExchanger(const Supercell &scel)
Constructor determine possible swaps in the given Supercell.
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.
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< 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
const std::vector< int > & sublattice() const
sublattice()[i] is the sublattice index for site 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_...
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...
Represents a supercell of the primitive parent crystal structure.
Definition: Supercell.hh:51
Main CASM namespace.
Definition: APICommand.hh:8