Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

Find circle radius & circle center in 3D from (3) XYZ pts 5

Status
Not open for further replies.

DrMetal

Materials
Oct 4, 2005
30
0
0
US
GIVEN: X-Y-Z coordinates of 3 points in 3D space. FIND: Radius of circle on those 3 points & Circle center co-ordinatesBookmark:
Question: Can someone provide a mathematical step by step procedure to calculate and determine a circle radius and the center point coordinates from three GIVEN 3D points with X-Y-Z coordinates?

- I have searched the web extensively, and found lots of proposed solutions, but my college math is quite rusty and after several days, I still can not come up with the correct detailed solution. I can do this easily from three points in 2D, in Excel using three simultaneous equations with TWO variables (i.e. find circle center @ h, j). But I can't get it to work in 3D with a similar spreadsheet approach with THREE variables (i.e. find circle center @ h-j-k). Seems I keep going in mathematical circles (no pun intended) with a modified Excel approach with the three quadratic equations.

- Is it possible to solve this mathematically with (3) simultaneous quadratic equations? Or do I need a 4th equation, determinates, etc?. Seems when I try the double elimination (or substitution) of variables approach, I keep coming up with unsolvable, or meaningless equations. With as much time as we have spent on this problem, we would be happy to compensate someone for their time to solve this for us.

- We have several drawings with bent pipes in 3D where we have only THREE 3D points given to us. We need to be able to determine the TRUE bend radius of the pipes. These are special alloy pipes @ $25k each, so we want to be sure we have the correct 2D bend radius before we bend them. I'd prefer an approach that could be put into a spreadsheet to make reiterative calcs go quickly. I'd prefer to have a detailed step-by-step solution vs. being directed to one of the web solutions. I have seen most of them, and still am stuck on this.
Thanks, MWP
 
Replies continue below

Recommended for you

"check that the two tangent points are the same distance from the IP, and if necessary moving the further one so that they are."well that's pretty redundant, 'cause they have to be, congruent triangles.

If both the points are tangent points to the same circle then they will be eqidistant from the intersection point, but it's perfectly possible to enter points that are not equidistant from the intersection point, in which case the function would return the centre of a circle which was not tangential to either point, and you wouldn't have any idea about the mistake. By checking that the points are equidistant it picks up that potential error, and by reporting the coordinates for the adjusted point it gives an indication of the error.

Doug Jenkins
Interactive Design Services
 
if the co-rods are entered in error, how can you correct them ? (other than by guessing) wouldn't it be better (if the tangency points aren't equidistant) to return an error code (rather than a radius which is probably not correct) ??
 
Apologize if this is already mentioned, I haven't read thru all responses in detail.

Here is the simplest hand calc solution according to me:

1. |C^-X1^| = |C^-X2^| = |C^-X3^|
2. C must lie on plane described by X1, X2 and X3.

The above 2 conditions describe a problem with 3 equations and 3 unknowns.

Where
C^, X1^, X2^ and X3^ are the position vectors of centers and the 3 points respectively. C = [c1 c2 c3], X1 = [x11 x12 x13] ... and so on.
 
if the co-rods are entered in error, how can you correct them ? (other than by guessing)

By assuming that one point is a true tangent point and the other point lies on a tangent, but is not on the circle. From examining the coordinates of the adjusted point (which are in the second row of the function return array) it will be obvious whether this is a reasonable assumption or not.

wouldn't it be better (if the tangency points aren't equidistant) to return an error code (rather than a radius which is probably not correct) ??

Depends on the application. It would be very easy to modify the code to do that. If you did you'd want to allow the passing of an acceptable error value (which would obviously depend on the units). For the application being discussed in this thread, which uses physical meaurements of a bent pipe, the accuracy would almost never match that required by the function, so it would almost always return an error, which wouldn't be very useful. You could easily re-write it to allow an error of up to some realistic value, with an adjustment of the further tangent point, and to return an error if the discrepancy in the tangent lengths was greater than that specified.

Doug Jenkins
Interactive Design Services
 
Doug,
- On the error issue ... this is actually what we are dealing with. We are given the 3 pts by an outside Engr party. When checking first for both tangent lines being equal, they are not equal (in all 4 cases for us). What we did was to move the point of intersection (POI) in the direction that had the most effect on the length, and the least affect on the positon of the pipe in space. So the small errors are corrected mathematically very quickly, but with little physical effect on the structure. We are dealing very large diameters (22'R to 580'R), and relatively small circle arc lengths (only 6'L to 20'L). We found that some very slight movements or errors in the 3 point's coordinate positions can have very large affects on the bend raddii. For example, if the POI "height" above the arc changes very slightly (e.g. 1"), it can change the arc radius by several feet. This is because it is a very "flat" and short arc. For example, taking this to extremes, if you had a 10' arc length on a 10,000' radius, the POI almost rests right on the circle. Raise that POI by just 1" and see how mach that radius has to change to accomodate that. Again, thanks for all this great help. Mike P.
 
let's sign off ... the problem moved from 3 points on an arc to two points of tangency and their intersection to the real world problem of points close to being where they should be ... quite the journey.

with your dimensions i would've thought the problem was in accurately measuring the dimensions, i would've expected at a 3D CAD program (or even a surveying program) would have been able to accurately dimension the required geometry. i suspect the real problem is how to physically create the required shape, rather than how to mathematically define it.

 
RB,
- I agree .. I think we have beat this one to death. But to answer your question ... we have to define it before we can make it ... and making this shape is not a big problem ... we have bent the 1st two short pipes and can make them lay on a true cut template within 1/16". Accuracy is important in our case because these pipes are not just out in free space. They are attached to a heavy fabicated cradle system, with 2"T support plates every 24". The support plates have half-circle cutouts that "cradle" the pipes. The support structure with the cradle plates are all fabricated as an assembly first. Then the bent pipe has to lay into this 3D structure. So we need to do both ... DEFINE the curve, and then PRODUCE the curve to a fair degree of accuracy for all of this to come together properly. I could have said this early on, but didn't want to cloud the issue any more than it was. Thanks again, Mike P.
 
Doug,
- Thanks again for postings. Most helpful.
- By any chance do you have a couple of related formulas?

1) After determining the circle radius and center point, do you have an Excel solution to determine the coordinates of any other point on the circle given any one of the X-Y-Z coordinates of the unknown point, OR given the arc angle from another known point on the circle?

2) Knowing the coordinates of 2 points in 3D (i.e. a line in 3D), an Excel method to determine the coordinates of any other point on the line by just plugging in a distance along the line from one of the two known points? This is pretty simple with the distance formula. If you don't already have this written, I can write it. I thought I'd check first to see if you already have one done in Excel.

Thanks again,
Mike P.
 
Mike - I don't have those functions right now, although the ptor (polar to rectangular) and rtop (rectangular to polar) functions would go most of the way to doing the calculation.

My plan is to split out the interpolation part of the IP spreadsheet, and add in additional geometric functions and line plotting functions, and make it a complete geometric tool-box, but I don't know when I'll get round to doing that.

Doug Jenkins
Interactive Design Services
 
Status
Not open for further replies.
Back
Top