Brain-Teaser 748: [Cutting corners]
From The Sunday Times, 16th November 1975 [link]
Young Bob had been given a carpentry set and with it a rectangular board (whose diagonal measured less than 1½ metres) on which to practise using his saw.
With straight cuts of successively greater length and aggregating to an exact number of metres, he first proceeded to saw dissimilar triangular pieces off each corner of the board in turn, the remaining quadrilateral piece being put aside for another day.
All the 12 sides of the sawn-off pieces measured exact and different numbers of centimetres.
What were the length and width of the board? (in cms).
As set this puzzle has multiple solutions, however if we interpret “less than 1½ meters” to mean “less than 150 cm, but more than 149 cm”, then we get a unique solution that is the same as that published in the newspaper.
This puzzle was originally published with no title.
[teaser748]



Jim Randell 12:30 pm on 5 May 2024 Permalink |
Perhaps the puzzle originally said “just less than 1½ metres”, but the “just” got lost somewhere.
The following program assembles pairs of Pythagorean triangles point-to-point. This gives us candidate widths and heights for the board. We then find two pairs with the same width that fit together to make a rectangle as specified.
By “dissimilar” triangles I am assuming that no pair of triangles is mathematically similar (i.e. none of them are multiples of the same primitive Pythagorean triangle).
The program runs in 108ms. (Internal runtime is 40ms).
Run: [ @replit ]
from enigma import ( defaultdict, pythagorean_triples, subsets, cproduct, seq_all_different, hypot, rev, ordered, ratio, cached, printf ) # diagonal limit D = 150 # possible triangles (x, y) -> z tris = dict(((x, y), z) for (x, y, z) in pythagorean_triples(D - 1)) # primitive triangle primitive = cached(lambda t: ratio(*t)) # assemble pairs of triangles: <combined-width> -> (<h1>, <h2>) -> (<w1>, <w2>) pairs = defaultdict(lambda: defaultdict(set)) for (k1, k2) in subsets(tris.keys(), size=2): for ((w1, h1), (w2, h2)) in cproduct((k, rev(k)) for k in (k1, k2)): w = w1 + w2 if w < D: (k, v) = ((h1, h2), (w1, w2)) if h1 < h2 else ((h2, h1), (w2, w1)) pairs[w][k].add(v) # choose a width and height for the initial rectangle for (w, h) in subsets(pairs.keys(), size=2): z = hypot(w, h) if not (D - 1 < z < D): continue # choose a pair of triangles for the base for k1 in pairs[w]: (h1, h2) = k1 # calculate the corresponding matched pair k2 = (h4, h3) = (h - h2, h - h1) if not (k2 > k1 and k2 in pairs[w]): continue for ((w1, w2), (w4, w3)) in cproduct(pairs[w][k] for k in (k1, k2)): # assemble the triangles (x1, y1, x2, y2, x3, y3, x4, y4) = (h1, w1, w2, h2, h4, w4, w3, h3) (z1, z2, z3, z4) = (tris[ordered(x, y)] for (x, y) in [(x1, y1), (x2, y2), (x3, y3), (x4, y4)]) # sum of cuts is a multiple of 100 T = z1 + z2 + z3 + z4 if T % 100 != 0: continue # sides are all different ts = (t1, t2, t3, t4) = ((x1, y1, z1), (x2, y2, z2), (x3, y3, z3), (x4, y4, z4)) if not seq_all_different(t1, t2, t3, t4): continue # triangle are dissimilar if not seq_all_different(primitive(ordered(*t)) for t in ts): continue # output solution printf("{w} x {h} -> {z:.2f}; {t1} {t2} {t3} {t4} T={T}")Solution: The board was: 28 cm × 147 cm.
And here is how the triangles fit together:
If we just look for any diagonal that is less than 150cm (which is a direct interpretation of the published puzzle text), then we find the following 23 solutions (ordered by length of diagonal):
and we see the published solution is the first of these (longest diagonal).
LikeLike
Hugo 3:36 pm on 5 May 2024 Permalink |
His saw cuts (each of which became the hypotenuse of a triangle) were progressively longer as he moved round the board to each corner in turn. Did you take that into account?
LikeLike
Jim Randell 4:45 pm on 5 May 2024 Permalink |
I didn’t check that the cut lengths can form an increasing sequence (going clockwise or anticlockwise around the board), as I decided he could just make the four cuts in ascending order, however they are arranged.
But if you do require this there are still 9 different solutions with diagonals <150 cm (including the published one).
LikeLike
Hugo 7:43 am on 6 May 2024 Permalink |
I think we can reduce it to a single solution if we add the words
“The board had the smallest possible area, consistent with what has been said.”
LikeLike