Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #21 Dec 21 2018 16:03:34
%S 1,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,1,1,1,
%T 2,1,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,1,1,
%U 1,2,1,1,1,1,1,1,2,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1,1,1,1,1,2,1,1
%N Number of e^m between Pi^n and Pi^(n+1).
%F a(n) = floor((n + 1) log Pi) - floor(n log Pi). - _Alonso del Arte_, Dec 20 2018
%e Pi^5 = 306.01968478528145326274131... and Pi^6 = 961.389193575304437...; in between them we find e^6 = 403.4287934927351226... and no other powers of e with integer exponents. Hence a(5) = 1.
%e Pi^6 = 961.389193575304437... and Pi^7 = 3020.2932277767920675142...; in between them we find e^7 = 1096.63315842845859926372... and e^8 = 2980.957987041728274743592... Hence a(6) = 2.
%p Digits:= 30:
%p log_Pi:= evalf(log(Pi));
%p a:= n-> floor((n+1)*log_Pi) -floor(n*log_Pi):
%p seq(a(n), n=0..80); # _Alois P. Heinz_, Dec 21 2018
%t Table[Floor[(n + 1)Log[Pi]] - Floor[n Log[Pi]], {n, 0, 99}] (* _Alonso del Arte_, Dec 21 2018 *)
%o (Scala) val logPi = Math.log(Math.PI); for (n <- 0 to 99) yield (Math.floor(logPi * (n + 1)) - Math.floor(logPi * n)).toInt // _Alonso del Arte_, Dec 21 2018
%Y Cf. A000796 (Pi), A001113 (e), A053510 (log(Pi)), A059561 (floor(n*log(Pi))).
%K nonn,easy
%O 0,7
%A _Clark Kimberling_