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.

A372754 a(n) is the least base in which the Fibonacci number A000045(n) is a palindrome.

This page as a plain text file.
%I A372754 #26 May 18 2024 14:45:46
%S A372754 2,2,3,2,2,3,3,2,4,4,8,11,3,11,9,11,15,29,25,29,29,29,40,17,121,76,76,
%T A372754 69,147,39,148,199,199,199,311,361,10876,428,521,521,1026,1364,1025,
%U A372754 1364,1364,1364,2100,2018,4973,3571,3571,3571,5802,6461,11343,9349,9349,9349,31952,24476,15885,24476
%N A372754 a(n) is the least base in which the Fibonacci number A000045(n) is a palindrome.
%C A372754 With F = A000045 the Fibonacci numbers and L = A000032 the Lucas numbers, for j odd we have F(3*j+k) = F(j+k)*L(j)^2 + F(k)*L(j) + F(j+k), thus this is a palindrome mod L(j) if F(k) >= 0 and 0 <= F(j+k) < L(j).  Therefore a(6*n), a(6*n+2), a(6*n+3) and a(6*n+4) all <= L(2*n+1).
%H A372754 Chai Wah Wu, <a href="/A372754/b372754.txt">Table of n, a(n) for n = 1..138</a> (terms 1..102 from Robert Israel)
%F A372754 a(n) = A016026(A000045(n)).
%e A372754 A000045(6) = 8.  In base 2 this is 1000, not a palindrome, but in base 3 it is 22, a palindrome.  Thus a(6) = 3.
%p A372754 f:= proc(x) local b,L;
%p A372754   for b from 2 do
%p A372754     L:= convert(x,base,b);
%p A372754     if L = ListTools:-Reverse(L) then return b fi
%p A372754   od
%p A372754 end proc:
%p A372754 map(f, [seq(combinat:-fibonacci(n), n=1..70)]);
%t A372754 A372754[n_] := Block[{b = 1}, While[!PalindromeQ[IntegerDigits[#, ++b]]] & [Fibonacci[n]]; b]; Array[A372754, 70] (* _Paolo Xausa_, May 18 2024 *)
%o A372754 (Python)
%o A372754 from itertools import count
%o A372754 from sympy import fibonacci
%o A372754 from sympy.ntheory.factor_ import digits
%o A372754 def A372754(n): return next(b for b in count(2) if (s := digits(fibonacci(n),b)[1:])[:(t:=len(s)+1>>1)]==s[:-t-1:-1]) # _Chai Wah Wu_, May 13 2024
%Y A372754 Cf. A000045, A016026, A045504.
%K A372754 nonn,base
%O A372754 1,1
%A A372754 _Robert Israel_, May 12 2024