A191760 Digital root of the n-th odd square.
1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1, 1, 9, 7, 4, 9, 4, 7, 9, 1
Offset: 1
Examples
The fifth, odd square number is 81 which has digital root 9. Hence a(5)=9.
Links
- Index entries for linear recurrences with constant coefficients, signature (0,0,0,0,0,0,0,0,1).
Programs
-
Mathematica
DigitalRoot[n_Integer?Positive]:=FixedPoint[Plus@@IntegerDigits[#]&,n];DigitalRoot[#] &/@((2#-1)^2 &/@Range[81]) LinearRecurrence[{0, 0, 0, 0, 0, 0, 0, 0, 1},{1, 9, 7, 4, 9, 4, 7, 9, 1},81] (* Ray Chandler, Aug 25 2015 *) PadRight[{},120,{1,9,7,4,9,4,7,9,1}] (* Harvey P. Dale, Jun 26 2021 *)
Formula
a(n) = 3*(1+cos(2(n-2)pi/3)+cos(4(n-2)pi/3)) +mod( (1+n)(1+7n-7n^2+7n^3+n^4-n^5+3n^6+3n^7), 9).
a(n) = a(n-9).
a(n) = 51-a(n-1)-a(n-2)-a(n-3)-a(n-4)-a(n-5)-a(n-6)-a(n-7)-a(n-8).
G.f.: x(1+9x+7x^2+4x^3+9x^4+4x^5+7x^6+9x^7+x^8)/( (1-x)*(1+x+x^2)*(1+x^3+x^6) ) (note that the coefficients of x in the numerator are precisely the terms that constitute the periodic cycle of the sequence).
a(n) = A056992(2n-1). - R. J. Mathar, Jun 27 2011
Comments