Commit 05d9a3b1 authored by Matthias Redies's avatar Matthias Redies

remove dimensions from atom routine

parent 44c4ce6a
...@@ -219,8 +219,7 @@ ...@@ -219,8 +219,7 @@
ENDDO ENDDO
ENDDO ENDDO
IF (xcpot%is_gga()) THEN IF (xcpot%is_gga()) THEN
CALL potl0(xcpot,DIMENSION%msh,input%jspins,input%jspins,n,& CALL potl0(xcpot,input%jspins,atoms%dx(ntyp), rad, rhoss, vxc)
atoms%dx(ntyp), rad, rhoss, vxc)
ELSE ELSE
CALL xcpot%get_vxc(input%jspins,rhoss,vxc,vx) CALL xcpot%get_vxc(input%jspins,rhoss,vxc,vx)
ENDIF ENDIF
......
...@@ -4,7 +4,7 @@ MODULE m_potl0 ...@@ -4,7 +4,7 @@ MODULE m_potl0
! gradients,dens,... only for nonmagnetic. ! gradients,dens,... only for nonmagnetic.
! ****************************************************************** ! ******************************************************************
CONTAINS CONTAINS
SUBROUTINE potl0(xcpot,mshd,jspd,jspins,msh,dx,rad,dens, & SUBROUTINE potl0(xcpot,jspins,dx,rad,dens, &
vxc) vxc)
USE m_grdchlh USE m_grdchlh
...@@ -13,29 +13,30 @@ CONTAINS ...@@ -13,29 +13,30 @@ CONTAINS
IMPLICIT NONE IMPLICIT NONE
CLASS(t_xcpot),intent(in)::xcpot CLASS(t_xcpot),intent(in)::xcpot
INTEGER, INTENT (IN) :: jspins,jspd,mshd,msh INTEGER, INTENT (IN) :: jspins
REAL, INTENT (IN) :: dx REAL, INTENT (IN) :: dx
REAL, INTENT (IN) :: rad(msh),dens(mshd,jspd) REAL, INTENT (IN) :: rad(:),dens(:,:)
REAL, INTENT (OUT):: vxc(mshd,jspd) REAL, INTENT (OUT):: vxc(:,:)
! .. previously untyped names .. ! .. previously untyped names ..
INTEGER,PARAMETER :: ndvgrd=6 INTEGER,PARAMETER :: ndvgrd=6
TYPE(t_gradients)::grad TYPE(t_gradients)::grad
INTEGER i,ispin INTEGER i,ispin,msh
REAL, ALLOCATABLE :: drr(:,:),ddrr(:,:) REAL, ALLOCATABLE :: drr(:,:),ddrr(:,:)
REAL :: vx(mshd,jspd) REAL :: vx(size(rad),jspins)
ALLOCATE ( drr(mshd,jspd),ddrr(mshd,jspd)) msh = size(rad)
ALLOCATE ( drr(msh,jspins),ddrr(msh,jspins))
! !
!--> evaluate gradients of dens. !--> evaluate gradients of dens.
! !
CALL xcpot%alloc_gradients(msh,jspins,grad) CALL xcpot%alloc_gradients(msh,jspins,grad)
DO ispin = 1, jspins DO ispin = 1, jspins
CALL grdchlh(1,1,msh,dx,rad,dens(1,ispin),ndvgrd,& CALL grdchlh(1,1,msh,dx,rad,dens(1:1,ispin),ndvgrd,&
drr(1,ispin),ddrr(1,ispin)) drr(1:1,ispin),ddrr(1:1,ispin))
ENDDO ENDDO
CALL mkgl0(jspins,rad,dens,drr,ddrr,& CALL mkgl0(jspins,rad,dens,drr,ddrr,&
......
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