login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A117645
a(n) = abs(floor(f(n))), where f(n) = (248/125)*f(n-1) - f(n-2), with f(0) = 120, and f(1) = 125.
1
120, 125, 128, 128, 127, 124, 119, 112, 103, 93, 81, 67, 53, 38, 22, 6, 11, 27, 43, 58, 72, 85, 96, 107, 115, 122, 126, 129, 129, 128, 124, 119, 112, 102, 92, 79, 66, 51, 36, 20, 4, 13, 29, 44, 59, 73, 86, 97, 107, 115, 122, 126, 128, 128, 126, 123
OFFSET
0,1
LINKS
FORMULA
a(n) = abs(floor(f(n))), where f(n) = (248/125)*f(n-1) - f(n-2), with f(0) = 120, and f(1) = 125.
a(n) = abs(floor( (5^(1-3*n)/498)*( (5976 - i*149*sqrt(249))*(124 + i*sqrt(249))^n + (5976 + i*149*sqrt(249))*(124 - i*sqrt(249))^n ) )).
MATHEMATICA
f[n_]:= f[n]= If[n<2, 5*(n+24), (248/125)*f[n-1] -f[n-2]];
Table[Abs[Floor[f[n]]], {n, 0, 55}]
(* Second program *)
M = {{0, 1}, {-1, (248/125)}}; v[0]= {120, 125}; v[n_]:= v[n]= M.v[n-1];
Table[Abs[Floor[v[n][[1]]]], {n, 0, 55}]
PROG
(Magma)
C<i> := ComplexField();
A117645:= func< n | Abs(Floor(Round( (5^(1-3*n)/498)*( (5976 - i*149*Sqrt(249))*(124 + i*Sqrt(249))^n + (5976 + i*149*Sqrt(249))*(124 - i*Sqrt(249))^n )) )) >;
[A117645(n): n in [0..60]]; // G. C. Greubel, Dec 03 2022
(SageMath)
@CachedFunction
def f(n): return 5*(n+24) if (n<2) else (248/125)*f(n-1) - f(n-2)
def A117645(n): return abs(floor(f(n)))
[A117645(n) for n in range(60)] # G. C. Greubel, Dec 03 2022
CROSSREFS
Sequence in context: A239535 A085218 A296884 * A157425 A030501 A271578
KEYWORD
nonn,less
AUTHOR
Roger L. Bagula, Apr 10 2006
EXTENSIONS
Edited by G. C. Greubel, Dec 03 2022
STATUS
approved