login
Partial sums of A084556.
9

%I #19 Jul 29 2017 12:52:06

%S 0,1,3,5,8,11,14,17,20,23,27,31,35,39,43,47,51,55,59,63,67,71,75,79,

%T 83,87,91,95,99,103,107,111,115,119,124,129,134,139,144,149,154,159,

%U 164,169,174,179,184,189,194,199,204,209,214,219,224,229,234,239,244,249

%N Partial sums of A084556.

%C For n>=1, (A130664(n),a(n)) = (1,1),(2,3),(4,5),(6,8),(9,11),(12,14),... gives the starting and ending offsets of the n-th permutation in the sequences like A030298 & A030496.

%C Note: this sequence is related to (ordinary) permutations. For a similar sequence related to juggling with three objects, see A084505.

%H A. Karttunen, <a href="/A084555/b084555.txt">Table of n, a(n) for n = 0..5614</a>

%H <a href="/index/Per#perm">Index entries for sequences related to permutations</a>

%F a(0)=0; for n >= 1, a(n) = a(n-1) + A084556(n). Also a(n) = A130664(n+1) - 1. - _Antti Karttunen_, Dec 18 2012

%t Accumulate@ Flatten[ Table[#, {#!}] & /@ Range[0, 5]]

%o (Scheme with memoization macro definec from _Antti Karttunen_'s intseq-library): (definec (A084555 n) (if (zero? n) 0 (+ (A084556 n) (A084555 (-1+ n)))))

%Y Differs from A084505 first time at the 130th term, where A084505(130) = 605, while A084555(130) = 604.

%K nonn

%O 0,3

%A _Antti Karttunen_, Jun 02 2003

%E Moved the misplaced Mathematica code from A084505. - _Antti Karttunen_, Oct 24 2012