Asked • 05/29/19

Finding all points common to two circles?

In Python, how would one find all integer points common to two circles? For example, imagine a Venn diagram-like intersection of two (equally sized) circles, with center-points `(x1,y1)` and `(x2,y2)` and radii `r1=r2`. Additionally, we already know the two points of intersection of the circles are `(xi1,yi1)` and `(xi2,yi2)`. How would one generate a list of all points `(x,y)` contained in both circles in an efficient manner? That is, it would be simple to draw a box containing the intersections and iterate through it, checking if a given point is within both circles, but is there a better way?

1 Expert Answer

By:

Patrick B. answered • 05/29/19

Tutor
4.7 (31)

Math and computer tutor/teacher

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.