login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A173950 a(n) = 1 if 6 divides (prime(n) + 1), a(n) = -1 if 6 divides (prime(n) - 1), a(n) = 0 otherwise. 3
0, 0, 1, -1, 1, -1, 1, -1, 1, 1, -1, -1, 1, -1, 1, 1, 1, -1, -1, 1, -1, -1, 1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 1, -1, 1, -1, -1, -1, 1, 1, 1, -1, 1, -1, 1, -1, -1, -1, 1, -1, 1, 1, -1, 1, 1, 1, 1, -1, -1, 1, -1, 1, -1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, -1, 1, 1, -1, 1, -1, 1, -1, 1, -1, -1, 1, 1, -1, 1, -1, 1, 1, -1, 1, -1, 1, 1, 1, -1, -1 (list; graph; refs; listen; history; text; internal format)
OFFSET
1
COMMENTS
Equals -A134323 except for the first term. - M. F. Hasler, Oct 09 2011
LINKS
FORMULA
a(n) = -A134323(n) for n > 1. - M. F. Hasler, Oct 09 2011
a(n) = -Kronecker(-12, prime(n)) = -Kronecker(prime(n), 12) = -A134667(prime(n)). - Jianing Song, Mar 17 2019
MATHEMATICA
Table[Which[Divisible[Prime[n]+1, 6], 1, Divisible[Prime[n]-1, 6], -1, True, 0], {n, 150}] (* Harvey P. Dale, Apr 24 2019 *)
PROG
(PARI) (From M. F. Hasler, Oct 09 2011) (Start)
A173950(n)=if(prime(n)%6==1, -1, n>2)
A173950(n)=(-1)^(prime(n)%3)*(n>2)
A173950(n)=[-1, 0, 0, 0, 1][prime(n)%6]
A173950(n)=if(n>2, prime(n)%6-3)/2 \\ (End)
CROSSREFS
Sequence in context: A179770 A189078 A257834 * A157928 A159075 A178333
KEYWORD
sign
AUTHOR
Giovanni Teofilatto, Nov 26 2010
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 18 20:26 EDT 2024. Contains 371781 sequences. (Running on oeis4.)