Chapter 17
A Prime Number of Rails
A right-angled triangular field has one side exactly rails long, and all three sides are a whole number of rails. How many rails are needed to fence it right round?
What if that side were rails instead?
Solution
Part 1. We need a right triangle with whole-number sides, one of them . As is far too short to be the hypotenuse, take it as a leg, with other leg and hypotenuse . Then Since is prime, can only be written as , so and , giving and . The sides are , , (and indeed ), so the fence needs A prime leg pins the triangle down completely: there is only one such field.
Part 2. With the trick fails, because splits in many ways into two factors of the same parity, and each gives a different triangle, for example So the question now has no single answer; the field could be fenced in many different ways. A prime side fixes a right triangle, a composite side does not.