login
A113396
a(n) = -prime(n)^2 (mod prime(n+1)).
3
2, 1, 3, 6, 9, 1, 15, 7, 22, 27, 1, 25, 39, 31, 17, 23, 57, 31, 55, 69, 43, 67, 53, 33, 85, 99, 91, 105, 97, 58, 115, 101, 135, 49, 147, 121, 127, 151, 137, 143, 177, 91, 189, 181, 195, 67, 79, 211, 225, 217, 203, 237, 151
OFFSET
1,1
LINKS
FORMULA
a(n) = prime(n+1) - A167770(n). - Jason Yuen, Sep 08 2024
EXAMPLE
-2^2 == 2 (mod 3); -3^2 == 1 (mod 5); -5^2 == 3 (mod 7); -7^2 == 6 (mod 11); etc.
MATHEMATICA
Mod[#[[2]]^2-#[[1]]^2, #[[2]]]&/@Partition[Prime[Range[60]], 2, 1] (* Harvey P. Dale, Nov 10 2014 *)
PROG
(Pari) vector(55, n, (-prime(n)^2)%prime(n+1)) \\ Joerg Arndt, Sep 09 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Marian Kraus, Oct 26 2005
EXTENSIONS
Name simplified by Joerg Arndt, Sep 09 2024
STATUS
approved