Expanding the determinant in terms of $3\times 3$ determinants, using the top row, we obtain an equation $A(x^2+y^2)+B x +C y +D =0$ with constants $A,B,C,D.$ The solution set to an equation of this form is (i) empty,or (ii) contains one point, or (iii) is a line,or (iv) is a circle, or (v) is the whole plane. Since the top row co-incides with one of the other rows when $(x,y)=(x_i,y_i)$ for $i\in \{1,2,3\},$ the $3$ given points belong to the solution set, so we can rule out (i) and (ii). And (iii) or (v) each require $A=0,$ but the co-efficient $A\ne 0$ because the $3$ given points are not co-linear. This leaves (iv).And as already stated, the $3$ given points belong to the solution set, that is, they lie on the circle.
Here's a completely different approach that might be easier to encode.
Your two given points ($(x_1, y_1)$ and $(x_2, y_2)$) and the
centers of the two desired circles are at the four vertices of a
rhombus with side length $r$.
You can use the Pythagorean Theorem to find the length of the diagonal
of the rhombus from $(x_1, y_1)$ to $(x_2, y_2)$.
Better still, divide by two so you now have half the length of the diagonal.
The two diagonals of a rhombus are perpendicular,
so the point $(x_1, y_1)$, the center of the rhombus, and one of the
circles' centers make a right triangle with hypotenuse $r$
and one leg equal to half the known diagonal.
Use the Pythagorean Theorem to find half the length of the other diagonal.
Now you just need to construct line segments of that length with one
end at the center of the rhombus, perpendicular to the known diagonal,
and the other end of each segment will be the center of one of the
desired circles.
That's the entire rationale of the procedure.
For the detailed calculations, I'll assign names to various lengths as
we go along in order to keep the equations from getting too ugly.
(You'd probably want to do this anyway when you do this in software.)
![enter image description here](https://i.stack.imgur.com/yrJ91.jpg)
Let $x_a = \frac12(x_2 - x_1)$ and $y_a = \frac12(y_2 - y_1)$;
then the center of the rhombus is at $(x_0,y_0) = (x_1+x_a, y_1+y_a)$
and half the length of the known diagonal is
$a = \sqrt{x_a^2 + y_a^2}.$
The length of the other diagonal is
$b = \sqrt{r^2 - a^2}.$
Now suppose (for example) that $(x_0,y_0)$ is above and to the right
of $(x_1,y_1)$ (assuming, at least for now,
the usual mathematical Cartesian $x,y$ coordinates).
To get from $(x_1,y_1)$ to $(x_0,y_0)$ along a straight line,
we go to the right $x_a$ units and up $y_a$ units for every
$a$ units of movement.
So to get from $(x_0,y_0)$ to the center of one of the circles,
$(x_3,y_3)$, we can just turn those rules $90$ degrees:
we can go down $x_a$ units and to the right $y_a$ units for every
$a$ units of movement;
that is, $\frac{x_a}{a}$ down and $\frac{y_a}{a}$ right for each unit
traveled along the diagonal.
But the distance from $(x_0,y_0)$ to $(x_3,y_3)$ is $b$,
so we will end up going down $b\frac{x_a}{a}$ units
and to the right $b\frac{y_a}{a}$ units.
In other words,
\begin{align}
x_3 &= x_0 + \frac{b y_a}{a}, \\
y_3 &= y_0 - \frac{b x_a}{a}. \\
\end{align}
To get to the center of the other circle, $(x_4,y_4)$,
we just go the same amount in the opposite direction from $(x_0,y_0)$:
\begin{align}
x_4 &= x_0 - \frac{b y_a}{a}, \\
y_4 &= y_0 + \frac{b x_a}{a}. \\
\end{align}
If $(x_0,y_0)$ is not above and to the right of $(x_1,y_1)$,
or if you're working in a graphics coordinate system with $y$ downward,
or both, the signs of either $x_a$ or $y_a$ (or both)
might be negative instead of positive; but all the formulas above
continue to work exactly the same way as before.
Best Answer
Let's call the center of the circle: $P_1 = (x_1, y_1).\;$
Let $ P_2 = (x_2, y_2)$ be a point on circle. Then:
$r$: radius of the circle = distance between points $P_1$ and $P_2$, where
$$r = \sqrt{(x_2 - x_1)^2 + (y_2-y_1)^2}$$
Any point $(x_i, y_i)$ satisfying the equation $(x_i - x_1)^2 + (y_i - y_1)^2 = r^2$ also lies on this circle.