login
a(n) is the smallest prime == 1 (mod F(n)) where F(n) is the n-th Fibonacci number.
1

%I #14 Nov 18 2020 06:50:44

%S 2,2,3,7,11,17,53,43,103,331,179,433,467,5279,1831,5923,6389,7753,

%T 8363,27061,21893,35423,1146281,92737,3001001,1213931,392837,1906867,

%U 4113833,4992241,5385077,17426473,14098313,91246193,110729581,44791057,144946903,938116057

%N a(n) is the smallest prime == 1 (mod F(n)) where F(n) is the n-th Fibonacci number.

%H Alois P. Heinz, <a href="/A087384/b087384.txt">Table of n, a(n) for n = 1..2000</a>

%e Prime corresponding to the Fibonacci number F(7) = 13 is 4*13+1 = 53.

%p F:= n-> (<<0|1>, <1|1>>^n)[1, 2]:

%p a:= proc(n) option remember; local f, p; f:= F(n);

%p for p from f+1 by f while not isprime(p) do od; p

%p end:

%p seq(a(n), n=1..50);

%t F[n_] := MatrixPower[{{0, 1}, {1, 1}}, n][[1, 2]];

%t a[n_] := a[n] = Module[{f = F[n], p}, For[p = f+1, !PrimeQ[p], p += f]; p];

%t Array[a, 50] (* _Jean-François Alcover_, Nov 18 2020, after _Alois P. Heinz_ *)

%Y Cf. A000040, A000045.

%K nonn

%O 1,1

%A _Amarnath Murthy_, Sep 09 2003

%E Offset corrected by _Alois P. Heinz_, Jul 09 2017