A348614
Numbers k such that the k-th composition in standard order has sum equal to twice its alternating sum.
Original entry on oeis.org
0, 9, 11, 14, 130, 133, 135, 138, 141, 143, 148, 153, 155, 158, 168, 177, 179, 182, 188, 208, 225, 227, 230, 236, 248, 2052, 2057, 2059, 2062, 2066, 2069, 2071, 2074, 2077, 2079, 2084, 2089, 2091, 2094, 2098, 2101, 2103, 2106, 2109, 2111, 2120, 2129, 2131
Offset: 1
The terms together with their binary indices begin:
0: ()
9: (3,1)
11: (2,1,1)
14: (1,1,2)
130: (6,2)
133: (5,2,1)
135: (5,1,1,1)
138: (4,2,2)
141: (4,1,2,1)
143: (4,1,1,1,1)
148: (3,2,3)
153: (3,1,3,1)
155: (3,1,2,1,1)
158: (3,1,1,1,2)
The unordered case (partitions) is counted by
A000712, reverse
A006330.
These compositions are counted by
A262977.
Except for 0, a subset of
A345917 (which is itself a subset of
A345913).
A000346 = even-length compositions with alt sum != 0, complement
A001700.
A034871 counts compositions of 2n with alternating sum 2k.
A097805 counts compositions by alternating (or reverse-alternating) sum.
A103919 counts partitions by sum and alternating sum (reverse:
A344612).
A116406 counts compositions with alternating sum >=0, ranked by
A345913.
A138364 counts compositions with alternating sum 0, ranked by
A344619.
A345197 counts compositions by length and alternating sum.
Cf.
A008549,
A013777,
A027306,
A058622,
A088218,
A114121,
A120452,
A126869,
A163493,
A294175,
A344604.
-
ats[y_]:=Sum[(-1)^(i-1)*y[[i]],{i,Length[y]}];
stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
Select[Range[0,1000],Total[stc[#]]==2*ats[stc[#]]&]
A345907
Triangle giving the main antidiagonals of the matrices counting integer compositions by length and alternating sum (A345197).
Original entry on oeis.org
1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 2, 2, 1, 1, 0, 0, 4, 3, 1, 1, 0, 0, 3, 6, 4, 1, 1, 0, 0, 6, 9, 8, 5, 1, 1, 0, 0, 0, 18, 18, 10, 6, 1, 1, 0, 0, 0, 10, 36, 30, 12, 7, 1, 1, 0, 0, 0, 20, 40, 60, 45, 14, 8, 1, 1, 0, 0, 0, 0, 80, 100, 90, 63, 16, 9, 1, 1
Offset: 0
Triangle begins:
1
1 1
0 1 1
0 1 1 1
0 2 2 1 1
0 0 4 3 1 1
0 0 3 6 4 1 1
0 0 6 9 8 5 1 1
0 0 0 18 18 10 6 1 1
0 0 0 10 36 30 12 7 1 1
0 0 0 20 40 60 45 14 8 1 1
0 0 0 0 80 100 90 63 16 9 1 1
0 0 0 0 35 200 200 126 84 18 10 1 1
0 0 0 0 70 175 400 350 168 108 20 11 1 1
0 0 0 0 0 350 525 700 560 216 135 22 12 1 1
Rows are the antidiagonals of the matrices given by
A345197.
A097805 counts compositions by alternating (or reverse-alternating) sum.
A103919 counts partitions by sum and alternating sum (reverse:
A344612).
A316524 gives the alternating sum of prime indices (reverse:
A344616).
Compositions of n, 2n, or 2n+1 with alternating/reverse-alternating sum k:
-
ats[y_]:=Sum[(-1)^(i-1)*y[[i]],{i,Length[y]}];
Table[Table[Length[Select[Join@@Permutations/@IntegerPartitions[n,{n-k}],k==(n+ats[#])/2-1&]],{k,0,n-1}],{n,0,15}]
A349155
Numbers k such that the k-th composition in standard order has sum equal to negative twice its reverse-alternating sum.
Original entry on oeis.org
0, 9, 130, 135, 141, 153, 177, 193, 225, 2052, 2059, 2062, 2069, 2074, 2079, 2089, 2098, 2103, 2109, 2129, 2146, 2151, 2157, 2169, 2209, 2242, 2247, 2253, 2265, 2289, 2369, 2434, 2439, 2445, 2457, 2481, 2529, 2561, 2689, 2818, 2823, 2829, 2841, 2865, 2913
Offset: 1
The terms and corresponding compositions begin:
0: ()
9: (3,1)
130: (6,2)
135: (5,1,1,1)
141: (4,1,2,1)
153: (3,1,3,1)
177: (2,1,4,1)
193: (1,6,1)
225: (1,1,5,1)
2052: (9,3)
2059: (8,2,1,1)
2062: (8,1,1,2)
2069: (7,2,2,1)
2074: (7,1,2,2)
2079: (7,1,1,1,1,1)
2089: (6,2,3,1)
2098: (6,1,3,2)
2103: (6,1,2,1,1,1)
These compositions are counted by
A224274 up to 0's.
A positive unordered version is
A349160, counted by
A006330 up to 0's.
A003242 counts Carlitz compositions.
A025047 counts alternating or wiggly compositions, complement
A345192.
A116406 counts compositions with alternating sum >=0, ranked by
A345913.
A138364 counts compositions with alternating sum 0, ranked by
A344619.
Cf.
A000070,
A000346,
A001250,
A001700,
A008549,
A027306,
A058622,
A088218,
A114121,
A120452,
A262977,
A294175,
A345917.
Statistics of standard compositions:
- The compositions themselves are the rows of
A066099.
- Heinz number is given by
A333219.
Classes of standard compositions:
-
stc[n_]:=Differences[Prepend[ Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
sats[y_]:=Sum[(-1)^(i-Length[y])*y[[i]],{i,Length[y]}];
Select[Range[0,1000],Total[stc[#]]==-2*sats[stc[#]]&]
A349154
Numbers k such that the k-th composition in standard order has sum equal to negative twice its alternating sum.
Original entry on oeis.org
0, 12, 160, 193, 195, 198, 204, 216, 240, 2304, 2561, 2563, 2566, 2572, 2584, 2608, 2656, 2752, 2944, 3074, 3077, 3079, 3082, 3085, 3087, 3092, 3097, 3099, 3102, 3112, 3121, 3123, 3126, 3132, 3152, 3169, 3171, 3174, 3180, 3192, 3232, 3265, 3267, 3270, 3276
Offset: 1
The terms and corresponding compositions begin:
0: ()
12: (1,3)
160: (2,6)
193: (1,6,1)
195: (1,5,1,1)
198: (1,4,1,2)
204: (1,3,1,3)
216: (1,2,1,4)
240: (1,1,1,5)
2304: (3,9)
2561: (2,9,1)
2563: (2,8,1,1)
2566: (2,7,1,2)
2572: (2,6,1,3)
2584: (2,5,1,4)
These compositions are counted by
A224274 up to 0's.
A positive unordered version is
A349159, counted by
A000712 up to 0's.
A000346 = even-length compositions with alt sum != 0, complement
A001700.
A003242 counts Carlitz compositions.
A025047 counts alternating or wiggly compositions, complement
A345192.
A103919 counts partitions by sum and alternating sum (reverse:
A344612).
A116406 counts compositions with alternating sum >=0, ranked by
A345913.
A138364 counts compositions with alternating sum 0, ranked by
A344619.
Cf.
A000070,
A000984,
A008549,
A027306,
A058622,
A088218,
A114121,
A120452,
A262977,
A294175,
A345917,
A349160.
Statistics of standard compositions:
- The compositions themselves are the rows of
A066099.
Classes of standard compositions:
-
ats[y_]:=Sum[(-1)^(i-1)*y[[i]],{i,Length[y]}];
stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
Select[Range[0,1000],Total[stc[#]]==-2*ats[stc[#]]&]
A360168
a(n) = Sum_{k=0..floor(n/3)} binomial(2*n,n-3*k).
Original entry on oeis.org
1, 2, 6, 21, 78, 297, 1145, 4447, 17358, 68001, 267141, 1051767, 4148281, 16385111, 64797543, 256515731, 1016368078, 4030114641, 15990813773, 63485616391, 252175202373, 1002136689071, 3984080489263, 15844839393411, 63036297959993, 250855287692647
Offset: 0
-
A360168 := proc(n)
add(binomial(2*n,n-3*k),k=0..n/3) ;
end proc:
seq(A360168(n),n=0..70) ; # R. J. Mathar, Mar 12 2023
-
a[n_] := Sum[Binomial[2*n, n - 3*k], {k, 0, Floor[n/3]}]; Array[a, 26, 0] (* Amiram Eldar, Jan 28 2023 *)
-
a(n) = sum(k=0, n\3, binomial(2*n, n-3*k));
-
my(N=30, x='x+O('x^N)); Vec(1/(sqrt(1-4*x)*(1-x^3*(2/(1+sqrt(1-4*x)))^6)))
A387033
a(n) = Sum_{k=0..n} binomial(3*n-1,k).
Original entry on oeis.org
1, 3, 16, 93, 562, 3473, 21778, 137980, 880970, 5658537, 36519556, 236618693, 1538132224, 10026362492, 65513177704, 428957009288, 2813768603466, 18486790962201, 121634649321208, 801330506737399, 5285305708097522, 34896814868837161, 230631268849574378
Offset: 0
-
[&+[Binomial(3*n-1,k): k in [0..n]]: n in [0..25]]; // Vincenzo Librandi, Aug 27 2025
-
Table[Sum[Binomial[3*n-1,k],{k,0,n}],{n,0,25}] (* Vincenzo Librandi, Aug 27 2025 *)
-
a(n) = sum(k=0, n, binomial(3*n-1, k));
A387037
a(n) = Sum_{k=0..n} binomial(4*n-1,k).
Original entry on oeis.org
1, 4, 29, 232, 1941, 16664, 145499, 1285624, 11460949, 102875128, 928495764, 8417689504, 76599066579, 699232769512, 6400175653922, 58718827590992, 539822826733397, 4971747032359352, 45863130731297180, 423683961417124576, 3919058645835901556
Offset: 0
-
[&+[Binomial(4*n-1, k): k in [0..n]]: n in [0..25]]; // Vincenzo Librandi, Sep 03 2025
-
Table[Sum[Binomial[4*n-1,k],{k,0,n}],{n,0,30}] (* Vincenzo Librandi, Sep 03 2025 *)
-
a(n) = sum(k=0, n, binomial(4*n-1, k));
A349153
Numbers k such that the k-th composition in standard order has sum equal to twice its reverse-alternating sum.
Original entry on oeis.org
0, 11, 12, 14, 133, 138, 143, 148, 155, 158, 160, 168, 179, 182, 188, 195, 198, 204, 208, 216, 227, 230, 236, 240, 248, 2057, 2066, 2071, 2077, 2084, 2091, 2094, 2101, 2106, 2111, 2120, 2131, 2134, 2140, 2149, 2154, 2159, 2164, 2171, 2174, 2192, 2211, 2214
Offset: 1
The terms and corresponding compositions begin:
0: ()
11: (2,1,1)
12: (1,3)
14: (1,1,2)
133: (5,2,1)
138: (4,2,2)
143: (4,1,1,1,1)
148: (3,2,3)
155: (3,1,2,1,1)
158: (3,1,1,1,2)
160: (2,6)
168: (2,2,4)
179: (2,1,3,1,1)
182: (2,1,2,1,2)
188: (2,1,1,1,3)
These compositions are counted by
A262977 up to 0's.
The unreversed negative version is
A349154.
A non-reverse unordered version is
A349159, counted by
A000712 up to 0's.
A003242 counts Carlitz compositions.
A025047 counts alternating or wiggly compositions, complement
A345192.
A116406 counts compositions with alternating sum >=0, ranked by
A345913.
A138364 counts compositions with alternating sum 0, ranked by
A344619.
Cf.
A000070,
A000346,
A001250,
A001700,
A008549,
A027306,
A058622,
A088218,
A114121,
A120452,
A294175.
Statistics of standard compositions:
- The compositions themselves are the rows of
A066099.
- Heinz number is given by
A333219.
Classes of standard compositions:
-
stc[n_]:=Differences[ Prepend[Join@@Position[ Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
sats[y_]:=Sum[(-1)^(i-Length[y])*y[[i]],{i,Length[y]}];
Select[Range[0,1000],Total[stc[#]]==2*sats[stc[#]]&]
A307665
A(n,k) = Sum_{j=0..floor(n/k)} binomial(2*n,k*j+n), square array A(n,k) read by antidiagonals, for n >= 0, k >= 1.
Original entry on oeis.org
1, 1, 3, 1, 2, 11, 1, 2, 7, 42, 1, 2, 6, 26, 163, 1, 2, 6, 21, 99, 638, 1, 2, 6, 20, 78, 382, 2510, 1, 2, 6, 20, 71, 297, 1486, 9908, 1, 2, 6, 20, 70, 262, 1145, 5812, 39203, 1, 2, 6, 20, 70, 253, 990, 4447, 22819, 155382, 1, 2, 6, 20, 70, 252, 936, 3796, 17358, 89846, 616666
Offset: 0
Square array begins:
1, 1, 1, 1, 1, 1, 1, 1, ...
3, 2, 2, 2, 2, 2, 2, 2, ...
11, 7, 6, 6, 6, 6, 6, 6, ...
42, 26, 21, 20, 20, 20, 20, 20, ...
163, 99, 78, 71, 70, 70, 70, 70, ...
638, 382, 297, 262, 253, 252, 252, 252, ...
2510, 1486, 1145, 990, 936, 925, 924, 924, ...
9908, 5812, 4447, 3796, 3523, 3446, 3433, 3432, ...
-
T[n_, k_] := Sum[Binomial[2*n, k*j + n], {j, 0, Floor[n/k]}]; Table[T[n - k, k], {n, 0, 11}, {k, n, 1, -1}] // Flatten (* Amiram Eldar, May 13 2021*)
A360149
a(n) = Sum_{k=0..floor(n/2)} binomial(2*n+k,n-2*k).
Original entry on oeis.org
1, 2, 7, 27, 107, 429, 1731, 7012, 28478, 115864, 471991, 1924483, 7852083, 32053208, 130893949, 534673600, 2184482707, 8926392419, 36479840422, 149095843951, 609400587426, 2490900041118, 10181669553847, 41618414303969, 170118507902985, 695366323719302
Offset: 0
-
A360149 := proc(n)
add(binomial(2*n+k,n-2*k),k=0..floor(n/2)) ;
end proc:
seq(A360149(n),n=0..40) ; # R. J. Mathar, Mar 02 2023
-
a[n_] := Sum[Binomial[2*n + k, n - 2*k], {k, 0, Floor[n/2]}]; Array[a, 26, 0] (* Amiram Eldar, Jan 28 2023 *)
-
a(n) = sum(k=0, n\2, binomial(2*n+k, n-2*k));
-
my(N=30, x='x+O('x^N)); Vec(1/(sqrt(1-4*x)*(1-x^2*(2/(1+sqrt(1-4*x)))^5)))
Comments