   "Split this plan node into a seq of plan nodes, all but 0-1 of which will have
    refined output sets."
   [pn input-set input-summary min-step-reward]
-  (let [{:keys [sub-osn excluded-child-set]} pn]
-    (let [split-children (split-osn sub-osn min-step-reward excluded-child-set)
-          new-ecs        (into excluded-child-set split-children)
-          new-summary    (broom-summary sub-osn new-ecs)]
-      (concat
-       (when (viable-summary? new-summary)
-         [(assoc pn :excluded-child-set new-ecs :output-summary new-summary)])
-       (for [child split-children]
-         (make-plan-node input-set input-summary child nil {} is/pos-inf))))))
+  (let [{:keys [sub-osn excluded-child-set]} pn
+        split-children (split-osn sub-osn min-step-reward excluded-child-set)
+;        _   (println "split" pn (count excluded-child-set) (count split-children))    
+        new-ecs        (into excluded-child-set split-children)
+        new-summary    (add-summaries input-summary (broom-summary sub-osn new-ecs))]
+    (concat
+     (when (viable-summary? new-summary)
+       (assert-valid-summary-change (:output-summary pn) new-summary)
+       [(assoc pn :excluded-child-set new-ecs :output-summary new-summary)])
+     (for [child split-children]
+       (do ;         (println "SC"  sub-osn child )
+           (make-plan-node input-set input-summary child nil {} is/pos-inf))))))
 
 
 (defn update-pn-input

    (if (identical? new-osn sub-osn)
      (let [new-output-summary (compute-plan-node-output-summary
                                new-input-summary sub-osn excluded-child-set reward-bound)]
        (when (viable-summary? new-output-summary)
          [[false output-set new-output-summary] (assoc pn :output-summary new-output-summary)]))
      (let [new-pn (make-plan-node new-input-set new-input-summary new-osn nil
                                   (osn-output-set sub-osn)
                                   (max-reward (broom-summary sub-osn)))
            new-output-pair (plan-node-output-set-and-summary new-pn)]
        (when (viable-output-set-and-summary? new-output-pair)
          [(cons (not (= (:output-set new-pn) output-set)) new-output-pair) new-pn])))))


                   (conj rest-things next-thing) (max-summary next-summary rest-summary) even-more-things)))
        [best-thing best-summary rest-things rest-summary])))

(defn summary-str [s] (str (max-reward s) (:status s) (vec (:opt-sol s))))
(defmethod print-method SimpleSummary [s o] (print-method (summary-str s) o))

(defn assert-valid-summary-change [old-summary new-summary]
  (util/assert-is (<= (max-reward new-summary) (max-reward old-summary)) "%s" [old-summary new-summary])
  (when-not (live? old-summary) (assert (= old-summary new-summary))))



;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Subproblems ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
