Octopus
perturbation_ionic_oct_m Module Reference

Data Types

interface  perturbation_ionic_t
 

Functions/Subroutines

class(perturbation_ionic_t) function, pointer perturbation_ionic_constructor (namespace, ions)
 The factory routine (or constructor) allocates a pointer of the corresponding type and then calls the init routine which is a type-bound procedure of the corresponding type. With this design, also derived classes can use the init routine of the parent class. More...
 
subroutine perturbation_ionic_init (this, namespace, ions)
 
subroutine perturbation_ionic_copy (this, source)
 
subroutine perturbation_ionic_finalize (this)
 
subroutine perturbation_ionic_info (this)
 
subroutine perturbation_ionic_setup_dir (this, dir, dir2)
 
subroutine perturbation_ionic_setup_atom (this, iatom, iatom2)
 
subroutine perturbation_ionic_setup_mixed_dir (this, iatom, idir, val, jatom, jdir, valuej)
 
subroutine dperturbation_ionic_apply (this, namespace, space, gr, hm, ik, f_in, f_out, set_bc)
 Returns f_out = H' f_in, where H' is perturbation Hamiltonian Note that e^ikr phase is applied to f_in, then is removed afterward. More...
 
subroutine dionic_perturbation (gr, namespace, ions, hm, ik, f_in, f_out, iatom, idir)
 
subroutine dperturbation_ionic_apply_order_2 (this, namespace, space, gr, hm, ik, f_in, f_out)
 
subroutine dionic_perturbation_order_2 (gr, namespace, ions, hm, ik, f_in, f_out, iatom, idir, jdir)
 
subroutine, public dionic_pert_matrix_elements_2 (gr, namespace, space, ions, hm, ik, st, vib, matrix)
 Computes the second order term. More...
 
subroutine zperturbation_ionic_apply (this, namespace, space, gr, hm, ik, f_in, f_out, set_bc)
 Returns f_out = H' f_in, where H' is perturbation Hamiltonian Note that e^ikr phase is applied to f_in, then is removed afterward. More...
 
subroutine zionic_perturbation (gr, namespace, ions, hm, ik, f_in, f_out, iatom, idir)
 
subroutine zperturbation_ionic_apply_order_2 (this, namespace, space, gr, hm, ik, f_in, f_out)
 
subroutine zionic_perturbation_order_2 (gr, namespace, ions, hm, ik, f_in, f_out, iatom, idir, jdir)
 
subroutine, public zionic_pert_matrix_elements_2 (gr, namespace, space, ions, hm, ik, st, vib, matrix)
 Computes the second order term. More...
 

Function/Subroutine Documentation

◆ perturbation_ionic_constructor()

class(perturbation_ionic_t) function, pointer perturbation_ionic_oct_m::perturbation_ionic_constructor ( type(namespace_t), intent(in)  namespace,
type(ions_t), intent(in), target  ions 
)
private

The factory routine (or constructor) allocates a pointer of the corresponding type and then calls the init routine which is a type-bound procedure of the corresponding type. With this design, also derived classes can use the init routine of the parent class.

Definition at line 192 of file perturbation_ionic.F90.

◆ perturbation_ionic_init()

subroutine perturbation_ionic_oct_m::perturbation_ionic_init ( type(perturbation_ionic_t), intent(out)  this,
type(namespace_t), intent(in)  namespace,
type(ions_t), intent(in), target  ions 
)
private

Definition at line 208 of file perturbation_ionic.F90.

◆ perturbation_ionic_copy()

subroutine perturbation_ionic_oct_m::perturbation_ionic_copy ( class(perturbation_ionic_t), intent(out)  this,
class(perturbation_ionic_t), intent(in)  source 
)
private

Definition at line 231 of file perturbation_ionic.F90.

◆ perturbation_ionic_finalize()

subroutine perturbation_ionic_oct_m::perturbation_ionic_finalize ( type(perturbation_ionic_t), intent(inout)  this)
private

Definition at line 254 of file perturbation_ionic.F90.

◆ perturbation_ionic_info()

subroutine perturbation_ionic_oct_m::perturbation_ionic_info ( class(perturbation_ionic_t), intent(in)  this)
private

Definition at line 266 of file perturbation_ionic.F90.

◆ perturbation_ionic_setup_dir()

subroutine perturbation_ionic_oct_m::perturbation_ionic_setup_dir ( class(perturbation_ionic_t), intent(inout)  this,
integer, intent(in)  dir,
integer, intent(in), optional  dir2 
)
private

Definition at line 275 of file perturbation_ionic.F90.

◆ perturbation_ionic_setup_atom()

subroutine perturbation_ionic_oct_m::perturbation_ionic_setup_atom ( class(perturbation_ionic_t), intent(inout)  this,
integer, intent(in)  iatom,
integer, intent(in), optional  iatom2 
)
private

Definition at line 297 of file perturbation_ionic.F90.

◆ perturbation_ionic_setup_mixed_dir()

subroutine perturbation_ionic_oct_m::perturbation_ionic_setup_mixed_dir ( class(perturbation_ionic_t), intent(inout)  this,
integer, intent(in)  iatom,
integer, intent(in)  idir,
real(real64), intent(in)  val,
integer, intent(in), optional  jatom,
integer, intent(in), optional  jdir,
real(real64), intent(in), optional  valuej 
)
private

Definition at line 319 of file perturbation_ionic.F90.

◆ dperturbation_ionic_apply()

subroutine perturbation_ionic_oct_m::dperturbation_ionic_apply ( class(perturbation_ionic_t), intent(in)  this,
type(namespace_t), intent(in)  namespace,
class(space_t), intent(in)  space,
type(grid_t), intent(in)  gr,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
real(real64), dimension(:, :), intent(in), contiguous  f_in,
real(real64), dimension(:, :), intent(out), contiguous  f_out,
logical, intent(in), optional  set_bc 
)
private

Returns f_out = H' f_in, where H' is perturbation Hamiltonian Note that e^ikr phase is applied to f_in, then is removed afterward.

Definition at line 420 of file perturbation_ionic.F90.

◆ dionic_perturbation()

subroutine perturbation_ionic_oct_m::dionic_perturbation ( type(grid_t), intent(in)  gr,
type(namespace_t), intent(in)  namespace,
type(ions_t), intent(in)  ions,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
real(real64), dimension(:), intent(in), contiguous  f_in,
real(real64), dimension(:), intent(out), contiguous  f_out,
integer, intent(in)  iatom,
integer, intent(in)  idir 
)
private

Definition at line 491 of file perturbation_ionic.F90.

◆ dperturbation_ionic_apply_order_2()

subroutine perturbation_ionic_oct_m::dperturbation_ionic_apply_order_2 ( class(perturbation_ionic_t), intent(in)  this,
type(namespace_t), intent(in)  namespace,
class(space_t), intent(in)  space,
type(grid_t), intent(in)  gr,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
real(real64), dimension(:, :), intent(in), contiguous  f_in,
real(real64), dimension(:, :), intent(out), contiguous  f_out 
)
private

Definition at line 554 of file perturbation_ionic.F90.

◆ dionic_perturbation_order_2()

subroutine perturbation_ionic_oct_m::dionic_perturbation_order_2 ( type(grid_t), intent(in)  gr,
type(namespace_t), intent(in)  namespace,
type(ions_t), intent(in)  ions,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
real(real64), dimension(:), intent(in)  f_in,
real(real64), dimension(:), intent(out)  f_out,
integer, intent(in)  iatom,
integer, intent(in)  idir,
integer, intent(in)  jdir 
)
private

Definition at line 624 of file perturbation_ionic.F90.

◆ dionic_pert_matrix_elements_2()

subroutine, public perturbation_ionic_oct_m::dionic_pert_matrix_elements_2 ( type(grid_t), intent(in)  gr,
type(namespace_t), intent(in)  namespace,
class(space_t), intent(in)  space,
type(ions_t), intent(in)  ions,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
type(states_elec_t), intent(inout)  st,
type(vibrations_t), intent(in)  vib,
real(real64), dimension(:, :), intent(inout)  matrix 
)

Computes the second order term.

\[-<\psi_0 | v^{(2)} | \psi_0>\]

entering in the dynamical matrix

The actual formula used is given in Andrade et al.. PCCP 17, 31371 (2014), see Eq. 58

Parameters
[in,out]matrixthis is an expectation value of a Hermitian operator

Definition at line 707 of file perturbation_ionic.F90.

◆ zperturbation_ionic_apply()

subroutine perturbation_ionic_oct_m::zperturbation_ionic_apply ( class(perturbation_ionic_t), intent(in)  this,
type(namespace_t), intent(in)  namespace,
class(space_t), intent(in)  space,
type(grid_t), intent(in)  gr,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
complex(real64), dimension(:, :), intent(in), contiguous  f_in,
complex(real64), dimension(:, :), intent(out), contiguous  f_out,
logical, intent(in), optional  set_bc 
)
private

Returns f_out = H' f_in, where H' is perturbation Hamiltonian Note that e^ikr phase is applied to f_in, then is removed afterward.

Definition at line 891 of file perturbation_ionic.F90.

◆ zionic_perturbation()

subroutine perturbation_ionic_oct_m::zionic_perturbation ( type(grid_t), intent(in)  gr,
type(namespace_t), intent(in)  namespace,
type(ions_t), intent(in)  ions,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
complex(real64), dimension(:), intent(in), contiguous  f_in,
complex(real64), dimension(:), intent(out), contiguous  f_out,
integer, intent(in)  iatom,
integer, intent(in)  idir 
)
private

Definition at line 962 of file perturbation_ionic.F90.

◆ zperturbation_ionic_apply_order_2()

subroutine perturbation_ionic_oct_m::zperturbation_ionic_apply_order_2 ( class(perturbation_ionic_t), intent(in)  this,
type(namespace_t), intent(in)  namespace,
class(space_t), intent(in)  space,
type(grid_t), intent(in)  gr,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
complex(real64), dimension(:, :), intent(in), contiguous  f_in,
complex(real64), dimension(:, :), intent(out), contiguous  f_out 
)
private

Definition at line 1025 of file perturbation_ionic.F90.

◆ zionic_perturbation_order_2()

subroutine perturbation_ionic_oct_m::zionic_perturbation_order_2 ( type(grid_t), intent(in)  gr,
type(namespace_t), intent(in)  namespace,
type(ions_t), intent(in)  ions,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
complex(real64), dimension(:), intent(in)  f_in,
complex(real64), dimension(:), intent(out)  f_out,
integer, intent(in)  iatom,
integer, intent(in)  idir,
integer, intent(in)  jdir 
)
private

Definition at line 1095 of file perturbation_ionic.F90.

◆ zionic_pert_matrix_elements_2()

subroutine, public perturbation_ionic_oct_m::zionic_pert_matrix_elements_2 ( type(grid_t), intent(in)  gr,
type(namespace_t), intent(in)  namespace,
class(space_t), intent(in)  space,
type(ions_t), intent(in)  ions,
type(hamiltonian_elec_t), intent(in)  hm,
integer, intent(in)  ik,
type(states_elec_t), intent(inout)  st,
type(vibrations_t), intent(in)  vib,
real(real64), dimension(:, :), intent(inout)  matrix 
)

Computes the second order term.

\[-<\psi_0 | v^{(2)} | \psi_0>\]

entering in the dynamical matrix

The actual formula used is given in Andrade et al.. PCCP 17, 31371 (2014), see Eq. 58

Parameters
[in,out]matrixthis is an expectation value of a Hermitian operator

Definition at line 1178 of file perturbation_ionic.F90.