login
A262978
Exponents n such that 2^n-1 and 2^n+1 are squarefree.
1
1, 2, 4, 5, 7, 8, 11, 13, 14, 16, 17, 19, 22, 23, 25, 26, 28, 29, 31, 32, 34, 35, 37, 38, 41, 43, 44, 46, 47, 49, 52, 53, 56, 58, 59, 61, 62, 64, 65, 67, 71, 73, 74, 76, 77, 79, 82, 83, 85, 86, 88, 89, 91, 92, 94, 95, 97, 98, 101, 103, 104, 106, 107, 109, 112, 113, 115, 116, 118, 119
OFFSET
1,2
LINKS
FORMULA
2^a(n) = A269758(n).
EXAMPLE
a(4) = 5 because 2^5 - 1 = 31 and 2^5 + 1 = 33 are squarefree numbers.
MATHEMATICA
Select[Range[120], AllTrue[2^#+{1, -1}, SquareFreeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Dec 20 2019 *)
PROG
(Magma) [n: n in [1..120] | IsSquarefree(2^n-1) and IsSquarefree(2^n+1)];
(PARI) is(n)=issquarefree(2^n-1) && issquarefree(2^n+1) \\ Charles R Greathouse IV, May 02 2016
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
STATUS
approved