      REAL FUNCTION LNDIF(A,C)
C LNDIF COMPUTES LN(GAMMA(A+C))-LN(GAMMA(A)) WHERE GAMMA IS THE GAMMA
C FUNCTION. IT IS ASSUMED THAT A IS GREATER THAN 100.
      DIMENSION CCC(2)
      DATA THIRD/.33333333333333/
      DATA CONST/-.83333333333333E-1/
      DATA CCC(1)/.27777777777777E-2/,CCC(2)/-.79365079365079E-3/
      THETA=C/A
      TEMP1=THETA+2.0
      Y=THETA/TEMP1
      YSQ=Y*Y
      IF(.15.LT.THETA)GO TO 1
      I=4
      GO TO 2
    1 I=9
    2 SUM=THIRD
      TERM=THIRD
      DO 3 N=1,I
      TEMP=2*N+1
      TERM=TEMP/(TEMP+2.0)*YSQ*TERM
    3 SUM=SUM+TERM
      TEMP1=SUM*YSQ*2.0/TEMP1-Y
      Y=-THETA/2.0
      TEMP1=TEMP1*(Y+C)+Y
      Y=A+C
      TEMP1=TEMP1+C*ALOG(Y)
      THETA=1./A
      TEMP=THETA*THETA
      Y=1./Y
      YSQ=Y*Y
      TEMP1=TEMP1+(THETA-Y)*CONST
      DO 4 I=1,2
      THETA=THETA*TEMP
      Y=Y*YSQ
       TEMP1=TEMP1+(THETA-Y)*CCC(I)
    4  CONTINUE
      LNDIF=TEMP1
      RETURN
      END
