OFFSET
1,4
COMMENTS
Related to the search of large primitive weird numbers: Kravitz has shown that 2^(k-1)*Q*R is a primitive weird number (cf. A002975) when Q > 2^k and R = (2^k*Q - Q - 1)/(Q + 1 - 2^k) both are prime. Here we count such primes for the special case where Q = 2^p - 1 is a Mersenne prime, p=A000043(n). For such Q one has R = 2^k - 1 + (2^k - 2)/(2^(p-k) - 1).
See A242025 for the resulting primes R, which however are there not listed in order of the p's.
This sequence gives the row lengths for the table A243003 whose rows hold the k-values leading to prime R, for a given Mersenne prime.
LINKS
S. Kravitz, A search for large weird numbers. J. Recreational Math. 9(1976), 82-85 (1977). Zbl 0365.10003
E. Weisstein, Weird numbers, on MathWorld - a Wolfram web ressource.
EXAMPLE
For given p=A000043(n), the following k's yield a prime R:
p : k's (and resulting primes R, Q=2^p-1 and/or weird W=2^(k-1)*Q*R)
2 : -
3 : 2 (R=5, Q=7, W=70)
5 : 4 (R=29, Q=31, W=7192)
7 : 4 (R=17, Q=127, W=17272), 5 (R=41, Q=127, W=83312)
13 : 11 (R=2729, Q=8191, W=22889716736)
17 : 13 (R=8737, Q=131071, W=4690605371392)
19 : 16 (R=74897, W=1286718208049152), 17 (R=174761, W=6004730783793152)
31 : 16 (R=65537, W=2^15*(2^31-1)*R), 29 (R=715827881, W=2^28*(2^31-1)*R)
61 : 57 (R=153722867280912929, W=2^56*(2^61-1)*R)
89 : 78 (R=302379100949042568368129, W=2^77*(2^89-1)*R)
107 through 86243 : none.
107 through 3021377: none. Robert Price, Sep 05 2019
The present sequence lists the number of k's in each line.
MATHEMATICA
A000043 = {2, 3, 5, 7, 13, 17, 19, 31, 61, 89, 107, 127, 521, 607,
1279, 2203, 2281, 3217, 4253, 4423, 9689, 9941, 11213, 19937,
21701, 23209, 44497, 86243, 110503, 132049, 216091, 756839, 859433,
1257787, 1398269, 2976221, 3021377, 6972593, 13466917, 20996011,
24036583, 25964951, 30402457, 32582657, 37156667, 42643801,
43112609};
lst = {};
For[i = 1, i <= 28, i++,
p = A000043[[i]];
kc = 0;
For[k = 1, k < p, k++,
r = 2^k - 1 + (2^k - 2)/(2^(p - k) - 1);
If[! IntegerQ[r], Continue[]];
If[PrimeQ[r], kc++]];
AppendTo[lst, kc]];
lst (* Robert Price, Sep 05 2019 *)
PROG
CROSSREFS
KEYWORD
nonn,hard,more
AUTHOR
M. F. Hasler, Aug 17 2014
EXTENSIONS
Typo in definition corrected by Jens Kruse Andersen, Aug 27 2014
a(29)-a(37) from Robert Price, Sep 05 2019
STATUS
approved