![]() |
Octopus
|
Data Types | |
type | sternheimer_t |
Functions/Subroutines | |
subroutine, public | sternheimer_init (this, namespace, space, gr, st, hm, xc, mc, wfs_are_cplx, set_ham_var, set_occ_response, set_last_occ_response, occ_response_by_sternheimer) |
subroutine, public | sternheimer_end (this) |
subroutine | sternheimer_build_fxc (this, namespace, gr, st, xc) |
Builds the exchange-correlation kernel \(f_{\rm xc}\) for computing the density response. More... | |
subroutine, public | sternheimer_build_kxc (this, namespace, mesh, st, xc) |
subroutine, public | sternheimer_unset_kxc (this) |
logical function, public | sternheimer_add_fxc (this) |
logical function, public | sternheimer_add_hartree (this) |
logical function, public | sternheimer_has_converged (this) |
logical pure function, public | sternheimer_have_rhs (this) |
subroutine, public | sternheimer_unset_rhs (this) |
logical pure function, public | sternheimer_have_inhomog (this) |
subroutine, public | sternheimer_unset_inhomog (this) |
integer pure function, public | swap_sigma (sigma) |
character(len=100) function, public | wfs_tag_sigma (namespace, base_name, isigma) |
subroutine, public | sternheimer_obsolete_variables (namespace, old_prefix, new_prefix) |
subroutine | calc_hvar_photons (this, mesh, nspin, lr_rho, nsigma, hvar, idir) |
subroutine, public | zsternheimer_solve (this, namespace, space, gr, kpoints, st, hm, mc, lr, nsigma, omega, perturbation, restart, rho_tag, wfs_tag, idir, have_restart_rho, have_exact_freq) |
This routine calculates the first-order variations of the wavefunctions for an applied perturbation. More... | |
subroutine | zsternheimer_add_occ (namespace, mesh, st, lr_psi, rhs, sst, est, ik, omega, degen_thres) |
add projection onto occupied states, by sum over states More... | |
subroutine, public | zsternheimer_calc_hvar (this, namespace, mesh, hm, lr, nsigma, hvar, idir) |
subroutine, public | zcalc_hvar (namespace, add_hartree, mesh, hm, lrc_alpha, lr_rho, nsigma, hvar, fxc) |
Computes the first-order variation of the Kohn-Sham Hamiltonian. More... | |
subroutine, public | zcalc_kvar (this, mesh, st, lr_rho1, lr_rho2, nsigma, kvar) |
subroutine, public | zsternheimer_set_rhs (this, rhs) |
subroutine, public | zsternheimer_set_inhomog (this, inhomog) |
subroutine, public | zsternheimer_solve_order2 (sh1, sh2, sh_2ndorder, namespace, space, gr, kpoints, st, hm, mc, lr1, lr2, nsigma, omega1, omega2, pert1, pert2, lr_2ndorder, pert_2ndorder, restart, rho_tag, wfs_tag, have_restart_rho, have_exact_freq, give_pert1psi2, give_dl_eig1) |
subroutine, public | dsternheimer_solve (this, namespace, space, gr, kpoints, st, hm, mc, lr, nsigma, omega, perturbation, restart, rho_tag, wfs_tag, idir, have_restart_rho, have_exact_freq) |
This routine calculates the first-order variations of the wavefunctions for an applied perturbation. More... | |
subroutine | dsternheimer_add_occ (namespace, mesh, st, lr_psi, rhs, sst, est, ik, omega, degen_thres) |
add projection onto occupied states, by sum over states More... | |
subroutine, public | dsternheimer_calc_hvar (this, namespace, mesh, hm, lr, nsigma, hvar, idir) |
subroutine, public | dcalc_hvar (namespace, add_hartree, mesh, hm, lrc_alpha, lr_rho, nsigma, hvar, fxc) |
Computes the first-order variation of the Kohn-Sham Hamiltonian. More... | |
subroutine, public | dcalc_kvar (this, mesh, st, lr_rho1, lr_rho2, nsigma, kvar) |
subroutine, public | dsternheimer_set_rhs (this, rhs) |
subroutine, public | dsternheimer_set_inhomog (this, inhomog) |
subroutine, public | dsternheimer_solve_order2 (sh1, sh2, sh_2ndorder, namespace, space, gr, kpoints, st, hm, mc, lr1, lr2, nsigma, omega1, omega2, pert1, pert2, lr_2ndorder, pert_2ndorder, restart, rho_tag, wfs_tag, have_restart_rho, have_exact_freq, give_pert1psi2, give_dl_eig1) |
Variables | |
character(len= *), parameter, public | em_resp_photons_dir = "em_resp_photons/" |
subroutine, public sternheimer_oct_m::sternheimer_init | ( | type(sternheimer_t), intent(out) | this, |
type(namespace_t), intent(in) | namespace, | ||
class(space_t), intent(in) | space, | ||
type(grid_t), intent(inout) | gr, | ||
type(states_elec_t), intent(in) | st, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
type(xc_t), intent(in) | xc, | ||
type(multicomm_t), intent(in) | mc, | ||
logical, intent(in) | wfs_are_cplx, | ||
integer, intent(in), optional | set_ham_var, | ||
logical, intent(in), optional | set_occ_response, | ||
logical, intent(in), optional | set_last_occ_response, | ||
logical, intent(in), optional | occ_response_by_sternheimer | ||
) |
Definition at line 232 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::sternheimer_end | ( | type(sternheimer_t), intent(inout) | this | ) |
Definition at line 400 of file sternheimer.F90.
|
private |
Builds the exchange-correlation kernel \(f_{\rm xc}\) for computing the density response.
Definition at line 421 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::sternheimer_build_kxc | ( | type(sternheimer_t), intent(inout) | this, |
type(namespace_t), intent(in) | namespace, | ||
class(mesh_t), intent(in) | mesh, | ||
type(states_elec_t), intent(in) | st, | ||
type(xc_t), intent(in) | xc | ||
) |
Definition at line 443 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::sternheimer_unset_kxc | ( | type(sternheimer_t), intent(inout) | this | ) |
Definition at line 469 of file sternheimer.F90.
logical function, public sternheimer_oct_m::sternheimer_add_fxc | ( | type(sternheimer_t), intent(in) | this | ) |
Definition at line 480 of file sternheimer.F90.
logical function, public sternheimer_oct_m::sternheimer_add_hartree | ( | type(sternheimer_t), intent(in) | this | ) |
Definition at line 487 of file sternheimer.F90.
logical function, public sternheimer_oct_m::sternheimer_has_converged | ( | type(sternheimer_t), intent(in) | this | ) |
Definition at line 494 of file sternheimer.F90.
logical pure function, public sternheimer_oct_m::sternheimer_have_rhs | ( | type(sternheimer_t), intent(in) | this | ) |
Definition at line 500 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::sternheimer_unset_rhs | ( | type(sternheimer_t), intent(inout) | this | ) |
Definition at line 506 of file sternheimer.F90.
logical pure function, public sternheimer_oct_m::sternheimer_have_inhomog | ( | type(sternheimer_t), intent(in) | this | ) |
Definition at line 518 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::sternheimer_unset_inhomog | ( | type(sternheimer_t), intent(inout) | this | ) |
Definition at line 524 of file sternheimer.F90.
integer pure function, public sternheimer_oct_m::swap_sigma | ( | integer, intent(in) | sigma | ) |
Definition at line 536 of file sternheimer.F90.
character(len=100) function, public sternheimer_oct_m::wfs_tag_sigma | ( | type(namespace_t), intent(in) | namespace, |
character(len=*), intent(in) | base_name, | ||
integer, intent(in) | isigma | ||
) |
Definition at line 548 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::sternheimer_obsolete_variables | ( | type(namespace_t), intent(in) | namespace, |
character(len=*), intent(in) | old_prefix, | ||
character(len=*), intent(in) | new_prefix | ||
) |
Definition at line 575 of file sternheimer.F90.
|
private |
[in,out] | hvar | (1:meshnp, 1:stdnspin, 1:nsigma) |
Definition at line 592 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::zsternheimer_solve | ( | type(sternheimer_t), intent(inout) | this, |
type(namespace_t), intent(in) | namespace, | ||
class(space_t), intent(in) | space, | ||
type(grid_t), intent(in), target | gr, | ||
type(kpoints_t), intent(in) | kpoints, | ||
type(states_elec_t), intent(in) | st, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
type(multicomm_t), intent(in) | mc, | ||
type(lr_t), dimension(:), intent(inout) | lr, | ||
integer, intent(in) | nsigma, | ||
complex(real64), intent(in) | omega, | ||
class(perturbation_t), intent(in) | perturbation, | ||
type(restart_t), intent(inout) | restart, | ||
character(len=*), intent(in) | rho_tag, | ||
character(len=*), intent(in) | wfs_tag, | ||
integer, intent(in), optional | idir, | ||
logical, intent(in), optional | have_restart_rho, | ||
logical, intent(in), optional | have_exact_freq | ||
) |
This routine calculates the first-order variations of the wavefunctions for an applied perturbation.
The perturbing Hamiltonian is usually given by
\[ \delta \hat{H}(\omega) =\delta \hat{v}(\boldsymbol{r}) +\int \mathrm{d} \boldsymbol{r}^{\prime} \frac{\delta n\left(\boldsymbol{r}^{\prime}, \omega\right)}{\left|\boldsymbol{r}-\boldsymbol{r}^{\prime}\right|} +\int \mathrm{d} \boldsymbol{r}^{\prime} f_{\mathrm{xc}} \left(\boldsymbol{r}, \boldsymbol{r}^{\prime}, \omega\right) \delta n\left(\boldsymbol{r}^{\prime}, \omega\right) . \]
Definition at line 714 of file sternheimer.F90.
|
private |
add projection onto occupied states, by sum over states
[in] | rhs | (np, ndim, nst) |
[in] | sst | start state |
[in] | est | start state |
Definition at line 1125 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::zsternheimer_calc_hvar | ( | type(sternheimer_t), intent(inout) | this, |
type(namespace_t), intent(in) | namespace, | ||
class(mesh_t), intent(in) | mesh, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
type(lr_t), dimension(:), intent(in) | lr, | ||
integer, intent(in) | nsigma, | ||
complex(real64), dimension(:,:,:), intent(out), contiguous | hvar, | ||
integer, intent(in), optional | idir | ||
) |
[out] | hvar | (1:meshnp, 1:stdnspin, 1:nsigma) |
Definition at line 1190 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::zcalc_hvar | ( | type(namespace_t), intent(in) | namespace, |
logical, intent(in) | add_hartree, | ||
class(mesh_t), intent(in) | mesh, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
real(real64), intent(in) | lrc_alpha, | ||
complex(real64), dimension(:,:), intent(in) | lr_rho, | ||
integer, intent(in) | nsigma, | ||
complex(real64), dimension(:,:,:), intent(out), contiguous | hvar, | ||
real(real64), dimension(:,:,:), intent(in), optional | fxc | ||
) |
Computes the first-order variation of the Kohn-Sham Hamiltonian.
This is given by Eq. 3 in Andrade et al., Phys. Chem. Chem. Phsy. 17, 31371 (2015) except for the change in the external potential.
\[ \delta \hat{H}_{\rm int}(\omega)= \int \mathrm{d} \boldsymbol{r}^{\prime} \frac{\delta n\left(\boldsymbol{r}^{\prime}, \omega\right)}{\left|\boldsymbol{r}-\boldsymbol{r}^{\prime}\right|} +\int \mathrm{d} \boldsymbol{r}^{\prime} f _{\mathrm{xc}}\left(\boldsymbol{r}, \boldsymbol{r}^{\prime}, \omega\right) \delta n\left(\boldsymbol{r}^{\prime}, \omega\right) . \]
[in] | lr_rho | (1:meshnp, 1:stdnspin) |
[out] | hvar | (1:meshnp, 1:stdnspin, 1:nsigma) |
[in] | fxc | (1:meshnp, 1:stdnspin, 1:stdnspin) |
Definition at line 1233 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::zcalc_kvar | ( | type(sternheimer_t), intent(in) | this, |
class(mesh_t), intent(in) | mesh, | ||
type(states_elec_t), intent(in) | st, | ||
complex(real64), dimension(:,:), intent(in) | lr_rho1, | ||
complex(real64), dimension(:,:), intent(in) | lr_rho2, | ||
integer, intent(in) | nsigma, | ||
complex(real64), dimension(:,:,:), intent(out) | kvar | ||
) |
[in] | lr_rho1 | (1:meshnp, 1:stdnspin) |
[in] | lr_rho2 | (1:meshnp, 1:stdnspin) |
[out] | kvar | (1:meshnp, 1:stdnspin, 1:nsigma) |
Definition at line 1298 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::zsternheimer_set_rhs | ( | type(sternheimer_t), intent(inout) | this, |
complex(real64), dimension(:, :, :, :), intent(in), target | rhs | ||
) |
Definition at line 1330 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::zsternheimer_set_inhomog | ( | type(sternheimer_t), intent(inout) | this, |
complex(real64), dimension(:, :, :, :, :), intent(in), target | inhomog | ||
) |
Definition at line 1342 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::zsternheimer_solve_order2 | ( | type(sternheimer_t), intent(inout) | sh1, |
type(sternheimer_t), intent(inout) | sh2, | ||
type(sternheimer_t), intent(inout) | sh_2ndorder, | ||
type(namespace_t), intent(in) | namespace, | ||
class(space_t), intent(in) | space, | ||
type(grid_t), intent(in), target | gr, | ||
type(kpoints_t), intent(in) | kpoints, | ||
type(states_elec_t), intent(in) | st, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
type(multicomm_t), intent(in) | mc, | ||
type(lr_t), dimension(:), intent(inout) | lr1, | ||
type(lr_t), dimension(:), intent(inout) | lr2, | ||
integer, intent(in) | nsigma, | ||
complex(real64), intent(in) | omega1, | ||
complex(real64), intent(in) | omega2, | ||
class(perturbation_t), intent(in) | pert1, | ||
class(perturbation_t), intent(in) | pert2, | ||
type(lr_t), dimension(:), intent(inout) | lr_2ndorder, | ||
class(perturbation_t), intent(in) | pert_2ndorder, | ||
type(restart_t), intent(inout) | restart, | ||
character(len=*), intent(in) | rho_tag, | ||
character(len=*), intent(in) | wfs_tag, | ||
logical, intent(in), optional | have_restart_rho, | ||
logical, intent(in), optional | have_exact_freq, | ||
complex(real64), dimension(:,:,:,:), intent(in), optional | give_pert1psi2, | ||
real(real64), dimension(:,:), intent(in), optional | give_dl_eig1 | ||
) |
[in] | give_pert1psi2 | (np, ndim, ist, ik) |
[in] | give_dl_eig1 | (nst, nk) expectation values of bare perturbation |
Definition at line 1355 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::dsternheimer_solve | ( | type(sternheimer_t), intent(inout) | this, |
type(namespace_t), intent(in) | namespace, | ||
class(space_t), intent(in) | space, | ||
type(grid_t), intent(in), target | gr, | ||
type(kpoints_t), intent(in) | kpoints, | ||
type(states_elec_t), intent(in) | st, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
type(multicomm_t), intent(in) | mc, | ||
type(lr_t), dimension(:), intent(inout) | lr, | ||
integer, intent(in) | nsigma, | ||
real(real64), intent(in) | omega, | ||
class(perturbation_t), intent(in) | perturbation, | ||
type(restart_t), intent(inout) | restart, | ||
character(len=*), intent(in) | rho_tag, | ||
character(len=*), intent(in) | wfs_tag, | ||
integer, intent(in), optional | idir, | ||
logical, intent(in), optional | have_restart_rho, | ||
logical, intent(in), optional | have_exact_freq | ||
) |
This routine calculates the first-order variations of the wavefunctions for an applied perturbation.
The perturbing Hamiltonian is usually given by
\[ \delta \hat{H}(\omega) =\delta \hat{v}(\boldsymbol{r}) +\int \mathrm{d} \boldsymbol{r}^{\prime} \frac{\delta n\left(\boldsymbol{r}^{\prime}, \omega\right)}{\left|\boldsymbol{r}-\boldsymbol{r}^{\prime}\right|} +\int \mathrm{d} \boldsymbol{r}^{\prime} f_{\mathrm{xc}} \left(\boldsymbol{r}, \boldsymbol{r}^{\prime}, \omega\right) \delta n\left(\boldsymbol{r}^{\prime}, \omega\right) . \]
Definition at line 1588 of file sternheimer.F90.
|
private |
add projection onto occupied states, by sum over states
[in] | rhs | (np, ndim, nst) |
[in] | sst | start state |
[in] | est | start state |
Definition at line 1999 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::dsternheimer_calc_hvar | ( | type(sternheimer_t), intent(inout) | this, |
type(namespace_t), intent(in) | namespace, | ||
class(mesh_t), intent(in) | mesh, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
type(lr_t), dimension(:), intent(in) | lr, | ||
integer, intent(in) | nsigma, | ||
real(real64), dimension(:,:,:), intent(out), contiguous | hvar, | ||
integer, intent(in), optional | idir | ||
) |
[out] | hvar | (1:meshnp, 1:stdnspin, 1:nsigma) |
Definition at line 2064 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::dcalc_hvar | ( | type(namespace_t), intent(in) | namespace, |
logical, intent(in) | add_hartree, | ||
class(mesh_t), intent(in) | mesh, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
real(real64), intent(in) | lrc_alpha, | ||
real(real64), dimension(:,:), intent(in) | lr_rho, | ||
integer, intent(in) | nsigma, | ||
real(real64), dimension(:,:,:), intent(out), contiguous | hvar, | ||
real(real64), dimension(:,:,:), intent(in), optional | fxc | ||
) |
Computes the first-order variation of the Kohn-Sham Hamiltonian.
This is given by Eq. 3 in Andrade et al., Phys. Chem. Chem. Phsy. 17, 31371 (2015) except for the change in the external potential.
\[ \delta \hat{H}_{\rm int}(\omega)= \int \mathrm{d} \boldsymbol{r}^{\prime} \frac{\delta n\left(\boldsymbol{r}^{\prime}, \omega\right)}{\left|\boldsymbol{r}-\boldsymbol{r}^{\prime}\right|} +\int \mathrm{d} \boldsymbol{r}^{\prime} f _{\mathrm{xc}}\left(\boldsymbol{r}, \boldsymbol{r}^{\prime}, \omega\right) \delta n\left(\boldsymbol{r}^{\prime}, \omega\right) . \]
[in] | lr_rho | (1:meshnp, 1:stdnspin) |
[out] | hvar | (1:meshnp, 1:stdnspin, 1:nsigma) |
[in] | fxc | (1:meshnp, 1:stdnspin, 1:stdnspin) |
Definition at line 2107 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::dcalc_kvar | ( | type(sternheimer_t), intent(in) | this, |
class(mesh_t), intent(in) | mesh, | ||
type(states_elec_t), intent(in) | st, | ||
real(real64), dimension(:,:), intent(in) | lr_rho1, | ||
real(real64), dimension(:,:), intent(in) | lr_rho2, | ||
integer, intent(in) | nsigma, | ||
real(real64), dimension(:,:,:), intent(out) | kvar | ||
) |
[in] | lr_rho1 | (1:meshnp, 1:stdnspin) |
[in] | lr_rho2 | (1:meshnp, 1:stdnspin) |
[out] | kvar | (1:meshnp, 1:stdnspin, 1:nsigma) |
Definition at line 2172 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::dsternheimer_set_rhs | ( | type(sternheimer_t), intent(inout) | this, |
real(real64), dimension(:, :, :, :), intent(in), target | rhs | ||
) |
Definition at line 2204 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::dsternheimer_set_inhomog | ( | type(sternheimer_t), intent(inout) | this, |
real(real64), dimension(:, :, :, :, :), intent(in), target | inhomog | ||
) |
Definition at line 2216 of file sternheimer.F90.
subroutine, public sternheimer_oct_m::dsternheimer_solve_order2 | ( | type(sternheimer_t), intent(inout) | sh1, |
type(sternheimer_t), intent(inout) | sh2, | ||
type(sternheimer_t), intent(inout) | sh_2ndorder, | ||
type(namespace_t), intent(in) | namespace, | ||
class(space_t), intent(in) | space, | ||
type(grid_t), intent(in), target | gr, | ||
type(kpoints_t), intent(in) | kpoints, | ||
type(states_elec_t), intent(in) | st, | ||
type(hamiltonian_elec_t), intent(in) | hm, | ||
type(multicomm_t), intent(in) | mc, | ||
type(lr_t), dimension(:), intent(inout) | lr1, | ||
type(lr_t), dimension(:), intent(inout) | lr2, | ||
integer, intent(in) | nsigma, | ||
real(real64), intent(in) | omega1, | ||
real(real64), intent(in) | omega2, | ||
class(perturbation_t), intent(in) | pert1, | ||
class(perturbation_t), intent(in) | pert2, | ||
type(lr_t), dimension(:), intent(inout) | lr_2ndorder, | ||
class(perturbation_t), intent(in) | pert_2ndorder, | ||
type(restart_t), intent(inout) | restart, | ||
character(len=*), intent(in) | rho_tag, | ||
character(len=*), intent(in) | wfs_tag, | ||
logical, intent(in), optional | have_restart_rho, | ||
logical, intent(in), optional | have_exact_freq, | ||
real(real64), dimension(:,:,:,:), intent(in), optional | give_pert1psi2, | ||
real(real64), dimension(:,:), intent(in), optional | give_dl_eig1 | ||
) |
[in] | give_pert1psi2 | (np, ndim, ist, ik) |
[in] | give_dl_eig1 | (nst, nk) expectation values of bare perturbation |
Definition at line 2229 of file sternheimer.F90.
character(len=*), parameter, public sternheimer_oct_m::em_resp_photons_dir = "em_resp_photons/" |
Definition at line 196 of file sternheimer.F90.