login
A047548
Numbers that are congruent to {1, 2, 3, 4, 7} mod 8.
1
1, 2, 3, 4, 7, 9, 10, 11, 12, 15, 17, 18, 19, 20, 23, 25, 26, 27, 28, 31, 33, 34, 35, 36, 39, 41, 42, 43, 44, 47, 49, 50, 51, 52, 55, 57, 58, 59, 60, 63, 65, 66, 67, 68, 71, 73, 74, 75, 76, 79, 81, 82, 83, 84, 87, 89
OFFSET
1,2
FORMULA
From Chai Wah Wu, May 29 2016: (Start)
a(n) = a(n-1) + a(n-5) - a(n-6) for n>6.
G.f.: x*(x^5 + 3*x^4 + x^3 + x^2 + x + 1)/(x^6 - x^5 - x + 1). (End)
MATHEMATICA
LinearRecurrence[{1, 0, 0, 0, 1, -1}, {1, 2, 3, 4, 7, 9}, 50] (* G. C. Greubel, May 29 2016 *)
PROG
(Magma) [n : n in [0..100] | n mod 8 in [1, 2, 3, 4, 7]]; // Wesley Ivan Hurt, May 29 2016
CROSSREFS
Sequence in context: A119345 A086391 A120127 * A095378 A141489 A060253
KEYWORD
nonn,easy
STATUS
approved