exatomic.algorithms.delocalization module

Delocalization

Miscellaneous functions for computing the curvature in the energy of a system as a function of the electron number. These functions require results from 3 different quantum chemical calculations on an (N-1), N, and (N+1) electron system.

exatomic.algorithms.delocalization.plot_energy(curv, color=None, title='', figsize=(21, 5), nylabel=3, nxlabel=5, fontsize=24)[source]

Accepts the output of compute_curvature or combine_curvature and returns a figure with appropriate styling.

exatomic.algorithms.delocalization.combine_curvature(curvs, order=None)[source]

Given a list of the results of compute_curvature, return a single dataframe containing all of the E(N) results.

exatomic.algorithms.delocalization.compute_curvature(*args, **kwargs)[source]

Computes the curvature of the energy of a system as a function of the number of electrons in the system E(N).

Parameters:
  • args (exatomic.core.universe.Universe) – unis in ascending electron order

  • neut (int) – index of args corresponding to the zero energy system

  • extras (bool) – if True, attach the raw data to df before returning

Returns:

df (pd.DataFrame) – The energy as a function of N

exatomic.algorithms.delocalization.functional_results(adir, code='gaussian', ip=False, ea=False, labels=None, timer=True)[source]
exatomic.algorithms.delocalization.tuning_results(adir, code='gaussian', ip=False, ea=False, deep=False, debug=0)[source]

Given a directory containing output files with systematic file names, return a dataframe containing summary information about the calculations.

Parameters:
  • adir (str) – path to the directory containing outputs

  • ip (bool) – if true only consider (N-1, N) systems

  • ea (bool) – if true only consider (N, N+1) systems

  • deep (bool) – if true must have (N-2, N-1, N, N+1, N+2) systems

  • ext (str) – output file extension

Returns:

data (pd.DataFrame) – summarized results