1 Introduction

The Weierstrass zeta function

$$\begin{aligned} Z_{L}(z)=\frac{1}{z}+\sum _{0\ne \lambda \in L}\left( \frac{1}{z-\lambda }+\frac{1}{\lambda }+\frac{z}{\lambda ^{2}}\right) \end{aligned}$$

of a rank 2 lattice \(L\subseteq \mathbb{C }\) is very important for the theory of elliptic functions. Though not elliptic itself, (minus) its derivative

$$\begin{aligned} \wp _{L}(z)=\frac{1}{z^{2}}+\sum _{0\ne \lambda \in L}\left( \frac{1}{(z-\lambda )^{2}}-\frac{1}{\lambda ^{2}}\right) \end{aligned}$$

is elliptic, and together with \(\wp _{L}^{\prime }\) it generates the field of functions which are elliptic with respect to \(L\). The zeta function \(Z_{L}\) also provides the relation between the Weierstrass \(\sigma \) function, a theta function of the lattice \(L\), and the elliptic function \(\wp _{L}\), since \(Z_{L}\) is the logarithmic derivative of the \(\sigma \) function and \(Z_{L}^{\prime }=-\wp _{L}\). Moreover, just like \(\wp _{L}\) is used in order to construct Eisenstein series of weight 2 (and from its derivatives one obtains Eisenstein series of higher weights), the function \(Z_{L}\) is used in order to construct Eisenstein series of weight 1 (see Chapter 4 of [1]). In fact, the results of the present paper have been obtained during the author’s study of this construction of weight 1 Eisenstein series, appearing in [1].

Since \(\wp _{L}\) is elliptic, the zeta function \(Z_{L}\) has a difference function

$$\begin{aligned} \eta _{L}:L\rightarrow \mathbb{C },\quad \eta _{L}(\lambda )=Z_{L}(z+\lambda )-Z_{L}(z), \end{aligned}$$

where the latter expression is a constant independent of \(z\). The map \(\eta _{L}\) is a homomorphism, and can be considered as the period map of \(\wp \) with respect to \(L=H_{1}(\mathbb{C }/L,\mathbb{Z })\). These constants \(\eta _{L}(\lambda )\) have various applications in the theory of elliptic functions: in particular, one of these constants shows up in the multiplier of the Fourier expansion of the sigma function. In all the references known to the author (see, for example, Chapter 18 of [2]), the evaluation of \(\eta _{L}\) requires various indirect tools (contour integration, for example). The purpose of this work is to introduce a specific order of summation for the series defining the zeta function which enables us to obtain the values of \(\eta _{L}\) directly, without the use of any additional tools. The same technique applies for obtaining the ellipticity of \(\wp _{L}\) and its derivatives, though here the standard proof is also short and simple.

The values of \(\eta _{L}\) for \(L=L_{\tau }\) involve the value of the Eisenstein series \(G_{2}\) at \(\tau \in \mathcal{H }\), defined by

$$\begin{aligned} G_{2}(\tau )=\sum _{c\in \mathbb{Z }}\sum _{d,(c,d)\ne (0,0)}\frac{1}{(c\tau +d)^{2} } \end{aligned}$$

(inner summation on \(d\), then on \(c\)). One knows that \(G_{2}\) is quasi-modular of weight 2, but the proof must address the problem that the defining series for \(G_{2}\) converges only conditionally. Here we show how the full quasi-modular behavior of \(G_{2}\) follows immediately from its relation with \(\eta _{L}\) and from the homogeneity property of the latter, saving even the need to verify that the quasi-modular action is an action.

In Sect. 2 we illustrate the application of the method for the simple case of \(\wp \) and its derivatives. Section 3 considers the Weierstrass zeta function and shows how this method evaluates \(\eta _{L}\) directly. Finally, in Sect. 4 we use these results to derive the quasi-modularity of \(G_{2}\) in a simple and transparent manner.

2 A simple illustration: \(\wp \) and its derivatives

Let \(\mathbb{C }\) denote the field of complex numbers, and for \(w\in \mathbb{C }\), \(\mathfrak{I } w\) denotes the imaginary part of \(w\). We denote the upper half plane \(\{\tau \in \mathbb{C }|\mathfrak{I }\tau >0\}\) by \(\mathcal{H }\), and a lattice \(L\) in \(\mathbb{C }\) is a rank 2 discrete subgroup of the additive group of \(\mathbb{C }\).

The analysis becomes much simpler when one of generators of the lattice \(L\subseteq \mathbb{C }\) is 1. For an element \(\tau \in \mathcal{H }\), we denote the lattice \(\mathbb{Z }\tau \oplus \mathbb{Z }\) by \(L_{\tau }\), and the index \(L_{\tau }\) is classically replaced by \(\tau \). It is evident that every lattice \(L\) is \(\alpha L_{\tau }\) for some \(\alpha \in \mathbb{C }\) and \(\tau \in \mathcal{H }\) (but not uniquely).

We start by presenting our argument for the simplest case of the derivatives of \(\wp \). For \(k\ge 3\) we have that the \((k-2)\)th derivative of \(\wp _{L}\) is

$$\begin{aligned} \wp _{L}^{(k-2)}(z)=(-1)^{k}(k-1)!\sum _{\lambda \in L}\frac{1}{(z-\lambda )^{k}}, \end{aligned}$$

hence for \(L=L_{\tau }\) we get

$$\begin{aligned} \wp _{\tau }^{(k-2)}(z)=(-1)^{k}(k-1)!\sum _{(c,d)\in \mathbb{Z }^2}\frac{1}{ (z-(c\tau +d))^k}. \end{aligned}$$

The only identities we shall need are the classical equality

$$\begin{aligned} \frac{1}{w}+\sum _{d=1}^{\infty }\left( \frac{1}{w+d}+\frac{1}{w-d} \right) =\pi \cot \pi w=-\pi i-2\pi i\sum _{m=1}^{\infty }\mathbf{e }(mw) \end{aligned}$$
(1)

and its derivatives

$$\begin{aligned} \sum _{d=-\infty }^{\infty }\frac{1}{(w+d)^{k}}=\frac{(-2\pi i)^{k}}{(k-1)!}\sum _{m=1}^{\infty }m^{k-1}\mathbf{e }(mw), \end{aligned}$$
(2)

both valid for \(w\in \mathcal{H }\) with \(\mathbf{e }(\sigma )=e^{2\pi i\sigma }\) for all \(\sigma \in \mathbb{C }\) (see, for example, Eqs. (1.1) and (1.2) of Chapter 1 of [1]—note that the summation in Eq. (1.1) there begins with \(m=0\) while we start with \(m=1\)). The left equality in Eq. (1) follows by taking the logarithmic derivative (at \(z=w\)) of the product expansion for the sine function,

$$\begin{aligned} \sin \pi z=\pi z\prod _{d=1}^{\infty }\left( 1-\frac{z^{2}}{d^{2}}\right) . \end{aligned}$$

The right equality there is obtained by expanding \(\pi \cot \pi w=\pi i\left( -1-\frac{2\mathbf{e }(w)}{1-\mathbf{e }(w)}\right) \) as a geometric series. We shall later obtain, however, expressions involving the left hand side of Eqs. (1) and (2) for \(w\not \in \mathcal{H }\). For \(w\in \overline{\mathcal{H }}\) we write \(w=-(-w)\), or alternatively use the geometric expansion of \(\pi \cot \pi w\) as \(\pi i\left( 1+\frac{2\mathbf{e }(-w)}{1-\mathbf{e }(-w)}\right) \). Then Eq. (1) takes the form

$$\begin{aligned} \frac{1}{w}+\sum _{d=1}^{\infty }\left( \frac{1}{w+d}+\frac{1}{w-d} \right) =\pi \cot \pi w=+\pi i+2\pi i\sum _{m=1}^{\infty }\mathbf{e }(-mw) \end{aligned}$$
(3)

and the corresponding Eq. (2) is obtained by differentiation:

$$\begin{aligned} \sum _{d=-\infty }^{\infty }\frac{1}{(w+d)^{k}}=\frac{(+2\pi i)^{k}}{(k-1)!}\sum _{m=1}^{\infty }m^{k-1}\mathbf{e }(-mw). \end{aligned}$$
(4)

We wish to substitute the value \(w=z-c\tau \) in these formulae, where \(\tau \) is the index of the lattice \(L_{\tau }\) and \(z\) is the argument of the function we investigate. We avoid the poles of the functions by considering \(z \not \in L_{\tau }\), which still allows \(w\) to be real, though not integral. For a real number \(x\) we denote its lower integral value \(\lfloor x \rfloor =\max \{n\in \mathbb{Z }|n \le x\}\), its upper integral value \(\lceil x \rceil =\min \{n\in \mathbb{Z }|n \ge x\}\), and its fractional part \(\{x\}=x-\lfloor x \rfloor \), the latter being the unique number \(0 \le a<1\) which lies in \(x+\mathbb{Z }\). Then for real \(w\) we use Eqs. (1) or (3) in the form

$$\begin{aligned} \frac{1}{w}+\sum _{d=1}^{\infty }\left( \frac{1}{w+d}+\frac{1}{w-d} \right) =\pi \cot \pi w=\pi \cot \pi a,\quad a=\{w\} \end{aligned}$$
(5)

(without the Fourier expansion). In Eq. (2) or (4) we cannot use the Fourier expansion as well, but decomposing the left hand side of these equations to \(d>-w\) and \(d<-w\) (again, we do not have a term with \(d=-w\) since we assume \(w\not \in \mathbb{Z }\)) gives

$$\begin{aligned} \sum _{d=-\infty }^{\infty }\frac{1}{(w+d)^{k}}=\zeta (k,a)+(-1)^{k}\zeta (k,1-a), \quad a=\{w\}. \end{aligned}$$
(6)

Here \(\zeta (s,v)\) denotes the Hurwitz zeta function, defined for \(\mathfrak R s>1\) and \(v>0\) by the series \(\sum _{n=0}^{\infty }\frac{1}{(n+v)^{s}}\).

Since the sum defining \(\wp _{\tau }^{(k-2)}(z)\) converges absolutely, we carry out the summation first on \(d\) and then on \(c\). We use Eq. (2) for \(c<\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\), (4) for \(c>\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\), and in case \(\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) is an integer we use Eq. (6) for \(c=\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) (we assume \(z \not \in L_{\tau }\)), where \(w=z-c\tau \). We use the classical notation \(q_{\tau }=\mathbf{e }(\tau )\) and \(q_{z}=\mathbf{e }(z)\), hence \(\mathbf{e }(mw)=q_{z}^{m}q_{\tau }^{-cm}\) and \(\mathbf{e }(-mw)=q_{\tau }^{cm}q_{z}^{-m}\) for any \(m\in \mathbb{N }\). These substitutions yield that

$$\begin{aligned} \frac{(-1)^{k}}{(k-1)!}\wp _{\tau }^{(k-2)}(z)=\sum _{c}\sum _{d}\frac{1}{ ((z-c\tau )-d)^{k}} \end{aligned}$$

equals

$$\begin{aligned} \frac{(-2\pi i)^{k}}{(k-1)!}\sum _{c<\frac{\mathfrak{I } z}{\mathfrak{I }\tau }}\sum _{m=1}^{\infty }m^{k-1}q_{z}^{m}q_{\tau }^{-cm}+\frac{(+2\pi i)^{k}}{(k-1)!}\sum _{c>\frac{\mathfrak{I } z}{\mathfrak{I }\tau }}\sum _{m=1}^{\infty }m^{k-1}q_{\tau }^{cm}q_{z}^{-m} \end{aligned}$$

(recall the value of \(w\)) plus a term appearing only if \(\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\in \mathbb{Z }\). Replacing \(m\) by \(-m\) in case \(c>\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) and noticing that the sign coming from \(m^{k-1}\) in this case and the sign difference between the coefficients \((-2\pi i)^{k}\) and \((+2\pi i)^{k}\) combine just to \(-1\) allows us to prove

Proposition 1

The function \(\frac{(-1)^{k}}{(k-1)!}\wp _{\tau }^{(k-2)}(z)\) equals

$$\begin{aligned} \delta \cdot (\zeta (k,a)+(-1)^{k}\zeta (k,1-a))+\frac{(-2\pi i)^{k}}{(k-1)!}\sum _{c\ne \frac{\mathfrak{I } z}{\mathfrak{I }\tau }}\sum _{m\rho >0}sgn(m)m^{k-1}q_{z}^{m}q_{\tau }^{-cm}, \end{aligned}$$

where \(\rho =\mathfrak{I }(z-c\tau )\). The coefficient \(\delta \) equals 1 if \(\mathfrak{I } z\) is an integral multiple \(c\) of \(\mathfrak{I }\tau \) (and then \(a=\{z-c\tau \}\) with \(z-c\tau \in \mathbb{R }{\setminus }\mathbb{Z })\), and vanishes otherwise.

The idea is that the expression in Proposition 1 shows that \(\wp _{\tau }^{(k-2)}\) is a lattice function. Indeed, we claim that both parts of this expression are invariant under both translations \(z \mapsto z+1\) and \(z \mapsto z+\tau \). \(q_{z}\) and \(\delta \) are invariant under \(z \mapsto z+1\) (the latter depends only on \(\mathfrak{I } z\)). Moreover, for \(\delta =1\) we use the same \(c\) so that the argument of the fractional value \(a\) is changed by an integer. Hence \(a\) is also invariant under this translation, and so is the expression in Proposition 1. As for \(z \mapsto z+\tau \), it takes \(\rho =\mathfrak{I }(z-c\tau )\) to \(\mathfrak{I }(z-(c-1)\tau )\), \(q_{z}^{m}q_{\tau }^{-cm}\) to \(q_{z}^{m}q_{\tau }^{-(c-1)m}\), and the condition \(c\ne \frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) to \(c\ne \frac{\mathfrak{I } z}{\mathfrak{I }\tau }+1\). Moreover, the quotients \(\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) and \(\frac{\mathfrak{I }(z+\tau )}{\mathfrak{I }\tau }\) differ by an additive integer, hence are integral together and the value of \(\delta \) is invariant under this translation. In addition, if \(\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) is an integer \(c\), then the integer \(\frac{\mathfrak{I }(z+\tau )}{\mathfrak{I }\tau }\) is \(c+1\), and the real numbers \(z+\tau -(c+1)\tau \) and \(z-c\tau \) coincide, whence the invariance of \(a\). Therefore replacing \(c\) by \(c+1\) throughout shows the invariance of the expression in Proposition 1 under this translation as well. This shows the ellipticity of \(\wp _{\tau }^{(k-2)}\), and the homogeneity property of \(\wp ^{(k-2)}\), namely

$$\begin{aligned} \wp _{\alpha L}^{(k-2)}(\alpha z)=\alpha ^{-k}\wp _{L}^{(k-2)}(z) \end{aligned}$$

for every lattice \(L\subseteq \mathbb{C }\), \(z\in \mathbb{C }\), and \(0\ne \alpha \in \mathbb{C }\), shows that \(\wp _{L}^{(k-2)}\) is an elliptic function for any lattice \(L\). Proposition 1 with \(k=3\) is related to the Fourier expansion of \(\wp _{\tau }^{\prime }(z)\) given in Proposition 3 of Section 3 in Chapter 4 of [2], from which one can also obtain the ellipticity of \(\wp _{\tau }^{\prime }\) (hence of \(\wp _{L}^{\prime }\) for any \(L\) by homogeneity).

For \(\wp _{L}^{(k-2)}\) we do not need these considerations, since its ellipticity is clear from its defining series. However, for \(\wp \) itself this property is not so obvious. Indeed, the ellipticity of \(\wp \) follows from that of \(\wp ^{\prime }\) and the fact that \(\wp \) is an even function of \(z\), but it is expedient to see (before we move on to the more complicated case of \(Z\)) how it can also be obtained using our argument. Specializing the definition of \(\wp _{L}(z)\) to \(L=L_{\tau }\) we obtain

$$\begin{aligned} \wp _{\tau }(z)=\frac{1}{z^{2}}+\sum _{(c,d)\ne (0,0)}\left( \frac{1}{ (z-(c\tau +d))^{2}}-\frac{1}{(c\tau +d)^{2}}\right) , \end{aligned}$$

and again we carry out the summation first over \(d\) and then over \(c\). Both parts of the sum converge, and we get

$$\begin{aligned} \wp _{\tau }(z)=\sum _{c\in \mathbb{Z }}\sum _{d\in \mathbb{Z }}\frac{1}{ (z-(c\tau +d))^{2}}-\sum _{c\in \mathbb{Z }}\sum _{d,(c,d)\ne (0,0)}\frac{1}{ (c\tau +d)^{2}}. \end{aligned}$$

The second sum is (by definition) the classical Eisenstein series \(G_{2}(\tau )\) (and is independent of \(z\)), and the first one can be evaluated as in the derivation of Proposition 1. We thus obtain

Proposition 2

The function \(\wp _{\tau }(z)\) equals

$$\begin{aligned} \delta \cdot (\zeta (2,a)+\zeta (2,1-a))+(-2\pi i)^{2}\sum _{c\ne \frac{\mathfrak{I } z}{\mathfrak{I }\tau }}\sum _{m\rho >0}sgn(m)mq_{z}^{m}q_{\tau }^{-cm}-G_{2}(\tau ), \end{aligned}$$

with \(\rho \), \(\delta \), and \(a\) bearing the same meaning as in Proposition 1.

The same argument used for the derivatives of \(\wp _{\tau }\) yields the ellipticity of \(\wp _{\tau }\), since the additional term \(G_{2}(\tau )\) is a constant, i.e., independent of \(z\). The homogeneity property

$$\begin{aligned} \wp _{\alpha L}(\alpha z)=\alpha ^{-2}\wp _{L}(z) \end{aligned}$$

for \(L\), \(z\), and \(\alpha \) as above shows the ellipticity of \(\wp _{L}\) for any \(L\), without using the parity of \(\wp _{L}\). We mention the existence of other forms of Fourier expansion of \(\wp _{\tau }(z)\)—see, for example Propositions 2 and 3 of Section 3 in Chapter 4 of [2]. From some of them (like the latter example here) the ellipticity of \(\wp _{\tau }\) (thus, by homogeneity, also of \(\wp _{L}\) for any \(L\)) can be deduced as with our argument.

The expression for \(G_{2}(\tau )\) is seen to be convergent by precisely the same method, yielding (using some symmetry conditions) the well-known Fourier expansion

$$\begin{aligned} G_{2}(\tau )=2\zeta (2)+2(2\pi i)^{2}\sum _{c=1}^{\infty }\sum _{m=1}^{\infty }mq_{\tau }^{cm}=\frac{\pi ^{2}}{3} -8\pi ^{2}\sum _{n}\sigma _{1}(n)q_{\tau }^{n} \end{aligned}$$

with \(\sigma _{1}(n)=\sum _{d|n}d\) (see, for example, Chapter 1 of [1]). The convergence properties of this expansion show that \(G_{2}\) is holomorphic (and also invariant under \(\tau \mapsto \tau +1\)), but no further properties are deduced at this point.

3 The Weierstrass zeta function

The above discussion serves well to illustrate how our method works, but it offers no obvious advantage because the standard derivation is just as simple. Here we demonstrate the usefulness of the technique by applying it to evaluate \(\eta _{\tau }\) directly (saving the contour integrals). The Legendre relation becomes just a simple corollary, rather than a tool in the proof.

We specialize \(Z_{L}(z)\) to \(L=L_{\tau }\) and obtain

$$\begin{aligned} Z_{\tau }(z)=\frac{1}{z}+\sum _{(c,d)\ne (0,0)}\left( \frac{1}{z-(c\tau +d)}+\frac{1}{c\tau +d}+\frac{z}{(c\tau +d)^{2}}\right) \end{aligned}$$
(7)

(which is known to be an absolutely convergent sum), and fix the following summation order: We sum first over \(d\) and then over \(c\), and for each index (\(c\) or \(d\)) we take first the value 0, and then the terms with \(d\) and \(-d\) (in the inner sum) or \(c\) and \(-c\) (in the outer sum) together. We then write \(Z_{\tau }(z)\) as the sum of three terms, each corresponding to one of the elements in the parentheses of Eq. (7). The first term becomes

$$\begin{aligned}&\frac{1}{z}+\sum _{f=1}^{\infty }\left( \frac{1}{z+f}+\frac{1}{z-f}\right) \nonumber \\&\quad +\sum _{ e=1}^{\infty }\left( \frac{1}{z+e\tau } +\sum _{f=1}^{\infty }\left( \frac{1}{z+e\tau +f }+\frac{1}{z+e\tau -f}\right) \right. \nonumber \\&\quad \left. +\frac{1}{z-e\tau }+\sum _{f=1}^{\infty }\left( \frac{1}{z-e\tau +f}+\frac{1}{ z-e\tau -f}\right) \right) , \end{aligned}$$
(8)

and similar expressions are obtained for the second and third terms.

We claim that the series in all three terms converge (in this order of summation). Indeed, the second term begins with \(\sum _{f=1}^{\infty }\left( \frac{1}{f}+\frac{1}{-f}\right) =0\) and continues with

$$\begin{aligned} \sum _{e=1}^{\infty }\left( \frac{1}{e\tau }+\sum _{f=1}^{\infty }\left( \frac{1}{ e\tau +f}+\frac{1}{e\tau -f}\right) +\frac{1}{-e\tau }+\sum _{f=1}^{\infty }\left( \frac{1}{-e\tau +f}+\frac{1}{-e\tau -f}\right) \right) \end{aligned}$$

which also vanishes. The third term yields directly \(zG_{2}(\tau )\). Therefore the series in Eq. (8) converges to \(Z_{\tau }(z)-zG_{2}(\tau )\), so that evaluating it explicitly gives an expression for \(Z_{\tau }(z)\).

Let us perform the evaluation. Note that the first part of Eq. (8) is just the left hand side of Eqs. (1), (3) or (5) for \(w=z\), and each \(e\) gives the sum of the left hand side of Eqs. (1), (3) or (5) with \(w=z+e\tau \) and with \(w=z-e\tau \). We thus substitute the right hand side of the corresponding equation (and value of \(w\)), and obtain expressions similar to those encountered in the proof of Propositions 1 and 2. However, there are two differences. First, for integral \(\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) we now have \(\pi \cot \pi a\) rather than the Hurwitz zeta function. Second, and more important, are the constants \(-\pi i\) in Eq. (1) and \(+\pi i\) in Eq. (3), which should be added to the power series in \(\mathbf{e }(\pm w)\). The part involving \(q_{z}\) and \(q_{\tau }\) converges as with \(\wp _{\tau }\) and its derivatives. It remains to verify that the constants also converge in the chosen order of summation. This follows from the fact that for \(e>\frac{|\mathfrak{I } z|}{\mathfrak{I }\tau }\), \(z+e\tau \) lies in \(\mathcal{H }\) and \(z-e\tau \) lies in \(\overline{\mathcal{H }}\), so that we use Eq. (1) for the first and Eq. (3) for the second, and the constants cancel. Hence for all but finitely many values of \(e\) the constants cancel, and the others give rise to some integral multiple of \(-\pi i\). This proves

Proposition 3

The equality

$$\begin{aligned} Z_{\tau }(z)=-t\pi i+\delta \cdot \pi \cot \pi a-2\pi i\sum _{c\ne \frac{\mathfrak{I } z}{\mathfrak{I }\tau }}\sum _{m\rho >0}sgn(m)q_{z}^{m}q_{\tau }^{-cm}+zG_{2}(\tau ) \end{aligned}$$

holds, where \(\rho \), \(\delta \), and \(a\) have the same meaning as in Propositions 1 and 2, and \(t\) is some (finite) integer depending on \(\tau \) and \(z\).

Indeed, as we have seen, a finite number of \(e\)-summands (possibly together with the one corresponding to \(e=0\)) involve a constant \(\mp \pi i\) from Eqs. (1) and (3). Recall that the contribution \(zG_{2}(\tau )\) of the third summands in Eq. (7) must also be included. We remark that Proposition 2 can be obtained directly from Proposition 3 by differentiation with respect to \(z\). This step requires some care: One should differentiate with respect to the real part, noting that \(\delta \) depends only on \(\mathfrak{I } z\) and, as Proposition 4 below shows, the same holds for \(t\)—this explains why \(\delta \) remains invariant and the term with \(t\) vanishes after taking the derivative. Similarly, one can deduce Proposition 1 by a \((k-2)\)-fold differentiation of the result of Proposition 2 with respect to \(z\). A Fourier expansion for \(Z_{\tau }(z)\), up to a factor which is linear in \(z\), appears in Equation 1 in Section 4 of Chapter 18 of [2] (and another formula appearing right after it), but this linear factor is written in terms of \(\eta _{\tau }(1)\), hence cannot be used alone for the evaluation of \(\eta _{\tau }(1)\).

It remains to find the value of the integer \(t\), where we recall that only \(e\le \frac{|\mathfrak{I } z|}{\mathfrak{I }\tau }\) should be considered in Eq. (8). For \(z\not \in \mathbb{R }\) the first sum (which does not involve \(e\)) contributes \(sgn(\mathfrak{I } z)\) to \(t\), while for \(z\in \mathbb{R }\) there is no contribution at all. Indeed, for \(\mathfrak{I } z>0\) we use Eq. (1) with the constant \(-\pi i\), for \(\mathfrak{I } z<0\) we employ Eq. (3) with \(+\pi i\) (recall that \(t\) is the coefficient of \(-\pi i\)), while Eq. (5), used for \(z\in \mathbb{R }\), provides no contribution to \(t\). For every \(e<\frac{|\mathfrak{I } z|}{\mathfrak{I }\tau }\) (this can be an empty set of integers, as is the case where \(-\mathfrak{I }\tau \le \mathfrak{I } z\le \mathfrak{I }\tau \)) both \(z+e\tau \) and \(z-e\tau \) have the same sign of imaginary part as \(z\), so that each such \(e\) contributes \(2sgn(\mathfrak{I } z)\) to \(t\). In the case where \(\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) is a non-zero integer we see that for the value \(e=\frac{|\mathfrak{I } z|}{\mathfrak{I }\tau }\) one summand gives real \(w\) (and no contribution to the constant) and the other gives a contribution of \(sgn(\mathfrak{I } z)\) to \(t\) as above. This is the basis of the proof of

Proposition 4

The integer \(t\) from Proposition 3 is given by

$$\begin{aligned} t=\left\lfloor \frac{\mathfrak{I } z}{\mathfrak{I }\tau }\right\rfloor +\left\lceil \frac{\mathfrak{I } z}{\mathfrak{I }\tau }\right\rceil . \end{aligned}$$

Proof

Write \(x=\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\), and we begin by assuming the \(x\) is not an integer. Then the number of \(e\)-summands which have a contribution of 2 is \(\lfloor |x|\rfloor \), so that the above argument yields \(t=(2\lfloor |x|\rfloor +1)sgn(x)\). For positive \(x\) this is just \(2\lfloor x \rfloor +1=\lfloor x \rfloor +\lceil x \rceil \) (\(x\) is not an integer, so that \(\lceil x \rceil =\lfloor x \rfloor +1\)). For negative \(x\) we write \(\lfloor -x\rfloor =-\lceil x \rceil \), so that \(-2\lfloor -x\rfloor -1=2\lceil x \rceil -1=\lfloor x \rfloor +\lceil x \rceil \) (we still assume \(x\not \in \mathbb{Z }\)). This shows that \(t\) has the asserted expression in this case. Next consider the case \(0 \ne x\in \mathbb{Z }\) is a nonzero integer. In this case the number of \(e\)-summands contributing 2 is \(|x|-1\) (since this is defined by a sharp inequality on \(e\)). An extra contribution of one comes from \(z\), and another one comes from \(e=|x|\), yielding \(t=2|x|sgn(x)=2x\). Since for integral \(x\) we have \(\lfloor x \rfloor =\lceil x \rceil =x\) this also agrees with the asserted expression. For \(x=0\) (i.e., real \(z\)) we have no constant contribution at all, and the value \(t=0\) is indeed the asserted expression for \(x=0\). This covers all the possible cases, hence proves the proposition. \(\square \)

Applying the identity \(\lfloor -x\rfloor =-\lceil x \rceil \) again shows that \(t=\left\lfloor \frac{\mathfrak{I } z}{\mathfrak{I }\tau }\right\rfloor -\left\lfloor \frac{-\mathfrak{I } z}{\mathfrak{I }\tau }\right\rfloor \), which has the advantage of using only the (more intuitive) lower integral value function. Moreover, it reflects better the fact that \(Z_{\tau }\) is an odd function of \(z\). However, only the equality in Proposition 4 will be used below.

We can now evaluate the lattice function \(\eta _{\tau }\) directly from Propositions 3 and 4, as given in the following

Theorem 5

The difference function \(\eta _{\tau }\) is given on the generators 1 and \(\tau \) of \(L_{\tau }\) by

$$\begin{aligned} \eta _{\tau }(1)=G_{2}(\tau ),\quad \eta _{\tau }(\tau )=\tau G_{2}(\tau )-2\pi i. \end{aligned}$$

For a general element \(\lambda =c\tau +d\) of \(L_{\tau }\) we have

$$\begin{aligned} \eta _{\tau }(c\tau +d)=(c\tau +d)G_{2}(\tau )-2\pi ic. \end{aligned}$$

Proof

We know that \(t\), \(\delta \), and also \(a\) if \(\delta =1\), depend only in \(\mathfrak{I } z\), and the sum in Proposition 3 depends on \(z\) only through \(q_{z}\). It follows that the translation \(z \mapsto z+1\) adds to \(Z_{\tau }(z)\) only \(G_{2}(\tau )\) from the last term. This proves the value of \(\eta _{\tau }(1)\). Turning to the translation \(z \mapsto z+\tau \), the sum is invariant by the usual summation index change argument, and the term with \(\delta \) and \(a\) is also invariant as above. On the other hand, \(t\) is increased by 2. Indeed, \(\frac{\mathfrak{I } z}{\mathfrak{I }\tau }\) increases by 1, hence so do the lower and upper integral values. Taking also the last summand into consideration, we obtain the asserted value of \(\eta _{\tau }(\tau )\). The expression for the general value \(\eta _{\tau }(c\tau +d)\) can be obtained the additivity of \(\eta _{\tau }\). Alternatively, we can deduce the general value directly from Propositions 3 and 4: the term with \(G_{2}(\tau )\) in Proposition 3 gives the first summand, the sum and \(\delta \) (and \(a\)) are invariant under any change \(z \mapsto z+\lambda \) for \(\lambda \in L_{\tau }\), and the value of \(t\) is increased by \(2c\). In this approach, the values of \(\eta _{\tau }(1)\) and \(\eta _{\tau }(\tau )\) are just special cases of the general formula.\(\square \)

We recall the homogeneity property of \(Z\), which implies a similar property for \(\eta \), namely

$$\begin{aligned} Z_{\alpha L}(\alpha z)=\alpha ^{-1}Z_{L}(z),\quad \eta _{\alpha L}(\alpha \lambda )=\alpha ^{-1}\eta _{L}(\lambda ) \end{aligned}$$

for \(L\), \(z\), and \(\alpha \) as above and \(\lambda \in L\). Combining this with Theorem 5 implies that for a general lattice \(L=\mathbb{Z }w_{1}\oplus \mathbb{Z }w_{2}\) normalized such that \(\tau =\frac{w_{1}}{w_{2}}\) is in \(\mathcal{H }\), we have

$$\begin{aligned} \eta _{L}(w_{2})=\frac{G_{2}(\tau )}{w_{2}},\quad \eta _{L}(w_{1})=\frac{\tau G_{2}(\tau )-2\pi i}{w_{2}}. \end{aligned}$$

This is so since \(L=w_{2}L_{\tau }\). We therefore obtain

Corollary 6

The Legendre relation holds:

$$\begin{aligned} w_{1}\eta _{L}(w_{2})-w_{2}\eta _{L}(w_{1})=+2\pi i. \end{aligned}$$

Substituting the value of \(\tau \) in the expressions for \(\eta _{L}(w_{1})\) and \(\eta _{L}(w_{2})\) proves Corollary 6 immediately. Alternatively, Corollary 6 for the special case of the lattice \(L=L_{\tau }\) with the basis \(w_{2}=1\) and \(w_{1}=\tau \) follows immediately from Theorem 5, and then the homogeneity property of \(\eta _{L}\), compensated by the (trivial) homogeneity of the coefficients, extends the validity of Corollary 6 to any lattice \(L\) with a normalized basis. We remark that in [2] (as well as in other references dealing with the function \(\eta _{\tau }\)), one first uses integration in order to obtain the Legendre relation in Corollary 6, then one evaluates (by more difficult means) \(\eta _{\tau }(1)\), and only then the value of \(\eta _{\tau }(\tau )\) (hence of \(\eta _{\tau }(\lambda )\) for any \(\lambda \in L_{\tau }\)) can be obtained. In our approach, one derives all the values of \(\eta _{\tau }(\lambda )\) at once, and Corollary 6 is established by a simple substitution.

4 Quasi-modularity of \(G_{2}\)

At this point, all we know about the Eisenstein series \(G_{2}\) is that it is holomorphic and invariant under \(\tau \mapsto \tau +1\). We now use its relation with \(\eta _{\tau }\) and the homogeneity of the latter to obtain its quasi-modular behavior under the action of \(SL_{2}(\mathbb{Z })\).

Theorem 7

If the matrix \(M=\left( {\begin{array}{c}a\ \ b\\ c\ \ d\end{array}}\right) \) is in \(SL_{2}(\mathbb{Z })\) then we have

$$\begin{aligned} G_{2}\left( \frac{a\tau +b}{c\tau +d}\right) =(c\tau +d)^{2}G_{2}(\tau )-2\pi ic(c\tau +d). \end{aligned}$$

Proof

The complex numbers \(w_{1}=a\tau +b\) and \(w_{2}=c\tau +d\) are clearly elements of \(L_{\tau }\), and the generators \(\tau \) and 1 of \(L_{\tau }\) can be written as \(dw_{1}-bw_{2}\) and \(aw_{2}-cw_{1}\) respectively (since \(ad-bc=1\)). Moreover, the quotient \(\frac{w_{1}}{w_{2}}=\frac{a\tau +b}{c\tau +d}\) (which we write as \(M\tau \)) has imaginary part \(\frac{\mathfrak{I }\tau }{|c\tau +d|^{2}}\) (again since \(ad-bc=1\)). Hence \(L_{\tau }=\mathbb{Z }w_{1}\oplus \mathbb{Z }w_{2}\), and this is a normalized basis, and \(M\tau \in \mathcal{H }\). We then write \(L_{\tau }\) as \((c\tau +d)L_{M\tau }\), and using the general formula in Theorem 5 and the homogeneity property of \(\eta _{L}\) we obtain the equality

$$\begin{aligned} (c\tau +d)G_{2}(\tau )-2\pi ic=\eta _{\tau }(c\tau +d)=\frac{\eta _{M\tau }(1)}{c\tau +d}=\frac{G_{2}(M\tau )}{ c\tau +d}. \end{aligned}$$

After multiplication by \(c\tau +d\), this proves the theorem.\(\square \)

Note that this proof does not require knowing that if the asserted relation holds for two matrices \(M\) and \(N\) then it holds for their product. Moreover, it is independent of the fact that \(\left( {\begin{array}{c}1\ \ 1\\ 0\ \ 1\end{array}}\right) \) and \(\left( {\begin{array}{c}0\ \ -1\\ 1\ \ \ \ 0\end{array}}\right) \) generate \(SL_{2}(\mathbb{Z })\), and even of the fact that \((M,\tau )\mapsto \frac{a\tau +b}{c\tau +d}\) (for \(M\) as above) defines an action of \(SL_{2}(\mathbb{Z })\) on \(\mathcal{H }\). The invariance under \(\tau \mapsto \tau +1\) already mentioned above is just the case \(M=\left( {\begin{array}{c}1\ \ 1\\ 0\ \ 1\end{array}}\right) \) in Theorem 7.