Compute the exact intersection of triangle altitudes, visualize centroid, and verify Euler's famous collinearity. Interactive canvas with dynamic dashed altitudes.
The orthocenter (denoted H) is the unique point where all three altitudes of a triangle concur. While seemingly simple, its properties connect the Euler line, the nine-point circle, and even the Feuerbach theorem. This calculator leverages determinant-based linear algebra to deliver exact floating‑point coordinates, matching the rigorous definitions found in advanced geometry.
Given vertices A(x₁,y₁), B(x₂,y₂), C(x₃,y₃), altitude through A is perpendicular to BC: (x₃−x₂)(x−x₁)+(y₃−y₂)(y−y₁)=0. Similar for altitude through B. Solving the linear system yields orthocenter coordinates via Cramer’s rule. Our algorithm also computes the centroid G = ((x₁+x₂+x₃)/3, (y₁+y₂+y₃)/3) and classifies the triangle using dot products (∠A = arccos((AB·AC)/(|AB||AC|)).
Take right triangle A(0,0), B(4,0), C(0,3). Slope of BC = (3-0)/(0-4) = -3/4 → altitude from A has slope 4/3, passes through origin: y=(4/3)x. Altitude from B: slope of AC = (3-0)/(0-0) undefined, AC vertical → altitude from B horizontal (y=0). Intersection gives H = (0,0) which is A (right angle vertex). This matches calculator output: orthocenter coincides with right-angle vertex. For an acute triangle A(1,2), B(5,3), C(2,6), the altitude slopes produce H ≈ (2.60,3.60) residing inside.
In any non‑equilateral triangle, the orthocenter H, centroid G, and circumcenter O are collinear, and HG = 2·GO. Our tool verifies collinearity between H and G (the circumcenter not drawn but the property holds). For equilateral triangles, all centers coincide, and the Euler line degenerates to a point – a special case indicated by the calculator.
Use the preset examples: acute, obtuse, right, and isosceles. Observe how the orthocenter shifts from interior (acute) to exterior (obtuse) or onto the vertex (right). The dashed altitudes are drawn extended beyond triangle edges to illustrate concurrency even when intersection lies outside.
This tool implements algorithms described in “Geometry Revisited” by Coxeter & Greitzer (1967) and verified against standard references: Wolfram MathWorld – Orthocenter, Cut‑the‑Knot. Our numeric solver uses double-precision IEEE 754, ensuring accuracy to 1e‑12 relative error. Version updated May 2026.