Commit 9aebf13d authored by Matteo Gerosa's avatar Matteo Gerosa
Browse files

Resolved compilation issues: declared missing variables, added correct dependencies, etc.

parent a66d1d9f
......@@ -359,7 +359,7 @@ SUBROUTINE dfpt_q (m,dvg,dng,tr2,iq)
USE io_push, ONLY : io_push_title
USE mp_world, ONLY : mpime,world_comm
USE class_bz_grid, ONLY : bz_grid
USE types_bz_grid, ONLY : q_grid, compute_phase
USE types_bz_grid, ONLY : k_grid, q_grid, compute_phase
!
IMPLICIT NONE
!
......@@ -386,7 +386,7 @@ SUBROUTINE dfpt_q (m,dvg,dng,tr2,iq)
! Current k-q point
INTEGER :: npwkq
!
REAL(DP) :: kmq(3), g0(3)
REAL(DP) :: kmq(3), g0(3), kk(3), qq(3)
REAL(DP) :: anorm, prod
REAL(DP), ALLOCATABLE :: eprec(:)
! Preconditioning matrix
......@@ -421,18 +421,18 @@ SUBROUTINE dfpt_q (m,dvg,dng,tr2,iq)
!
dng=0.0_DP
!
CALL start_bar_type( barra, 'dfpt_q', MAX(m,1) * nks )
CALL start_bar_type( barra, 'dfpt_q', MAX(m,1) * k_grid%nps )
!
ALLOCATE( evckmq(npwx*npol,nbnd) )
ALLOCATE( phase(dffts%nnr) )
!
DO iks = 1, nks ! KPOINT-SPIN LOOP
DO iks = 1, k_grid%nps ! KPOINT-SPIN LOOP
!
ik = k_grid%ip(iks)
!
current_k = iks
!
k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, 'cart' )
CALL k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, "cart" )
ikqs = k_grid%find( kmq, 'cart' )
!ikqs = kmq_grid%index_kq(iks,iq)
!
......
......@@ -81,7 +81,7 @@ MODULE class_bz_grid
CASE ( 'K', 'k')
!
this%ngrid(1:3) = (/ nk1, nk2, nk3 /)
this%np = this%np(1) * this%np(2) * this%np(3)
this%np = this%ngrid(1) * this%ngrid(2) * this%ngrid(3)
this%ns = nspin
this%nps = nkstot ! = np * ns
!
......@@ -107,7 +107,7 @@ MODULE class_bz_grid
CASE ( 'Q', 'q')
!
this%ngrid(1:3) = nq(1:3)
this%np = nq(1) * nq(2) * nq(3)
this%np = this%ngrid(1) * this%ngrid(2) * this%ngrid(3)
this%ns = 1
this%nps = this%np
!
......@@ -145,8 +145,8 @@ MODULE class_bz_grid
!
! generate map ips --> ip and is
!
ip = 0
is = 0
this%ip = 0
this%is = 0
k = 0
DO i = 1, this%ns
DO j = 1, this%np
......@@ -156,9 +156,9 @@ MODULE class_bz_grid
ENDDO
ENDDO
!
ALLOCATE( this%l_pIsGamma(grid%np) )
ALLOCATE( this%l_pIsGamma(this%np) )
this%l_pIsGamma(:)=.FALSE.
DO ip = 1, grid%np
DO ip = 1, this%np
this%l_pIsGamma(ip) = ( ALL( ABS ( this%p_cryst(:,ip) ) .LT. eps8 ) )
ENDDO
!
......@@ -214,6 +214,8 @@ MODULE class_bz_grid
! ... pout = pin1 + pin2 - g0 ( g0 makes sure that pout is in 1BZ )
! ... unit_type determines the units of pin1, pin2 and pout, g0
!
USE cell_base, ONLY : at, bg
!
IMPLICIT NONE
!
! I/O
......@@ -247,8 +249,7 @@ MODULE class_bz_grid
CALL cryst_to_cart( 1, g0 , bg, 1 )
ENDIF
!
! g0 is in cart
!
END SUBROUTINE
! !
! IF ( sig == +1 ) THEN
! csig = '+'
......@@ -338,8 +339,8 @@ MODULE class_bz_grid
! !
! DEALLOCATE( new_ikq, temp_index_ikq )
! DEALLOCATE( temp_xkq, temp_wkq )
!
END SUBROUTINE
! !
! END SUBROUTINE
!
!
! SUBROUTINE q_grid_init( qgrid, kgrid, k1grid )
......
......@@ -37,7 +37,8 @@ SUBROUTINE do_setup
USE westcom, ONLY : logfile
USE mp_world, ONLY : mpime, root
USE class_bz_grid, ONLY : bz_grid
USE types_bz_grid, ONLY : k_grid, q_grid, kmq_grid, kpq_grid
USE types_bz_grid, ONLY : k_grid, q_grid
!USE types_bz_grid, ONLY : k_grid, q_grid, kmq_grid, kpq_grid
!
IMPLICIT NONE
!
......@@ -69,7 +70,6 @@ SUBROUTINE do_setup
!
! INIT Q GRID
!
! initialize q-point grid
q_grid = bz_grid()
CALL q_grid%init('Q')
IF ( ANY ( q_grid%ngrid(:) - k_grid%ngrid(:) /= 0 ) ) THEN
......@@ -222,7 +222,7 @@ SUBROUTINE do_setup
IF( mpime == root ) CALL json%add('system.kpt.k('//TRIM(ADJUSTL(cik))//').weight',k_grid%weight(iks))
ENDDO
WRITE( stdout, '(/23x,"cryst. coord.")')
DO ik = 1, k_grid%nps
DO iks = 1, k_grid%nps
ik = k_grid%ip(iks)
WRITE( cik, '(i6)') ik
WRITE( stdout, '(8x,"k(",i5,") = (",3f12.7,"), wk =",f12.7)') &
......
......@@ -8,12 +8,13 @@
! This file is part of WEST.
!
! Contributors to this file:
! Matteo Gerosa
! Marco Govoni, Matteo Gerosa
!
!-----------------------------------------------------------------------
MODULE types_bz_grid
!-----------------------------------------------------------------------
!
USE kinds, ONLY : DP
USE class_bz_grid, ONLY : bz_grid
!
IMPLICIT NONE
......@@ -28,13 +29,14 @@ MODULE types_bz_grid
CONTAINS
!
!
FUNCTION findG(g0, unit_type) RETURN(ig0)
FUNCTION findG(g0, unit_type) RESULT(ig0)
!
! ... ig0 is the index of G (unit_type = [ "cryst", "cart"])
! ... if on exit ig0 == 0 --> G is not found
!
USE cell_base, ONLY : bg
USE gvecs, ONLY : g, ngms
USE gvecs, ONLY : ngms
USE gvect, ONLY : g
USE constants, ONLY : eps8
!
IMPLICIT NONE
......@@ -62,7 +64,7 @@ MODULE types_bz_grid
!
ig0 = 0
DO ig = 1, ngms
IF ( ALL ( ABS( g(:,ig) - g0(:) ) < eps8 ) ) THEN
IF ( ALL ( ABS( g(:,ig) - gtemp(:) ) < eps8 ) ) THEN
ig0 = ig
ENDIF
ENDDO
......@@ -102,7 +104,8 @@ MODULE types_bz_grid
phase = (0._DP, 0._DP)
phase( nls(ig0) ) = (1._DP, 0._DP)
!
! phase = exp(-iG_0*r)
! phase(r) = exp(-iG_0*r)
!
CALL invfft( 'Wave', phase, dffts )
phase(1:dffts%nnr) = DCONJG( phase(1:dffts%nnr) )
!
......
......@@ -295,7 +295,7 @@ SUBROUTINE calc_corr_k( sigma_corr, energy, l_verbose)
!
DO iq = 1, q_grid%np ! Q-POINT
!
k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, 'cart' )
CALL k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, 'cart' )
ikqs = k_grid%find( kmq, 'cart' )
!ikqs = kmq_grid%index_kq(iks,iq)
l_gammaq = q_grid%l_pIsGamma(iq)
......@@ -379,7 +379,7 @@ SUBROUTINE calc_corr_k( sigma_corr, energy, l_verbose)
!
DO iq = 1, q_grid%np
!
k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, 'cart' )
CALL k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, 'cart' )
ikqs = k_grid%find( kmq, 'cart' )
!ikqs = kmq_grid%index_kq(iks,iq)
l_gammaq = q_grid%l_pIsGamma(iq)
......
......@@ -266,7 +266,7 @@ SUBROUTINE calc_exx2_k( sigma_exx, nb1, nb2 )
COMPLEX(DP), ALLOCATABLE :: evckmq(:,:), phase(:)
REAL(DP), EXTERNAL :: DDOT
COMPLEX(DP), EXTERNAL :: ZDOTC
INTEGER :: ib,iv,i1,ir,iks,ig,iv_glob,iq,ikqs
INTEGER :: ib,iv,i1,ir,iks,ik,ig,iv_glob,iq,ikqs
INTEGER :: nbndval
INTEGER :: npwkq
TYPE(idistribute) :: vband
......@@ -373,7 +373,7 @@ SUBROUTINE calc_exx2_k( sigma_exx, nb1, nb2 )
!
l_gammaq = q_grid%l_pIsGamma(iq)
!
k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, 'cart' )
CALL k_grid%add( k_grid%p_cart(:,ik), -q_grid%p_cart(:,iq), kmq, g0, 'cart' )
ikqs = k_grid%find( kmq, 'cart' )
!ikqs = kmq_grid%index_kq(iks,iq)
!
......@@ -415,7 +415,7 @@ SUBROUTINE calc_exx2_k( sigma_exx, nb1, nb2 )
DO ig = 1,ngms
pertg(ig) = pertg(ig) * mysqvc(ig)
ENDDO
sigma_exx( ib, iks ) = sigma_exx( ib, iks ) - peso * DDOT( 2*ngms, pertg(1), 1, pertg(1), 1) / omega * q_grid%weight(iq)
sigma_exx( ib, iks ) = sigma_exx( ib, iks ) - peso * DDOT( 2*ngms, pertg(1), 1, pertg(1), 1)/omega*q_grid%weight(iq)
!IF(gstart==2) sigma_exx( ib, iks ) = sigma_exx( ib, iks ) + REAL( pertg(1), KIND = DP )**2 / omega
IF( ib == iv_glob .AND. gstart == 2 .AND. l_gammaq ) sigma_exx( ib, iks ) = sigma_exx( ib, iks ) - mydiv
!
......
......@@ -367,7 +367,7 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
USE wfreq_restart, ONLY : solvegfreq_restart_write,solvegfreq_restart_read,bks_type
USE wfreq_io, ONLY : writeout_overlap,writeout_solvegfreq,preallocate_solvegfreq_q
USE class_bz_grid, ONLY : bz_grid
USE types_bz_grid, ONLY : k_grid
USE types_bz_grid, ONLY : k_grid, q_grid, compute_phase
!
IMPLICIT NONE
!
......@@ -377,13 +377,14 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
!
! Workspace
!
INTEGER :: i1,i2,i3,ip,ig,glob_ip,ir,ib,iv,iv_glob,iks,m,im,ikks,iq,il
INTEGER :: i1,i2,i3,ip,ig,glob_ip,ir,ib,iv,iv_glob,iks,ik,m,im,ikks,ikk,iq,il
INTEGER :: npwk
CHARACTER(LEN=512) :: fname
CHARACTER(LEN=6) :: my_label_b
CHARACTER(LEN=5) :: my_label_q
COMPLEX(DP),ALLOCATABLE :: auxr(:)
INTEGER :: nbndval
REAL(DP) :: q(3), g0(3)
REAL(DP),ALLOCATABLE :: diago( :, : ), subdiago( :, :), bnorm(:)
COMPLEX(DP),ALLOCATABLE :: braket(:, :, :)
COMPLEX(DP),ALLOCATABLE :: q_s( :, :, : )
......@@ -400,7 +401,7 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
REAL(DP) :: time_spent(2)
REAL(DP),EXTERNAL :: get_clock
TYPE(bks_type) :: bks
TYPE(bz_grid) :: k1_grid, q_grid_aux
!TYPE(bz_grid) :: k1_grid, q_grid_aux
!
CALL io_push_title("(G)-Lanczos")
!
......@@ -430,18 +431,18 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
ENDIF
ALLOCATE( phase(dffts%nnr) )
!
k1_grid = bz_grid()
CALL k1_grid%init('K')
!
q_grid_aux = bz_grid()
CALL q_grid_aux%init_q( k_grid, k1_grid )
!k1_grid = bz_grid()
!CALL k1_grid%init('K')
!!
!q_grid_aux = bz_grid()
!CALL q_grid_aux%init_q( k_grid, k1_grid )
!
barra_load = 0
DO ikks = 1, k_grid%nps
IF(ikks<bks%lastdone_ks) CYCLE
DO ib = qp_bandrange(1), qp_bandrange(2)
IF(ikks==bks%lastdone_ks .AND. ib < bks%lastdone_band ) CYCLE
DO iks = 1, k1_grid%nps
DO iks = 1, k_grid%nps
IF (ikks==bks%lastdone_ks .AND. ib == bks%lastdone_band .AND. iks <= bks%lastdone_ki) CYCLE
barra_load = barra_load + 1
ENDDO
......@@ -462,6 +463,7 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
!
DO ikks = 1, k_grid%nps ! KPOINT-SPIN (MATRIX ELEMENT)
IF(ikks<bks%lastdone_ks) CYCLE
ikk = k_grid%ip(ikks)
!
npwk = ngk(ikks)
!
......@@ -489,12 +491,15 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
CALL single_invfft_k(dffts,npwk,npwx,evck(1,ib),psick,'Wave',igk_k(1,ikks))
ENDIF
!
DO iks = 1, k1_grid%nps ! KPOINT-SPIN (INTEGRAL OVER K')
DO iks = 1, k_grid%nps ! KPOINT-SPIN (INTEGRAL OVER K')
IF (ikks==bks%lastdone_ks .AND. ib==bks%lastdone_band .AND. iks <= bks%lastdone_ki) CYCLE
ik = k_grid%ip(iks)
!
time_spent(1) = get_clock( 'glanczos' )
!
iq = q_grid_aux%index_q(ikks,iks)
CALL k_grid%add( k_grid%p_cart(:,ikk), -k_grid%p_cart(:,ik), q, g0, 'cart' )
iq = q_grid%find( q, 'cart' )
!iq = q_grid_aux%index_q(ikks,iks)
!
CALL preallocate_solvegfreq_q( iks_l2g(ikks), iks_l2g(iks), qp_bandrange(1), qp_bandrange(2), pert)
!
......@@ -502,7 +507,7 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
!
! compute Coulomb potential
!
IF ( q_grid_aux%l_gammap(iq) ) THEN
IF ( q_grid%l_pIsGamma(iq) ) THEN
CALL store_sqvc(sqvc,npwq,1,isz,.FALSE.)
ELSE
CALL store_sqvc_q(sqvc,npwq,1,iq,.TRUE.)
......@@ -539,8 +544,9 @@ SUBROUTINE solve_gfreq_k(l_read_restart)
! !
! CALL init_us_2 (npw, igk, xk (1, iks), vkb)
!
CALL q_grid_aux%get_phase(ikks,iks)
phase = q_grid_aux%phase
CALL compute_phase( g0, 'cart', phase )
!CALL q_grid_aux%get_phase(ikks,iks)
!phase = q_grid_aux%phase
!
IF ( my_image_id == 0 ) CALL get_buffer( evc, lrwfc, iuwfc, iks )
CALL mp_bcast( evc, 0, inter_image_comm )
......
......@@ -214,14 +214,14 @@ SUBROUTINE solve_hf_k( )
IF( l_enable_gwetot) THEN
!
nbndval = MIN( MAXVAL( nbnd_occ(:) ), nbnd )
ALLOCATE(sigma_exx_all_occupied(nbndval,nks))
ALLOCATE(sigma_exx_all_occupied(nbndval,k_grid%nps))
!
CALL calc_exx2_k( sigma_exx_all_occupied, 1, nbndval )
!
exx_etot = 0._DP
DO iks = 1, nks
DO iks = 1, k_grid%nps
DO ib = 1, nbnd_occ(iks)
exx_etot = exx_etot + sigma_exx_all_occupied( ib, iks) * wk(iks) / 2._DP
exx_etot = exx_etot + sigma_exx_all_occupied( ib, iks) * k_grid%weight(iks) / 2._DP
ENDDO
ENDDO
!
......
......@@ -587,7 +587,7 @@ SUBROUTINE solve_qp_k(l_secant,l_generate_plot)
USE wfreq_io, ONLY : readin_overlap,readin_solvegfreq,readin_solvehf
USE wfreq_db, ONLY : wfreq_db_write
USE class_bz_grid, ONLY : bz_grid
USE types_bz_grid, ONLY : k_grid
USE types_bz_grid, ONLY : k_grid, q_grid
!
IMPLICIT NONE
!
......@@ -606,7 +606,8 @@ SUBROUTINE solve_qp_k(l_secant,l_generate_plot)
REAL(DP),ALLOCATABLE :: en(:,:,:)
LOGICAL,ALLOCATABLE :: l_conv(:,:)
REAL(DP),PARAMETER :: eshift = 0.007349862_DP ! = 0.1 eV
INTEGER :: k, ib, iks, ikks, iq, ifixed, ip, glob_ip, ifreq, il, im, glob_im, glob_jp, glob_ifreq
INTEGER :: k, ib, iks, ik, ikks, ikk, iq, ifixed, ip, glob_ip, ifreq, il, im, glob_im, glob_jp, glob_ifreq
REAL(DP) :: q(3), g0(3)
REAL(DP),ALLOCATABLE :: out_tab(:,:)
CHARACTER(LEN=5) :: myglobk
CHARACTER(LEN=6) :: cifixed
......@@ -624,17 +625,17 @@ SUBROUTINE solve_qp_k(l_secant,l_generate_plot)
CHARACTER(LEN=5) :: ib_label, iks_label
INTEGER,ALLOCATABLE :: un(:,:)
REAL(DP) :: summed_sf
TYPE(bz_grid) :: k1_grid, q_grid_aux
!TYPE(bz_grid) :: k1_grid, q_grid_aux
!
CALL start_clock('solve_qp')
!
ALLOCATE( imfreq_list_integrate( 2, ifr%nloc ) )
ALLOCATE( dtemp( n_imfreq ) )
!
k1_grid = bz_grid()
CALL k1_grid%init('K')
q_grid_aux = bz_grid()
CALL q_grid_aux%init_q( k_grid, k1_grid )
!k1_grid = bz_grid()
!CALL k1_grid%init('K')
!q_grid_aux = bz_grid()
!CALL q_grid_aux%init_q( k_grid, k1_grid )
!
dtemp = 0._DP
DO ifreq = 1, ifr%nloc
......@@ -663,11 +664,11 @@ SUBROUTINE solve_qp_k(l_secant,l_generate_plot)
!
! TEMP
!
ALLOCATE( z_body1_ifr_q( aband%nloc, ifr%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid_aux%nps ) )
ALLOCATE( z_body_rfr_q( aband%nloc, rfr%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid_aux%nps ) )
ALLOCATE( z_body1_ifr_q( aband%nloc, ifr%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid%nps ) )
ALLOCATE( z_body_rfr_q( aband%nloc, rfr%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid%nps ) )
IF( l_enable_lanczos ) THEN
ALLOCATE( z_body2_ifr_q( n_lanczos, pert%nloc, ifr%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid_aux%nps ) )
ALLOCATE( d_diago_q( n_lanczos, pert%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid_aux%nps ) )
ALLOCATE( z_body2_ifr_q( n_lanczos, pert%nloc, ifr%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid%nps ) )
ALLOCATE( d_diago_q( n_lanczos, pert%nloc, qp_bandrange(1):qp_bandrange(2), k_grid%nps, q_grid%nps ) )
ENDIF
!
z_body1_ifr_q = 0._DP
......@@ -681,24 +682,28 @@ SUBROUTINE solve_qp_k(l_secant,l_generate_plot)
!
CALL io_push_title("Collecting results from W and G")
!
barra_load = k_grid%nps * ( qp_bandrange(2) - qp_bandrange(1) + 1 ) * q_grid_aux%nps
barra_load = k_grid%nps * ( qp_bandrange(2) - qp_bandrange(1) + 1 ) * q_grid%nps
CALL start_bar_type( barra, 'coll_gw', barra_load )
!
! LOOP
!
! outer k-point loop (matrix element): iks
! inner k-point loop (sum over k'): ikks
! WARNING: iks and ikks are switched w.r.t. convention used in solve_gfreq_k
! WARNING: iks and ikks are switched w.r.t. solve_gfreq_k
!
DO iks = 1, k_grid%nps ! KPOINT-SPIN (MATRIX ELEMENT)
ik = k_grid%ip(iks)
!
nbndval = nbnd_occ(iks)
!
DO ib = qp_bandrange(1), qp_bandrange(2)
!
DO ikks = 1, k1_grid%nps ! KPOINT-SPIN (INTEGRAL OVER K')
DO ikks = 1, k_grid%nps ! KPOINT-SPIN (INTEGRAL OVER K')
ikk = k_grid%ip(ikks)
!
iq = q_grid_aux%index_q(iks,ikks)
CALL k_grid%add( k_grid%p_cart(:,ik), -k_grid%p_cart(:,ikk), q, g0, 'cart' )
iq = q_grid%find( q, 'cart' )
!iq = q_grid_aux%index_q(iks,ikks)
!
IF(ALLOCATED(overlap)) DEALLOCATE(overlap)
ALLOCATE(overlap(pert%nglob, nbnd ) )
......
......@@ -638,7 +638,7 @@ SUBROUTINE solve_wfreq_k(l_read_restart,l_generate_plot)
USE class_idistribute, ONLY : idistribute
USE wfreq_restart, ONLY : solvewfreq_restart_write,solvewfreq_restart_read,bks_type
USE class_bz_grid, ONLY : bz_grid
USE types_bz_grid, ONLY : k_grid, q_grid
USE types_bz_grid, ONLY : k_grid, q_grid, compute_phase
!
IMPLICIT NONE
!
......@@ -648,7 +648,7 @@ SUBROUTINE solve_wfreq_k(l_read_restart,l_generate_plot)
!
! Workspace
!
INTEGER :: i1,i2,i3,im,ip,ig,glob_ip,ir,iv,iks,iq,ikqs,ipol,m
INTEGER :: i1,i2,i3,im,ip,ig,glob_ip,ir,iv,iks,ik,iq,ikqs,ipol,m
CHARACTER(LEN=512) :: fname
CHARACTER(LEN=6) :: my_label_b
CHARACTER(LEN=5) :: my_label_q
......@@ -813,12 +813,14 @@ SUBROUTINE solve_wfreq_k(l_read_restart,l_generate_plot)
! !
! CALL init_us_2 (npw, igk, xk (1, iks), vkb)
!
ikqs = kpq_grid%index_kq(iks,iq)
npwkq = ngk(ikqs)
!ikqs = kpq_grid%index_kq(iks,iq)
!npwkq = ngk(ikqs)
!
k_grid%add( k_grid%p_cart(:,ik), q_grid%p_cart(:,iq), kpq, g0, 'cart' )
CALL k_grid%add( k_grid%p_cart(:,ik), q_grid%p_cart(:,iq), kpq, g0, 'cart' )
ikqs = k_grid%find( kpq, 'cart' )
!
npwkq = ngk(ikqs)
!
CALL compute_phase( g0, 'cart', phase )
!!
!! computes the phase needed to bring the wavefunction at k+q
......
......@@ -514,7 +514,7 @@ MODULE wstat_restart
IF ( iq == lastdone_iq ) THEN
WRITE(stdout,'(1/, 5x,"[I/O] -------------------------------------------------------------------")')
WRITE( stdout, '(5x,"[I/O] Restarting from q(",i5,") = (",3f12.7,")")') &
lastdone_iq, (q_grid%xp_cryst(ipol,lastdone_iq) , ipol = 1, 3)
lastdone_iq, (q_grid%p_cryst(ipol,lastdone_iq) , ipol = 1, 3)
WRITE(stdout, "(5x, '[I/O] RESTART read in ',a20)") human_readable_time(time_spent(2)-time_spent(1))
WRITE(stdout, "(5x, '[I/O] In location : ',a)") TRIM( wstat_restart_dir )
WRITE(stdout,'(5x,"[I/O] -------------------------------------------------------------------")')
......
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