All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Numbers
5 Pandigital Primes (Posted on 2023-08-10) Difficulty: 3 of 5
Find five 11-digit pandigital primes P<Q<R<S<T that can be written in a column so that each of the first 10 columns of digits has 5 distinct digits.

Find the set with smallest T.

See The Solution Submitted by K Sengupta    
Rating: 5.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
soln Comment 2 of 2 |
T = 5011234678

The first set 
(the one with lowest P,Q,R,S & T) is: 

PDP              Place on PDP  
             n   n-list
------------------------------------
14355809627  1   269863
23440687159  2   228957
32204158967  3   131977
41021563897  4    92582
50112346789  5        1

This T (as Larry noted) is the smallest "5-PDP" of length 11.
It persists in giving valid solutions for the column
constraint. E.g, the millionth example that works is, 

PDP              Place on PDP  
             n   n-list
------------------------------------
14390827651     273758
23457680419     230324
32204158967     131977
41021563897      92582
50112346789          1

where R, and S, haven't budged.

I did the problem via brute force, along with a couple of
short cuts: the repeated 11th digit cannot be 0, 3, 6, or 9, 
since the sum of digits would then be a multiple of 3 and 
make number non-prime. I needed (I thought) to sort all 
candidate pd numbers in increasing order, and that took a lot 
of time (10 hr cpu) but even that went faster than expected
using file structures to sort 1000 sets 8-digit pandigit 
numbers + 3 leading digits separately. Had I known the 50112346789 
worked, then any example with it present is a proof, and sorting 
would have been unnecessary. 

I found solutions from bottom to top, starting with the rows
and finding columns that worked. After finding a 1,2,3,4,5 
1st column solution that worked (below), I knew to instead start 
my search first with T.

10123457689  1
21014368579  95819
32201574869  131944
43450826917  307877
54342681709  392700

Larry's shortcut grid idea was very clever. I am not sure if 
solving the problem by using a grid with legal columns and 
then finding legal rows (Larry's method) or the reverse order (my
method)is harder, but in any even, the task is long. 

Programs and a complete set of PD-11 primes are here:

make_all_11-pan-digit numbers
make_all_11_pds_increasing_sorted
find_all_11_pd_primes
find_smallest_T
list_of_all_11_digit_pan_primes

Edited on August 12, 2023, 7:39 pm
  Posted by Steven Lord on 2023-08-12 00:27:30

Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (10)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information