Primality Certificate for (19979^4933-1)/19978

Andy Steward21,211 digits14 February 2011
Originally by A.A.D.Steward 2011

This certificate uses a theorem of Brillhart, Lehmer and Selfridge 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 37.581425% factorization of N-1:

From Factorisation
1997919979
Φ22 · 2 · 3 · 3 · 3 · 5 · 37
Φ3399180421
Φ42 · 17 · 17 · 690589
Φ63 · 133046821
Φ92179 · 5951979379 · 4903699325221
Φ1213 · 61 · 277 · 725340671581
Φ183 · 19 · 2923831 · 41067883 · 9292082203
Φ3673 · 109 · p48
Φ137823 · 6577 · c579
Φ27496634812653 · p574
Φ41122238769409 · 13672672820707 · c1147
Φ54819181 · 13899068838593 · 915262411052636873 · c1135
Φ8224933 · 86311 · 2501347 · 421078171279 · 6177260263987 · 6354617167219 · 192831199280029 · 7869206388282525667 · c1085
Φ1233c3510
Φ164437813 · 23574961 · 88447201 · 484284280573 · c2308
Φ24662467 · 79363279 · 11031716404430797321 · c3479
Φ493244389 · 103448701 · p7006

From this partial factorization, we use sufficient of the largest prime factors of N-1 so that their product F is at least N 1/3 :

748780 4797775219 6830935272 6989554192 8189363522 2755205417 4228247836 6768375149 1284304402 0202201990 1413265104 8544441265 1488196881 8606873301 0985002233 7686495782 8095433418 6625345896 1092748304 1870672810 7083017500 9434600052 4665162244 3092846777 6834604435 1875733649 5702249979 5445381196 9246297730 1844707282 4719433592 9886575014 6619759197 3968678300 0153533913 4257208225 7528181773 9455271286 8982699769 7988739114 8313221153 2424805497 2518207172 9223615595 8423216840 0608975119 3465264859 4579433137 8343490424 4088265837 0481337841 4659470234 5807823282 4519215020 2314860016 6214263668 1281878194 3362122800 8990742783 1767834096 0837385100 9635272481 0307972611 4656032289 0186050296 8340043652 5380960171 1903433483 5805047752 6960272291 8827878226 0056570430 8776102370 3230904864 2632736042 5387142228 9012407732 7030227038 0225367179 6994856808 0901425028 1325938110 0714628434 4314233393 3955380456 7214051585 6304741413 2378800576 2050566940 7534553202 1928283652 0732010983 8136200223 3333698742 0907881736 8822507336 5846538827 0530982061 7908828329 3468406241 7426020374 5307134958 9931632368 5634964784 1040953658 1303481051 9037783946 9509306735 0746762655 4656754406 2397892715 9274654094 8909062792 4265639429 4959607902 3704739848 2823601030 2960326852 3842975635 0660953593 3430274996 5536884309 1502113622 8404593451 3000757105 8660927173 2799952961 5308975280 2828654060 9237863122 1693730152 8037544809 4287372427 2595034134 3498432447 3389377916 4684930372 4011236180 1458009768 8340885924 0164866923 9714234368 0167403199 8284160279 0921553565 2579069850 3727077010 2131408238 9434790449 5275635179 8308107955 3342612370 3395661220 3539481408 0492728518 6282009017 8333950319 4064389484 8479524509 2097261245 3968638074 1177363657 7439421611 5598154911 1867442879 8409842523 4792484668 0872454850 5641359151 0357425694 6035988231 1182490496 3705220220 7152067943 1469414245 1889118192 2302449356 9597354390 7191667252 9991204749 7027731119 3196444508 9072196185 9727180404 4452068156 2131755209 2340740627 5556022117 2599628316 9286819532 0269434396 9731524287 7235387006 7940189539 9897243922 5280738058 1490777616 5244159144 0211240896 3761456261 9360668105 1841887516 9400138572 0961518170 3462296327 8508657905 8063833230 8694454334 6399630170 7890335537 1156884288 6737365132 6981283008 5040405784 8950113514 4875386084 7560839723 0478647701 1607633916 1865187446 3942384516 6513512037 7806182093 5110224986 8320393669 9228638507 1385935666 4595252073 6251133639 8659034916 3947460099 1073141714 8946189244 8819449076 1016013726 2149275003 1075388651 0431705517 3838529223 5395828945 5767228708 5226664602 7991380236 7019834720 3680614227 5921800787 5681174595 2534135151 5867401207 4224991914 6807616175 7471470768 7911072314 9234929089 1563870310 4409336033 8633428744 6381389728 2651991271 2799204363 2579500940 3699487530 6316969181 2844577256 0168794519 0709267076 9465244155 6869065648 6012226547 3133603541 9978055388 0092631011 2731075552 7900459864 7252764962 0469981252 6642504975 9937023196 2370770657 3795253464 6836182938 8562658340 3979016269 0066376122 0779146288 2304934382 6229771993 9590290268 0851709249 1426943979 1606012502 2801696949 2961246799 7158058122 1385650745 5513573967 7389775001 8960338100 9033431833 0285406271 7540230239 5017862312 2276006430 9956814872 7077465081 8083049133 4816048515 5884206639 0856741978 8946232897 4174206255 4407208496 1556748663 5181539896 1333451624 4381136837 3922954865 7535404239 1738613405 5968793292 4915592010 5693040156 6517362811 5190841678 2095846975 0008226261 3802376516 8461766397 5892605620 8737203439 8974428541 6195724789 4687476754 8280983064 7455684925 8787884953 1996564177 3147948460 9950109828 2674096945 3481515265 7353370876 7643302112 1794430349 1809770371 6089710827 4332332777 3050454133 0093342096 7654452563 4156222358 4164840840 6527809426 1336450567 2983197064 4357742872 4514305732 0560120837 4423177268 6678508039 3917479038 6871184077 7183043172 8045960274 3039499759 0368739003 5328653716 9024365703 3245878102 2957021215 8982365631 8697758554 0704705501 1741902626 7746041889 2881743803 3084648445 4670960723 2960795543 3612358451 1822424941 2969800247 4636811203 3232791720 0049684616 5222627080 0589648446 8349110172 4075888212 5390765201 6599247446 5515491935 8978617346 4625676799 9914527993 4884186241 3954733653 3354615641 8605732888 1032012825 3805142929 0494043681 6777710079 6466412734 0059730603 1989121270 2191301915 1247719055 0573702406 7623366157 1148331508 8351291729 4583020352 5948238714 8490601971 0796798073 2335197036 4758817360 6137125518 6787802983 7340197110 9652689431 5483167496 6718241310 3368204787 5868691987 7463878107 4366623689 1486322173 8659163991 1472463410 1180871167 9059981970 2682438817 5591191549 3786677132 5826723816 4284347274 0039844263 2484616084 7306205070 8664621701 5941677626 1216716572 1944679158 0124156116 0024065356 6273235139 5215991854 1343616815 1292944903 5871269480 6893004766 7136413890 5351332628 3013126978 8895598770 7313804601 6202618713 7240539966 5515706465 9169723095 6331399966 0678683372 6116742097 2919905308 6765718112 7185730507 4651580352 6307012483 0793843887 7210233385 1174768248 5097896297 9517084771 6328465427 0919063073 3347340782 2156670652 3858042215 3364578803 1874807835 8379622002 0790355434 9534439852 6657271545 2986470577 1783375766 2807809773 8097576084 7213037901 8032537918 0165638218 7279508581 0899792911 2298152629 3372030646 6778746384 2472200832 5632475255 0676327845 4307111700 8899946413 2578862737 1153508559 5584961351 1840229690 6105084009 1398461921 0042209928 8330754483 4838374025 2610398391 4267521785 5352591788 5827665712 9633924959 0644966861 7250225781 5875269726 6426596629 8778634887 1618929951 2728454293 5179630179 9232039701 8629534483 7180690350 4667360954 7706391002 8127721152 0623090698 9311541038 6746339712 5496927918 5799382182 5182397984 3342577596 7098672904 9865640175 3310625836 4501733778 1310165155 9987971375 2547756461 4670611300 7391705792 4561824956 3763493671 1290462796 6143298065 9844510369 9799033554 5007362879 9984919348 1606026844 1638493921 9471993559 3132914892 0061931318 2819708904 6306627775 2627666013 9410484791 4924605806 5733820118 0369435680 5966972503 2660214812 4289023228 8887369308 0636894412 1366247459 2603695144 2082823179 4208096402 9059640144 4063151773 5029036752 3569326169 9892059567 5659383799 6054189451 4672574973 5247787422 5588990877 2823345250 4619154550 8918137641 1140365241 0692377087 1822831746 8935219479 7495740888 3508707526 2363490315 1548236449 0982676076 5910970780 2568452808 6849368276 1037004571 3946173243 0778956013 8985855639 3612181951 7472437545 8871122989 3798941481 6763482658 9030411670 8935459677 0438180156 8375017924 2746324887 9543298328 8465360264 9506080084 2281240445 5505899977 6897367808 1228645225 8291907016 3044000833 3574165813 1010941771 9863104394 1155870450 1362606492 8751495078 8431812395 6991881142 7851514777 0780697594 9134829657 1935259368 0593571946 9509733014 9879340383 8875493208 9402359024 2778338089 5258647906 0023583054 7746985142 2900392940 1778444900 4863037996 1734017448 1714428869 4860392429 4098638519 6462412279 8487009642 5447290113 6225793559 4175062363 8406170347 2919010151 2362381899 4886720250 9807244122 2342750924 5929410286 2441981427 7884654627 2640461448 9877183311 1976155860 5218372890 2891718545 9537190808 5037851466 1546170979 7374615289 2462052474 1298833910 9631965434 4939590479 4813627476 0383303451 3400863918 0309359889 2031631919 8112146436 6762696517 3295045812 8648456831 6165962668 1352108855 2535728617 7191641756 1036980065 3301190998 3668903846 2810778180 0501125776 7293051852 2542447477 0857842069 3733851889
7814 0148168813 5244147752 3597583706 4573883842 9041539397 8421826073 4919777528 4755178640 4540552503 7483139375 1047606336 8325610284 1372537665 2313323889 7620699631 5993007751 6024860784 9475729658 4357435760 3373552142 3098865173 5980595879 6792890034 9314083561 8767157992 7221431955 3682464234 4671752503 8582799841 8571226942 1225591253 7645234338 1508395310 6109837141 7035780290 2370636184 1698638169 8723543993 6534395314 0368941174 9936490227 0738633132 9809808021 3077051690 6328450136 0977091986 2532938712 0930917715 5121322505 7736149043 4125695049 7532161735 1295353690 3069677615 2764566220 6220757230 4175963869

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) = 35.736038%

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 = 7 suffices.

Given such a witness, Pocklington's Theorem shows that every prime factor of N ≡ 1 (mod F). As F3>N, N can have no more than two 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 is prime if and only if c12-4·c2 is not a square (given 2F3 > N).

Here, c12-4·c2 is ≡ 57 (mod 63) and therefore cannot be a square and N is prime.