      subroutine fndcal(itarg,isel,indx,istat)
      implicit double precision (a-h,p-x),integer (i-n),logical (o)
      parameter (numcal=5000)
      parameter (mxchai=50)
      parameter (mxheta=50)
      parameter (mxres=42)
      integer reson
      common /calf/ icalf(6,numcal),ncalf,ianf(mxchai),islu(mxchai),
     &              nchain,iamino(numcal),iamicl(mxres),ihet(mxheta),
     &              iclhet(mxheta),reson(numcal),issdon

      istat = 1
      do i=1,ncalf
         if (icalf(isel,i).eq.itarg) then
            indx = i
            return
         endif
      end do
      istat = 0
      return
      end
