[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
login
Search: a006046 -id:a006046
     Sort: relevance | references | number | modified | created      Format: long | short | data
Total number of odd coefficients in (1+x+x^2)^k for k=0,...,n.
+10
7
1, 4, 7, 12, 15, 24, 29, 40, 43, 52, 61, 76, 81, 96, 107, 128, 131, 140, 149, 164, 173, 200, 215, 248, 253, 268, 283, 308, 319, 352, 373, 416, 419, 428, 437, 452, 461, 488, 503, 536, 545, 572, 599, 644, 659, 704, 737, 800, 805, 820, 835, 860, 875, 920, 945, 1000
OFFSET
0,2
COMMENTS
a(n) = Sum_{k <= n} A071053(k)
LINKS
S. R. Finch, P. Sebah and Z.-Q. Bai, Odd Entries in Pascal's Trinomial Triangle (arXiv:0802.2654)
N. J. A. Sloane, On the Number of ON Cells in Cellular Automata, arXiv:1503.01168, 2015
MATHEMATICA
Sum[PolynomialMod[(1+x+x^2)^k, 2] /. x->1, {k, 0, n-1}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Steven Finch, Jan 25 2008
EXTENSIONS
Offset changed to 0 by N. J. A. Sloane, Feb 06 2015
STATUS
approved
Number of triangles after n-th stage in a cellular automaton based in isosceles triangles of two sizes (see Comments lines for precise definition).
+10
7
0, 1, 3, 7, 11, 15, 23, 33, 41, 45, 53, 65, 81, 91, 111, 133, 149, 153, 161, 173, 189, 201, 225, 253, 285, 295, 315, 343, 383, 405, 449, 495, 527, 531, 539, 551, 567, 579, 603, 631, 663, 675, 699, 731, 779, 807, 863, 923, 987, 997, 1017, 1045, 1085, 1113, 1169, 1233, 1313, 1335, 1379, 1439, 1527, 1573, 1665, 1759, 1823
OFFSET
0,3
COMMENTS
On the semi-infinite square grid the structure of this C.A. contains "black" triangles and "gray" triangles (see the Links section). Both types of triangles have two sides of length 5^(1/2). Every black triangle has a base of length 2 hence its height is 2 and its area is 2. Every gray triangle has a base of length 2^(1/2) hence its height is 3/(2^(1/2)) and its area is 3/2. Both types of triangles are arranged in the same way as the triangles of Sierpinski gasket (see A047999 and A006046). The black triangles are arranged in vertical direction. On the other hand the gray triangles are arranged in diagonal direction in the holes of the structure formed by the black triangles. Note that the vertices of all triangles coincide with the grid points.
The sequence gives the total number of triangles (black and gray) in the structure after n-th stage. A231349 (the first differences) gives the number of triangles added at n-th stage.
For a more complex structure see A233780.
EXAMPLE
We start at stage 0 with no triangles, so a(0) = 0.
At stage 1 we add a black triangle, so a(1) = 1.
At stage 2 we add two black triangles, so a(2) = 1+2 = 3.
At stage 3 we add two black triangles and two gray triangles from the vertices of the master triangle, so a(3) = 3+2+2 = 7.
At stage 4 we add four black triangles, so a(4) = 7+4 = 11.
At stage 5 we add two black triangles and two gray triangles from the vertices of the master triangle, so a(5) = 11+2+2 = 15.
At stage 6 we add four black triangles and four gray triangles, so a(6) = 15+4+4 = 23.
At stage 7 we add four black triangles and six gray triangles, so a(7) = 23+4+6 = 33.
At stage 8 we add eight black triangles, so a(8) = 33+8 = 41.
And so on.
Note that always we add both black triangles and gray triangles except if n is a power of 2. In this case at stage 2^k we add only 2^k black triangles, for k >= 0.
KEYWORD
nonn
AUTHOR
Omar E. Pol, Dec 15 2013
STATUS
approved
If n = binomial(b,2)+binomial(c,1), b>c>=0 then a(n) = binomial(b+1,3)+binomial(c+1,2).
+10
5
1, 2, 4, 5, 7, 10, 11, 13, 16, 20, 21, 23, 26, 30, 35, 36, 38, 41, 45, 50, 56, 57, 59, 62, 66, 71, 77, 84, 85, 87, 90, 94, 99, 105, 112, 120, 121, 123, 126, 130, 135, 141, 148, 156, 165, 166, 168, 171, 175, 180, 186, 193, 201, 210, 220, 221, 223, 226, 230, 235, 241
OFFSET
1,2
COMMENTS
Triangle-tree numbers: a(n) = sum(b(m), m = 1..n), b(m) = 1,1,2,1,2,3,1,2,3,4,... = A002260. - Klaus Strassburger (strass(AT)ddfi.uni-duesseldorf.de)
REFERENCES
W. Bruns and J. Herzog, Cohen-Macaulay Rings, Cambridge, 1993, p. 159.
FORMULA
a(n*(n+1)/2+m)=n*(n+1)*(n+2)/6 + m*(m+1)/2=A000292(n)+ A000217(m), m=0...n+1, n=1, 2, 3.. - Klaus Strassburger (strass(AT)ddfi.uni-duesseldorf.de)
a(n) = a(n-1)+A002260(n). As a triangle with n >= k >= 1: a(n, k) =a(n-1, k)+(n-1)*n/2 =a(n, k-1)+k =(n^3-n+3k^2+3k)/6. - Henry Bottomley, Nov 14 2001
a(n) = b(n) * (b(n) + 1) * (b(n) + 2) / 6 + c(n) * (c(n) + 1) / 2, where b(n) = [sqrt(2 * n) - 1/2] and c(n) = n - b(n) * (b(n) + 1) / 2 - Robert A. Stump (bee_ess107(AT)msn.com), Sep 20 2002
As a triangle, T(n,k) = binomial(n+1, 3) + binomial(k+1,2). - Franklin T. Adams-Watters, Jan 27 2014
EXAMPLE
The triangle starts:
1
2 4
5 7 10
11 13 16 20
21 23 26 30 35
MAPLE
a := 0: for i from 1 to 15 do for j from 1 to i do a := a+j: printf(`%d, `, a); od:od:
CROSSREFS
Cf. A002260, A000292 (main diagonal), A000217, A014368, A014369, A006046, A050407 (1st column), A005581 (subdiagonal), A071239 (row sums), A212013.
KEYWORD
nonn,easy,tabl
AUTHOR
EXTENSIONS
More terms from James A. Sellers, Feb 05 2000
STATUS
approved
a(n) = Sum_{k=1..n} 2^b(k) where b(k) denotes the number of 1's in the binary representation of k.
+10
5
2, 4, 8, 10, 14, 18, 26, 28, 32, 36, 44, 48, 56, 64, 80, 82, 86, 90, 98, 102, 110, 118, 134, 138, 146, 154, 170, 178, 194, 210, 242, 244, 248, 252, 260, 264, 272, 280, 296, 300, 308, 316, 332, 340, 356, 372, 404, 408, 416, 424, 440, 448, 464, 480, 512, 520, 536
OFFSET
1,1
LINKS
Hsien-Kuei Hwang, Svante Janson, and Tsung-Hsi Tsai, Identities and periodic oscillations of divide-and-conquer recurrences splitting at half, arXiv:2210.10968 [cs.DS], 2022, p. 29.
FORMULA
a(n+1)-a(n) = A001316(n)
From Ralf Stephan, Oct 07 2003: (Start)
a(0)=0, a(2n) = 2a(n-1) + a(n) + 2, a(2n+1) = 3a(n) + 2.
G.f.: (1/(1-x)) * Product_{k>=0} (1 + 2x^2^k). (End)
MAPLE
f:= proc(n) option remember; if n::even then 2*procname(n/2-1)+procname(n/2)+2
else 3*procname((n-1)/2)+2
fi
end proc:
f(0):= 0:
map(f, [$1..100]); # Robert Israel, Oct 08 2020
MATHEMATICA
b[n_] := IntegerDigits[n, 2] // Total;
a[n_] := 2^(b /@ Range[n]) // Total;
Array[a, 100] (* Jean-François Alcover, Aug 16 2022 *)
PROG
(PARI) a(n)=sum(i=1, n, 2^sum(k=1, length(binary(i)), component(binary(i), k)))
CROSSREFS
a(n) = A006046(n+1)-1. Cf. A080263.
KEYWORD
easy,nonn
AUTHOR
Benoit Cloitre, Oct 06 2002
STATUS
approved
a(0)=1, a(1)=1, a(n) = 11*a(n/2) for even n, and a(n) = 10*a((n-1)/2) + a((n+1)/2) for odd n >= 3.
+10
5
0, 1, 11, 21, 121, 131, 231, 331, 1331, 1341, 1441, 1541, 2541, 2641, 3641, 4641, 14641, 14651, 14751, 14851, 15851, 15951, 16951, 17951, 27951, 28051, 29051, 30051, 40051, 41051, 51051, 61051, 161051, 161061, 161161, 161261, 162261, 162361, 163361, 164361
OFFSET
0,3
COMMENTS
From Gary W. Adamson, Aug 30 2016: (Start)
Let M =
1, 0, 0, 0, 0, ...
11, 0, 0, 0, 0, ...
10, 1, 0, 0, 0, ...
0, 11, 0, 0, 0, ...
0, 10, 1, 0, 0, ...
0, 0, 11, 0, 0, ...
0, 0, 10, 1, 0, ...
...
Then lim_{k->infinity} M^k converges to a single nonzero column giving the sequence.
The sequence divided by its aerated variant is (1, 11, 10, 0, 0, 0, ...). (End)
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..16383 (first 2501 terms from G. C. Greubel)
H. Harborth, Number of Odd Binomial Coefficients, Proc. Amer. Math. Soc. 62, 19-22, 1977.
Hsien-Kuei Hwang, Svante Janson, and Tsung-Hsi Tsai, Identities and periodic oscillations of divide-and-conquer recurrences splitting at half, arXiv:2210.10968 [cs.DS], 2022, pp. 27, 33.
Eric Weisstein's World of Mathematics, Stolarsky-Harborth Constant
FORMULA
Let r(x) = (1 + 11x + 10x^2). The sequence is r(x) * r(x^2) * r(x^4) * r(x^8) * ... - Gary W. Adamson, Aug 30 2016
a(n) = Sum_{k=0..n-1} 10^wt(k), where wt = A000120. - Mike Warburton, Mar 14 2019
a(n) = Sum_{k=0..floor(log_2(n))} 10^k*A360189(n-1,k). - Alois P. Heinz, Mar 06 2023
MAPLE
a:=proc(n) if n=0 then 0 elif n=1 then 1 elif n mod 2 = 0 then 11*a(n/2) else 10*a((n-1)/2)+a((n+1)/2) fi end: seq(a(n), n=0..42);
MATHEMATICA
b[0] := 0; b[1] := 1; b[n_?EvenQ] := b[n] = 11*b[n/2]; b[n_?OddQ] := b[n] = 10*b[(n - 1)/2] + b[(n + 1)/2]; a = Table[b[n], {n, 1, 25}]
KEYWORD
nonn,changed
AUTHOR
Roger L. Bagula, Mar 15 2006
EXTENSIONS
Edited by N. J. A. Sloane, Apr 16 2005
STATUS
approved
a(0)=1, a(1)=1, a(n) = 9*a(n/2) for even n >= 2, and a(n) = 8*a((n-1)/2) + a((n+1)/2) for odd n >= 3.
+10
5
0, 1, 9, 17, 81, 89, 153, 217, 729, 737, 801, 865, 1377, 1441, 1953, 2465, 6561, 6569, 6633, 6697, 7209, 7273, 7785, 8297, 12393, 12457, 12969, 13481, 17577, 18089, 22185, 26281, 59049, 59057, 59121, 59185, 59697, 59761, 60273, 60785, 64881, 64945, 65457, 65969
OFFSET
0,3
COMMENTS
A 9-divide version of A084230.
The interest this one has is in the prime form of even odd 2^n+1, 2^n.
From Gary W. Adamson, Aug 30 2016: (Start)
Let M =
1, 0, 0, 0, 0, ...
9, 0, 0, 0, 0, ...
8, 1, 0, 0, 0, ...
0, 9, 0, 0, 0, ...
0, 8, 1, 0, 0, ...
0, 0, 9, 0, 0, ...
0, 0, 8, 1, 0, ...
...
Then M^k converges to a single nonzero column giving the sequence.
The sequence divided by its aerated variant is (1, 9, 8, 0, 0, 0, ...). (End)
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..16383 (first 2501 terms from G. C. Greubel)
H. Harborth, Number of Odd Binomial Coefficients, Proc. Amer. Math. Soc. 62, 19-22, 1977.
Hsien-Kuei Hwang, Svante Janson, and Tsung-Hsi Tsai, Identities and periodic oscillations of divide-and-conquer recurrences splitting at half, arXiv:2210.10968 [cs.DS], 2022, pp. 27, 33.
Eric Weisstein's World of Mathematics, Stolarsky-Harborth Constant
FORMULA
a(n) = Sum_{k=0..n-1} 8^wt(k), where wt = A000120. - Mike Warburton, Mar 14 2019
a(n) = Sum_{k=0..floor(log_2(n))} 8^k*A360189(n-1,k). - Alois P. Heinz, Mar 06 2023
MAPLE
a:=proc(n) if n=0 then 0 elif n=1 then 1 elif n mod 2 = 0 then 9*a(n/2) else 8*a((n-1)/2)+a((n+1)/2) fi end: seq(a(n), n=0..45);
MATHEMATICA
b[0] := 0; b[1] := 1; b[n_?EvenQ] := b[n] = 9*b[n/2]; b[n_?OddQ] := b[n] = 8*b[(n - 1)/2] + b[(n + 1)/2]; a = Table[b[n], {n, 1, 25}]
KEYWORD
nonn,changed
AUTHOR
Roger L. Bagula, Mar 15 2006
EXTENSIONS
Edited by N. J. A. Sloane, Apr 16 2006
STATUS
approved
Number of entries in the n-th row of Pascal's triangle not divisible by 5.
+10
5
1, 2, 3, 4, 5, 2, 4, 6, 8, 10, 3, 6, 9, 12, 15, 4, 8, 12, 16, 20, 5, 10, 15, 20, 25, 2, 4, 6, 8, 10, 4, 8, 12, 16, 20, 6, 12, 18, 24, 30, 8, 16, 24, 32, 40, 10, 20, 30, 40, 50, 3, 6, 9, 12, 15, 6, 12, 18, 24, 30, 9, 18, 27, 36, 45, 12, 24, 36, 48, 60, 15, 30
OFFSET
0,2
COMMENTS
Pascal triangles modulo p with p prime have the dimension D = log(p*(p+1)/2)/log(p). [Corrected by Connor Lane, Nov 28 2022]
Also number of ones in row n of triangle A254609. - Reinhard Zumkeller, Feb 04 2015
LINKS
FORMULA
a(n) = Product_{d=1..4} (d+1)^b(n,d) with b(n,d) = number of digits d in base 5 expansion of n. The formula generalizes to other prime bases p.
a(n) = A194458(n) - A194458(n-1).
EXAMPLE
n = 32 = 112|_5: b(32,1) = 2, b(32,2) = 1, thus a(32) = 2^2 * 3^1 = 12.
MAPLE
a:= proc(n) local l, m, t;
m:= n;
l:= [0$5];
while m>0 do t:= irem(m, 5, 'm')+1; l[t]:=l[t]+1 od;
mul(r^l[r], r=2..5)
end:
seq(a(n), n=0..100);
MATHEMATICA
Nest[Join[#, 2#, 3#, 4#, 5#]&, {1}, 4] (* Jean-François Alcover, Apr 12 2017, after code by Robert G. Wilson v in A006047 *)
PROG
(Haskell)
a194459 = sum . map (signum . flip mod 5) . a007318_row
-- Reinhard Zumkeller, Feb 04 2015
CROSSREFS
Cf. A006046, A001316 (for p=2).
Cf. A006048, A006047 (for p=3).
Cf. A194458 (for p=5).
KEYWORD
nonn,look
AUTHOR
Paul Weisenhorn, Aug 24 2011
EXTENSIONS
Edited by Alois P. Heinz, Sep 06 2011
STATUS
approved
Partial sums of A134660.
+10
5
1, 5, 9, 13, 17, 33, 37, 45, 49, 65, 81, 85, 89, 105, 113, 129, 133, 149, 165, 181, 197, 261, 265, 273, 277, 293, 309, 317, 325, 357, 373, 405, 409, 425, 441, 457, 473, 537, 553, 585, 601, 665, 729, 733, 737, 753, 761, 777, 781, 797, 813, 829, 845, 909, 917, 933, 941, 973, 1005, 1021, 1037, 1101, 1133, 1197
OFFSET
0,2
COMMENTS
All the following are of the same type: A006046, A134659, A255649-A255653. For more information see A255488.
KEYWORD
nonn,look
AUTHOR
Omar E. Pol, Mar 01 2015
STATUS
approved
Partial sums of A134661.
+10
5
1, 4, 7, 14, 17, 26, 33, 46, 49, 58, 67, 86, 93, 114, 127, 154, 157, 166, 175, 196, 205, 232, 251, 286, 293, 314, 335, 376, 389, 428, 455, 510, 513, 522, 531, 552, 561, 588, 609, 648, 657, 684, 711, 766, 785, 842, 877, 950, 957, 978, 999, 1048, 1069, 1132, 1173, 1248, 1261, 1300, 1339, 1418, 1445, 1526, 1581, 1690
OFFSET
0,2
COMMENTS
All the following are of the same type: A006046, A134659, A255645, A255650-A255653. For more information see A255488.
KEYWORD
nonn,look
AUTHOR
Omar E. Pol, Mar 01 2015
STATUS
approved
Partial sums of A134662.
+10
5
1, 4, 7, 16, 19, 26, 35, 52, 55, 64, 71, 92, 101, 118, 135, 168, 171, 180, 189, 216, 223, 240, 261, 304, 313, 340, 357, 408, 425, 460, 493, 560, 563, 572, 581, 608, 617, 638, 665, 716, 723, 744, 761, 812, 833, 874, 917, 1000, 1009, 1036, 1063, 1144, 1161, 1204, 1255, 1368, 1385, 1436, 1471, 1576, 1609, 1676, 1743, 1880
OFFSET
0,2
COMMENTS
All the following are of the same type: A006046, A134659, A255645, A255649, A255651-A255653. For more information see A255488.
KEYWORD
nonn,look
AUTHOR
Omar E. Pol, Mar 01 2015
STATUS
approved

Search completed in 0.034 seconds