qrunch.chemistry.builders.input

Functions for constructing molecular configurations and reaction path problem inputs.

build_molecular_configuration(molecule: Path | Molecule | Sequence[tuple[str | int, float, float, float]], basis_set: str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | BasisSet | dict[Atom, BasisSet] = BasisSet.STO3G, charge: int = 0, spin_difference: int = 0, embedded_atoms: Sequence[int] | None = None, solvent: Solvent | None = None, aux_basis_set: str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | BasisSet | dict[Atom, BasisSet] | None = None, *, units: Literal['angstrom', 'bohr', 'nanometer', 'meter'] = 'angstrom') MolecularConfiguration

Create a MolecularConfiguration directly.

Parameters:
  • molecule (Path | Molecule | Sequence[tuple[str | int, float, float, float]]) – Definition of the molecule to use. You can specify either a Path to an XYZ file, a Molecule object (See qrunch.chemistry.molecule.molecule), or a Sequence of atom data written as a tuple of (element, x-coordinates, y-coordinates, z-coordinates). The atom can be specified either by its element symbol (str) or atomic number (int).

  • basis_set (str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | ~qrunch.chemistry.molecule.basis_sets.BasisSet | dict[~qrunch.chemistry.molecule.atom.Atom, ~qrunch.chemistry.molecule.basis_sets.BasisSet]) – Basis set to use (default: sto3g). Can also be a dictionary mapping specific atom types to basis sets. The dictionary keys should be Atom objects. (See qrunch.chemistry.molecule.atom) and the values should be BasisSet objects (See qrunch.chemistry.molecule.basis_sets)

  • charge (int) – Molecular charge in units of e (default: 0).

  • spin_difference (int) – Difference between the number of spin up and spin down electrons (default: 0).

  • embedded_atoms (Sequence[int] | None) – Sequence of embedded atom indices (default: None). The indices refer to the order of atoms in the provided molecule.

  • solvent (Solvent | None) – Solvent to use. See qrunch.chemistry.molecule.solvent (default: None).

  • aux_basis_set (str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | ~qrunch.chemistry.molecule.basis_sets.BasisSet | dict[~qrunch.chemistry.molecule.atom.Atom, ~qrunch.chemistry.molecule.basis_sets.BasisSet] | None) – Auxiliary basis set (default: None). Can also be a dictionary mapping specific atoms to basis sets.

  • units (Literal['angstrom', 'bohr', 'nanometer', 'meter']) – Units for the coordinates, such as “angstrom” or “bohr”.

Return type:

MolecularConfiguration

build_reaction_configuration(reaction: Path | Sequence[Molecule] | Sequence[Sequence[tuple[str | int, float, float, float]]], basis_set: str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | BasisSet | dict[Atom, BasisSet] = BasisSet.STO3G, charge: int = 0, spin_difference: int = 0, embedded_atoms: Sequence[int] | None = None, solvent: Solvent | Sequence[Solvent] | None = None, aux_basis_set: str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | BasisSet | dict[Atom, BasisSet] | None = None, *, units: Literal['angstrom', 'bohr', 'nanometer', 'meter'] = 'angstrom') ReactionConfiguration

Create a MolecularConfiguration directly.

Parameters:
  • reaction (Path | Sequence[Molecule] | Sequence[Sequence[tuple[str | int, float, float, float]]]) – Definition of the reaction to use. You can specify either a Path to an XYZ file; a Sequence of Molecule objects; or a Sequence of a Sequence of atom data written as a tuple of (element, x, y, z), where each inner Sequence defines a single Molecule and the outer Sequence defines the reaction path. The atom can be specified either by its element symbol (str) or atomic number (int).

  • basis_set (str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | ~qrunch.chemistry.molecule.basis_sets.BasisSet | dict[~qrunch.chemistry.molecule.atom.Atom, ~qrunch.chemistry.molecule.basis_sets.BasisSet]) – Basis set to use (default: sto3g). Can also be a dictionary mapping specific atoms to basis sets.

  • charge (int) – Molecular charge in units of e (default: 0).

  • spin_difference (int) – Difference between the number of spin up and spin down electrons (default: 0).

  • embedded_atoms (Sequence[int] | None) – Sequence of embedded atom indices (default: None). The indices refer to the order of atoms in the provided molecule.

  • solvent (Solvent | Sequence[Solvent] | None) – Solvent to use (default: None).

  • aux_basis_set (str | Literal['sto-3g', '3-21g', '6-31g', '6-31g*', 'def2-svp', 'def2-tzvp', 'def2-tzvpp', 'cc-pvdz', 'cc-pvtz', 'cc-pvqz', 'aug-cc-pvdz', 'aug-cc-pvtz', 'aug-cc-pvqz', 'pc-0', 'pc-1', 'pc-2', 'pc-seg-0', 'pc-seg-1', 'pc-seg-2', 'weigend'] | ~qrunch.chemistry.molecule.basis_sets.BasisSet | dict[~qrunch.chemistry.molecule.atom.Atom, ~qrunch.chemistry.molecule.basis_sets.BasisSet] | None) – Auxiliary basis set (default: None). Can also be a dictionary mapping specific atoms to basis sets.

  • units (Literal['angstrom', 'bohr', 'nanometer', 'meter']) – Units for the coordinates.

Return type:

ReactionConfiguration