             log("generators:")
             log(generators.map{ "\t\($0.dim): \($0)"}.joined(separator: ",\n"))
             
-            if !relations.isEmpty {
+            if !diff.isEmpty {
                 log("")
-                log("relations:")
-                log(relations.map { "\t\($0.anyElement!.0.dim): \($0)"}.joined(separator: ",\n"))
+                log("diffs:")
+                log( diff.sorted(by: {$0.0 <= $1.0} ).map { (s, c) in "\t\(s) -> \(c)"}.joined(separator: ",\n"))
             }
             log("")
             

    internal var debug = false
    
    internal var generators = [S]()
    internal var relations  = [C]()
    internal var diff = [S : C]()

    internal var fNodes = [S : Node]()

                return self.value
            }
            
            let value = _collect()
            
            if flatten {
//                self.value = value
//                self.refs = []
            }
            
            return value
        }
        
        @_specialize(where R == ComputationSpecializedRing)
        private func _collect() -> C {
            return value + refs.filter{ !$0.0.isZero }
                               .sum { (n, r) in r * n._collect() }
        }
        
        var hashValue: Int {
