quantum-espresso/LR_Modules
degironc 3e6b4f8e76 MAJOR restructuring of the FFTXlib library
In real space processors are organized in a 2D pattern.

Each processor owns data from a sub-set of Z-planes and a sub-set of Y-planes.
In reciprocal space each processor owns Z-columns that belong to a sub set of
X-values. This allows to split the processors in two sets for communication
in the YZ and XY planes.
In alternative, if the situation allows for it, a task group paralelization is used
(with ntg=nyfft) where complete XY planes of ntg wavefunctions are collected and Fourier
trasnformed in G space by different task-groups. This is preferable to the Z-proc + Y-proc
paralleization if task group can be used because a smaller number of larger ammounts of 
data are transferred. Hence three types of fft are implemented: 
 
  !
  !! ... isgn = +-1 : parallel 3d fft for rho and for the potential
  !
  !! ... isgn = +-2 : parallel 3d fft for wavefunctions
  !
  !! ... isgn = +-3 : parallel 3d fft for wavefunctions with task group
  !
  !! ... isgn = +   : G-space to R-space, output = \sum_G f(G)exp(+iG*R)
  !! ...              fft along z using pencils        (cft_1z)
  !! ...              transpose across nodes           (fft_scatter_yz)
  !! ...              fft along y using pencils        (cft_1y)
  !! ...              transpose across nodes           (fft_scatter_xy)
  !! ...              fft along x using pencils        (cft_1x)
  !
  !! ... isgn = -   : R-space to G-space, output = \int_R f(R)exp(-iG*R)/Omega
  !! ...              fft along x using pencils        (cft_1x)
  !! ...              transpose across nodes           (fft_scatter_xy)
  !! ...              fft along y using pencils        (cft_1y)
  !! ...              transpose across nodes           (fft_scatter_yz)
  !! ...              fft along z using pencils        (cft_1z)
  !
  ! If task_group_fft_is_active the FFT acts on a number of wfcs equal to 
  ! dfft%nproc2, the number of Y-sections in which a plane is divided. 
  ! Data are reshuffled by the fft_scatter_tg routine so that each of the 
  ! dfft%nproc2 subgroups (made by dfft%nproc3 procs) deals with whole planes 
  ! of a single wavefunciton.
  !

fft_type module heavily modified, a number of variables renamed with more intuitive names 
(at least to me), a number of more variables introduced for the Y-proc parallelization.

Task_group module made void. task_group management is now reduced to the logical component
 fft_desc%have_task_groups of fft_type_descriptor type variable fft_desc.

In term of interfaces, the 'easy' calling sequences are

SUBROUTINE invfft/fwfft( grid_type, f, dfft, howmany )

  !! where:
  !! 
  !! **grid_type = 'Dense'** : 
  !!   inverse/direct fourier transform of potentials and charge density f
  !!   on the dense grid (dfftp). On output, f is overwritten
  !! 
  !! **grid_type = 'Smooth'** :
  !!   inverse/direct fourier transform of  potentials and charge density f
  !!   on the smooth grid (dffts). On output, f is overwritten
  !! 
  !! **grid_type = 'Wave'** :
  !!   inverse/direct fourier transform of  wave functions f
  !!   on the smooth grid (dffts). On output, f is overwritten
  !!
  !! **grid_type = 'tgWave'** :
  !!   inverse/direct fourier transform of  wave functions f with task group
  !!   on the smooth grid (dffts). On output, f is overwritten
  !!
  !! **grid_type = 'Custom'** : 
  !!   inverse/direct fourier transform of potentials and charge density f
  !!   on a custom grid (dfft_exx). On output, f is overwritten
  !! 
  !! **grid_type = 'CustomWave'** :
  !!   inverse/direct fourier transform of  wave functions f
  !!   on a custom grid (dfft_exx). On output, f is overwritten
  !! 
  !! **dfft = FFT descriptor**, IMPORTANT NOTICE: grid is specified only by dfft.
  !!   No check is performed on the correspondence between dfft and grid_type.
  !!   grid_type is now used only to distinguish cases 'Wave' / 'CustomWave' 
  !!   from all other cases
                                                                                                 

Many more files modified.




git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@13676 c92efa57-630b-4861-b058-cf58834340f0
2017-08-01 20:31:02 +00:00
..
Makefile added LAXlib to the include path of LR_modules 2017-07-30 19:56:06 +00:00
adddvepsi_us.f90 more changes at the smmothing of beta- and q-funcions 2017-07-15 23:16:18 +00:00
adddvscf.f90 Upgrade of the TDDFPT codes using the new logic of the global indices igk_k(1:3,ik) and ngk(ik). 2016-06-12 17:26:36 +00:00
addusdbec.f90 Upgrade of the TDDFPT codes using the new logic of the global indices igk_k(1:3,ik) and ngk(ik). 2016-06-12 17:26:36 +00:00
addusdbec_nc.f90 Upgrade of the TDDFPT codes using the new logic of the global indices igk_k(1:3,ik) and ngk(ik). 2016-06-12 17:26:36 +00:00
apply_dpot.f90 MAJOR restructuring of the FFTXlib library 2017-08-01 20:31:02 +00:00
cft_wave.f90 MAJOR restructuring of the FFTXlib library 2017-08-01 20:31:02 +00:00
cg_psi.f90 cg_psi copied to LR_Modules. 2016-01-20 08:17:10 +00:00
cgsolve_all.f90 Routine computing preconditioning matrix made more general and self-contained. 2016-06-21 08:23:33 +00:00
ch_psi_all.f90 - logical flag have_task_groups removed from FFT type. 2016-07-29 16:37:19 +00:00
commutator_Hx_psi.f90 More removal of I/O of indices 2016-06-04 20:18:02 +00:00
compute_vsgga.f90 Copying the routine compute_vsgga.f90 from PHonon/PH to LR_Modules 2016-02-27 15:30:21 +00:00
dfpt_tetra_mod.f90 Some harmonization of old and new tetrahedra: 2017-01-08 14:14:38 +00:00
dgradcorr.f90 Copying the routine dgradcorr.f90 from PHonon/PH to LR_Modules. 2016-02-20 18:44:17 +00:00
dnonloccorr.f90 Believe it or not, CMPLX(0.d0,0.d0) /= (0.d0,0.d0) : the latter is a double 2017-02-17 13:11:41 +00:00
dv_of_drho.f90 Put the routine dv_of_drho in the module (called dv_of_drho_lr), because it contains an optional array drhoc (response core charge density). Without putting dv_of_drho in the module, the code was stopping (if it was compiled with the XLF compiler (on BG/Q)) when making a check "if (add_nlcc .and. .not.present(drhoc))" in the routine dv_of_drho. Thanks to Lorenzo Paulatto and Paolo Giannozzi for the discussions about how to solve this bug! 2016-05-17 13:58:51 +00:00
dv_rVV10.f90 Believe it or not, CMPLX(0.d0,0.d0) /= (0.d0,0.d0) : the latter is a double 2017-02-17 13:11:41 +00:00
dv_vdW_DF.f90 Believe it or not, CMPLX(0.d0,0.d0) /= (0.d0,0.d0) : the latter is a double 2017-02-17 13:11:41 +00:00
dynmat_sub.f90 Splitting of the program dynmat.f90. 2016-05-04 15:31:48 +00:00
h_prec.f90 Routine computing preconditioning matrix made more general and self-contained. 2016-06-21 08:23:33 +00:00
incdrhoscf.f90 MAJOR restructuring of the FFTXlib library 2017-08-01 20:31:02 +00:00
incdrhoscf_nc.f90 MAJOR restructuring of the FFTXlib library 2017-08-01 20:31:02 +00:00
lr_sm1_psi.f90 more changes at the smmothing of beta- and q-funcions 2017-07-15 23:16:18 +00:00
lrcom.f90 Global variable "eprec" no longer useful, deleted 2016-06-21 10:50:51 +00:00
make.depend UtilXlib directory created to contain a library (libutil.a) for 2017-07-26 11:15:20 +00:00
newdq.f90 fdef preprocessor macro refactoring (LR_Modules) 2016-09-17 14:36:58 +00:00
orthogonalize.f90 Optimized tetrahedra for DFPT, contributed by Mitsuaki Kawamura 2016-12-23 12:49:16 +00:00
qdipol_cryst.f90 Copying the routine qdipol_cryst.f90 from PHonon/PH to LR_Modules 2016-02-28 13:09:03 +00:00
set_dbecsum_nc.f90 set_dbecsum_nc and set_int3_nc extracted from PHonon/PH/set_int12_nc.f90 and moved to LR_Modules as separated files 2016-01-22 03:00:30 +00:00
set_int3_nc.f90 set_dbecsum_nc and set_int3_nc extracted from PHonon/PH/set_int12_nc.f90 and moved to LR_Modules as separated files 2016-01-22 03:00:30 +00:00
setqmod.f90 Copying the routine setqmod.f90 from PHonon/PH to LR_Modules 2016-02-28 14:04:50 +00:00
setup_alpha_pv.f90 Optimized tetrahedra for DFPT, contributed by Mitsuaki Kawamura 2016-12-23 12:49:16 +00:00
setup_dgc.f90 Copying the routine setup_dgc.f90 from PHonon/PH to LR_Modules 2016-02-27 15:29:02 +00:00
setup_dmuxc.f90 Moved a part of the PHonon code (which computes the derivative of the XC potential) 2016-02-27 16:33:33 +00:00
setup_nbnd_occ.f90 Optimized tetrahedra for DFPT, contributed by Mitsuaki Kawamura 2016-12-23 12:49:16 +00:00
setup_nscf.f90 Cleanup of unused variables 2017-01-23 15:46:28 +00:00
smallgq.f90 moving small group of q routine to LR_Modules 2016-01-20 16:05:38 +00:00