points.f 772 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34
      MODULE m_points
      CONTAINS
      SUBROUTINE points(x,n)
c     *********************************************************
c     generate random points, in internal coordinates,
c     within the unit cell omega-tilda
c     *********************************************************
      USE m_qranf
      IMPLICIT NONE
C     .. Scalar Arguments ..
      INTEGER n
C     ..
C     .. Array Arguments ..
      REAL x(3,n)
C     ..
C     .. Local Scalars ..
      REAL r
      INTEGER i,j
C     ..

C     ..
C     .. Intrinsic Functions ..
      INTRINSIC sqrt
C     ..
      r = sqrt(13.)
      j = 1
      DO  i = 1,n
         x(1,i) = qranf(r,j)
         x(2,i) = qranf(r,j)
         x(3,i) = qranf(r,j) - 0.5
      ENDDO
      RETURN
      END SUBROUTINE
      END