anchor.diff:  
       select case(rank)
       case(rank_main)
  +
  +       ! Find the number of photons per chunk
  +       if(n_photons_chunk == 0) then
  +          n_photons_chunk = nint(real(n_photons_tot, dp) / real(nproc, dp) / real(n_steps, dp))
  +       end if
   
          time_curr = time_curr + time2-time1
   
  
positive.code:              if(n_photons_curr > n_photons_tot) stop "n_photons_curr > n_photons_tot"
  
               ! Find how many photons to request and increment counter
               if(n_photons_tot - n_photons_curr <= n_photons_chunk*2_idp) then
                  n_photons_send(ir) = n_photons_chunk / 10_idp
               else
                  n_photons_send(ir) = n_photons_chunk
               end if
               n_photons_curr = n_photons_curr + n_photons_send(ir)
  
               ! Send number of photons and initialize receive for status check
  
negative.code:        else
  
            ! Set number of photons to a fraction of the normal chunk size
            n_photons = nint(real(n_photons_chunk, dp) / 10._dp)
  
            if(n_photons_curr + n_photons > n_photons_tot) n_photons = n_photons_tot - n_photons_curr
  
            n_photons_curr = n_photons_curr + n_photons
  
         end if
  
         if(first) first=.false.       
  
         if(n_photons_curr >= n_stats_last + n_photons_stats) then
            call perf_numbers(n_photons_curr, time_curr)
            n_stats_last = n_photons_curr - mod(n_photons_curr, n_photons_stats)
         end if
  
      case default
  
  