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 A068452 #34 Feb 16 2025 08:32:45 %S A068452 9,1,2,0,4,2,0,6,4,0,4,11,6,4,14,8,12,6,18,12,12,14,13,2,7,20,12,2,16, %T A068452 21,25,26,29,19,7,3,20,3,38,7,12,19,37,1,23,32,19,32,38,45,45,27,44, %U A068452 34,14,49,35,29,30,57,57,18,56,48,33,19,44,35,12,56,28,38,64,35,10,45,35,0 %N A068452 Pi^2 = Sum_{n>=1} a(n)/n!. %C A068452 For the fractional part, this corresponds to the factoradic (or factorial base, or harmonic) expansion, but the integer part 9 = 3! + 2! + 1! would be [1, 1, 1] in factorial base, cf. A007623(9) = 111. - _M. F. Hasler_, Nov 27 2018 %H A068452 G. C. Greubel, <a href="/A068452/b068452.txt">Table of n, a(n) for n = 1..10000</a> (terms 1..1000 from Vincenzo Librandi) %H A068452 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/HarmonicExpansion.html">Harmonic Expansion</a>. %H A068452 Wikipedia, <a href="https://en.wikipedia.org/wiki/Factorial_number_system#Fractional_values">Factorial number system: Fractional values</a> %H A068452 <a href="/index/Fa#facbase">Index to sequences related to factorial base representation of noninteger constants</a>. %p A068452 fexp := proc(x) local xres,a,n ; xres := x ; a := [] ; for n from 1 to 100 do a := [op(a),floor(n!*xres)] ; xres := xres-op(-1,a)/n! ; od: a ; end: Digits := 400 ; fexp(evalf(Pi^2)) ; Digits := 600 ; fexp(evalf(Pi^2)) ; # _R. J. Mathar_, Sep 30 2008 %t A068452 p=N[Pi, 10000]^2; Do[k=Floor[p n!]; p=p - k / n!; Print[k], {n, 1000}] (* _Vincenzo Librandi_, Nov 24 2018 *) %t A068452 With[{b = Pi^2}, Table[If[n == 1, Floor[b], Floor[n!*b] -n*Floor[(n- 1)!*b]], {n, 1, 100}]] (* _G. C. Greubel_, Nov 26 2018 *) %o A068452 (PARI) default(realprecision, 250); b = Pi^2; for(n=1, 80, print1(if(n==1, floor(b), floor(n!*b) - n*floor((n-1)!*b)), ", ")) \\ _G. C. Greubel_, Nov 26 2018 %o A068452 (PARI) A068452(N=90, c=precision(Pi^2,logint(N!,10)))=vector(N, n, if(n>1, c=c%1*n, c)\1) \\ _M. F. Hasler_, Nov 27 2018 %o A068452 (Magma) SetDefaultRealField(RealField(250)); R:=RealField(); [Floor(Pi(R)^2)] cat [Floor(Factorial(n)*Pi(R)^2) - n*Floor(Factorial((n-1))*Pi(R)^2) : n in [2..80]]; // _G. C. Greubel_, Nov 26 2018 %o A068452 (Sage) %o A068452 def A068452(n): %o A068452 if (n==1): return floor(pi^2) %o A068452 else: return expand(floor(factorial(n)*pi^2) - n*floor(factorial(n-1)*pi^2)) %o A068452 [A068452(n) for n in (1..80)] # _G. C. Greubel_, Nov 26 2018 %Y A068452 Cf. A002388 (decimal expansion of Pi^2). %Y A068452 Similar expansions: A068450 (sqrt(Pi)), A075874 (Pi), A007514 (different variant for Pi). %K A068452 nonn %O A068452 1,1 %A A068452 _Benoit Cloitre_, Mar 10 2002 %E A068452 Corrected beginning at 3rd term by _R. J. Mathar_, Sep 30 2008