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.

A322505 Factorial expansion of 1/sqrt(2) = Sum_{n>=1} a(n)/n!.

Original entry on oeis.org

0, 1, 1, 0, 4, 5, 0, 6, 4, 9, 0, 11, 7, 3, 11, 10, 2, 2, 5, 16, 11, 3, 7, 18, 16, 19, 11, 12, 21, 19, 22, 5, 31, 21, 25, 30, 20, 6, 5, 21, 17, 41, 36, 14, 28, 13, 45, 16, 0, 33, 1, 2, 41, 1, 28, 43, 9, 15, 16, 28, 22, 19, 22, 13, 34, 61, 38, 40, 56, 44, 69, 25, 42, 44, 34, 73, 71, 42, 17
Offset: 1

Views

Author

G. C. Greubel, Dec 12 2018

Keywords

Examples

			1/sqrt(2) = 0 + 1/2! + 1/3! + 0/4! + 4/5! + 5/6! + 0/7! + 6/8! + ...
		

Crossrefs

Cf. A010503 (decimal expansion), A130130 (continued fraction).
Cf. A009949 (sqrt(2)).

Programs

  • Magma
    SetDefaultRealField(RealField(250));  [Floor(1/Sqrt(2))] cat [Floor(Factorial(n)/Sqrt(2)) - n*Floor(Factorial((n-1))/Sqrt(2)) : n in [2..80]];
    
  • Mathematica
    With[{b = 1/Sqrt[2]}, Table[If[n == 1, Floor[b], Floor[n!*b] - n*Floor[(n - 1)!*b]], {n, 1, 100}]] (* G. C. Greubel, Dec 12 2018 *)
  • PARI
    default(realprecision, 250); b = 1/sqrt(2); for(n=1, 80, print1(if(n==1, floor(b), floor(n!*b) - n*floor((n-1)!*b)), ", "))
    
  • Sage
    b=1/sqrt(2);
    def a(n):
        if (n==1): return floor(b)
        else: return expand(floor(factorial(n)*b) -n*floor(factorial(n-1)*b))
    [a(n) for n in (1..80)]