The Elk Code
 
Loading...
Searching...
No Matches
potuplot.f90
Go to the documentation of this file.
1
2! Copyright (C) 2019 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
6subroutine potuplot
7use modmain
8use modulr
9implicit none
10! local variables
11integer ifq,ias,is
12! initialise universal variables
13call init0
14call init1
15! initialise the ultra long-range variables
16call initulr
17! read in the Kohn-Sham potential from STATE_ULR.OUT
18call readstulr
19! convert potential to spherical harmonics
20do ifq=1,nfqrz
21 do ias=1,natmtot
22 is=idxis(ias)
23 call zfshtip(nrcmt(is),nrcmti(is),vsqmt(:,ias,ifq))
24 end do
25end do
26! write the density plot to file
27select case(task)
28case(741)
29 open(50,file='VSU1D.OUT',form='FORMATTED')
30 open(51,file='VSULINES.OUT',form='FORMATTED')
31 call plotu1d(50,51,1,vsqmt,vsqir)
32 close(50)
33 close(51)
34 write(*,*)
35 write(*,'("Info(potuplot):")')
36 write(*,'(" 1D ultra long-range Kohn-Sham potential plot written to &
37 &VSU1D.OUT")')
38 write(*,'(" vertex location lines written to VSULINES.OUT")')
39case(742)
40 open(50,file='VSU2D.OUT',form='FORMATTED')
41 call plotu2d(.false.,50,1,vsqmt,vsqir)
42 open(50)
43 write(*,*)
44 write(*,'("Info(potuplot):")')
45 write(*,'(" 2D ultra long-range Kohn-Sham potential plot written to &
46 &VSU2D.OUT")')
47case(743)
48 open(50,file='VSU3D.OUT',form='FORMATTED')
49 call plotu3d(50,1,vsqmt,vsqir)
50 close(50)
51 write(*,*)
52 write(*,'("Info(potuplot):")')
53 write(*,'(" 3D ultra long-range Kohn-Sham potential plot written to &
54 &VSU3D.OUT")')
55end select
56end subroutine
57
subroutine init0
Definition init0.f90:10
subroutine init1
Definition init1.f90:10
subroutine initulr
Definition initulr.f90:7
integer nfqrz
Definition modmain.f90:539
integer, dimension(maxspecies) nrcmt
Definition modmain.f90:173
integer, dimension(maxatoms *maxspecies) idxis
Definition modmain.f90:44
integer natmtot
Definition modmain.f90:40
integer task
Definition modmain.f90:1298
integer, dimension(maxspecies) nrcmti
Definition modmain.f90:211
complex(8), dimension(:,:,:), pointer, contiguous vsqmt
Definition modulr.f90:83
complex(8), dimension(:,:), pointer, contiguous vsqir
Definition modulr.f90:83
subroutine plotu1d(fnum1, fnum2, nf, zfmt, zfir)
Definition plotu1d.f90:7
subroutine plotu2d(tproj, fnum, nf, zfmt, zfir)
Definition plotu2d.f90:7
subroutine plotu3d(fnum, nf, zfmt, zfir)
Definition plotu3d.f90:7
subroutine potuplot
Definition potuplot.f90:7
subroutine readstulr
Definition readstulr.f90:7
subroutine zfshtip(nr, nri, zfmt)
Definition zfshtip.f90:7