A072702 Last digit of F(n) is 4 where F(n) is the n-th Fibonacci number.
9, 12, 18, 51, 69, 72, 78, 111, 129, 132, 138, 171, 189, 192, 198, 231, 249, 252, 258, 291, 309, 312, 318, 351, 369, 372, 378, 411, 429, 432, 438, 471, 489, 492, 498, 531, 549, 552, 558, 591, 609, 612, 618, 651, 669, 672, 678, 711, 729, 732, 738, 771, 789
Offset: 1
Links
- Colin Barker, Table of n, a(n) for n = 1..1000
- Index entries for linear recurrences with constant coefficients, signature (1,0,0,1,-1).
Programs
-
Mathematica
With[{fibs=Fibonacci[Range[800]]},Flatten[Position[fibs,?(Last[ IntegerDigits[ #]]==4&)]]] (* _Harvey P. Dale, Sep 24 2012 *) Position[Mod[Fibonacci[Range[800]],10],4]//Flatten (* Harvey P. Dale, Apr 09 2023 *)
-
PARI
a(n) = (-60 + 6*(-1)^n + (9+21*I)*(-I)^n + (9-I*21)*I^n + 60*n) / 4 \\ Colin Barker, Oct 16 2015
-
PARI
Vec(x*(9*x^4+33*x^3+6*x^2+3*x+9)/(x^5-x^4-x+1) + O(x^100)) \\ Colin Barker, Oct 16 2015
-
PARI
for(n=0, 1e3, if(fibonacci(n) % 10 == 4, print1(n", "))) \\ Altug Alkan, Oct 16 2015
Formula
G.f.: x*(9*x^4+33*x^3+6*x^2+3*x+9) / (x^5-x^4-x+1). - Colin Barker, Jun 16 2013
a(n) = (-60 + 6*(-1)^n + (9+21*i)*(-i)^n + (9-i*21)*i^n + 60*n) / 4 where i=sqrt(-1). - Colin Barker, Oct 16 2015
Comments