The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A357624 Skew-alternating sum of the reversed n-th composition in standard order. 12

%I #5 Oct 08 2022 09:39:50

%S 0,1,2,0,3,-1,1,-1,4,-2,0,-2,2,-2,0,0,5,-3,-1,-3,1,-3,-1,1,3,-3,-1,-1,

%T 1,-1,1,1,6,-4,-2,-4,0,-4,-2,2,2,-4,-2,0,0,0,2,2,4,-4,-2,-2,0,-2,0,2,

%U 2,-2,0,0,2,0,2,0,7,-5,-3,-5,-1,-5,-3,3,1,-5,-3,1

%N Skew-alternating sum of the reversed n-th composition in standard order.

%C We define the skew-alternating sum of a sequence (A, B, C, D, E, F, G, ...) to be A - B - C + D + E - F - G + ....

%C The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

%H Gus Wiseman, <a href="https://docs.google.com/document/d/e/2PACX-1vTCPiJVFUXN8IqfLlCXkgP15yrGWeRhFS4ozST5oA4Bl2PYS-XTA3sGsAEXvwW-B0ealpD8qnoxFqN3/pub">Statistics, classes, and transformations of standard compositions</a>

%e The 357-th composition is (2,1,3,2,1) so a(357) = 1 - 2 - 3 + 2 + 1 = -1.

%e The 358-th composition is (2,1,3,1,2) so a(358) = 2 - 1 - 3 + 1 + 2 = 1.

%t stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;

%t skats[f_]:=Sum[f[[i]]*(-1)^(1+Ceiling[(i+1)/2]),{i,Length[f]}];

%t Table[skats[Reverse[stc[n]]],{n,0,100}]

%Y See link for sequences related to standard compositions.

%Y The half-alternating form is A357622, non-reverse A357621.

%Y The reverse version is A357623.

%Y Positions of zeros are A357628, non-reverse A357627.

%Y The version for prime indices is A357630.

%Y The version for Heinz numbers of partitions is A357634.

%Y A124754 gives alternating sum of standard compositions, reverse A344618.

%Y A357637 counts partitions by half-alternating sum, skew A357638.

%Y A357641 counts comps w/ half-alt sum 0, partitions A357639, even A357642.

%Y Cf. A001700, A001511, A053251, A344619, A357136, A357182, A357183, A357184, A357185, A357625, A357626, A357629, A357640.

%K sign

%O 0,3

%A _Gus Wiseman_, Oct 08 2022

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 7 20:29 EDT 2024. Contains 373206 sequences. (Running on oeis4.)