[go: up one dir, main page]

login
A047289 revision #37

A047289
Numbers that are congruent to {0, 4, 6} mod 7.
1
0, 4, 6, 7, 11, 13, 14, 18, 20, 21, 25, 27, 28, 32, 34, 35, 39, 41, 42, 46, 48, 49, 53, 55, 56, 60, 62, 63, 67, 69, 70, 74, 76, 77, 81, 83, 84, 88, 90, 91, 95, 97, 98, 102, 104, 105, 109, 111, 112, 116, 118, 119, 123, 125, 126, 130, 132, 133, 137, 139, 140
OFFSET
1,2
FORMULA
From Colin Barker, Mar 13 2012: (Start)
G.f.: x*(4+2*x+x^2)/((1-x)^2*(1+x+x^2)).
a(n) = a(n-1) + a(n-3) - a(n-4) for n>4. (End)
a(n) = Sum_{i=1..n} 2^(-i mod 3). - Wesley Ivan Hurt, Jul 08 2014
From Wesley Ivan Hurt, Jun 10 2016: (Start)
a(n) = (21*n-12+3*cos(2*n*Pi/3)-5*sqrt(3)*sin(2*n*Pi/3))/9.
a(3k) = 7k-1, a(3k-1) = 7k-3, a(3k-2) = 7k-7. (End)
MAPLE
A047289:=n->(21*n-12+3*cos(2*n*Pi/3)-5*sqrt(3)*sin(2*n*Pi/3))/9: seq(A047289(n), n=1..100); # Wesley Ivan Hurt, Jun 10 2016
MATHEMATICA
Cases[Range[0, 123], n_ /; MatchQ[Mod[n, 7], 0 | 4 | 6]] (* Jean-François Alcover, Mar 16 2011 *)
Select[Range[0, 125], MemberQ[{0, 4, 6}, Mod[#, 7]]&] (* Vincenzo Librandi, Apr 26 2012 *)
PROG
(Magma) I:=[0, 4, 6, 7]; [n le 4 select I[n] else Self(n-1)+Self(n-3)-Self(n-4): n in [1..70]]; // Vincenzo Librandi, Apr 26 2012
CROSSREFS
Cf. A153727.
Sequence in context: A206775 A287157 A102140 * A345717 A022436 A102139
KEYWORD
nonn,easy
EXTENSIONS
More terms from Wesley Ivan Hurt, Jul 08 2014
STATUS
approved