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.
%I A375089 #44 Aug 29 2024 12:00:58 %S A375089 0,0,1,1,1,1,1,2,3,2,1,10,1,2,8,4,1,9,1,11,8,2,3,55,6,2,6,11,3,49,1,8, %T A375089 8,2,13,133,1,6,20,46,1,49,3,27,81,4,1,260,2,38,20,11,1,106,21,78,20, %U A375089 4,7,874,1,6,81,48,29,49,3,27,42,108,1,1319,3,14,174,23,13,101,1,444 %N A375089 Number of positive integers with Pisano period equal to 2n. %C A375089 a(n) = 0 for all odd values n > 3 since the Pisano period of m is always even except when m=1 or 2. %C A375089 The Pisano period of m divides n if and only if F_m = 0 (mod n) and F_{m+1} = 1 (mod n), hence n | gcd(F_m,F_{m+1}-1). %C A375089 Conjecture: If n is of the form 12*5^j (i.e. 2n is of the form 24*5^j which has the unique property that pi(2n)=2n), then a(n) > a(m) for all m < n. %C A375089 Conjecture: Every natural number appears on this list. %H A375089 Chai Wah Wu, <a href="/A375089/b375089.txt">Table of n, a(n) for n = 1..314</a> (terms 1..239 from Oliver Lippard) %H A375089 B. Benfield and O. Lippard, <a href="https://arxiv.org/abs/2404.08194">Fixed points of K-Fibonacci Pisano periods</a>, arXiv:2404.08194 [math.NT], 2024. %H A375089 J. D. Fulton and W. L. Morris, <a href="https://eudml.org/doc/204918">On arithmetical functions related to the Fibonacci numbers</a>, Acta Arithmetica 16 (1969), 105-110. %e A375089 a(9) = 3 because the Pisano periods of 76, 38, and 19, but no others, are 2*9=18. %e A375089 There are no numbers with Pisano period 2 or 4, so a(1) = a(2) = 0. %o A375089 (Sage) %o A375089 def a(n): %o A375089 num=0 %o A375089 if n<3: %o A375089 return 0 %o A375089 x=gcd(fibonacci(2*n),fibonacci(2*n+1)-1) %o A375089 for d in divisors(x): %o A375089 if BinaryRecurrenceSequence(1,1,0,1).period(d)==2*n: %o A375089 num+=1 %o A375089 return num %o A375089 for i in range(1,101): %o A375089 print(a(i)) %o A375089 (Python) %o A375089 from functools import lru_cache %o A375089 from math import gcd, lcm %o A375089 from sympy import factorint, divisors, fibonacci %o A375089 def A375089(n): %o A375089 @lru_cache(maxsize=None) %o A375089 def A001175(n): %o A375089 if n == 1: %o A375089 return 1 %o A375089 f = factorint(n).items() %o A375089 if len(f) > 1: %o A375089 return lcm(*(A001175(a**b) for a,b in f)) %o A375089 else: %o A375089 k,x = 1, (1,1) %o A375089 while x != (0,1): %o A375089 k += 1 %o A375089 x = (x[1], (x[0]+x[1]) % n) %o A375089 return k %o A375089 a, b = fibonacci((m:=n<<1)+1), fibonacci(m) %o A375089 return sum(1 for d in divisors(gcd(a-1,b),generator=True) if A001175(d)==m) # _Chai Wah Wu_, Aug 28 2024 %Y A375089 Cf. A000045, A001175. %Y A375089 See A375519 for the "equal to n" version. %K A375089 nonn %O A375089 1,8 %A A375089 _Oliver Lippard_ and _Brennan G. Benfield_, Jul 29 2024