Primality Certificate for (7372^3889-1)/7371

Andy Steward15,038 digits04 March 2007
Originally by A.A.D.Steward 2007

This certificate uses a theorem of Coppersmith and Howgrave-Graham to prove an integer N prime by making use of a partial prime factorization of N-1.

Factorizing N-1

As N is a Generalized Repunit, we make use of the algebraic factorization of N-1 to arrive at the following 28.701049% factorization of N-1:

From Factorisation
73722 · 2 · 19 · 97
Φ273 · 101
Φ33 · 31 · 181 · 3229
Φ45 · 10869277
Φ6373 · 145681
Φ82953529453875457
Φ93 · 37 · 1446068881585823977423
Φ121009 · 71329 · 41037793
Φ1617 · 1801144121137 · 284895261606831553
Φ18160513645855225178408257
Φ24p31
Φ273 · 4591 · 48497084257289257 · p49
Φ36541 · 400408777 · 421664714749 · 282069289339608060732241
Φ48256129 · 43375600369 · p46
Φ54163 · 3489481 · 18039011787287317 · 12779741976617310967 · 31539340486976753842617169
Φ72364821481 · 76194791051141041360817689 · p59
Φ813 · 487 · 2269 · c203
Φ108109 · p138
Φ14414515777 · 37819765905879755502721 · p156
Φ16210369 · 67739228001127 · p192
Φ216433 · 16095825911142570905857 · c254
Φ2433 · 5347 · 2963023417 · 17206915051 · 843536703163655132300449567 · c576
Φ3241621 · c415
Φ4326481 · 5678641 · 801982124497 · c535
Φ48617011 · 785854881030703139992110259 · p596
Φ6481297 · 17497 · c829
Φ972286881913 · 353225675773 · c1234
Φ1296c1671
Φ1944448294177 · p2498
Φ38883889 · c5009

We need the product F of all the prime factors from this partial factorization:

34972647 0336744975 0046417359 4906287256 6243767233 6188703574 4475620897 3783586789 9878962704 0358829918 7366838314 6317746842 1574305297 4492467098 6228880634 7579716916 8459291334 5032351970 4412426848 7327867994 1355220736 7239637622 9263099875 6428138988 4751068423 5411350930 0301042020 2380956658 2544073748 8433832975 8714785654 6356527948 0603506925 9998746177 7150172785 2693843952 6703848877 7296771812 8190647797 4822513696 5330942830 4087746777 4862191639 6333022430 5946824694 0381580046 7328166098 2329951751 7281747073 6071658614 7930134764 6534858917 5599314990 6769758437 3359687482 2498934552 3126922609 5984934719 4475135433 5913986548 2954207582 3445975513 9510990836 3997161806 5990339294 6368010891 3774119478 3681960901 1045510073 2609086040 2645117430 7698437865 3181828702 3975255202 4755650090 2691722245 1709983456 5106688089 1440622180 3468937348 2263553429 5733476631 5386097041 5426199843 1219688879 0171560876 6726637451 2765934504 2841579937 3250248336 4882780907 2024838346 0610676162 8155634746 1295127857 9048240384 9393267445 0203642352 4089899644 3989528751 1971564166 2521338914 9839182567 0594467860 1402390861 2069871312 9237917226 2802032386 2748551014 2011450859 9980111378 2292803330 3384337761 9317113796 8248440239 2121545957 9939089290 5471172871 7478480690 4454386681 1638394306 4334946593 0749858300 6779432671 5148951974 8563212081 8562365926 6536813362 5934912371 3113688979 4118145626 8456853347 6775230250 4267283768 1926606344 2159816620 0504538201 1263646220 2007843733 0946178591 7837475553 0682144315 5185093929 2393468137 8371572642 8243206031 4837459438 4693620715 0255302662 1902103230 0179439492 8395534058 6770123539 7206688642 6158860130 1031425346 1128520144 7915110494 9022408164 1885988558 2579056315 2720128296 0016904227 3660635822 2602050466 2080875346 8839345807 4294291821 6050872444 9766629484 7544437113 1660443802 9962753407 1369001491 6737598756 8297045641 9414801416 9330838710 9507937977 6426919201 9688825176 9247121035 0363421023 0645201544 7574253847 4065519421 1881516341 4126285480 0772635787 7510680460 0180447074 8672804946 6332376140 7357158387 7006914910 1000845465 2214085842 3187289199 9005827128 2881289262 2980860382 8246107463 7694773523 3676669855 0485730278 1280728322 5341048409 9558601071 2481806460 1316012175 1941385916 0476340326 3619824159 9800866863 7482437323 4728166448 4904295996 2075740320 1014327108 4581834603 1378235077 3791854797 0683600964 0819036617 1872141514 6585128088 3335837911 8732261352 8420930996 2785949896 9341402565 7202373706 1915347023 4233651629 1558728258 0900171637 2770850311 6482820489 3723259561 8765746987 8753889874 2384443036 9989801992 0902465359 8889311769 3290813236 9214018291 1066476168 2499514834 1442467553
264698 0251107680 9855008188 7601265687 3414536783 2333353566 4083950498 5968397592 2220738275 9534091266 5751708532 8854207477 7786617525 6359484064 0808681906 8646679902 3218508753 0455327772 7852073936 8144818657 0720438936 4091151840 7041491480 1707194239 4366656984 0552794685 1598641508 3438736570 8447267259 5159880034 9504088728 1909612462 2880087383 7785451293 0845110807 8168411750 0056775183 7859105836 3145569688 8824938022 2085909441 1164285126 3047666552 7487683111 5052707432 1198780176 4873079177 6517268736 4018658845 0124242973 0322720933 5704657948 2667583621 5716239986 3955686578 5962114878 3342933230 2082854479 9470586829 0679205337
10 0700242459 0394410950 6015686120 8615595591 6087573626 0648619016 9528920336 0035718332 2840960052 7648929506 7891195227 3538061759 9720013584 0352148752 5164454165 8968818325 2036463516 7118925781 0499278039
802669 1106486500 9333439951 5172947240 3160227068 3060606104 5867463009 8624752778 0717178985 5724489439 0881716135 1785849099 5749499843 6802319339 9693158277 8919632193
15690806 1770747836 4480255619 0406641626 2208237738 3878131103 2418698027 5758615024 9071059180 6695127010 9430828659 4557836891 4262658035 0475438437
238804305 5342555775 7692595714 8246468783 3071865987 5353770049
619144047 0684007315 6170245213 7224653101 1965984637
684953 3149760203 0073427946 4378354521 7286364561
8 7233362349 0984641784 8105332481
8435367 0316365513 2300449567
7858548 8103070313 9992110259
761947 9105114104 1360817689
315393 4048697675 3842617169
2820 6928933960 8060732241
1605 1364585522 5178408257
378 1976590587 9755502721
160 9582591114 2570905857
14 4606888158 5823977423
1277974197 6617310967
28489526 1606831553
4849708 4257289257
1803901 1787287317
295352 9453875457
6773 9228001127
180 1144121137
80 1982124497
42 1664714749
35 3225675773
4 3375600369
1 7206915051
2963023417
448294177
400408777
364821481
286881913
41037793
14515777
10869277
5678641
3489481
256129
145681
71329
17497
17011
10369
6481
5347
4591
3889
3229
2269
1621
1297
1009
541
487
433
373
181
163
109
101
97
73
37
31
19
17
5
35
22

Note that all prime factors listed above have been proven. As primes of under 250 decimal digits can be verified in a few seconds, proof of their primality is not included here, in order to save space. Larger prime factors can take from hours to months to prove; certificates for all such factors have been PKZIPped into this file.

We set R = (N-1)/F. Note that GCD(F,R)=1 and Log(F)/Log(N) = 28.701049%

Finding a Witness to Primality

Next, we find an integer witness w such that for each prime factor p of N-1, w(N-1) ≡ 1 mod N and GCD(w(N-1)/p-1,N) = 1. In this case, w = 2 suffices.

Given such a witness, Pocklington's Theorem shows that every prime factor of N ≡ 1 (mod F). As F4>N, N can have no more than three prime factors.

Express N in base F

As F2 < N < F3 and N ≡ 1 (mod F), we can let N = c2·F2 + c1·F + 1.

Brillhart, Lehmer and Selfridge

Brillhart, Lehmer and Selfridge's Theorem shows that N has exactly two prime factors if and only if c12-4·c2 is a perfect square.

Here, c12-4·c2 is ≡ 56 (mod 63) and therefore cannot be a square and this stage of the proof is passed.

Coppersmith and Howgrave-Graham

We are left with two possibilities for N: either it has exactly three prime factors or it is prime. The non-existence of exactly three factors is demonstrated by the Theorem of Coppersmith and Howgrave-Graham, here performed by a Pari/GP script written by John Renze and David Broadhurst. Here is the stdout:

realprecision = 5500 significant digits

Welcome to the CHG primality prover!
------------------------------------

Input file is:  IO\1CCC0F31.cin
Certificate file is:  IO\1CCC0F31.chg
Found values of n, F and G.
    Number to be tested has 15038 digits.
    Modulus has 4316 digits.
Modulus is 28.70104869% of n.

NOTICE: This program assumes that n has passed
    a BLS PRP-test with n, F, and G as given.  If
    not, then any results will be invalid!

Square test passed for F >> G.  Using modified right endpoint.

Search for factors congruent to 1.
    Running CHG with h = 6, u = 2. Right endpoint has 2090 digits.
        Done!  Time elapsed:  80281ms.
    Running CHG with h = 6, u = 2. Right endpoint has 2050 digits.
        Done!  Time elapsed:  86672ms.
    Running CHG with h = 6, u = 2. Right endpoint has 1989 digits.
        Done!  Time elapsed:  90281ms.
    Running CHG with h = 6, u = 2. Right endpoint has 1897 digits.
        Done!  Time elapsed:  96109ms.
    Running CHG with h = 6, u = 2. Right endpoint has 1760 digits.
        Done!  Time elapsed:  93985ms.
    Running CHG with h = 6, u = 2. Right endpoint has 1554 digits.
        Done!  Time elapsed:  85172ms.
    Running CHG with h = 6, u = 2. Right endpoint has 1318 digits.
        Done!  Time elapsed:  50109ms.
    Running CHG with h = 5, u = 1. Right endpoint has 1082 digits.
        Done!  Time elapsed:  13953ms.
    Running CHG with h = 5, u = 1. Right endpoint has 725 digits.
        Done!  Time elapsed:  19266ms.
    Running CHG with h = 5, u = 1. Right endpoint has 11 digits.
        Done!  Time elapsed:  83515ms.
A certificate has been saved to the file:  IO\1CCC0F31.chg

Running David Broadhurst's verifier on the saved certificate...

Testing a PRP called "IO\1CCC0F31.cin".

Pol[1, 1] with [h, u]=[5, 1] has ratio=1.509068209 E-1287 at X, ratio=3.681551371 E-1298 at Y, witness=3.
Pol[2, 1] with [h, u]=[4, 1] has ratio=8.51320480 E-85 at X, ratio=1.336525116 E-714 at Y, witness=2.
Pol[3, 1] with [h, u]=[4, 1] has ratio=3.734497202 E-359 at X, ratio=8.42808031 E-358 at Y, witness=3.
Pol[4, 1] with [h, u]=[6, 2] has ratio=0.620921835 at X, ratio=4.774383266 E-473 at Y, witness=2.
Pol[5, 1] with [h, u]=[6, 2] has ratio=0.570504232 at X, ratio=6.37134345 E-473 at Y, witness=19.
Pol[6, 1] with [h, u]=[6, 2] has ratio=1.157740796 E-206 at X, ratio=3.305211267 E-412 at Y, witness=3.
Pol[7, 1] with [h, u]=[6, 2] has ratio=1.543130723 E-139 at X, ratio=2.896674199 E-275 at Y, witness=2.
Pol[8, 1] with [h, u]=[6, 2] has ratio=2.253421094 E-92 at X, ratio=1.346074505 E-183 at Y, witness=2.
Pol[9, 1] with [h, u]=[6, 2] has ratio=2.337806268 E-62 at X, ratio=1.070961285 E-122 at Y, witness=3.
Pol[10, 1] with [h, u]=[6, 2] has ratio=1.967365861 E-42 at X, ratio=4.756468842 E-82 at Y, witness=5.

Validated in 9 sec.


Congratulations! n is prime!

The actual input file containing N and F and the output certificate are included in this file.