sf.apps.qchem.vibronic.energies

energies(samples, w, wp)[source]

Computes the energy \(E = \sum_{k=1}^{N}m_k\omega'_k - \sum_{k=N+1}^{2N}n_k\omega_k\) of each GBS sample in units of \(\text{cm}^{-1}\).

Example usage:

>>> samples = [[1, 1, 0, 0, 0, 0], [1, 2, 0, 0, 1, 1]]
>>> w  = np.array([300.0, 200.0, 100.0])
>>> wp = np.array([700.0, 600.0, 500.0])
>>> energies(samples, w, wp)
[1300.0, 1600.0]
Parameters
  • samples (list[list[int]] or list[int]) – a list of samples from GBS, or alternatively a single sample

  • w (array) – normal mode frequencies of initial state in units of \(\text{cm}^{-1}\)

  • wp (array) – normal mode frequencies of final state in units of \(\text{cm}^{-1}\)

Returns

list of GBS sample energies in units of \(\text{cm}^{-1}\), or a single sample energy if only one sample is input

Return type

list[float] or float