login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

A161996
A (negated) characteristic function of twin composite odd numbers.
1
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1
OFFSET
1,1
COMMENTS
a(n) = 0 if n is a member of A060461, otherwise a(n) = 1.
MATHEMATICA
If[AllTrue[6#+{1, -1}, CompositeQ], 0, 1]&/@Range[300] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Feb 15 2015 *)
PROG
(PARI) A161996(n) = (isprime((6*n)-1)||isprime((6*n)+1)); \\ Antti Karttunen, Dec 15 2017
CROSSREFS
Sequence in context: A015111 A014446 A014883 * A362447 A242718 A015918
KEYWORD
nonn,easy
AUTHOR
Pierre CAMI, Jun 24 2009
EXTENSIONS
Definition rephrased by R. J. Mathar, Aug 14 2009
STATUS
approved