The Elk Code
k_tfvw.f90
Go to the documentation of this file.
1 
2 ! Copyright (C) 2021 J. K. Dewhurst, S. Sharma and E. K. U. Gross.
3 ! This file is distributed under the terms of the GNU General Public License.
4 ! See the file COPYING for license details.
5 
6 !BOP
7 ! !ROUTINE: k_tfvw
8 ! !INTERFACE:
9 subroutine k_tfvw(n,rho,grho2,dtdr,dtdgr2)
10 ! !INPUT/OUTPUT PARAMETERS:
11 ! n : number of density points (in,integer)
12 ! rho : spin-unpolarised charge density (in,real(n))
13 ! grho2 : |grad rho|^2 (in,real(n))
14 ! dtdr : dtau/drho (out,real(n))
15 ! dtdgr2 : dtau/d|grad rho|^2 (out,real(n))
16 ! !DESCRIPTION:
17 ! Calculates the derivatives $\partial\tau/\partial\rho$ and
18 ! $\partial\tau/\partial|\nabla\rho|^2$ of the gradient expansion of the
19 ! kinetic energy density $\tau$ for a set of points. See {\tt k\_tfvw1}.
20 !
21 ! !REVISION HISTORY:
22 ! Created December 2021 (JKD)
23 !EOP
24 !BOC
25 implicit none
26 ! arguments
27 integer, intent(in) :: n
28 real(8), intent(in) :: rho(n),grho2(n)
29 real(8), intent(out) :: dtdr(n),dtdgr2(n)
30 ! local variables
31 integer i
32 do i=1,n
33  call k_tfvw1(rho(i),grho2(i),dtdr(i),dtdgr2(i))
34 end do
35 end subroutine
36 !EOC
37 
elemental subroutine k_tfvw1(rho, grho2, dtdr, dtdgr2)
Definition: k_tfvw1.f90:10
subroutine k_tfvw(n, rho, grho2, dtdr, dtdgr2)
Definition: k_tfvw.f90:10