anchor.diff:          case default
               ! Select cluster from the excitors on the current processor in
               ! a uniform manner.
  -            amplitude = 1.0_p
  -            do i = 1, cluster_size
  +            ! First excitor 'seeds' the cluster:
  +            pos = int(genrand_real2()*tot_walkers) +1
  +            cdet%f = walker_dets(:,pos)
  +            cluster_pop = walker_population(1,pos)
  +            ! Now the rest...
  +            do i = 2, cluster_size
                   ! Select a position between in the excitors list.
  -                excitor(i) = int(genrand_real2()*tot_walkers) + 1
  -                amplitude = amplitude*walker_population(1,excitor(i))
  +                pos = int(genrand_real2()*tot_walkers) + 1
  +                call collapse_cluster(walker_dets(:,pos), walker_population(1,pos), cdet%f, cluster_pop)
  +                if (cluster_pop == 0) exit
               end do
  +
               ! Normalisation factor for amplitudes...
  -            amplitude = amplitude/(D0_population**(cluster_size-1)) ! TODO: don't accumulate D0 over report loops
  -
  -            ! TODO: collapse cluster (return also excitation_level)
  +            amplitude = real(cluster_pop,p)/(D0_population**(cluster_size-1)) ! TODO: don't accumulate D0 over report loops
  +
  +            ! TODO: sign change due to difference between determinant
  +            ! representation and excitors.
   
               ! We chose excitors uniformly.
               !  -> prob. of each excitor is 1./(number of excitors on processor).
  
positive.code:         use determinants, only: det_info
          use dSFMT_interface, only: genrand_real2
          use fciqmc_data, only: f0, D0_population, tot_walkers, &
                                 walker_population
          use proc_pointers, only: decoder_ptr
          use utils, only: factorial
  
  
negative.code:         real(p), intent(out) :: amplitude, pcluster
  
          real(p) :: rand, psize
          integer :: cluster_size, i, pos, cluster_pop
          logical :: valid_cluster
  
          ! We shall accumulate the factors which comprise pcluster as we go.
          !   pcluster = n_sel p_size p_clust
  