# Circumcircle

In geometry, the circumscribed circle or circumcircle of a triangle is a circle that passes through all three vertices. The center of this circle is called the circumcenter of the triangle, and its radius is called the circumradius. The circumcenter is the point of intersection between the three perpendicular bisectors of the triangle's sides, and is a triangle center.
More generally, an n-sided polygon with all its vertices on the same circle, also called the circumscribed circle, is called a cyclic polygon, or in the special case n = 4, a cyclic quadrilateral. All rectangles, isosceles trapezoids, right kites, and regular polygons are cyclic, but not every polygon is.

## Straightedge and compass construction

The circumcenter of a triangle can be constructed by drawing any two of the three perpendicular bisectors. For three non-collinear points, these two lines cannot be parallel, and the circumcenter is the point where they cross. Any point on the bisector is equidistant from the two points that it bisects, from which it follows that this point, on both bisectors, is equidistant from all three triangle vertices. The circumradius is the distance from it to any of the three vertices.

## Alternative construction

An alternative method to determine the circumcenter is to draw any two lines each one departing from one of the vertices at an angle with the common side, the common angle of departure being 90° minus the angle of the opposite vertex. (In the case of the opposite angle being obtuse, drawing a line at a negative angle means going outside the triangle.)
In coastal navigation, a triangle's circumcircle is sometimes used as a way of obtaining a position line using a sextant when no compass is available. The horizontal angle between two landmarks defines the circumcircle upon which the observer lies.

## Circumcircle equations
### Cartesian coordinates

In the Euclidean plane, it is possible to give explicitly an equation of the circumcircle in terms of the Cartesian coordinates of the vertices of the inscribed triangle. Suppose that
    ${\begin{aligned}\mathbf {A} &=(A_{x},A_{y})\\\mathbf {B} &=(B_{x},B_{y})\\\mathbf {C} &=(C_{x},C_{y})\end{aligned}}$
are the coordinates of points A, B, C. The circumcircle is then the locus of points $\mathbf {v} =(v_{x},v_{y})$ in the Cartesian plane satisfying the equations
    ${\begin{aligned}|\mathbf {v} -\mathbf {u} |^{2}&=r^{2}\\|\mathbf {A} -\mathbf {u} |^{2}&=r^{2}\\|\mathbf {B} -\mathbf {u} |^{2}&=r^{2}\\|\mathbf {C} -\mathbf {u} |^{2}&=r^{2}\end{aligned}}$
guaranteeing that the points A, B, C, v are all the same distance r from the common center $\mathbf {u}$ of the circle. Using the polarization identity, these equations reduce to the condition that the matrix
    ${\begin{bmatrix}|\mathbf {v} |^{2}&-2v_{x}&-2v_{y}&-1\\|\mathbf {A} |^{2}&-2A_{x}&-2A_{y}&-1\\|\mathbf {B} |^{2}&-2B_{x}&-2B_{y}&-1\\|\mathbf {C} |^{2}&-2C_{x}&-2C_{y}&-1\end{bmatrix}}$
has a nonzero kernel. Thus the circumcircle may alternatively be described as the locus of zeros of the determinant of this matrix:
    $\det {\begin{bmatrix}|\mathbf {v} |^{2}&v_{x}&v_{y}&1\\|\mathbf {A} |^{2}&A_{x}&A_{y}&1\\|\mathbf {B} |^{2}&B_{x}&B_{y}&1\\|\mathbf {C} |^{2}&C_{x}&C_{y}&1\end{bmatrix}}=0.$
Using cofactor expansion, let
    ${\begin{aligned}S_{x}&={\frac {1}{2}}\det {\begin{bmatrix}|\mathbf {A} |^{2}&A_{y}&1\\|\mathbf {B} |^{2}&B_{y}&1\\|\mathbf {C} |^{2}&C_{y}&1\end{bmatrix}},\\[5pt]S_{y}&={\frac {1}{2}}\det {\begin{bmatrix}A_{x}&|\mathbf {A} |^{2}&1\\B_{x}&|\mathbf {B} |^{2}&1\\C_{x}&|\mathbf {C} |^{2}&1\end{bmatrix}},\\[5pt]a&=\det {\begin{bmatrix}A_{x}&A_{y}&1\\B_{x}&B_{y}&1\\C_{x}&C_{y}&1\end{bmatrix}},\\[5pt]b&=\det {\begin{bmatrix}A_{x}&A_{y}&|\mathbf {A} |^{2}\\B_{x}&B_{y}&|\mathbf {B} |^{2}\\C_{x}&C_{y}&|\mathbf {C} |^{2}\end{bmatrix}}\end{aligned}}$
we then have $a|\mathbf {v} |^{2}-2\mathbf {Sv} -b=0$ where $\mathbf {S} =(S_{x},S_{y}),$ and – assuming the three points were not in a line (otherwise the circumcircle is that line that can also be seen as a generalized circle with S at infinity) – $\left|\mathbf {v} -{\tfrac {\mathbf {S} }{a}}\right|^{2}={\tfrac {b}{a}}+{\tfrac {|\mathbf {S} |^{2}}{a^{2}}},$ giving the circumcenter ${\tfrac {\mathbf {S} }{a}}$ and the circumradius ${\sqrt {{\tfrac {b}{a}}+{\tfrac {|\mathbf {S} |^{2}}{a^{2}}}}}.$ A similar approach allows one to deduce the equation of the circumsphere of a tetrahedron.

### Parametric equation

A unit vector perpendicular to the plane containing the circle is given by
    ${\widehat {n}}={\frac {(P_{2}-P_{1})\times (P_{3}-P_{1})}{|(P_{2}-P_{1})\times (P_{3}-P_{1})|}}.$
Hence, given the radius, r, center, P$_c$, a point on the circle, P$_0$ and a unit normal of the plane containing the circle, ⁠${\widehat {n}},$⁠ one parametric equation of the circle starting from the point P$_0$ and proceeding in a positively oriented (i.e., right-handed) sense about ⁠${\widehat {n}}$⁠ is the following:
    $\mathrm {R} (s)=\mathrm {P_{c}} +\cos \left({\frac {\mathrm {s} }{\mathrm {r} }}\right)(P_{0}-P_{c})+\sin \left({\frac {\mathrm {s} }{\mathrm {r} }}\right)\left[{\widehat {n}}\times (P_{0}-P_{c})\right].$

### Trilinear and barycentric coordinates

An equation for the circumcircle in trilinear coordinates x : y : z is ${\tfrac {a}{x}}+{\tfrac {b}{y}}+{\tfrac {c}{z}}=0.$ An equation for the circumcircle in barycentric coordinates x : y : z is ${\tfrac {a^{2}}{x}}+{\tfrac {b^{2}}{y}}+{\tfrac {c^{2}}{z}}=0.$
The isogonal conjugate of the circumcircle is the line at infinity, given in trilinear coordinates by $ax+by+cz=0$ and in barycentric coordinates by $x+y+z=0.$

### Higher dimensions

Additionally, the circumcircle of a triangle embedded in three dimensions can be found using a generalized method. Let A, B, C be three-dimensional points, which form the vertices of a triangle. We start by transposing the system to place C at the origin:
    ${\begin{aligned}\mathbf {a} &=\mathbf {A} -\mathbf {C} ,\\\mathbf {b} &=\mathbf {B} -\mathbf {C} .\end{aligned}}$
The circumradius r is then
    $r={\frac {\left\|\mathbf {a} \right\|\left\|\mathbf {b} \right\|\left\|\mathbf {a} -\mathbf {b} \right\|}{2\left\|\mathbf {a} \times \mathbf {b} \right\|}}={\frac {\left\|\mathbf {a} -\mathbf {b} \right\|}{2\sin \theta }}={\frac {\left\|\mathbf {A} -\mathbf {B} \right\|}{2\sin \theta }},$
where θ is the interior angle between a and b. The circumcenter, p$_0$, is given by
    $p_{0}={\frac {(\left\|\mathbf {a} \right\|^{2}\mathbf {b} -\left\|\mathbf {b} \right\|^{2}\mathbf {a} )\times (\mathbf {a} \times \mathbf {b} )}{2\left\|\mathbf {a} \times \mathbf {b} \right\|^{2}}}+\mathbf {C} .$
This formula only works in three dimensions as the cross product is not defined in other dimensions, but it can be generalized to the other dimensions by replacing the cross products with following identities:
    ${\begin{aligned}\mathbf {u} \times (\mathbf {v} \times \mathbf {w} )&=(\mathbf {u} \cdot \mathbf {w} )\mathbf {v} -(\mathbf {u} \cdot \mathbf {v} )\mathbf {w} ,\\\left\|\mathbf {u} \times \mathbf {v} \right\|^{2}&=\left\|\mathbf {u} \right\|^{2}\left\|\mathbf {v} \right\|^{2}-(\mathbf {u} \cdot \mathbf {v} )^{2}.\end{aligned}}$
This gives us the following equation for the circumradius r:
    $r={\frac {\left\|\mathbf {a} \right\|\left\|\mathbf {b} \right\|\left\|\mathbf {a} -\mathbf {b} \right\|}{2{\sqrt {\left\|\mathbf {a} \right\|^{2}\left\|\mathbf {b} \right\|^{2}-(\mathbf {a} \cdot \mathbf {b} )^{2}}}}}$
and the following equation for the circumcenter p$_0$:
    $p_{0}={\frac {((\left\|\mathbf {a} \right\|^{2}\mathbf {b} -\left\|\mathbf {b} \right\|^{2}\mathbf {a} )\cdot \mathbf {b} )\mathbf {a} -((\left\|\mathbf {a} \right\|^{2}\mathbf {b} -\left\|\mathbf {b} \right\|^{2}\mathbf {a} )\cdot \mathbf {a} )\mathbf {b} }{2(\left\|\mathbf {a} \right\|^{2}\left\|\mathbf {b} \right\|^{2}-(\mathbf {a} \cdot \mathbf {b} )^{2})}}+\mathbf {C}$
which can be simplified to:
    $p_{0}={\frac {\left\|\mathbf {a} \right\|^{2}\left\|\mathbf {b} \right\|^{2}(\mathbf {a} +\mathbf {b} )-(\mathbf {a} \cdot \mathbf {b} )(\left\|\mathbf {a} \right\|^{2}\mathbf {b} +\left\|\mathbf {b} \right\|^{2}\mathbf {a} )}{2(\left\|\mathbf {a} \right\|^{2}\left\|\mathbf {b} \right\|^{2}-(\mathbf {a} \cdot \mathbf {b} )^{2})}}+\mathbf {C}$

## Circumcenter coordinates
### Cartesian coordinates

The Cartesian coordinates of the circumcenter $U=\left(U_{x},U_{y}\right)$ are
    ${\begin{aligned}U_{x}&={\frac {1}{D}}\left[(A_{x}^{2}+A_{y}^{2})(B_{y}-C_{y})+(B_{x}^{2}+B_{y}^{2})(C_{y}-A_{y})+(C_{x}^{2}+C_{y}^{2})(A_{y}-B_{y})\right]\\[5pt]U_{y}&={\frac {1}{D}}\left[(A_{x}^{2}+A_{y}^{2})(C_{x}-B_{x})+(B_{x}^{2}+B_{y}^{2})(A_{x}-C_{x})+(C_{x}^{2}+C_{y}^{2})(B_{x}-A_{x})\right]\end{aligned}}$
with
    $D=2\left[A_{x}(B_{y}-C_{y})+B_{x}(C_{y}-A_{y})+C_{x}(A_{y}-B_{y})\right].\,$
Without loss of generality this can be expressed in a simplified form after translation of the vertex A to the origin of the Cartesian coordinate systems, i.e., when $A'=A-A=(A'_{x},A'_{y})=(0,0).$ In this case, the coordinates of the vertices $B'=B-A$ and $C'=C-A$ represent the vectors from vertex A' to these vertices. Observe that this trivial translation is possible for all triangles and the circumcenter $U'=(U'_{x},U'_{y})$ of the triangle △A'B'C' follow as
    ${\begin{aligned}U'_{x}&={\frac {1}{D'}}\left[C'_{y}({B'_{x}}^{2}+{B'_{y}}^{2})-B'_{y}({C'_{x}}^{2}+{C'_{y}}^{2})\right],\\[5pt]U'_{y}&={\frac {1}{D'}}\left[B'_{x}({C'_{x}}^{2}+{C'_{y}}^{2})-C'_{x}({B'_{x}}^{2}+{B'_{y}}^{2})\right]\end{aligned}}$
with
    $D'=2(B'_{x}C'_{y}-B'_{y}C'_{x}).\,$
Due to the translation of vertex A to the origin, the circumradius r can be computed as
    $r=\|U'\|={\sqrt {{U'_{x}}^{2}+{U'_{y}}^{2}}}$
and the actual circumcenter of △ABC follows as
    $U=U'+A$

### Trilinear coordinates

The circumcenter has trilinear coordinates
    $\cos \alpha :\cos \beta :\cos \gamma$
where α, β, γ are the angles of the triangle.
In terms of the side lengths a, b, c, the trilinears are
    $a\left(b^{2}+c^{2}-a^{2}\right):b\left(c^{2}+a^{2}-b^{2}\right):c\left(a^{2}+b^{2}-c^{2}\right).$

### Barycentric coordinates

The circumcenter has barycentric coordinates
    $a^{2}\left(b^{2}+c^{2}-a^{2}\right):\;b^{2}\left(c^{2}+a^{2}-b^{2}\right):\;c^{2}\left(a^{2}+b^{2}-c^{2}\right),\,$
where a, b, c are edge lengths BC, CA, AB respectively) of the triangle.
In terms of the triangle's angles α, β, γ, the barycentric coordinates of the circumcenter are
    $\sin 2\alpha :\sin 2\beta :\sin 2\gamma .$

### Circumcenter vector

Since the Cartesian coordinates of any point are a weighted average of those of the vertices, with the weights being the point's barycentric coordinates normalized to sum to unity, the circumcenter vector can be written as
    $U={\frac {a^{2}\left(b^{2}+c^{2}-a^{2}\right)A+b^{2}\left(c^{2}+a^{2}-b^{2}\right)B+c^{2}\left(a^{2}+b^{2}-c^{2}\right)C}{a^{2}\left(b^{2}+c^{2}-a^{2}\right)+b^{2}\left(c^{2}+a^{2}-b^{2}\right)+c^{2}\left(a^{2}+b^{2}-c^{2}\right)}}.$
Here U is the vector of the circumcenter and A, B, C are the vertex vectors. The divisor here equals 16S $^2$ where S is the area of the triangle. As stated previously
    ${\begin{aligned}\mathbf {a} &=\mathbf {A} -\mathbf {C} ,\\\mathbf {b} &=\mathbf {B} -\mathbf {C} .\end{aligned}}$

### Cartesian coordinates from cross- and dot-products

In Euclidean space, there is a unique circle passing through any given three non-collinear points P$_1$, P$_2$, P$_3$. Using Cartesian coordinates to represent these points as spatial vectors, it is possible to use the dot product and cross product to calculate the radius and center of the circle. Let
    $\mathrm {P_{1}} ={\begin{bmatrix}x_{1}\\y_{1}\\z_{1}\end{bmatrix}},\mathrm {P_{2}} ={\begin{bmatrix}x_{2}\\y_{2}\\z_{2}\end{bmatrix}},\mathrm {P_{3}} ={\begin{bmatrix}x_{3}\\y_{3}\\z_{3}\end{bmatrix}}$
Then the radius of the circle is given by
    $\mathrm {r} ={\frac {\left|P_{1}-P_{2}\right|\left|P_{2}-P_{3}\right|\left|P_{3}-P_{1}\right|}{2\left|\left(P_{1}-P_{2}\right)\times \left(P_{2}-P_{3}\right)\right|}}$
The center of the circle is given by the linear combination
    $\mathrm {P_{c}} =\alpha \,P_{1}+\beta \,P_{2}+\gamma \,P_{3}$
where
    ${\begin{aligned}\alpha ={\frac {\left|P_{2}-P_{3}\right|^{2}\left(P_{1}-P_{2}\right)\cdot \left(P_{1}-P_{3}\right)}{2\left|\left(P_{1}-P_{2}\right)\times \left(P_{2}-P_{3}\right)\right|^{2}}}\\\beta ={\frac {\left|P_{1}-P_{3}\right|^{2}\left(P_{2}-P_{1}\right)\cdot \left(P_{2}-P_{3}\right)}{2\left|\left(P_{1}-P_{2}\right)\times \left(P_{2}-P_{3}\right)\right|^{2}}}\\\gamma ={\frac {\left|P_{1}-P_{2}\right|^{2}\left(P_{3}-P_{1}\right)\cdot \left(P_{3}-P_{2}\right)}{2\left|\left(P_{1}-P_{2}\right)\times \left(P_{2}-P_{3}\right)\right|^{2}}}\end{aligned}}$

### Location relative to the triangle

The circumcenter's position depends on the type of triangle:
* For an acute triangle (all angles smaller than a right angle), the circumcenter always lies inside the triangle.
* For a right triangle, the circumcenter always lies at the midpoint of the hypotenuse. This is one form of Thales' theorem.
* For an obtuse triangle (a triangle with one angle bigger than a right angle), the circumcenter always lies outside the triangle.
These locational features can be seen by considering the trilinear or barycentric coordinates given above for the circumcenter: all three coordinates are positive for any interior point, at least one coordinate is negative for any exterior point, and one coordinate is zero and two are positive for a non-vertex point on a side of the triangle.

## Angles

The angles which the circumscribed circle forms with the sides of the triangle coincide with angles at which sides meet each other. The side opposite angle α meets the circle twice: once at each end; in each case at angle α (similarly for the other two angles). This is due to the alternate segment theorem, which states that the angle between the tangent and chord equals the angle in the alternate segment.

## Triangle centers on the circumcircle

In this section, the vertex angles are labeled A, B, C and all coordinates are trilinear coordinates:
* Steiner point: the non-vertex point of intersection of the circumcircle with the Steiner ellipse.
       ${\frac {bc}{b^{2}-c^{2}}}:{\frac {ca}{c^{2}-a^{2}}}:{\frac {ab}{a^{2}-b^{2}}}$
    (The Steiner ellipse, with center = centroid (ABC), is the ellipse of least area that passes through A, B, C. An equation for this ellipse is ${\tfrac {1}{ax}}+{\tfrac {1}{by}}+{\tfrac {1}{cz}}=0$.)
* Tarry point: antipode of the Steiner point
       $\sec(A+\omega ):\sec(B+\omega ):\sec(C+\omega )$
* Focus of the Kiepert parabola:
       $\csc(B-C):\csc(C-A):\csc(A-B).$

## Other properties

The diameter of the circumcircle, called the circumdiameter and equal to twice the circumradius, can be computed as the length of any side of the triangle divided by the sine of the opposite angle:
    ${\text{diameter}}={\frac {a}{\sin A}}={\frac {b}{\sin B}}={\frac {c}{\sin C}}.$
As a consequence of the law of sines, it does not matter which side and opposite angle are taken: the result will be the same.
The diameter of the circumcircle can also be expressed as
    ${\begin{aligned}{\text{diameter}}&={\frac {abc}{2\cdot {\text{area}}}}={\frac {|AB||BC||CA|}{2|\Delta ABC|}}\\[5pt]&={\frac {abc}{2{\sqrt {s(s-a)(s-b)(s-c)}}}}\\[5pt]&={\frac {2abc}{\sqrt {(a+b+c)(-a+b+c)(a-b+c)(a+b-c)}}}\end{aligned}}$
where a, b, c are the lengths of the sides of the triangle and $s={\tfrac {a+b+c}{2}}$ is the semiperimeter. The expression $\scriptstyle {\sqrt {s(s-a)(s-b)(s-c)}}$ above is the area of the triangle, by Heron's formula. Trigonometric expressions for the diameter of the circumcircle include
    ${\text{diameter}}={\sqrt {\frac {2\cdot {\text{area}}}{\sin A\sin B\sin C}}}.$
The triangle's nine-point circle has half the diameter of the circumcircle.
In any given triangle, the circumcenter is always collinear with the centroid and orthocenter. The line that passes through all of them is known as the Euler line.
The isogonal conjugate of the circumcenter is the orthocenter.
The useful minimum bounding circle of three points is defined either by the circumcircle (where three points are on the minimum bounding circle) or by the two points of the longest side of the triangle (where the two points define a diameter of the circle). It is common to confuse the minimum bounding circle with the circumcircle.
The circumcircle of three collinear points is the line on which the three points lie, often referred to as a circle of infinite radius. Nearly collinear points often lead to numerical instability in computation of the circumcircle.
Circumcircles of triangles have an intimate relationship with the Delaunay triangulation of a set of points.
By Euler's theorem in geometry, the distance between the circumcenter O and the incenter I is
    ${\overline {OI}}={\sqrt {R(R-2r)}},$
where r is the incircle radius and R is the circumcircle radius; hence the circumradius is at least twice the inradius (Euler's triangle inequality), with equality only in the equilateral case.
The distance between O and the orthocenter H is
    ${\overline {OH}}={\sqrt {R^{2}-8R^{2}\cos A\cos B\cos C}}={\sqrt {9R^{2}-(a^{2}+b^{2}+c^{2})}}.$
For centroid G and nine-point center N we have
    ${\begin{aligned}{\overline {IG}}&<{\overline {IO}},\\2{\overline {IN}}&<{\overline {IO}},\\{\overline {OI}}^{2}&=2R\cdot {\overline {IN}}.\end{aligned}}$
The product of the incircle radius and the circumcircle radius of a triangle with sides a, b, c is
    $rR={\frac {abc}{2(a+b+c)}}.$
With circumradius R, sides a, b, c, and medians m$_a$, m$_b$, m$_c$, we have
    ${\begin{aligned}3{\sqrt {3}}R&\geq a+b+c\\[5pt]9R^{2}&\geq a^{2}+b^{2}+c^{2}\\[5pt]{\frac {27}{4}}R^{2}&\geq m_{a}^{2}+m_{b}^{2}+m_{c}^{2}.\end{aligned}}$
If median m, altitude h, and internal bisector t all emanate from the same vertex of a triangle with circumradius R, then
    $4R^{2}h^{2}(t^{2}-h^{2})=t^{4}(m^{2}-h^{2}).$
Carnot's theorem states that the sum of the distances from the circumcenter to the three sides equals the sum of the circumradius and the inradius. Here a segment's length is considered to be negative if and only if the segment lies entirely outside the triangle.
If a triangle has two particular circles as its circumcircle and incircle, there exist an infinite number of other triangles with the same circumcircle and incircle, with any point on the circumcircle as a vertex. (This is the n = 3 case of Poncelet's porism). A necessary and sufficient condition for such triangles to exist is the above equality ${\overline {OI}}={\sqrt {R(R-2r)}}.$

## Cyclic polygons

A set of points lying on the same circle are called concyclic, and a polygon whose vertices are concyclic is called a cyclic polygon. Every triangle is concyclic, but polygons with more than three sides are not in general.
Cyclic polygons, especially four-sided cyclic quadrilaterals, have various special properties. In particular, the opposite angles of a cyclic quadrilateral are supplementary angles (adding up to 180° or π radians).