CASM  1.1.0
A Clusters Approach to Statistical Mechanics
PrimClex

Detailed Description

PrimClex is the top-level data structure for a CASM project.

Classes

class  CASM::DB::ValDatabase< ValueType >
 Generic interface for database of a particular CASM type. More...
 
class  CASM::DB::Database< T >
 
class  CASM::PrimClex
 PrimClex is the top-level data structure for a CASM project. More...
 

Typedefs

typedef Structure CASM::PrimClex::PrimType
 

Functions

 CASM::PrimClex::PrimClex (ProjectSettings const &_project_settings, std::shared_ptr< PrimType const > _shared_prim)
 Initial construction of a PrimClex, from ProjectSettings and shared prim. More...
 
 CASM::PrimClex::PrimClex (const fs::path &_root)
 
 CASM::PrimClex::PrimClex (const PrimClex &)=delete
 
 CASM::PrimClex::~PrimClex ()
 Necessary for "pointer to implementation". More...
 
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...
 
ProjectSettingsCASM::PrimClex::settings ()
 
const ProjectSettingsCASM::PrimClex::settings () const
 
bool CASM::PrimClex::has_dir () const
 Check if DirectoryStructure exists. More...
 
const DirectoryStructureCASM::PrimClex::dir () const
 Access DirectoryStructure object. Throw if not set. More...
 
double CASM::PrimClex::crystallography_tol () const
 Get the crystallography_tol. More...
 
bool CASM::PrimClex::has_composition_axes () const
 check if CompositionConverter object initialized More...
 
const CompositionConverterCASM::PrimClex::composition_axes () const
 const Access CompositionConverter object More...
 
bool CASM::PrimClex::has_chemical_reference () const
 check if ChemicalReference object initialized More...
 
const ChemicalReferenceCASM::PrimClex::chemical_reference () const
 const Access ChemicalReference object More...
 
const PrimTypeCASM::PrimClex::prim () const
 const Access to primitive Structure More...
 
std::shared_ptr< PrimType const > const & CASM::PrimClex::shared_prim () const
 Access to the primitive Structure as a shared resource. More...
 
Index CASM::PrimClex::n_basis () const
 const Access to number of basis atoms More...
 
std::shared_ptr< PrimNeighborList > const & CASM::PrimClex::shared_nlist () const
 Access to the primitive neighbor list as a shared resource. More...
 
PrimNeighborListCASM::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...
 
template<typename T >
DB::ValDatabase< T > & CASM::PrimClex::generic_db () const
 
template<typename T >
const DB::ValDatabase< T > & CASM::PrimClex::const_generic_db () const
 
template<typename T >
DB::Database< T > & CASM::PrimClex::db () const
 
template<typename T >
const DB::Database< T > & CASM::PrimClex::const_db () const
 
template<typename T >
DB::PropertiesDatabaseCASM::PrimClex::db_props (std::string calc_type) const
 
template<typename T >
const DB::PropertiesDatabaseCASM::PrimClex::const_db_props (std::string calc_type) const
 
DB::DatabaseHandlerCASM::PrimClex::db_handler () const
 
const DB::DatabaseHandlerCASM::PrimClex::const_db_handler () const
 
bool CASM::PrimClex::has_basis_set_specs (std::string const &basis_set_name) const
 
ClexBasisSpecs const & CASM::PrimClex::basis_set_specs (std::string const &basis_set_name) const
 
Clexulator CASM::PrimClex::clexulator (std::string const &basis_set_name) const
 
bool CASM::PrimClex::has_eci (const ClexDescription &key) const
 
ECIContainer const & CASM::PrimClex::eci (const ClexDescription &key) const
 
void CASM::PrimClex::_init ()
 Initialization routines. More...
 
void CASM::write_basis_set_data (std::shared_ptr< Structure const > shared_prim, ProjectSettings const &settings, std::string const &basis_set_name, ClexBasisSpecs const &basis_set_specs, PrimNeighborList &prim_neighbor_list)
 
Clexulator CASM::make_clexulator (ProjectSettings const &settings, std::string const &basis_set_name, PrimNeighborList &prim_neighbor_list)
 

Variables

std::unique_ptr< PrimClexDataCASM::PrimClex::m_data
 

Typedef Documentation

◆ PrimType

Definition at line 57 of file PrimClex.hh.

Function Documentation

◆ _init()

void CASM::PrimClex::_init ( )
private

Initialization routines.

Initialization routines

  • If !root.empty(), read all saved data to generate all Supercells and Configurations, etc.

Definition at line 121 of file PrimClex.cc.

◆ basis_set_specs()

ClexBasisSpecs const & CASM::PrimClex::basis_set_specs ( std::string const &  basis_set_name) const

Definition at line 344 of file PrimClex.cc.

◆ chemical_reference()

const ChemicalReference & CASM::PrimClex::chemical_reference ( ) const

const Access ChemicalReference object

Definition at line 255 of file PrimClex.cc.

◆ clexulator()

Clexulator CASM::PrimClex::clexulator ( std::string const &  basis_set_name) const

Definition at line 366 of file PrimClex.cc.

◆ composition_axes()

const CompositionConverter & CASM::PrimClex::composition_axes ( ) const

const Access CompositionConverter object

Definition at line 243 of file PrimClex.cc.

◆ const_db()

template<typename T >
const DB::Database< T > & CASM::PrimClex::const_db

Definition at line 307 of file PrimClex.cc.

◆ const_db_handler()

const DB::DatabaseHandler & CASM::PrimClex::const_db_handler ( ) const

Definition at line 329 of file PrimClex.cc.

◆ const_db_props()

template<typename T >
const DB::PropertiesDatabase & CASM::PrimClex::const_db_props ( std::string  calc_type) const

Definition at line 317 of file PrimClex.cc.

◆ const_generic_db()

template<typename T >
const DB::ValDatabase< T > & CASM::PrimClex::const_generic_db

Definition at line 297 of file PrimClex.cc.

◆ crystallography_tol()

double CASM::PrimClex::crystallography_tol ( ) const

Get the crystallography_tol.

Definition at line 233 of file PrimClex.cc.

◆ db()

template<typename T >
DB::Database< T > & CASM::PrimClex::db

Definition at line 302 of file PrimClex.cc.

◆ db_handler()

DB::DatabaseHandler & CASM::PrimClex::db_handler ( ) const

Definition at line 322 of file PrimClex.cc.

◆ db_props()

template<typename T >
DB::PropertiesDatabase & CASM::PrimClex::db_props ( std::string  calc_type) const

Definition at line 312 of file PrimClex.cc.

◆ dir()

const DirectoryStructure & CASM::PrimClex::dir ( ) const

Access DirectoryStructure object. Throw if not set.

Definition at line 230 of file PrimClex.cc.

◆ eci()

const ECIContainer & CASM::PrimClex::eci ( const ClexDescription key) const

Definition at line 406 of file PrimClex.cc.

◆ generic_db()

template<typename T >
DB::ValDatabase< T > & CASM::PrimClex::generic_db

Definition at line 292 of file PrimClex.cc.

◆ has_basis_set_specs()

bool CASM::PrimClex::has_basis_set_specs ( std::string const &  basis_set_name) const

Definition at line 336 of file PrimClex.cc.

◆ has_chemical_reference()

bool CASM::PrimClex::has_chemical_reference ( ) const

check if ChemicalReference object initialized

Definition at line 250 of file PrimClex.cc.

◆ has_composition_axes()

bool CASM::PrimClex::has_composition_axes ( ) const

check if CompositionConverter object initialized

const Access CompositionConverter object

Definition at line 238 of file PrimClex.cc.

◆ has_dir()

bool CASM::PrimClex::has_dir ( ) const

Check if DirectoryStructure exists.

Definition at line 228 of file PrimClex.cc.

◆ has_eci()

bool CASM::PrimClex::has_eci ( const ClexDescription key) const

Definition at line 397 of file PrimClex.cc.

◆ make_clexulator()

Clexulator CASM::make_clexulator ( ProjectSettings const &  settings,
std::string const &  basis_set_name,
PrimNeighborList prim_neighbor_list 
)

Make Clexulator from existing source code

Notes:

  • Use write_basis_set_data to write Clexulator source code prior to calling this function.
  • This function will compile the Clexulator source code if that has not yet been done.

Definition at line 524 of file PrimClex.cc.

◆ n_basis()

Index CASM::PrimClex::n_basis ( ) const

const Access to number of basis atoms

Definition at line 268 of file PrimClex.cc.

◆ nlist()

PrimNeighborList & CASM::PrimClex::nlist ( ) const

Access to the primitive neighbor list.

Definition at line 283 of file PrimClex.cc.

◆ prim()

const PrimClex::PrimType & CASM::PrimClex::prim ( ) const

const Access to primitive Structure

Definition at line 262 of file PrimClex.cc.

◆ PrimClex() [1/3]

CASM::PrimClex::PrimClex ( const fs::path &  _root)
explicit

Construct PrimClex from existing CASM project directory

  • read PrimClex and directory structure to generate all its Supercells and Configurations, etc.

Definition at line 111 of file PrimClex.cc.

◆ PrimClex() [2/3]

CASM::PrimClex::PrimClex ( const PrimClex )
delete

◆ PrimClex() [3/3]

CASM::PrimClex::PrimClex ( ProjectSettings const &  _project_settings,
std::shared_ptr< PrimType const >  _shared_prim 
)
explicit

Initial construction of a PrimClex, from ProjectSettings and shared prim.

Initial construction of a PrimClex, from a primitive Structure.

Definition at line 98 of file PrimClex.cc.

◆ refresh()

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.

Parameters
read_settingsRead project_settings.json and plugins
read_compositionRead composition_axes.json
read_chem_refRead chemical_reference.json
read_configsRead SCEL and config_list.json
clear_clexClear stored orbitrees, clexulators, and eci
  • This does not check if what you request will cause problems.
  • ToDo: refactor into separate functions

Definition at line 156 of file PrimClex.cc.

◆ settings() [1/2]

ProjectSettings & CASM::PrimClex::settings ( )

Definition at line 224 of file PrimClex.cc.

◆ settings() [2/2]

const ProjectSettings & CASM::PrimClex::settings ( ) const

Definition at line 226 of file PrimClex.cc.

◆ shared_nlist()

std::shared_ptr< PrimNeighborList > const & CASM::PrimClex::shared_nlist ( ) const

Access to the primitive neighbor list as a shared resource.

Definition at line 270 of file PrimClex.cc.

◆ shared_prim()

std::shared_ptr< PrimClex::PrimType const > const & CASM::PrimClex::shared_prim ( ) const

Access to the primitive Structure as a shared resource.

Definition at line 264 of file PrimClex.cc.

◆ vacancy_allowed()

bool CASM::PrimClex::vacancy_allowed ( ) const

returns true if vacancy are an allowed species

Definition at line 286 of file PrimClex.cc.

◆ vacancy_index()

Index CASM::PrimClex::vacancy_index ( ) const

returns the index of vacancies in composition vectors

Definition at line 289 of file PrimClex.cc.

◆ write_basis_set_data()

void CASM::write_basis_set_data ( std::shared_ptr< Structure const >  shared_prim,
ProjectSettings const &  settings,
std::string const &  basis_set_name,
ClexBasisSpecs const &  basis_set_specs,
PrimNeighborList prim_neighbor_list 
)

Write clust.json, basis.json, and clexulator source code, by constructing orbits and ClexBasis

Notes:

Write clexulator, clust.json, basis.json by constructing orbits and ClexBasis

Definition at line 504 of file PrimClex.cc.

◆ ~PrimClex()

CASM::PrimClex::~PrimClex ( )

Necessary for "pointer to implementation".

Definition at line 116 of file PrimClex.cc.

Variable Documentation

◆ m_data

std::unique_ptr<PrimClexData> CASM::PrimClex::m_data
private

Definition at line 175 of file PrimClex.hh.