This site is supported by donations to The OEIS Foundation.

# A remarkable formula of Ramanujan

(Redirected from Sqrt(2/(pi*e))/erfc(1/sqrt(2)))

Ramanujan found the following remarkable formula which relates
 π
and
 e
to the sum of a generalized continued fraction and a power series, but where neither the continued fraction nor the power series separately relate to
 π
and
 e
.
${\displaystyle {\sqrt {{\frac {\pi }{2}}\cdot {\frac {e^{x}}{x}}}}={\cfrac {1}{x+{\cfrac {1}{1+{\cfrac {2}{x+{\cfrac {3}{1+{\cfrac {4}{x+{\cfrac {5}{1+{\cfrac {6}{x+{\cfrac {7}{1+{\cfrac {8}{\ddots }}}}}}}}}}}}}}}}}}~+~{\Bigg \{}1+{\frac {x}{1\cdot 3}}+{\frac {x^{2}}{1\cdot 3\cdot 5}}+{\frac {x^{3}}{1\cdot 3\cdot 5\cdot 7}}+{\frac {x^{4}}{1\cdot 3\cdot 5\cdot 7\cdot 9}}+\cdots {\Bigg \}},\quad x>0,\,}$

or

${\displaystyle {\sqrt {{\frac {\pi }{2}}\cdot {\frac {e^{x}}{x}}}}={\cfrac {1}{a_{0}+{\cfrac {b_{1}}{a_{1}+{\cfrac {b_{2}}{\ddots +{\cfrac {\ddots }{a_{n-1}+{\cfrac {b_{n}}{a_{n}+{\cfrac {b_{n+1}}{\ddots }}}}}}}}}}}}~+~{\Bigg \{}\sum _{n=0}^{\infty }{\frac {1}{(2n+1)!!}}~x^{n}{\Bigg \}},\quad x>0,\,}$
where
 an   − 1 = x (n mod 2), bn = n, n   ≥   1
, and
 n!!
is the double factorial.

## Sqrt(pi*e/2)

For
 x = 1
we get
${\displaystyle {\sqrt {\frac {\pi e}{2}}}={\cfrac {1}{1+{\cfrac {1}{1+{\cfrac {2}{1+{\cfrac {3}{1+{\cfrac {4}{1+{\cfrac {5}{1+{\cfrac {6}{1+{\cfrac {7}{1+{\cfrac {8}{\ddots }}}}}}}}}}}}}}}}}}~+~{\Bigg \{}1+{\frac {1}{1\cdot 3}}+{\frac {1}{1\cdot 3\cdot 5}}+{\frac {1}{1\cdot 3\cdot 5\cdot 7}}+{\frac {1}{1\cdot 3\cdot 5\cdot 7\cdot 9}}+\cdots {\Bigg \}},\,}$

or

${\displaystyle {\sqrt {\frac {\pi e}{2}}}={\cfrac {1}{a_{0}+{\cfrac {b_{1}}{a_{1}+{\cfrac {b_{2}}{\ddots +{\cfrac {\ddots }{a_{n-1}+{\cfrac {b_{n}}{a_{n}+{\cfrac {b_{n+1}}{\ddots }}}}}}}}}}}}~+~{\Bigg \{}\sum _{n=0}^{\infty }{\frac {1}{(2n+1)!!}}{\Bigg \}},\,}$
where
 an   − 1 = 1, bn = n, n   ≥   1
, and
 n!!
is the double factorial. Since it is not known whether
 π e
is irrational or not, it is thus not known whether

2√  π e / 2
is transcendental or not (although it is obviously irrational).

### Decimal expansion of Sqrt(pi*e/2)

The decimal expansion of
 2√  π e / 2
is
${\displaystyle {\sqrt {\frac {\pi e}{2}}}=2.06636567706124646923469594215\ldots \,}$
A059444 Decimal expansion of
 2√  π e / 2
.
 {2, 0, 6, 6, 3, 6, 5, 6, 7, 7, 0, 6, 1, 2, 4, 6, 4, 6, 9, 2, 3, 4, 6, 9, 5, 9, 4, 2, 1, 4, 9, 9, 2, 6, 3, 2, 4, 7, 2, 2, 7, 6, 0, 9, 5, 8, 4, 9, 5, 6, 5, 4, 2, 2, 5, 7, 7, 8, 3, 2, 5, 6, 2, 6, 8, 9, 8, ...}

### Continued fraction expansion of Sqrt(pi*e/2)

The simple continued fraction expansion of
 2√  π e / 2
is
${\displaystyle {\sqrt {\frac {\pi e}{2}}}=2+{\cfrac {1}{15+{\cfrac {1}{14+{\cfrac {1}{1+{\cfrac {1}{2+{\cfrac {1}{3+{\cfrac {1}{17+{\cfrac {1}{1+{\cfrac {1}{1+{\cfrac {1}{\ddots }}}}}}}}}}}}}}}}}}.\,}$
A059445 Continued fraction for square root of
 2√  π e / 2
.
 {2, 15, 14, 1, 2, 3, 17, 1, 1, 5, 1, 30, 1, 3, 2, 1, 1, 1, 3, 3, 1, 4, 2, 9, 2, 1, 9, 1, 7, 1, 6, 1, 5, 1, 5, 3, 1, 1, 3, 1, 36, 4, 18, 2, 1, 2, 4, 1, 3, 366, 3, 1, 1, 16, 2, 1, 2, 2, 1, 3, 3, 1, 5, ...}

### Continued fraction part

The continued fraction part is given by

${\displaystyle {\cfrac {1}{1+{\cfrac {1}{1+{\cfrac {2}{1+{\cfrac {3}{1+{\cfrac {4}{1+{\cfrac {5}{1+{\cfrac {6}{1+{\cfrac {7}{1+{\cfrac {8}{\ddots }}}}}}}}}}}}}}}}}}={\sqrt {\frac {\pi e}{2}}}{\rm {~erfc}}({\tfrac {1}{\sqrt {2}}})={\sqrt {\frac {\pi e}{2}}}\,(1-{\rm {~erf}}({\tfrac {1}{\sqrt {2}}}))={\sqrt {e}}\,{\Bigg \{}{\sqrt {\frac {\pi }{2}}}~-~\sum _{n=0}^{\infty }{\frac {(-1)^{n}}{2^{n}\,n!\,(2n+1)}}{\Bigg \}},\,}$

where

${\displaystyle {\rm {erfc}}(z):={\frac {2}{\sqrt {\pi }}}\int _{z}^{\infty }e^{-t^{2}}dt=1-{\rm {~erf}}(z)=1-{\frac {2}{\sqrt {\pi }}}\int _{0}^{z}e^{-t^{2}}dt=1-{\frac {2}{\sqrt {\pi }}}\sum _{n=0}^{\infty }{\frac {(-1)^{n}\,z^{2n+1}}{n!\,(2n+1)}}\,}$
is the complementary error function (
 erfc
)[1] and
 erf (z) = 1 −   erfc (z)
is the error function (
 erf
).[2]

The continued fraction part has decimal expansion

${\displaystyle 0.6556795424187984715438712307308112833992823328704\ldots \,}$
A108088 Decimal expansion of
 1  + 1  /  (1  + 2  /  (1  + 3  /  (1  + 4  /  (1  + 5  /  (1 + ⋯ ) ⋯ )
.
 {6, 5, 5, 6, 7, 9, 5, 4, 2, 4, 1, 8, 7, 9, 8, 4, 7, 1, 5, 4, 3, 8, 7, 1, 2, 3, 0, 7, 3, 0, 8, 1, 1, 2, 8, 3, 3, 9, 9, 2, 8, 2, 3, 3, 2, 8, 7, 0, 4, 6, 2, 0, 2, 8, 0, 5, 3, 6, 8, 6, 1, 5, 8, 7, 3, 4, ...}

#### Reciprocal of the continued fraction part

The reciprocal of the continued fraction part is given by

${\displaystyle 1+{\cfrac {1}{1+{\cfrac {2}{1+{\cfrac {3}{1+{\cfrac {4}{1+{\cfrac {5}{1+{\cfrac {6}{1+{\cfrac {7}{1+{\cfrac {8}{\ddots }}}}}}}}}}}}}}}}={\sqrt {\frac {2}{\pi e}}}{\frac {1}{{\rm {~erfc}}({\tfrac {1}{\sqrt {2}}})}},\,}$

with decimal expansion

${\displaystyle 1.52513527616098120908909053639057871330711636492060333554631394242\ldots \,}$
A111129 Decimal expansion of the continued fraction
 1  + 1  /  (1  + 2  /  (1  + 3  /  (1  + 4  /  (1  + 5  /  (1 + ⋯ ) ⋯ )
.
 {1, 5, 2, 5, 1, 3, 5, 2, 7, 6, 1, 6, 0, 9, 8, 1, 2, 0, 9, 0, 8, 9, 0, 9, 0, 5, 3, 6, 3, 9, 0, 5, 7, 8, 7, 1, 3, 3, 0, 7, 1, 1, 6, 3, 6, 4, 9, 2, 0, 6, 0, 3, 3, 3, 5, 5, 4, 6, 3, 1, 3, 9, 4, 2, 4, 2, ...}

### Power series part

${\displaystyle \sum _{n=0}^{\infty }{\frac {1}{(2n+1)!!}}={\sqrt {\frac {\pi e}{2}}}\,{\rm {~erf}}({\tfrac {1}{\sqrt {2}}})={\sqrt {e}}\,\sum _{n=0}^{\infty }{\frac {(-1)^{n}}{2^{n}\,n!\,(2n+1)}}={\sqrt {e}}\,\sum _{n=0}^{\infty }{\frac {(-1)^{n}}{(2n)!!\,(2n+1)}},\,}$

where

${\displaystyle {\rm {erf}}(z)\equiv {\frac {2}{\sqrt {\pi }}}\int _{0}^{z}e^{-t^{2}}dt={\frac {2}{\sqrt {\pi }}}\sum _{n=0}^{\infty }{\frac {(-1)^{n}\,z^{2n+1}}{n!\,(2n+1)}}\,}$
is the error function (
 erf
).[2] The power series part has decimal expansion (which is pretty close to
 2√  2 = 1.414213562373095…
) (see A002193)
${\displaystyle \sum _{n=0}^{\infty }{\frac {1}{(2n+1)!!}}=1.410686134642447997690824711419115041323478\ldots .\,}$
A060196 Decimal expansion of
 1 + 1 / (1 ⋅  3) + 1 / (1 ⋅  3 ⋅  5) + 1 ⧸ (1 ⋅  3 ⋅  5 ⋅  7) + ...
 {1, 4, 1, 0, 6, 8, 6, 1, 3, 4, 6, 4, 2, 4, 4, 7, 9, 9, 7, 6, 9, 0, 8, 2, 4, 7, 1, 1, 4, 1, 9, 1, 1, 5, 0, 4, 1, 3, 2, 3, 4, 7, 8, 6, 2, 5, 6, 2, 5, 1, 9, 2, 1, 9, 7, 7, 2, 4, 6, 3, 9, 4, 6, 8, 1, 6, ...}