Octopus
excited_states_oct_m Module Reference

Data Types

interface  dstates_elec_mpdotp
 
interface  dstates_elec_mpmatrixelement
 
type  excited_states_t
 
type  states_pair_t
 
interface  zstates_elec_mpdotp
 
interface  zstates_elec_mpmatrixelement
 

Functions/Subroutines

subroutine, public excited_states_init (excited_state, ground_state, filename, namespace)
 Fills in an excited_state structure, by reading a file called "filename". This file describes the "promotions" from occupied to unoccupied levels that change the initial Slater determinant structure specified in ground_state. These promotions are a set of electron-hole pairs. The structure of the file is thus four columns: More...
 
subroutine, public excited_states_kill (excited_state)
 Kills an excited_state structure. More...
 
subroutine, public excited_states_output (excited_state, dirname, namespace)
 
logical function pair_is_eq (pair1, pair2)
 
real(real64) function dstates_elec_mpdotp_x (namespace, mesh, excited_state, st, mat)
 Returns the dot product of two many-body states; the first one is an "excited_state". More...
 
subroutine, public dstates_elec_matrix_swap (mat, pair)
 The matrix mat should contain the dot products between two states. One of them (the one operating on the left) is an excited state. The pair_t pair indicates the substitution of one the occupied spin-orbitals by one unoccupied one (electron-hole excitation). This routine returns then the matrix that would correspond to the dot products between this excited state (on the left) and the same ground state (on the right) More...
 
real(real64) function dstates_elec_mpmatrixelement_g (namespace, mesh, st1, st2, opst2)
 Returns <st1 | O | st2>, where both st1 and st2 are Slater determinants represented by states_elec_t st1 and st2. O is a one-body operator. More...
 
real(real64) function dstates_elec_mpdotp_g (namespace, mesh, st1, st2, mat)
 Returns the dot product of two many-body states st1 and st2. More...
 
complex(real64) function zstates_elec_mpdotp_x (namespace, mesh, excited_state, st, mat)
 Returns the dot product of two many-body states; the first one is an "excited_state". More...
 
subroutine, public zstates_elec_matrix_swap (mat, pair)
 The matrix mat should contain the dot products between two states. One of them (the one operating on the left) is an excited state. The pair_t pair indicates the substitution of one the occupied spin-orbitals by one unoccupied one (electron-hole excitation). This routine returns then the matrix that would correspond to the dot products between this excited state (on the left) and the same ground state (on the right) More...
 
complex(real64) function zstates_elec_mpmatrixelement_g (namespace, mesh, st1, st2, opst2)
 Returns <st1 | O | st2>, where both st1 and st2 are Slater determinants represented by states_elec_t st1 and st2. O is a one-body operator. More...
 
complex(real64) function zstates_elec_mpdotp_g (namespace, mesh, st1, st2, mat)
 Returns the dot product of two many-body states st1 and st2. More...
 

Function/Subroutine Documentation

◆ excited_states_init()

subroutine, public excited_states_oct_m::excited_states_init ( type(excited_states_t), intent(inout)  excited_state,
type(states_elec_t), intent(in), target  ground_state,
character(len=*), intent(in)  filename,
type(namespace_t), intent(in)  namespace 
)

Fills in an excited_state structure, by reading a file called "filename". This file describes the "promotions" from occupied to unoccupied levels that change the initial Slater determinant structure specified in ground_state. These promotions are a set of electron-hole pairs. The structure of the file is thus four columns:

i a k weight

where i should be an occupied state, a an unoccupied one, and k the k-point (including spin) of the corresponding orbital. This pair is then associated with a creation-annihilation pair a^t_{a,k} a_{i,k}, so that the excited state will be a linear combination in the form:

|ExcitedState> = Sum [ weight(i,a,k) a^t_{a,k} a_{i,k} |GroundState> ]

where weight is the number in the fourth column. These weights should be normalized to one; otherwise the routine will normalize them, and write a warning.

This file structure is the one written by the casida run mode, in the files

in the directory "excitations".

Definition at line 203 of file excited_states.F90.

◆ excited_states_kill()

subroutine, public excited_states_oct_m::excited_states_kill ( type(excited_states_t), intent(inout)  excited_state)

Kills an excited_state structure.

Definition at line 398 of file excited_states.F90.

◆ excited_states_output()

subroutine, public excited_states_oct_m::excited_states_output ( type(excited_states_t), intent(in)  excited_state,
character(len=*), intent(in)  dirname,
type(namespace_t), intent(in)  namespace 
)

Definition at line 412 of file excited_states.F90.

◆ pair_is_eq()

logical function excited_states_oct_m::pair_is_eq ( type(states_pair_t), intent(in)  pair1,
type(states_pair_t), intent(in)  pair2 
)
private

Definition at line 433 of file excited_states.F90.

◆ dstates_elec_mpdotp_x()

real(real64) function excited_states_oct_m::dstates_elec_mpdotp_x ( type(namespace_t), intent(in)  namespace,
class(mesh_t), intent(in)  mesh,
type(excited_states_t), intent(in)  excited_state,
type(states_elec_t), intent(in)  st,
real(real64), dimension(:, :, :), intent(in), optional  mat 
)
private

Returns the dot product of two many-body states; the first one is an "excited_state".

WARNING!!!!: periodic systems are not considered in these expressions.

Definition at line 512 of file excited_states.F90.

◆ dstates_elec_matrix_swap()

subroutine, public excited_states_oct_m::dstates_elec_matrix_swap ( real(real64), dimension(:, :, :), intent(inout)  mat,
type(states_pair_t), intent(in)  pair 
)

The matrix mat should contain the dot products between two states. One of them (the one operating on the left) is an excited state. The pair_t pair indicates the substitution of one the occupied spin-orbitals by one unoccupied one (electron-hole excitation). This routine returns then the matrix that would correspond to the dot products between this excited state (on the left) and the same ground state (on the right)

Definition at line 556 of file excited_states.F90.

◆ dstates_elec_mpmatrixelement_g()

real(real64) function excited_states_oct_m::dstates_elec_mpmatrixelement_g ( type(namespace_t), intent(in)  namespace,
class(mesh_t), intent(in)  mesh,
type(states_elec_t), intent(in)  st1,
type(states_elec_t), intent(in)  st2,
type(states_elec_t), intent(in)  opst2 
)
private

Returns <st1 | O | st2>, where both st1 and st2 are Slater determinants represented by states_elec_t st1 and st2. O is a one-body operator.

The auxiliary Slater determinant opst2 is formed by the orbitals that result of applying operator O on each of the spin-orbitals of st2.

The routine directly applies Lowdin`s formula [P.-O. Lowdin, Phys. Rev. 97, 1474; Eq. 49].

Definition at line 592 of file excited_states.F90.

◆ dstates_elec_mpdotp_g()

real(real64) function excited_states_oct_m::dstates_elec_mpdotp_g ( type(namespace_t), intent(in)  namespace,
class(mesh_t), intent(in)  mesh,
type(states_elec_t), intent(in)  st1,
type(states_elec_t), intent(in)  st2,
real(real64), dimension(:, :, :), intent(in), optional  mat 
)
private

Returns the dot product of two many-body states st1 and st2.

Warning
: it does not permit fractional occupation numbers.

Definition at line 759 of file excited_states.F90.

◆ zstates_elec_mpdotp_x()

complex(real64) function excited_states_oct_m::zstates_elec_mpdotp_x ( type(namespace_t), intent(in)  namespace,
class(mesh_t), intent(in)  mesh,
type(excited_states_t), intent(in)  excited_state,
type(states_elec_t), intent(in)  st,
complex(real64), dimension(:, :, :), intent(in), optional  mat 
)
private

Returns the dot product of two many-body states; the first one is an "excited_state".

WARNING!!!!: periodic systems are not considered in these expressions.

Definition at line 973 of file excited_states.F90.

◆ zstates_elec_matrix_swap()

subroutine, public excited_states_oct_m::zstates_elec_matrix_swap ( complex(real64), dimension(:, :, :), intent(inout)  mat,
type(states_pair_t), intent(in)  pair 
)

The matrix mat should contain the dot products between two states. One of them (the one operating on the left) is an excited state. The pair_t pair indicates the substitution of one the occupied spin-orbitals by one unoccupied one (electron-hole excitation). This routine returns then the matrix that would correspond to the dot products between this excited state (on the left) and the same ground state (on the right)

Definition at line 1017 of file excited_states.F90.

◆ zstates_elec_mpmatrixelement_g()

complex(real64) function excited_states_oct_m::zstates_elec_mpmatrixelement_g ( type(namespace_t), intent(in)  namespace,
class(mesh_t), intent(in)  mesh,
type(states_elec_t), intent(in)  st1,
type(states_elec_t), intent(in)  st2,
type(states_elec_t), intent(in)  opst2 
)
private

Returns <st1 | O | st2>, where both st1 and st2 are Slater determinants represented by states_elec_t st1 and st2. O is a one-body operator.

The auxiliary Slater determinant opst2 is formed by the orbitals that result of applying operator O on each of the spin-orbitals of st2.

The routine directly applies Lowdin`s formula [P.-O. Lowdin, Phys. Rev. 97, 1474; Eq. 49].

Definition at line 1053 of file excited_states.F90.

◆ zstates_elec_mpdotp_g()

complex(real64) function excited_states_oct_m::zstates_elec_mpdotp_g ( type(namespace_t), intent(in)  namespace,
class(mesh_t), intent(in)  mesh,
type(states_elec_t), intent(in)  st1,
type(states_elec_t), intent(in)  st2,
complex(real64), dimension(:, :, :), intent(in), optional  mat 
)
private

Returns the dot product of two many-body states st1 and st2.

Warning
: it does not permit fractional occupation numbers.

Definition at line 1220 of file excited_states.F90.