File: genzfrm.f90

package info (click to toggle)
elkcode 5.4.24-2
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 12,840 kB
  • sloc: f90: 48,415; fortran: 22,457; perl: 965; makefile: 384; sh: 369; python: 105; ansic: 67
file content (43 lines) | stat: -rw-r--r-- 1,415 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43

! Copyright (C) 2002-2010 J. K. Dewhurst, S. Sharma and C. Ambrosch-Draxl.
! This file is distributed under the terms of the GNU General Public License.
! See the file COPYING for license details.

subroutine genzfrm(wfmt11,wfmt12,wfir11,wfir12,wfmt21,wfmt22,wfir21,wfir22, &
 zrhomt,zrhoir,zmagmt,zmagir)
use modmain
use modomp
implicit none
! arguments
complex(8), intent(in) ::  wfmt11(npcmtmax,natmtot),wfmt12(npcmtmax,natmtot)
complex(8), intent(in) ::  wfir11(ngtot),wfir12(ngtot)
complex(8), intent(in) ::  wfmt21(npcmtmax,natmtot),wfmt22(npcmtmax,natmtot)
complex(8), intent(in) ::  wfir21(ngtot),wfir22(ngtot)
complex(8), intent(out) :: zrhomt(npcmtmax,natmtot),zrhoir(ngtot)
complex(8), intent(out) :: zmagmt(npcmtmax,natmtot,ndmag),zmagir(ngtot,ndmag)
! local variables
integer ld,is,ias,nthd
!-------------------------!
!     muffin-tin part     !
!-------------------------!
ld=npcmtmax*natmtot
call omp_hold(natmtot,nthd)
!$OMP PARALLEL DEFAULT(SHARED) &
!$OMP PRIVATE(is) &
!$OMP NUM_THREADS(nthd)
!$OMP DO
do ias=1,natmtot
  is=idxis(ias)
  call genzrm(npcmt(is),wfmt11(:,ias),wfmt12(:,ias),wfmt21(:,ias), &
   wfmt22(:,ias),zrhomt(:,ias),ld,zmagmt(:,ias,1))
end do
!$OMP END DO
!$OMP END PARALLEL
call omp_free(nthd)
!---------------------------!
!     interstitial part     !
!---------------------------!
call genzrm(ngtot,wfir11,wfir12,wfir21,wfir22,zrhoir,ngtot,zmagir)
return
end subroutine