Attract curves with Kangaroo

Hi everyone!

I need to attract two curves with the condition that the final result keeps a segment with a certain length (let’s say 11mm) in the intersection between them. Both curves should be able to move during the attraction. I am using Kangaroo because this is part of a wider analysis and I need to have this kind of “freedom” in the possible results. Any ideas?

This is the stage before the attraction:

After the attraction there are many possible results:

What have you tried so far? Can you share a grasshopper definition?

Sure, I have been trying different options but this is the best result I got by using the colinear and OnCurve goals.

This is not the result I need because the points on one of the curves which is attracted are attached to one of its corners, so the position of the common segment is actually predefined before the attraction.

Attract curves.gh (19.9 KB)