[go: up one dir, main page]

login
A047343
Numbers that are congruent to {1, 3, 4} mod 7.
1
1, 3, 4, 8, 10, 11, 15, 17, 18, 22, 24, 25, 29, 31, 32, 36, 38, 39, 43, 45, 46, 50, 52, 53, 57, 59, 60, 64, 66, 67, 71, 73, 74, 78, 80, 81, 85, 87, 88, 92, 94, 95, 99, 101, 102, 106, 108, 109, 113, 115, 116, 120, 122, 123, 127, 129, 130, 134, 136, 137, 141
OFFSET
1,2
COMMENTS
Also, numbers n such that kronecker(n+2, 7) = -1. - M. F. Hasler, Mar 15 2013
FORMULA
G.f.: x*(1+2*x+x^2+3*x^3)/((1+x+x^2)*(x-1)^2). - R. J. Mathar, Dec 04 2011
From Wesley Ivan Hurt, Jun 10 2016: (Start)
a(n) = a(n-1) + a(n-3) - a(n-4) for n>4.
a(n) = (21*n-18-9*cos(2*n*Pi/3)+sqrt(3)*sin(2*n*Pi/3))/9.
a(3k) = 7k-3, a(3k-1) = 7k-4, a(3k-2) = 7k-6. (End)
MAPLE
A047343:=n->(21*n-18-9*cos(2*n*Pi/3)+sqrt(3)*sin(2*n*Pi/3))/9: seq(A047343(n), n=1..100); # Wesley Ivan Hurt, Jun 10 2016
MATHEMATICA
Flatten[Table[{7n + 1, 7n + 3, 7n + 4}, {n, 0, 19}]] (* Alonso del Arte, Mar 15 2013 *)
LinearRecurrence[{1, 0, 1, -1}, {1, 3, 4, 8}, 90] (* Harvey P. Dale, Aug 07 2021 *)
PROG
(PARI) A047343(n)=n\3*7+[-3, 1, 3][n%3+1] \\ M. F. Hasler, Mar 15 2013
(PARI) for(k=1, 200, kronecker(k+2, 7)==-1 & print1(k", ")) \\ For illustrative purpose of the comment. - M. F. Hasler, Mar 15 2013
(Magma) [n : n in [0..150] | n mod 7 in [1, 3, 4]]; // Wesley Ivan Hurt, Jun 10 2016
CROSSREFS
Sequence in context: A239976 A191193 A327185 * A155730 A005047 A083317
KEYWORD
nonn,easy
STATUS
approved