Simplifying an Organic Curve for Tube Bending

Hi everyone, I have a question. Is it possible to simplify a very complex and organic form that was created in another software in Rhino and Grasshopper so that a tube bending manufacturer can actually produce the individual parts?

The challenge is that the bending machines can only handle certain bend radii. In principle, any radius above 170 mm is possible, but the preferred radii are 170 mm, 230 mm, and 390 mm.

Does anyone know how to set this up in Grasshopper so that the curve is first rebuilt and then adjusted to match these specific bending radii (with a minimum of 170 mm)?

I’ve attached the curve and a screenshot of the tube for reference.
Any advice or tips would be greatly appreciated!

curve.dxf (149.9 KB)

the question is how exact do you need it? in Rhino you could try with RebuildCrvNonUniform, set it to something low like 150 pts, then use Fair to equalise the curvature acceleration.

after that use ExtractMinMaxRadiusPoints and target the areas with the tight radius. turn on the curve points select the control points in that area and use Smooth, if needed multiple times.

btw is that some protein chain?

after applying the above suggestions, you can try something like this which transforms the resulting curve into arcs and straight lines -it uses a script from this thread: Geometry optimization related to an library - #6 by AndersDeleuran

curves_to_arcs_and_lines_andersdeleuran.gh (36.5 KB)
[the polyline from your dxf file is internalized]

this way you can see in a glance what diameters do not respect the 170+ radius rule

I guess another important point you need to consider is about self-intersection, which you probably want to avoid while simplifying the curve

also relevant, if two consecutive arcs do not share end-tangents, you will get these kinks: