|
Problems & Puzzles:
Puzzles
Puzzle 1288. Bas van Dorst’s massive attack using AI: 64 results on
61 puzzles
On Oct 29, 2026, Bas van Dorst, a software developer from Breda, the Netherlands, sent me 64 results
for 61 puzzles of this site, obtained working with an AI model. Some lines from his e-mails:
"I'm a software developer, not a mathematician. I wanted to see how far LLM reasoning can go on hard
number problems, and your Prime Puzzles site turned out to be the perfect test."
"Working with an AI model, I ended up with 39 new records and 25 first answers to open questions.
General approach was to reason about why the old records worked instead of spending hours in front of
the whiteboard and running huge computer searches."
"All results, each with a short explanation and a Python script to verify it, are here:
https://github.com/basvandorst/praime"
"A few years ago, LLMs couldn’t even do basic calculations. Times have changed,
and with the right instructions and validations, they can be very powerful.
However, they still hallucinate, and their answers don’t always make sense.
Humans should stay in the loop."Asked about his view on
solving puzzles with AI, Bas answered:
"It’s like using a sudoku or Rubik’s cube solver. It works, but
you skip the fun part ;) For me, the fun part was improving an LLM’s
reasoning. Your website is great for this: clear challenges, a good
structure, clear explanations, and earlier solutions"
The 64 results
This table gathers Bas van Dorst's 64 results: 39 better solutions and 25 first answers to open
questions. They are numbered #1 to #64 and arranged in 8 sections, roughly from the simplest topics to
the hardest:
- Magic squares (5 results)
- Arrangements, figures and paths (7 results)
- Prime-generating formulas (9 results)
- Consecutive primes (3 results)
- Iterations and chains (5 results)
- Large primes and digit properties (16 results)
- Arithmetic functions, factors and covering sets (10 results)
- Proofs (9 results)
Each entry has the same structure: a) the challenge, b) Bas's contribution, c) the
verification and notes (including any Reviewer's note), and finally the Editor's decision.
Each puzzle name links to the original puzzle page, and says whether the result is a Better solution
or a First answer; a second link leads to Bas's own explanation and verification script. An appendix
after the table gives the full proofs of puzzles 890 and 516.
About the review. Everything in a), b) and c), including each Reviewer's note, comes from a
technical review carried out with Claude (Anthropic's AI model); each Editor's decision is my final
ruling as editor. All results were re-checked with five Python scripts run on my own computer
(verifica_BvD18, verifica_BvD24_directos, verifica_BvD8_optimalidad, verifica_BvD_pesados6 and
verifica_BvD_demostraciones9). Links to Bas's repository point to its snapshot of October 30, 2026
(commit 27b7837). As a general rule on this site, anything not explicitly forbidden by a puzzle's
statement is accepted.
| 1. Magic squares | #1 Puzzle 87 (Q1, Q2) Better solution | Bas's explanation and verification script a) Challenge. Q1: find two different 3×3 prime magic squares A and B such that A + B + 1 (cell by cell) is again a prime magic square, as small as possible. Q2: the same with three squares, A + B + C. Previous records (J. E. Everett): magic constants 1263 (Q1) and 3327 (Q2). b) Bas's contribution. Q1, magic constant 1041: [53 251 197 / 311 167 23 / 137 83 281] + [257 11 269 / 191 179 167 / 89 347 101] + 1 = [311 263 467 / 503 347 191 / 227 431 383]. Q2, magic constant 789: [41 113 59 / 89 71 53 / 83 29 101] + [29 167 71 / 131 89 47 / 107 11 149] + [67 79 163 / 199 103 7 / 43 127 139] = [137 359 293 / 419 263 107 / 233 167 389]. Method: the centre of a 3×3 magic square is a third of its constant, so he listed every 3×3 prime magic square with entries below 2000 by centre and tried pairs and triples from the smallest up. c) Verification and notes. OK (verifica_BvD18). Every square is magic, all entries are distinct primes, and the cell-by-cell sums are exact. Both records are beaten. Reviewer’s note: Bas also claims these are the smallest possible with entries below 2000; that claim was not checked independently and is not needed for the record. Editor’s decision: Accepted. As the reviewer’s note says, Bas’s claim that these are the smallest squares with entries below 2000 was not checked independently; it is not needed for the record. | #2 Puzzle 87 (Q3) First answer | Bas's explanation and verification script a) Challenge. Redo Q1 and Q2 with 4×4 prime magic squares. No solution had been published (Everett said he had some but did not send them). b) Bas's contribution. A + B + 1 with magic constant 548: [7 41 59 97 / 83 73 31 17 / 67 29 71 37 / 47 61 43 53] + [5 19 137 179 / 167 149 11 13 / 59 41 139 101 / 109 131 53 47] + 1 = [13 61 197 277 / 251 223 43 31 / 127 71 211 139 / 157 193 97 101]. A + B + C with magic constant 570: [3 13 37 127 / 103 61 5 11 / 43 17 97 23 / 31 89 41 19] + [3 17 53 113 / 107 59 7 13 / 47 37 83 19 / 29 73 43 41] + [7 41 59 97 / 83 73 31 17 / 67 29 71 37 / 47 61 43 53] = [13 71 149 337 / 293 193 43 41 / 157 83 251 79 / 107 223 127 113]. Method: squares built from two orthogonal Latin squares, which stay magic when added cell by cell. c) Verification and notes. OK (verifica_BvD8_optimalidad). All eight 4×4 squares are magic (rows, columns and both diagonals), each holds 16 distinct primes, and the sums are exact. First published answer. Bas does not claim these constants are the smallest. | #3 Puzzle 81 (c) First answer | Bas's explanation and verification script a) Challenge. Find the least triplet of 3×3 prime magic squares whose cells are p, 2p + 1 and 4p + 3 (first order), or p, 2p − 1 and 4p − 3 (second order), cell by cell. b) Bas's contribution. First order, magic sum 145060413: p-square [87167051 1319651 56573711 / 17760131 48353471 78946811 / 40133231 95387291 9539891]. Second order, magic sum 143168367: p-square [87113239 5530939 50524189 / 11133739 47722789 84311839 / 44921389 89914639 8332339]. The other two squares of each triplet follow cell by cell. Method: the magic sum is three times the centre, so he searched centres in increasing order and stopped at the first that works. c) Verification and notes. OK (verifica_BvD8_optimalidad). For each order, all 27 numbers are proven primes (below 2^64) and the three squares are magic. Minimality: Bas's own search, re-run with the script's exhaustive option (about 40 s), confirms these are the least centres; its logic was reviewed and is sound, but the check uses his code, not an independent one. | #4 Puzzle 106 First answer | Bas's explanation and verification script a) Challenge. John Everett found two 4×4 prime magic squares that add up, cell by cell, to a 4×4 square filled with 2000, but no such pair of 3×3 squares. For k different 3×3 magic squares of distinct primes adding up to the 3×3 square full of 2000: Q1 asks for the least k, Q2 for the largest k, and Q3 for a solution with k = 3 for 2001. No solutions had been published. b) Bas's contribution. Least k = 4 for 2000 (k = 2 is impossible): [17 89 71 / 113 59 5 / 47 29 101] + [101 29 47 / 5 59 113 / 71 89 17] + [269 1493 1061 / 1733 941 149 / 821 389 1613] + [1613 389 821 / 149 941 1733 / 1061 1493 269]. Largest k = 26, using centres 59 (8 squares), 71 (8), 73 (7), 127, 131 and 191. For 2001: k = 3 exists, [109 67 43 / 7 73 139 / 103 79 37] + [643 241 1297 / 1381 727 73 / 157 1213 811] + [1249 1693 661 / 613 1201 1789 / 1741 709 1153], and the largest k is 27. Method: a magic square plus its half-turned copy is a constant square, and in general the squares must have centres adding up to 2000 and corner offsets that cancel. c) Verification and notes. OK (verifica_BvD8_optimalidad). All squares are prime magic squares and the sums are exact; Bas's own search, re-run with the exhaustive option, confirms the least and largest k (4 and 26 for 2000; 3 and 27 for 2001). Reviewer’s note: Bas counts rotations and reflections of one square as different squares. His k = 4 answer is two squares, each added to its own half-turn, so only 2 squares are different up to rotation, and k = 26 uses all eight orientations of the centre-59 square. If the page treats a rotated square as the same square, the answers k = 4 and k = 26 do not stand. The k = 3 answer for 2001 uses three genuinely different squares and stands either way. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted; the statement does not forbid counting rotations and reflections of a square as different squares, so the answers k = 4 and k = 26 stand. | #5 Puzzle 249 Better solution | Bas's explanation and verification script a) Challenge. Q2: a 3×3 magic square of nine different primes that are each pandigital (using all ten digits 0–9), with a pandigital magic sum; smaller is better. Previous record (J. C. Rosa, 2005): magic sum 1530758629047. b) Bas's contribution. Magic sum 961547036829, with the square [c − b, c + a + b, c − a / c − a + b, c, c + a − b / c + a, c − a − b, c + b], where c = 320515678943, a = 3000000 and b = 4554. Method: each 12-digit number is split into two halves that each use five of the ten digits, so pandigitality is automatic and only primality has to be searched. c) Verification and notes. OK (verifica_BvD18). The square is magic; its nine entries are distinct 12-digit proven primes, each containing all ten digits; the magic sum 961547036829 is pandigital too. Reviewer’s note: the result follows Bas's reading of "pandigital" (all ten digits at least once); confirm it matches the page's rule. Editor’s decision: Accepted. The solution is correct: the nine entries are distinct pandigital primes, and the magic sum is pandigital too. | | 2. Arrangements, figures and paths | #6 Puzzle 92 (n = 5) Better solution | Bas's explanation and verification script a) Challenge. Stack balls into a tetrahedral pile of n levels. Every ball holds a different prime, and every ball above the bottom holds the sum of the three balls it rests on. Find the least pile for n = 5, 6 and 7. Previous record for n = 5: total 2,675,763. b) Bas's contribution. Total 16561 for n = 5, top ball 4999. Bottom level, row by row: 23 | 61 127 | 41 29 71 | 139 43 7 103 | 17 101 137 89 37. Method: fix the remainders of the bottom primes mod 3 (and a few small primes) so that no upper ball can be divisible by them, then fill the bottom with small primes by a guided search. c) Verification and notes. OK (verifica_BvD24_directos). All 35 balls are different proven primes, the top is 4999 and the total is 16561. Bas does not claim this pile is the least. | #7 Puzzle 92 (n = 6, 7) First answer | Bas's explanation and verification script a) Challenge. The same pile for n = 6 and n = 7; none had been published. b) Bas's contribution. n = 6: total 80076, top 23911, bottom level 43 | 137 19 | 61 59 79 | 173 37 197 211 | 223 53 13 191 17 | 5 229 71 67 73 283. n = 7: total 457468, top 135433, bottom level 409 | 457 131 | 61 83 139 | 47 281 313 71 | 241 331 79 41 379 | 7 59 11 431 181 593 | 13 557 127 211 19 347 109. c) Verification and notes. OK (verifica_BvD24_directos). The 56 and 84 balls are different proven primes, with the stated tops and totals. First published piles; not claimed to be the least. | #8 Puzzle 77 First answer | Bas's explanation and verification script a) Challenge. A pine of R rows has 1 number at the top, 2 below, and so on; each number is the average of the two it touches below, and all are different primes. Q1 asks for pines with R > 8. The page had 9 rows (J. Tramu, J. van Delden); van Delden could not find 10 rows (2012). b) Bas's contribution. The first 10-row pine, 55 different primes, with bottom row 3548161 12418561 54405121 351859201 368417281 3437575681 8200980481 18681062401 47753502721 809036659201. Method: every entry is ≡ 1 mod 3, 5, 7 and 11, so those primes never divide any of the 55 numbers. c) Verification and notes. OK (verifica_BvD18). Each entry is the exact average of the two below it, and all 55 are different proven primes. All of them end in 1, so it is also a one-colour pine for Q3. Bas claims the first 10-row pine, not the least one. | #9 Puzzle 342 (Q3) Better solution | Bas's explanation and verification script a) Challenge. Write a different square on each face of a die so that the three faces around each of the 8 corners add up to 8 different primes, with the least total. Previous record (J. Tramu): 1330. b) Bas's contribution. Total 658, with opposite faces (4, 64), (36, 144) and (49, 361); the corner sums are 89, 401, 197, 509, 149, 461, 257 and 569. He also claims 658 is the minimum. c) Verification and notes. OK (verifica_BvD18). Minimality was confirmed by an independent exhaustive search: with a total below 659 every face is at most 252, and no choice of six squares and opposite pairing does better. Case closed: 658 cannot be improved. | #10 Puzzle 359 (Q1) Better solution | Bas's explanation and verification script a) Challenge. Arrange the first N primes in a circle so that neighbours and diametrically opposite primes never share a digit; how large can N be? Previous record (A. Sahay, 2006): N = 108. b) Bas's contribution. A circle of the first 202 primes, and a proof that 202 is the maximum: exactly 101 of the first 202 primes contain the digit 1, so they must alternate; from 203 to 297 more than half contain a 1; and from the 298th prime (1973) on, that prime is compatible only with 2 and 5 but needs three partners. c) Verification and notes. OK (verifica_BvD8_optimalidad). Every neighbour pair and every opposite pair is digit-disjoint. The maximality argument was checked independently, both counts included. Case closed: N = 202 is the maximum. | #11 Puzzle 189 (Task 2) First answer | Bas's explanation and verification script a) Challenge. Arrange 1, 2, …, n so that every two neighbours a, b have both a + b and a2 + b2 prime. Is there a solution for every n above some n0, and what is n0? T. D. Noe left 22 values of n open. b) Bas's contribution. All open cases settled: paths exist for 52, 53, 56, 58 and every open value above (plus 12 and 31, missed earlier); none exist for 44, 45, 46, 47, 49, 51, 54 and 57. With paths for every n from 58 to 200, he gives n0 = 57. c) Verification and notes. OK (verifica_BvD8_optimalidad). The 143 paths for n = 58–200 and those for 12, 31, 52, 53 and 56 were checked. The non-existence for 44–54 comes from Bas's exhaustive C search, re-run here with the same result; for 57 a short degree argument (54 and 47 each have a single neighbour) was checked independently. Note: n0 = 57 is proven only up to n = 200; that paths exist for every n above 200 is not proven, as Bas states. Editor’s decision: Accepted, with the reviewer’s caveat: n0 = 57 is proven only up to n = 200; that paths exist for every n above 200 is not proven, as Bas himself states. | #12 Puzzle 172 (Q1) First answer | Bas's explanation and verification script a) Challenge. A complete prime ruler has gaps equal to 1 or a prime, and measures every length from 1 to its total length L. Find the shortest one using 1 and each of the first K primes. R. Opao solved K ≤ 8; Q1 asks for K = 9 and 10. b) Bas's contribution. K = 9: L = 113, gaps 1.1.1.1.1.1.1.3.19.17.7.23.2.13.5.11.1.1.1.1.1.1. K = 10: L = 144, gaps 1.1.1.1.1.1.23.1.11.17.3.13.19.29.5.7.1.1.1.2.1.1.1.1.1. Both claimed minimal. Method: a repeated prime, or one outside the first K, can be replaced by the same number of 1s, so only the number of 1s matters; an exhaustive search in C then finds the least. c) Verification and notes. OK (verifica_BvD8_optimalidad). Both rulers are complete. The reduction argument is sound. Minimality rests on Bas's C search, re-run here: no complete ruler with one 1 fewer exists (K = 9 in 11 s, K = 10 in 2.5 min). This C program is not part of the Python verification files, since it needs a C compiler. | | 3. Prime-generating formulas | #13 Puzzle 227 Better solution | Bas's explanation and verification script a) Challenge. Find t such that the integer parts of t, t2, …, tj are all prime, with j as large as possible (Crandall–Pomerance, problem 1.75). On the page: 37 powers (P. Carmody, 2004); best known: 100 powers (D. Terr). b) Bas's contribution. 239 powers, with t = a/2^2760, ⌊t⌋ = 3001 and a an 835-digit integer (in his data file). Method: each new prime narrows the interval for t; starting near 3000 keeps that interval wide enough, with backtracking at dead ends. c) Verification and notes. OK (verifica_BvD24_directos). ⌊tj⌋ is a probable prime for every j = 1 to 239. | #14 Puzzle 597 (Q2) Better solution | Bas's explanation and verification script a) Challenge. For a quadratic f, count how many of f(0), …, f(10000) are primes or semiprimes. Previous record (E. Vantieghem): x2 + x + 247757, with 9567. b) Bas's contribution. x2 − 9999x + 25242757, with 9743. Method: shift the best known quadratic so its minimum sits in the middle of the range, where values are smallest. c) Verification and notes. OK (verifica_BvD24_directos): 9743 hits for x = 0–10000. Reviewer’s note: the new polynomial is Vantieghem's own one shifted by x → x − 5000, so the gain comes from re-centring it, not from a new polynomial. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted, and shifting a known polynomial is not forbidden. | #15 Puzzle 1028 (Q2) Better solution | Bas's explanation and verification script a) Challenge. Find f(n) = Σ (Ai·n mod Bi) giving as many distinct primes in a row as possible. Previous record (D. Kamenetsky, 2021): 5 terms, 41 primes. b) Bas's contribution. 5 terms, 49 primes for n = 1–49: (35968n mod 35969) + (9481023n mod 94764426) + (204182n mod 4083624) + (1230n mod 36886) + (13256n mod 530202). Also 6 terms, 59 primes: (35968n mod 35969) + (9189321n mod 91701916) + (417875n mod 8357494) + (48429n mod 1452860) + (10880n mod 435176) + (33186n mod 1659256). Method: the remainders act like a staircase that jumps between blocks of ten primes in arithmetic progression with difference 9699690 (19#). c) Verification and notes. OK. The 5-term version is in verifica_BvD18; the 6-term version was checked during this review (59 distinct proven primes) but is not in the verification files. | #16 Puzzle 1097 Better solution | Bas's explanation and verification script a) Challenge. A prime generator that is not a polynomial but may use the mod operator. Previous record (D. Rotondo): 75 primes, 65 of them different. b) Bas's contribution. 130 distinct primes for n = 0–129 from f(n) = 9699690·(n mod 10) + Σ ej·((⌊n/10⌋ + j) mod 13), with e = [933516151, −104434997, 23700127, −128911085, 56766199, 48442819, −1599797, −152799521, 32343931, −71698241, 45728731, 44720503, 43956415]/1014. Method: 13 blocks of ten primes in arithmetic progression, glued with Paolo Lava's trick of solving a linear system for the ej. c) Verification and notes. OK (verifica_BvD24_directos): every value is a whole number, prime and distinct. Reviewer’s note: as A. Stinchcombe remarks on the page, such formulas can reproduce any chosen list; the real content is the 13 blocks of ten primes in progression. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted. | #17 Puzzle 1099 Better solution | Bas's explanation and verification script a) Challenge. Using only n, constants and floor divisions ⌊n/k⌋, write a formula prime for n = 0, 1, 2, … as long as possible. Previous record (E. Vantieghem, 2022): 120 distinct primes. b) Bas's contribution. 570 distinct primes for n = 0–569 from H(n) = 35969 + 9699690n + Σ cj·⌊n/(10j)⌋, with 56 floor terms (coefficients in his data file). Method: keep adding blocks of ten primes in progression with difference 19#, each needing one more floor term. c) Verification and notes. OK (verifica_BvD24_directos): 570 distinct proven primes. Reviewer’s note: the same remark as for 1097 applies; the content is the list of 57 blocks of primes in progression. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted. | #18 Puzzle 1135 Better solution | Bas's explanation and verification script a) Challenge. Find polynomials giving many consecutive primes whose digits do not alternate parity. Previous record (D. Rotondo): n4 + 29n2 + 101, 19 primes. b) Bas's contribution. 5n4 − 330n3 + 9395n2 − 130510n + 709337 gives 30 primes for n = 0–29. Method: the polynomial is always ≡ 17 mod 40, so every value ends in an odd digit followed by 7 and can never alternate parity; only primality had to be searched. c) Verification and notes. OK (verifica_BvD18): 30 proven primes, all ≡ 17 mod 40, none alternating. | #19 Puzzle 1209 (Q2) Better solution | Bas's explanation and verification script a) Challenge. Find a polynomial giving many consecutive primes that are all lucky or all unlucky. On the page: D. Rotondo, 30 different unlucky primes; G. Kalogeropoulos (2025), |36n2 − 810n + 2753| for n = 0–44, 45 claimed. b) Bas's contribution. −3x2 + 2799x + 22433 gives 34 unlucky primes for x = 0–33. Method: the second step of the lucky sieve removes every number ≡ 5 mod 6, so a polynomial always ≡ 5 mod 6 gives only unlucky values. He also points out that the 45-value answer uses absolute values, which turns 5 mod 6 into 1 mod 6, so some values are lucky. c) Verification and notes. OK (verifica_BvD18): 34 distinct unlucky primes, all ≡ 5 mod 6. His objection was confirmed during this review: in the 45-value answer, 1801, 1693, 991, 613 and 163 are lucky, and the longest run of unlucky primes is 26. Reviewer’s note: if you agree, the record listed on the page should be corrected to 26. Editor’s decision: Accepted, including the correction in the reviewer’s note: G. Kalogeropoulos’s solution gives only 26 consecutive unlucky primes, from 359 (n = 19) to 36809 (n = 44), so the record listed on the page will be corrected. | #20 Puzzle 1217 Better solution | Bas's explanation and verification script a) Challenge. Find functions of p(n+1) and p(n) that are prime for long runs of successive n, preferably with many different primes. Previous record (A. Stinchcombe, 2025): 30,800 successive n, 22 different primes. b) Bas's contribution. With h = (p(n+1) − p(n))/2, half the gap: |S(h − 43)|, S being the Dress–Landreau sextic, is prime for 103,518 successive n with 53 different primes; and h2 − 79h + 1601 (Euler's polynomial, shifted) is prime for 1,319,943 successive n with 41 different primes. Method: prime gaps stay small for a long time, so a polynomial that is prime on a whole window of small inputs stays prime until the first gap too large for that window. c) Verification and notes. OK (verifica_BvD24_directos): both runs and both counts of distinct primes confirmed. Both beat the record in length and in distinct primes. Reviewer’s note: choose which to list; his repository leads with the sextic, his e-mail with Euler's polynomial. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted. Both results beat the record and both will be listed: the sextic (103,518 successive n, 53 different primes) and Euler’s polynomial (1,319,943 successive n, 41 different primes). | #21 Puzzle 1230 Better solution | Bas's explanation and verification script a) Challenge. Find a formula giving as many different primes in a row as possible, each with an even-length period of 1/p. Previous record (J. M. Rebert, 2025): 29 primes. b) Bas's contribution. The same quartic as in puzzle 1135, 5n4 − 330n3 + 9395n2 − 130510n + 709337, gives 30 primes for n = 0–29. Method: primes ≡ 17 mod 40 have (10/p) = −1, which forces an even period. c) Verification and notes. OK (verifica_BvD18): all 30 primes have an even period. | | 4. Consecutive primes | #22 Puzzle 65 Better solution | Bas's explanation and verification script a) Challenge. Find multigrade relations made of primes: two lists with equal sums, equal sums of squares, and so on up to some degree. Here, with consecutive primes only. Previous record (A. Stinchcombe, 2021): degree 3, with 8 consecutive primes. b) Bas's contribution. Degree 5 with 12 consecutive primes: for p = 19765897565467, the lists p + {0, 16, 22, 54, 60, 76} and p + {4, 6, 36, 40, 70, 72} have equal sums of k-th powers for k = 1 to 5. Also degree 4 with 10 consecutive primes starting at 835589088973. Method: take a known degree-5 Prouhet–Tarry–Escott solution, double it (gaps between odd primes are even) and sieve for a start where all twelve numbers are consecutive primes. c) Verification and notes. OK. The degree-5 relation is in verifica_BvD18 (12 consecutive proven primes, equal power sums for k = 1–5); the degree-4 relation was checked during this review but is not in the verification files. | #23 Puzzle 356 (Q1) Better solution | Bas's explanation and verification script a) Challenge. Find K primes whose pairwise sums (a prime added to itself included) are all different, with the largest prime as small as possible. Previous records (F. Schneider, 2006): 751 (K = 20), 1409 (K = 25), 2273 (K = 30). b) Bas's contribution. Maxima 661, 1297 and 2213. K = 20: 2 3 5 29 79 97 107 193 239 311 349 401 461 541 577 599 607 641 647 661. K = 25: 2 3 13 31 103 151 281 307 347 389 433 449 577 599 673 761 797 983 1033 1063 1097 1117 1289 1291 1297. K = 30: 2 3 7 23 89 139 193 211 467 503 547 631 659 719 877 997 1021 1301 1439 1451 1549 1613 1811 1873 1907 2053 2083 2161 2207 2213. Method: simulated annealing. He also notes that Schneider's K = 10 set {2, 3, 5, 13, 23, 37, 41, 67, 83, 89} breaks the self-sum rule (13 + 13 = 3 + 23). c) Verification and notes. OK (verifica_BvD18; the sums including a prime added to itself were also checked during this review). Not claimed minimal. Editor’s decision: Accepted, including Bas’s observation that F. Schneider’s K = 10 example with maximum 89 breaks the self-sum rule (13 + 13 = 3 + 23). | #24 Puzzle 522 Better solution | Bas's explanation and verification script a) Challenge. Take three disjoint sets of k consecutive primes such that each prime of the first set divides the sum of the matching primes of the other two. With the first set being the first k primes, push k. Previous record (F. Schneider): k = 14. b) Bas's contribution. k = 15 (divisors 2 to 47): second set starting at 3355845769, third at 5130974053. Method: each run gets a key of remainders, and two runs fit when one key is the negative of the other, so sorting replaces pairing. c) Verification and notes. OK (verifica_BvD24_directos). Reviewer’s note: His further claim that this is the smallest pair for k = 15 below 2·1010 was not checked. Editor’s decision: Accepted. As the reviewer’s note says, Bas’s claim that this is the smallest pair for k = 15 below 2·1010 was not checked; it is not needed for the record. | | 5. Iterations and chains | #25 Puzzle 299 (Q2) First answer | Bas's explanation and verification script a) Challenge. Under R. Knjzek's rule a prime p goes to the largest prime factor of 3p + 1. Find the smallest start of an increasing run of 9 primes. L. Pebody had shown only that it is above 7·108. b) Bas's contribution. 35014031359 = 68386780·29 − 1. Method: in an increasing run p + 1 is multiplied by 3/2 at each step, so every run of 9 has the shape m·3k·29−k − 1, and a sieve over m finds the least m. c) Verification and notes. OK (verifica_BvD24_directos): the nine primes and every step of the rule. Minimality was checked independently: no smaller m gives nine primes. Case closed. | #26 Puzzle 476 (Q1) Better solution | Bas's explanation and verification script a) Challenge. Find a Collatz seed whose odd terms form the longest possible chain of primes. Previous record (J. K. Andersen's chain, extended by D. Dima): 19 primes. b) Bas's contribution. A 458-digit seed (in his data file) whose first 30 odd terms are all prime. Method: build the chain backwards and keep the 40 smallest predecessors at each step (beam search). c) Verification and notes. OK (verifica_BvD24_directos): 30 consecutive odd terms, all probable primes. | #27 Puzzle 905 Better solution | Bas's explanation and verification script a) Challenge. Choose a polynomial P and a start k, set f(0) = k and f(m) = P(f(m − 1)), and get as many different primes in a row as possible. A linear P(x) = x + d is forbidden, because it just walks along a known arithmetic progression of primes. Previous record (J. K. Andersen, 2017): 19. b) Bas's contribution. 28 primes from P(x) = x + d + 18·(x − a0)(x − a1)…(x − a25), where aj are the terms of PrimeGrid's AP-27 (a0 = 224584605939537911, d = 81292139·223092870). The last prime has 451 digits. c) Verification and notes. OK (verifica_BvD24_directos); the 28th prime is a probable prime. Reviewer’s note: the polynomial has degree 26, so it is allowed by the letter of the rule, but on the 27 terms of the AP-27 it behaves exactly like the forbidden x + d; only the 28th prime comes from the added term. Bas himself labels it "beaten (within the stated rules)". Decide whether it meets the spirit of the puzzle. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted; the puzzle forbids only a linear P(x) = x + d, and Bas’s polynomial has degree 26. | #28 Puzzle 908 (Q2) Better solution | Bas's explanation and verification script a) Challenge. For primes p < q and N = pq, take r1 = N mod (p + q), r2 = N mod r1, and so on until 1; all remainders must be prime or 1. Find chains with more than six remainders. Previous record (F. Schneider, 2018): 14. b) Bas's contribution. 34 remainders (199, 197, 193, …, 5, 2, 1) with p = 68516818704324257201795329467591133865835633315118443095966860117 and q = p2 − p + 199. Method: this q forces the first remainder to be 199; the rest of the chain is steered with the Chinese remainder theorem. c) Verification and notes. OK (verifica_BvD24_directos). p and q are probable primes; the remainders are small proven primes. | #29 Puzzle 1251 (Q3) Better solution | Bas's explanation and verification script a) Challenge. Repeating p → greatest prime divisor of a·p + b, every prime falls into a cycle. Which (a, b) give many different cycles below 109? Previous record (G. Gusev): (1, 2358719), 72 cycles. b) Bas's contribution. (a, b) = (1, 518918399), with 477 cycles (listed in his data file). Method: b + 1 = 28·34·52·7·11·13 has very many divisors, and each way of splitting it into factors tends to build a cycle. c) Verification and notes. OK (verifica_BvD24_directos): all 477 cycles close, are distinct, and stay below 109. | | 6. Large primes and digit properties | #30 Puzzle 75 (Q2) First answer | Bas's explanation and verification script a) Challenge. Q2. Redo, with palprimes, four claims about primes and 2000: the smallest and the largest palprime with 2000 digits, the smallest palprime with digit sum 2000, and the smallest 2000-digit palprime with digit sum 2000. b) Bas's contribution. The three claims about 2000 digits are impossible: every palindrome with an even number of digits is a multiple of 11. The smallest palprime with digit sum 2000 has 223 digits: 10223 − 1 − (10221 + 10220 + 10124 + 10111 + 1098 + 102 + 10). Method: list candidates in increasing order and test them. c) Verification and notes. OK (verifica_BvD18): palindrome, digit sum 2000, 223 digits, probable prime. The impossibility argument is correct, and 223 is the least possible length (222 nines give only 1998). Reviewer’s note: that this number is the smallest candidate of that length was not checked. Editor’s decision: Accepted, with the reviewer’s caveat that this 223-digit palprime was not checked to be the smallest of its length. | #31 Puzzle 99 Better solution | Bas's explanation and verification script a) Challenge. Find primes p with R(p) prime and p2 = R(R(p)2), where R reverses the digits; the larger the better. Previous record (F. Russo, 2000): 50 digits. b) Bas's contribution. p = 103000 + 101889 + 101500 + 101111 + 1, 3001 digits. Method: if p is a palindrome and squaring it produces no carries, p2 is a palindrome too and the condition holds by itself. c) Verification and notes. OK (verifica_BvD24_directos): p and p2 are palindromes; p is a probable prime. Reviewer’s note: this is the special case R(p) = p, a palprime with a palindromic square; Russo's record is not a palindrome. Decide whether palindromes are within the spirit of the puzzle. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted, and the statement does not exclude palindromes. | #32 Puzzle 134 (Q3) Better solution | Bas's explanation and verification script a) Challenge. A carrousel step turns every 1 into 3, 3 into 7, 7 into 9 and 9 into 1; a carrousel prime stays prime for three steps. Q3 asks for a very large one with only one active digit. Previous record (M. Bell, 2001): 50 digits. b) Bas's contribution. A 201-digit carrousel prime 10·B + 1, whose four images are 10·B + 1, 3, 7, 9; B uses only inactive digits and was built with the Chinese remainder theorem so that no small prime divides any of the four. c) Verification and notes. OK (verifica_BvD24_directos): one active digit, four probable primes. | #33 Puzzle 134 (Q4) First answer | Bas's explanation and verification script a) Challenge. A 100-digit carrousel prime with only one inactive digit; no answer had been published. b) Bas's contribution. 9773317917193993331131917339173977131919931391113371131103919313311737119331717179393197317197911119, with a single 0. c) Verification and notes. OK (verifica_BvD18): 100 digits, one inactive digit, all four carrousel images are probable primes. | #34 Puzzle 179 (Q1) First answer | Bas's explanation and verification script a) Challenge. Find an alphametic made of number words in which every number is prime; the examples on the page were not all prime. b) Bas's contribution. TROIS + ONZE = SEPT + SEPT, that is 12689 + 6053 = 9371 + 9371, all prime. Also CINQ + CINQ + ONZE = 3·SEPT, that is 2879 + 2879 + 6701 = 3·4153. Both are true as words too (3 + 11 = 7 + 7; 5 + 5 + 11 = 3·7). Method: balance the words first, then each alphametic is one linear equation checked over all digit assignments. c) Verification and notes. OK (verifica_BvD18): the sums hold, each letter stands for one digit and different letters for different digits, and all numbers are proven primes. | #35 Puzzle 307 Better solution | Bas's explanation and verification script a) Challenge. Improve a record for huge Smith numbers within one of the listed recipes; here P. Costello's N = P·Q·10M, Q a Mersenne prime and P a small prime. Previous record (L. Soule, 2005): 127·(225964951 − 1)·10M. b) Bas's contribution. 7·(2136279841 − 1)·102192, 41,026,513 digits, built on the newest known Mersenne prime. c) Verification and notes. OK (verifica_BvD_pesados6): S(Q) = 184,595,719 and S(7·Q) = 184,611,070, so the Smith condition S(7·Q) = 7 + S(Q) + 7·2192 holds. The primality of Q rests on GIMPS. Reviewer’s note: the page prints Soule's record with 104634, but recomputing it gives M = 662 (4634 = 7·M); the exponent, and the digit count with it, should be corrected. Editor’s decision: Accepted, including the correction in the reviewer’s note: in L. Soule’s record the exponent will be corrected from 104634 to 10662, together with its digit count. | #36 Puzzle 324 (Q3) Better solution | Bas's explanation and verification script a) Challenge. Read a number in pairs "c d" meaning "digit d appears c times"; it is self-descriptive if the inventory is exact. Q3 asks for the largest self-descriptive prime, repeated pairs allowed. Previous record (C. Rivera, from P. Capelle's largest number): 70 digits. b) Bas's contribution. 99989897979696968585858484848473737373737373626262626262515140405151404051, 74 digits. Method: reordering the pairs keeps a number self-descriptive, so he took the largest possible one (74 digits, Manning 2025) and listed its pair orderings from the top down until one was prime. c) Verification and notes. OK (verifica_BvD18): probable prime; the pairs 99, 98, 97, 96, 85, 84, 73, 62, 51, 40 (some repeated) describe its digits exactly. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted. | #37 Puzzle 340 (Q1) Better solution | Bas's explanation and verification script a) Challenge. Find primes p whose digits appear as one unbroken block inside p2. Previous record (G. Resta): 1339 digits. b) Bas's contribution. p = ⌈103923·(1 + √22001)/2⌉, 3925 digits; p2 contains p right after the digits "55". Method: Resta's idea of aiming for a square of fixed shape, which becomes a quadratic whose root gives p. c) Verification and notes. OK (verifica_BvD24_directos): p is a probable prime and appears in p2 at the stated place. | #38 Puzzle 373 (Q3) Better solution | Bas's explanation and verification script a) Challenge. A self number is never of the form m + (digit sum of m). Find large self primes. Previous record (L. Pebody): 224036583 − 1. b) Bas's contribution. 282589933 − 1 (24,862,048 digits) is a self number. Method: a generator of n differs from n only in its last few digits, so the test reduces to two small equations on the last 9 digits (Pebody's test). c) Verification and notes. OK (verifica_BvD_pesados6), with the exact two-case test, itself checked against brute force; it also confirms Pebody's record. The primality rests on GIMPS. Editor’s decision: Accepted. Puzzles 307, 373, 450 and 607 rest on primes proven by GIMPS, PrimeGrid and the Prime Pages, which will be credited when publishing. | #39 Puzzle 398 (Q2) Better solution | Bas's explanation and verification script a) Challenge. Find large primes for which inserting any digit between two of its digits always gives a composite number. Previous record (G. Resta): 10999 + 33592689, 1000 digits. b) Bas's contribution. N = A·10900 + 1, 1057 digits, with A = 1057447767801982899810936078986870322855097083184870799512294142679453394807877910422539690997221686644824565309308629748242833059104863529225434120688108130. Method: insertions into the run of zeros depend only on the digit and the position mod 240, and A was chosen with the Chinese remainder theorem so that 31 small primes kill about 90% of them. c) Verification and notes. OK (verifica_BvD_pesados6). N is proven prime (Pocklington, base 3). All 10,560 interior insertions are composite: 9,987 have a factor below 105 and 573 fail a Fermat test. | #40 Puzzle 438 Better solution | Bas's explanation and verification script a) Challenge. The same question as puzzle 398, as the page itself notes. Previous record (W. E. Clark): 200 digits. b) Bas's contribution. The same 1057-digit prime as in puzzle 398. c) Verification and notes. OK (verifica_BvD_pesados6), the same check as 398. | #41 Puzzle 607 (Q1) Better solution | Bas's explanation and verification script a) Challenge. Find the largest prime power pn (n > 1) missing some decimal digit. Previous record (E. Vantieghem): (19·101169 + 1)6, 7022 digits, no digit 2. b) Bas's contribution. (101888529 − 10944264 − 1)7, 13,219,703 digits, with no digit 6. Method: powers of a prime with few nonzero digits are long runs of 9s and 0s with short blocks between them; he used the largest known palindromic prime. c) Verification and notes. OK (verifica_BvD_pesados6): no 6 among the 13,219,703 digits, which are 5,665,568 zeros, 7,554,099 nines and only 46 other digits. Reviewer’s note: The primality of the base rests on the Prime Pages. Editor’s decision: Accepted. The primality of the base rests on the Prime Pages, which will be credited when publishing. | #42 Puzzle 793 Better solution | Bas's explanation and verification script a) Challenge. Find the smallest prime with K different digits in which every pair of those digits stands side by side somewhere, for K = 5 to 10. Current values: E. Vantieghem's. b) Bas's contribution. Smaller primes for three cases. K = 6: 1012031234062461463. K = 8: 10203123405142534560716273657467. K = 10: 101203123405142534560716273647567809182938495869789. Method: digits as towns and pairs as roads, so the shortest number is the shortest walk using every road (an Euler path). c) Verification and notes. OK (verifica_BvD24_directos): every pair is contiguous and each number is smaller than Vantieghem's; K = 6 is proven prime, K = 8 and 10 are probable primes. Not claimed minimal. Reviewer’s note: for K = 6 Bas uses the digits {0, 1, 2, 3, 4, 6}, while Vantieghem used {0, …, 5}; this is valid only if any K digits are allowed. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted, so any K different digits may be used. | #43 Puzzle 808 Better solution | Bas's explanation and verification script a) Challenge. Find palprimes that are palindromes in as many bases as possible (base 10 counted, the trivial base p − 1 left out). Previous record (E. Vantieghem): 1002113112001, 82 bases. b) Bas's contribution. 108864424468801, palindromic in 227 bases. Method: a 3-digit palindrome [1, c, 1] in base b means p − 1 = b(b + c), so every divisor of p − 1 near √p gives a base; he chose p ≡ 1 mod 720720 so that p − 1 has a huge number of divisors. c) Verification and notes. OK (verifica_BvD18): 227 bases under the stated convention. Reviewer’s note: confirm that this convention is the page's. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted, including the convention of counting base 10 and leaving out the trivial base p − 1. | #44 Puzzle 957 Better solution | Bas's explanation and verification script a) Challenge. Write large primes as expressions using the digits 1–9, 1–9 and 0, 9–1, or 9–1 and 0, each once and in order, with + − × / ^ and parentheses. Previous records (P. Cleary, 2019): 489, 753, 691 and 691 digits. b) Bas's contribution. All four types beaten: (a) 1−2+3·(4·5^6)^(7·89) = 3·62500^623 − 1, 2989 digits; (b) −(1+2)+34^(5·6·7+890) = 34^1100 − 3, 1685 digits; (c) −9+8·7^(6·54·3^2)·1 = 8·7^2916 − 9, 2466 digits; (d) −9+8·76^(54−3+2^10) = 8·76^1075 − 9, 2023 digits. c) Verification and notes. OK (verifica_BvD24_directos): the digits appear in the required order and all four are probable primes. Reviewer’s note: expressions (b), (c) and (d) start with a minus sign; confirm the rules allow it. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted, including expressions that start with a minus sign. | #45 Puzzle 1190 Better solution | Bas's explanation and verification script a) Challenge. Find the largest prime Friedman numbers with 7, 8, 9 and 10 digits: primes that can be written with their own digits and + − × / ^. Previous record for 10 digits (A. Stinchcombe, 2024): 9999999001. b) Bas's contribution. 9999999967 = ((9·9+9)/9)^(9+9/9) − 6·7 + 9. c) Verification and notes. OK (verifica_BvD18). The expression uses exactly the digits of the number: eight 9s, one 6 and one 7. Since 9999999967 is the largest 10-digit prime, the case is closed. | | 7. Arithmetic functions, factors and covering sets | #46 Puzzle 325 (Q4) First answer | Bas's explanation and verification script a) Challenge. A Zeisel number is a product of n ≥ 3 distinct primes p1·p2·…·pn with p0 = 1 and pi = A·pi₋1 + B for fixed A and B. Q4 asks for one with at least 10,000 digits; the page had 1000-digit examples only. b) Bas's contribution. A Zeisel number of 10,008 digits: p1 = 12487, p2 = (1021 + 1245)·7723# + 1, A = (p2 − 1)/12486 − 1, B = 12487 − A, p3 = A·p2 + B. Method: choose the first two primes freely; A and B then follow from them, so only p3 needs luck. c) Verification and notes. OK (verifica_BvD24_directos): the recurrence holds from p0 = 1, and p2 (3336 digits) and p3 (6668 digits) pass a probable-prime test. Bas reports a proof for p2, whose p2 − 1 is almost fully factored; p3 is a probable prime. | #47 Puzzle 419 (Q4) Better solution | Bas's explanation and verification script a) Challenge. Find N with σ(N) = (SOPF(N)·ND(N))P for an exponent P > 3, the larger the better (SOPF = sum of prime factors, ND = number of divisors). On the page: J. Wroblewski up to P = 7; best known (Wroblewski's linked files): P = 31. b) Bas's contribution. P = 47, with N the product of 336 distinct primes and SOPF(N) = 342·525 (primes in his data file). Method: use only primes q with q + 1 = 2a·3b·5c, so σ(N) is a product of 2, 3 and 5, and pick 336 of them whose exponents and sum match a 47th power. c) Verification and notes. OK (verifica_BvD24_directos): 336 distinct primes (the larger ones probable primes), SOPF = 342·525, and σ(N) = (SOPF·2336)47 exactly. | #48 Puzzle 435 First answer | Bas's explanation and verification script a) Challenge. Solve φ(m) + σ(m) = 5m. No solution was known; J. López had sent congruence conditions only. b) Bas's contribution. m = 60493590969525342720 = 29·35·5·73·132·312·41·42577. Method: build all of m except its largest prime; that prime then follows from a linear equation. c) Verification and notes. OK (verifica_BvD18). Not claimed to be the smallest solution, so the next term of OEIS A015704 stays open. | #49 Puzzle 450 Better solution | Bas's explanation and verification script a) Challenge. Find two consecutive primes whose sum has as many prime factors as possible, counted with repetition. Previous record (J. K. Andersen, 2008): the twin primes 2003663613·2195000 ± 1, with 195,005. b) Bas's contribution. The largest known twin primes, 2996863034895·21290000 ± 1 (PrimeGrid), whose sum k·21290001 has 1,290,006 prime factors, since k = 32·5·18583·3583757. c) Verification and notes. OK (verifica_BvD_pesados6). Reviewer’s note: The primality of the twins rests on PrimeGrid; the script also prints the PFGW commands to re-prove them (about 30–60 min each). Editor’s decision: Accepted. The primality of the twins rests on PrimeGrid, which will be credited when publishing; the script also prints the PFGW commands to re-prove them (about 30–60 min each). | #50 Puzzle 458 First answer | Bas's explanation and verification script a) Challenge. With P(x) the set of prime factors of x, find n with P(σ(n)) ⊊ P(n) ⊊ P(φ(n)) (F. Firoozbakht). No answer had been published. b) Bas's contribution. n = 678395112906914180368298499070649370 = 2·3·5·7·11·133·172·292·313·372·473·672·3073. Method: start from L. Pebody's number, whose three prime sets are equal, and multiply by 473; that adds 47 to P(n), adds 23 to P(φ(n)) and leaves P(σ(n)) unchanged. c) Verification and notes. OK (verifica_BvD24_directos): both strict inclusions confirmed by full factorization. | #51 Puzzle 553 Better solution | Bas's explanation and verification script a) Challenge. Add up all integers from a prime to the next prime; find cases where the total is a product of consecutive primes, using as many primes as possible. Previous record (G. Resta): 349·…·2677, 319 primes. b) Bas's contribution. p = (523·541·…·3001)/2593 − 1296 and q = p + 2592 (1060 digits): p + (p + 1) + … + q = 523·541·…·3001, a product of 333 consecutive primes. Method: the known solutions share a pattern that fixes p exactly, so no search was needed beyond testing p and q. c) Verification and notes. OK (verifica_BvD24_directos): the sum is exact and q is the next prime after p (both probable primes). | #52 Puzzle 830 (Q2) Better solution | Bas's explanation and verification script a) Challenge. Write N = a1·…·an with every ai ≥ 2 so that (a1 + 1)·…·(an + 1) = K·N, with the smallest N, for K = 2012 to 2017. Current values (E. Vantieghem, "not 100% sure N is minimal"): 485664325632000 (K = 2012) and 386983526400 (K = 2013). b) Bas's contribution. K = 2012: N = 3520·21·4·211·310 = 35757277839360. K = 2013: N = 60·54·213·38 = 174142586880. For K = 2014–2017 his search finds nothing smaller than the listed values. Method: let the largest prime still to cancel choose the next factor. c) Verification and notes. OK (verifica_BvD24_directos): both products give exactly K·N and both N are smaller than the listed values. Not proven minimal. | #53 Puzzle 1001 (Q4) Better solution | Bas's explanation and verification script a) Challenge. With Q = SAD(P), the sum of the anti-divisors of a prime P, find P with Q prime and Q/P as large as possible. Previous record (J. van Delden, 2020): 4.7810759740. b) Bas's contribution. P = 391177608521960466267478281835624430526821956454882813 gives Q/P = 5.5201061257. Method: for a prime, SAD(P) = σ(2P − 1) + σ(2P + 1) − 4P, and Q is odd only when 2P − 1 is a square; choosing that square's root with many small factors makes Q large. c) Verification and notes. OK (verifica_BvD24_directos): the SAD formula was checked against the definition for every prime below 400; 2P − 1 = 8845084606966294771503168752; P and Q are probable primes. | #54 Puzzle 1080 First answer | Bas's explanation and verification script a) Challenge. F. Schneider defines a(n) as the least y such that σ3(x) = y has n solutions; a(1) = 1, a(2) = 7401260364550416, and no a(3) was found up to 2·108. b) Bas's contribution. σ3(54608832726) = σ3(56689652415) = σ3(57381413815) = 190592992522906181161863557566464, so a(3) ≤ 1.9·1032. Method: σ3 is multiplicative, so two known pairs with equal σ3 combine by multiplication. c) Verification and notes. OK (verifica_BvD18). His claim of exactly three solutions was confirmed independently during this review, by inverting σ3 over all 1,213,056 divisors of the value. Not claimed to be the least, so a(3) itself remains open. | #55 Puzzle 1145 (Q1) First answer | Bas's explanation and verification script a) Challenge. For k = 3a2 with a = 153479820268467961 (Wesolowski), no prime k·2n + 1 divides a Fermat number: for odd n, k·2n + 1 is never prime because of a covering set. Q1 asks for a smaller k with both properties that is not a Sierpiński number. b) Bas's contribution. The covering set behind Wesolowski's k, {5, 7, 11, 31, 73, 97, 151, 241, 631, 673, 1321, 23311}; proof that his a is the minimum for that set over all 34,560 covers; and a bounded search that finds no smaller k for any period dividing 1440. k·2600 + 1 is a probable prime, so k is not Sierpiński. c) Verification and notes. Partial answer. Verified (verifica_BvD8_optimalidad): the set covers every odd n, and k·2600 + 1 is a probable prime. Bas's bounded search could not be repeated, since its C program is not in his repository. Q1 itself stays open: no smaller k was found, and the search does not prove that none exists. Editor’s decision: Accepted as a partial answer. The bounded search could not be repeated because its C program is not in Bas’s repository, so Q1 itself stays open. . | | 8. Proofs | #56 Puzzle 170 (Q10) First answer | Bas's explanation and verification script a) Challenge. Find a prime n such that n + 1 is a base-2 pseudoprime (a composite N with 2N ≡ 2 mod N), or prove that none exists. b) Bas's contribution. Impossible. Proof: for n = 2, n + 1 = 3 is prime. Otherwise N = n + 1 is even. If 4 divided N, then 2N ≡ 0 (mod 4) while 2 ≢ 0 (mod 4); so N = 2m with m odd, and m > 1 because N is composite. Reducing 2N ≡ 2 modulo m and dividing by 2 (m is odd) gives 2N−1 ≡ 1 (mod m). The order t of 2 modulo m therefore divides N − 1 = n, with t > 1 (since 2 ≢ 1 mod m) and t ≤ φ(m) < m < n. So n has a divisor strictly between 1 and n and cannot be prime. c) Verification and notes. Correct. Every step holds; no gap. Numerical check: the six even pseudoprimes below 107 (the smallest is 161038, where the order of 2 mod 80519 is 261 and 161037 = 261·617) all have N − 1 composite. | #57 Puzzle 493 First answer | Bas's explanation and verification script a) Challenge. For a prime p > 2, are there always positive integers x, y, a, b with pᵖ = x·a2 + y·b2, x + y = p, gcd(a, b) = 1 and a ≠ b? b) Bas's contribution. Yes, for every odd prime p and every split x + y = p. Proof: since p is odd, expanding (√x + i√y)ᵖ gives A·√x + i·B·√y with A, B integers. Taking squared absolute values, x·A2 + y·B2 = (x + y)ᵖ = pᵖ. All middle binomial coefficients are multiples of p, so A ≡ x^((p−1)/2) and B ≡ ±y^((p−1)/2) (mod p), and neither is 0 since 0 < x, y < p. A common prime factor of A and B would divide pᵖ, so it would be p, which is impossible; hence gcd(A, B) = 1. Finally |A| = |B| would force |A| = |B| = 1 and pᵖ = p, which is false. So a = |A|, b = |B| works. Example: p = 5, x = 1, y = 4 gives 55 = 1·412 + 4·192. c) Verification and notes. Correct. A complete and elegant proof, stronger than what was asked (it works for every split). Checked numerically for all 4,180 cases with p < 200. Reviewer’s note: confirm the page puts no further conditions on x, y, a, b. Editor’s decision: Accepted. As a general rule on this site, anything not explicitly forbidden by a puzzle’s statement is accepted; the proof answers the question as stated, for every split x + y = p. | #58 Puzzle 890 (Q1) First answer | Bas's explanation and verification script a) Challenge. Find the smallest 3×3 magic square made of the nine numbers of three primitive Pythagorean triples, or prove that none exists. b) Bas's contribution. Impossible. Idea: every 3×3 magic square has Lucas's form (centre c with cells c ± a, c ± b, c ± (a + b), c ± (a − b)). Parity fixes where the three even legs sit and forces c and b to be multiples of 4; remainders mod 4 then fix the three hypotenuses; what is left is 36 systems of three quadratic equations, whose only solutions repeat a number or need a negative one. Full proof in the Appendix. c) Verification and notes. Correct. The parity cases and the mod-4 step were checked by hand; the 36 systems were solved again (only b = 0, or a/c = 25/4 with negative entries); and an independent brute-force search, not using his argument, finds no such square with centre up to 300. Reviewer’s note: the proof assumes the nine numbers are different; the degenerate square made of 3, 4, 5 three times is magic. Confirm the page requires distinct numbers. Editor’s decision: Accepted. By the standard definition, a magic square of any order is made of distinct integers, so the proof answers the question. | #59 Puzzle 516 (Q1) First answer | Bas's explanation and verification script a) Challenge. With P(n) the product of the digits of n and π the prime-counting function, prove that 59 = P(59) + π(P(59)) = 45 + 14 is the only n > 1 with n = P(n) + π(P(n)) (F. Firoozbakht). b) Bas's contribution. 59 is the only solution. Idea: a digit product grows far more slowly than the number, so no solution has more than 7 digits; a computer check below 107 finds only 59. Full proof in the Appendix. c) Verification and notes. Correct (computer-assisted). The bound (10/9)^(d−1) < 2, hence d ≤ 7, is right; the complete search below 107 was repeated and finds only 59. | #60 Puzzle 1204 First answer | Bas's explanation and verification script a) Challenge. For 51.6% of the primes p below 15015, 30030 − p is prime too (D. Kamenetsky). Q1: why? Q2: do larger n behave the same way? (None above 50% was known up to 105.) b) Bas's contribution. Q1: 30030 = 2·3·5·7·11·13, so for p not dividing it, 30030 − p is not divisible by those six primes either, which makes it about 5 times more likely to be prime; the Hardy–Littlewood formula predicts 51.7% against 51.6% observed. Q2: no n with 15015 < n ≤ 2·106 exceeds 50%, with a heuristic reason why none should. c) Verification and notes. Correct as an explanation; not a proof, as Bas himself states: it rests on the unproven Hardy–Littlewood formula. Numbers confirmed: 905 of 1755 primes (51.6%) for n = 15015; predictions 51.7%, 48.3% and 42.6% against 51.6%, 48.2% and 42.3% for n = 15015, 30030 and 255255; the highest fraction for 15015 < n ≤ 2·106 is 48.49% (n = 19635). Editor’s decision: Accepted, with the reviewer’s caveat: this is not a formal proof but an explanation that rests on the unproven Hardy–Littlewood formula. | #61 Puzzle 490 First answer | Bas's explanation and verification script a) Challenge. 25 − 23 + 1 = 52, 27 − 23 + 1 = 112 and 215 − 23 + 1 = 1812 (S. M. Ruiz). Q1: are there other odd n with 2n − 2k + 1 a square? Q2: is k always 3? b) Bas's contribution. No other odd n, and k = 3 always. Written as y2 + (2k − 1) = 2n, the case k = 3 is the Ramanujan–Nagell equation (solutions n = 3, 4, 5, 7, 15). For k ≥ 4 the equation has at most two solutions, and two always exist: n = k (trivial) and n = 2k − 2 (even); so no odd n remains. k = 0, 1, 2 are settled by congruences. c) Verification and notes. Correct, with a remark on the citation. The theorem needed, "x2 + D = 2n has at most two solutions for D ≠ 7", is due to Apéry (1960), not Beukers; the list of exceptions Bas attributes to Beukers is misquoted (the form 22m − 3·2m+1 + 1 belongs to another case). Beukers' actual result (two solutions only for D = 23 or D = 2k − 1) agrees with his conclusion, so the answer stands. A direct search over odd n < 400 finds only (n, k) = (5, 3), (7, 3) and (15, 3). Editor’s decision: Accepted, with the reviewer’s correction: the key theorem is Apéry’s (1960), not Beukers’ as Bas cites. | #62 Puzzle 631 First answer | Bas's explanation and verification script a) Challenge. Can three consecutive prime gaps all be arbitrarily large? (L. Pebody, following puzzle 630.) b) Bas's contribution. Yes. By Shiu's theorem (Strings of congruent primes, J. London Math. Soc. 61, 2000), for every q there are four consecutive primes all ≡ 1 (mod q); the three gaps between them are positive multiples of q, so each is at least q. c) Verification and notes. Correct (application of a published theorem). The theorem is applied correctly and the argument is complete. The first such string for q = 30 is 4560121, 4560151, 4560181, 4560211, as stated. | #63 Puzzle 677 First answer | Bas's explanation and verification script a) Challenge. Q1: the smallest prime P such that all primes 2, 3, …, P can be arranged in a row with every two neighbours summing to a square. Q2: the same in a circle. E. Vantieghem gave lower bounds; P = 238373 and 409271 were tried in vain. b) Bas's contribution. A square sum forces neighbours to alternate between team A = {2} ∪ {primes ≡ 1 mod 4} and team B = {primes ≡ 3 mod 4}, so a row needs the team sizes to differ by at most one, and a circle needs them equal. Hence both tried values are impossible (A − B = −51 and −66). The smallest row, if it exists, has P in [615721, 634187] or P ≥ 12305677; no circle exists for P < 12305753. Editor’s decision: Accepted as a partial answer; the question remains open. | #64 Puzzle 639 First answer | Bas's explanation and verification script a) Challenge. Prove that for every m ≥ 1 there are composite n with σ(n) + 12m = σ(n + 12m) (F. Firoozbakht and Jahangeer). b) Bas's contribution. n = P·(P + 6m + 2) works whenever P, P + 2, P + 6m and P + 6m + 2 are all prime, because n + 12m = (P + 2)(P + 6m). Such P exists for every m ≤ 3.3·107, and for all m under the prime k-tuples conjecture. Editor’s decision: Accepted as a conditional answer: the claim for every m depends on an unproven conjecture (the prime k-tuples conjecture). |
Appendix: full proofs
Puzzle 890 — no magic square from three primitive Pythagorean triples Original: Bas's explanation and verification script. Written out here as reviewed. Setup. Every 3×3 magic square has Lucas's form: a centre c and the eight cells c ± a, c ± b, c ± (a + b), c ± (a − b), with 0 < b < a and a ≠ 2b so that the nine numbers differ. In a primitive triple (u, v, w) with u2 + v2 = w2, exactly one leg is even and it is a multiple of 4; the other leg is odd; and the hypotenuse is odd with w ≡ 1 (mod 4). So the nine numbers contain exactly three even numbers, all multiples of 4, and three hypotenuses, all ≡ 1 (mod 4). Step 1: parity. Count the odd numbers among the nine cells for each parity pattern of c, a and b. With c even: a and b both even gives 0; both odd gives 4; exactly one odd gives 6. With c odd: a and b both even gives 9; both odd gives 5; exactly one odd gives 3. Only "c even, exactly one of a, b odd" gives six odd numbers. Reflecting the square swaps a and b, so take b even. The even numbers are then c − b, c and c + b; each is an even leg, hence a multiple of 4, so c and b are multiples of 4. Step 2: remainders mod 4. The six odd numbers are c ± a, c ± (a + b) and c ± (a − b). Since c ≡ b ≡ 0 (mod 4), the three with a plus sign are ≡ a and the three with a minus sign are ≡ −a (mod 4). The three hypotenuses are ≡ 1 (mod 4), so they are exactly one of these two groups. Replacing a by −a (another reflection), the hypotenuses are c + a + j·b, the odd legs c − a + l·b and the even legs c + k·b, with j, l, k each running over −1, 0, 1. Step 3: the equations. Each triple takes one even leg, one odd leg and one hypotenuse. Ordering the triples by k, there are 3!·3! = 36 ways to match the rest. For one triple, (c − a + l·b)2 + (c + k·b)2 = (c + a + j·b)2 expands to c² − 4ac + 2b·((c − a)·l + c·k − (c + a)·j) + (l² + k² − j²)·b² = 0 The equations depend only on a/c and b/c. Solving the three equations for each of the 36 matchings gives only two kinds of real solution: b/c = 0 with a/c = 1/4, where c − b = c = c + b repeat; and b/c = ±6 with a/c = 25/4, where c − a = −21c/4 is negative. So no magic square with nine different positive numbers comes from three primitive Pythagorean triples. Review notes. Every step was checked; the 36 systems were solved again, and a brute-force search that does not use the argument finds no square with centre up to 300. The proof needs the nine numbers to be different: the square with rows 5 3 4 / 3 4 5 / 4 5 3, made of 3, 4, 5 three times, is magic. Puzzle 516 — 59 is the only solution of n = P(n) + π(P(n)) Original: Bas's explanation and verification script. Written out here as reviewed. Step 1: no digit 0. If n has a digit 0, then P(n) = 0 and the right side is 0 + π(0) = 0, so n = 0. Hence every solution n > 0 has only nonzero digits. Step 2: at most 7 digits. Let n have d digits and leading digit a. Then n ≥ a·10^(d−1), and P(n) ≤ a·9^(d−1) because every other digit is at most 9. Since π(x) < x for x ≥ 1, n = P(n) + π(P(n)) < 2·P(n) ≤ 2a·9^(d−1). Combining both bounds gives a·10^(d−1) < 2a·9^(d−1), that is (10/9)^(d−1) < 2. As (10/9)6 ≈ 1.88 < 2 < (10/9)7 ≈ 2.09, this forces d − 1 ≤ 6, so n has at most 7 digits. Step 3: computer check. Every n below 107 was tested: the only solutions are n = 1 (excluded by n > 1) and n = 59, where P = 45 and π(45) = 14. Review notes. The bound is correct and the search below 107 was repeated independently (verifica_BvD_demostraciones9); only 59 appears.
Q1. Can you improve any of the 39 better solutions?
Q2. Can you settle any of the parts left open? Puzzle 677: a row or circle of primes with square sums;
puzzle 1145: a smaller k; puzzle 639: an unconditional proof; puzzle 189: n0 = 57 for every n > 200;
puzzle 1080: the exact value of a(3).
Q3. Can you confirm or improve the claims not verified here? Puzzle 75: that the 223-digit palprime is
the smallest; puzzle 87: that Bas's 4×4 squares can be beaten.
Q4. What is your opinion about the role of AI in solving the puzzles of this site?
|
|
|
|
|
|

|