An inverse Jacobian algorithm for Picard curves

We study the inverse Jacobian problem for the case of Picard curves over C\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$${\mathbb {C}}$$\end{document}. More precisely, we elaborate on an algorithm that, given a small period matrix Ω∈C3×3\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$$\varOmega \in {\mathbb {C}}^{3\times 3}$$\end{document} corresponding to a principally polarized abelian threefold equipped with an automorphism of order 3, returns a Legendre–Rosenhain equation for a Picard curve with Jacobian isomorphic to the given abelian variety. Our method corrects a formula obtained by Koike–Weng (Math Comput 74(249):499–518, 2005) which is based on a theorem of Siegel. As a result, we apply the algorithm to obtain equations of all the isomorphism classes of Picard curves with maximal complex multiplication by the maximal order of the sextic CM-fields with class number at most 4\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$$4$$\end{document}. In particular, we obtain the complete list of maximal CM Picard curves defined over Q\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$${\mathbb {Q}}$$\end{document}. In the appendix, Vincent gives a correction to the generalization of Takase’s formula for the inverse Jacobian problem for hyperelliptic curves given in [Balakrishnan–Ionica–Lauter–Vincent, LMS J. Comput. Math., 19(suppl. A):283-300, 2016].


Introduction
Let J be the map from the set M g of isomorphism classes of algebraic curves of genus g defined over C to the set A g of isomorphism classes of complex principally polarized abelian varieties of dimension g. In this context, the inverse Jacobian problem consists of identifying a model of the preimage via J of the class of a given principally polarized abelian variety, if it exists. This is a classic result in the case of curves of genus 1, and has also been solved for curves of genus 2 [26,36] and genus 3 [2,7,14,34,38,39].
In this paper we present an inverse Jacobian algorithm for the family of Picard curves. This was initially done by Koike and Weng in [14], but their exposition presents some gaps and mistakes that we fix here.
In Sect. 2 we give a formula to approximate the x-coordinates of the affine branch points of a Picard curve in terms of theta constants of its Jacobian, see Theorem 3. The given formula differs from the result in [14] by a third root of unity, see Remark 1.
In Sect. 3 we first characterize the image under J of this family of curves, and then develop the algorithm that takes the Jacobian of a Picard curve C and returns a Legendre-Rosenhain equation for C, see Algorithm 5. The main step of the algorithm is applying the formula of Theorem 3, so we first identify the objects needed to apply said formula, mainly the Riemann constant and the images by the Abel-Jacobi map of the affine branch points. Our algorithm makes the process of identifying these points explicit in Theorem 4, see Remark 3 for a comparison with the approach of [14].
Our correction of the algorithm allows us to re-obtain the results of [14] and extend the list of known maximal CM Picard curves, that is, Picard curves such that their Jacobians have endomorphism ring isomorphic to the maximal order of a sextic CM number field K . We obtain twenty-three new curves, displayed in Sect. 4, among which we include all maximal CM Picard curves defined over Q. The corresponding CM-fields are collected from [23]. The computations have been performed using SageMath [35], and an implementation can be found at [31].
In the appendix, Vincent applies the tools introduced in Sect. 2 to correct a sign in the generalization of Takase's formula for the inverse Jacobian problem for hyperelliptic curves, given in [2].
The present paper is an extension and clarification of our earlier work [16] to include further improvements of the algorithm, such as Theorem 4.

A Thomae-like formula for Picard curves
Let C be a Picard curve defined over C, that is, a genus-3 smooth, plane, projective curve given by the affine equation y 3 = f (x) where f is a polynomial of degree 4. The curve C has an automorphism ρ of order 3 given by (x, y) → (x, z 3 y) with z 3 = exp 2π i 3 . This automorphism fixes the affine branch points (t, 0) with f (t) = 0. The curve C has a unique point at infinity, with projective coordinates (0 : 1 : 0), which is also fixed by the automorphism ρ.
Up to isomorphism, we can (and do) assume that C is given by a Legendre-Rosenhain equation Let H 0 (ω C ) be the space of holomorphic differentials of C, let H 0 (ω C ) * be its dual and let H 1 (C, Z) be the first homology group of C. Following the literature, for example [4,Sect. 11.1], we define the Jacobian of C as J (C) = H 0 (ω C ) * /H 1 (C, Z), and for ω = (ω 1 , . . . , ω g ) a basis of H 0 (ω C ) and the base point P ∞ = (0 : 1 : 0) we define the Abel-Jacobi map and extend it additively to divisors of C.
The following two classical theorems, due to Riemann and Siegel respectively, deal with the zero locus of the Riemann theta functions and the values of a function of an algebraic curve on non-special divisors. Recall that the Riemann theta function θ : C g × H g → C is given by and that a non-special divisor D is a divisor with (K − D) = 0 for K a canonical divisor of C.
Theorem 1 (Riemann's Vanishing Theorem, see [21,Corollary 3.6]) Let C be a curve defined over C of genus g, let J (C) be the Jacobian of C with period matrix Ω ∈ H g and let α be an Abel-Jacobi map of C. There is an element Δ ∈ J (C), called a Riemann constant with respect to α, such that the function θ ( · , Ω) vanishes at z ∈ C g if and only if there exist The choice of a base point determines uniquely the Riemann constant Δ, as shown by Mumford in Theorem 3.10 and Corollary 3.11 of [21].
Theorem 2 (Siegel [30,Theorem 11.3]) Let C be a curve of genus g over C, and let φ be a function on C with Let P ∈ C and let ω be a basis of H 0 (ω C ) for which the Jacobian J (C) has period matrix Ω ∈ H g . Let Δ be the Riemann constant with respect to the Abel-Jacobi map α with base point P.
Choose paths from the base point P to A i and B i that satisfy Then, given an effective non-special divisor D = P 1 + · · · + P g of degree g that satisfies where E ∈ C × is independent of D, and the integrals from P to P j take the same paths both in the numerator and the denominator.
Observe that in (2) we are evaluating the Riemann theta functions at points of the Jacobian.
We shall need a version of Theorem 2 in terms of Riemann theta constants. Given c = (c 1 , c 2 ) with c i ∈ R g , the Riemann theta constant (with characteristic c) is the function θ[c]: H g → C given by We use the following two elementary properties of the Riemann theta constants: They are even in c, that is, and they are quasi-periodic in c, that is, for m = (m 1 , m 2 ) ∈ Z 2g one has Due to the quasi-periodicity of the Riemann theta constants, we must fix representatives in R 2g for the points of the Jacobian. Throughout, we consider the composition of the maps where α is the Abel-Jacobi map, the map · identifies J (C) with R 2g /Z 2g via Ωc 1 +c 2 → (c 1 , c 2 ) and · maps a class in R 2g /Z 2g to its representative with entries in [0, 1).
For P ∈ C we write P instead of α(P); and in the case of a divisor D = n P P, we define D := n P P ∈ R 2g . Note that with this definition for most divisors D we get that D and α(D) are different.
With the definitions above, one can rewrite Theorem 2 in terms of Riemann theta constants as follows: where E ∈ C × is also independent of D.
Proof Observe that the exponential factor in (3) for Riemann theta constants can be written as exp(πiB(x, x)) where B is the symmetric bilinear form given by Let Q(u) = B(u, u) and let c = D − Δ. For j = 1, . . . , g, let x j = P j and choose a path from P to P j that satisfies .
We want to prove that E does not depend on D. By (3) we get so in terms of characteristics we obtain m i=1 (a i − b i ) = 0 and then it follows that does not depend on D.
Lemma 1 Let C be a Picard curve defined over C given by y 3 , and consider the branch points P 0 = (0, 0), P 1 = (1, 0), P λ = (λ, 0), P μ = (μ, 0), and P ∞ at infinity. Let J (C) be the Jacobian of C with period matrix Ω, let α be the Abel-Jacobi map with base point P ∞ , and let Δ ∈ J (C) be the associated Riemann constant. Then, for every non-special divisor D = R 1 + R 2 + R 3 , we have Proof Let ω be the basis of holomorphic differentials for which J (C) has period matrix Ω.
The divisor of the function x on C is div(x) = 3 P 0 − 3 P ∞ , so in order to apply Corollary 1 for φ = x and P = P ∞ , we choose three times the zero path from P ∞ to itself, the path γ 1 from P ∞ to P 0 that for a 1 = P 0 satisfies and paths γ 2 , γ 3 from P ∞ to P 0 that satisfy Let a 2 , a 3 be the elements in R 6 that satisfy Then, by Corollary 1, we have for some constant E ∈ C × independent of D. Note that for k = 1, 2, 3 we have so the differences a i − a j for i = j are integer vectors. Applying the quasi-periodicity property (5), Eq. (8) becomes But it follows from (7) that the sum a 1 + a 2 + a 3 is zero, so we obtain a 1 − a 2 + a 1 − a 3 = 3a 1 = 3 P 0 and the statement follows.
The final step is to choose the right non-special divisors.
Proof We apply Lemma 1 twice, to the divisors D 1 = P 1 + 2P η and D 2 = 2P 1 + P η , which are non-special as proven in [14, p. 506]. Then, we get Moreover, using the symmetry (4) and quasi-periodicity (5) of the Riemann theta constants we also obtain as desired.
Remark 1 Compare the above formula in Theorem 3 with the ones given in [14,Eq. 9]. The formulas there are the same as in (9) replacing ε η by 1, hence in general they do not hold due to the absence of the precise root of unity.
However, if we follow the original work by Picard [24, p. 131], then we obtain a particular form of the period matrix Ω (see also Shiga [27,) for which it is always the case that ε λ = ε μ = 1. In such case, the formulas in [14] hold.

The algorithm
In this section we explain how to use the formula in Theorem 3 to obtain an inverse Jacobian algorithm for Picard curves, that is, an algorithm that, given the Jacobian of a Picard curve C, returns a model of C.
The following result characterizes the Jacobian of a Picard curve based on work of Koike-Weng and Estrada. Proposition 1 Let X be a simple principally polarized abelian variety of dimension 3 defined over an algebraically closed field k. If X has an automorphism ϕ of order 3, then we have that X is the Jacobian of a Picard curve. Furthermore, let ρ be the curve automorphism ρ(x, y) = (x, z 3 y), and let ρ * be the automorphism of the Jacobian that it induces. Then we Proof By Oort-Ueno [22], based on work by Matsusaka [18] and Hoyt [9], we have that since X is a simple principally polarized abelian variety of dimension 3 over an algebraically closed field, then it is the Jacobian of a curve. Let C be a curve with X ∼ = J (C).
Therefore, the degree of the map π : C → C/ η is also 3, and by the Riemann-Hurwitz formula one obtains that C/ η has either genus 0 or 1. But X is simple, so the curve C/ η is isomorphic to P 1 and π has 5 ramification points.
Then k(C)/k(C/ η ) is a Kummer extension of degree 3, hence C is given by an equation of the form y 3 = h(x) where h has 4 different roots. By Lemma 7.3 in Estrada [8, Appendix I], we obtain a model for C given by y 3 = f (x) where f has degree 4 and distinct roots and η is either the automorphism ρ given by (x, y) → (x, z 3 y) or its square.
Remark 2 While the idea behind the proof is the same in Proposition 1 and in [14, Lemma 1], the assumptions in [14] are in a way more restrictive, as Koike and Weng focus on maximal CM Picard curves. Moreover, the proof in [14] has a gap, which is fixed exactly by our reference to Estrada [8, Appendix I].
We provide the proof above as an homage to Koike-Weng, but one could alternatively use the classifications of plane quartics and genus-3 hyperelliptic curves by their automorphism group to prove the result: by Propositions 1.1 and 1.2 in [17] one concludes that the only genus-3 curves with order-3 automorphisms that have simple Jacobians are Picard curves.
It follows from Proposition 1 that one can think of the input of the inverse Jacobian algorithm for Picard curves to be a period matrix Ω ∈ H 3 together with the rational representation of an automorphism of order 3. To give the curve we will compute the values of λ and μ in a Legrendre-Rosenhain equation of the curve.
First we want to determine the points in C 3 /(ΩZ 3 +Z 3 ) that correspond to the Riemann constant Δ and the image of the branch points via α. The former is given by the following result due to Koike and Weng.
where (·) 0 denotes the diagonal of the matrix as a column vector.
The following step is to identify the image under α of the branch points.
Then α(B) and −α(B) are the only subsets T ⊂ J (C) of four elements such that: Proof We first show that α(B) and −α(B) satisfy (i)-(iii), and then we prove that these are the only possibilities. That α(B) satisfies (i) follows from div(y) = P∈B P − 4P ∞ . That α(B) satisfies (ii) is proven by Koike and Weng in [14,Remark 8]. Next we prove that α(B) satisfies (iii). On the one hand, given To prove the opposite inclusion, let Note now that a Picard curve is non-hyperelliptic, since one checks that the canonical map is the embedding (x : y : 1): C → P 2 . Then we conclude that h is constant, since otherwise it has degree at most 2, hence the curve would be hyperelliptic. Therefore we have ρ(Q 1 ) + ρ(Q 2 ) = Q 1 + Q 2 , but since ρ has order 3, the cardinality of the orbit of Q i has length 3 or 1, so we obtain ρ(Q i ) = Q i . Therefore Q 1 and Q 2 are branch points, so the other inclusion holds.
It is clear that −α(B) satisfies (i) and (ii). To see that it satisfies (iii), it is enough to prove that Θ 3 is invariant under the map x → −x. But this follows from the symmetry of the Riemann theta constants, see (4).
Next we prove that α(B) and −α(B) are, in fact, all the subsets that satisfy (i)-(iii).
Let e 1 , e 2 , e 3 be the standard basis vectors of F 3 3 , and let e 4 = −e 1 − e 2 − e 3 , so for One can check #O 0 = 15, and moreover we have If the set of elements of T satisfies (iii), then we have Remark 3 With Theorem 4, we make precise the idea hinted in Corollary 11 of Koike-Weng [14]. There, they claim the existence of a 4-element set that satisfies (i) and (ii), prove that α(B) does satisfy (i) and (ii), and assume without further comments that when one finds such a set, it is α(B). This is problematic not only because they disregard the case where the set is −α(B) but especially because they do not consider (iii), since there exist 4-element sets in J (C) that satisfy (i) and (ii) which are not α(B) or even −α(B).
In fact, there are # GL 3 (F 3 ) = 11, 232 possible sequences T ∈ J (C) 4 that satisfy (i) and (ii), hence the probability of finding one that corresponds to a permutation of B is 1/468 ≈ 0.002.
We now have all the tools to state the algorithm.

Algorithm 5
Input: A period matrix Ω ∈ H 3 of the Jacobian of a Picard curve C, and the transposed rational representation N ∈ Z 6×6 of the automorphism of the Jacobian ρ * induced by the curve automorphism ρ(x, y) = (x, z 3 y). Output: The complex values λ and μ in a Legendre-Rosenhain equation

Return λ and μ.
Remark 4 Algorithm 5 is a mathematical algorithm, but, because it involves infinite sums, complex numbers and exponentials, it cannot be run on a Turing machine or a physical computer. To do so one needs to truncate the sum on the Riemann theta constants, approximate complex numbers and keep track of the error propagation. For implementation details, we refer the reader to [32, Sect. 1.5].
Proof of Algorithm 5 Let Δ ∈ J (C) be the Riemann constant with respect to P ∞ = (0 : 1 : 0) and let B be the set of affine branch points of C. By Proposition 2, the point Δ is the only one that satisfies N [Δ] = Δ and is a 2-torsion point, that is, it satisfies Δ ∈ 1 2 Z 6 /Z 6 . We conclude D = Δ. By Theorem 4, the sequence (t 1 , t 2 , t 3 , t 4 ) is an ordering of either α(B) or −α(B). In the former case, the values λ, μ obtained in Step 4 are the x-coordinates of the affine branch points different from (0, 0) and (0, 1). A quasi-periodicity argument similar to those in the proofs of Lemma 1 or Theorem 3 yields that in the latter case the same holds too.

Computing maximal CM Picard curves
In this section, we present how to use Algorithm 5 to compute maximal CM Picard curves, that is, Picard curves such that their Jacobians have an endomorphism ring isomorphic to the maximal order of a sextic CM-field K .
Since ρ * is an automorphism of order 3, the field K contains a primitive 3rd root of unity ζ 3 ∈ K . In fact, the field K is determined by a totally real cubic field K 0 that satisfies K = K 0 (ζ 3 ).
Van Wamelen [37] gives an algorithm that, given a CM-field K , lists all the isomorphism classes of period matrices of principally polarized abelian varieties with complex multiplication by O K . This method is based on the CM theory due to Shimura and Taniyama (see [29]) and we use the implementation in [33].
Applying said method to a sextic CM-field containing a primitive third root of unity ζ 3 ∈ K , we obtain a list, say CM K , of period matrices Ω corresponding to principally polarized abelian threefolds with CM by O K with an order-3 automorphism associated to ζ 3 . By Proposition 1, they are Jacobians of Picard curves. To then obtain the rational representation N of the order-3 automorphism is a matter of keeping track of the changes of basis throughout van Wamelen's method. We use the resulting list of pairs (Ω, N ) as input for Algorithm 5.
When computing the Riemann theta constants in the algorithm implementation, we restrict the sum to a hypercube [−B, B] ⊂ Z 3 for a certain value B that depends on the precision required and the minimum eigenvalue of the imaginary part of the period matrix. For efficiency, we would like the smallest eigenvalue of the imaginary part of Ω to be as big as possible, due to its role in the computation of the bound B. Since the isomorphism class of a principally polarized abelian variety only depends on the orbit of Ω under the action of Sp 2g (Z), this can be achieved by choosing a representative in a certain fundamental domain of H g . For this we use the implementation due to Kılıçer-Streng [10] of Algorithm 2 in Labrande-Thomé [15,Sect. 4.1] on our period matrix before applying Algorithm 5. For more details we refer the reader to [32, Sect. 1.5].
After numerically approximating the x-coordinates of the branch points of C with Algorithm 5, we obtain a polynomial up to some precision, while the curve is actually isomorphic to y 3 = h(x) for a certain polynomial h over a number field.
Given the quartic polynomial p(x) = x 4 + g 2 x 2 + g 3 x + g 4 with g 2 , g 3 = 0 we define the absolute invariants of p(x) as In order to find h(x) from f (x), we compute the absolute invariants of C by computing j 1 and j 2 for an isomorphic curve of the form y 3 = x 4 + g 2 x 2 + g 3 x + g 4 . We use them to obtain a numerical approximation of the class polynomials which have coefficients in the ring of integers of the moduli field of the curve. Once we recognize the exact polynomials we recover the pairs (j 1 , j 2 ) by embedding the roots of H j 1 , H j 2 to C and comparing them with the numerical approximations obtained from f .
We then reconstruct an exact model h(x) for each curve from the exact absolute invariants, obtaining Note that in order to be able to recognize the coefficients of H j 1 and H j 2 as algebraic numbers we have to compute λ and μ with enough precision. Finally, one can use the algorithm in [5] to compute the endomorphism algebra of the Jacobian of the curve, confirming that the obtained curves have CM by the maximal order of the initial CM-field.
The list below contains models for all maximal CM Picard curves whose CM-field has class number h ≤ 4. We get the sextic fields from [23, Table 3]. The authors of [13], working off an earlier version of this paper [16], give supporting evidence of the correctness of our examples. We have now confirmed the correctness of the models using the implementation of the algorithm in [5].
The examples (1) 14) we also obtain three conjugate curves defined over K 0 ; see also [11,  The examples (9)-(12) are defined over a cubic number field L such that the composition KL is the Hilbert class field of K . This follows from Shimura-Taniyama [28, Main Theorem 1], since we have h K = 3 and the curves are not defined over Q.
Remark 5 Examples (1)-(5) also appear in [14, Sect. 6.1]. Moreover, it is worth mentioning the existence of an algorithm to compute maximal CM plane quartics, see [12]. In particular, this algorithm can be used to compute maximal CM Picard curves, although less efficiently due to its more general scope. In fact, all the curves defined over Q that we give were independently found in [12].

Remark 6
It is also possible to use this algorithm to compute maximal CM Picard curves over finite fields, by obtaining first a rational model, and then reducing it modulo p. An alternative approach to this problem is given in [1] using the Chinese Reminder Theorem. In particular, see [1,Sect. 7] for an example using the CM-field in Example (2) and a comparison of the performance of both algorithms.
and the three conjugates

Acknowledgements
The first two authors would like to thank Marco Streng and Christelle Vincent for useful discussions. They also thank the reviewers for their very helpful comments. The author of this appendix wishes to thank first and foremost Sorina Ionica, who verified the result independently with a proof that follows Takase's work more closely. She also thanks Marco Streng for first bringing to her attention the need to generalize Takase's work, and Anna Somoza for pointing out that her work on Picard curves could be adapted to obtain the correct sign. In addition, she thanks Jeroen Sijsling for performing computations confirming the correctness of the sign as computed in this appendix. Finally, she would like to extend her warmest thanks to the referees for their helpful suggestions which have made the writing stronger.

Appendix A (by Christelle Vincent)
Let C be a hyperelliptic curve of genus g ≥ 2 defined over C, and denote by x : C → P 1 a morphism of degree 2 from C to P 1 . Then x has 2g + 2 branch points which do not depend on the choice of x. We fix once and for all an ordering of these branch points, and denote them by P 1 , P 2 , . . . , P 2g+2 . Furthermore, for simplicity of notation in what follows we will denote The significance of these quantities is the following: If x(P j ) = ∞ for any j, then a model for C over C is given by whereas if there is k with x(P k ) = ∞, a model for C over C is given by Our goal in this appendix is to show the following proposition, which generalizes a formula given by Takase [34,Theorem 1.1]. In the statement we use the notation [a l , a m , a k , a ∞ ] for the cross-ratio Proposition 3 Let C be a hyperelliptic curve defined over C, x : C → P 1 be a morphism of degree 2 with branch points P 1 , . . . , P 2g+2 , and Ω be a (small) period matrix for J (C), the Jacobian of C. Let k, l and m be distinct and belong to the set {1, 2, . . . , 2g + 2}, and fix P ∞ a distinguished branch point of x, ∞ = k, l, m. Then, for a j = x(P j ) and η an eta-map associated to Ω and the base point P ∞ with corresponding U -set U η , we have where V and W are any sets that give a disjoint decomposition with #V = #W = g − 1.
As an immediate corollary, if we denote by λ i for i = 3, 4, . . . , 2g + 1 the Rosenhain invariants of C, by which we mean the constants appearing in a choice of Rosenhain model for the curve C, we obtain the following formula: Corollary 2 Let C be a hyperelliptic curve defined over C, and fix a choice of Rosenhain model for C. Let P ∞ denote the point of C that is "at infinity" in the Rosenhain model of C, Ω be a choice of period matrix for J (C), the Jacobian of C, and η be an eta-map associated to Ω and the base point P ∞ with corresponding U -set U η . Then for j ∈ {3, 4, . . . , 2g + 1}, the Rosenhain invariants of C are given by the expression where V and W are two sets of cardinality g − 1 such that and the notation • denotes the symmetric difference of two sets: For S, T ⊆ {1, 2, . . . , 2g +2}, we have We now discuss briefly the history of this result and why this publication is necessary. In his work [34], Takase gives the formula presented in Proposition 3 in the special case where a ∞ = ∞, and only for certain choices of period matrix Ω for the Jacobian of C. These period matrices are those given by Mumford [20], using his "traditional" choice of symplectic basis for the first homology group of the Jacobian. This work was notably used by Weng in [39] to give models of hyperelliptic curves whose Jacobian has complex multiplication. Since our software [3] did not allow us to make the same choice of period matrix, for our computations we needed a more general result. Our earlier article [2,Theorem 4.5] claimed to give the formula for all period matrices (retaining the assumption that a ∞ = ∞), but unfortunately we found out later that there remained a mistake in the sign of λ i , which had not been corrected to account for the general case.
The mistake was originally found by the authors of [12] as they worked to complete the list of curves of genus 3 defined over Q whose geometric endomorphism ring is a maximal order in a sextic field. For a specific period matrix in their list, the code provided in [3] did not yield a correct model for the hyperelliptic curve. Somoza, an author of this article, pointed out the "third root of unity" issue she had found and fixed in the Picard case, and after some trial and error we found that we had the same issue in the hyperelliptic case, with the exception that we were missing instead a second root of unity, or a sign.
The formula we finally give here is valid for all period matrices, and gives the correct value for λ i . We note that the software available at [3] has been updated to be correct. As mentioned before, in addition to correcting the sign of λ i , the formula given here is more general than that given by Takase, because here we do not assume that a ∞ = ∞, which explains why we compute the cross-ratio [a l , a m , a k , a ∞ ] rather than the simpler quotient a k −a l a k −a m as Takase does. As far as the proof is concerned, our proof does not follow that given by Takase, though it is possible to follow his method to arrive at the same result (though still with the assumption that a ∞ = ∞) as was done independently by Ionica in unpublished work. We note that this is not simpler or shorter than the proof we give here. The corrected formula has since been used in [6] to compute hyperelliptic class polynomials in genus 3.

A.1 Preliminaries
Following the technique used in the body of the paper, we will use Siegel's Theorem 2 applied to a suitable choice of function φ : C → P 1 to obtain our results. To apply Siegel's Theorem, we first need a non-special divisor on C: Lemma 2 Let C be a hyperelliptic curve defined over C, x: C → P 1 be a morphism of degree 2 from C to P 1 , and P 1 , . . . P 2g+2 be the branch points of x. Let I ⊂ {1, 2, . . . , 2g + 2} be any subset of cardinality g. Then is a non-special divisor on C. In other words, any sum of g distinct branch points of x is a non-special divisor on C.
Proof We recall that a divisor D is non-special if (K − D) = 0, where K is a canonical divisor on the curve C. Fix P ∞ a branch point that is not in the support of D, and a model for the hyperelliptic curve, where f is of degree 2g + 1 and P ∞ is the point at infinity. Then div(s) = i =∞ P i − (2g + 1)P ∞ , and val P ∞ (div(t)) = −2.
We may then use as a canonical divisor. Now suppose by way of contradiction that (div(dt) − D) ≥ 1, so there exists a function f on C with Then certainly we have Now functions on C are rational functions in s and t, and functions on C with poles only at ∞ must be polynomials in s and t. Since val P ∞ (s) = −(2g + 1), the function sf is a polynomial in t, of degree less than or equal to g − 1. However, such a polynomial cannot have g zeroes, one at each of the points in the support of D. From this contradiction we conclude that (K − D) = 0 and D is non-special.
Secondly, to connect our result to the established literature on hyperelliptic curves, we will need an eta-map associated to a period matrix Ω and a base point P ∞ . We refer the interested reader to either Poor's work [25] or our earlier work [2] for more details on these maps, and present here only the barest of facts necessary to keep this appendix readable. Let P ∞ be an arbitrary but fixed branched point of the degree 2 morphism x : C → P 1 fixed above, and recall that we have labeled the branch points of x to be P 1 , P 2 , . . . , P 2g+2 (one of these is of course also labeled P ∞ ). As in the body of the paper, fix α an Abel-Jacobi map for C with base point P ∞ . Then for j ∈ {1, 2, . . . , 2g + 2}, we write where · is the map given in equation (6), and as in the body of the paper we denote the composition of the three maps by the last. The fact that the coordinates of η j for each j are half-integers follows from the fact that P j − P ∞ is two-torsion in J (C), see [20,Corollary 2.11]. Furthermore, for any subset S ⊆ {1, 2, . . . , 2g + 2}, we write Note that we use the same convention as in the body of the paper regarding summation of characteristics; see the paragraph immediately following Eq. (6) for a discussion of this convention. Because of this, it follows that for We note that the dependence of the eta-map on the period matrix Ω happens explicitly via the map ·. Under these assumptions, there exists a subset U η ⊆ {1, 2, . . . , 2g + 2} such that where Δ is the Riemann constant associated to the choice of Abel-Jacobi map α that we made. We note that in fact there are several such sets; it is customary to choose one of even cardinality, and we have adopted in earlier work the convention that U η should also contain ∞. This determines the set U η uniquely. We call this set a U -set corresponding to η. Finally, one can show that if S is the complement of T inside of {1, 2, . . . , 2g + 2}, then

A.2 Proof of the formula
With this notation and preliminaries in place, we may begin the proof. We begin with an auxiliary result: Lemma 3 Let P j and P ∞ be two distinct branch points of the morphism x, α be an Abel-Jacobi map with base point P ∞ , and γ be a path from P ∞ to P j such that if P j = η j (where the map · is as in Eq. (6)), then In this case there exists a second path γ from P ∞ to P j such that Proof We have that P j = η j ∈ {0, 1 2 } 2g (see Eq. (27) and the discussion surrounding it for this fact). From this it follows that if L Ω = ΩZ 2g + Z 2g is the lattice attached to the period matrix Ω, we have that As a consequence, γ ω and − γ ω differ by an element of L Ω , and since every L Ω -translate of γ ω is γ ω for some other path γ from P ∞ to P j , it follows that there is γ from P ∞ to P j such that We can now give the crucial part of the proof: Lemma 4 Let C be a hyperelliptic curve defined over C, x: C → P 1 be a morphism of degree 2 with branch points P 1 , . . . , P 2g+2 , and Ω be a period matrix for J (C), the Jacobian of C. Let k, l and m be distinct and belong to the set {1, 2, . . . , 2g + 2}, and fix P ∞ a distinguished branch point of x, with ∞ = k, l, m. Then, for a j = x(P j ), and η an eta-map associated to Ω and to the base point P ∞ with corresponding U -set U η , we have where and for j = l, m, we have and where V is any set of cardinality g − 1 such that V ⊂ {1, 2, . . . , 2g + 2}, k, l, m, ∞ / ∈ V .
(Note that this is possible since 2g − 2 ≥ g − 1 for g ≥ 1.) Then the quantity which interests us is given by In addition, for j = l, m, the divisor is a sum of g distinct branch points of x, and therefore an effective non-special divisor by Lemma 2.
Using the notation of Siegel's Theorem 2, we have and now wish to apply Corollary 1 to compute the quantities x k (D l ) and x k (D m ).
To do so, we note that and that the supports of the divisors D l and D m avoid the support of div(x k ). As in the previous section, we denote by Δ the Riemann constant for the Abel-Jacobi map α of C with base point P ∞ . In the application of Siegel's Theorem, we will choose the paths from P ∞ to P ∞ to be the trivial paths. As in Lemma 3, we fix a path γ from P k to P ∞ such that and denote by γ the path from P k to P ∞ such that We have then that Finally, to simplify the notation, we further let for j = l, m, and replace the notation P i with the notation η i , using our convention for sums. After these preliminaries, a straightforward application of Corollary 1 to x k (D l ) and To use the quasiperiodicity property of the theta function, we write for j = l, m, so that we have since k / ∈ T j . Then for j = l, m, the characteristics differ by an integer vector, namely −2η k . Applying the quasi-periodicity property of the Riemann theta constant with characteristic given in equation (5), we obtain Therefore we have We finally handle the quantity Δ. First, we note that since Δ is a vector with half-integer entries, Δ and − Δ differ by a vector with integer entries. Furthermore, as noted in Eq. (31), η U η and Δ differ by a vector with integer entries. Therefore − Δ and η U η differ by a vector with integer entries, say n: (60) Recalling our notation for the symmetric difference of two sets given in Eq. (20), we have that and for j = l, m. Once again we thus apply the quasi-periodicity property of the Riemann theta constant with characteristic to remove the integer vectors appearing in each characteristic. This time around, we note that since all of characteristics appearing above are halfintegers, the sign exp(2πix 1 m 2 ) from the transformation formula will be ±1. Since all of the theta constants are now squared in the formula, the signs vanish and we finally obtain: [a l , a m , a k , a ∞ ] = exp(4πi(η m − η l ) 1 This completes the proof.
To finish the proof of Proposition 3, it remains now only to rewrite it so that the characteristics agree with Takase's and to verify that the signs agree. Indeed, the crossratio we compute here in this article agrees with the quotient computed by Takase, since in his article, Takase assumes that a ∞ = ∞. In that case, we have that [a l , a m , a k , a ∞ ] = a k − a l a k − a m .
We therefore turn our attention to the characteristics: Following Takase's notation, let W be the complement of V ∪ {k, l, m, ∞} in {1, 2, . . . , 2g + 2}. Then from the definitions it follows that for j = l, m. We also have that T l ∪{∞} is the complement of W ∪{k, m} in {1, 2, . . . , 2g +2}, and T m ∪ {∞} is the complement of W ∪ {k, l}. As a result, and Now by definition, we have that since P ∞ is chosen to be the base point of the Abel-Jacobi map. Therefore we have for j = l, m. By Eq. (32), we have that and η (T m ∪{∞})•U η = η U η •(W ∪{k,l}) .