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!)
A171386 The characteristic function of 2 and 3: 1 if n is prime such that either n-1 or n+1 is prime, else 0. 15
0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
A181354(n) + A181376(n) + A181378(n) + A181380(n) + A181384(n) + A181401(n) + A181403(n) + A181405(n) + a(n) = A052268(n).
LINKS
FORMULA
a(n) = A130130(n) - A130130(n-1), for n>0.
MATHEMATICA
Join[{0, 1, 1}, LinearRecurrence[{1}, {0}, 102]] (* Ray Chandler, Sep 23 2015 *)
PROG
(PARI) a(n)=n==2||n==3 \\ Charles R Greathouse IV, Sep 24 2015
CROSSREFS
Sequence in context: A358224 A072608 A295304 * A189816 A342000 A194685
KEYWORD
nonn,easy,less
AUTHOR
EXTENSIONS
Edited by Charles R Greathouse IV, Mar 23 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 27 10:42 EDT 2024. Contains 372017 sequences. (Running on oeis4.)