Determining the Longest Segment of a Non-Continuous Polyline

I have a polyline that is non-continuous (please see picture, polyline is in red). I am looking to separate the polyline based on this geographic discontinuity so that I can calculate the length of each portion individually. Unfortunately I do not know how to separate the polyline in this manner, i have tried multiple things with no success. My best thought so far was to split the line at the vertices (each time the line changes angle) and then unsplit them, but that does not work for some reason. Thoughts? I am using ArcGis 10.5.1.

Note: the the dataset is large and contains quite a bit of variation. The Lines will often converge forming what looks to be a single line, though they each will independently follow the same path. These polylines are the result of a Least Cost Path analysis.

The Red numbers indicate the four different segments I am looking to individually calculate the length of. The Blue dotted line adjacent to segment 4 indicates a partial overlap from a different polyline that separates roughly half way through segment 4.

The overall goal of this analysis is to determine the longest polyline segment.

• Is the polyline a multipart feature? Does it continue underneath the polygons? What license level do you have? Commented Jun 20, 2018 at 5:39
• You say splitting the line doesn't work? What, specifically, are you trying that doesn't work? What tools? Do you have python experience?
– Fezter
Commented Jun 20, 2018 at 5:55
• Make the polygons transparent and show in a new screenshot exactly the lengths you want to calculate.
– Bera
Commented Jun 20, 2018 at 7:11
• Assign unique id to your lines. Explode to single part and sort descending using length. Delete identical using unique id. Commented Jun 20, 2018 at 19:04
• @Michael Stimson The polylines do not continue underneath the polygons (I intersected the polylines with the polygons). As for licensing, I have access to most everything in Arc: spatial analyst, geostatistical analyst, etc. Hopefully that helps!
– Zach
Commented Jun 20, 2018 at 22:36