The Elk Code
 
Loading...
Searching...
No Matches
writew90amn.f90
Go to the documentation of this file.
1
2! Copyright (C) 2024 J. K. Dewhurst and S. Sharma.
3! This file is distributed under the terms of the GNU General Public License.
4! See the file COPYING for license details.
5
6subroutine writew90amn
7use modmain
8use modw90
9use modrandom
10implicit none
11! local variables
12integer ik,ist,i
13real(8) a,b
14character(256) fname
15fname=trim(seedname)//'.amn'
16open(50,file=trim(fname),action='WRITE',form='FORMATTED')
17write(50,'("Generated by Elk version ",I0,".",I0,".",I0)') version
18write(50,'(3I6)') num_bands,nkptnr,num_wann
19do ik=1,nkptnr
20 do i=1,num_wann
21 do ist=1,num_bands
22 a=0.5d0-randomu()
23 b=0.5d0-randomu()
24 write(50,'(3I8,2G18.10)') ist,i,ik,a,b
25 end do
26 end do
27end do
28close(50)
29write(*,*)
30write(*,'("Info(writew90amn): created file ",A)') trim(fname)
31end subroutine
32
integer nkptnr
Definition modmain.f90:463
integer, dimension(3), parameter version
Definition modmain.f90:1288
real(8) function randomu()
Definition modrandom.f90:18
integer num_wann
Definition modw90.f90:18
integer num_bands
Definition modw90.f90:20
character(256) seedname
Definition modw90.f90:12
subroutine writew90amn