login
a(0)=0, a(1)=2, a(n) = smallest prime > a(n-1)+a(n-2).
8

%I #11 Sep 24 2023 05:45:12

%S 0,2,3,7,11,19,31,53,89,149,239,389,631,1021,1657,2683,4349,7039,

%T 11393,18433,29833,48271,78121,126397,204521,330943,535481,866431,

%U 1401937,2268377,3670319,5938711,9609031,15547769,25156811,40704589,65861461,106566059,172427531

%N a(0)=0, a(1)=2, a(n) = smallest prime > a(n-1)+a(n-2).

%H Amiram Eldar, <a href="/A055502/b055502.txt">Table of n, a(n) for n = 0..1000</a>

%p A055502 := proc(n) option remember; if n<=0 then n else nextprime(A055502(n-1)+A055502(n-2)); fi; end;

%t a[0] = 0; a[1] = 2; a[n_] := a[n] = NextPrime[a[n-1] + a[n-2]]; Array[a, 40, 0] (* _Amiram Eldar_, Sep 24 2023 *)

%Y Cf. A055498, A055499, A055500, A055501.

%K nonn

%O 0,2

%A _N. J. A. Sloane_, Jul 09 2000

%E More terms from _Amiram Eldar_, Sep 24 2023