momentGW.pbc.uhf.base

Base class for moment-constrained GW solvers with periodic boundary conditions and unrestricted references.

Module Contents

class momentGW.pbc.uhf.base.BaseKUGW(mf, **kwargs)

Bases: momentGW.pbc.base.BaseKGW, momentGW.uhf.base.BaseUGW

Base class for moment-constrained GW solvers for periodic systems with unrestricted references.

Parameters:
  • mf (pyscf.pbc.scf.KSCF) – PySCF periodic mean-field class.

  • diagonal_se (bool, optional) – If True, use a diagonal approximation in the self-energy. Default value is False.

  • polarizability (str, optional) – Type of polarizability to use, can be one of (“drpa”, “drpa-exact”, “dtda”, “thc-dtda”). Default value is `”drpa”.

  • npoints (int, optional) – Number of numerical integration points. Default value is 48.

  • optimise_chempot (bool, optional) – If True, optimise the chemical potential by shifting the position of the poles in the self-energy relative to those in the Green’s function. Default value is False.

  • fock_loop (bool, optional) – If True, self-consistently renormalise the density matrix according to the updated Green’s function. Default value is False.

  • fock_opts (dict, optional) – Dictionary of options passed to the Fock loop. For more details see momentGW.pbc.fock.

  • compression (str, optional) – Blocks of the ERIs to use as a metric for compression. Can be one or more of (“oo”, “ov”, “vv”, “ia”) which can be passed as a comma-separated string. “oo”, “ov” and “vv” refer to compression on the initial ERIs, whereas “ia” refers to compression on the ERIs entering RPA, which may change under a self-consistent scheme. Default value is “ia”.

  • compression_tol (float, optional) – Tolerance for the compression. Default value is 1e-10.

  • thc_opts (dict, optional) – Dictionary of options to be used for THC calculations. Current implementation requires a filepath to import the THC integrals.

  • fc (bool, optional) – If True, apply finite size corrections. Default value is False.

property cell

Get the unit cell.

property mol

Alias for self.cell.

property nmo

Get the number of molecular orbitals.

property kpts

Get the k-points.

property nkpts

Get the number of k-points.

abstract property name

Abstract property for the solver name.

property qp_energy

Get the quasiparticle energies.

Notes

For most GW methods, this simply consists of the poles of the self.gf that best overlap with the MOs, in order. In some methods such as qsGW, these two quantities are not the same.

property has_fock_loop

Get a boolean indicating whether the solver requires a Fock loop.

Notes

For most GW methods, this is simply self.fock_loop. In some methods such as qsGW, a Fock loop is required with or without self.fock_loop for the quasiparticle self-consistency, with this property acting as a hook to indicate this.

property with_df

Get the density fitting object.

property nao

Get the number of atomic orbitals.

property nocc

Get the number of occupied molecular orbitals.

property active

Get the mask to remove frozen orbitals.

property mo_energy

Get the molecular orbital energies.

property mo_energy_with_frozen

Get the molecular orbital energies with frozen orbitals.

property mo_coeff

Get the molecular orbital coefficients.

property mo_coeff_with_frozen

Get the molecular orbital coefficients with frozen orbitals.

property mo_occ

Get the molecular orbital occupation numbers.

property mo_occ_with_frozen

Get the molecular orbital occupation numbers with frozen orbitals.

abstract build_se_static(*args, **kwargs)

Abstract method for building the static self-energy.

abstract build_se_moments(*args, **kwargs)

Abstract method for building the self-energy moments.

abstract ao2mo(transform=True)

Abstract method for getting the integrals object.

abstract solve_dyson(*args, **kwargs)

Abstract method for solving the Dyson equation.

kernel(nmom_max, moments=None, integrals=None)

Driver for the method.

Parameters:
  • nmom_max (int) – Maximum moment number to calculate.

  • moments (tuple of numpy.ndarray, optional) – Tuple of (hole, particle) moments, if passed then they will be used instead of calculating them. Default value is None.

  • integrals (BaseIntegrals, optional) – Integrals object. If None, generate from scratch. Default value is None.

Returns:

  • converged (bool) – Whether the solver converged. For single-shot calculations, this is always True.

  • gf (dyson.Lehmann) – Green’s function object.

  • se (dyson.Lehmann) – Self-energy object.

  • qp_energy (numpy.ndarray) – Quasiparticle energies. For most GW methods, this is None.

run(*args, **kwargs)

Alias for kernel, instead returning self.

Parameters:
  • *args (tuple) – Positional arguments to pass to kernel.

  • **kwargs (dict) – Keyword arguments to pass to kernel.

Returns:

self – The solver object.

Return type:

BaseGW