Sunday Times Teaser 3052 – Porcus Facit Griphus
by Stephen Hogg
Published Sunday March 21 2021 (link)
“Argent bend sinister abased sable in dexter chief a hog enraged proper” blazons our shield (shaped as a square atop a semi-circle, with a 45° diagonal black band meeting the top corner). We’ve three shields. For the first, in centimetres, the top width (L) is an odd perfect cube and the vertical edge height of the band (v) is an odd two-figure product of two different primes. The others have, in inches, whole-number L (under two feet) and v values (all different). For each shield, the two white zones have almost identical areas. All three v/L values, in percent, round to the same prime number.
Give the shortest top width, in inches.
One Comment
Leave one →
-
Brian Gladman permalink1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859from math import pi, asinfrom itertools import combinationsfrom collections import defaultdict# primes in range 3..100pr = [2, 3, 5, 7]pr = pr[1:] + [x for x in range(11, 100, 2) if all(x % p for p in pr)]# list possible values for v in the first shieldvf = []for p, q in combinations(pr[:10], 2):prd = p * qif 10 <= prd < 100:vf.append(prd)# calculate the ratio of the areas of the white regionsdef areas(v, l):r = l / 2t = r - vy = ((2 * r * r - t * t) ** (1/2) - t) / 2alpha = pi - asin(y / r)return ((l - v) ** 2 + r ** 2 * alpha + t * y) / l ** 2# save solutions indexed on the nearest prime to (v / l)p2s = defaultdict(list)for v in vf:for i in range(1, 10, 2):l = i ** 3if l > v:# if the ratio of white areas is closerbt = areas(v, l)if 0.95 < rbt < 1.05:p = round(100 * v / l)if p in pr:p2s[p].append((v, l))print(f"V = {v} cm, L = {l} cm, P = {p}, (B / T) = {round(rbt, 6)}")# for candidate first shields find the other twofor p, l_vl in p2s.items():for v, l in l_vl:# the width of the first shield in inchesmin_w = l / 2.54for v in range(1, 24):for l in range(v + 1, 24):# if the ratio of white areas is closerbt = areas(v, l)if 0.95 < rbt < 1.05:p = round(100 * v / l)# if the prime matches that for the first shieldif p in p2s.keys():# save the smallest widthif l < min_w:min_w = lprint(f"V = {v:2} in, L = {l:3} in, P = {p}, (B / T) = {round(rbt, 6)}")print(f"\nMinimum width = {min_w} in")