Article 76JD9 Incircles and Excircles of Pythagorean triangles

Incircles and Excircles of Pythagorean triangles

by
John
from John D. Cook on (#76JD9)

This post will reveal the connection between my two previous posts: one on the Star Trek lemma and one on Pythagorean triples.

In the process of writing the latter, I looked at the Wikipedia article on Pythagorean triples and noticed this curious paragraph.

In every Pythagorean triangle, the radius of theincircleand the radii of the threeexcirclesare positive integers. Specifically, for a primitive triple the radius of the incircle isr=n(m-n), and the radii of the excircles opposite the sidesm2-n2,2mn, and the hypotenuse m2+n2are respectivelym(m-n),n(m+n), and m(m+n).

The citation for the paragraph above was the book by my former officemate, which led to the post on the Star Trek lemma. The passage in Arthur Baragar's book that Wikipedia cites is Exercise 15.3.

Let ABC be a right angle triangle with sides of integer length. Prove that the inradius r and the exradii ra, rb, and rc are all integers.

I don't know whether Arthur discovered this theorem, but I'll call it Baragar's theorem for this post.

Incircles and excircles

To unpack Baragar's theorem, let's start by saying what incircles and excircles are. Incircles are more familiar. Theincircle of a triangle is the largest circle that can be inscribed inside the triangle, and the radius of this circle is the inradius.

Since an incircle is an inscribed circle, you might expect an excircle to be a circumscribed circle, but that's not it. There are three excircles, one for each side. To find the excircle for a side, extend the other two sides and find the circle tangent to the side and the two extensions. The radius of an excircle is its exradius.

Proof

Baragar's theorem follows directly from Euclid's formula for Pythagorean triples mentioned in the previous post

osborne2.svg

and formulas for the inradius r and the exradii ra, rb, and rc.

exradii.svg

HereK is the area of the triangle, which in our case isab/2, ands is the semiperimeter, half the perimeter.

Expressing the radii in terms ofm andn gives the values cited by Wikipedia above.

Illustrating the theorem

I'd like to write a Python script to illustrate the theorem, and knowing the radii of the circles help, but we also need to know the centers of the circles.

The center of the incircle is the weighted average of the vertices, with weights given by the lengths of the opposite sides. That is, if the vertices areA,B, andC, and the sides opposite these vertices area,b, andc, the the incenter is

incenter_formula.svg

The centers for the excircles have remarkably similar expressions. For the incenter of the circle opposite a vertex, flip the sign of the corresponding side.

excenters.svg

Python code

Putting it all together, here's an illustrate the theorem.

baragar_circles.png

And here's the code that produced it. Note that everything in this section works for right triangles in general, not just Pythagorean triangles.

import numpy as npimport matplotlib.pyplot as pltdef connect(A, B): plt.plot([A[0], B[0]], [A[1], B[1]], "C0")def draw_circle(c, r, color): t = np.linspace(0, 2*np.pi) plt.plot(r*np.cos(t) + c[0], r*np.sin(t) + c[1], color=color)a, b, c, = 3, 4, 5A = np.array([0, b])B = np.array([-a, 0])C = np.array([0, 0])s = (a + b + c)/2K = a*b/2r = K/sra = K/(s - a)rb = K/(s - b)rc = K/(s - c)I = (a*A + b*B + c*C)/(a + b + c)Ia = (-a*A + b*B + c*C)/(-a + b + c)Ib = (a*A - b*B + c*C)/(a - b + c)Ic = (a*A + b*B - c*C)/(a + b - c)draw_circle(I, r, "C1")draw_circle(Ia, ra, "C2")draw_circle(Ib, rb, "C3")draw_circle(Ic, rc, "C4")plt.plot([-2*rc, 2*rb], [0, 0], "C0")plt.plot([0, 0], [-2*ra, 2*rc], "C0")plt.plot([(-2*ra - b)*a/b, 2*rb], [-2*ra, 2*rb*b/a + b], "C0")plt.gca().set_aspect("equal")plt.show()
The post Incircles and Excircles of Pythagorean triangles first appeared on John D. Cook.
External Content
Source RSS or Atom Feed
Feed Location http://feeds.feedburner.com/TheEndeavour?format=xml
Feed Title John D. Cook
Feed Link https://www.johndcook.com/blog
Reply 0 comments