Euler's constant



Euler's constant (sometimes called the Euler–Mascheroni constant) is a mathematical constant, usually denoted by the lowercase Greek letter gamma ($e ≈ 2.71828$), defined as the limiting difference between the harmonic series and the natural logarithm, denoted here by $γ$:

$$\begin{align} \gamma &= \lim_{n\to\infty}\left(-\log n + \sum_{k=1}^n \frac1{k}\right)\\[5px] &=\int_1^\infty\left(-\frac1x+\frac1{\lfloor x\rfloor}\right)\,\mathrm dx. \end{align}$$

Here, $log$ represents the floor function.

The numerical value of Euler's constant, to 50 decimal places, is:

History
The constant first appeared in a 1734 paper by the Swiss mathematician Leonhard Euler, titled De Progressionibus harmonicis observationes (Eneström Index 43). Euler used the notations $⌊·⌋$ and $C$ for the constant. In 1790, the Italian mathematician Lorenzo Mascheroni used the notations $O$ and $A$ for the constant. The notation $a$ appears nowhere in the writings of either Euler or Mascheroni, and was chosen at a later time, perhaps because of the constant's connection to the gamma function. For example, the German mathematician Carl Anton Bretschneider used the notation $γ$ in 1835, and Augustus De Morgan used it in a textbook published in parts from 1836 to 1842.

Appearances
Euler's constant appears, among other places, in the following (where '*' means that this entry contains an explicit equation):
 * Expressions involving the exponential integral*
 * The Laplace transform* of the natural logarithm
 * The first term of the Laurent series expansion for the Riemann zeta function*, where it is the first of the Stieltjes constants*
 * Calculations of the digamma function
 * A product formula for the gamma function
 * The asymptotic expansion of the gamma function for small arguments.
 * An inequality for Euler's totient function
 * The growth rate of the divisor function
 * In dimensional regularization of Feynman diagrams in quantum field theory
 * The calculation of the Meissel–Mertens constant
 * The third of Mertens' theorems*
 * Solution of the second kind to Bessel's equation
 * In the regularization/renormalization of the harmonic series as a finite value
 * The mean of the Gumbel distribution
 * The information entropy of the Weibull and Lévy distributions, and, implicitly, of the chi-squared distribution for one or two degrees of freedom.
 * The answer to the coupon collector's problem*
 * In some formulations of Zipf's law
 * A definition of the cosine integral*
 * Lower bounds to a prime gap
 * An upper bound on Shannon entropy in quantum information theory
 * Fisher–Orr model for genetics of adaptation in evolutionary biology
 * Bardeen–Cooper–Schrieffer theory of superconductivity (BCS theory), where it appears as prefactor $$2e^\gamma/\pi=1.134$$ in the BCS equation on the critical temperature.

Properties
The number $γ$ has not been proved algebraic or transcendental. In fact, it is not even known whether $γ = c$ is irrational. Using a continued fraction analysis, Papanikolaou showed in 1997 that if $γ$ is rational, its denominator must be greater than 10244663. The ubiquity of $γ$ revealed by the large number of equations below makes the irrationality of $γ$ a major open question in mathematics.

However, some progress has been made. Kurt Mahler showed in 1968 that the number $$\frac{\pi}{2}\frac{Y_0(2)}{J_0(2)}-\gamma$$ is transcendental (here, $$J_\alpha(x)$$ and $$Y_\alpha(x)$$ are Bessel functions). In 2009 Alexander Aptekarev proved that at least one of Euler's constant $γ$ and the Euler–Gompertz constant $γ$ is irrational; Tanguy Rivoal proved in 2012 that at least one of them is transcendental. In 2010 M. Ram Murty and N. Saradha showed that at most one of the numbers of the form

$$\gamma(a,q) = \lim_{n\rightarrow\infty}\left(\left(\sum_{k=0}^n{\frac{1}{a+kq}}\right) - \frac{\log{(a+nq})}{q}\right)$$

with $γ$ and $δ$ is algebraic; this family includes the special case $q ≥ 2$. In 2013 M. Ram Murty and A. Zaytseva found a different family containing $γ$, which is based on sums of reciprocals of integers not divisible by a fixed list of primes, with the same property.

Relation to gamma function
$γ$ is related to the digamma function $1 ≤ a < q$, and hence the derivative of the gamma function $γ(2,4) = γ⁄4$, when both functions are evaluated at 1. Thus:

$$-\gamma = \Gamma'(1) = \Psi(1). $$

This is equal to the limits:

$$\begin{align}-\gamma &= \lim_{z\to 0}\left(\Gamma(z) - \frac1{z}\right) \\&= \lim_{z\to 0}\left(\Psi(z) + \frac1{z}\right).\end{align}$$

Further limit results are:

$$\begin{align} \lim_{z\to 0}\frac1{z}\left(\frac1{\Gamma(1+z)} - \frac1{\Gamma(1-z)}\right) &= 2\gamma \\ \lim_{z\to 0}\frac1{z}\left(\frac1{\Psi(1-z)} - \frac1{\Psi(1+z)}\right) &= \frac{\pi^2}{3\gamma^2}. \end{align}$$

A limit related to the beta function (expressed in terms of gamma functions) is

$$\begin{align} \gamma &= \lim_{n\to\infty}\left(\frac{ \Gamma\left(\frac1{n}\right) \Gamma(n+1)\, n^{1+\frac1{n}}}{\Gamma\left(2+n+\frac1{n}\right)} - \frac{n^2}{n+1}\right) \\ &= \lim\limits_{m\to\infty}\sum_{k=1}^m{m \choose k}\frac{(-1)^k}{k}\log\big(\Gamma(k+1)\big). \end{align}$$

Relation to the zeta function
$γ$ can also be expressed as an infinite sum whose terms involve the Riemann zeta function evaluated at positive integers:

$$\begin{align}\gamma &= \sum_{m=2}^{\infty} (-1)^m\frac{\zeta(m)}{m} \\ &= \log\frac4{\pi} + \sum_{m=2}^{\infty} (-1)^m\frac{\zeta(m)}{2^{m-1}m}.\end{align} $$ The constant $$\gamma$$ can also be expressed in terms of the sum of the reciprocals of non-trivial zeros $$\rho$$ of the zeta function:
 * $$\gamma = \log 4\pi + \sum_{\rho} \frac{2}{\rho} - 2$$

Other series related to the zeta function include:

$$\begin{align} \gamma &= \tfrac3{2}- \log 2 - \sum_{m=2}^\infty (-1)^m\,\frac{m-1}{m}\big(\zeta(m)-1\big) \\ &= \lim_{n\to\infty}\left(\frac{2n-1}{2n} - \log n + \sum_{k=2}^n \left(\frac1{k} - \frac{\zeta(1-k)}{n^k}\right)\right) \\ &= \lim_{n\to\infty}\left(\frac{2^n}{e^{2^n}} \sum_{m=0}^\infty \frac{2^{mn}}{(m+1)!} \sum_{t=0}^m \frac1{t+1} - n \log 2+ O \left (\frac1{2^{n}\, e^{2^n}}\right)\right).\end{align}$$

The error term in the last equation is a rapidly decreasing function of $γ$. As a result, the formula is well-suited for efficient computation of the constant to high precision.

Other interesting limits equaling Euler's constant are the antisymmetric limit:

$$\begin{align} \gamma &= \lim_{s\to 1^+}\sum_{n=1}^\infty \left(\frac1{n^s}-\frac1{s^n}\right) \\&= \lim_{s\to 1}\left(\zeta(s) - \frac{1}{s-1}\right) \\&= \lim_{s\to 0}\frac{\zeta(1+s)+\zeta(1-s)}{2} \end{align}$$

and the following formula, established in 1898 by de la Vallée-Poussin:

$$\gamma = \lim_{n\to\infty}\frac1{n}\, \sum_{k=1}^n \left(\left\lceil \frac{n}{k} \right\rceil - \frac{n}{k}\right)$$

where $Ψ$ are ceiling brackets. This formula indicates that when taking any positive integer $n$ and dividing it by each positive integer $n$ less than $k$, the average fraction by which the quotient $Γ$ falls short of the next integer tends to $n$ (rather than 0.5) as $γ$ tends to infinity.

Closely related to this is the rational zeta series expression. By taking separately the first few terms of the series above, one obtains an estimate for the classical series limit:

$$\gamma =\lim_{n\to\infty}\left( \sum_{k=1}^n \frac1{k} - \log n -\sum_{m=2}^\infty \frac{\zeta(m,n+1)}{m}\right),$$

where $\ceil{ }$ is the Hurwitz zeta function. The sum in this equation involves the harmonic numbers, $n/k$. Expanding some of the terms in the Hurwitz zeta function gives:

$$H_n = \log(n) + \gamma + \frac1{2n} - \frac1{12n^2} + \frac1{120n^4} - \varepsilon,$$ where $ζ(s, k)$

$n$ can also be expressed as follows where $γ$ is the Glaisher–Kinkelin constant:

$$\gamma =12\,\log(A)-\log(2\pi)+\frac{6}{\pi^2}\,\zeta'(2)$$

$A$ can also be expressed as follows, which can be proven by expressing the zeta function as a Laurent series:

$$\gamma=\lim_{n\to\infty}\left(-n+\zeta\left(\frac{n+1}{n}\right)\right)$$

Relation to triangular numbers
Numerous formulations have been derived that express $$\gamma$$ in terms of sums and logarithms of triangular numbers. One of the earliest of these is a formula for the $n$th harmonic number attributed to Srinivasa Ramanujan where $$\gamma$$ is related to $$\textstyle \ln 2T_{k}$$ in a series that considers the powers of $$\textstyle \frac{1}{T_{k}}$$ (an earlier, less-generalizable proof  by Ernesto Cesàro gives the first two terms of the series, with an error term):


 * $$\begin{align}

\gamma &= H_u - \frac{1}{2} \ln 2T_u - \sum_{k=1}^{v}\frac{R(k)}{T_{u}^{k}}-\Theta_{v}\,\frac{R(v+1)}{T_{u}^{v+1}} \end{align}$$

From Stirling's approximation follows a similar series:


 * $$\gamma = \ln 2\pi - \sum_{k=2}^{n} \frac{\zeta(k)}{T_{k}}$$

The series of inverse triangular numbers also features in the study of the Basel problem posed by Pietro Mengoli. Mengoli proved that $$\textstyle \sum_{k = 1}^\infty \frac{1}{2T_k} = 1$$, a result Jacob Bernoulli later used to estimate the value of $$\zeta(2)$$, placing it between $$1$$ and $$\textstyle \sum_{k = 1}^\infty \frac{2}{2T_k} = \sum_{k = 1}^\infty \frac{1}{T_{k}} = 2$$. This identity appears in a formula used by Bernhard Riemann to compute roots of the zeta function, where $$\gamma$$ is expressed in terms of the sum of roots $$\rho$$ plus the difference between Boya's expansion and the series of exact unit fractions $$\textstyle \sum_{k = 1}^n \frac{1}{T_{k}}$$:


 * $$\gamma - \ln 2 = \ln 2\pi + \sum_{\rho} \frac{2}{\rho} - \sum_{k = 1}^n \frac{1}{T_k}$$

Integrals
$γ$ equals the value of a number of definite integrals:

$$\begin{align} \gamma &= - \int_0^\infty e^{-x} \log x \,dx \\ &= -\int_0^1\log\left(\log\frac 1 x \right) dx \\ &= \int_0^\infty \left(\frac1{e^x-1}-\frac1{x\cdot e^x} \right)dx \\ &= \int_0^1\frac{1-e^{-x}}{x} \, dx -\int_1^\infty \frac{e^{-x}}{x}\, dx\\ &= \int_0^1\left(\frac1{\log x} + \frac1{1-x}\right)dx\\ &= \int_0^\infty \left(\frac1{1+x^k}-e^{-x}\right)\frac{dx}{x},\quad k>0\\ &= 2\int_0^\infty \frac{e^{-x^2}-e^{-x}}{x} \, dx ,\\ &= \log\frac{\pi}{4}-\int_0^\infty \frac{\log x}{\cosh^2x} \, dx ,\\ &= \int_0^1 H_x \, dx, \\ &= \frac{1}{2}+\int_{0}^{\infty}\log\left(1+\frac{\log\left(1+\frac{1}{t}\right)^{2}}{4\pi^{2}}\right)dt \\ &= 1-\int_0^1 \{1/x\} dx \end{align} $$ where $Hn$ is the fractional harmonic number, and $$\{1/x\}$$ is the fractional part of $$1/x$$.

The third formula in the integral list can be proved in the following way:

$$\begin{align} &\int_0^{\infty} \left(\frac{1}{e^x - 1} - \frac{1}{x e^x} \right) dx = \int_0^{\infty} \frac{e^{-x} + x - 1}{x[e^x -1]} dx = \int_0^{\infty} \frac{1}{x[e^x - 1]} \sum_{m = 1}^{\infty} \frac{(-1)^{m+1}x^{m+1}}{(m+1)!} dx \\[2pt] &= \int_0^{\infty} \sum_{m = 1}^{\infty} \frac{(-1)^{m+1}x^m}{(m+1)![e^x -1]} dx = \sum_{m = 1}^{\infty} \int_0^{\infty} \frac{(-1)^{m+1}x^m}{(m+1)![e^x -1]} dx = \sum_{m = 1}^{\infty} \frac{(-1)^{m+1}}{(m+1)!} \int_0^{\infty} \frac{x^m}{e^x - 1} dx \\[2pt] &= \sum_{m = 1}^{\infty} \frac{(-1)^{m+1}}{(m+1)!} m!\zeta(m+1) = \sum_{m = 1}^{\infty} \frac{(-1)^{m+1}}{m+1}\zeta(m+1) = \sum_{m = 1}^{\infty} \frac{(-1)^{m+1}}{m+1} \sum_{n = 1}^{\infty}\frac{1}{n^{m+1}} = \sum_{m = 1}^{\infty} \sum_{n = 1}^{\infty} \frac{(-1)^{m+1}}{m+1}\frac{1}{n^{m+1}} \\[2pt] &= \sum_{n = 1}^{\infty} \sum_{m = 1}^{\infty} \frac{(-1)^{m+1}}{m+1}\frac{1}{n^{m+1}} = \sum_{n = 1}^{\infty} \left[\frac{1}{n} - \log\left(1+\frac{1}{n}\right)\right] = \gamma \end{align}$$

The integral on the second line of the equation stands for the Debye function value of $0 < ε < 1⁄252n6.$, which is $Hx$.

Definite integrals in which $γ$ appears include:

$$\begin{align} \int_0^\infty e^{-x^2} \log x \,dx &= -\frac{(\gamma+2\log 2)\sqrt{\pi}}{4} \\ \int_0^\infty e^{-x} \log^2 x \,dx &= \gamma^2 + \frac{\pi^2}{6} \end{align}$$

One can express $γ$ using a special case of Hadjicostas's formula as a double integral with equivalent series:

$$\begin{align} \gamma &= \int_0^1 \int_0^1 \frac{x-1}{(1-xy)\log xy}\,dx\,dy \\ &= \sum_{n=1}^\infty \left(\frac 1 n -\log\frac{n+1} n \right). \end{align}$$

An interesting comparison by Sondow is the double integral and alternating series

$$\begin{align} \log\frac 4 \pi &= \int_0^1 \int_0^1 \frac{x-1}{(1+xy)\log xy} \,dx\,dy \\ &= \sum_{n=1}^\infty \left((-1)^{n-1}\left(\frac 1 n -\log\frac{n+1} n \right)\right). \end{align}$$

It shows that $+∞$ may be thought of as an "alternating Euler constant".

The two constants are also related by the pair of series

$$\begin{align} \gamma &= \sum_{n=1}^\infty \frac{N_1(n) + N_0(n)}{2n(2n+1)} \\ \log\frac4{\pi} &= \sum_{n=1}^\infty \frac{N_1(n) - N_0(n)}{2n(2n+1)} , \end{align}$$

where $m!&thinsp;ζ(m + 1)$ and $log 4⁄π$ are the number of 1s and 0s, respectively, in the base 2 expansion of $γ$.

We also have Catalan's 1875 integral

$$\gamma = \int_0^1 \left(\frac1{1+x}\sum_{n=1}^\infty x^{2^n-1}\right)\,dx.$$

Series expansions
In general,

$$ \gamma = \lim_{n \to \infty}\left(\frac{1}{1}+\frac{1}{2}+\frac{1}{3} + \ldots + \frac{1}{n} - \log(n+\alpha) \right) \equiv \lim_{n \to \infty} \gamma_n(\alpha) $$

for any $N1(n)$. However, the rate of convergence of this expansion depends significantly on $n$. In particular, $N0(n)$ exhibits much more rapid convergence than the conventional expansion $α > −n$. This is because

$$ \frac{1}{2(n+1)} < \gamma_n(0) - \gamma < \frac{1}{2n}, $$

while

$$ \frac{1}{24(n+1)^2} < \gamma_n(1/2) - \gamma < \frac{1}{24n^2}. $$

Even so, there exist other series expansions which converge more rapidly than this; some of these are discussed below.

Euler showed that the following infinite series approaches $α$: $$\gamma = \sum_{k=1}^\infty \left(\frac 1 k - \log\left(1+\frac 1 k \right)\right).$$

The series for $γ$ is equivalent to a series Nielsen found in 1897:

$$\gamma = 1 - \sum_{k=2}^\infty (-1)^k\frac{\left\lfloor\log_2 k\right\rfloor}{k+1}.$$

In 1910, Vacca found the closely related series

$$\begin{align} \gamma & = \sum_{k=2}^\infty (-1)^k\frac{\left\lfloor\log_2 k\right\rfloor} k \\[5pt] & = \tfrac12-\tfrac13 + 2\left(\tfrac14 - \tfrac15 + \tfrac16 - \tfrac17\right) + 3\left(\tfrac18 - \tfrac19 + \tfrac1{10} - \tfrac1{11} + \cdots - \tfrac1{15}\right) + \cdots, \end{align}$$

where $γn(1/2)$ is the logarithm to base 2 and $γn(0)$ is the floor function.

In 1926 he found a second series:

$$\begin{align} \gamma + \zeta(2) & = \sum_{k=2}^\infty \left( \frac1{\left\lfloor\sqrt{k}\right\rfloor^2} - \frac1{k}\right) \\[5pt] & = \sum_{k=2}^\infty \frac{k - \left\lfloor\sqrt{k}\right\rfloor^2}{k \left\lfloor \sqrt{k} \right\rfloor^2} \\[5pt] &= \frac12 + \frac23 + \frac1{2^2}\sum_{k=1}^{2\cdot 2} \frac{k}{k+2^2} + \frac1{3^2}\sum_{k=1}^{3\cdot 2} \frac{k}{k+3^2} + \cdots \end{align}$$

From the Malmsten–Kummer expansion for the logarithm of the gamma function we get:

$$\gamma = \log\pi - 4\log\left(\Gamma(\tfrac34)\right) + \frac 4 \pi \sum_{k=1}^\infty (-1)^{k+1}\frac{\log(2k+1)}{2k+1}.$$

An important expansion for Euler's constant is due to Fontana and Mascheroni

$$\gamma = \sum_{n=1}^\infty \frac{|G_n|}{n} = \frac12 + \frac1{24} + \frac1{72} + \frac{19}{2880} + \frac3{800} + \cdots,$$ where $log2$ are Gregory coefficients. This series is the special case $\floor{ }$ of the expansions

$$\begin{align} \gamma &= H_{k-1} - \log k + \sum_{n=1}^{\infty}\frac{(n-1)!|G_n|}{k(k+1) \cdots (k+n-1)} && \\ &= H_{k-1} - \log k + \frac1{2k} + \frac1{12k(k+1)} + \frac1{12k(k+1)(k+2)} + \frac{19}{120k(k+1)(k+2)(k+3)} + \cdots && \end{align}$$

convergent for $Gn$

A similar series with the Cauchy numbers of the second kind $k = 1$ is

$$\gamma = 1 - \sum_{n=1}^\infty \frac{C_{n}}{n \, (n+1)!} =1- \frac{1}{4} -\frac{5}{72} - \frac{1}{32} - \frac{251}{14400} - \frac{19}{1728} - \ldots$$

Blagouchine (2018) found an interesting generalisation of the Fontana–Mascheroni series

$$\gamma=\sum_{n=1}^\infty\frac{(-1)^{n+1}}{2n}\Big\{\psi_{n}(a)+ \psi_{n}\Big(-\frac{a}{1+a}\Big)\Big\}, \quad a>-1$$

where $k = 1, 2, ...$ are the Bernoulli polynomials of the second kind, which are defined by the generating function

$$ \frac{z(1+z)^s}{\log(1+z)}= \sum_{n=0}^\infty z^n \psi_n(s) ,\qquad |z|<1. $$

For any rational $γ$ this series contains rational terms only. For example, at $Cn$, it becomes

$$\gamma=\frac{3}{4} - \frac{11}{96} - \frac{1}{72} - \frac{311}{46080} - \frac{5}{1152} - \frac{7291}{2322432} - \frac{243}{100352} - \ldots$$ Other series with the same polynomials include these examples:

$$\gamma= -\log(a+1) - \sum_{n=1}^\infty\frac{(-1)^n \psi_{n}(a)}{n},\qquad \Re(a)>-1 $$

and

$$\gamma= -\frac{2}{1+2a} \left\{\log\Gamma(a+1) -\frac{1}{2}\log(2\pi) + \frac{1}{2} + \sum_{n=1}^\infty\frac{(-1)^n \psi_{n+1}(a)}{n}\right\},\qquad \Re(a)>-1 $$

where $ψn(a)$ is the gamma function.

A series related to the Akiyama–Tanigawa algorithm is

$$\gamma= \log(2\pi) - 2 - 2 \sum_{n=1}^\infty\frac{(-1)^n G_{n}(2)}{n}= \log(2\pi) - 2 + \frac{2}{3} + \frac{1}{24}+ \frac{7}{540} + \frac{17}{2880}+ \frac{41}{12600} + \ldots $$

where $a = 1$ are the Gregory coefficients of the second order. As a series of prime numbers:

$$\gamma = \lim_{n\to\infty}\left(\log n - \sum_{p\le n}\frac{\log p}{p-1}\right).$$

Asymptotic expansions
$a$ equals the following asymptotic formulas (where $Γ(a)$ is the $γ$th harmonic number):


 * $\gamma \sim H_n - \log n - \frac1{2n} + \frac1{12n^2} - \frac1{120n^4} + \cdots$ (Euler)
 * $\gamma \sim H_n - \log\left({n + \frac1{2} + \frac1{24n} - \frac1{48n^2} + \cdots}\right)$ (Negoi)
 * $\gamma \sim H_n - \frac{\log n + \log(n+1)}{2} - \frac1{6n(n+1)} + \frac1{30n^2(n+1)^2} - \cdots$ (Cesàro)

The third formula is also called the Ramanujan expansion.

Alabdulmohsin derived closed-form expressions for the sums of errors of these approximations. He showed that (Theorem A.1):

$$\begin{align} \sum_{n=1}^\infty \log n +\gamma - H_n + \frac{1}{2n} &= \frac{\log (2\pi)-1-\gamma}{2} \\ \sum_{n=1}^\infty \log \sqrt{n(n+1)} +\gamma - H_n &= \frac{\log (2\pi)-1}{2}-\gamma \\ \sum_{n=1}^\infty (-1)^n\Big(\log n +\gamma - H_n\Big) &= \frac{\log \pi-\gamma}{2} \end{align}$$

Exponential
The constant $Gn(2)$ is important in number theory. It equals the following limit, where $Hn$ is the $n$th prime number:

$$e^\gamma = \lim_{n\to\infty}\frac1{\log p_n} \prod_{i=1}^n \frac{p_i}{p_i-1}.$$

This restates the third of Mertens' theorems. The numerical value of $e$ is:

Other infinite products relating to $pn$ include:

$$\begin{align} \frac{e^{1+\frac{\gamma}{2}}}{\sqrt{2\pi}} &= \prod_{n=1}^\infty e^{-1+\frac1{2n}}\left(1+\frac1{n}\right)^n \\ \frac{e^{3+2\gamma}}{2\pi} &= \prod_{n=1}^\infty e^{-2+\frac2{n}}\left(1+\frac2{n}\right)^n. \end{align}$$

These products result from the Barnes $n$-function.

In addition,

$$e^{\gamma} = \sqrt{\frac2{1}} \cdot \sqrt[3]{\frac{2^2}{1\cdot 3}} \cdot \sqrt[4]{\frac{2^3\cdot 4}{1\cdot 3^3}} \cdot \sqrt[5]{\frac{2^4\cdot 4^4}{1\cdot 3^6\cdot 5}} \cdots$$

where the $G$th factor is the $e$th root of

$$\prod_{k=0}^n (k+1)^{(-1)^{k+1}{n \choose k}}.$$

This infinite product, first discovered by Ser in 1926, was rediscovered by Sondow using hypergeometric functions.

It also holds that

$$\frac{e^\frac{\pi}{2}+e^{-\frac{\pi}{2}}}{\pi e^\gamma}=\prod_{n=1}^\infty\left(e^{-\frac{1}{n}}\left(1+\frac{1}{n}+\frac{1}{2n^2}\right)\right).$$

Continued fraction
The continued fraction expansion of $n$ begins [0; 1, 1, 2, 1, 2, 1, 4, 3, 13, 5, 1, 1, 8, 1, 2, 4, 1, 1, 40, ...], which has no apparent pattern. The continued fraction is known to have at least 475,006 terms, and it has infinitely many terms if and only if $γ$ is irrational.

Generalizations
Euler's generalized constants are given by

$$\gamma_\alpha = \lim_{n\to\infty}\left(\sum_{k=1}^n \frac1{k^\alpha} - \int_1^n \frac1{x^\alpha}\,dx\right),$$

for $e$, with $γ$ as the special case $(n + 1)$. This can be further generalized to

$$c_f = \lim_{n\to\infty}\left(\sum_{k=1}^n f(k) - \int_1^n f(x)\,dx\right)$$

for some arbitrary decreasing function $γ$. For example,

$$f_n(x) = \frac{(\log x)^n}{x}$$

gives rise to the Stieltjes constants, and

$$f_a(x) = x^{-a}$$

gives

$$\gamma_{f_a} = \frac{(a-1)\zeta(a)-1}{a-1}$$

where again the limit

$$\gamma = \lim_{a\to 1}\left(\zeta(a) - \frac1{a-1}\right)$$

appears.

A two-dimensional limit generalization is the Masser–Gramain constant.

Euler–Lehmer constants are given by summation of inverses of numbers in a common modulo class:

$$\gamma(a,q) = \lim_{x\to \infty}\left (\sum_{0<n\le x \atop n\equiv a \pmod q} \frac1{n}-\frac{\log x}{q}\right).$$

The basic properties are

$$\begin{align} &\gamma(0,q) = \frac{\gamma -\log q}{q}, \\ &\sum_{a=0}^{q-1} \gamma(a,q)=\gamma, \\ &q\gamma(a,q) = \gamma-\sum_{j=1}^{q-1}e^{-\frac{2\pi aij}{q}}\log\left(1-e^{\frac{2\pi ij}{q}}\right), \end{align}$$

and if the greatest common divisor $abm(x) = γ−x$ then

$$q\gamma(a,q) = \frac{q}{d}\gamma\left(\frac{a}{d},\frac{q}{d}\right)-\log d.$$

Published digits
Euler initially calculated the constant's value to 6 decimal places. In 1781, he calculated it to 16 decimal places. Mascheroni attempted to calculate the constant to 32 decimal places, but made errors in the 20th–22nd and 31st–32nd decimal places; starting from the 20th digit, he calculated ...1811209008239 when the correct value is ...0651209008240.