      SUBROUTINE DRRLE(ICORE,MAXCOR,IUHF,RLECYC,LAMBDA)
C
C DRIVER FOR RLE EXTRAPOLATION ROUTINES.
C
CEND
      IMPLICIT INTEGER (A-Z)
      DOUBLE PRECISION R
      LOGICAL NEWT,SINGLE,LAMBDA
      EQUIVALENCE (RLETYP,IFLAGS(21))
      DIMENSION ICORE(MAXCOR)
      COMMON /RMAT/ R(400)
      COMMON /FLAGS/ IFLAGS(100)
      SAVE IBOT
      MAXORD=IFLAGS(12)
      NEWT=.FALSE.
      SINGLE=.FALSE.
      IF(IFLAGS(2).GE.9)SINGLE=.TRUE.
      IF(RLECYC.LE.1)THEN
       CALL RLELST(ICORE,MAXCOR,IUHF,SINGLE,RLETYP)
       CALL ROLLT(ICORE,MAXCOR,IUHF,RLECYC,SINGLE,-1,RLETYP,LAMBDA,
     &            MAXORD)
       IF(RLECYC.EQ.0)THEN
        WRITE(6,1000)RLETYP+1,MAXORD
1000    FORMAT(T3,'@DRRLE-I, RLE method #',I1,' will be used to ',
     &            'accelerate convergence.',/,
     &         T13,'Maximum dimension of iterative subspace is ',I3,'.')
        IBOT=0
        RLECYC=1
       ENDIF
       RETURN
      ENDIF
      CALL ROLLT(ICORE,MAXCOR,IUHF,RLECYC,SINGLE,0,RLETYP,LAMBDA,
     &           MAXORD)
      CALL MAKER(ICORE,MAXCOR,IUHF,RLECYC,MAXORD,IBOT,SINGLE,RLETYP)
      IF(MOD(RLECYC-1,MAXORD).EQ.0.OR.RLETYP.EQ.2.OR.RLETYP.EQ.3)THEN
       NEWT=.TRUE.
       CALL FRMTAU(ICORE,MAXCOR,IUHF,RLECYC,MAXORD,NEWT,IBOT,SINGLE,
     &             RLETYP)
       IF(RLETYP.NE.2.AND.RLETYP.NE.3)THEN
        IBOT=IBOT+RLECYC-1
        RLECYC=1
       ELSE
        IBOT=IBOT
       ENDIF
       RETURN
      ENDIF
      CALL FRMTAU(ICORE,MAXCOR,IUHF,RLECYC,MAXORD,NEWT,IBOT,SINGLE,
     &            RLETYP)
      RETURN
      END
