OFFSET
1,2
COMMENTS
Numbers of the form d*7^j for d = 1,2,3,6.
REFERENCES
Trygve Nagell, Introduction to Number Theory. New York: Wiley, 1951, pp. 164-168.
LINKS
Eric M. Schmidt, Table of n, a(n) for n = 1..500
Benedict W. J. Irwin A sequence a(n+1) is product over binary components of n, plus 1
Eric Weisstein, Cyclotomic Polynomial.
Index entries for linear recurrences with constant coefficients, signature (0,0,0,7).
FORMULA
a(n) = 7*a(n-4). G.f.: -x*(2*x+1)*(3*x^2+1) / (7*x^4-1). - Colin Barker, Jul 30 2014
From Benedict W. J. Irwin, Jul 22 2016: (Start)
a(n) appears to satisfy x*Prod_{n>=0} (1 + a(2^n+1)x^(2^n)) = Sum_{n>=1} a(n)x^n.
Then a(n+1)=a(2^x+1)a(2^y+1)a(2^z+1)..., where n=2^x+2^y+2^z+... .
For example,
n=12=2^2+2^3, then a(12+1)=a(2^2+1)*a(2^3+1) i.e. 343=49*7.
n=31=2^0+2^1+2^2+2^3+2^4, then a(31+1)=a(2)*a(3)*a(5)*a(9)*a(17) i.e. 4941258=2*3*7*49*2401.
(End)
EXAMPLE
The 3rd cyclotomic polynomial x^2 + x + 1 considered modulo 7 has a root x = 2, so 3 is in the sequence.
MATHEMATICA
m = 7; Function[d, Table[d[[k]] m^n, {n, 0, 9}, {k, Length@ d}]]@ Divisors[m - 1] // Flatten (* or *)
Rest@ CoefficientList[Series[-x (2 x + 1) (3 x^2 + 1)/(7 x^4 - 1), {x, 0, 40}], x] (* Michael De Vlieger, Jul 25 2016 *)
LinearRecurrence[{0, 0, 0, 7}, {1, 2, 3, 6}, 50] (* Harvey P. Dale, Oct 10 2018 *)
PROG
(Sage) def A245479(n) : return [6, 1, 2, 3][n%4]*7^((n-1)//4)
(PARI) for(n=1, 10^6, if(#polrootsmod(polcyclo(n), 7), print1(n, ", "))) /* by definition; rather inefficient. - Joerg Arndt, Jul 28 2014 */
(PARI) Vec(-x*(2*x+1)*(3*x^2+1)/(7*x^4-1) + O(x^100)) \\ Colin Barker, Jul 30 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Eric M. Schmidt, Jul 23 2014
STATUS
approved