      FUNCTION CONEW(COND,ELINSY,RELRSD,AVERR,PASTC,PASTRE)
C
C   THIS IS USED IN UPDATING THE VALUE OF THE CONDITION NUMBER
C   IN IEGS.
C
      AVERR=SQRT(ELINSY*PASTRE)
      PASTRE=ELINSY
      IF(RELRSD .EQ. 0.0) GO TO 1
      C=AMAX1(1.0,ELINSY/RELRSD)
      CONEW=SQRT(C*PASTC)
      PASTC=C
      RETURN
1     CONEW=COND
      RETURN
      END
