data.oc.core.ion#

Classes#

Ion

Initializes an ion object in one of 2 ways:

Module Contents#

class data.oc.core.ion.Ion(ion_atoms: ase.Atoms = None, ion_id_from_db: int | None = None, ion_db_path: str = ION_PKL_PATH)#

Initializes an ion object in one of 2 ways: - Directly pass in an ase.Atoms object. - Pass in index of ion to select from ion database.

Parameters:
  • ion_atoms (ase.Atoms) – ion structure.

  • ion_id_from_db (int) – Index of ion to select.

  • ion_db_path (str) – Path to ion database.

ion_id_from_db#
ion_db_path#
__len__()#
__str__()#
_load_ion(ion: dict) None#

Saves the fields from an ion stored in a database. Fields added after the first revision are conditionally added for backwards compatibility with older database files.

get_ion_concentration(volume)#

Compute the ion concentration units of M, given a volume in units of Angstrom^3.