OFFSET
1,2
COMMENTS
This sequence is closed under multiplication. A006521 is a subsequence of this sequence. A006521 is also closed under multiplication. In fact if m is even and k is a natural number then the sequence "n divides m^n^k + 1" is a subsequence of the sequence "n divides m^n^(k+1)+ 1" and both are closed under multiplication.
"Closed under multiplication" means that if x and y are terms then so is x*y.
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..415
MATHEMATICA
Select[ Range[250857], PowerMod[2, #^2, # ] == # - 1 &] (* Robert G. Wilson v, Apr 02 2004 *)
PROG
(PARI) is(n)=Mod(2, n)^n^2==-1 \\ Charles R Greathouse IV, Aug 01 2016
CROSSREFS
KEYWORD
nonn
AUTHOR
Farideh Firoozbakht, Mar 31 2004
EXTENSIONS
Corrected and extended by Robert G. Wilson v, Apr 02 2004
STATUS
approved