A168329 a(n) = (3/2)*(2*n - (-1)^n - 1).
3, 3, 9, 9, 15, 15, 21, 21, 27, 27, 33, 33, 39, 39, 45, 45, 51, 51, 57, 57, 63, 63, 69, 69, 75, 75, 81, 81, 87, 87, 93, 93, 99, 99, 105, 105, 111, 111, 117, 117, 123, 123, 129, 129, 135, 135, 141, 141, 147, 147, 153, 153, 159, 159, 165, 165, 171, 171, 177, 177, 183, 183
Offset: 1
Links
- Vincenzo Librandi, Table of n, a(n) for n = 1..10000
- Index entries for linear recurrences with constant coefficients, signature (1,1,-1).
Programs
-
Magma
[(3/2)*(2*n-(-1)^n-1): n in [1..70]]; // Vincenzo Librandi, Nov 15 2011
-
Mathematica
LinearRecurrence[{1,1,-1},{3,3,9},80 ] (* Vincenzo Librandi, Nov 15 2011 *) Table[(3/2) (2 n - (-1)^n - 1), {n, 70}] (* Bruno Berselli, Sep 17 2013 *)
Formula
a(n) = 6*n - a(n-1) - 6 for n>1, a(1)=3.
G.f.: 3*x*(1 + x^2)/((1+x)*(1-x)^2). - Bruno Berselli, Nov 06 2011
a(n) = -a(-n+1) = 3*A109613(n-1) = A198392(n-1) - A198392(-n). - Bruno Berselli, Nov 06 2011 - Sep 17 2013
E.g.f.: (3/2)*(-1 + 2*exp(x) + (2*x - 1)*exp(2*x))*exp(-x). - G. C. Greubel, Jul 18 2016
Extensions
New definition by Bruno Berselli, Sep 17 2013