A358978 Numbers that are coprime to the number of terms in their Zeckendorf representation (A007895).
1, 2, 3, 5, 7, 8, 9, 11, 13, 15, 17, 19, 20, 21, 23, 25, 28, 29, 31, 32, 33, 34, 35, 37, 38, 39, 40, 41, 43, 44, 47, 49, 50, 51, 52, 53, 55, 57, 59, 61, 62, 63, 64, 65, 67, 70, 71, 73, 75, 77, 79, 83, 85, 87, 88, 89, 91, 95, 97, 98, 100, 101, 103, 104, 107, 109
Offset: 1
Examples
3 is a term since A007895(3) = 1, and gcd(3, 1) = 1.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..10000
Crossrefs
Programs
-
Mathematica
z[n_] := Length[DeleteCases[NestWhileList[# - Fibonacci[Floor[Log[Sqrt[5]*# + 3/2]/Log[GoldenRatio]]] &, n, # > 1 &], 0]]; Select[Range[120], CoprimeQ[#, z[#]] &] (* after Alonso del Arte at A007895 *)
-
PARI
is(n) = if(n<4, 1, my(k=2, m=n, s, t); while(fibonacci(k++)<=m, ); while(k && m, t=fibonacci(k); if(t<=m, m-=t; s++); k--); gcd(n, s)==1); \\ after Charles R Greathouse IV at A007895
Comments