A215504 Prime numbers p such that p^2 - 1 has exactly one distinct prime factor other than 2 and 3.
11, 13, 19, 23, 31, 37, 47, 53, 73, 97, 107, 127, 163, 193, 257, 383, 487, 577, 863, 1153, 2593, 2917, 4373, 8747, 995327, 1492993, 1990657, 5308417, 28311553, 86093443, 6879707137, 1761205026817, 2348273369087, 5566277615617, 7421703487487, 21422803359743
Offset: 1
Examples
For any primes less than 11, p^2 - 1 does not have factors other than 2 or 3. 11^2 - 1 = 120 = 2^3*3*5, 5 is the only prime factor other than 2 and 3, so a(1) = 11; 13^2 - 1 = 168 = 2^3*3*5, so a(2) = 13; 17^2 - 1 = 288 = 2^5*3^2, so 17 is a not a term; 19^2 - 1 = 360 = 2^3*3^2*5, so a(3) = 19. 97^2 - 1 = 9408 = 2^6 * 3 * 7^2 which shows the other prime (7 here) can have multiplicity > 1. - _David A. Corneth_, Dec 21 2020
Links
- David A. Corneth, Table of n, a(n) for n = 1..70 (first 53 terms from Lei Zhou)
Programs
-
Mathematica
(* Method a *) Table[While[p = Prime[i++]; Length[Delete[Delete[FactorInteger[p^2 - 1], 1], 1]] != 1]; p, {k, 1, 30}] (* Method b *) f[n_] := Block[{p2, p3 = 3^Range[0, Floor@ Log[3, n] + 1]}, p2 = 2^Floor[ Log[2, n/p3] + 1]; Min[ Select[ p2*p3, IntegerQ]]]; fQ[n_] := Block[{pq = n}, While[ Mod[pq, 2] == 0, pq /= 2]; While[ Mod[pq, 3] == 0, pq /= 3]; PrimeNu@ pq == 1]; k = 1; lst = {}; While[k < 10^50, If[ PrimeQ[k - 1] && fQ[k - 2], AppendTo[lst, k - 1]]; If[ PrimeQ[k + 1] && fQ[k + 2], AppendTo[lst, k + 1]]; k = f@ k]; lst (* Robert G. Wilson v, Aug 23 2012 *)
Comments