login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A112448 a(n) = 1 if 2*n+1 is prime, otherwise a(n) = minimal residue of (-1)^binomial(n+2,2) mod (2n+1). 0
0, -1, 1, 1, 0, -1, 1, 0, -1, -1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, -1, -1, 0, 1, 0, 0, 1, 0, 0, -1, 1, 0, 0, -1, 0, 1, -1, 0, 0, 1, 0, -1, 0, 0, -1, 0, 0, 0, -1, 0, 1, 1, 0, -1, 1, 0, -1, 0, 0, 0, 0, 0, 0, 1, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, -1, 1, 0, 0, 0, 0, 1, -1, 0, 1, 1, 0, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,1

LINKS

Table of n, a(n) for n=0..101.

Eric Weisstein's World of Mathematics, Wilson's Theorem

MATHEMATICA

Table[If[PrimeQ[2 n + 1], (-1)^Binomial[n + 2, 2], 0], {n, 0, 101}] (* Michael De Vlieger, Aug 22 2015 *)

PROG

(PARI) a(n) = if (isprime(2*n+1), ((-1)^ (binomial(n+2, 2))), 0); \\ Michel Marcus, Aug 16 2015

CROSSREFS

Apart from signs, same as A101264.

Sequence in context: A130854 A165191 A189576 * A101264 A189723 A095770

Adjacent sequences:  A112445 A112446 A112447 * A112449 A112450 A112451

KEYWORD

sign

AUTHOR

Eric W. Weisstein, Dec 12 2005

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 12 12:18 EDT 2020. Contains 335661 sequences. (Running on oeis4.)