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.

A210434 Number of digits in 4^n.

This page as a plain text file.
%I A210434 #43 Apr 08 2025 04:38:15
%S A210434 1,1,2,2,3,4,4,5,5,6,7,7,8,8,9,10,10,11,11,12,13,13,14,14,15,16,16,17,
%T A210434 17,18,19,19,20,20,21,22,22,23,23,24,25,25,26,26,27,28,28,29,29,30,31,
%U A210434 31,32,32,33,34,34,35,35,36,37,37,38,38,39,40,40,41,41
%N A210434 Number of digits in 4^n.
%C A210434 Since log10(4) = A114493 ~ 0.60205 (= twice log10(2) = 0.30102999566...), the first 98 terms are equal to floor(n*3/5)+1. - _M. F. Hasler_, Mar 31 2025
%H A210434 Alois P. Heinz, <a href="/A210434/b210434.txt">Table of n, a(n) for n = 0..1000</a>
%F A210434 a(n) = A055642(A000302(n)) = A055642(4^n) = floor(log_10(10*(4^n))). - _Jonathan Vos Post_, Mar 22 2012
%e A210434 a(4) = 3 because 4^4 = 256, which has 3 digits.
%e A210434 a(5) = 4 because 4^5 = 1024, which has 4 digits.
%p A210434 a:= n-> length(4^n): seq(a(n), n=0..100); # _Alois P. Heinz_, Mar 22 2012
%t A210434 Table[Length[IntegerDigits[4^n]], {n, 0, 68}] (* _Bruno Berselli_, Mar 22 2012 *)
%o A210434 (Magma) [#Intseq(4^n): n in [0..68]]; // _Bruno Berselli_, Mar 22 2012
%o A210434 (PARI) apply( {A210434(n)=logint(4^n,10)+1}, [0..66]) \\ _M. F. Hasler_, Mar 31 2025
%o A210434 (PARI) a(n)=log(4)*n\log(10)+1 \\ correct up to n ~ 10^precision, with default precision = 38. - _M. F. Hasler_, Mar 31 2025
%o A210434 (Python)
%o A210434 from math import log
%o A210434 def A210434(n): return int(n*log(4,10))+1 if n<1e16 else "not enough precision" # _M. F. Hasler_, Mar 31 2025
%Y A210434 Cf. A000302, A034887, A034888, A210062, A210435, A210436.
%K A210434 nonn,base,easy
%O A210434 0,3
%A A210434 _Luc Comeau-Montasse_, Mar 21 2012