      function distabs(nd,v1,v2) ! bernd berg june 26 2005.
c distance between two points (given by the vectors v1 and v2) in
c the absolute value norm.
      include '../../libs/fortran/implicit.sta'  
      include '../../libs/fortran/constants.par'
      dimension v1(nd),v2(nd)
      distabs=zero
      do id=1,nd
        distabs=distabs+abs(v2(id)-v1(id))
      enddo
      return
      end
