login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A052109
a(1)=1, a(n)=a(n-a(1))+a(n-a(2))+a(n-a(3))+....a(n-a(n-1)) for n>1, with convention that a(i)=0 for i<=0.
2
1, 1, 2, 5, 12, 30, 73, 178, 434, 1058, 2580, 6291, 15341, 37408, 91217, 222427, 542374, 1322546, 3224947, 7863835, 19175478, 46758223, 114017050, 278023561, 677943348, 1653123143, 4031039074, 9829440768, 23968486545, 58445679752, 142516194140, 347516970942
OFFSET
1,3
LINKS
Emmanuel Preissmann, A Self-Indexed Sequence, Journal of Integer Sequences, Vol. 8 (2005), Article 05.3.5.
EXAMPLE
a(5) = a(4)+a(4)+a(3) = 5+5+2 = 12.
MATHEMATICA
a[1] = 1; a[n_ /; n <= 0] = 0; a[n_] := a[n] = Sum[a[n - a[k]], {k, 1, n-1}]; Table[a[n], {n, 1, 32}] (* Jean-François Alcover, Oct 07 2013 *)
PROG
(Haskell)
a052109 n = a052109_list !! (n-1)
a052109_list = 1 : f 2 [1] where
f n xs = z : f (n+1) (z:xs) where
z = sum $ map (a052109 . fromInteger) $
dropWhile (<= 0) $ map (n -) xs
-- Reinhard Zumkeller, Dec 02 2011
CROSSREFS
Cf. A004001.
Sequence in context: A291253 A348619 A101911 * A157748 A046170 A369145
KEYWORD
easy,nonn,nice
AUTHOR
Robert Lozyniak (11(AT)onna.com), Jan 20 2000
EXTENSIONS
More terms from David W. Wilson, Feb 01 2000
STATUS
approved