Monday, 18 May 2026

Highly Primeable Numbers

A composite numbers is primeable if it can be made prime by changing a single digit. If it cannot, then it is said to be unprimeable. What struck me about the number associated with my diurnal age today (28169) is how many ways (10) in which it can be made prime.

28169 is NOT unprimeable. It can be made prime with the following changes (permalink):

- Changing the '2' at position 1 (from the left) to '1' yields 18169
- Changing the '2' at position 1 (from the left) to '5' yields 58169
- Changing the '2' at position 1 (from the left) to '8' yields 88169
- Changing the '8' at position 2 (from the left) to '1' yields 21169
- Changing the '8' at position 2 (from the left) to '4' yields 24169
- Changing the '8' at position 2 (from the left) to '5' yields 25169
- Changing the '1' at position 3 (from the left) to '0' yields 28069
- Changing the '1' at position 3 (from the left) to '6' yields 28669
- Changing the '6' at position 4 (from the left) to '0' yields 28109
- Changing the '9' at position 5 (from the left) to '3' yields 28163

This got me thinking about highly primeable numbers and what numbers are record breakers by setting records for the number of ways in which they can be made prime. I got Gemini to write a program to investigate this and here is what it came up with in the range up to 100000 (permalink):

Record-Breaking Primeable Numbers
----------------------------------------
Number          | Ways to Make Prime
----------------------------------------
4               | 4
21              | 7
33              | 8
111             | 10
133             | 11
177             | 13
357             | 14
1001            | 15
4221            | 16
10759           | 17
11487           | 18
42189           | 20
----------------------------------------

Here is the list of numbers: 4, 21, 33, 111, 133, 177, 357, 1001, 4221, 10759, 11487, 42189.

So we see that 28169, though highly primeable, is NOT a record breaker.

Let's look at the 20 ways in which 42189 can be made prime:

42189 is NOT unprimeable. It can be made prime with the following changes (permalink):
- Changing the '4' at position 1 (from the left) to '2' yields 22189 - Changing the '4' at position 1 (from the left) to '3' yields 32189 - Changing the '4' at position 1 (from the left) to '5' yields 52189 - Changing the '4' at position 1 (from the left) to '6' yields 62189 - Changing the '4' at position 1 (from the left) to '8' yields 82189 - Changing the '4' at position 1 (from the left) to '9' yields 92189 - Changing the '2' at position 2 (from the left) to '0' yields 40189 - Changing the '2' at position 2 (from the left) to '1' yields 41189 - Changing the '2' at position 2 (from the left) to '3' yields 43189 - Changing the '2' at position 2 (from the left) to '4' yields 44189 - Changing the '2' at position 2 (from the left) to '7' yields 47189 - Changing the '1' at position 3 (from the left) to '0' yields 42089 - Changing the '1' at position 3 (from the left) to '5' yields 42589 - Changing the '1' at position 3 (from the left) to '6' yields 42689 - Changing the '1' at position 3 (from the left) to '9' yields 42989 - Changing the '8' at position 4 (from the left) to '3' yields 42139 - Changing the '8' at position 4 (from the left) to '6' yields 42169 - Changing the '8' at position 4 (from the left) to '7' yields 42179 - Changing the '9' at position 5 (from the left) to '1' yields 42181 - Changing the '9' at position 5 (from the left) to '7' yields 42187

No comments:

Post a Comment