A292448 Primes q of the form sigma((p + 1) / 2) where p is a prime.
3, 7, 13, 31, 127, 307, 1723, 2801, 3541, 8191, 19531, 86143, 131071, 492103, 524287, 552793, 684757, 704761, 735307, 797161, 1353733, 1886503, 3413257, 3894703, 5473261, 7094233, 7781311, 9250723, 10378063, 12655807, 18143341, 19443691, 22292563, 23907211
Offset: 1
Keywords
Examples
Prime 13 is a term because there is prime 17 with sigma((17 + 1) / 2) = sigma(9) = 13.
Programs
-
Magma
m := 5*10^7; Set(Sort([SumOfDivisors((n+1) div 2): n in [1..2*m] | IsPrime(n) and IsPrime(SumOfDivisors((n+1) div 2)) and SumOfDivisors((n+1) div 2) le m])); // corrected by Amiram Eldar, Oct 08 2021
-
Mathematica
max = 10^6; Select[Union@ Reap[Do[If[PrimeQ@ #, Sow@ #] &@DivisorSigma[1, (Prime@ i + 1)/2], {i, max}] ][[-1, 1]], # < Prime[max]/2 &] (* Michael De Vlieger, Sep 16 2017, corrected by Amiram Eldar, Oct 08 2021 *)
-
PARI
lista(nn) = {my(list = List()); forprime(p=3, 2*nn, if (isprime(q=sigma((p+1)/2)), listput(list, q));); select(x->(x <= nn), vecsort(Vec(list)));} \\ Michel Marcus, Oct 08 2021
Comments