login
A361509
a(n) = smallest Fibonacci number F(k) such that F(k) + F(n) is a prime, or -1 if no such F(k) exists.
3
2, 1, 1, 0, 0, 0, 3, 0, 2, 3, 34, 0, 5, 0, 2, 3, 34, 0, 987, 46368, 2584, 3, 2, 0, 13, 144
OFFSET
0,1
COMMENTS
a(26) is currently unknown.
a(26) > 10^7000 if it is not -1. - Robert Israel, Apr 03 2023
FORMULA
a(n) = A000045(A361902(A000045(n))) (unless A361902(A000045(n)) = -1). - Pontus von Brömssen, Mar 30 2023
MAPLE
with(combinat):
a:=[]; b:=[]; for n from 0 to 25 do
k:=0; t1:=fibonacci(n);
while not isprime( fibonacci(k)+t1) do k:=k+1; od:
a:=[op(a), fibonacci(k)]; b:=[op(b), k];
od:
a; # A361509
b; # A361510
MATHEMATICA
a[n_] := Module[{fn = Fibonacci[n], k = 0}, While[! PrimeQ[fn + Fibonacci[k]], k++]; Fibonacci[k]]; Array[a, 26, 0] (* Amiram Eldar, Mar 30 2023 *)
PROG
(PARI) a(n) = my(k=0, fn=fibonacci(n)); while (!isprime(fn+fibonacci(k)), k++); fibonacci(k); \\ Michel Marcus, Mar 30 2023
CROSSREFS
KEYWORD
nonn,more,less
AUTHOR
Jack Braxton, Mar 26 2023
EXTENSIONS
Edited by N. J. A. Sloane, Mar 30 2023
STATUS
approved