login
A319890
a(n) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 + 21*20*19*18*17*16*15 - ... + (up to the n-th term).
8
7, 42, 210, 840, 2520, 5040, 5040, 5026, 4858, 2856, -18984, -235200, -2157120, -17292240, -17292219, -17291820, -17284260, -17148600, -14850360, 21777840, 568758960, 568758932, 568758204, 568739304, 568267560, 556965360, 297506160, -5398802640, -5398802605
OFFSET
1,1
COMMENTS
For similar sequences that alternate in descending blocks of k natural numbers, we have: a(n) = (-1)^floor(n/k) * Sum_{j=1..k-1} (floor((n-j)/k) - floor((n-j-1)/k)) * (Product_{i=1..j} n-i-j+k+1) + Sum_{j=1..n} (-1)^(floor(j/k)+1) * (floor(j/k) - floor((j-1)/k)) * (Product_{i=1..k} j-i+1). Here, k=7.
EXAMPLE
a(1) = 7;
a(2) = 7*6 = 42;
a(3) = 7*6*5 = 210;
a(4) = 7*6*5*4 = 840;
a(5) = 7*6*5*4*3 = 2520;
a(6) = 7*6*5*4*3*2 = 5040;
a(7) = 7*6*5*4*3*2*1 = 5040;
a(8) = 7*6*5*4*3*2*1 - 14 = 5026;
a(9) = 7*6*5*4*3*2*1 - 14*13 = 4858;
a(10) = 7*6*5*4*3*2*1 - 14*13*12 = 2856;
a(11) = 7*6*5*4*3*2*1 - 14*13*12*11 = -18984;
a(12) = 7*6*5*4*3*2*1 - 14*13*12*11*10 = -235200;
a(13) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9 = -2157120;
a(14) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 = -17292240;
a(15) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 + 21 = -17292219;
a(16) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 + 21*20 = -17291820;
a(17) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 + 21*20*19 = -17284260;
a(18) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 + 21*20*19*18 = -17148600;
a(19) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 + 21*20*19*18*17 = -14850360;
a(20) = 7*6*5*4*3*2*1 - 14*13*12*11*10*9*8 + 21*20*19*18*17*16 = 21777840;
etc.
MAPLE
a:=(n, k)->(-1)^(floor(n/k))* add((floor((n-j)/k)-floor((n-j-1)/k))*(mul(n-i-j+k+1, i=1..j)), j=1..k-1) + add( (-1)^(floor(j/k)+1)*(floor(j/k)-floor((j-1)/k))*(mul(j-i+1, i=1..k)), j=1..n): seq(a(n, 7), n=1..35); # Muniru A Asiru, Sep 30 2018
CROSSREFS
For similar sequences, see: A001057 (k=1), A319885 (k=2), A319886 (k=3), A319887 (k=4), A319888 (k=5), A319889 (k=6), this sequence (k=7), A319891 (k=8), A319892 (k=9), A319893 (k=10).
Sequence in context: A255614 A022731 A092072 * A319871 A374506 A261482
KEYWORD
sign,easy
AUTHOR
Wesley Ivan Hurt, Sep 30 2018
STATUS
approved