A203016 Numbers congruent to {1, 2, 3, 4} mod 6, multiplied by 3.
3, 6, 9, 12, 21, 24, 27, 30, 39, 42, 45, 48, 57, 60, 63, 66, 75, 78, 81, 84, 93, 96, 99, 102, 111, 114, 117, 120, 129, 132, 135, 138, 147, 150, 153, 156, 165, 168, 171, 174, 183, 186, 189, 192, 201, 204, 207, 210, 219, 222, 225, 228, 237, 240, 243, 246, 255, 258, 261, 264, 273, 276, 279, 282, 291, 294, 297
Offset: 1
Links
- Colin Foster, Peripheral mathematical knowledge, For the Learning of Mathematics, vol. 31, #3 (November, 2011), pp. 24-28.
- Index entries for linear recurrences with constant coefficients, signature (1,0,0,1,-1).
Programs
-
Magma
[3*n : n in [0..100] | n mod 6 in [1..4]]; // Wesley Ivan Hurt, Jun 07 2016
-
Maple
A203016:=n->3*(6*n-5-I^(2*n)+(1+I)*I^(1-n)+(1-I)*I^(n-1))/4: seq(A203016(n), n=1..100); # Wesley Ivan Hurt, Jun 07 2016
-
Mathematica
3 Select[Range[100], MemberQ[{1, 2, 3, 4}, Mod[#, 6]] &] (* Wesley Ivan Hurt, Jun 07 2016 *)
Formula
From Wesley Ivan Hurt, Jun 07 2016: (Start)
G.f.: 3*x*(1+x+x^2+x^3+2*x^4)/((x-1)^2*(1+x+x^2+x^3)).
a(n) = 3*(6*n-5-i^(2*n)+(1+i)*i^(1-n)+(1-i)*i^(n-1))/4 where i=sqrt(-1).
a(n) = a(n-1) + a(n-4) - a(n-5) for n>5.
E.g.f.: 3*(4 + sin(x) - cos(x) + (3*x - 2)*sinh(x) + 3*(x - 1)*cosh(x))/2. - Ilya Gutkovskiy, Jun 07 2016
Comments