diff --git a/source/final.f b/source/final.f index 75f1341e..7e55fe90 100644 --- a/source/final.f +++ b/source/final.f @@ -1166,6 +1166,8 @@ subroutine final if (allocated(mvdw)) deallocate (mvdw) if (allocated(ired)) deallocate (ired) if (allocated(kred)) deallocate (kred) + if (allocated(radvdw)) deallocate (radvdw) + if (allocated(epsvdw)) deallocate (epsvdw) if (allocated(radmin)) deallocate (radmin) if (allocated(epsilon)) deallocate (epsilon) if (allocated(radmin4)) deallocate (radmin4) diff --git a/source/kvdw.f b/source/kvdw.f index a470767b..e269f959 100644 --- a/source/kvdw.f +++ b/source/kvdw.f @@ -278,6 +278,8 @@ subroutine kvdw if (allocated(xred)) deallocate (xred) if (allocated(yred)) deallocate (yred) if (allocated(zred)) deallocate (zred) + if (allocated(radvdw)) deallocate (radvdw) + if (allocated(epsvdw)) deallocate (epsvdw) allocate (ivdw(n)) allocate (jvdw(n)) allocate (mvdw(maxtyp)) @@ -286,6 +288,8 @@ subroutine kvdw allocate (xred(n)) allocate (yred(n)) allocate (zred(n)) + allocate (radvdw(n)) + allocate (epsvdw(n)) c c perform dynamic allocation of some local arrays c @@ -547,6 +551,18 @@ subroutine kvdw end if end do c +c set vdw radii and well depth for each individual atom +c + do i = 1, n + if (vdwindex .eq. 'TYPE') then + ia = type(i) + else + ia = class(i) + end if + radvdw(i) = rad(ia) + epsvdw(i) = eps(ia) + end do +c c apply radii and well depths for special atom class pairs c do i = 1, maxnvp diff --git a/source/vdw.f b/source/vdw.f index 773ddd68..5a28caab 100644 --- a/source/vdw.f +++ b/source/vdw.f @@ -21,6 +21,8 @@ c xred reduced x-coordinate for each atom in the system c yred reduced y-coordinate for each atom in the system c zred reduced z-coordinate for each atom in the system +c radvdw van der Waals radius for each atom in the system +c epsvdw van der Waals well depth for each atom in the system c radmin minimum energy distance for each atom class pair c epsilon well depth parameter for each atom class pair c radmin4 minimum energy distance for 1-4 interaction pairs @@ -40,6 +42,8 @@ module vdw real*8, allocatable :: xred(:) real*8, allocatable :: yred(:) real*8, allocatable :: zred(:) + real*8, allocatable :: radvdw(:) + real*8, allocatable :: epsvdw(:) real*8, allocatable :: radmin(:,:) real*8, allocatable :: epsilon(:,:) real*8, allocatable :: radmin4(:,:)