Group: comp.lang.ruby
From: Alex Shulgin
Date: Sunday, February 17, 2008 3:22 PM
Subject: Re: The Smallest Circle (#157)

On Feb 15, 3:19 pm, Matthew D Moss wrote:
>
> As mentioned, this one may be more difficult than it seems. Feel free
> to estimate the smallest circle, if you get stuck on getting the
> exact solution.

This is really way more difficult than it seemed to me...

I was approaching some geometrical solution just to be shocked that
there are cases there not both ends of the longest chord lay on the
smallest circle!

Check out these (found by pure luck and help of random):

-0.385628 -0.435444
-0.319182 +0.478400
+0.257012 +0.333913
-0.243603 -0.496925

The longest chord is from points[0] to points[2] (of length 1.002445),
but correct solution appears to be the circle around a triangle [[1],
[2], [3]]. It includes second to longest chord [1]->[3] of length
0.978249.

--
Alex