       (assert (= (count new-parents) (dec (count @parents))))
       (reset! parents new-parents))))
 )
+
+
+(comment
+  (defn- make-atomic-subproblem [stub subsuming-sp inp-set function-set out-set reward status]
+  (let [children (when (= status :live)
+                   (or #_ (refined-children subsuming-as inp-set) ;; TODO!!
+                       (map #(make-fs-seq-stub inp-set %)
+                            (fs/child-seqs function-set inp-set))))]
+    (make-simple-subproblem
+     [::Atomic (fs/fs-name function-set) inp-set]
+     inp-set out-set
+     (if (= status :live)
+       (fn [s]
+         (assert (empty? (summaries/node-subsuming-children s)))
+         (assert (= (count children) (count (summaries/node-ordinary-children s))))
+         (summary/or-combine (map summaries/summary children) s reward))
+       (fn [s] (summary/make-simple-summary reward status s)))     
+     children children identity
+     (fn [s ref-inp-set] (make-atomic-stub s ref-inp-set function-set))))))
   #(let [n (second (subproblem-name %))] (when-not (= (first n) :noop) n))))

(defn- get-root-subproblem [inp-set fs]
  (let [root-stub (make-atomic-stub nil inp-set fs)
        ret       (atom nil)]
    (add-watcher! root-stub (fn [_ root] (reset! ret root)))
    (evaluate! root-stub)

     (add-output! ts child-sp)
     (let [my-sum (summaries/summary ts) child-sum (summaries/summary (tree-summarizer child-sp))]
;       (util/assert-is (>= (summary/max-reward my-sum) (summary/max-reward child-sum)))  Cannot assert this -- see above.
       (when-not (summary/>= my-sum child-sum)
         (summaries/summary-changed! ts))))
    
   summaries/Summarizable
   (summarize [s]
