The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A317420 a(n) = number of k with 1 <= k <= n-1 such that a(k) AND a(n-k) = a(k) (where AND denotes the bitwise AND operator). 7
0, 1, 1, 2, 3, 2, 2, 3, 2, 5, 5, 5, 9, 6, 6, 5, 2, 4, 3, 3, 8, 8, 8, 8, 5, 8, 7, 9, 6, 5, 4, 6, 5, 5, 7, 11, 8, 7, 8, 7, 13, 10, 15, 16, 16, 18, 14, 9, 15, 15, 11, 14, 11, 12, 13, 14, 12, 17, 16, 18, 18, 14, 16, 15, 18, 14, 17, 14, 16, 17, 15, 17, 18, 17, 18 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,4
COMMENTS
This sequence was inspired by A055224.
See also A317419, A317441, A317443 and A317585 for similar sequences; these sequences can be defined as a(n) = Sum_{k=1..n-1} [P(a(k), a(n-k))] for some predicate P in two variables (where [] is an Iverson bracket).
LINKS
EXAMPLE
For n = 4:
- a(1) AND a(3) = 0 AND 1 = 0 = a(1),
- a(2) AND a(2) = 1 AND 1 = 1 = a(2),
- a(3) AND a(1) = 1 AND 0 = 0 <> a(3),
- hence a(4) = 2.
PROG
(PARI) a = vector(75); for (n=1, #a, a[n] = sum(k=1, n-1, bitand(a[k], a[n-k])==a[k]); print1 (a[n] ", "))
CROSSREFS
Sequence in context: A241604 A282900 A126014 * A256795 A273404 A281976
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, Jul 27 2018
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 June 4 06:06 EDT 2024. Contains 373089 sequences. (Running on oeis4.)