Nothing Special   »   [go: up one dir, main page]

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”).

A214040
a(n)=a(n-1)+floor((a(n-2)+a(n-3))/2), with a(n)=n for n<3.
1
0, 1, 2, 2, 3, 5, 7, 11, 17, 26, 40, 61, 94, 144, 221, 340, 522, 802, 1233, 1895, 2912, 4476, 6879, 10573, 16250, 24976, 38387, 59000, 90681, 139374, 214214, 329241, 506035, 777762, 1195400, 1837298, 2823879, 4340228, 6670816, 10252869, 15758391, 24220233
OFFSET
0,3
MATHEMATICA
RecurrenceTable[{a[0]==0, a[1]==1, a[2]==2, a[n]==a[n-1]+Floor[(a[n-2]+ a[n-3])/2]}, a, {n, 50}] (* Harvey P. Dale, Aug 25 2014 *)
PROG
(PARI) a(n) = if (n < 3, n, a(n-1) + (a(n-2)+a(n-3))\2) \\ Michel Marcus, Jul 10 2013
CROSSREFS
Sequence in context: A133225 A240487 A066889 * A077419 A125189 A226498
KEYWORD
nonn
AUTHOR
Alex Ratushnyak, Jul 01 2012
STATUS
approved