   tournament selection on the :spea2-fitness, and the cycle begins again."
   [config]
   (let [{:keys [unary-ops binary-ops goals archive-size]} config]
-    {:elite-selector         (fn [rabble elite] (make-new-archive goals archive-size rabble elite))
-     :mating-pool-selector   (fn [_ elite] elite)
-     :reproduction-config    {:selector   (partial selection/tournament-selector 2 :spea2-fitness)
-                              :unary-ops  unary-ops
-                              :binary-ops binary-ops}}))+    {:elite-selector       (fn [rabble elite] (make-new-archive goals archive-size rabble elite))
+     :mating-pool-selector (fn [_ elite] elite)
+     :reproduction-config  {:selector   (partial selection/tournament-selector 2 :spea2-fitness)
+                            :unary-ops  unary-ops
+                            :binary-ops binary-ops}}))
(ns algebolic.algorithms.spea2
  "An implementation of the SPEA2 algorithm of Zitzler et al.

  Currently limited to two objectives, but the API is arranged so that should be easy to
  generalise if needed."
  (:require [algebolic.evolution.pareto :as pareto]
            [algebolic.evolution.selection :as selection]))

        ;; individuals that are non-dominated will have a fitness less than 1
        new-elites (filter #(< (:spea2-fitness %) 1.0) scored-pool)
        new-size (count new-elites)
        ;;        _ (println "New archive raw size: " new-size)
        ]
    ;; there are three cases here: either the new archive is exactly the right size, too big, or too small
    (cond
      ;; the easy one, if we happen to have the right number, then we're done.
