anchor.diff:  * ===========================
   * Info on configurations, etc
   * ===========================
  +*
  +      IF(NOCSF.EQ.0.AND.ICNFBAT.EQ.1) THEN
  +*
  +*. Generate the configurations and order them according
  +*. to number of open orbitals
  +*
  +        CALL GEN_CONF_FOR_CISPC(WORK(KCIOCCLS_ACT),NCOCCLS_ACT,ISM,
  +     &       WORK(KIOCCLS))
  +*. The output are delivered in pointers set in GEN_CONF_FOR_CISPC
  +*         Occupations: KICONF_OCC(ISYM)
  +*         Reorder arrays: KICONF_REO(1) (independent of symmetry)
  +*. And then the reordering of the SD's
  +*. The reordering arrays for the SD's are stored in KSDREO_I((ISM)
  +C       WRITE(6,*) ' KSDREO_I(ISM) = ', KSDREO_I(ISM)
  +        CALL CNFORD_GAS(WORK(KCIOCCLS_ACT),NCOCCLS_ACT,WORK(KIOCCLS),
  +     &       ISM,PSSIGN,
  +     &       IPRCSF,WORK(KICONF_OCC(ISM)),WORK(KICONF_REO(1)),
  +     &       WORK(KSDREO_I(ISM)),WORK(KSDREO_S(ISM)),
  +     &       WORK(KCBLTP),WORK(KCIBT),NCBLOCK)
  +C?      WRITE(6,*) ' IBLTP after CNFORD '
  +C?      CALL IWRTMA(WORK(KCBLTP),1,4,1,4)
  +      END IF ! all Conformation should be set up
   *
         MXSTBL0 = MXNSTR           
   *. type of alpha and beta strings
  
positive.code:       KVEC1P = KVEC1
        KVEC2P = KVEC2
  * 
  *. Allocate space for two complete vectors of variables
        if ( .not. ga_create( mt_dbl, nvar_max, 1, 'CONVC1',
       $   0,0, KCOMVEC1) ) call errquit(
        if ( .not. ga_create( mt_dbl, nvar_max, 1, 'CONVC2',
       $   0,0, KCOMVEC2) ) call errquit(
       $   'GASCI: ga_create kcomvec2 failed', nvar_max , GA_ERR)
  CNW    CALL MEMMAN(KCOMVEC1,NVAR_MAX,'ADDL  ',2,'COMVC1')
  CNW    CALL MEMMAN(KCOMVEC2,NVAR_MAX,'ADDL  ',2,'COMVC2')
  *. Pointers to vectors holding complete or partial vector over variables
        KPVEC1 = KCOMVEC1
        KPVEC2 = KCOMVEC2
  * 
        LBLK = NVAR
  *
  *. CI diagonal - if required
  * 
        KPDIA_SD = KPVEC1
  *
        I_DO_PRECOND = 1
        IF(IDIAG.EQ.2.AND.IRESTR.EQ.1) I_DO_PRECOND = 0
  
negative.code:      &  ' **************************************************'
          WRITE(6,*)
          END IF
          IF(ICISTR.EQ.1) THEN
            CALL FRMDSC(WORK(KPVEC1),NVAR,-1,LUC,IMZERO,IAMPACK)
            CALL COPVEC(WORK(KPVEC1),WORK(KPVEC2),NVAR)
  *
  C?      WRITE(6,*) ' Testing: CI vector read in '
  C?      CALL WRTMAT(WORK(KPVEC1),1,NVAR,1,NVAR)
  *
            IF(IDENSI.EQ.1) THEN
              KRHO2 = 1
            END IF
            IF(IDENSI.GE.1)
       &    CALL DENSI2(IDENSI,WORK(KRHO1),WORK(KRHO2),
       &         WORK(KPVEC1),WORK(KPVEC2),0,0,EXPS2,ISPNDEN,WORK(KSRHO1),
       &         WORK(KRHO2AA),WORK(KRHO2AB),WORK(KRHO2BB),1)
            IF(IDENSI.EQ.2) THEN
  *. Test calculation of energy
              CALL EN_FROM_DENS(ENERGY,2,0)
              WRITE(6,*) ' Energy from density ', ENERGY
            END IF
  *
  C?      IF(I_DO_LZ2.EQ.1) THEN
  C?          CALL EXP_LZ2(KPVEC1,KPVEC2,RLZEFF,RL2EFF,0)
  