Smallest Enclosing Circle Calculator

Result

Calculation Steps
Visual Representation

About Smallest Enclosing Circle

What is a Smallest Enclosing Circle?

The smallest enclosing circle, also known as the minimum covering circle, is the smallest circle that contains a given set of points in the Euclidean plane. It's a fundamental problem in computational geometry with applications in computer graphics, facility location, and data visualization.

Formula

There's no simple formula for finding the smallest enclosing circle. Instead, it's typically solved using iterative algorithms. One common approach is Welzl's algorithm, which has an expected linear time complexity.

However, once we have the circle, we can describe it with the following equations:

  • Circle equation: \((x - h)^2 + (y - k)^2 = r^2\)
  • Where \((h, k)\) is the center of the circle and \(r\) is its radius

Calculation Steps

  1. Input the set of points
  2. Initialize the circle with the first two points
  3. For each remaining point:
    • If the point is outside the current circle, update the circle to include this point
    • The new circle is the smallest circle that includes the new point and all previous points
  4. The resulting circle is the smallest enclosing circle

Example

Let's find the smallest enclosing circle for the points (0,0), (1,1), (-1,1), and (0,-1):

  1. Start with (0,0) and (1,1): circle center (0.5, 0.5), radius \(\sqrt{0.5}\)
  2. Add (-1,1): new circle center (0, 1), radius \(\sqrt{2}\)
  3. Add (0,-1): final circle center (0, 0), radius 1
Center (0,0) (1,1) (-1,1) (0,-1)