The Ramanujan tau function, studied by Ramanujan (1916), is the function τ : N → Z {\displaystyle \tau :\mathbb {N} \to \mathbb {Z} } defined by the following identity:
where q = exp ( 2 π i z ) {\displaystyle q=\exp(2\pi iz)} with I m ( z ) > 0 {\displaystyle \mathrm {Im} (z)>0} , ϕ {\displaystyle \phi } is the Euler function, η {\displaystyle \eta } is the Dedekind eta function, and the function Δ ( z ) {\displaystyle \Delta (z)} is a holomorphic cusp form of weight 12 and level 1, known as the discriminant modular form (some authors, notably Apostol, write Δ / ( 2 π ) 12 {\displaystyle \Delta /(2\pi )^{12}} instead of Δ {\displaystyle \Delta } ). It appears in connection to an "error term" involved in counting the number of ways of expressing an integer as a sum of 24 squares. A formula due to Ian G. Macdonald was given in Dyson (1972).