Hi all,
I have an arc convergent problem I couldn’t solve. Any help will be appreciated!
Problem: I would like to generate minimum number of arcs to proximate the curve C in the image and there are few rules to follow when the arcs are generated. First all all the, curvature should be as close to the original as possible, secondly, the arcs generated need to be tangent to both red and blue lines indicated as A and B in the image.
My guess to solve this problem:
step 1. take a mid point of the C curve and find perpendicular point on the curve from end points of A and B line to get a vector direction for generating a circle with unknown radius. This radius should be defined to reach the closest curvature of the C curve. However, I’m not sure what is the best way to calculate this. Currently, I do this based on the visual.
step 2. use the offset line of line A to find the direction to generate a new circle (orange) with radius X again, and make sure this circle is tangent to the first circle drawn. Generating a circle with the vector direction will make sure that it’s also tangent to the line A. However, I’m not quite sure how to define the radius which can make this new circle tangent to the previous one.
step 3. repeat the step2 to generate another circle from line B
step 4, trim off the parts I dont need to get only three arcs.
Maybe there is another way to do it but I’m not sure what it’s the best way as I tried many different arc generation methods in GH, but they are all very off from the original geometry or having too many arcs.
I can see that if I will be able to find out how to defines radius of those circles as the questions above, I should be able to get arcs which are very similar to the original curve.
Getting arcs as result is very crucial in this exercise, as well as having both left and right circles to tangent to line A and B. ( the original curve is not tangent to the line A and B).
I hope that someone can help. Thanks in advance!