login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A174980 Stern's diatomic series type ([0,1], 1) 2
0, 0, 1, 0, 2, 1, 1, 0, 3, 2, 3, 1, 2, 1, 1, 0, 4, 3, 5, 2, 5, 3, 4, 1, 3, 2, 3, 1, 2, 1, 1, 0, 5, 4, 7, 3, 8, 5, 7, 2, 7, 5, 8, 3, 7, 4, 5, 1, 4, 3, 5, 2, 5, 3, 4, 1, 3, 2, 3, 1, 2, 1, 1, 0, 6, 5, 9, 4, 11, 7, 10, 3, 11, 8, 13, 5, 12, 7, 9, 2, 9, 7, 12, 5, 13, 8, 11, 3, 10, 7, 11, 4, 9, 5, 6, 1, 5, 4, 7, 3, 8 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,5

COMMENTS

A variant of Stern's diatomic series A002487. See the article of P. Luschny and the Maple function below for the classification by types which is based on a generalization of Dijkstra's fusc function.

a(n) is also the number of superduperbinary integer partitions of n.

LINKS

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

Edsger Dijkstra, Selected Writings on Computing, Springer, 1982, p. 232. EWD 578: More about the function 'fusc'.

Peter Luschny, Rational Trees and Binary Partitions.

Moritz A. Stern, Über eine zahlentheoretische Funktion, J. Reine Angew. Math., 55 (1858), 193-220.

FORMULA

Recursion: a(2n + 1) = a(n) and a(2n) = a(n - 1) + a(n) + [n = 2k] for n = 1, a(0) = 0. [n = 2k] is 1 if n is a power of 2, 0 otherwise.

EXAMPLE

The sequence splits into rows of length 2k:

0,

0,1,

0,2,1,1,

0,3,2,3,1,2,1,1,

0,4,3,5,2,5,3,4,1,3,2,3,1,2,1,1,

MAPLE

SternDijkstra := proc(L, p, n) local k, i, len, M; len := nops(L); M := L; k := n; while k > 0 do M[1+(k mod len)] := add(M[i], i=1..len); k := iquo(k, len); od; op(p, M) end:

a := n -> SternDijkstra([0, 1], 1, n);

MATHEMATICA

a[0] = 0; a[n_?OddQ] := a[n] = a[(n-1)/2]; a[n_?EvenQ] := a[n] = a[n/2 - 1] + a[n/2] + Boole[ IntegerQ[ Log[2, n/2]]]; Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Jul 26 2013 *)

CROSSREFS

A002487, A070879, A047679, A007306, A174981.

Sequence in context: A080791 A124748 A161225 * A277488 A119513 A085815

Adjacent sequences:  A174977 A174978 A174979 * A174981 A174982 A174983

KEYWORD

easy,nonn,tabf

AUTHOR

Peter Luschny, Apr 03 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 | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified September 22 00:25 EDT 2017. Contains 292326 sequences.