![]() |
Octopus
|
Data Types | |
| type | ace_t |
| type | exchange_operator_t |
Functions/Subroutines | |
| subroutine | ace_init (this, namespace, st) |
| Initialize an instance of ACE_t. More... | |
| subroutine | ace_end (this) |
| End an instance of ACE_t. More... | |
| subroutine | ace_write_info (this, namespace) |
| subroutine, public | exchange_operator_init (this, namespace, space, st, der, mc, stencil, kpoints, cam) |
| subroutine, public | exchange_operator_reinit (this, cam, st) |
| subroutine, public | exchange_operator_end (this) |
| subroutine, public | exchange_operator_rdmft_occ_apply (this, mesh, hpsib) |
| subroutine | exchange_operator_write_info (this, namespace) |
| subroutine, public | dexchange_operator_single (this, namespace, space, mesh, st_d, kpoints, phase, ist, ik, psi, hpsi, rdmft, force_noace) |
| subroutine, public | dexchange_operator_apply (this, namespace, space, mesh, st_d, kpoints, phase, psib, hpsib, rdmft, force_noace) |
| subroutine | dexchange_operator_apply_standard (this, namespace, space, mesh, st_d, kpoints, phase, psib, hpsib, rdmft) |
| subroutine | dexchange_operator_apply_ace (this, mesh, st_d, psib, hpsib) |
| subroutine | dexchange_operator_apply_ace_gemm (this, mesh, chib, psib, hpsib) |
| Apply the ACE operator \( |h\psi_j\rangle \mathrel{-}= \sum_i \langle\chi_i|\psi_j\rangle\,|\chi_i\rangle \) to a packed batch as GEMM operations on the device buffers. More... | |
| subroutine, public | dexchange_operator_compute_potentials (this, namespace, space, gr, st, xst, kpoints, F_out) |
| subroutine | dexchange_accumulate (np, xket, ff, ff_bra_host, pot_host, bra_buffer, ld_bra, ist_bra, pot_buffer) |
Accumulate the exchange contribution \( |x_j\rangle \mathrel{-}= ff\,\psi_{sym}\,V_{ij} \) into the whole target block xket, on host or device. More... | |
| subroutine | dexchange_operator_accumulate_return (gr, st, kpoints, ib2, ik2, exx_weight, pot, psi2, xpsi_ret, pot_buffer, xret_buffer, ff2_buffer, ff2_base, base_ret) |
| Accumulates the exchange contribution of one batch of local states acting on a received state. More... | |
| subroutine | dexchange_operator_add_returned (gr, st, xst, ib_send, ik_send, xpsi_rec, xret_buffer) |
| Add the returned exchange potential into the local xst block (sending task). More... | |
| real(real64) function, public | dexchange_operator_compute_ex (mesh, st, xst) |
| Compute the exact exchange energy. More... | |
| subroutine, public | dexchange_operator_ace (this, namespace, mesh, st, xst, phase) |
| Construct the ACE vectors. More... | |
| subroutine | dexchange_operator_ace_overlap (this, mesh, st, xst, xpsi, MM) |
| Build the ACE overlap matrix for state-parallel wave functions. More... | |
| subroutine | dexchange_operator_ace_overlap_batched (this, mesh, st, xst, MM) |
| Build the ACE overlap matrix from non-state-parallel wave-function batches. More... | |
| subroutine, public | dexchange_operator_commute_r (this, namespace, mesh, st_d, ik, psi, gpsi) |
| subroutine, public | dexchange_operator_hartree_apply (this, namespace, mesh, st_d, kpoints, exx_coef, psib, hpsib) |
| subroutine, public | zexchange_operator_single (this, namespace, space, mesh, st_d, kpoints, phase, ist, ik, psi, hpsi, rdmft, force_noace) |
| subroutine, public | zexchange_operator_apply (this, namespace, space, mesh, st_d, kpoints, phase, psib, hpsib, rdmft, force_noace) |
| subroutine | zexchange_operator_apply_standard (this, namespace, space, mesh, st_d, kpoints, phase, psib, hpsib, rdmft) |
| subroutine | zexchange_operator_apply_ace (this, mesh, st_d, psib, hpsib) |
| subroutine | zexchange_operator_apply_ace_gemm (this, mesh, chib, psib, hpsib) |
| Apply the ACE operator \( |h\psi_j\rangle \mathrel{-}= \sum_i \langle\chi_i|\psi_j\rangle\,|\chi_i\rangle \) to a packed batch as GEMM operations on the device buffers. More... | |
| subroutine, public | zexchange_operator_compute_potentials (this, namespace, space, gr, st, xst, kpoints, F_out) |
| subroutine | zexchange_accumulate (np, xket, ff, ff_bra_host, pot_host, bra_buffer, ld_bra, ist_bra, pot_buffer) |
Accumulate the exchange contribution \( |x_j\rangle \mathrel{-}= ff\,\psi_{sym}\,V_{ij} \) into the whole target block xket, on host or device. More... | |
| subroutine | zexchange_operator_accumulate_return (gr, st, kpoints, ib2, ik2, exx_weight, pot, psi2, xpsi_ret, pot_buffer, xret_buffer, ff2_buffer, ff2_base, base_ret) |
| Accumulates the exchange contribution of one batch of local states acting on a received state. More... | |
| subroutine | zexchange_operator_add_returned (gr, st, xst, ib_send, ik_send, xpsi_rec, xret_buffer) |
| Add the returned exchange potential into the local xst block (sending task). More... | |
| real(real64) function, public | zexchange_operator_compute_ex (mesh, st, xst) |
| Compute the exact exchange energy. More... | |
| subroutine, public | zexchange_operator_ace (this, namespace, mesh, st, xst, phase) |
| Construct the ACE vectors. More... | |
| subroutine | zexchange_operator_ace_overlap (this, mesh, st, xst, xpsi, MM) |
| Build the ACE overlap matrix for state-parallel wave functions. More... | |
| subroutine | zexchange_operator_ace_overlap_batched (this, mesh, st, xst, MM) |
| Build the ACE overlap matrix from non-state-parallel wave-function batches. More... | |
| subroutine, public | zexchange_operator_commute_r (this, namespace, mesh, st_d, ik, psi, gpsi) |
| subroutine, public | zexchange_operator_hartree_apply (this, namespace, mesh, st_d, kpoints, exx_coef, psib, hpsib) |
Variables | |
| type(fourier_space_op_t) | coulb |
| Operator in Fourier space. More... | |
| real(real64), parameter, private | tol_exx_weight = 1.0e-3_real64 |
| Minimum weight below which EXX is not added. More... | |
|
private |
Initialize an instance of ACE_t.
Definition at line 230 of file exchange_operator.F90.
|
private |
End an instance of ACE_t.
Definition at line 271 of file exchange_operator.F90.
|
private |
Definition at line 293 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::exchange_operator_init | ( | type(exchange_operator_t), intent(inout) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| type(states_elec_t), intent(in) | st, | ||
| type(derivatives_t), intent(in) | der, | ||
| type(multicomm_t), intent(in) | mc, | ||
| type(stencil_t), intent(in) | stencil, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| type(xc_cam_t), intent(in) | cam | ||
| ) |
Definition at line 306 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::exchange_operator_reinit | ( | type(exchange_operator_t), intent(inout) | this, |
| type(xc_cam_t), intent(in) | cam, | ||
| type(states_elec_t), intent(in), optional, target | st | ||
| ) |
Definition at line 414 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::exchange_operator_end | ( | type(exchange_operator_t), intent(inout) | this | ) |
Definition at line 430 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::exchange_operator_rdmft_occ_apply | ( | type(exchange_operator_t), intent(in) | this, |
| type(mesh_t), intent(in) | mesh, | ||
| class(wfs_elec_t), intent(inout) | hpsib | ||
| ) |
Definition at line 451 of file exchange_operator.F90.
|
private |
Definition at line 465 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::dexchange_operator_single | ( | type(exchange_operator_t), intent(inout) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| class(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| type(phase_t), intent(in) | phase, | ||
| integer, intent(in) | ist, | ||
| integer, intent(in) | ik, | ||
| real(real64), dimension(:, :), intent(inout), contiguous | psi, | ||
| real(real64), dimension(:, :), intent(inout), contiguous | hpsi, | ||
| logical, intent(in) | rdmft, | ||
| logical, intent(in), optional | force_noace | ||
| ) |
Definition at line 554 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::dexchange_operator_apply | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| type(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| type(phase_t), intent(in) | phase, | ||
| class(wfs_elec_t), intent(inout) | psib, | ||
| class(wfs_elec_t), intent(inout) | hpsib, | ||
| logical, intent(in) | rdmft, | ||
| logical, intent(in), optional | force_noace | ||
| ) |
Definition at line 585 of file exchange_operator.F90.
|
private |
Definition at line 612 of file exchange_operator.F90.
|
private |
Definition at line 774 of file exchange_operator.F90.
|
private |
Apply the ACE operator \( |h\psi_j\rangle \mathrel{-}= \sum_i \langle\chi_i|\psi_j\rangle\,|\chi_i\rangle \) to a packed batch as GEMM operations on the device buffers.
GEMM operations run on the packed buffers (ist-1)*dim+idim. For spinors the spin diagonal of the coefficient matrix is summed and re-expanded so the same S(i,j) is applied to every spinor component.
Definition at line 858 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::dexchange_operator_compute_potentials | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| type(grid_t), intent(in) | gr, | ||
| type(states_elec_t), intent(inout), target | st, | ||
| type(states_elec_t), intent(inout) | xst, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| real(real64), dimension(:,:,:,:,:), intent(out), optional | F_out | ||
| ) |
| [in,out] | xst | Action of V_X on a set of KS states |
| [out] | f_out | For RDMFT |
Definition at line 994 of file exchange_operator.F90.
|
private |
Accumulate the exchange contribution \( |x_j\rangle \mathrel{-}= ff\,\psi_{sym}\,V_{ij} \) into the whole target block xket, on host or device.
| [in] | ff | device: scaling factor; host: unused (folded in ff_bra_host) |
| [in] | ff_bra_host | host: ff*psi_sym (np,dim) |
| [in] | pot_host | host: pot(:,1:xketnst) |
Definition at line 1612 of file exchange_operator.F90.
|
private |
Accumulates the exchange contribution of one batch of local states acting on a received state.
| [in] | ib2 | Block index of the local states |
| [in] | ik2 | k-point index of the local states |
| [in] | exx_weight | Weight of the exchange operator |
| [in] | pot | host: potentials for the local states of the batch |
| [in,out] | psi2 | host: workspace for accessing device batches |
| [in,out] | xpsi_ret | host: accumulated potential to be returned |
| [in] | pot_buffer | device: potentials (np, nst2) |
| [in,out] | xret_buffer | device: (np, dim, nst_received) return buffer |
| [in] | ff2_buffer | device: precomputed per-lane weights (real64) |
| [in] | ff2_base | device: offset of this block weights in ff2_buffer |
| [in] | base_ret | device: element offset of the current bra in xret_buffer |
Definition at line 1702 of file exchange_operator.F90.
|
private |
Add the returned exchange potential into the local xst block (sending task).
| [in] | ib_send | Block index of the states that were sent |
| [in] | ik_send | k-point index of the states that were sent |
| [in] | xpsi_rec | host: returned potential, (np, dim, nst) |
| [in] | xret_buffer | device: returned potential, (np, dim, nst) |
Definition at line 1799 of file exchange_operator.F90.
| real(real64) function, public exchange_operator_oct_m::dexchange_operator_compute_ex | ( | class(mesh_t), intent(in) | mesh, |
| type(states_elec_t), intent(in) | st, | ||
| type(states_elec_t), intent(in) | xst | ||
| ) |
Compute the exact exchange energy.
\[ E_X = \frac{1}{2} \sum_{i, \sigma \mathbf{k}} w_\mathbf{k} f_{i\sigma\mathbf{k}} \int \psi^\ast_{i \sigma \mathbf{k}}(\mathbf{r}) W_{i \sigma \mathbf{k}}(\mathbf{r}) d\mathbf{r} \]
where
\[ W_{i\sigma\mathbf{k}}(\mathbf{r}) = - \sum_{j,\mathbf{k}^\prime} f_{j\sigma\mathbf{k}^\prime}\,\omega_{\mathbf{k}^\prime} V_{ij}^{\mathbf{k},\mathbf{k}^\prime,\sigma}(\mathbf{r}) \psi_{j\sigma\mathbf{k}^\prime}(\mathbf{r}) \]
is the action of the exchange operator on a set of Kohn-Sham states.
xst. This is what is done in the routine exchange_operator_compute_potentials. | [in] | st | A set of KS states |
| [in] | xst | V_X operating on a set of KS states |
Definition at line 1917 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::dexchange_operator_ace | ( | type(exchange_operator_t), intent(inout) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(mesh_t), intent(in) | mesh, | ||
| type(states_elec_t), intent(inout) | st, | ||
| type(states_elec_t), intent(inout) | xst, | ||
| type(phase_t), intent(in), optional | phase | ||
| ) |
Construct the ACE vectors.
This follows the procedure defined in Lin, J. Chem. Theory Comput. 2016, 12, 2242. It constructs the \( M \) matrix, defined as the projection of the exact exchange operator onto the occupied Kohn-Sham states:
\[ M_{ij} = \langle \psi_i | \hat{V}_X | \psi_j \rangle = \langle \psi_i | W_j \rangle, \]
where \( W_j(\mathbf{r}) = (\hat{V}_X \psi_j)(\mathbf{r}) \) is the exchange operator applied to state \( j \). \( M \) is then decomposed into \( L \), which is inverted and used to construct the ACE vectors:
\[ \xi_k(\mathbf{r}) = \sum_{j=1}^n W_j(\mathbf{r}) \left(L^{-H}\right)_{j k} \]
| [in,out] | this | ACE vectors, of size thisacenst |
| [in,out] | xst | Application of the exact exchange |
Definition at line 1972 of file exchange_operator.F90.
|
private |
Build the ACE overlap matrix for state-parallel wave functions.
For each local spin/k-point, construct the lower triangle of the ACE overlap matrix:
\[ M_{ij}^{(k)} = -\left\langle \psi_i^{(k)} \middle| \hat{X} \middle| \psi_j^{(k)} \right\rangle, \qquad (i, j) \leq N_{\mathrm{ACE}}. \]
Here, st contains the Kohn–Sham states \(\psi_i\) and xst contains their images under the exact-exchange operator, \(\hat{X}\psi_j\).
| [in,out] | xpsi | Work array |
Definition at line 2121 of file exchange_operator.F90.
|
private |
Build the ACE overlap matrix from non-state-parallel wave-function batches.
For each local spin/k-point, construct the lower triangle of the ACE overlap matrix:
\[ M_{ij}^{(k)} = -\left\langle \psi_i^{(k)} \middle| \hat{X} \middle| \psi_j^{(k)} \right\rangle, \qquad (i, j) \leq N_{\mathrm{ACE}}. \]
The unused upper triangle, and spin/k-points without electrons, are returned as zero.
| [out] | mm | Overlap |
Definition at line 2186 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::dexchange_operator_commute_r | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| integer, intent(in) | ik, | ||
| real(real64), dimension(:, :), intent(in), contiguous | psi, | ||
| real(real64), dimension(:, :, :), intent(inout), contiguous | gpsi | ||
| ) |
Definition at line 2235 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::dexchange_operator_hartree_apply | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| type(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| real(real64), intent(in) | exx_coef, | ||
| class(wfs_elec_t), intent(inout) | psib, | ||
| class(wfs_elec_t), intent(inout) | hpsib | ||
| ) |
Definition at line 2306 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::zexchange_operator_single | ( | type(exchange_operator_t), intent(inout) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| class(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| type(phase_t), intent(in) | phase, | ||
| integer, intent(in) | ist, | ||
| integer, intent(in) | ik, | ||
| complex(real64), dimension(:, :), intent(inout), contiguous | psi, | ||
| complex(real64), dimension(:, :), intent(inout), contiguous | hpsi, | ||
| logical, intent(in) | rdmft, | ||
| logical, intent(in), optional | force_noace | ||
| ) |
Definition at line 2459 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::zexchange_operator_apply | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| type(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| type(phase_t), intent(in) | phase, | ||
| class(wfs_elec_t), intent(inout) | psib, | ||
| class(wfs_elec_t), intent(inout) | hpsib, | ||
| logical, intent(in) | rdmft, | ||
| logical, intent(in), optional | force_noace | ||
| ) |
Definition at line 2490 of file exchange_operator.F90.
|
private |
Definition at line 2517 of file exchange_operator.F90.
|
private |
Definition at line 2679 of file exchange_operator.F90.
|
private |
Apply the ACE operator \( |h\psi_j\rangle \mathrel{-}= \sum_i \langle\chi_i|\psi_j\rangle\,|\chi_i\rangle \) to a packed batch as GEMM operations on the device buffers.
GEMM operations run on the packed buffers (ist-1)*dim+idim. For spinors the spin diagonal of the coefficient matrix is summed and re-expanded so the same S(i,j) is applied to every spinor component.
Definition at line 2763 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::zexchange_operator_compute_potentials | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(space_t), intent(in) | space, | ||
| type(grid_t), intent(in) | gr, | ||
| type(states_elec_t), intent(inout), target | st, | ||
| type(states_elec_t), intent(inout) | xst, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| complex(real64), dimension(:,:,:,:,:), intent(out), optional | F_out | ||
| ) |
| [in,out] | xst | Action of V_X on a set of KS states |
| [out] | f_out | For RDMFT |
Definition at line 2899 of file exchange_operator.F90.
|
private |
Accumulate the exchange contribution \( |x_j\rangle \mathrel{-}= ff\,\psi_{sym}\,V_{ij} \) into the whole target block xket, on host or device.
| [in] | ff | device: scaling factor; host: unused (folded in ff_bra_host) |
| [in] | ff_bra_host | host: ff*psi_sym (np,dim) |
| [in] | pot_host | host: pot(:,1:xketnst) |
Definition at line 3526 of file exchange_operator.F90.
|
private |
Accumulates the exchange contribution of one batch of local states acting on a received state.
| [in] | ib2 | Block index of the local states |
| [in] | ik2 | k-point index of the local states |
| [in] | exx_weight | Weight of the exchange operator |
| [in] | pot | host: potentials for the local states of the batch |
| [in,out] | psi2 | host: workspace for accessing device batches |
| [in,out] | xpsi_ret | host: accumulated potential to be returned |
| [in] | pot_buffer | device: potentials (np, nst2) |
| [in,out] | xret_buffer | device: (np, dim, nst_received) return buffer |
| [in] | ff2_buffer | device: precomputed per-lane weights (real64) |
| [in] | ff2_base | device: offset of this block weights in ff2_buffer |
| [in] | base_ret | device: element offset of the current bra in xret_buffer |
Definition at line 3616 of file exchange_operator.F90.
|
private |
Add the returned exchange potential into the local xst block (sending task).
| [in] | ib_send | Block index of the states that were sent |
| [in] | ik_send | k-point index of the states that were sent |
| [in] | xpsi_rec | host: returned potential, (np, dim, nst) |
| [in] | xret_buffer | device: returned potential, (np, dim, nst) |
Definition at line 3713 of file exchange_operator.F90.
| real(real64) function, public exchange_operator_oct_m::zexchange_operator_compute_ex | ( | class(mesh_t), intent(in) | mesh, |
| type(states_elec_t), intent(in) | st, | ||
| type(states_elec_t), intent(in) | xst | ||
| ) |
Compute the exact exchange energy.
\[ E_X = \frac{1}{2} \sum_{i, \sigma \mathbf{k}} w_\mathbf{k} f_{i\sigma\mathbf{k}} \int \psi^\ast_{i \sigma \mathbf{k}}(\mathbf{r}) W_{i \sigma \mathbf{k}}(\mathbf{r}) d\mathbf{r} \]
where
\[ W_{i\sigma\mathbf{k}}(\mathbf{r}) = - \sum_{j,\mathbf{k}^\prime} f_{j\sigma\mathbf{k}^\prime}\,\omega_{\mathbf{k}^\prime} V_{ij}^{\mathbf{k},\mathbf{k}^\prime,\sigma}(\mathbf{r}) \psi_{j\sigma\mathbf{k}^\prime}(\mathbf{r}) \]
is the action of the exchange operator on a set of Kohn-Sham states.
xst. This is what is done in the routine exchange_operator_compute_potentials. | [in] | st | A set of KS states |
| [in] | xst | V_X operating on a set of KS states |
Definition at line 3831 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::zexchange_operator_ace | ( | type(exchange_operator_t), intent(inout) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(mesh_t), intent(in) | mesh, | ||
| type(states_elec_t), intent(inout) | st, | ||
| type(states_elec_t), intent(inout) | xst, | ||
| type(phase_t), intent(in), optional | phase | ||
| ) |
Construct the ACE vectors.
This follows the procedure defined in Lin, J. Chem. Theory Comput. 2016, 12, 2242. It constructs the \( M \) matrix, defined as the projection of the exact exchange operator onto the occupied Kohn-Sham states:
\[ M_{ij} = \langle \psi_i | \hat{V}_X | \psi_j \rangle = \langle \psi_i | W_j \rangle, \]
where \( W_j(\mathbf{r}) = (\hat{V}_X \psi_j)(\mathbf{r}) \) is the exchange operator applied to state \( j \). \( M \) is then decomposed into \( L \), which is inverted and used to construct the ACE vectors:
\[ \xi_k(\mathbf{r}) = \sum_{j=1}^n W_j(\mathbf{r}) \left(L^{-H}\right)_{j k} \]
| [in,out] | this | ACE vectors, of size thisacenst |
| [in,out] | xst | Application of the exact exchange |
Definition at line 3886 of file exchange_operator.F90.
|
private |
Build the ACE overlap matrix for state-parallel wave functions.
For each local spin/k-point, construct the lower triangle of the ACE overlap matrix:
\[ M_{ij}^{(k)} = -\left\langle \psi_i^{(k)} \middle| \hat{X} \middle| \psi_j^{(k)} \right\rangle, \qquad (i, j) \leq N_{\mathrm{ACE}}. \]
Here, st contains the Kohn–Sham states \(\psi_i\) and xst contains their images under the exact-exchange operator, \(\hat{X}\psi_j\).
| [in,out] | xpsi | Work array |
Definition at line 4035 of file exchange_operator.F90.
|
private |
Build the ACE overlap matrix from non-state-parallel wave-function batches.
For each local spin/k-point, construct the lower triangle of the ACE overlap matrix:
\[ M_{ij}^{(k)} = -\left\langle \psi_i^{(k)} \middle| \hat{X} \middle| \psi_j^{(k)} \right\rangle, \qquad (i, j) \leq N_{\mathrm{ACE}}. \]
The unused upper triangle, and spin/k-points without electrons, are returned as zero.
| [out] | mm | Overlap |
Definition at line 4100 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::zexchange_operator_commute_r | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| class(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| integer, intent(in) | ik, | ||
| complex(real64), dimension(:, :), intent(in), contiguous | psi, | ||
| complex(real64), dimension(:, :, :), intent(inout), contiguous | gpsi | ||
| ) |
Definition at line 4149 of file exchange_operator.F90.
| subroutine, public exchange_operator_oct_m::zexchange_operator_hartree_apply | ( | type(exchange_operator_t), intent(in) | this, |
| type(namespace_t), intent(in) | namespace, | ||
| type(mesh_t), intent(in) | mesh, | ||
| type(states_elec_dim_t), intent(in) | st_d, | ||
| type(kpoints_t), intent(in) | kpoints, | ||
| real(real64), intent(in) | exx_coef, | ||
| class(wfs_elec_t), intent(inout) | psib, | ||
| class(wfs_elec_t), intent(inout) | hpsib | ||
| ) |
Definition at line 4220 of file exchange_operator.F90.
|
private |
Operator in Fourier space.
Definition at line 221 of file exchange_operator.F90.
|
private |
Minimum weight below which EXX is not added.
Definition at line 225 of file exchange_operator.F90.