login
Primes q such that p-1 | q-1 or q-1 | p-1 for every prime p | 2^(q-1)-1.
1

%I #81 Jun 14 2021 16:00:57

%S 2,3,5,7,11,13,17,19,23,31,37,43,47,59,79,83,107,167,179,223,227,263,

%T 347,359,367,383,467,479,503,563,587,719,839,863,887,983,1019,1187,

%U 1283,1307,1319,1367,1439,1487,1523,1619,1823,1907,2027,2039,2063,2099,2207

%N Primes q such that p-1 | q-1 or q-1 | p-1 for every prime p | 2^(q-1)-1.

%C Are there infinitely many such primes?

%C Are there only finitely many such primes that are not safe primes?

%C Is their set {2, 3, 13, 17, 19, 31, 37, 43, 79, 223, 367} complete?

%C It is assumed that there are infinitely many safe primes (and their estimated asymptotic density ~ 1.32/(log n)^2 converges to the actual value as far as we know), so the answer to the first question is certainly "yes". - _M. F. Hasler_, Jun 14 2021

%t seqQ[q_] := PrimeQ[q] && Module[{ps = FactorInteger[2^(q - 1) - 1][[;; , 1]]}, AllTrue[ps, Divisible[# - 1, q - 1] || Divisible[q - 1, # - 1] &]]; Select[Range[100], seqQ] (* _Amiram Eldar_, Jun 09 2020 *)

%o (PARI) isok(q) = {if (! isprime(q), return (0)); my(f=factor(2^(q-1)-1)[,1]~, qq=q-1); for (k=1, #f, my(pp=f[k]-1); if ((qq % pp) && (pp % qq), return(0));); return (1);} \\ _Michel Marcus_, Jun 09 2020

%o (PARI) is_A334797(n)={isprime(n)&&!foreach(factor(2^n---1)[,1],p,n%(p-1)&&(p-1)%n&&return)} \\ _M. F. Hasler_, Jun 14 2021

%Y A005385 is a proper subset.

%K nonn,hard

%O 1,1

%A _Thomas Ordowski_, Jun 09 2020

%E a(17)-a(38) from _Amiram Eldar_, Jun 09 2020

%E a(39)-a(53) from _Daniel Suteu_, Jun 19 2020