      real function atdist (coorda, coordb)                             ATDI001
c     routine to determine the distance in space between the two        ATDI002
c     atoms represented by the coordinate arrays.                       ATDI003
c                                                                       ATDI004
c                                                                       ATDI005
c     include 'brkcln.par'                                              ATDI006
c                                                                       ATDI007
      real    coorda(3), coordb(3), dist                                ATDI008
c                                                                       ATDI009
      integer i                                                         ATDI010
c                                                                       ATDI011
      dist = 0.0                                                        ATDI012
      do 200 i = 1, 3                                                   ATDI013
      dist = dist + ((coorda(i) - coordb(i)) ** 2)                      ATDI014
  200 continue                                                          ATDI015
      atdist = sqrt(dist)                                               ATDI016
      end                                                               ATDI017
