%I #16 Feb 17 2014 20:31:57
%S 1,1,2,2,3,3,3,4,4,4,4,5,5,5,5,5,6,6,6,6,6,6,7,7,7,7,7,7,8,8,8,8,8,8,
%T 8,9,9,9,9,9,9,9,9,10,10,10,10,10,10,10,10,11,11,11,11,11,11,11,11,12,
%U 12,12,12,12,12,12,12,12,13,13,13,13,13,13,13,13,13,13,14,14,14,14,14,14
%N a(1) = a(2) = 1. For n > 1, n is repeated (a(n)+a(n-1)) times.
%C Differs from A002024(n+1) from the first 8 on: there are only six "7", only seven "8", only eight "9" and "10" and "11" in the present sequence; from there on, n is repeated less than n-2 times. - _M. F. Hasler_, Feb 16 2014
%H M. F. Hasler, <a href="/A130148/b130148.txt">Table of n, a(n) for n = 1..1965</a>
%o (PARI) lista(nn) = {va = vector(nn, i, (i==1) || (i==2)); ipos = 3; n = 2; while ((ipos <= nn), nbr = va[n] + va[n-1]; while (nbr && (ipos <= nn), va[ipos] = n; ipos++; nbr--); n++;); for (i=1, nn, print1(va[i], ", "));} \\ _Michel Marcus_, Feb 17 2014
%o (PARI) a=[1,1];for(n=2,20,a=concat(a,vector(a[n]+a[n-1],j,n));a \\ _M. F. Hasler_, Feb 17 2014
%Y Cf. A001462.
%K easy,nonn
%O 1,3
%A _Leroy Quet_, Aug 02 2007
|