tblite
Light-weight tight-binding framework
Loading...
Searching...
No Matches
tblite_scf_potential Module Reference

Implementation of the density dependent potential and its contribution to the effective Hamiltonian. More...

Data Types

type  potential_type
 Container for density dependent potential-shifts. More...

Functions/Subroutines

subroutine, public new_potential (self, mol, bas, nspin, grad)
 Create a new potential object.
subroutine, public reduce_potential (error, pot, comm)
 Assemble the SCF potential before expanding atom/shell shifts into vao.
subroutine, public mpi_add_pot_to_h1 (error, bas, ints, pot, h1, comm)
 Expand the replicated potential into disjoint Hamiltonian columns. Local storage needs a distributed transpose of one-centre contributions; the compatibility path gathers complete columns for a replicated solver.
subroutine, public add_pot_to_h1 (bas, ints, pot, h1, columns)
 Add the collected potential shifts to complete or locally stored columns. Local storage returns one-centre contributions; the frontend adds their distributed transpose. Complete storage includes both centres directly.

Detailed Description

Implementation of the density dependent potential and its contribution to the effective Hamiltonian.

Function/Subroutine Documentation

◆ add_pot_to_h1()

subroutine, public tblite_scf_potential::add_pot_to_h1 ( type(basis_type), intent(in) bas,
type(integral_type), intent(in) ints,
type(potential_type), intent(inout) pot,
real(wp), dimension(:, :, :), intent(out) h1,
integer, dimension(2), intent(in), optional columns )

Add the collected potential shifts to complete or locally stored columns. Local storage returns one-centre contributions; the frontend adds their distributed transpose. Complete storage includes both centres directly.

Parameters
[in]basBasis set information
[in]intsIntegrals stored as complete matrices or complete local columns
[in,out]potPotential shifts, expanded to shell and orbital resolution
[out]h1Hamiltonian columns to overwrite; local storage returns one-centre terms
[in]columnsOptional range to compute within replicated storage

◆ mpi_add_pot_to_h1()

subroutine, public tblite_scf_potential::mpi_add_pot_to_h1 ( type(error_type), intent(inout), allocatable error,
type(basis_type), intent(in) bas,
type(integral_type), intent(in) ints,
type(potential_type), intent(inout) pot,
real(wp), dimension(:, :, :), intent(inout), contiguous h1,
integer, intent(in), optional comm )

Expand the replicated potential into disjoint Hamiltonian columns. Local storage needs a distributed transpose of one-centre contributions; the compatibility path gathers complete columns for a replicated solver.

Parameters
[in,out]errorError handling
[in]basBasis set information
[in]intsIntegrals stored as complete matrices or complete local columns
[in,out]potReplicated potential shifts, expanded to shell and orbital resolution
[in,out]h1Effective Hamiltonian to overwrite, using the same column layout as ints
[in]commCommunicator for distributed assembly, absent selects serial execution

◆ new_potential()

subroutine, public tblite_scf_potential::new_potential ( type(potential_type), intent(out) self,
type(structure_type), intent(in) mol,
type(basis_type), intent(in) bas,
integer, intent(in) nspin,
logical, intent(in), optional grad )

Create a new potential object.

Parameters
[out]selfInstance of the density dependent potential
[in]molMolecular structure data
[in]basDescription of the basis set
[in]nspinNumber of spin channels
[in]gradFlag to indicate if potential gradients are requested

◆ reduce_potential()

subroutine, public tblite_scf_potential::reduce_potential ( type(error_type), intent(inout), allocatable error,
type(potential_type), intent(inout) pot,
integer, intent(in), optional comm )

Assemble the SCF potential before expanding atom/shell shifts into vao.

Parameters
[in,out]errorError handling; a pending error skips the reduction
[in,out]potPartial atomic and shell potentials, replaced by their sum over all ranks
[in]commCommunicator to reduce over, absent leaves the potential unchanged