horton_part.core.proatomdb module
Pro-atom databases
- class ProAtomDB(records)
Bases:
object
- __init__(records)
- Parameters:
records (sequence of ProAtomRecord instances) –
- A sequence of ProAtomRecord instances. If two or more records have
the same number and charge, only the lowest in energy is retained.
Based on the records present it is determined which records are safe to use, i.e. apparently not bound by the basis set.
- compact(nel_lost)
Make the pro-atoms more compact
Argument:
- nel_lost
This parameter controls the part of the tail that gets neglected. This is the (maximym) number of electrons in the part that gets discarded.
Note that only ‘safe’ atoms are considered to determine the cutoff radius.
- get_charges(number, safe=False)
- get_numbers()
Return the element numbers present in the database
- get_record(number, charge)
- get_rgrid(number)
- get_rho(number, parameters=0, combine='linear', do_deriv=False)
Construct a proatom density on a grid.
Arguments:
- number
The element
Optional arguments:
- parameters
This argument may take two forms:
Integer: the charge of the pro-atom
Dictionary: a linear or geometric combination of different charged pro-atoms. The keys are the charges and the values are the coefficients.
- combine
In case parameters is an array, this determines the type of combination: ‘linear’ or ‘geometric’.
- do_deriv
When set to True, the derivative of rho is also returned. In case the derivative is not available, the second return value is None.
- get_spline(number, parameters=0, combine='linear')
Construct a proatom spline.
Arguments: See
get_rho
method.
- normalize()
- property size
Number of proatoms in the database.
- class ProAtomRecord(number, charge, energy, rgrid, rho, deriv=None, pseudo_number=None, ipot_energy=None)
Bases:
object
A single proatomic density record
- __init__(number, charge, energy, rgrid, rho, deriv=None, pseudo_number=None, ipot_energy=None)
- Parameters:
number (int) – The atomic number of the proatom.
charge (int) – The net charge of the proatom.
energy (float) – The total energy of the proatom.
rgrid (instance RadialGrid) – The radial grid on which the density (and optional radial density derivatives) are tabulated.
rho (np.ndarray) – The electron density on the grid.
deriv (np.ndarray) – The radial derivative of the electron density.
pseudo_number (int, default=None) – The effective core charge. If None, it is set to number.
ipot_energy (float, default=None) – The ionization potential.
- property charge
The atomic charge.
- chop(npoint)
Reduce the proatom to the given number of radial grid points.
- compute_radii(populations)
Compute approximate radii and grid points at which the atom contains the given populations
Arguments:
- populations
A list of populations for which the corresponding radii have to be computed.
- property deriv
The radial derivative of the density on a radial grid.
- property energy
The total electronic energy.
- get_moment(order)
Return the integral of rho*r**order
- property ipot_energy
The ionization potential.
- property number
The atomic number.
- property population
The total number of electrons.
- property pseudo_number
The pseudo atomic number (effective core charge)
- property pseudo_population
The total effective number of electrons.
- property rgrid
The radial grid.
- property rho
The density on a radial grid.
- property safe
When safe is True, this pro atom is safe to use, i.e. not know to be basis-set bound
- update_safe(other)
Update the safe attribute based on a comparison with other records.
Arguments:
- other
Another instance of ProAtomRecord