<s>[INST] Determinant formula for coordinates of circumcenter and orthocenter of a triangle I've come across the following formulas for coordinates of circumcenter $O=(x_O,y_O)$ and orthocenter $H=(x_H,y_H)$ of a triangle, in a formula book, stated without derivation. For a triangle with vertices $(x_i,y_i),$ $i \in \{1,2,3\}$,
$$x_O=\frac{\begin{vmatrix} x_1^2+y_1^2 & y_1 & 1 \\ x_2^2+y_2^2 & y_2 & 1 \\ x_3^2+y_3^2 & y_3 & 1 \end{vmatrix}}{2\begin{vmatrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{vmatrix}} \quad , \quad y_O=\frac{\begin{vmatrix} x_1 & x_1^2+y_1^2 & 1 \\ x_2 & x_2^2+y_2^2 & 1 \\ x_3 & x_3^2+y_3^2 & 1 \end{vmatrix}}{2\begin{vmatrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{vmatrix}} \tag{A}$$

$$x_H=\frac{\begin{vmatrix} y_1 & x_2x_3+y_1^2 & 1 \\ y_2 & x_3x_1+y_2^2 & 1 \\ y_3 & x_1x_2+y_3^2 & 1 \end{vmatrix}}{\begin{vmatrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{vmatrix}} \quad , \quad y_H=\frac{\begin{vmatrix} x_1^2+y_2y_3 & x_1 & 1 \\ x_2^2+y_3y_1 & x_2 & 1 \\ x_3^2+y_1y_2 & x_3 & 1 \end{vmatrix}}{\begin{vmatrix} x_1 & y_1 & 1 \\ x_2 & y_2 & 1 \\ x_3 & y_3 & 1 \end{vmatrix}} \tag{B}$$

The circumcenter case is pretty clear to me. Comparing two different equations of circumcircle
$$\begin{vmatrix} x^2+y^2 & x & y & 1 \\ x_1^2+y_1^2 & x_1 & y_1 & 1 \\ x_2^2+y_2^2 & x_2 & y_2 & 1 \\ x_3^2+y_3^2 & x_3 & y_3 & 1 \end{vmatrix} = 0 = \lambda(x^2+y^2 -2x_{O}x -2y_{O}y+c)$$
and equating the coefficients of $x,y$, one obtains $(A)$.
But I have not been able to make progress towards derivation of $(B)$. Can somebody provide a proof of it?
Please avoid an algebra-tedious proof. Thank you!
 [/INST] Consider instead triangle $A_1B_1C_1$ whose midtriangle is precisely triangle $ABC$.
A classical result says that the orthocenter $H$ of $ABC$ is the circumcenter of $A_1B_1C_1$.
It is easy to express the coordinates of points $A_1,B_1,C_1$ as functions of the coordinates of $A,B,C$ using relationships
$$\vec{AB}+\vec{AC}=\vec{AA_1} \implies A_1=B+C-A, \ \text{etc.} $$
Last step: one applies the first set of formulas to triangle with vertices $A_1,B_1,C_1$ .
Please note that my first explanation using barycentric coordinates was a much too indirect way.
</s>