diff --git a/dnarbd/segmentmodel.py b/dnarbd/segmentmodel.py
index fa053566e48655fdc075dc72deb94373ecd9bfe2..867bd630bf0e54f488e992f2140e1aad098dba41 100644
--- a/dnarbd/segmentmodel.py
+++ b/dnarbd/segmentmodel.py
@@ -279,23 +279,25 @@ class SegmentParticle(PointParticle):
                     assert( sign in (1,-1) )
                     if distance < cutoff: # TODO: check if this does anything
                         cutoff = distance
-                    return [[distance, contour_in_seg+sign*seg.nt_pos_to_contour(distance)]]
+                    return [[distance, contour_in_seg+sign*seg.nt_pos_to_contour(distance)]], [(seg, contour_in_seg, distance)]
                 if distance > cutoff:
-                    return None
+                    return None,None
                     
                 ret_list = []
+                hist_list = []
                 ## Find intrahelical locations in seg that we might pass through
                 for c,A,B in seg.get_connections_and_locations("intrahelical"):
                     if B.container in visited_segs: continue
-                    dx = seg.contour_to_nt_pos( np.abs(A.address-contour_in_seg),
-                                                round_nt=False) 
-                    results = descend_search_tree( B.container, B.address,
+                    dx = seg.contour_to_nt_pos( A.address, round_nt=False ) - seg.contour_to_nt_pos( contour_in_seg, round_nt=False)
+                    dx = np.abs(dx)
+                    results,history = descend_search_tree( B.container, B.address,
                                                    distance+dx, visited_segs + [seg] )
                     if results is not None:
                         ret_list.extend( results )
-                return ret_list
+                        hist_list.extend( history )
+                return ret_list,hist_list
 
-            results = descend_search_tree(self.parent, self.contour_position)
+            results,history = descend_search_tree(self.parent, self.contour_position)
             if results is None or len(results) == 0:
                 raise Exception("Could not find location in segment") # TODO better error
             return sorted(results,key=lambda x:x[0])[0][1]