|
PROGRESS
master
|
Functions/Subroutines | |
| subroutine, public | prg_implicit_fermi_save_inverse (Inv_bml, h_bml, p_bml, nsteps, nocc, mu, beta, occErrLimit, threshold, tol, SCF_IT, occiter, totns) |
| Recursive Implicit Fermi Dirac for finite temperature. More... | |
| subroutine, public | prg_implicit_fermi (h_bml, p_bml, nsteps, k, nocc, mu, beta, method, osteps, occErrLimit, threshold, tol) |
| Recursive Implicit Fermi Dirac for finite temperature. More... | |
| subroutine, public | prg_implicit_fermi_zero (h_bml, p_bml, nsteps, mu, method, threshold, tol) |
| Recursive Implicit Fermi Dirac for zero temperature. More... | |
| subroutine, public | prg_implicit_fermi_first_order_response (H0_bml, H1_bml, P0_bml, P1_bml, Inv_bml, nsteps, mu0, beta, nocc, threshold) |
| Calculate first order density matrix response to perturbations using Implicit Fermi Dirac. More... | |
| subroutine, public | prg_implicit_fermi_response (H0_bml, H1_bml, H2_bml, H3_bml, P0_bml, P1_bml, P2_bml, P3_bml, nsteps, mu0, mu, beta, nocc, occ_tol, lin_tol, order, threshold) |
| Calculate density matrix response to perturbations using Implicit Fermi Dirac. More... | |
| subroutine, public | prg_finite_diff (H0_bml, H_list, mu0, mu_list, beta, order, lambda, h, threshold) |
| Calculate density matrix response from perturbations in the Hamiltonian. More... | |
| subroutine | prg_setup_linsys (p_bml, A_bml, b_bml, p2_bml, y_bml, aux_bml, aux1_bml, k, threshold) |
| Set up linear system for Implicit Fermi Dirac. More... | |
| subroutine | prg_newtonschulz (a_bml, ai_bml, r_bml, tmp_bml, d_bml, I_bml, tol, threshold, num_iter) |
| Find the inverse of the matrix A with Newton-Schulz iteration. More... | |
| subroutine | prg_pcg (A_bml, p_bml, p2_bml, d_bml, wtmp_bml, cg_tol, threshold) |
| Solve the system AX = B with conjugate gradient. More... | |
| subroutine | prg_conjgrad (A_bml, p_bml, p2_bml, tmp_bml, d_bml, w_bml, cg_tol, threshold) |
| Solve the system AX = B with conjugate gradient. More... | |
| subroutine | prg_get_density_matrix (ham_bml, p_bml, beta, mu, threshold) |
| Calculate the density matrix with diagonalization. More... | |
| subroutine, public | prg_test_density_matrix (ham_bml, p_bml, beta, mu, nocc, osteps, occErrLimit, threshold) |
| Calculate the density matrix with diagonalization and converge chemical. More... | |
| real(dp) function | fermi (e, mu, beta) |
| Gives the Fermi distribution value for energy e. More... | |
Variables | |
| integer, parameter | dp = kind(1.0d0) |
|
private |
Gives the Fermi distribution value for energy e.
| e | Energy. |
| mu | Fermi energy. |
| beta | Inverse temperature |
Definition at line 1192 of file prg_implicit_fermi_mod.F90.
|
private |
Solve the system AX = B with conjugate gradient.
| A_bml | Coefficient matrix A |
| p_bml | Output solution X |
| p2_bml | Right side matrix B |
| d_bml | Auxillary matrix |
| w_bml | Auxillary matrix |
| cg_tol | Convergence condition (OBS squared Frobenius norm of residual matrix) |
| threshold | Threshold for matrix algebra |
Definition at line 1006 of file prg_implicit_fermi_mod.F90.
| subroutine, public prg_implicit_fermi_mod::prg_finite_diff | ( | type(bml_matrix_t), intent(in) | H0_bml, |
| type(bml_matrix_t), dimension(:), intent(in), allocatable | H_list, | ||
| real(dp), intent(in) | mu0, | ||
| real(dp), dimension(:), intent(in), allocatable | mu_list, | ||
| real(dp), intent(in) | beta, | ||
| integer, intent(in) | order, | ||
| real(dp), intent(in) | lambda, | ||
| real(dp), intent(in) | h, | ||
| real(dp), intent(in) | threshold | ||
| ) |
Calculate density matrix response from perturbations in the Hamiltonian.
Definition at line 726 of file prg_implicit_fermi_mod.F90.
|
private |
Calculate the density matrix with diagonalization.
| ham_bml | Input hamiltonian |
| p_bml | Output density matrix |
| beta | Inverse temperature |
| mu | Chemical potential |
| threshold | Threshold for matrix algebra |
Definition at line 1056 of file prg_implicit_fermi_mod.F90.
| subroutine, public prg_implicit_fermi_mod::prg_implicit_fermi | ( | type(bml_matrix_t), intent(in) | h_bml, |
| type(bml_matrix_t), intent(inout) | p_bml, | ||
| integer, intent(in) | nsteps, | ||
| integer, intent(in) | k, | ||
| real(dp), intent(in) | nocc, | ||
| real(dp), intent(inout) | mu, | ||
| real(dp), intent(in) | beta, | ||
| integer, intent(in) | method, | ||
| integer, intent(in) | osteps, | ||
| real(dp), intent(in) | occErrLimit, | ||
| real(dp), intent(in) | threshold, | ||
| real(dp), intent(in) | tol | ||
| ) |
Recursive Implicit Fermi Dirac for finite temperature.
| h_bml | Input Hamiltonian matrix. |
| p_bml | Output density matrix. |
| nsteps | Number of recursion steps. |
| k | Expansion order |
| nocc | Number of occupied states. |
| mu | Shifted chemical potential |
| beta | Input inverse temperature. |
| method | 0 - conjugate gradient, 1 - newton-schultz |
| osteps | Outer loop steps to converge chemical potential |
| occErrLimit | Occupation error limit. |
| threshold | Threshold for multiplication. |
| tol | Tolerance for linear system solver See |
Definition at line 209 of file prg_implicit_fermi_mod.F90.
| subroutine, public prg_implicit_fermi_mod::prg_implicit_fermi_first_order_response | ( | type(bml_matrix_t), intent(in) | H0_bml, |
| type(bml_matrix_t), intent(in) | H1_bml, | ||
| type(bml_matrix_t), intent(inout) | P0_bml, | ||
| type(bml_matrix_t), intent(inout) | P1_bml, | ||
| type(bml_matrix_t), dimension(nsteps), intent(in) | Inv_bml, | ||
| integer, intent(in) | nsteps, | ||
| real(dp), intent(in) | mu0, | ||
| real(dp), intent(in) | beta, | ||
| real(dp), intent(in) | nocc, | ||
| real(dp), intent(in) | threshold | ||
| ) |
Calculate first order density matrix response to perturbations using Implicit Fermi Dirac.
| H0_bml | Input Hamiltonian matrix. |
| H1_bml | Input First order perturbation of H0. |
| P0_bml | Output density matrix. |
| P1_bml | Output First order density matrix response. |
| nsteps | Number of recursion steps. |
| mu0 | Shifted chemical potential. |
| beta | Input inverse temperature. |
| nocc | Number of occupied states. |
| threshold | Threshold for matrix algebra. See |
Definition at line 439 of file prg_implicit_fermi_mod.F90.
| subroutine, public prg_implicit_fermi_mod::prg_implicit_fermi_response | ( | type(bml_matrix_t), intent(in) | H0_bml, |
| type(bml_matrix_t), intent(in) | H1_bml, | ||
| type(bml_matrix_t), intent(in) | H2_bml, | ||
| type(bml_matrix_t), intent(in) | H3_bml, | ||
| type(bml_matrix_t), intent(inout) | P0_bml, | ||
| type(bml_matrix_t), intent(inout) | P1_bml, | ||
| type(bml_matrix_t), intent(inout) | P2_bml, | ||
| type(bml_matrix_t), intent(inout) | P3_bml, | ||
| integer, intent(in) | nsteps, | ||
| real(dp), intent(inout) | mu0, | ||
| real(dp), dimension(:), intent(inout), allocatable | mu, | ||
| real(dp), intent(in) | beta, | ||
| real(dp), intent(in) | nocc, | ||
| real(dp), intent(in) | occ_tol, | ||
| real(dp), intent(in) | lin_tol, | ||
| integer | order, | ||
| real(dp) | threshold | ||
| ) |
Calculate density matrix response to perturbations using Implicit Fermi Dirac.
| H0_bml | Input Hamiltonian matrix. |
| H1_bml,H2_bml,H3_bml | Input First to third order perturbations of H0. |
| P0_bml | Output density matrix. |
| P1_bml,P2_bml,P3_bml | Output First to third order density matrix response. |
| nsteps | Number of recursion steps. |
| mu0 | Shifted chemical potential. |
| mu | Pre-allocated array of length order. |
| beta | Input inverse temperature. |
| nocc | Number of occupied states. |
| occ_tol | Occupation error tolerance. |
| lin_tol | Linear solver tolerance. |
| order | Calculate response up to this order. |
| threshold | Threshold for matrix algebra. See |
Definition at line 547 of file prg_implicit_fermi_mod.F90.
| subroutine, public prg_implicit_fermi_mod::prg_implicit_fermi_save_inverse | ( | type(bml_matrix_t), dimension(nsteps), intent(inout) | Inv_bml, |
| type(bml_matrix_t), intent(in) | h_bml, | ||
| type(bml_matrix_t), intent(inout) | p_bml, | ||
| integer, intent(in) | nsteps, | ||
| real(dp), intent(in) | nocc, | ||
| real(dp), intent(inout) | mu, | ||
| real(dp), intent(in) | beta, | ||
| real(dp), intent(in) | occErrLimit, | ||
| real(dp), intent(in) | threshold, | ||
| real(dp), intent(in) | tol, | ||
| integer, intent(in) | SCF_IT, | ||
| integer, intent(inout) | occiter, | ||
| integer, intent(inout) | totns | ||
| ) |
Recursive Implicit Fermi Dirac for finite temperature.
| Inv_bml | Inverses generated by algorithm. |
| h_bml | Input Hamiltonian matrix. |
| p_bml | Output density matrix. |
| nsteps | Number of recursion steps. |
| nocc | Number of occupied states. |
| mu | Shifted chemical potential |
| beta | Input inverse temperature. |
| occErrLimit | Occupation error limit. |
| threshold | Threshold for multiplication. |
| tol | Tolerance for linear system solver. |
| SCF_IT | The current SCF iteration. |
| occiter | Counts the total nr of DM calculations during MD. See |
Definition at line 46 of file prg_implicit_fermi_mod.F90.
| subroutine, public prg_implicit_fermi_mod::prg_implicit_fermi_zero | ( | type(bml_matrix_t), intent(in) | h_bml, |
| type(bml_matrix_t), intent(inout) | p_bml, | ||
| integer, intent(in) | nsteps, | ||
| real(dp), intent(in) | mu, | ||
| integer, intent(in) | method, | ||
| real(dp), intent(in) | threshold, | ||
| real(dp), intent(inout), optional | tol | ||
| ) |
Recursive Implicit Fermi Dirac for zero temperature.
| h_bml | Input Hamiltonian matrix. |
| p_bml | Output density matrix. |
| nsteps | Number of recursion steps. |
| mu | Shifted chemical potential |
| beta | Input inverse temperature. |
| method | 0 - conjugate gradient, 1 - newton-schultz |
| threshold | Threshold for multiplication. |
| tol | Tolerance for linear system solver |
Definition at line 347 of file prg_implicit_fermi_mod.F90.
|
private |
Find the inverse of the matrix A with Newton-Schulz iteration.
| a_bml | Input matrix A |
| ai_bml | Input starting guess and output inverse |
| r_bml | Auxillary matrix |
| tmp_bml | Auxillary matrix |
| tol | Convergence criterion (Frobenius norm of residual matrix) |
| threshold | Threshold for matrix algebra |
Definition at line 888 of file prg_implicit_fermi_mod.F90.
|
private |
Solve the system AX = B with conjugate gradient.
| A_bml | Coefficient matrix A |
| p_bml | Output solution X |
| p2_bml | Right side matrix B |
| d_bml | Auxillary matrix |
| w_bml | Auxillary matrix |
| cg_tol | Convergence condition (OBS squared Frobenius norm of residual matrix) |
| threshold | Threshold for matrix algebra |
Definition at line 934 of file prg_implicit_fermi_mod.F90.
|
private |
Set up linear system for Implicit Fermi Dirac.
| p_bml | Input X_i matrix. |
| p2_bml | Output X_i^k matrix. |
| A_bml | Output [X_i^k + (I - X_i)^k] matrix. |
| y_bml | Auxillary matrix. |
| aux_bml | Auxillary matrix |
| aux1_bml | Auxillary matrix. |
| k | Expansion order (an even number) |
| threshold | Threshold for multiplication. OBS this routine can be numerically unstable for k > 4 |
Definition at line 843 of file prg_implicit_fermi_mod.F90.
| subroutine, public prg_implicit_fermi_mod::prg_test_density_matrix | ( | type(bml_matrix_t), intent(in) | ham_bml, |
| type(bml_matrix_t), intent(inout) | p_bml, | ||
| real(dp), intent(in) | beta, | ||
| real(dp), intent(inout) | mu, | ||
| real(dp), intent(in) | nocc, | ||
| integer, intent(in) | osteps, | ||
| real(dp), intent(in) | occErrLimit, | ||
| real(dp), intent(in) | threshold | ||
| ) |
Calculate the density matrix with diagonalization and converge chemical.
Definition at line 1112 of file prg_implicit_fermi_mod.F90.
|
private |
Definition at line 20 of file prg_implicit_fermi_mod.F90.