3.13.1. horton.scripts.atomdb – Code used by horton-atomdb.py

class horton.scripts.atomdb.Template(*args, **kwargs)

Bases: string.Template

A template with modifications to support inclusion of other files.

__init__(*args, **kwargs)
get_subs(number, pop, mult)
safe_substitute(*args, **kws)
substitute(*args, **kws)
delimiter = ‘$’
idpattern = ‘[_a-z0-9.:-]+’
pattern = <_sre.SRE_Pattern object>
class horton.scripts.atomdb.EnergyTable

Bases: object

__init__()
add(number, pop, energy)
log()
horton.scripts.atomdb.iter_mults(nel, hund)

Iterate over atomic spin multiplicites for the given number of electrons

Arguments:

nel
The number of electrons (1-56)
hund
When set to True, only one spin multiplicity is returned. Otherwise several reasonable spin multiplicities are given.
horton.scripts.atomdb.iter_states(elements, max_kation, max_anion, hund)

Iterate over all requested atomic states

Arguments:

elements
A string that is suitable for iter_elements
template
An instance of the atomdb.Template class
max_kation
The limit for the most positive kation
max_anion
The limit for the most negative anion
hund
Flag to adhere to hund’s rule for the spin multiplicities.