m_rdinput.f90

Go to the documentation of this file.
00001 module m_rdinput 
00002 implicit none
00003 private
00004 public::read_input 
00005 !--
00006 integer,public::N_CALC_BAND!TOTAL NUMBER OF CALCULATION BANDS 
00007 real(8),public::Ecut_for_eps!cutoff energy for dielectric matrix (Ry)
00008 real(8),public::shift_ef!artificial shift of Ef (eV) 
00009 real(8),public::Max_excitation_energy!delta_ex!excitation constraint (eV)
00010 real(8),public::delta_ex!excitation constraint (eV)
00011 real(8),public::Green_func_delt!delt!ttrhdrn Green's function delt (eV)
00012 real(8),public::delt!ttrhdrn Green's function delt (eV)
00013 real(8),public::ttrhdrn_dmna!dmna!ttrhdrn
00014 real(8),public::dmna!ttrhdrn
00015 real(8),public::ttrhdrn_dmnr!dmnr!ttrhdrn
00016 real(8),public::dmnr!ttrhdrn
00017 integer,public::MPI_io_rank!io_rank !mpi 
00018 integer,public::io_rank !mpi 
00019 integer,public::MPI_num_proc_per_qcomm!num_of_mpi_per_comm !mpi 
00020 integer,public::num_of_mpi_per_comm !mpi 
00021 integer,public::MPI_num_qcomm!num_of_comm !mpi 
00022 integer,public::num_of_comm !mpi 
00023 integer,public::Num_freq_grid!nen !frequency grid 
00024 integer,public::nen !frequency grid 
00025 real(8),public::Lower_bound_energy_window!LOWER BOUND OF ENERGY WINDOW (eV)
00026 real(8),public::E_LOWER!LOWER BOUND OF ENERGY WINDOW (eV)
00027 real(8),public::Upper_bound_energy_window!UPPER BOUND OF ENERGY WINDOW (eV)
00028 real(8),public::E_UPPER!UPPER BOUND OF ENERGY WINDOW (eV)
00029 integer,public::flg_cRPA 
00030 integer,public::flg_cRPA_band 
00031 integer,public::flg_cRPA_ewin
00032 integer,public::flg_calc_type 
00033 integer,public::file_num_log_start 
00034 integer,public::file_num_chi_start 
00035 integer,public::file_num_eps_start 
00036 integer,public::file_num_chi_base_start 
00037 integer,public::file_num_eps_base_start
00038 !calc_num_k 
00039 integer,public::n_calc_q!total number of calculated q pts
00040 integer,public,allocatable::calc_num_k(:)!calc_num_k(n_calc_q) 
00041 namelist/param_chiqw/N_CALC_BAND,Ecut_for_eps,shift_ef,Max_excitation_energy,& 
00042 Green_func_delt,ttrhdrn_dmna,ttrhdrn_dmnr,MPI_io_rank,MPI_num_proc_per_qcomm,&
00043 MPI_num_qcomm,Num_freq_grid,Lower_bound_energy_window,Upper_bound_energy_window,&
00044 flg_cRPA,flg_calc_type,file_num_log_start,file_num_chi_start,file_num_eps_start,&
00045 file_num_chi_base_start,file_num_eps_base_start,n_calc_q 
00046 contains
00047 subroutine read_input(nproc)  
00048 integer::nproc 
00049 integer::ix 
00050 !--
00051 !default
00052 Ecut_for_eps=0.0d0!1/10 of Ecut_for_psi 
00053 Num_freq_grid=70!log grid 
00054 N_CALC_BAND=0!NTB
00055 SHIFT_EF=0.0d0!eV
00056 MAX_EXCITATION_ENERGY=200.0d0!eV 
00057 GREEN_FUNC_DELT=0.1d0!eV
00058 TTRHDRN_DMNA=0.001d0!eV
00059 TTRHDRN_DMNR=0.001d0!eV
00060 MPI_IO_RANK=0!master
00061 MPI_NUM_QCOMM=0!see below
00062 MPI_NUM_PROC_PER_QCOMM=0!see below
00063 LOWER_BOUND_ENERGY_WINDOW=0.0d0!not active
00064 UPPER_BOUND_ENERGY_WINDOW=0.0d0!not active
00065 FLG_CRPA=0!fRPA
00066 FLG_CALC_TYPE=0!all-q-calc
00067 FILE_NUM_LOG_START=400
00068 FILE_NUM_CHI_START=500
00069 FILE_NUM_EPS_START=600
00070 FILE_NUM_CHI_BASE_START=500000
00071 FILE_NUM_EPS_BASE_START=600000
00072 N_CALC_Q=0
00073 !--
00074 !open(999,file='input.in')
00075 !read(999,nml=param_chiqw)
00076 read(5,nml=param_chiqw)
00077 !--
00078 !default mpi setting
00079 if(MPI_num_qcomm==0)then
00080  MPI_num_qcomm=1
00081  MPI_num_proc_per_qcomm=nproc 
00082 endif 
00083 if(MPI_num_qcomm/=0)then
00084  if(mod(nproc,MPI_num_qcomm)/=0)then 
00085   write(6,*)'ERROR: mpi setting wrong'
00086   stop
00087  endif 
00088  MPI_num_proc_per_qcomm=nproc/MPI_num_qcomm 
00089 endif 
00090 !--
00091 if(flg_cRPA==0)then
00092  write(6,*) 
00093  write(6,*)'========================'
00094  write(6,*)'THIS CALCULATION IS fRPA'
00095  write(6,*)'========================'
00096  write(6,*) 
00097 elseif(flg_cRPA==1)then  
00098  write(6,*) 
00099  write(6,*)'========================'
00100  write(6,*)'THIS CALCULATION IS cRPA'
00101  write(6,*)'========================'
00102  write(6,*) 
00103 endif 
00104 !--
00105 if(flg_calc_type==2.and.n_calc_q==0)then!manual mode 
00106  write(6,*)'ERROR: n_calc_q should not be zero'
00107  stop
00108 endif 
00109 !--
00110 if(n_calc_q/=0)then!manual mode 
00111  allocate(calc_num_k(n_calc_q));calc_num_k=0
00112  !read(999,*)(calc_num_k(ix),ix=1,n_calc_q)
00113  read(5,*)(calc_num_k(ix),ix=1,n_calc_q)
00114 else
00115  allocate(calc_num_k(n_calc_q));calc_num_k=0!not use
00116 endif 
00117 !
00118 write(6,nml=param_chiqw) 
00119 delta_ex=Max_excitation_energy 
00120 delt=Green_func_delt 
00121 dmna=ttrhdrn_dmna 
00122 dmnr=ttrhdrn_dmnr  
00123 io_rank=MPI_io_rank 
00124 num_of_mpi_per_comm=MPI_num_proc_per_qcomm 
00125 num_of_comm=MPI_num_qcomm
00126 nen=Num_freq_grid
00127 E_LOWER=Lower_bound_energy_window
00128 E_UPPER=Upper_bound_energy_window
00129 end subroutine
00130 end module

Generated on 17 Nov 2020 for respack by  doxygen 1.6.1