16 template<
typename T,
typename U>
class ConfigIterator;
17 class PermuteIterator;
35 class Supercell :
public Comparisons<Supercell> {
41 typedef boost::container::stable_vector<Configuration>
ConfigList;
168 Supercell(
PrimClex *_prim,
const Eigen::Ref<const Eigen::Matrix3i> &superlattice_matrix);
213 return m_prim_grid.
size();
226 t_bijk[0] =
get_b(i);
250 if(m_perm_symrep_ID.
empty())
288 return config_list[i];
292 return config_list[i];
410 template<
typename ConfigIterType>
413 template<
typename ConfigIterType>
414 void add_configs(ConfigIterType it_begin, ConfigIterType it_end);
437 bool print_config_name)
const;
464 template<
typename ConfigIterType>
469 Index N_existing_enumerated = 0;
474 for(; it_begin != it_end; ++it_begin) {
479 if(N_existing_enumerated != N_existing) {
481 config_list[index].push_back_source(it_begin->source());
483 N_existing_enumerated++;
495 template<
typename ConfigIterType>
497 for(; it_begin != it_end; ++it_begin) {
502 std::string
generate_name(
const Eigen::Matrix3i &transf_mat);
const Configuration & get_config(Index i) const
const Array< Permutation > & translation_permute() const
const PrimGrid & prim_grid() const
Supercell(const Supercell &RHS)
SymOp from_canonical() const
Eigen::MatrixXd pad(const Eigen::MatrixXd &M, int n)
Construct a matrix consisting of blocks M and Identity(n,n)
Coordinate coord(const UnitCellCoord &bijk) const
void _add_canon_config(const Configuration &config)
std::string get_name() const
Return supercell name.
ConfigIterator< const Configuration, const PrimClex > config_const_iterator
Eigen::MatrixXcd m_fourier_matrix
ReturnArray< int > max_allowed_occupation() const
void generate_factor_group() const
std::string m_name
unique name of the supercell based on hermite normal form (see _generate_name() ) ...
PermuteIterator permute_const_iterator
std::map< const Configuration *, Index, ConfigMapCompare > m_config_map
std::pair< config_const_iterator, bool > insert_config(const Configuration &config)
Insert a configuration that may be non-canonical.
const Lattice & get_recip_prim_lattice() const
SymGroupRep const & permutation_symrep() const
void read_clex_relaxations(const Lattice &home_lattice)
Type-safe ID object for communicating and accessing Symmetry representation info. ...
void generate_all_delta_config_props()
Calculate delta properties for each configuration in *this (see above)
bool empty() const
Returns true if SymGroupRepID has not been initialized with valid group_index or rep_index.
const Eigen::MatrixXcd & fourier_matrix() const
Eigen::Matrix3i transf_mat
std::string generate_name(const Eigen::Matrix3i &transf_mat)
const Structure & get_prim() const
Structure specifies the lattice and atomic basis of a crystal.
Object copy_apply(const Transform &f, Object obj, Args &&...args)
void generate_delta_config_props(Index config_index)
Calculate delta properties for a configuration (must have read in calculated and reference properties...
Configuration configuration(const BasicStructure< Site > &structure_to_config, double tol=TOL)
SymGroupRepID permutation_symrep_ID() const
void _generate_name() const
notstd::cloneable_ptr< SuperNeighborList > m_nlist
const Lattice & get_real_super_lattice() const
const Eigen::MatrixXd & k_mesh() const
SymOp to_canonical() const
const ConfigList & get_config_list() const
Supercell & canonical_form() const
void generate_permutations() const
ConfigList & get_config_list()
bool operator()(const Configuration *A, const Configuration *B) const
Supercell * m_canonical
Store a pointer to the canonical equivalent Supercell.
Represents a supercell of the primitive parent crystal structure.
config_const_iterator config_cend() const
Lattice recip_prim_lattice
void generate_fourier_matrix()
Structure Factor.
bool contains_config(const Configuration &config) const
PrimClex & get_primclex() const
void read_config_list(const jsonParser &json)
void read_relaxed_structure(Index configNum, const Lattice &home_lattice)
jsonParser & write_config_list(jsonParser &json)
Call Configuration::write out every configuration in supercell.
fs::path get_path() const
Return path to supercell directory.
The SuperNeighborList gives the linear indices of neighboring sites and unitcells in a particular Sup...
SymGroup is a collection of symmetry operations that satisfy the group property The symmetry operatio...
void generate_phase_factor(const Eigen::MatrixXd &shift_vectors, const Array< bool > &is_commensurate, const bool &override)
permute_const_iterator permute_begin() const
Lattice real_super_lattice
boost::container::stable_vector< Configuration > ConfigList
void print_PERTURB_json(std::ofstream &file, const Configuration &background_config, const Array< Array< Array< Index > > > &perturb_config_index, const Array< Array< Array< permute_const_iterator > > > &perturb_config_symop_index, bool print_config_name) const
SymOp is the Coordinate representation of a symmetry operation it keeps fraction (FRAC) and Cartesian...
const MasterSymGroup & factor_group() const
Represents cartesian and fractional coordinates.
ConfigIterator< Configuration, PrimClex > config_iterator
const SuperNeighborList & nlist() const
Returns the SuperNeighborList.
EigenIndex Index
For long integer indexing:
Index volume() const
Return number of primitive cells that fit inside of *this.
Array< bool > is_commensurate_kpoint(const Eigen::MatrixXd &recip_coordinates, double tol=TOL)
Array< CoordType > basis
Lattice vectors that specifies periodicity of the crystal.
bool add_canon_config(const Configuration &config, Index &index)
Structure superstructure() const
Index m_id
index into PrimClex::supercell_list
void add_configs(ConfigIterType it_begin, ConfigIterType it_end)
bool add_config(const Configuration &config)
permute_const_iterator translate_begin() const
Begin iterator over pure translational permutations.
const SymGroup & factor_group() const
PrimClex is the top-level data structure for a CASM project.
UnitCellCoord uccoord(Index i) const
bool is_supercell_of(const Structure &structure) const
Eigen::MatrixXd real_coordinates() const
Index get_linear_index(const Site &site, double tol=TOL) const
config_const_iterator config_cbegin() const
Index find(const UnitCellCoord &bijk) const
void enumerate_perturb_configurations(const std::string &background, fs::path CSPECS, double tol=TOL, bool verbose=false, bool print=false)
void print_sublat_to_comp(std::ostream &stream)
Old CASM style corr.in output for all the configurations in *this supercell.
bool is_equivalent(const Supercell &B) const
void printUCC(std::ostream &stream, COORD_TYPE mode, UnitCellCoord ucc, char term=0, int prec=7, int pad=5) const
permute_const_iterator translate_end() const
End iterator over pure translational permutations.
bool is_canonical() const
Eigen::MatrixXd recip_coordinates() const
config_iterator config_end()
config_iterator config_begin()
Configuration & get_config(Index i)
SymGroupRep is an alternative representation of a SymGroup for something other than real space...
const Permutation & factor_group_permute(Index i) const
void populate_structure_factor()
Eigen::MatrixXcd m_phase_factor
Index amount_selected() const
Count how many configs are selected in *this.
A 'cloneable_ptr' can be used in place of 'unique_ptr'.
void generate_all_reference_config_props()
Calculate reference properties for each configuration in *this (see above)
UnitCellCoord uccoord(Index i) const
bool _eq(const Supercell &B) const
std::pair< config_const_iterator, bool > insert_canon_config(const Configuration &config)
Insert a configuration that is known to be canonical.
bool operator<(const Supercell &B) const
const Eigen::MatrixXcd & phase_factor() const
const Eigen::Matrix3i & get_transf_mat() const
Index get_b(Index i) const
void add_unique_canon_configs(ConfigIterType it_begin, ConfigIterType it_end)
Index m_nlist_size_at_construction
ReturnArray< int > vacant() const
SymGroupRepID m_perm_symrep_ID
permute_const_iterator permute_end() const
Object & apply(const Transform &f, Object &obj, Args &&...args)
void generate_reference_config_props(Index config_index)
Calculate reference properties for a configuration (must have reference states in appropriate directo...
permute_const_iterator permute_it(Index fg_index, Index trans_index) const
A Configuration represents the values of all degrees of freedom in a Supercell.
void print_bijk(std::ostream &stream)
SymGroupRep const & representation(SymGroupRepID i) const
Const access of alternate Representations of a SymGroup.