Molecule
Container of gauxc.Atom objects; behaves like a Python list.
Constructor
Molecule(atoms=[])
Parameters
atoms (list[Atom], optional) — initial list of atoms.
Methods
maxZ()— return the largest atomic number in the molecule.
List interface
len(mol),mol[i],mol.append(atom)and iteration are supported.
Example
atoms = [
gxc.Atom(6, 0.0, 0.0, 0.0),
gxc.Atom(1, 1.0, 1.0, 0.0),
gxc.Atom(1, -1.0, 1.0, 0.0),
]
mol = gxc.Molecule(atoms)
print(f"Number of atoms: {len(mol)}")
print(f"Heaviest element: Z = {mol.maxZ()}")