cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A357182 Number of integer compositions of n with the same length as their alternating sum.

This page as a plain text file.
%I A357182 #17 Sep 29 2022 12:55:57
%S A357182 1,1,0,0,1,3,1,4,6,20,13,48,50,175,141,512,481,1719,1491,5400,4929,
%T A357182 17776,15840,57420,52079,188656,169989,617176,559834,2033175,1842041,
%U A357182 6697744,6085950,22139780,20123989,73262232,66697354,242931321,221314299,806516560
%N A357182 Number of integer compositions of n with the same length as their alternating sum.
%C A357182 A composition of n is a finite sequence of positive integers summing to n.
%C A357182 The alternating sum of a sequence (y_1,...,y_k) is Sum_i (-1)^(i-1) y_i.
%e A357182 The a(1) = 1 through a(8) = 6 compositions:
%e A357182   (1)  (31)  (113)  (42)  (124)  (53)
%e A357182              (212)        (223)  (1151)
%e A357182              (311)        (322)  (2141)
%e A357182                           (421)  (3131)
%e A357182                                  (4121)
%e A357182                                  (5111)
%t A357182 ats[y_]:=Sum[(-1)^(i-1)*y[[i]],{i,Length[y]}];
%t A357182 Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],Length[#]==ats[#]&]],{n,0,15}]
%Y A357182 For product instead of length we have A114220.
%Y A357182 For sum equal to twice alternating sum we have A262977, ranked by A348614.
%Y A357182 For product equal to sum we have A335405, ranked by A335404.
%Y A357182 For absolute value we have A357183.
%Y A357182 These compositions are ranked by A357184.
%Y A357182 The case of partitions is A357189.
%Y A357182 A003242 counts anti-run compositions, ranked by A333489.
%Y A357182 A011782 counts compositions.
%Y A357182 A025047 counts alternating compositions, ranked by A345167.
%Y A357182 A124754 gives alternating sums of standard compositions.
%Y A357182 A238279 counts compositions by sum and number of maximal runs.
%Y A357182 A261983 counts non-anti-run compositions.
%Y A357182 A357136 counts compositions by alternating sum.
%Y A357182 Cf. A000120, A032020, A070939, A106356, A114901, A131044, A178470, A233564, A242882, A262046, A301987.
%K A357182 nonn
%O A357182 0,6
%A A357182 _Gus Wiseman_, Sep 28 2022
%E A357182 a(21)-a(39) from _Alois P. Heinz_, Sep 29 2022