GauChkParser package

Submodules

GauChkParser.ChkReader module

class GauChkParser.ChkReader.ChkReader(fname: str)

Bases: object

A class for reading .chk file generaged by Gaussian 09/16 x64 version

property params: ChkParams

Return ChkParams dataclass

property ilsw: List[int]

Return ILSW array (size=100)

property rlsw: List[float]

Return RLSW array (size=ilsw[57])

write_gjf(fname: str)

Write a gjf file based on the information of .chk

Parameters:

fname – the output gjf file name

write_fchk(fname: str)

Write a formatted checkpoint file based on the partial information of .chk

Note

The generated .fchk file is not as complete as one created using formchk. However, it contains enough information to be used by [Multiwfn](http://sobereva.com/multiwfn).

Parameters:

fname – the output fchk file name

GauChkParser.Constants module

GauChkParser.Constants.Bohr2Ang = 0.529177249

Bohr to Angstrom constant in 1986, the value used in GaussView 6.0

https://doi.org/10.1103/RevModPhys.59.1121

GauChkParser.Constants.Bohr2Ang1998 = 0.5291772083

Borh to Angstrom constant in 1998, the value used in Gaussian 03

https://physics.nist.gov/cuu/pdf/all_1998.pdf

GauChkParser.Constants.Bohr2Ang2006 = 0.52917720859

Borh to Angstrom constant in 2006, the value used in Gaussian 09

https://physics.nist.gov/cuu/pdf/all_2006.pdf

GauChkParser.Constants.Bohr2Ang2010 = 0.52917721092

Borh to Angstrom constant in 2010, the value used in Gaussian 16

https://physics.nist.gov/cuu/Constants/Preprints/lsa2010.pdf

GauChkParser.Types module

class GauChkParser.Types.GenDef(value)

Bases: IntEnum

Gen Array index in enum type, such as use genarr[GenDef.VirialRatio]

VirialRatio = 0

Virial ratio.

ElecX = 1

X Component of applied electric field

ElecY = 2

Y Component of applied electric field

ElecZ = 3

Z Component of applied electric field

Scf2E = 4

2e SCF energy

ScrfGf = 5

SCRF g-factor

ScrfA0 = 6

SCRF a0

ThermalEne = 7

Thermal Energy

ECiCcQciBd = 8

E(CI/CC/QCI/BD)

Eccd = 9

E(CCD+ST4(CCD)/QCISD(T)/BD(T)/CI+Davidson)

Evar1 = 10

E(VAR1)

ZeroPointEne = 11

Zero-point energy

MultiStepEne = 12

Multi-step (G1, G2, etc.) energy

NimagFreq = 13

Number of imaginary frequencies.

Dpuhf = 14

D(PUHF)

Epuhf = 15

EPUHF

Ecbs2 = 16

ECBS2

Ecbsi = 17

ECBSI

Epmp20 = 18

EPMP2-0

Epmp30 = 19

EPMP3-0

Rmsdopt = 20

ROOT-MEAN-SQUARED FORCE OF OPTIMIZED PARAMETERS

EcisMP2 = 21

E(CIS-MP2)

RmsError = 22

RMS ERROR IN DENSITY MATRIX

S2 = 23

S**2 after annihilation of first contaminant.

CisEne = 24

CIS energy

Ump4d = 25

UMP4D (=UMP4DQ - E4(R+Q))

RefBdEne = 26

Reference energy for BD

MP5 = 27

MP5

S4SD = 28

S4SD, computed in ANNIL in L502, used by PSCF spin projection routines

ForzenEne = 29

Frozen-core part of total energy

Tau = 30

‘TAU’ FROM SCFDM

ScfEne = 31

SCF ENERGY.

UMP2Ene = 32

UMP2 ENERGY.

UMP3Ene = 33

UMP3 ENERGY.

UMP4Ene = 34

UMP4(SDTQ) ENERGY.

CbsOIii = 35

CBS OIii

TotEneRF = 36

Total energy with RF from L116

MP4EDQEne = 37

MP4DQ ENERGY

MP4SDQEne = 38

MP4SDQ ENERGY

L116 = 39

Set in L116 for some reason

NucRepEne = 40

NUCLEAR REPULSION ENERGY

LenRefDet = 41

T (LENGTH OF CORRECTION OF REFERENCE DETERMINANT)

UpdateEne = 42

UPDATED ENERGY FOR OPTIMIZATIONS

S2Scf = 43

<S**2> OF SCF WAVE FUNCTION

S2FirstOrder = 44

<S**2> CORRECTED TO FIRST ORDER (AFTER DOUBAR)

S2Doubles = 45

<S**2> CORRECTED FOR DOUBLES (NOT IMPLEMENTED)

A0 = 46

A0

Dummy = 47

Unused in G16

TempTher = 48

Temperature for thermochemistry

PressTher = 49

Pressure for thermochemistry

ScalFactorFreqTher = 50

Scale factor for frequencies in thermochemistry

NucRep = 51

Nuclear repulsion contribution from inactive atom pairs

SingE2ToRomp2 = 52

Singles contribution to E2 in ROMP2

E2 = 53

E(2) with current orbitals for extrapolation

NucRF = 54

Nuclear term in the reaction field energy

ElecRF = 55

Electronic term in the reaction field energy

CurProFreq = 56

Curvature from projected frequency jobs

ReacCoord = 57

Reaction coordinate for single-points along IRCs

FlagExt = 58

Flag for status from external programs; see RunExt

ScfEneFirstIter = 59

SCF energy at first iteration

JobStat = 60

Job status, -1 = in progress, 0 = undefined/old chk file, 1 = finished successfully, 2 = step in mult i-step job completed successfully, 3 = job terminated with error

HighestOrder = 61

Highest order of nuclear coordinate derivatives available

NIterMostRecSCF = 62

Number of iterations in most recent SCF

NucRepEneNoExf = 63

Nuclear repulsion energy without external field contribution

class GauChkParser.Types.DensDef(value)

Bases: IntEnum

Density matrix definition in enum type, such as use totdens[DensDef.DensSCF], return empty list if not exists

DensSCF = 0

SCF Density

DensPSI = 1

Psi(1) Density

DensMP2 = 2

MP2 Density

DensMP3 = 3

MP3 Density

DensMP4 = 4

MP4 Density

DensCIRho = 5

CI Rho(1) Density

DensCI = 6

CI Density

DensCC = 7

CC Density

Dens2ndOrder = 8

2nd Order Density

class GauChkParser.Types.Mol(natoms: int = 0, totchg: int = 0, ne: int = 0, nae: int = 0, nbe: int = 0, nbasis: int = 0, nbsuse: int = 0, ndim: int = 0, multiplicity: int = 0, maxbond: int = 0, nbond: ~typing.List[str] = <factory>, ibond: ~typing.List[str] = <factory>, rbond: ~typing.List[str] = <factory>, names: ~typing.List[str] = <factory>, atomicnums: ~typing.List[int] = <factory>, coords: ~numpy.ndarray = <factory>, gradient: ~typing.List[float] = <factory>, hessian: ~numpy.ndarray = <factory>, aoene: ~typing.List[float] = <factory>, boene: ~typing.List[float] = <factory>, amocoeff: ~typing.List[float] = <factory>, bmocoeff: ~typing.List[float] = <factory>, orthbasis: ~typing.List[float] = <factory>, cell: ~numpy.ndarray = <factory>, primexp: ~typing.List[float] = <factory>, concoeff: ~typing.List[float] = <factory>, spconcoeff: ~typing.List[float] = <factory>, cshell: ~numpy.ndarray = <factory>, nucchg: ~typing.List[float] = <factory>, shelltypes: ~typing.List[int] = <factory>, shellnprim: ~typing.List[int] = <factory>, shell2map: ~typing.List[int] = <factory>, orblabels: ~typing.List[str] = <factory>, totdens: ~typing.List[~typing.List[float]] = <factory>, spindens: ~typing.List[~typing.List[float]] = <factory>)

Bases: object

A mol dataclass for storing molecule data

natoms

number of atoms

Type:

int

totchg

total charge

Type:

int

ne

number of electrons

Type:

int

nae

number of alpha electrons

Type:

int

nbe

number of beta electrons

Type:

int

nbasis

number of basis functions

Type:

int

nbsuse

number of independent functions

Type:

int

ndim

number of translation vectors (0-3 dim)

Type:

int

multiplicity

multiplicity

Type:

int

maxbond

The max connect bonds

Type:

int

nbond

The number of bonds for each atom, length= natoms

Type:

List[str]

ibond

The atom index(0 means no) for all bonds, length= maxbond*natoms

Type:

List[str]

rbond

The bond order for all bonds, length= maxbond*natoms

Type:

List[str]

names

atom element name

Type:

List[str]

coords

atomic coords (N*3), unit is Angstrom

Type:

numpy.ndarray

hessian

hessian matrix (3N*3N)

Type:

numpy.ndarray

gradient

cartesian gradient (N*3 list)

Type:

List[float]

aoene

alpha orbital energies

Type:

List[float]

boene

beta orbital energies

Type:

List[float]

amocoeff

alpha MO coefficients

Type:

List[float]

bmocoeff

beta MO coefficients

Type:

List[float]

orthbasis

orthogonal basis

Type:

List[float]

cell

cell size (3*3) of molecule, unit is Angstrom

Type:

numpy.ndarray

primexp

primitives exponents

Type:

List[float]

concoeff

contraction coefficients

Type:

List[float]

spconcoeff

P(S=P) Contraction coefficients

Type:

List[float]

cshell

Coordinates of each shell, unit is Angstrom

Type:

numpy.ndarray

nucchg

nuclear charges

Type:

List[float]

shelltypes

shell types

Type:

List[int]

shellnprim

number of primitives in each shell

Type:

List[int]

shell2map

shell to map

Type:

List[int]

orblabels

each atom orbital labels

Type:

List[str]

totdens

total density matrix, nine types see DensDef, such as Total SCF Density

Type:

List[List[float]]

spindens

spin density matrix, nine types see DensDef, such as Spin SCF Density

Type:

List[List[float]]

class GauChkParser.Types.ChkParams(mol: ~GauChkParser.Types.Mol = <factory>, route: str = None, gauver: str = None, title: str = None, jobtype: str = None, method: str = None, baset: str = None, viratio: float = 0, scfene: float = 0, totene: float = 0, info1_9: ~typing.List[int] = <factory>, genarr: ~typing.List[float] = <factory>)

Bases: object

A chk parameters dataclass

mol

The mol structure dataclass

Type:

GauChkParser.Types.Mol

route

The route string

Type:

str

gauver

The gaussian version description

Type:

str

title

The title section description

Type:

str

jobtype

job type, such as SP, Freq, etc.

Type:

str

method

method, such as RHF, MP4, etc.

Type:

str

baset

basis set, such as def2SVP, 6-31G, etc

Type:

str

viratio

virtual ratio

Type:

float

scfene

scf energy

Type:

float

totene

total energy

Type:

float

info1_9

The scalar data of Info1-9, size=9

Type:

List[int]

genarr

The scalar data of the calculation (Gen array), size=1000

Type:

List[float]

Module contents