cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A316141 Number of ordered pairs (k, m) with k > 1 and m > 0 such that n - F(k)*L(m) is an odd prime, where F(k) is the k-th Fibonacci number (A000045) and L(m) is the m-th Lucas number (A000204).

Original entry on oeis.org

0, 0, 0, 1, 1, 3, 2, 4, 3, 4, 4, 4, 4, 6, 5, 6, 4, 6, 6, 7, 6, 6, 5, 7, 9, 8, 7, 6, 5, 4, 8, 9, 5, 8, 7, 5, 9, 8, 8, 9, 7, 7, 8, 10, 8, 9, 6, 6, 9, 10, 8, 11, 6, 6, 10, 7, 6, 11, 8, 7, 11, 11, 9, 9, 11, 9, 9, 10, 8, 9, 8, 8, 9, 12, 11, 11, 8, 7, 10, 9, 10, 11, 8, 7, 9, 10, 10, 8, 8, 6
Offset: 1

Views

Author

Zhi-Wei Sun, Jun 25 2018

Keywords

Comments

Conjecture: a(n) > 0 for all n > 3. In other words, any integer n > 3 can be written as p + F(k)*L(m), where p is an odd prime, and k and m are positive integers.
This has been verified for all n = 4..5*10^9.
Note that 1623412692 is the first value of n > 3 which cannot be written as p + F(k)*L(m) with p an odd prime and k and m positive integers of the same parity.

Examples

			a(4) = 1 with 4 - F(2)*L(1) = 4 - 1*1 = 3 an odd prime.
a(5) = 1 with 5 - F(3)*L(1) = 5 - 2*1 = 3 an odd prime.
a(7) = 2 with 7 - F(3)*L(1) = 7 - 2*1 = 5 and 7 - F(2)*L(3) = 7 - 1*4 = 3 odd primes.
		

Crossrefs

Programs

  • Mathematica
    F[n_]:=F[n]=Fibonacci[n];
    L[n_]:=L[n]=LucasL[n];
    PQ[n_]:=PQ[n]=n>2&&PrimeQ[n];
    tab={};Do[r=0;k=2;Label[aa];If[F[k]>=n,Goto[cc]];m=1;Label[bb];If[L[m]>=n/F[k],k=k+1;Goto[aa]];If[PQ[n-F[k]L[m]],r=r+1];m=m+1;Goto[bb];Label[cc];tab=Append[tab,r],{n,1,90}];Print[tab]