anchor.diff:  *
   c      INCLUDE 'implicit.inc'
   c      INCLUDE 'mxpdim.inc'
  +	  
         INCLUDE 'wrkspc.inc'
         INCLUDE 'clunit.inc'
         INCLUDE 'crun.inc'
  
positive.code:       DO IFRZ_T = 1, NFRZ_ORB
          IFRZ_S = IREOTS(IFRZ_ORB(IFRZ_T))
  C            ICOPVE3(IIN,IOFFIN,IOUT,IOFFOUT,NDIM)
          CALL ICOPVE3(IFRZ_S,1,WORK(KLFRZS),IFRZ_T,1)
        END DO
  *
        IF(NTEST.GE.10) THEN
          WRITE(6,*) ' Frozen orbitals in symmetry numbering '
          CALL IWRTMA(WORK(KLFRZS),1,NFRZ_ORB,1,NFRZ_ORB)
        END IF
  *. And orthonormalize
  C     ORT_MOS_TO_SELECTED_MOS(CMOAO,NORT,IORT)
        CALL ORT_MOS_TO_SELECTED_MOS(CMOAO,NFRZ_ORB,WORK(KLFRZS))
  *
        IF(NTEST.GE.100) THEN 
          WRITE(6,*) ' Orbitals orthogonalized to frozen '
  
negative.code: *. And a scratch matrix 
        CALL MEMMAN(KLSCR,LENM,'ADDL  ',2,'SCRM  ')
  *. Obtain density matrix in initial basis
        CALL GET_D_INI_FROM_C(dbl_mb(KLDINI),C,IHOLETP)
  *. Contract with two-electron integrals
        FACC = 1.0D0
        FACE = 0.5D0
  C     TWO_INT_D_TERM_F(F2,DINI,FACC,FACE)
        CALL MEMCHK2('BE_TWO')
        CALL TWOINT_D_TERM_F(F2,dbl_mb(KLDINI),FACC,FACE)
        CALL MEMCHK2('AF_TWO')
  *. Transform from initial to current basis
  C     TRAN_SYM_BLOC_MAT4
  C    &(AIN,XL,XR,NBLOCK,LX_ROW,LX_COL,AOUT,SCR,ISYM)
        CALL MEMCHK2('BE_TRA')
        CALL TRAN_SYM_BLOC_MAT4(F2,C,C,NSMOB,NTOOBS,NTOOBS,
       &     dbl_mb(KLSCR),dbl_mb(KLDINI),0)
        CALL MEMCHK2('AF_TRA')
        CALL COPVEC(dbl_mb(KLSCR),F2,LEN_F)
  *
        IF(NTEST.GE.100) THEN
          WRITE(6,*) ' Output from GET_2E_TERMS '
  