login
A121891
Least m such that (F(n) mod m) > (F(n+2) mod m).
0
3, 4, 2, 3, 3, 2, 5, 4, 2, 5, 5, 2, 3, 4, 2, 5, 3, 2, 7, 3, 2, 5, 10, 2, 3, 4, 2, 3, 3, 2, 5, 4, 2, 11, 7, 2, 3, 4, 2, 7, 3, 2, 13, 3, 2, 11, 5, 2, 3, 4, 2, 3, 3, 2, 6, 4, 2, 7, 19, 2, 3, 4, 2, 10, 3, 2, 5, 3, 2, 5, 5, 2, 3, 4, 2, 3, 3, 2, 6, 4, 2, 5, 7, 2, 3, 4, 2, 7, 3, 2, 5, 3, 2, 11, 13, 2, 3, 4, 2, 3, 3
OFFSET
1,1
COMMENTS
F(n) = Fibonacci numbers A000045.
EXAMPLE
n=20: a(20) = 7 because F(20)=6765 == 3 mod 7, F(22)=17711 == 1 mod 7 and 7 is the least m such that 6765 > 17711 mod m.
MATHEMATICA
s={}; Do[n1=Fibonacci [n]; n2=Fibonacci [n+2]; Do[If[Mod[n1, m]>Mod[n2, m], AppendTo[s, {n, n1, n2, m}]; Break[]], {m, 1, 200}], {n, 2, 120}]; Last/@s
CROSSREFS
Cf. A000045.
Sequence in context: A088916 A117966 A303932 * A346780 A271590 A232115
KEYWORD
nonn
AUTHOR
Zak Seidov, Aug 31 2006
STATUS
approved