The Elk Code
 
Loading...
Searching...
No Matches
sstask.f90
Go to the documentation of this file.
1
2! Copyright (C) 2012 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 sstask(fnum,fext)
7use modmain
8use modmpi
9implicit none
10! arguments
11integer, intent(in) :: fnum
12character(*), intent(out) :: fext
13! local variables
14logical exist
15! only master process should search for file
16if (.not.mp_mpi) goto 10
17do iqss=1,nqpt
18! construct the spin-spiral file extension
19 call ssfext(iqss,fext)
20! determine if the SS file exists
21 inquire(file='SS'//trim(fext),exist=exist)
22 if (.not.exist) then
23 open(fnum,file='SS'//trim(fext),form='FORMATTED')
24 goto 10
25 end if
26end do
27iqss=0
28write(*,'("Info(sstask): nothing more to do")')
2910 continue
30! broadcast to all other processes
31call mpi_bcast(iqss,1,mpi_integer,0,mpicom,ierror)
32if (iqss == 0) then
33 fext='.OUT'
34else
35 call ssfext(iqss,fext)
36end if
37end subroutine
38
integer nqpt
Definition modmain.f90:525
integer iqss
Definition modmain.f90:297
integer ierror
Definition modmpi.f90:19
integer mpicom
Definition modmpi.f90:11
logical mp_mpi
Definition modmpi.f90:17
subroutine ssfext(iq, fext)
Definition ssfext.f90:7
subroutine sstask(fnum, fext)
Definition sstask.f90:7