Law of cosines . The power of the point with respect to the circle is equal to both and . Therefore, which is the law of cosines. Using algebraic measures for line segments (allowing negative numbers as lengths of segments) the case of obtuse angle () and acute angle () can be treated simultaneously. By using the law of sines and knowing that the angles of a triangle must sum to 180 degrees, we have the following system of equations (the three unknowns are the angles): Then, by using the third equation of the system, we obtain a system of two equations in
Incircle and excircles of a triangle Because the Incenter is the same distance of all sides the trilinear coordinates for the incenter are The barycentric coordinates for a point in a triangle give weights such that the point is the weighted average of the triangle vertex positions. Barycentric coordinates for the incenter are given by where formula_7, formula_8, and formula_9 are the lengths of the sides of the triangle, or equivalently (using the law of sines) by where formula_11, formula_12, and formula_13 are the angles at the three vertices. The Cartesian coordinates of the incenter are a weighted average of the coordinates of the three vertices