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.

Showing 1-5 of 5 results.

A143382 Numerator of Sum_{k=0..n} 1/k!!.

Original entry on oeis.org

1, 2, 5, 17, 71, 121, 731, 1711, 41099, 370019, 740101, 2713789, 1206137, 423355111, 846710651, 1814380259, 203210595443, 12654139763, 531473870981, 43758015399281, 525096184837561, 441080795274037, 22054039763790029
Offset: 0

Views

Author

Jonathan Vos Post, Aug 11 2008

Keywords

Comments

Denominators are A143383. A143382(n)/A143383(n) is to A007676(n)/A007676(n) as double factorials are to factorials. A143382/A143383 fractions begin:
n numerator/denominator
0 1/0!! = 1/1
1 1/0!! + 1/1!! = 2/1
2 1/0!! + 1/1!! + 1/2!! = 5/2
3 1/0!! + 1/1!! + 1/2!! + 1/3!! = 17/6
4 1/0!! + 1/1!! + 1/2!! + 1/3!! + 1/4!! = 71/24
5 1/0!! + 1/1!! + 1/2!! + 1/3!! + 1/4!! + 1/5!! = 121/40
6 1/0!! + 1/1!! + 1/2!! + 1/3!! + 1/4!! + 1/5!! + 1/6!! = 731/240
The series converges to sqrt(e) + sqrt((e*Pi)/2)*erf(1/sqrt(2)) = 3.0594074053425761445... whose decimal expansion is given by A143280. The analogs of A094007 and A094008 are determined by 2 being the only prime denominator in the convergents to the sum of reciprocals of double factorials and prime numerators beginning: a(1) = 2, a(2) = 5, a(3) = 17, a(4) = 71, a(15) = 1814380259, a(19) = 43758015399281, a(21) = 441080795274037, a(23) = 867081905243923.

Examples

			a(3) = 17 because 1/0!! + 1/1!! + 1/2!! + 1/3!! = 17/6.
a(15) = 1814380259 because 1814380259/593049600 = 1/1 + 1/1 + 1/2 + 1/3 + 1/8 + 1/15 + 1/48 + 1/105 + 1/384 + 1/945 + 1/3840 + 1/10395 + 1/46080 + 1/135135 + 1/645120 + 1/2027025.
		

Crossrefs

Cf. A006882 (n!!), A094007, A143280 (m(2)), A143383 (denominators).

Programs

  • Magma
    [n le 0 select 1 else Numerator( 1 + (&+[ 1/(0 + (&*[k-2*j: j in [0..Floor((k-1)/2)]])) : k in [1..n]]) ): n in [0..25]]; // G. C. Greubel, Mar 28 2019
    
  • Mathematica
    Table[Numerator[Sum[1/k!!, {k, 0, n}]], {n, 0, 30}] (* G. C. Greubel, Mar 28 2019 *)
    Accumulate[1/Range[0,30]!!]//Numerator (* Harvey P. Dale, May 19 2023 *)
  • PARI
    vector(25, n, n--; numerator(sum(k=0,n, 1/prod(j=0,floor((k-1)/2), (k - 2*j)) ))) \\ G. C. Greubel, Mar 28 2019
    
  • Sage
    [numerator(sum( 1/product((k - 2*j) for j in (0..floor((k-1)/2)))   for k in (0..n))) for n in (0..25)] # G. C. Greubel, Mar 28 2019

Formula

Numerators of Sum_{k=0..n} 1/k!! = Sum_{k=0..n} 1/A006882(k).

A143383 Denominator of Sum_{k=0..n} 1/k!!.

Original entry on oeis.org

1, 1, 2, 6, 24, 40, 240, 560, 13440, 120960, 241920, 887040, 394240, 138378240, 276756480, 593049600, 66421555200, 4136140800, 173717913600, 14302774886400, 171633298636800, 144171970854912, 7208598542745600, 283414985441280
Offset: 0

Views

Author

Jonathan Vos Post, Aug 11 2008

Keywords

Comments

Numerators are A143382. A143382(n)/A143383(n) is to A007676(n)/A007676(n) as double factorials are to factorials. A143382/A143383 fractions begin:
n numerator/denominator
0 1/0!! = 1/1
1 1/0!! + 1/1!! = 2/1
2 1/0!! + 1/1!! + 1/2!! = 5/2
3 1/0!! + 1/1!! + 1/2!! + 1/3!! = 17/6
4 1/0!! + 1/1!! + 1/2!! + 1/3!! + 1/4!! = 71/24
5 1/0!! + 1/1!! + 1/2!! + 1/3!! + 1/4!! + 1/5!! = 121/40
6 1/0!! + 1/1!! + 1/2!! + 1/3!! + 1/4!! + 1/5!! + 1/6!! = 731/240
The series converges to sqrt(e) + sqrt((e*Pi)/2)*erf(1/sqrt(2)) = 3.0594074053425761445... whose decimal expansion is given by A143280. The analogs of A094007 and A094008 are determined by 2 being the only prime denominator in the convergents to the sum of reciprocals of double factorials and prime numerators beginning: a(1) = 2, a(2) = 5, a(3) = 17, a(4) = 71, a(15) = 1814380259, a(19) = 43758015399281, a(21) = 441080795274037, a(23) = 867081905243923.

Examples

			a(3) = 6 because 1/0!! + 1/1!! + 1/2!! + 1/3!! = 17/6.
a(15) = 593049600 because 1814380259/593049600 = 1/1 + 1/1 + 1/2 + 1/3 + 1/8 + 1/15 + 1/48 + 1/105 + 1/384 + 1/945 + 1/3840 + 1/10395 + 1/46080 + 1/135135 + 1/645120 + 1/2027025.
		

Crossrefs

Cf. A006882 (n!!), A094007, A143280 (m(2)), A143382 (numerator).

Programs

  • Magma
    [n le 0 select 1 else Denominator( 1 + (&+[ 1/(0 + (&*[k-2*j: j in [0..Floor((k-1)/2)]])) : k in [1..n]]) ): n in [0..25]]; // G. C. Greubel, Mar 28 2019
    
  • Mathematica
    Table[Denominator[Sum[1/k!!, {k,0,n}]], {n,0,25}] (* G. C. Greubel, Mar 28 2019 *)
  • PARI
    vector(25, n, n--; denominator(sum(k=0,n, 1/prod(j=0,floor((k-1)/2), (k - 2*j)) ))) \\ G. C. Greubel, Mar 28 2019
    
  • Sage
    [denominator(sum(1/product((k-2*j) for j in (0..floor((k-1)/2))) for k in (0..n))) for n in (0..25)] # G. C. Greubel, Mar 28 2019

Formula

Denominators of Sum_{k=0..n} 1/k!! = Sum_{k=0..n} 1/A006882(k).

A094007 Numbers k such that the denominator of the k-th convergent of the continued fraction expansion of e is prime.

Original entry on oeis.org

3, 5, 8, 14, 20, 35, 41, 65, 239, 269
Offset: 1

Views

Author

Jonathan Sondow, Apr 20 2004; corrected Apr 21 2004

Keywords

Comments

a(n) is the position of A094008(n) in A007677 (denominators of convergents to e), so A007677(a(n)) = A094008(n). Also, A102049(n) is the position of A007677(a(n)) in A000040 (the prime numbers), so A000040(A102049(n)) = A007677(a(n)).
a(11) > 50000. - Lucas A. Brown, Apr 21 2021

Examples

			The convergents for e are 2, 3, 8/3, 11/4, 19/7, ... and so the 3rd convergent is the first one with prime denominator: a(1) = 3 and the 5th convergent is the 2nd one with prime denominator: a(2) = 5.
		

Crossrefs

Programs

  • Mathematica
    L = {}; cf = ContinuedFraction[E, 5000]; Do[ If[ PrimeQ[ Denominator[ FromContinuedFraction[ Take[ cf, n]] ]], AppendTo[L, n]], {n, Length[cf]}]; L (* Robert G. Wilson v, May 14 2004 *)

Extensions

More terms from Robert G. Wilson v, May 14 2004

A086791 Primes found among the numerators of the continued fraction rational approximations to e.

Original entry on oeis.org

2, 3, 11, 19, 193, 49171, 1084483, 563501581931, 332993721039856822081, 3883282200001578119609988529770479452142437123001916048102414513139044082579
Offset: 1

Views

Author

Cino Hilliard, Aug 04 2003; corrected Jul 24 2004

Keywords

Examples

			The first 8 rational approximations to e are 2/1, 3/1, 8/3, 11/4, 19/7, 87/32, 106/39, 193/71. The numerators 2, 3, 11, 19, 193 are primes.
		

Crossrefs

Programs

  • PARI
    \\ Continued fraction rational approximation of numeric constants f. m=steps.
    cfracnumprime(m,f) = { default(realprecision,3000); cf = vector(m+10); x=f; for(n=0,m, i=floor(x); x=1/(x-i); cf[n+1] = i; ); for(m1=0,m, r=cf[m1+1]; forstep(n=m1,1,-1, r = 1/r; r+=cf[n]; ); numer=numerator(r); denom=denominator(r); if(ispseudoprime(numer),print1(numer,",")); ) }
    
  • PARI
    default(realprecision,10^5);
    cf=contfrac(exp(1));
    n=0;
    { for(k=1, #cf,  \\ generate b-file
        pq = contfracpnqn( vector(k,j, cf[j]) );
        p = pq[1,1];  q = pq[2,1];
        if ( ispseudoprime(p), n+=1; print(n," ",p) );  \\ A086791
    \\    if ( ispseudoprime(q), n+=1; print(n," ",q) );  \\ A094008
    ); }
    /* Joerg Arndt, Apr 21 2013 */

A102049 Indices of primes which are denominators of convergents to e.

Original entry on oeis.org

2, 4, 20, 2073, 688812, 23493068282804, 51287550456151700
Offset: 1

Views

Author

Jonathan Sondow, Dec 27 2004

Keywords

Comments

The prime denominators of convergents to e form A094008 (so A000040(a(n)) = A094008(n)). Their positions in A007677 (denominators of convergents to e) form A094007, so a(n) = A000720(A007677(A094007(n))).
a(6)-a(7) computed using Kim Walisch's primecount program. - Giovanni Resta, Jun 03 2019

Examples

			a(1) = 2 because the first convergent to e with prime denominator is 8/3 and the index of 3 is 2, i.e., 3 is the 2nd prime.
		

Crossrefs

Formula

a(n) = A000720(A094008(n)).

Extensions

a(6)-a(7) from Giovanni Resta, Jun 03 2019
Showing 1-5 of 5 results.