*Spoiler for New Scientist Enigma 1708: *

From a point on one side of a rectangular sheet of paper I drew two straight lines, one of them to a point on one adjacent side and the other to a point on the other adjacent side. My sheet of paper was now divided into two triangles and a pentagon. The lengths of the sides of the triangles were all integers, the lengths of the sides of the pentagon were, in some order, five consecutive integers, each less than 50.

What were the dimensions of the sheet of paper?

Another Pythagorean triples problem. There may be some way to cut down the solution space more easily than I did, but I still got this fairly quickly.

You can look at a list of Pythagorean triples, or just generate all the ones with numbers less than 50 if you remember the formula for doing so. (I did the latter and then checked it with the former.) From that you can find all the possible pairs of hypotenuses which differ by no more than 4. I found 21 such pairs,or 23 if you count length 25 twice, since it is the hypotenuse of two triples: 15, 20, 25 and 7, 24, 25.

Then look through the possible triples and pick out the ones where a side of one triangle plus a side of the other differs by no more than 4 (but more than 0) from both the hypotenuses. For instance the pair 5, 12, 13 and 8, 15, 17 is eliminated because 5+8=17 is equal to one of the hypotenuses, while 5+15, 12+8, and 12+15 all differ from 13 by more than 4. Then look at the remaining two sides; they have to differ by no more than 4 (but more than 0).

I found four pairs of triples that meet those requirements:

- 7, 24, 25 and 20, 21, 29
- 10, 24, 26 and 20, 21, 29
- 16, 30, 34 and 21, 28, 35
- 12, 35, 37 and 24, 32, 40

Try the first of these:

The two unlabelled line segments would have to be 26 and 28, but these differ by 2 while 24 and 21 differ by 3, so the two rectangle sides come out unequal. So this doesn’t work. The only pair that does is 16, 30, 34 and 21, 28, 35. The right side of the rectangle is 16+21=37 so one of the remaining line segments must be 36 while the other is either 33 or 38. Since 28 and 30 differ by 2 the remaining line segments must differ by 2 as well, so must be 36 and 38. The rectangle is

and the dimensions are 37 by 66.