OFFSET
0,2
COMMENTS
Numbers k such that k is +-1 mod 4, 9, and 25. - Charles R Greathouse IV, Dec 23 2011
Numbers congruent to {1, 199, 251, 449} mod 450. - Philippe Deléham, Dec 02 2016
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000 (corrected by Ray Chandler, Jan 19 2019)
Index entries for linear recurrences with constant coefficients, signature (1,0,0,1,-1).
FORMULA
a(n) = a(n-4) + 450.
a(n) = a(n-1) + a(n-4) - a(n-5). - R. J. Mathar, Aug 18 2009
From Jon E. Schoenfield, Jun 19 2010: (Start)
a(n) = (2*n + 1)*225/4 + f(n mod 4)/4, where f(0)=-221, f(1)=121, f(2)=-121, f(3)=221, so a nonrecursive formula for a(n) is
a(n) = (450*n + 225 - (100*floor(((n-1) mod 4)/2) + 121)*(-1)^n)/4. (End)
G.f.: x*(199 + 52*x + 198*x^2 + 2*x^3 - x^4)/((1 - x)^2*(1 + x)*(1 + x^2)). - Colin Barker, Apr 10 2012
Sum_{n>=0} (-1)^n/a(n) = (cot(Pi/450) - tan(13*Pi/225))*Pi/450. - Amiram Eldar, Feb 28 2023
MATHEMATICA
LinearRecurrence[{1, 0, 0, 1, -1}, {199, 251, 449, 451, 649}, 50] (* Harvey P. Dale, Apr 29 2011 *)
Select[Range[5000], PowerMod[#, 2, 900]==1&] (* Harvey P. Dale, May 05 2018 *)
PROG
(PARI) a(n)=n\8*900+[1, 199, 251, 449, 451, 649, 701, 899][n%8+1] \\ Charles R Greathouse IV, Dec 23 2011
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Vincenzo Librandi, Feb 17 2009
EXTENSIONS
Edited and a(11) corrected by R. J. Mathar, Aug 18 2009
STATUS
approved