I want a script to find the radius of a circle that passes through three points
For exampleA: (1,2)B: (3,4)C: (5,6)Is it possible to easily find the radius of a circle passing through ABC?
Sure, draw a line from {xc,yc} (the center) to any point on the circle. Three good candidates are {ax,ay}, {bx,by} and {cx,cy} . A diameter would be slightly harder, but you could find the point opposite A, through the center, at {CX + (CX-AX), CY + (CY-AY)}. You also know the radius is
Sqrt( (xc - ax) ^ 2 + (yc - ay) ^ 2 )
(using the center point and point A) so you could find other points as well, using cx + r*cos( a ), cy + r*sin(a), for various angles in radians.
Circle through three points
And I like you example of a circle!
I'm degenerate!
Good point (!) , you'll want to watch out for edge cases.
Thank you SCL for illustrating the circle.It helped me a lot!
Is it possible to show the radius?