Commit 6b4fc4ed authored by Uliana Alekseeva's avatar Uliana Alekseeva

optional MPI in init/stepf.F90

parent ebf77e75
MODULE m_setup
USE m_juDFT
CONTAINS
SUBROUTINE setup(atoms,kpts,DIMENSION,sphhar,&
SUBROUTINE setup(mpi,atoms,kpts,DIMENSION,sphhar,&
obsolete,sym,stars,oneD, input,noco,vacuum,cell,xcpot, sliceplot,enpara,l_opti)
!
!----------------------------------------
......@@ -55,6 +55,7 @@
IMPLICIT NONE
! ..
! .. Scalars Arguments ..
TYPE(t_mpi),INTENT(IN) :: mpi
TYPE(t_atoms),INTENT(INOUT) :: atoms
TYPE(t_kpts),INTENT(INOUT) :: kpts
TYPE(t_dimension),INTENT(INOUT):: DIMENSION
......@@ -77,6 +78,7 @@
INTEGER :: ntp1,ii,i,j,n1,n2,na,np1,n
INTEGER, ALLOCATABLE :: lmx1(:), nq1(:), nlhtp1(:)
!
IF ( mpi%irank == 0 ) THEN
IF (sym%namgrp.EQ.'any ') THEN
CALL rw_symfile('R',94,'sym.out',sym%nop,cell%bmat, sym%mrot,sym%tau,sym%nop,sym%nop2,sym%symor)
ELSE
......@@ -173,16 +175,18 @@
CALL prp_xcfft(stars,input, cell, xcpot)
!
ENDIF ! (mpi%irank == 0)
IF (.NOT.sliceplot%iplot) THEN
!
CALL stepf(sym,stars,atoms,oneD, input,cell, vacuum)
CALL stepf(sym,stars,atoms,oneD, input,cell, vacuum,mpi)
!
CALL convn(DIMENSION,atoms,stars)
!
!---> set up electric field parameters (if needed)
!
CALL efield(atoms, DIMENSION, stars, sym, vacuum, cell, input)
IF ( mpi%irank == 0 ) THEN
CALL convn(DIMENSION,atoms,stars)
!
!---> set up electric field parameters (if needed)
!
CALL efield(atoms, DIMENSION, stars, sym, vacuum, cell, input)
ENDIF
ENDIF
END SUBROUTINE setup
......
This diff is collapsed.
......@@ -315,11 +315,13 @@
IF ((sliceplot%iplot).OR.(input%strho).OR.(input%swsp).OR.&
& (input%lflip).OR.(obsolete%l_f2u).OR.(obsolete%l_u2f).OR.(input%l_bmt)) l_opti = .TRUE.
!
END IF ! mpi%irank.eq.0
CALL setup(&
& atoms,kpts,DIMENSION,sphhar,&
& mpi,atoms,kpts,DIMENSION,sphhar,&
& obsolete,sym,stars,oneD,input,noco,&
& vacuum,cell,xcpot,&
& sliceplot,enpara,l_opti)
IF (mpi%irank.EQ.0) THEN
!
stars%ng3=stars%ng3 ; stars%ng2=stars%ng2
!+t3e
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment