CASM
AClustersApproachtoStatisticalMechanics
|
PrimClex is the top-level data structure for a CASM project.
Classes | |
class | CASM::PrimClex |
PrimClex is the top-level data structure for a CASM project. More... | |
Typedefs | |
typedef ConfigIterator < Configuration, PrimClex > | CASM::PrimClex::config_iterator |
typedef ConfigIterator< const Configuration, const PrimClex > | CASM::PrimClex::config_const_iterator |
Functions | |
CASM::PrimClex::PrimClex (const Structure &_prim, const Logging &logging=Logging()) | |
Initial construction of a PrimClex, from a primitive Structure. More... | |
CASM::PrimClex::PrimClex (const fs::path &_root, const Logging &logging=Logging()) | |
void | CASM::PrimClex::refresh (bool read_settings=false, bool read_composition=false, bool read_chem_ref=false, bool read_configs=false, bool clear_clex=false) |
Reload PrimClex data from settings. More... | |
std::string | CASM::PrimClex::name () const |
Return project name. More... | |
const DirectoryStructure & | CASM::PrimClex::dir () const |
ProjectSettings & | CASM::PrimClex::settings () |
const ProjectSettings & | CASM::PrimClex::settings () const |
double | CASM::PrimClex::crystallography_tol () const |
double | CASM::PrimClex::lin_alg_tol () const |
fs::path | CASM::PrimClex::get_path () const |
Return casm project directory path. More... | |
fs::path | CASM::PrimClex::get_path (const Index &scel_index) const |
Return supercell directory path. More... | |
fs::path | CASM::PrimClex::get_path (const Index &scel_index, const Index &config_index) const |
Return configuration directory path. More... | |
fs::path | CASM::PrimClex::get_config_list_path () const |
Return config_list.json file path. More... | |
bool | CASM::PrimClex::has_composition_axes () const |
check if CompositionConverter object initialized More... | |
const CompositionConverter & | CASM::PrimClex::composition_axes () const |
const Access CompositionConverter object More... | |
bool | CASM::PrimClex::has_chemical_reference () const |
check if ChemicalReference object initialized More... | |
const ChemicalReference & | CASM::PrimClex::chemical_reference () const |
const Access ChemicalReference object More... | |
const Structure & | CASM::PrimClex::get_prim () const |
const Access to primitive Structure More... | |
PrimNeighborList & | CASM::PrimClex::nlist () const |
Access to the primitive neighbor list. More... | |
bool | CASM::PrimClex::vacancy_allowed () const |
returns true if vacancy are an allowed species More... | |
Index | CASM::PrimClex::vacancy_index () const |
returns the index of vacancies in composition vectors More... | |
boost::container::stable_vector < Supercell > & | CASM::PrimClex::get_supercell_list () |
Access entire supercell_list. More... | |
const boost::container::stable_vector < Supercell > & | CASM::PrimClex::get_supercell_list () const |
const Access entire supercell_list More... | |
const Supercell & | CASM::PrimClex::get_supercell (Index i) const |
const Access supercell by index More... | |
Supercell & | CASM::PrimClex::get_supercell (Index i) |
Access supercell by index. More... | |
const Supercell & | CASM::PrimClex::get_supercell (std::string scellname) const |
const Access supercell by name More... | |
Supercell & | CASM::PrimClex::get_supercell (std::string scellname) |
Access supercell by name. More... | |
Supercell & | CASM::PrimClex::get_supercell (const Lattice &lat) |
Access supercell by Lattice, adding if necessary. More... | |
const Configuration & | CASM::PrimClex::configuration (const std::string &configname) const |
access configuration by name (of the form "scellname/[NUMBER]", e.g., ("SCEL1_1_1_1_0_0_0/0") More... | |
Configuration & | CASM::PrimClex::configuration (const std::string &configname) |
config_iterator | CASM::PrimClex::config_begin () |
Configuration iterator: begin. More... | |
config_iterator | CASM::PrimClex::config_end () |
Configuration iterator: end. More... | |
config_const_iterator | CASM::PrimClex::config_begin () const |
Configuration iterator: begin. More... | |
config_const_iterator | CASM::PrimClex::config_end () const |
Configuration iterator: end. More... | |
config_const_iterator | CASM::PrimClex::config_cbegin () const |
const Configuration iterator: begin More... | |
config_const_iterator | CASM::PrimClex::config_cend () const |
const Configuration iterator: end More... | |
config_iterator | CASM::PrimClex::selected_config_begin () |
Configuration iterator: begin. More... | |
config_iterator | CASM::PrimClex::selected_config_end () |
Configuration iterator: end. More... | |
config_const_iterator | CASM::PrimClex::selected_config_cbegin () const |
const Configuration iterator: begin More... | |
config_const_iterator | CASM::PrimClex::selected_config_cend () const |
const Configuration iterator: end More... | |
Eigen::MatrixXd | CASM::PrimClex::shift_vectors () const |
private: More... | |
void | CASM::PrimClex::set_composition_axes (const CompositionConverter &_converter) |
Sets the composition axes. More... | |
void | CASM::PrimClex::write_config_list (std::set< std::string > scel_to_delete={}) |
void | CASM::PrimClex::generate_supercells (const ScelEnumProps &enum_props) |
Use the given CSPECS. More... | |
void | CASM::PrimClex::print_enum_info (std::ostream &stream) |
void | CASM::PrimClex::print_supercells (std::set< std::string > scel_to_delete={}) const |
void | CASM::PrimClex::print_supercells (std::ostream &stream, std::set< std::string > scel_to_delete={}) const |
void | CASM::PrimClex::read_supercells (std::istream &stream) |
void | CASM::PrimClex::print_clex_configurations () |
void | CASM::PrimClex::read_config_list () |
void | CASM::PrimClex::read_scel_props (int scel_index, const std::string &JSON_output) |
Fill up props of every configuration for a partucluar supercell. This will be deprecated when props disappears. More... | |
void | CASM::PrimClex::read_all_scel_props (const std::string &JSON_output) |
Call read_config_props on every Supercell. More... | |
int | CASM::PrimClex::amount_selected () const |
Count over the number of configurations that are selected in all supercells. More... | |
bool | CASM::PrimClex::contains_supercell (std::string scellname, Index &index) const |
bool | CASM::PrimClex::contains_supercell (const Supercell &scel) const |
bool | CASM::PrimClex::contains_supercell (const Supercell &scel, Index &index) const |
Index | CASM::PrimClex::add_supercell (const Lattice &superlat) |
Index | CASM::PrimClex::add_canonical_supercell (const Lattice &superlat) |
Eigen::Matrix3i | CASM::PrimClex::calc_transf_mat (const Lattice &superlat) const |
void | CASM::PrimClex::set_global_dof_state (const Configuration &curr_config) const |
Set internal values of each DoFEnvironment. More... | |
void | CASM::PrimClex::set_local_dof_state (const Configuration &curr_config, Index l) const |
bool | CASM::PrimClex::has_orbitree (const ClexDescription &key) const |
const Access to global orbitree More... | |
const SiteOrbitree & | CASM::PrimClex::orbitree (const ClexDescription &key) const |
bool | CASM::PrimClex::has_clexulator (const ClexDescription &key) const |
Clexulator | CASM::PrimClex::clexulator (const ClexDescription &key) const |
bool | CASM::PrimClex::has_eci (const ClexDescription &key) const |
const ECIContainer & | CASM::PrimClex::eci (const ClexDescription &key) const |
void | CASM::PrimClex::_init () |
Initialization routines. More... | |
SiteOrbitree | CASM::make_orbitree (Structure &prim, const jsonParser &json, double _tol) |
Make orbitree. For now specifically global. More... | |
void | CASM::print_clexulator (const Structure &prim, SiteOrbitree &tree, const PrimNeighborList &nlist, std::string class_name, std::ostream &stream, double xtal_tol) |
Print clexulator. More... | |
Variables | |
fs::path | CASM::PrimClex::root |
DirectoryStructure | CASM::PrimClex::m_dir |
ProjectSettings | CASM::PrimClex::m_settings |
Structure | CASM::PrimClex::prim |
bool | CASM::PrimClex::m_vacancy_allowed |
Index | CASM::PrimClex::m_vacancy_index |
DoFManager | CASM::PrimClex::m_dof_manager |
boost::container::stable_vector < Supercell > | CASM::PrimClex::supercell_list |
Contains all the supercells that were involved in the enumeration. More... | |
bool | CASM::PrimClex::m_has_composition_axes = false |
CompositionConverter | CASM::PrimClex::m_comp_converter |
notstd::cloneable_ptr < ChemicalReference > | CASM::PrimClex::m_chem_ref |
notstd::cloneable_ptr < PrimNeighborList > | CASM::PrimClex::m_nlist |
std::map< ClexDescription, SiteOrbitree > | CASM::PrimClex::m_orbitree |
std::map< ClexDescription, Clexulator > | CASM::PrimClex::m_clexulator |
std::map< ClexDescription, ECIContainer > | CASM::PrimClex::m_eci |
typedef ConfigIterator<const Configuration, const PrimClex> CASM::PrimClex::config_const_iterator |
Definition at line 86 of file PrimClex.hh.
typedef ConfigIterator<Configuration, PrimClex> CASM::PrimClex::config_iterator |
Definition at line 85 of file PrimClex.hh.
|
private |
Initialization routines.
Initialization routines
Definition at line 49 of file PrimClex.cc.
Index CASM::PrimClex::add_canonical_supercell | ( | const Lattice & | superlat | ) |
add a supercell if it doesn't already exist return the index of the supercell in supercell_list
TODO: Check to see if superlat is linear combination of previously enumerated Supercell. You'll have to transform the coordinates if you're trying to import something with a supercell that already exists. Should return operations involved. If supercell doesn't exist add it as it is without transforming
Definition at line 511 of file PrimClex.cc.
Index CASM::PrimClex::add_supercell | ( | const Lattice & | superlat | ) |
add a supercell if it doesn't already exist return the index of the supercell in supercell_list
Unlike the initial version above this, this routine will use an Array of SymOps (probably the point group of the lattice) to determine whether the provided superlat is equivalent to a Supercell in the PrimClex list. It will then populate the transformation matrix that maps the passed lattice onto the one on the list (i.e. the one on on the list is treated as 'primitive'). If it doesn't map, then the matrix gets flattened to zeros.
This routine should replace the original one once it converges to something people can agree on.
Definition at line 550 of file PrimClex.cc.
int CASM::PrimClex::amount_selected | ( | ) | const |
Count over the number of configurations that are selected in all supercells.
Definition at line 700 of file PrimClex.cc.
Eigen::Matrix3i CASM::PrimClex::calc_transf_mat | ( | const Lattice & | superlat | ) | const |
Definition at line 731 of file PrimClex.cc.
const ChemicalReference & CASM::PrimClex::chemical_reference | ( | ) | const |
const Access ChemicalReference object
Definition at line 251 of file PrimClex.cc.
Clexulator CASM::PrimClex::clexulator | ( | const ClexDescription & | key | ) | const |
Definition at line 1030 of file PrimClex.cc.
const CompositionConverter & CASM::PrimClex::composition_axes | ( | ) | const |
const Access CompositionConverter object
Definition at line 237 of file PrimClex.cc.
PrimClex::config_iterator CASM::PrimClex::config_begin | ( | ) |
Configuration iterator: begin.
Definition at line 371 of file PrimClex.cc.
PrimClex::config_const_iterator CASM::PrimClex::config_begin | ( | ) | const |
Configuration iterator: begin.
const Configuration iterator: begin
Definition at line 385 of file PrimClex.cc.
PrimClex::config_const_iterator CASM::PrimClex::config_cbegin | ( | ) | const |
const Configuration iterator: begin
Definition at line 399 of file PrimClex.cc.
PrimClex::config_const_iterator CASM::PrimClex::config_cend | ( | ) | const |
const Configuration iterator: end
Definition at line 407 of file PrimClex.cc.
PrimClex::config_iterator CASM::PrimClex::config_end | ( | ) |
Configuration iterator: end.
Definition at line 379 of file PrimClex.cc.
PrimClex::config_const_iterator CASM::PrimClex::config_end | ( | ) | const |
Configuration iterator: end.
const Configuration iterator: end
Definition at line 393 of file PrimClex.cc.
const Configuration & CASM::PrimClex::configuration | ( | const std::string & | configname | ) | const |
access configuration by name (of the form "scellname/[NUMBER]", e.g., ("SCEL1_1_1_1_0_0_0/0")
Definition at line 347 of file PrimClex.cc.
Configuration & CASM::PrimClex::configuration | ( | const std::string & | configname | ) |
Definition at line 365 of file PrimClex.cc.
bool CASM::PrimClex::contains_supercell | ( | std::string | scellname, |
Index & | index | ||
) | const |
Definition at line 709 of file PrimClex.cc.
bool CASM::PrimClex::contains_supercell | ( | const Supercell & | scel | ) | const |
Definition at line 721 of file PrimClex.cc.
Definition at line 726 of file PrimClex.cc.
|
inline |
Definition at line 124 of file PrimClex.hh.
|
inline |
Definition at line 112 of file PrimClex.hh.
const ECIContainer & CASM::PrimClex::eci | ( | const ClexDescription & | key | ) | const |
Definition at line 1076 of file PrimClex.cc.
void CASM::PrimClex::generate_supercells | ( | const ScelEnumProps & | enum_props | ) |
Use the given CSPECS.
Generate supercells of a certain volume and shape and store them in the array of supercells.
Generate supercells of a certain volume and shape and store them in the array of supercells
enum_props | An ScelEnumProps instance, see constructor for details |
Definition at line 492 of file PrimClex.cc.
fs::path CASM::PrimClex::get_config_list_path | ( | ) | const |
Return config_list.json file path.
Definition at line 220 of file PrimClex.cc.
fs::path CASM::PrimClex::get_path | ( | ) | const |
Return casm project directory path.
Definition at line 202 of file PrimClex.cc.
fs::path CASM::PrimClex::get_path | ( | const Index & | scel_index | ) | const |
Return supercell directory path.
Definition at line 208 of file PrimClex.cc.
Return configuration directory path.
Definition at line 214 of file PrimClex.cc.
const Structure & CASM::PrimClex::get_prim | ( | ) | const |
const Access to primitive Structure
Definition at line 260 of file PrimClex.cc.
const Supercell & CASM::PrimClex::get_supercell | ( | Index | i | ) | const |
const Access supercell by index
Definition at line 311 of file PrimClex.cc.
Supercell & CASM::PrimClex::get_supercell | ( | Index | i | ) |
Access supercell by index.
Definition at line 317 of file PrimClex.cc.
const Supercell & CASM::PrimClex::get_supercell | ( | std::string | scellname | ) | const |
const Access supercell by name
Definition at line 323 of file PrimClex.cc.
Supercell & CASM::PrimClex::get_supercell | ( | std::string | scellname | ) |
Access supercell by name.
Definition at line 335 of file PrimClex.cc.
Supercell & CASM::PrimClex::get_supercell | ( | const Lattice & | lat | ) |
Access supercell by Lattice, adding if necessary.
Definition at line 341 of file PrimClex.cc.
boost::container::stable_vector< Supercell > & CASM::PrimClex::get_supercell_list | ( | ) |
Access entire supercell_list.
const Access entire supercell_list
Definition at line 299 of file PrimClex.cc.
const boost::container::stable_vector< Supercell > & CASM::PrimClex::get_supercell_list | ( | ) | const |
const Access entire supercell_list
Definition at line 305 of file PrimClex.cc.
bool CASM::PrimClex::has_chemical_reference | ( | ) | const |
check if ChemicalReference object initialized
Definition at line 245 of file PrimClex.cc.
bool CASM::PrimClex::has_clexulator | ( | const ClexDescription & | key | ) | const |
Definition at line 1018 of file PrimClex.cc.
bool CASM::PrimClex::has_composition_axes | ( | ) | const |
check if CompositionConverter object initialized
const Access CompositionConverter object
Definition at line 231 of file PrimClex.cc.
bool CASM::PrimClex::has_eci | ( | const ClexDescription & | key | ) | const |
Definition at line 1065 of file PrimClex.cc.
bool CASM::PrimClex::has_orbitree | ( | const ClexDescription & | key | ) | const |
const Access to global orbitree
Delete 'properties.ref_state.X.json' files, Then call 'clear_reference_properties' Sets the root reference state to be the calculated properties of the chosen config Calls 'clear_reference_properties' Check that it is valid to use 'config' as reference state 'refid', returns bool and if false, sets 'reason_invalid' Currently checks: 1) that the necessary properties have been calculated, 2) that the same Configuration is not being used twice Needs to check that reference states span composition space find calculated configurations closest to [0, 0, 0, ...], [1, 0, 0, ...], [0, 1, 0, ...], [0, 0, 1, ...], ... and set them as the root reference states, also calls regenerate_references Clears reference states and properties whether or not it succeeds Clear 'reference' and 'delta' properties from all Configurations Re-write all Configurations, updating: param_composition.json properties.calc.json properties.ref.json properties.delta.json
Definition at line 983 of file PrimClex.cc.
|
inline |
Definition at line 128 of file PrimClex.hh.
SiteOrbitree CASM::make_orbitree | ( | Structure & | prim, |
const jsonParser & | json, | ||
double | _tol | ||
) |
Make orbitree. For now specifically global.
prim | Primitive Structure. non-const due to Structure::set_site_internals. |
json | bspecs.json file |
Definition at line 1097 of file PrimClex.cc.
std::string CASM::PrimClex::name | ( | ) | const |
Return project name.
Definition at line 194 of file PrimClex.cc.
PrimNeighborList & CASM::PrimClex::nlist | ( | ) | const |
Access to the primitive neighbor list.
Definition at line 266 of file PrimClex.cc.
const SiteOrbitree & CASM::PrimClex::orbitree | ( | const ClexDescription & | key | ) | const |
Definition at line 996 of file PrimClex.cc.
Initial construction of a PrimClex, from a primitive Structure.
Definition at line 21 of file PrimClex.cc.
Construct PrimClex from existing CASM project directory
Definition at line 36 of file PrimClex.cc.
void CASM::PrimClex::print_clex_configurations | ( | ) |
void CASM::print_clexulator | ( | const Structure & | prim, |
SiteOrbitree & | tree, | ||
const PrimNeighborList & | nlist, | ||
std::string | class_name, | ||
std::ostream & | stream, | ||
double | xtal_tol | ||
) |
Print clexulator.
Definition at line 1219 of file PrimClex.cc.
void CASM::PrimClex::print_enum_info | ( | std::ostream & | stream | ) |
void CASM::PrimClex::print_supercells | ( | std::set< std::string > | scel_to_delete = {} | ) | const |
Definition at line 557 of file PrimClex.cc.
void CASM::PrimClex::print_supercells | ( | std::ostream & | stream, |
std::set< std::string > | scel_to_delete = {} |
||
) | const |
Definition at line 593 of file PrimClex.cc.
void CASM::PrimClex::read_all_scel_props | ( | const std::string & | JSON_output | ) |
Call read_config_props on every Supercell.
void CASM::PrimClex::read_config_list | ( | ) |
Read the config_list file at 'file_name' and adds config to supercell, assuming it is already canonical. If 'print_dirs', call Supercell::print_clex_configuration() for each config to be made.
Definition at line 680 of file PrimClex.cc.
void CASM::PrimClex::read_scel_props | ( | int | scel_index, |
const std::string & | JSON_output | ||
) |
Fill up props of every configuration for a partucluar supercell. This will be deprecated when props disappears.
void CASM::PrimClex::read_supercells | ( | std::istream & | stream | ) |
Definition at line 605 of file PrimClex.cc.
void CASM::PrimClex::refresh | ( | bool | read_settings = false , |
bool | read_composition = false , |
||
bool | read_chem_ref = false , |
||
bool | read_configs = false , |
||
bool | clear_clex = false |
||
) |
Reload PrimClex data from settings.
read_settings | Read project_settings.json and plugins |
read_composition | Read composition_axes.json |
read_chem_ref | Read chemical_reference.json |
read_configs | Read SCEL and config_list.json |
clear_clex | Clear stored orbitrees, clexulators, and eci |
Definition at line 90 of file PrimClex.cc.
PrimClex::config_iterator CASM::PrimClex::selected_config_begin | ( | ) |
Configuration iterator: begin.
Definition at line 413 of file PrimClex.cc.
PrimClex::config_const_iterator CASM::PrimClex::selected_config_cbegin | ( | ) | const |
const Configuration iterator: begin
Definition at line 430 of file PrimClex.cc.
PrimClex::config_const_iterator CASM::PrimClex::selected_config_cend | ( | ) | const |
const Configuration iterator: end
Definition at line 438 of file PrimClex.cc.
PrimClex::config_iterator CASM::PrimClex::selected_config_end | ( | ) |
Configuration iterator: end.
Definition at line 424 of file PrimClex.cc.
void CASM::PrimClex::set_composition_axes | ( | const CompositionConverter & | _converter | ) |
Sets the composition axes.
Sets the composition axes, updates all configuration references, and writes the updated configuration info
Also:
Definition at line 749 of file PrimClex.cc.
|
inline |
Set internal values of each DoFEnvironment.
Definition at line 293 of file PrimClex.hh.
|
inline |
Definition at line 297 of file PrimClex.hh.
|
inline |
Definition at line 116 of file PrimClex.hh.
|
inline |
Definition at line 120 of file PrimClex.hh.
Eigen::MatrixXd CASM::PrimClex::shift_vectors | ( | ) | const |
private:
Definition at line 973 of file PrimClex.cc.
bool CASM::PrimClex::vacancy_allowed | ( | ) | const |
returns true if vacancy are an allowed species
Definition at line 284 of file PrimClex.cc.
Index CASM::PrimClex::vacancy_index | ( | ) | const |
returns the index of vacancies in composition vectors
Definition at line 290 of file PrimClex.cc.
void CASM::PrimClex::write_config_list | ( | std::set< std::string > | scel_to_delete = {} | ) |
Call Configuration::write on every configuration to update files
Re-write config_list.json, excluding specified scel
Definition at line 450 of file PrimClex.cc.
|
private |
ChemicalReference specifies a reference for formation energies, chemical potentials, etc.
Definition at line 76 of file PrimClex.hh.
|
mutableprivate |
Definition at line 345 of file PrimClex.hh.
|
private |
Definition at line 72 of file PrimClex.hh.
|
private |
Definition at line 56 of file PrimClex.hh.
|
mutableprivate |
Definition at line 63 of file PrimClex.hh.
|
mutableprivate |
Definition at line 346 of file PrimClex.hh.
|
private |
CompositionConverter specifies parameteric composition axes and converts between parametric composition and mol composition
Definition at line 71 of file PrimClex.hh.
|
mutableprivate |
Stores the neighboring UnitCell and which sublattices to include in neighbor lists
Definition at line 80 of file PrimClex.hh.
|
mutableprivate |
Definition at line 344 of file PrimClex.hh.
|
private |
Definition at line 57 of file PrimClex.hh.
|
private |
Definition at line 60 of file PrimClex.hh.
|
private |
Definition at line 61 of file PrimClex.hh.
|
private |
Definition at line 59 of file PrimClex.hh.
|
private |
Definition at line 54 of file PrimClex.hh.
|
private |
Contains all the supercells that were involved in the enumeration.
Definition at line 66 of file PrimClex.hh.