|
|
A079003
|
|
Least k >= 3 such that Fibonacci(k) == -1 (mod 3^n).
|
|
1
|
|
|
3, 6, 14, 38, 110, 326, 974, 2918, 8750, 26246, 78734, 236198, 708590, 2125766, 6377294, 19131878, 57395630, 172186886, 516560654, 1549681958, 4649045870, 13947137606, 41841412814, 125524238438, 376572715310, 1129718145926
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
REFERENCES
|
R. L. Graham, D. E. Knuth and O. Patashnick, "Concrete Mathematics", second edition, Addison Wesley, ex. 6.59.
|
|
LINKS
|
|
|
FORMULA
|
a(1) = 3; for n > 1, a(n) = 3*a(n-1)-4; a(n) = 4*3^(n-2)+2.
a(n) = 4*a(n-1) - 3*a(n-2) for n > 3.
G.f.: x*(3 - 6*x - x^2)/((1-x)*(1-3*x)). (End)
E.g.f.: (1/9)*(4*exp(3*x) + 18*exp(x) - 3*x - 22). - Stefano Spezia, Nov 10 2019
|
|
MATHEMATICA
|
CoefficientList[Series[(3-6*x-x^2)/((1-x)*(1-3*x)), {x, 0, 40}], x] (* Vincenzo Librandi, Jun 23 2012 *)
|
|
PROG
|
(PARI) a(n)=if(n<0, 0, x=3; while((fibonacci(x)+1)%(3^n)>0, x++); x)
(Magma) I:=[3, 6, 14, 38]; [n le 4 select I[n] else 4*Self(n-1) -3*Self(n-2): n in [1..30]]; // Vincenzo Librandi, Jun 23 2012
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|