Kronecker's limit formula, holomorphic modular functions and $q$-expansions on certain moonshine groups

For any square-free integer $N$ such that the"moonshine group"$\Gamma_0(N)^+$ has genus zero, the Monstrous Moonshine Conjectures relate the Hauptmoduli of $\Gamma_0(N)^+$ to certain McKay-Thompson series associated to the representation theory of the Fischer-Griess monster group. In particular, the Hauptmoduli admits a $q$-expansion which has integer coefficients. In this article, we study the holomorphic function theory associated to higher genus moonshine groups $\Gamma_0(N)^+$. For all moonshine groups of genus up to and including three, we prove that the corresponding function field admits two generators whose $q$-expansions have integer coefficients, has lead coefficient equal to one, and has minimal order of pole at infinity. As corollary, we derive a polynomial relation which defines the underlying projective curve, and we deduce whether $i\infty$ is a Weierstrass point. Our method of proof is based on modular forms and includes extensive computer assistance, which, at times, applied Gauss elimination to matrices with thousands of entries, each one of which was a rational number whose numerator and denominator were thousands of digits in length.

1. Introduction 1.1.Classical aspects of Klein's j-invariant.The action of the discrete group PSL(2, Z) on the hyperbolic upper half plane H yields a quotient space PSL(2, Z)\H which has genus zero and one cusp.By identifying PSL(2, Z)\H with a well-known fundamental domain for the action of PSL(2, Z) on H, we will, as is conventional, identify the cusp of PSL(2, Z)\H with the point denoted by i∞.From the uniformization theorem, we have the existence of a single-valued meromorphic function on PSL(2, Z)\H which has a simple pole at i∞ and which maps the one-point compactification of PSL(2, Z)\H onto the one-dimensional projective space P 1 .Let z denote the global coordinate on H, and set q = e 2πiz , which is a local coordinate in a neighborhood of i∞ in the compactification of PSL(2, Z)\H.The bi-holomorphic map f from the compactification of PSL(2, Z)\H onto P 1 is uniquely determined by specifying constants c −1 = 0 and c 0 such that the local expansion of f near i∞ is of the form f (q) = c −1 q −1 + c 0 + O(q) as q → 0. For reasons coming from the theory of automorphic forms, one chooses c −1 = 1 and c 0 = 744.The unique function obtained by setting of c −1 = 1 and c 0 = 744 is known as Klein's j-invariant, which we denote by j(z). Let One defines the holomorphic Eisenstein series E k of even weight k ≥ 4 by the series Classically, it is known that which yields an important explicit expression for the j-invariant.As noted on page 90 of [30], which is a point we will emphasize in the next subsection, the j-invariant admits the series expansion j(z) = 1 q + 744 + 196884q + 21493760q 2 + O(q 3 ) as q → 0. (3) An explicit evaluation of the coefficients in the expansion (3) was established by Rademacher in [28], and we refer the reader to the fascinating article [20] for an excellent exposition on the history of the j-invariant in the setting of automorphic forms.More recently, there has been some attention on the computational aspects of the Fourier coefficients in (3); see, for example, [2] and, for the sake of completeness, we mention the monumental work in [7] with its far reaching vision.
For quite some time it has been known that the j-invariant has importance far beyond the setting of automorphic forms and the uniformization theorem as applied to PSL(2, Z)\H.For example, in 1937 T. Schneider initiated the study of the transcendence properties of j(z).Specifically, Schneider proved that if z is a quadratic irrational number in the upper half plane then j(z) is an algebraic integer, and if z is an algebraic number but not imaginary quadratic then j(z) is transcendental.More specifically, if z is any element of an imaginary quadratic extension of Q, then j(z) is an algebraic integer, and the field extension Q[j(z), z]/Q(z) is abelian.In other words, special values of the j-invariant provide the beginning of class field theory.The seminal work of Gross-Zagier [12] studies the factorization of the j-function evaluated at imaginary quadratic integers, yielding numbers known as singular moduli, from which we have an abundance of current research which reaches in various directions of algebraic and arithmetic number theory.
There is so much richness in the arithmetic properties of the j-invariant that we are unable to provide an exhaustive list, but rather ask the reader to accept the above-mentioned examples as indicating the important role played by Klein's j-invariant in number theory and algebraic geometry.
1.2.Monstrous moonshine.Klein's j-invariant attained another realm of importance with the discovery of "Monstrous Moonshine".We refer to the article [9] for a fascinating survey of the history of monstrous moonshine, as well as the monograph [10] for a thorough account of the underlying mathematics and physics surrounding the moonshine conjectures.At this point, we offer a cursory overview in order to provide motivation for this article.
In the mid-1900's, there was considerable research focused toward the completion of the list of sporadic finite simple groups.In 1973, B. Fischer and R. L. Griess discovered independently, but simultaneously, certain evidence suggesting the existence of the largest of all sporadic simple groups; the group itself was first constructed by R. L. Griess in [13] and is now known as "the monster", or "the friendly giant", or "the Fischer-Griess monster", and we denote the group by M. Prior to [13], certain properties of M were deduced assuming its existence, such as its order and various aspects of its character table.At that time, there were two very striking observations.On one hand, A. Ogg observed that the set of primes which appear in the factorization of the order of M is the same set of primes such that the discrete group Γ 0 (p) + has genus zero.On the other hand, J. McKay observed that the linear-term coefficient in (3) is the sum of the two smallest irreducible character degrees of M. J. Thompson further investigated McKay's observation in [32] and [33], which led to the conjectures asserting all coefficients in the expansion (3) are related to the dimensions of the components of a graded module admitting action by M. Building on this work, J. Conway and S. Norton established the "monstrous moonshine" conjectures in [5] which more precisely formulated relations between M and Klein's j-invariant (3).A graded representation for M was explicitly constructed by I. Frenkel, J. Lepowsky, and A. Meurman in [8] thus proving aspects of the McKay-Thompson conjectures from [32] and [33].Building on this work, R. Borcherds proved a significant portion of the Conway-Norton "monstrous moonshine" conjectures in his celebrated work [3].More recently, additional work by many authors (too numerous to list here) has extended "moonshine" to other simple groups and other j-invariants associated to certain genus zero Fuchsian groups.
Still, there is a considerable amount yet to be understood within the framework of "monstrous moonshine".Specifically, we call attention to the following statement by T. Gannon from [9]: In genus > 0, two functions are needed to generate the function field.A complication facing the development of a higher-genus Moonshine is that, unlike the situation in genus 0 considered here, there is no canonical choice for these generators.
In other words, one does not know the analogue of Klein's j-invariant for moonshine groups of genus greater than zero from which one can begin the quest for "higher genus moonshine".1.3.Our main result.The motivation behind this article is to address the above statement by T. Gannon.The methodology we developed yields the following result, which is the main theorem of the present paper.
Theorem 1.For any square-free N , let Γ 0 (N ) + denote the "moonshine group" which is obtained by adding the Atkin-Lehner involutions to the congruence subgroup Γ 0 (N ).Then the function field associated to every genus one, genus two, and genus three moonshine group admits two generators whose q-expansions have integer coefficients after the lead coefficient has been normalized to equal one.Moreover, the orders of poles of the generators at i∞ are at most g + 2.
In all cases, the generators we compute have the minimal poles possible, as can be shown by the Weierstrass gap theorem.Finally, as an indication of the explicit nature of our results, we compute a polynomial relation associated to the underlying projective curve.For all moonshine groups of genus two and genus three, we deduce whether i∞ is a Weierstrass point.
In brief, our analysis involves four steps.First, we establish an integrality theorem which proves that if a holomorphic modular function f on Γ 0 (N ) + admits a q-expansion of the form f (z) = q −a + k>−a c k q k , then there is an explicitly computable κ such that if c k ∈ Z for k ≤ κ then c k ∈ Z for all k.Second, we prove the analogue of Kronecker's limit formula, resulting in the construction of a non-vanishing holomorphic modular form ∆ N on Γ 0 (N ) + ; we refer to ∆ N as the Kronecker limit function.Third, we construct spaces of holomorphic modular functions on Γ 0 (N ) + by taking ratios of holomorphic modular forms whose numerators are holomorphic Eisenstein series on Γ 0 (N ) + and whose denominator is a power of the Kronecker limit function.Finally, we employ considerable computer assistance in order to implement an algorithm, based on the Weierstrass gap theorem and Gauss elimination, to derive generators of the function fields from our spaces of holomorphic functions.By computing the q-expansions of the generators out to order q κ , the integrality theorem from the first step completes our main theorem.
1.4.Additional aspects of the main theorem.There are ways in which one can construct generators of the function fields associated to the moonshine groups, two of which we now describe.However, the methodology does not provide all the information which we developed in the proof of our main theorem.
Classically, one can use Galois theory and elementary aspects of the moonshine group in order to form modular functions using Klein's j-invariant.In particular, the functions v|N j(vz) and v|N j(vz) generate all holomorphic functions which are Γ 0 (N ) + invariant and, from (3), admit q-expansions with lead coefficients equal to one and all other coefficients are integers.However, the order of poles at i∞ are much larger than g + 2.
From modern arithmetic algebraic geometry, we have another approach toward our main result.We shall first present the argument, which was first given to us by an anonymous reader of a previous draft of the present article, and then discuss how our main theorem goes beyond the given argument.
The modular curve X 0 (N ) exists over Z, is nodal, and its cusps are disjoint Z-valued points.For all primes p dividing N , the Atkin-Lehner involutions w p of X 0 (N ) commute with each other and generate a group G N of order 2 r .Let X 0 (N ) + = X 0 (N )/G N , and let c denote the unique cusp of X 0 (N ) + .The cusp can be shown to be smooth over Z; moreover, all the fibers of X 0 (N ) + over Spec(Z) are geometrically irreducible.Therefore, the complement U of Spec(Z) in X 0 (N ) + is affine.The coordinate ring O N (U ) is a finitely generated Z-algebra, with an increasing filtration by sub-Z-modules O N (U ) k consisting of the functions with a pole of order at most k along the cusp c.The successive quotients O N (U ) k /O N (U ) k−1 are free Z-modules, each with rank either zero or one.The k for which the rank is zero form the gap-sequence of X 0 (N ) + Q , the generic fiber of X 0 (N ) + .If k is not a gap, there is a non-zero element f k ∈ O N (U ) k , unique up to sign and addition of elements from O N (U ) k−1 .The q-parameter is obtained by considering the formal parameter at c, which is the projective limit of the sequence of quotients (O N /I n )(X 0 (N ) + ) where I is the ideal of c.The projective limit is naturally isomorphic to the formal power series ring Z [[q]].With all this, if f is any element of O N (U Q ), then there is an integer n such that nf has q-expansion in Z((q)).In other words, the function field of X 0 (N ) + Q can be generated by two elements whose q-expansions are in Z((q)).Returning to our main result, we can discuss the information contained in our main theorem which goes beyond the above general argument.The above approach from arithmetic algebraic geometry yields generators of the function field with poles of small order with integral q-expansion; however, it was necessary to "clear denominators" by multiplying through by the integer n, thus allowing for the possibility that the lead coefficient is not equal to one.In the case that X 0 (N ) + has genus one, then results which are well-known to experts in the field (though there is no specific reference, we refer to [4] for an exposition) may be used to show that the generators satisfy an integral Weierstrass equation; see, in particular, Definition 2.4, Theorem 2.8 and the proof of Corollary 2.9.However, these arguments do not apply to the genus two and genus three cases which we exhaustively analyzed.Furthermore, we found that our result holds in all cases when N is square-free, independent of the structure of the gap sequence at i∞; see, [21].As we found, for genus two i∞ was not a Weierstrass point for any N ; however, for genus three, there were various types of gap sequences for different levels N .Further details of these findings will be mentioned in later sections in the present article and described in detail in [19].
Finally, given all of the above discussion, one naturally is led to the following conjecture.
Conjecture 2. For any square-free N , the function field associated to any positive genus g moonshine group Γ 0 (N ) + admits two generators whose q-expansions have integer coefficients after the lead coefficient has been normalized to equal one.Moreover, the orders of poles of the generators at i∞ are at most g + 2.
1.5.Our method of proof.Let us now describe our theoretical results and computational investigations in greater detail.
For any square-free integer N , the subset of SL(2, R) defined by is an arithmetic subgroup of SL(2, R), which, as discussed in [16], we call a moonshine group.As shown in [6], there are precisely 44 such moonshine groups which have genus zero and 38, 39, and 31 which have genus one, two, and three, respectively.These groups of genus up to three will form a considerable portion of the focus in this article.
There are two reasons for focusing on the groups Γ 0 (N ) + for square-free N .First, for any positive integer N , the groups Γ 0 (N ) + are of moonshine-type (see, e.g., Definition 1 from [9]).Second, should N not be square-free, then there exist genus zero groups Γ 0 (N ) + , namely when N = 25, 49 and 50, but those groups correspond to "ghost" classes of the monster.In summary, we are paying attention to the known results from "monstrous moonshine".For arbitrary square-free N , the discrete group Γ 0 (N ) + has one-cusp, which we denote by i∞.Associated to the cusp of Γ 0 (N ) + one has, from spectral theory and harmonic analysis, a well-defined non-holomorphic Eisenstein series denoted by E ∞ (z, s).The real analytic Eisenstein series E ∞ (z, s) is defined for z ∈ H and Re(s) > 1 by where Γ ∞ (N ) is the parabolic subgroup of Γ 0 (N ) + .Our first result is to determine the Fourier coefficients of E ∞ (z, s) in terms of elementary arithmetic functions, from which one obtains the meromorphic continuation of the real analytic Eisenstein series E ∞ (z, s) to all s ∈ C.
As a corollary of these computations, it is immediate that E ∞ (z, s) has no pole in the interval (1/2, 1).Consequently, we prove that groups Γ 0 (N ) + have no residual spectrum besides the obvious one at zero.
Using our explicit formulas for the Fourier coefficients of E ∞ (z, s), we are able to study the special values at s = 1 and s = 0, which, of course, are related by the functional equation for E ∞ (z, s).As a result, we arrive at the following generalization of Kronecker's limit formula.For any square-free N which has r prime factors, the real analytic Eisenstein series E ∞ (z, s) admits a Taylor series expansion of the form where η(z) is Dedekind's eta function associated to PSL(2, Z).From the modularity of E ∞ (z, s), one concludes that v|N |η(vz)| 4 (Im(z)) 2 r is invariant with respect to the action by Γ 0 (N ) + .Consequently, there exists a multiplicative character ε N (γ) on Γ 0 (N ) + such that one has the identity We study the order of the character, and we define ℓ N to be the integer so that ε ℓN N = 1.A priori, it is not immediate that ℓ N is finite for general N .Classically, when N = 1, the study of the character ε 1 on PSL(2, Z) is the beginning of the theory of Dedekind sums; see [24].For general N , we prove that ℓ N is finite and, furthermore, can be evaluated by the expression where lcm(•, •) denotes the least common multiple function and σ(N ) stands for the sum of divisors of N .
With the above notation, we define the Kronecker limit function ∆ N (z) associated to Γ 0 (N ) + to be and we let k N denote the weight of ∆ N .By combining ( 5) and ( 6), we get that k N = 2 r−1 ℓ N .In summary, ∆ N (z) is a non-vanishing, weight k N holomorphic modular form with respect to Γ 0 (N ) + .
Analogous to the setting of PSL(2, Z), one defines the holomorphic Eisenstein series of even weight k ≥ 4 associated to Γ 0 (N ) + by the series We show that one can express E (N ) 2m in terms of E 2m , the holomorphic Eisenstein series associated to PSL(2, Z); namely, for m ≥ 2 one has the relation With the above analysis, we are now able to construct holomorphic modular functions on the space Γ 0 (N ) + \H.For any non-negative integer M , the function is a holomorphic modular function on Γ 0 (N ) + \H, meaning a weight zero modular form with polynomial growth near i∞.The vector b = (b ν ) can be viewed as a weighted partition of the integer k N M with weights m = (m ν ) formed by the weights, in the sense of modular forms, of the holomorphic Eisenstein series.For considerations to be described below, we let S M denote the set of all possible rational functions defined in (9) by varying the vectors b and m yet keeping M fixed.Trivially, S 0 consists of the constant function {1}, which is convenient to include in our computations.
Dedekind's eta function can be expressed by the well-known product formula, namely 24 where q = e 2πiz with z ∈ H, and the holomorphic Eisenstein series associated to PSL(2, Z) admits the q-expansion where B k denotes the k-th Bernoulli number and σ is the generalized divisor function It is immediate that each function F b in (9) admits a q-expansion with rational coefficients.However, it is clear that such coefficients are certainly not integers and, actually, can have very large numerators and denominators.Indeed, when combining (8) and (10), one gets that q + O(q 2 ), as q → 0.
which, evidentially, can have a large denominator when m and N are large.In addition, note that the function in ( 9) is defined with a product of holomorphic Eisenstein series in the numerators, so the rational coefficients in the q-expansion of (9) are even farther removed from being easily described.
With the above theoretical background material, we implement the algorithm described in section 7.3 to find a set of generators for the function field associated to the genus g moonshine group Γ 0 (N ) + .In addition to the theoretical results outlined above, we obtain the following results which are based on our computational investigations.
(1) For all genus zero moonshine groups, the algorithm concludes successfully, thus yielding the q-expansion of the Hauptmoduli.In all such cases, the q-expansions have positive integer coefficients as far as computed.
The computations were completed for all 44 different genus zero moonshine groups Γ 0 (N ) + .(2) For all genus one moonshine groups, the algorithm concludes successfully, thus yielding the q-expansions for two generators of the associated function fields.In all such cases, each q-expansion has integer coefficients as far as computed.The computations were completed for all 38 different genus one moonshine groups Γ 0 (N ) + .The function whose q-expansion begins with q −2 is the Weierstrass ℘-function in the coordinate z ∈ H for the underlying elliptic curve.(3) For all 38 different genus one moonshine groups, we computed a cubic relation satisfied by the two generators of the function fields.
(4) In addition, we consider all moonshine groups of genus two and three.In every instance, the algorithm concludes successfully, yielding generators for the function fields whose q-expansions admit integer coefficients as far as computed.Only for the function field generators on X 510 an additional base change becomes necessary.(5) We extend all q-expansions out to order q κ , where κ is given in Tables 1 and 2 or evaluated according to Remark 6, thus showing that the field generators have integer q-expansions.
The fact that all of the q-expansions which we uncovered have integer coefficients is not at all obvious and leads us to believe there is deeper, so-far hidden, arithmetic structure which perhaps can be described as "higher genus moonshine".
In some instances, the computations from our algorithm were elementary and could have been completed without computer assistance.For instance, when N = 5 or N = 6, the first iteration of the algorithm used a set with only two functions to conclude successfully.However, as N grew, the complexity of the computations became quite large.As an example, for N = 71, which is genus zero and appears in "monstrous moonshine", the smallest non-zero weight for a denominator in (9) was 4, but we needed to consider all functions whose numerators had weight up to 40, resulting in 362 functions whose largest pole had order 120.The most computationally extensive genus one example was N = 79 where the smallest non-zero weight denominator in (9) was 12, but we needed to consider all functions whose numerator had weight up to 84, resulting in 13, 158 functions whose largest pole had order 280.
As one can imagine, the data associated to the q-expansions we considered is massive.In some instances, we encountered rational numbers whose numerators and denominators each occupied a whole printed page.In addition, in the cases where the algorithm required several iterations, the input data of q-expansions of all functions were stored in computer files which if printed would occupy hundreds of thousands of pages.As an example of the size of the problem we considered, it was necessary to write computer programs to search the output from the Gauss elimination to determine if all coefficients of all q-expansions were integers since the output itself, if printed, would occupy thousands of pages.
The computational results are summarized in sections 8, 9 and 10.In Table 5, Table 7, and Table 9, we list the q-expansions of the two generators of function fields associated to each genus one, genus two, and genus three moonshine group.As T. Gannon's comment suggests, the information summarized in those tables does not exist elsewhere.In Table 6, Table 8, and Table 10, we list the polynomial relations satisfied by the generators of Table 5, Table 7, and Table 9, respectively.The stated results, in particular the q-expansions, were limited solely by space considerations; a thorough documentation of our findings will be given in forthcoming articles.
We will supplement the dissemination of our study as summarized in the present article by making available the computer programs as well as input and output data supporting the statements we present here.In other words: We will make available all input and output information and computer programs associated to the computational investigations undertaken in the present article.1.6.Further studies.As stated above, Klein's j-invariant can be written in terms of holomorphic Eisenstein series associated to PSL (2, Z).By storing all information from the computations from Gauss elimination, we obtain similar expressions for the Hauptmoduli for all genus zero moonshine groups.As one would imagine based upon the above discussion, some of the expressions will be rather large.In [17], we will report of this investigation, which in many instances yields new relations for the j-invariants and for holomorphic Eisenstein series themselves.For the genus one groups, the computations from Gauss elimination produce expressions for the Weierstrass ℘-function, in the coordinate on H, in terms of holomorphic Eisenstein series; these computations will be presented in [18].Finally, in [19], we will study higher genus examples, and in some instances compute the projective equation of the underlying algebraic curve.1.7.Outline of the paper.In section 2, we will establish notation and recall various background material.In section 3, we prove that if a certain number of coefficients in the q-expansions of the generators are integers, then all coefficients are integers.In section 4, we will compute the Fourier expansion of the non-holomorphic Eisenstein series associated to Γ 0 (N ) + .The generalization of Kronecker's limit formula for moonshine groups is proven in section 5, including an investigation of its weight and the order of the associated Dedekind sums.In section 6, we relate the holomorphic Eisenstein series associated to Γ 0 (N ) + to holomorphic Eisenstein series on PSL(2, Z), as cited above.Further details regarding the algorithm we develop and implement are given in section 7. Results of our computational investigations are given in section 8 for genus zero, section 9 for genus one, and section 10 for genus two and genus three.Finally, in section 11, we offer concluding remarks and discuss directions for future study, most notably our forthcoming articles [17], [18], and [19].
1.8.Closing comment.The quote we presented above from [9] indicates that "higher genus moonshine" has yet to have the input from which one can search for the type of mathematical clues that are found in McKay's observation involving the coefficients of Klein's j-invariant or in Ogg's computation of the levels of all genus zero moonshine groups and their appearance in the prime factorization of the order of the Fischer-Griess monster M. It is our hope that someone will recognize some patterns in the q-expansions we present in this article, as well as in [17], [18], and [19], and then, perhaps, higher genus moonshine will manifest itself.

Background material
2.1.Preliminary notation.Throughout we will employ the standard notation for several arithmetic quantities and functions, including: The generalized divisor function σ a , Bernoulli numbers B k , the Möbius function µ, and the Euler totient function ϕ, the Jacobi symbol p d , the greatest common divisor function (•, •), and the least common multiple function lcm(•, •).Throughout the paper we denote by {p i }, i = 1, . . ., r, a set of distinct primes and by N = p 1 • • • p r a square-free, positive integer.
The convention we employ for the Bernoulli numbers follows [34] which is slightly different than [30] although, of course, numerical evaluations agree when following either set of notation.For a precise discussion, we refer to the footnote on page 90 of [30].
2.2.Certain moonshine groups.As stated above, H denotes the hyperbolic upper half plane with global variable z ∈ C with z = x + iy and y > 0, and we set q = e 2πiz = e(z).
The subset of SL(2, R), defined by is an arithmetic subgroup of SL(2, R), called moonshine group.We denote by Γ 0 (N ) Basic properties of Γ 0 (N ) + , for square-free N are derived in [16] and references therein.In particular, we use that the surface X N = Γ 0 (N ) + \H has exactly one cusp, which can be taken to be at i∞.Let g N denote the genus of X N .

Function fields and modular forms.
The set of meromorphic functions on X N is a function field, meaning a degree one transcendental extension of C. If g N = 0, then the function field of X N is isomorphic to C(j) where j is a single-valued meromorphic function on X N .If g N > 0, then the function field of X N is generated by two elements which satisfy a polynomial relation.
A meromorphic function f on H is a weight 2k meromorphic modular form if we have the relation In other language, the differential The product, resp.quotient, of weight k 1 and weight k 2 meromorphic forms is a weight each holomorphic modular form admits a Laurent series expansion which, when setting q = e 2πiz , can be written as As is common in the mathematical literature, we consider forms such that c m = 0 whenever m < m 0 for some m 0 ∈ Z.If c m0 = 0, the function f frequently will be re-scaled so that c m0 = 1 when c m = 0 for m < m 0 ; the constant m 0 is the order of the pole of f at i∞.
If X N has genus zero, then by the Hauptmoduli j N for X N one means the weight zero holomorphic form which is the generator of the function field on X N .If g N > 0, then we will use the notation j 1;N and j 2;N to denote two generators of the function field.
Unfortunately, the notation of hyperbolic geometry writes the local coordinate on H as x + iy, and the notation of the algebraic geometry of curves uses x and y to denote the generators of the function field under consideration; see, for example, page 31 of [25].We will follow both conventions and provide ample discussion in order to prevent confusion.

Integrality of the coefficients in the q-expansion
In this section we prove that integrality of all coefficients in the q-expansion of the Hauptmodul j N when g N = 0 and the generators j 1;N and j 2;N when g N > 0 can be deduced from integrality of a certain finite number of coefficients.Also, our proof yields an effective bound on the number of coefficients needed to test for integrality.First, we present a proof in the case when genus is zero, followed by a proof for the higher genus setting which is a generalization of the genus zero case.The proof is based on the property of Hecke operators and Atkin-Lehner involutions.We begin with a simple lemma.Lemma 3.For any prime p which is relatively prime to N , let T p denote the unscaled Hecke operator which acts on Γ 0 (N ) invariant functions f , If f is a holomorphic modular form on Γ 0 (N ) + , then T p (f ) is also a holomorphic modular form on Γ 0 (N ) + . Proof.
Theorem 4. Let j N be the Hauptmodul for a genus zero moonshine group Γ 0 (N ) + .Let p 1 and p 2 with p 2 > p 1 be distinct primes which are relatively prime to N .If the q-expansion of j N contains integer coefficients out to order q κ for some κ ≥ (p 2 /(p 2 − 1)) • (p 1 p 2 ) 2 , then all further coefficients in the q-expansion of j N are integers.
Proof.Let c k denote the coefficient of q k in the q-expansion of j N .Let m > κ be arbitrary integer.Assume that c k is an integer for k < m, and let us now prove that c m is an integer.To do so, let us consider the Γ 0 (N ) + invariant functions T p1 (j r1 N )(z) and T p2 (j r2 N )(z) for specific integers r 1 and r 2 depending on m which are chosen as follows.First, take r 1 to be the unique integer such that r 1 ≡ (m + 1) mod p 1 and 1 ≤ r 1 ≤ p 1 .We now wish to choose r 2 to be the smallest positive integer such that r 2 ≡ (m + 1) mod p 2 with r 2 ≥ 1 and (r 1 p 1 , r 2 p 2 ) = 1.
Let us argue in general the existence of r 2 and establish a bound in terms of p 1 and p 2 , noting that for any specific example one may be able to choose r 2 much smaller than determined by the bound below.
Since p 1 and p 2 are primes and 1 ≤ r 1 ≤ p 1 < p 2 , we have that (p 2 , r 1 p 1 ) = 1.By applying the Euclidean algorithm and Bezout's identity, there exists an r ≥ 1 such that rp 2 ≡ 1 mod r 1 p 1 .Choose A be the smallest positive integer such that A ≡ r 2 − (m + 1)r mod r 1 p 1 and Clearly, r 2 ≡ (m + 1) mod p 2 and, furthermore In particular, r 1 p 1 and r 2 p 2 are relatively prime, and we have the bounds r 1 p 1 ≤ p 2 1 and r 2 p 2 ≤ p 2 1 p 2 2 .With the above choices of r 1 and r 2 , set f 1 = j r1 N and f 2 = j r2 N .The function f 1 is a Γ 0 (N ) + invariant modular function with pole of order r 1 at i∞.Therefore, there is a polynomial P r1,p1 (x) of degree r 1 p 1 such that If we write the q-expansion of f 1 as The coefficients b k are determined by the binomial theorem and the coefficients of j N , namely by By assumption, c 1 , . . ., c m−1 are integers, and m − 1 From this, we conclude that b −r1 , . . ., b m−r1 are integers.In particular, all coefficients of T p1 (f 1 )(z) out to order q 0 are integers, from which we can compute the coefficients of P r1,p1 and conclude that the polynomial P r1,p1 has integer coefficients, in particular the lead coefficient is one.
Let us determine the first appearance of the coefficient c m in T p1 (f 1 ).First, the smallest k where c m appears in the formula for b k is when k = m + 1 − r 1 , and then we have that b m+1−r1 = r 1 c m + an integer determined by binomial coefficients and c k for k < m.
By our choice of r 1 , the index m + 1 − r 1 is positive and divisible by p 1 .As a result, the first appearance of c m in the expansion of T p1 (f 1 ) is within the coefficient of q d where d = (m + 1 − r 1 )/p 1 .Going further, we have that the coefficient of q d for d = (m + 1 − r 1 )/p 1 in the expansion of T p1 (f 1 ) is of the form p 1 r 1 c m plus an integer which can be determined by binomial coefficients and c k for k < m.
Let us now determine the first appearance of c m in P r1,p1 (j N ).Again, by the binomial theorem, we have that c m first appears as a coefficient of q e where e = m − r 1 p 1 + 1.By the choice of m and r 1 , since p 1 < p 2 , one has that The above inequality is equivalent to in other words, d < e.As a consequence, we have that the coefficient of q d in P r1,p1 (j N ) can be written as a polynomial expression involving binomial coefficients and c k for k < m.By induction, the coefficient of q d in P r1,p1 (j N ) is an integer.In summary, by equating the coefficients of q d where d = (m+1−r 1 )/p 1 in the formula (12), on the left-hand-side we get an expression of the formula r 1 p 1 c m plus an integer, and on the right-hand-side we get an integer.Therefore, c m is a rational number whose denominator is a divisor of r 1 p 1 .
Let us now consider T p2 (j r2 N ).Since m + 1 − r 2 is divisible by p 2 , we consider the coefficient of q d ′ where d ′ = (m + 1 − r 2 )/p 2 .By the choice of m and r 2 , recalling that r 2 ≤ p 2 1 p 2 , we have With all this, we conclude, analogously as in the first case that c m is a rational number whose denominator is a divisor of r 2 p 2 .However, r 1 p 1 and r 2 p 2 are relatively prime, hence c m is an integer.By induction on m, the proof of the theorem is complete.
Theorem 5. Let Γ 0 (N ) + have genus greater than zero, and assume there exists two holomorphic modular functions j 1;N and j 2;N which generate the function field associated to Γ 0 (N ) + .Furthermore, assume that the q-expansions of j 1;N and j 2;N are normalized in the form Let p 1 and p 2 with p 2 > p 1 be distinct primes which are relatively prime to a 1 a 2 N .Assume the q-expansions of j 1;N and j 2;N contain integer coefficients out to order q κ with κ ≥ a 2 (p 2 /(p 2 − 1)) • (p 1 p 2 ) 2 .Then all further coefficients in the q-expansions of j 1;N and j 2;N are integers.
Proof.The argument is very similar to the proof of Theorem 4. Let c l;k denote the coefficient of q k in the qexpansion of j l;N , l ∈ {1, 2}.Assume that c l;k is an integer for l ∈ {1, 2} and k < m, and let us prove that c 1;m and c 2;m are integers.For i, l ∈ {1, 2}, we study the expression T pi (j ri l;N )(z) = (j l;N (z)) ripi + Q i,l (j 1;N , j 2;N ).(13) for certain polynomials Q i,l of two variables.The left-hand-side of the above equation has a pole at i∞ of order a l p i r i .Hence The existence of Q i,l (x, y) follows from the assumption that j 1;N and j 2;N generate the function field associated to Γ 0 (N ) + and the observation that T pi (j ri l;N ) − (j l;N ) ripi is Γ 0 (N ) + invariant and has a pole of order less than a l r i p i .Of course, the polynomials Q i,l are not unique since j 1;N and j 2;N satisfy a polynomial relation.This does not matter.We introduce the following canonical choice in order to uniquely determine the polynomials.Consider the coefficient b i,l;n1,n2 .If there exist non-negative integers n ′ 1 and n ′ 2 such that a 1 < n 1 then we set b i,l;n1,n2 equal to zero.Integrality of coefficients of j 1;N and j 2;N out to order q κ with κ ≥ a 2 (p 2 /(p 2 − 1)) • (p 1 p 2 ) 2 implies that all coefficients of T pi (j ri l;N )(z) out to order q 0 are integers.The coefficient b i,l;n1,n2 of the polynomial Q i,l (x, y) first appears on the right-hand-side of (13) as a coefficient multiplying q −(n1a1+n2a2) .The canonical choice of coefficients enables us to deduce, inductively in the degree ranging from −a l r i p i + 1 to zero that all coefficients b i,l;n1,n2 are integers.
Having established that the coefficients of the polynomials Q i,l are integers, now we wish to determine two values r 1 and r 2 so that the coefficient c 1;m first appears in T pi (j ri 1;N )(z) as a factor of q d for the smallest possible d, which leads to determining r i from the equation m − (r i − 1)a 1 ≡ 0 mod p i .Such a solution exists provided p 1 and p 2 are relatively prime to a 1 .Without loss of generality, we may assume that 1 ≤ r 1 ≤ p 1 .As in the proof of Theorem 4, we impose the further condition that (r 1 p 1 , r 2 p 2 ) = 1.For at least one value of r 2 in the range 1 ≤ r 2 ≤ r 1 p 1 p 2 , we have that m − (r 2 − 1)a 1 ≡ 0 mod p 2 and r 2 p 2 ≡ 1 mod r 1 p 1 , so, in particular, (r With the above choices of r 1 , we determine the first appearance of c 1;m in the equation (j 1;N , j 2;N ).On the left-hand-side, c 1;m appears as a coefficient of q d where d = (m − (r 1 − 1)a 1 )/p 1 , and, in fact, the coefficient of q d is equal to an integer plus r 1 p 1 c 1;m .On the right-hand-side, c 1;m first appears as a coefficient of q e where e = m − a 1 (r 1 p 1 − 1).We have that d < e when m > m ′ where The resulting expression shows that c 1;m can be expressed as a fraction, where the numerator is a finite sum involving integer multiples of positive powers of c 1;k and c 2;k for k < m and denominator equal to r 1 p 1 .Similarly, by studying the first appearance of c 1;m in the expression T p2 (j r2 1;N )(z) = (j 1;N (z)) r2p2 + Q 2,1 (j 1;N , j 2;N ), we obtain an expression showing that c 1;m can be expressed as a fraction, where the numerator is a finite sum involving integer multiples of positive powers of c 1;k and c 2;k for k < m and denominator equal to r 2 p 2 .By induction on m, and that (r 1 p 1 , r 2 p 2 ) = 1, we conclude that c 1;m is an integer.
Analogously, one studies c 2;m .In the four different equations studied, the minimum number of coefficients needed to be integers in order to initiate the induction is the smallest integer that is larger than or equal to a 2 (p 2 /(p 2 − 1))(p 1 p 2 ) 2 , which is assumed to hold in the premise of the theorem.Remark 6.Let us now describe, then implement, an algorithm which will reduce the number of coefficients which need to be tested for integrality.For this remark alone, let us set Let m be the lower bound determined in Theorem 4 and Theorem 5. Let p 1 , • • • , p k be the set of primes less than m which are relatively prime to a 1 a 2 N .For each prime, let r i,l be the integer in the range 1 ≤ r i,l ≤ p i satisfying m − (r i,l − 1)a l ≡ 0 mod p i , l ∈ {1, 2}.Let S m,l denote the set of triples Note that if r i,l is such that a l (r i,l (p i + 1) − 1) ≥ m, then the set S m,l does not contain a triple whose prime is Assume that the greatest common divisor of all elements in R m,1 is one and that of R m,2 is also one.Then, by using all the Hecke operators T pi applied to the functions j ri,1+jpi 1;N and j ri,2+jpi 2;N and the arguments from Theorem 4 and Theorem 5, we can determine c 1;m and c 2;m from lower indexed coefficients and show that c 1;m and c 2;m are integers if all lower indexed coefficients are integers.
Although the above observation is too cumbersome to employ theoretically, it does lead to the following algorithm which can be implemented.
(1) Let m be the lower bound given in Theorem 4 for g = 0 or Theorem 5 for g > 0.
(2) Construct the sets S m,l and R m,l , as described above.
(3) If the greatest common divisor of all elements in R m,1 is one and that of R m,2 is one, too, then replace m by m − 1 and repeat with Step 2. (4) If the greatest common divisor of all elements of R m,1 or R m,2 is greater than one, let κ = m.
The outcome of this algorithm yields a reduced number κ of coefficients which need to be tested for integrality in order to conclude that all coefficients are integers.
In Tables 1 and 2 we list the level N and improved bounds on κ which were determined by the above algorithm for all genus zero and genus one moonshine groups.

The Fourier coefficients of the real analytic Eisenstein series
In this section we derive formulas for coefficients in the Fourier expansion of the real analytic Eisenstein series E ∞ (z, s).First, we derive an intermediate result, expressing the Fourier coefficients in terms of Ramanujan sums.Then, we compute coefficients in a closed form.
Proof.The Fourier expansion (14) of the real analytic Eisenstein series E ∞ (z, s) for Re(s) > 1 is a special case of [14], Theorem 3.4., when the surface has only one cusp at i∞ with identity scaling matrix.By ϕ N (s) we denote the scattering matrix, evaluated in [16] as where .
If C N denotes the set of positive left-lower entries of matrices from Γ 0 (N ) + , then, by [14], Theorem 3.4.The Fourier coefficients of ( 14) are given by where S N denotes the Kloosterman sum (see [14], formula (2.23)) defined, for c ∈ C N , as In [16] we proved that This is a Ramanujan sum, which can be evaluated using formula (3.3) from [15], page 44 to get .
For n ∈ N element c = (N/ √ v)n belongs to C N if and only if v | N and (n, v) = 1, hence equation ( 16) becomes , which proves (15).

Computation of Fourier coefficients.
In this subsection we will compute coefficients (15) in closed form.We will assume that m > 0 and incorporate negative terms via the identity ϕ N (−m, s) = ϕ N (m, s).Let p and q to denote prime numbers, and let α p ∈ Z ≥0 denote the highest power of p that divides m, i.e. the number α p is such that p αp | m and p αp+1 ∤ m.For any prime p, set Theorem 8. Assume N is square-free and let ϕ N (m, s) denote the m-th coefficient in the Fourier series expansion (14) of the Eisenstein series.Then the coefficients ϕ N (m, s) can be meromorphically continued from the half plane Re(s) > 1 to the whole complex plane by the equation Proof.We employ the equation ( 15) and observe that coefficients a m (n) are multiplicative.Therefore, it is natural to investigate the associated L-series defined for Re(s) > 1.The series L m (s) is defined in [22], Lemma 2.2 for Re(s) > 1, where its analytic continuation to the whole complex plane is given by the formula The multiplicativity of coefficients a m (n) implies that for Re(s) > 1 one has the Euler product where E p (m, s) stands for the p-th Euler factor, i.e.
By the computations presented in [22], page 1137, one has Let v | N be fixed.In order to compute the sum using equation (19), we use the fact that N is square-free, so (v, N/v) = 1, hence every integer n coprime to v can be represented as q nq • k, where n q ≥ 0, (k, v) = 1 and (k, q) = 1 for all q | (N/v).(20) Since (k, v) = 1 and (k, q) = 1 for every q | (N/v), we deduce that actually (k, N ) = 1.Therefore Let q 1 , . . ., q l denote the set of all prime divisors of N/v.The multiplicativity of coefficients a m implies that for n given by ( 20) one has hence, by (21) one gets that The identity ( 19) is now applied to the inner sum in the above equation, from which we deduce that a m (q For all ν = 1, . . ., l one then has a m (q a m (q by (18).Therefore, ( Substituting ( 22) into (15) completes the proof.Furthermore, for a prime p and m ∈ Z >0 where α p ∈ Z ≥0 is the highest power of p dividing m.
Proof.We apply induction on number r of prime factors of N .For r = 1 the statement is immediate.Assume that the statement is true for all numbers N with r distinct prime factors and let N = the statement is easily deduced from the definition of D N (m, s) and the inductive assumption.
The second statement follows trivially from the properties of the function σ s (m) and the definition of the Euler factor F p .
Proof.From Lemma 7 with m = 0, we have a formula for the constant term ϕ N (s) in the Fourier expansion of the real analytic Eisenstein series, namely see also Lemma 5 of [16].It is elementary to see that ϕ N (s) has no poles in the interval (1/2, 1).From the spectral theory, one has that the residual eigenvalues λ of the hyperbolic Laplacian such that λ ∈ (0, 1/4) correspond to poles s of the real analytic Eisenstein series with s ∈ (1/2, 1) with the relation s(1 − s) = λ.Since poles of real analytic Eisenstein series E ∞ (z, s) are exactly the poles of ϕ N (s), the statement is proved.
5. Kronecker's limit formula for Γ 0 (N ) + In this section we derive Kronecker's limit formula for the Laurent series expansion of the real analytic Eisenstein series.First, we will prove the following, intermediate result.
Proposition 11.For a square-free integer N = r ν=1 p ν , we have the Laurent expansion )(e(mz) + e(−mz)) + O(s − 1), (23) as s → 1, where Proof.We start with the formula ( 14) for the Fourier expansion of real analytic Eisenstein series at the cusp i∞.
Let ϕ denote the scattering matrix for PSL(2, Z).Then, one has ϕ N (s) = ϕ(s)D N (s).We will use this fact in order to deduce the first two terms in the Laurent series expression of E ∞ (z, s) around s = 1.
By the classical Kronecker limit formula for PSL(2, Z) the Laurent series expansion of ϕ(s)y 1−s at s = 1 is given by (see e.g.[23], page 228) where In order to get the residue and the constant term steaming from ϕ N it is left to compute values of D N and D ′ N at s = 1, and This, together with (14) and Theorem 8 completes the proof.
Since the series E ∞ (z, s) always has a pole at s = 1 with residue 1/ Vol(X N ), from the above proposition, we easily deduce a simple formula for the volume of the surface X N in terms of the level of the group, namely Theorem 12.For a square-free integer N = r ν=1 p ν , we have the asymptotic expansion Proof.From the definition of Euler factors F p (m, s), using the fact that σ −1 (m) = σ(m) m , we get that σ(p αp ) p αp .Therefore, a simple computation implies that where we put P (i 1 , . . ., i k ) = 1 for k = 0, and for k = 1, . . ., r ) − 1 σ(p ) .
Every m ≥ 1 can be written as m = p α1 1 • • • p αr r • l, where α i ≥ 0 and (l, N ) = 1.Therefore, we may write the sum over m in (23) as as deduced from the proof of the classical PSL(2, Z) Kronecker limit formula.Now, we will take k ∈ {1, . . ., r} and compute one term in the sum (24).Without loss of generality, in order to ease the notation, we may assume that i 1 = 1, . . ., i k = k and compute the term with P (1, . . ., k).Later, we will take the sum over all indices 1 ≤ i 1 < . . .< i k ≤ r.First, we observe that P (1, . . ., k) = 0 if α i = 0, for any i ∈ 1, . . ., k and Since every integer m ≥ 1 can be represented as m = p α1−1 by (25).
Let us now sum over all k = 0, . . ., r and the sum over all indices 1 ≤ i 1 < . . .< i k ≤ r, which is equivalent to taking the sum over all v | N .The sum (24) then becomes since v|N v = σ(N ).Therefore, we get that The proof is complete.
Remark 13.Since the number of divisors of is a geometric mean.
When N = 1, Theorem 12 amounts to the classical Kronecker limit formula.
From Theorem 12 and functional equation for real analytic Eisenstein series we can reformulate the Kronecker limit formula as asserting an expansion for E ∞ (z, s) as s → 0. Proposition 14.For z ∈ H, the real analytic Eisenstein series E ∞ (z, s) admits a Taylor series expansion of the form An immediate consequence of Theorem 12 and the above proposition is the fact that the function is invariant under the action of the group Γ 0 (N ) + .Using the fact that the eta function is non-vanishing on H, we may deduce the stronger statement.
Proposition 15.There exists a character ε N (γ) on Γ 0 (N ) + such that Since the expression ( 26) is a group invariant we have Dividing by Im(z) = 0 and raising the expression to the 2 r /4 power, we get that for some function f of absolute value 1.
Since the function η is a holomorphic function, non-vanishing on H, for a fixed γ ∈ Γ 0 (N ) + the function f (γ, z) is a holomorphic function in z on H of absolute value 1 on H, hence it is constant, as a function of z.Therefore, , for all γ 1 , γ 2 ∈ Γ 0 (N ) + .This is an immediate consequence of formula (27).
The character ε N (γ) is the analogue of the classical Dedekind sum.In the case when the genus of the surface X N is equal to zero, the group Γ 0 (N ) + is a free product of finite, cyclic groups, hence the character ε N (γ) is finite in the sense that there exists an integer ℓ N such that ε N (γ) ℓN = 1 for all γ ∈ Γ 0 (N ) + .
Irrespective of the genus of the surface X N , we will prove that the character ε N (γ) is a certain 24th root of unity.
Then, the function Proof.The vanishing of the function ∆ N (z) at the cusp i∞ only is an immediate consequence of properties of the Dedekind eta function.Therefore, it is left to prove that ∆ N (z) is a weight k N = 2 r−1 ℓ N holomorphic form on Γ 0 (N ) + .
Let τ = aτ bτ cτ dτ ∈ Γ 0 (N ) + \ {Id} be an arbitrary element of order two.Then there exists z τ ∈ H such that τ z τ = z τ and τ 2 = Id, where Id stands for the identity.Obviously, ∆ N (τ z τ ) = ∆ N (z τ ).From Proposition 15 we have that In order to complete the proof of the theorem, it is left to prove that ε N (γ) ℓN = 1, for an arbitrary γ = * * c d ∈ Γ 0 (N ).For this, we apply results of [29], chapter 2.2.3, pages 21-23 with f 1 = ∆ N ; g = 2 r−1 ; δ l = v, r δ l = ℓ N , for all δ l = v and k = k N .By the definition of ℓ N , we see that ℓ N σ(N ) ≡ 0 mod 24, therefore, conditions (2.11) and (2.12) of [29] are fulfilled, so then where v d denotes the Jacobi symbol.The multiplicativity of the Jacobi symbol implies that , Table 3.The degree ℓ N and the weight k N of the modular form ∆ N on Γ 0 (N ) + for all moonshine groups of genus zero.Listed are the level N , and the values of degree ℓ N and weight k N .
since k N is even.The proof is complete.
In Tables 3 and 4 we list the values of degree ℓ N and weight k N for all genus zero and genus one moonshine groups.
6. Holomorphic Eisenstein series on Γ 0 (N ) + In the classical Γ 0 (1) = PSL(2, Z) case, holomorphic Eisenstein series of even weight k ≥ 4 are defined by formula (1).Modularity is an immediate consequence of the definition.We proceed analogously in the moonshine case and define for even k ≥ 4 modular forms by (7).The following proposition relates k (z) be the modular form defined by (7).Then, for all even k = 2m ≥ 4 and all z ∈ H one has where E k is defined by (1).
Proof.Taking e ∈ {v : v | N } in the definition (11) of the moonshine group we see that where . Now, we use the fact that N is square-free to deduce that for a fixed v 1 | N we have Therefore, for a fixed v 1 | N we have that Multiplying the above equation by v and taking the sum over all v 1 | N we get u1 , it is easy to see that v ranges over all divisors of N , as u 1 runs through divisors of v 1 and u 2 runs through divisors of N/v 1 .
Furthermore, for fixed v 1 , v | N there exists a unique pair (u 1 , u 2 ) of positive integers such that Reasoning in this way, we see that By the definition of the function σ m (N ) the above equation is equivalent to (28), which completes the proof.

Searching for generators of function fields
With the above analysis, we are now able to define holomorphic modular functions on the space X N = Γ 0 (N ) + \H.
7.1.q-expansions.According to Theorem 16, the form ∆ N has weight k N , and its q-expansion is easily obtained from inserting the product formula of the classical ∆ function This allows us to get the q-expansion for any power of ∆ N , including negative powers.
Similarly, the q-expansion of the holomorphic Eisenstein series E (N ) k is obtained from the q-expansion of the classical Eisenstein series E k .Using the notation of [34], we write where B k stands for the k-th Bernoulli number (e.g.−8/B 4 = 240; −12/B 6 = −504, etc.).From (28) we deduce 7.2.Subspaces of rational functions.Now it is evident that for any positive integer M , the function is a holomorphic modular function on Γ 0 (N ) + \H, meaning a weight zero modular form with polynomial growth near i∞.Its q-expansion follows from substituting E (N ) k and ∆ N by their q-expansions.Let S M denote the set of all possible rational functions defined in (9) for all possible vectors b = (b ν ) and m = (m ν ) with fixed M .Our rationale for finding a set of generators for the function field of the smooth, compact algebraic curve associated to X N is based on the assumption that a finite span of S = ∪ K M=0 S M contains the set of generators for the function field.Subject to this assumption, the set of generators follows from a base change.The base change is performed as follows.
(1) Form the matrix A S of coefficients from the q-expansions of all elements of S, where each element in S is expanded along a row with each column containing the coefficient of a power, negative, zero or positive, of q.The expansion is recorded out to order q κ .(2) Apply Gauss elimination to A S , thus producing a matrix B S which is in row-reduced echelon form.
(3) Implement the following decision to determine if the algorithm is complete: If the g lowest non-trivial rows at the bottom of B S correspond to q-expansions whose lead terms have precisely g gaps in the set {q −1 , . . ., q −2g }, then the algorithm is completed.If the indicator to stop fails, then replace M by M + 1, S by S M ∪ S and reiterate the algorithm.
We described the algorithm with choice of an arbitrary κ.For reasons of efficiency, we initially selected κ to be zero, so that all coefficients for q ν for ν ≤ κ are included in A S , but finally increased κ to its desired value according to Remark 6.
The rationale for the stopping decision in Step 3 above is based on two ideas, one factual and one hopeful.First, the Weierstrass gap theorem states that for any point P on a compact Riemann surface there are precisely g gaps in the set of possible orders from 1 to 2g of functions whose only pole is at P .For the main considerations of this paper, we study g ≤ 3.For instance, when g = 1 there occurs exactly one gap which for topological reasons is always {q −1 }.Second, for any genus, the assumption which is hopeful is that the function field is generated by the set of holomorphic modular functions defined in (9), which is related to the question of whether the ring of holomorphic modular forms on Γ 0 (N ) + is generated by holomorphic Eisenstein series and the Kronecker limit function.The latter assumption is not obvious, but it has turned out to be true for all moonshine groups Γ 0 (N ) + that we have studied so far.This includes in particular all moonshine groups of genus zero, genus one, genus two, and genus three.7.4.Implementation notes.We have implemented C code that generates in integer arithmetic the set S = ∪ k M=0 S M of all possible rational functions defined in (9) for any given positive integer K and any square-free level N .The set S is passed in symbolic notation to PARI/GP [27] which computes in rational arithmetic the q-expansions of all elements of S up to any given positive order κ and forms the matrix A S .Theoretically, we could have used PARI/GP for the Gauss elimination of A S .However, for reasons of efficiency, we have written our own C code, linked against the GMP MP library [11], to compute the Gauss elimination in rational arithmetic.The result is a matrix B S whose rows correspond to q-expansions with rational coefficients.Inspecting the rational coefficients of B S , we find that the denominators are 1, i.e. after Gauss elimination the coefficients turn out to be integers.All computations are in rational arithmetic, hence are exact.
After the fact, we select κ as in Tables 1 and 2 in case when genus is zero or one, or compute κ as explained in Remark 6 when genus is bigger than one, and extend the q-expansions of the field generators out to order q κ .Inspecting the coefficients we find that they are integer which proves that the field generators have integer q-expansions.
It is important that we compute the Gauss elimination with a small value of κ first, and extend the q-expansions for the field generators out to the larger number κ according to Remark 6, later.There are two reasons for this: (i) It would be a waste of resources to start with a large value of κ.Once the Gauss elimination is done with a small value of κ, it is easy to extend the q-expansions out to a larger value of κ using reverse engineering of the Gauss elimination.(ii) If the genus is larger than one, we do not know the gap sequence for the field generators in advance.We can determine a 1 and a 2 , and hence κ according to Remark 6 only if we have completed the Gauss elimination with some other positive value of κ before.
Every function f k with k = 1, . . ., 11 can be written as a polynomial in f 12 .For example, f 11 = f 2 12 − 14.Further relations are easily derived.
As stated, the j-invariant, also called the Hauptmodul, is the unique holomorphic modular function with simple pole at z = i∞.For Γ 0 (17) + , the Hauptmodul is given by j 17 = f 12 (z).It is remarkable that the q-expansion for j 17 has integer coefficients, especially when considering how we obtained j 17 .
In the case when the surface X N has genus equal to zero, q-expansions of Hauptmoduls j N coincide with McKay-Thompson series for certain classes of the monster M. Therefore, we were able to compare results obtained using the algorithm explained above with well known expansions that may be found e.g. at [31].All expansions were computed out to order q κ and they match with the corresponding expansions of McKay-Thompson series available at [31].
The successful execution of our algorithm in the genus zero case, besides direct check of the correctness of the algorithm provides two additional corollaries.First, the j-invariant is expressed as a linear combination of elements from the set S M , for some M , thus showing that the Hauptmoduli can be written as a rational function in holomorphic Eisenstein series and the Kronecker limit function, thus generalizing (2).Second, since the function field associated to the underlying algebraic curve is generated by the j-invariant, we conclude that all holomorphic modular forms on X N are generated by a finite set of holomorphic Eisenstein series and a power of the Kronecker limit function, again generalizing a classical result for PSL(2, Z).A complete analysis of these two results for all genus zero moonshine groups will be given in [17].

Genus one
The smallest N such that Γ 0 (N ) + has genus one is N = 37.In that example, the Kronecker limit function is ∆ 37 (z) = ∆(z)∆(37z), which has weight 12.After four iterations, the algorithm completes successfully.However, S 4 consists of 434 functions, and this set contains functions whose pole at i∞ has order as large as 76.For instance, the function F (48) (z) = E (37) 48 (z)/∆ 4 37 (z) is in S 4 , and the first few terms in the q-expansion of F (48) are In the setting of genus one, there is no holomorphic modular function with a simple pole at i∞.However, there does exist a holomorphic modular function with an order two pole at i∞, which is equal to the Weierstrass ℘-function.We let j 1;N denote the ℘-function for Γ 0 (N ) + .Also, let j 2;N denote the holomorphic modular function with a third order pole at i∞.In the coordinates of the complex plane, j 2;N is the derivative of j 1;N .However, in the coordinate of the upper half plane, either z or q, one will not have that j 2;N is the derivative of j 1;N , as can be seen by the chain rule from one variable calculus.In all cases, the functions j 1;N and j 2;N generate the function field of the underlying elliptic curve.
In Table 5, we list the generators of the function field of the underlying algebraic curve for all 38 genus one moonshine groups Γ 0 (N ) + .In some instances, the computations behind Table 5 were quite intensive.For N = 79, the Kronecker limit function has weight 12, and we needed seven iterations of the algorithm.When considering all functions whose numerator had weight up to 84, the set S 8 had 13, 158 functions, and the orders of the pole at i∞ was as large as 280.As N became larger, the size of the denominators of the rational coefficients in the q-expansions for S grew very large, in some cases becoming thousands of digits in length.Nonetheless, we have computed q-expansions of generators of the function field in all 38 genus one cases out to order q κ where κ is listed in Table 2.The exact arithmetic of the program and successful completion of the algorithm, together with Theorem 5 yields the following result.
For each genus one moonshine group, the two generators j 1;N and j 2;N of the function field have integer qexpansions.
If we set x = j 1;37 and y = j 2;37 , then it can be shown that j 1;37 and j 2;37 satisfy the cubic relation In Table 6 we present the list of cubic relations satisfied by j 1;N and j 2;N for all genus one moonshine groups.
As in the genus zero setting, there are two important consequences of the successful implementation of our algorithm.First, the functions j 1;N and j 2;N can be expressed as linear combinations of elements in S M for some M .In particular, the Weierstrass ℘-function j 1;N can be written in terms of certain holomorphic Eisenstein series and powers of the Kronecker limit function.The same assertion holds for j 2;N .Second, since j 1;N and j 2;N generate the function field, we conclude that all holomorphic modular forms can be written in terms of certain holomorphic Eisenstein series and the Kronecker limit functions.A full documentation of these results will be given in [18].As it turned out, for all moonshine groups of genus two and for all but four moonshine groups of genus three, the gap sequence consists of {q −1 , . . ., q −g }, and i∞ was not a Weierstrass point.For Γ 0 (109) + , Γ 0 (151) + and Γ 0 (179) + , the gap sequence consists of {q −1 , q −2 , q −4 } and for Γ 0 (282) + the gap sequence consists of {q −1 , q −2 , q −5 }.For the latter four groups, i∞ is a Weierstrass point.
We list in Tables 7 to 10 the q-expansions of the generators as well as the algebraic relation satisfied by the generators.
In [19] we will provide a thorough discussion of our findings in the setting of higher genus moonshine groups, including expressions for the function field generators in terms of holomorphic Eisenstein series, relations satisfied by holomorphic Eisenstein series, further q-expansions, and the special role of level N = 510.Table 10.Polynomial relation satisfied by x = j 1;N and y = j 2;N for the genus three moonshine groups Γ 0 (N ) + .For N = 510, we give the polynomial relation satisfied by v = y + x and w = y − x, instead.In a few words, we can express a response to the problem posed by T. Gannon which we quoted in the introduction.The generators of the function fields associated to X N which one should consider are given by the two invariant holomorphic functions whose poles at i∞ have the smallest possible orders and with initial q-expansions which are normalized by the criteria of row-reduced echelon form.

N
The above statement when applied to all the moonshine groups we considered produced generators with integer q-expansions, except for the level N = 510 where a further base change was necessary.The cases we considered include all moonshine groups Γ 0 (N ) + with squarefree N of genus up to three.
In other articles, we will present further results related to the material presented here.Specifically, in [17], we study further details regarding genus zero moonshine groups.In particular, for each level, we list the generators of the ring of holomorphic forms as well as relations for the Hauptmodul and Kronecker limit functions in terms of holomorphic Eisenstein series.Similar information for genus one moonshine groups is studied in [18], as well as additional aspects of the "arithmetic of the moonshine elliptic curves".

For a fixed
c = (N/ √ v)n ∈ C N , with v | N and n ∈ N arbitrary, we can take e = v in the definition of Γ 0 (N ) + to deduce that matrices from Γ 0 (N ) + with left lower entry c are given by √ a, b and d such that vad − (N/v)bn = 1.Since N is square-free, this equation has a solution if and only if (v, n) = 1 and (d, (N/v)n) = 1.Therefore, for m ∈ Z \ {0}, and fixed c = (N/ √ v)n ∈ C N equation (17) becomes

Table 1 .
Number of expansion coefficients that need to be integer in order that all coefficients in the q-expansion of the Hauptmodul are integer.Listed is the level N and the value of κ according to Remark 6 for the genus zero moonshine groups Γ 0 (N ) + .

Table 2 .
Number of expansion coefficients that need to be integer in order that all coefficients in the q-expansions of the field generators are integer.Listed is the level N and the value of κ according to Remark 6 for the genus one moonshine groups Γ 0 (N ) + .