On the Rosenhain forms of superspecial curves of genus two

In this paper, we examine superspecial genus-2 curves $C: y^2 = x(x-1)(x-\lambda)(x-\mu)(x-\nu)$ in odd characteristic $p$. As a main result, we show that the difference between any two elements in $\{0,1,\lambda,\mu,\nu\}$ is a square in $\mathbb{F}_{p^2}$. Moreover, we show that $C$ is maximal or minimal over $\mathbb{F}_{p^2}$ without taking its $\mathbb{F}_{p^2}$-form (we also give a criterion in terms of $p$ that tells whether $C$ is maximal or minimal). As these applications, we study the maximality of superspecial hyperelliptic curves of genus $3$ and $4$ whose automorphism groups contain $\mathbb{Z}/2\mathbb{Z} \times \mathbb{Z}/2\mathbb{Z}$.


Introduction
Throughout this paper, a curve always means a non-singular projective variety of dimension one defined over a field of characteristic p ≥ 3.An elliptic curve E is called supersingular if the p-torsion group of E is trivial.Recently, supersingular elliptic curves are often used in protocols of isogeny-based cryptosystems.One of the reasons is that all supersingular elliptic curves are defined over F p 2 , and so we can do computations without a field extension any further.As a more advanced result by Auer-Top [1], they investigated Legendre forms of supersingular elliptic curves; if an elliptic curve E : y 2 = x(x − 1)(x − t) is supersingular, then −t is eighth power in F p 2 .
In this paper, we focus mainly on superspecial genus-2 curves.Here, a curve C is called superspecial when the Jacobian variety of C is isomorphic to the product of supersingular elliptic curves.It is known [15] that the curve C is superspecial if and only if the Cartier operator on H 0 (C, Ω C ) vanishes.Superspecial curves are not only important objects in algebraic geometry, but also have applications to such as cryptography and coding theory.Here, let us review previous works on superspeciality of genus-2 curves briefly: Ibukiyama-Katsura-Oort determined the exact number of isomorphism classes of superspecial genus-2 curves in [7,Theorem 3.3].In particular, there is such a curve for arbitrary characteristics p ≥ 5. Jordan-Zaytman [9, Section 7] showed that the superspecial (2, 2)-isogeny graph is connected, which implies that all superspecial genus-2 curves can be listed by using (2, 2)-isogenies (see Subsection 2.3 for detail).Katsura-Takashima counted the number of superspecial (2, 2)-isogenies in [11, Section 6].In terms of application, Castryck-Decru-Smith [2] constructed hash functions using superspecial genus-2 curves.
Our first contribution on superspecial genus-2 curves is that we give a variant of Auer-Top's result.More precisely, we obtain the following result on Rosenhain forms of superspecial genus-2 curves: Main Theorem A. Assume that the genus-2 curve is superspecial.Then, the following statements are true: The other main result in this paper concerns the maximality of genus-2 curves.Here, a curve C is called maximal (resp.minimal) over F q with q = p 2e if the number of F q -rational points of C attains the Hasse-Witt upper (resp.lower) bound.It is known that maximal or minimal curves over F p 2 are all superspecial, whereas all superspecial curves over F p 2 are not necessarily maximal or minimal (cf.[3, Section II, Theorem 1.1]).On the other hand, it follows from Auer-Top's result [1,Proposition 2.2] that all supersingular Legendre elliptic curves E : y 2 = x(x − 1)(x − t) are maximal or minimal over F p 2 .In [16,Theorem 1.1], the author studied the maximality of hyperelliptic genus-3 curves H : y 2 = (x 4 − ax 2 + 1)(x 4 − bx 2 + 1), whose automorphism groups contain (Z/2Z) 3 ; if H is superspecial, then H is maximal or minimal over F p 2 .In [17,Theorem 1.1], the author also studied the maximality of Ciani quartics H ′ : x 4 + y 4 + z 4 + rx 2 y 2 + sy 2 z 2 + tz 2 x 2 = 0, which are non-hyperelliptic genus-3 curves whose automorphism groups contain the dihedral group of order 4; if H ′ is superspecial, then H ′ is maximal or minimal over F p 2 .In this paper, we give a variant of these results for superspecial genus-2 curves: Main Theorem B. Assume that the genus-2 curve is superspecial.Then, the curve C is maximal or minimal over F p 2 .More precisely, we have the following: • The case of p ≡ 1 (mod 4): the curve C is minimal over In particular, the curve C is maximal or minimal over F p 2 .
As an application of Main Theorem B, we examine hyperelliptic genus-3 curves D whose automorphism groups contain (Z/2Z) 2 and hyperelliptic genus-4 curves D ′ whose automorphism groups contain (Z/2Z) 2 in Section 4. We find a form of D (resp.D ′ ) such that its superspeciality implies its maximality or minimality over F p 2 , and we give an explicit criterion whether D (resp.D ′ ) is maximal or minimal over F p 2 .Now, the rest of this paper is organized as follows: Section 2 is devoted to preliminaries for genus-2 curves.In Subsections 3.1 and 3.2, we prove Main Theorems A and B respectively.Finally, we give three applications of these main theorems in Section 4.

Consider the genus-2 curve
where each a i is a distinct element of K ∪ {∞}.If a i = ∞, then we mean that the factor (X − a i ) is excluded from the above equation.The transformation gives the equation defined by Note that κ is a non-zero element of K since i = j ⇒ a i = a j by the assumption.Setting then we see that C λ,µ,ν is a Rosenhain form of C.
In particular case that all a i belong to K ∪ {∞}, then the isomorphism C ∼ = C λ,µ,ν which we constructed is defined over K if and only if κ is a square in K.In short, we have the following lemma.Lemma 2.3.Consider the genus-2 curve C given as (2.1), where each a i is a distinct element of K ∪ {∞}.Then the curve C λ,µ,ν is a Rosenhain form of C, where λ, µ, ν are defined as (2.3).In addition, the curve C is isomorphic to C λ,µ,ν over K if and only if κ is a square in K, where κ is defined as (2.2).
Proof.This is a direct result of the above discussion.

Reduced automorphism groups of genus-2 curves
From now on, we have the following notations for the groups: • Let C n ( ∼ = Z/nZ) be the cyclic group of order n.
• Let D 2n be the dihedral group of order 2n.
• Let S n be the symmetric group of degree n.
First of all, we recall the definition of the reduced automorphism group of a hyperelliptic curve.Definition 2.5.For a hyperelliptic curve C, the reduced automorphism group of C is defined as RA(C) := Aut(C)/ ι , where Aut(C) denotes the automorphism group of C over K, and ι is the hyperelliptic involution.
Igusa [8,Section 8] classified all genus-2 curves C by their reduced automorphism groups and gave explicit equations of a Rosenhain forms of C (see also Ibukiyama-Katsura-Oort [7, Section 1.2]).On the other hand, Katsura-Takashima [11,Section 5] gave other equations of C (we call them normal forms of C).The following is a table summarizing their results for p ≥ 7; there are 7 possible reduced automorphism groups.We denote by i a square root of −1 and by ζ a primitive fifth root of unity.
Remark 2.7.There is a criterion to determine the reduced automorphism group of a genus-2 curve by using the Clebsch invariants (cf.[4,Section 3.2]).
Not all of the classifications in the table above are necessary, but we will only use the following result.
Proposition 2.8.Assume that p ≥ 3. Let C be a genus-2 curve, then the following statements are true: (1) If RA(C) ∼ = C 5 , then C is isomorphic to the curve defined by the equation y 2 = x 5 − 1.
(2) If RA(C) ⊃ C 2 , then C is isomorphic to the curve defined by the equation for some a, b (belonging to K).
Proof.(3) This assertion holds since no other reduced automorphism groups of C exist except {1}, from the above table and Remark 2.6.
For the second case in Proposition 2.8, there exist two involutions σ, τ defined by We put the quotients E 1 := C/ σ and E 2 := C/ τ , then they are elliptic curves defined by Moreover, we see that these two morphisms and two elliptic curves Proof.As mentioned in the above discussion, there exists a (2, 2)-isogeny φ : By the same coordinate change as [10, Section 2], these elliptic curves are transformed into (2.6) Hence, the curve C is superspecial if and only if two elliptic curves .
Solving these equations for a and b, we have this lemma.

Richelot isogeny
A Richelot isogeny is a (2, 2)-isogeny whose domain is the Jacobian variety of a genus-2 curve.Let us briefly recall the abstract description of this according to [11, Section 3], which helps readers understand.Let C be a genus-2 curve.We denote by J := Jac(C) be the Jacobian variety of C, and denote by J t the dual abelian variety of J. Considering C as a divisor of J, it defines a principal polarization ϕ C : J ∼ = J t .Therefore, the divisor 2C defines a polarization ϕ 2C : One can show that C ′ defines a principal polarization on J/G.By the construction (based on descent theory as in [14, Section 12]), we see that C ′ is defined over K if both C and G are defined over K.
Here, the superspecial (2, 2)-isogeny graph G p is defined as follows: The vertices of G p are isomorphism classes of superspecial principally polarized abelian surfaces defined over F p 2 .The edges of G p are isomorphism classes of (2, 2)-isogenies between superspecial principally polarized abelian surfaces.Then, thanks to Theorem 2.10, we can enumerate all superspecial genus-2 curves using the following algorithm (cf.[ Next, let us review how to compute the genus-2 curve which is Richelot isogenous to a given genus-2 curve (see [2, Section 3.2] for details).Definition 2.12.Let f (X) ∈ K[X] be a separable polynomial of degree 5 or 6.Then, a quadratic splitting Consider the genus-2 curve where each a i is a distinct element of K ∪ {∞}.For i ∈ {1, . . ., 6}, we put P i := ∞ if a i = ∞ and P i := (a i , 0) otherwise.Then, all 2-torsion points on J := Jac(C) are written as Proposition 2.13.With the notations as above, let {G 1 , G 2 , G 3 } be a quadratic splitting of f (X) with we have the following statements: (1) If δ = 0, then J/G is isomorphic to the Jacobian of the genus-2 curve C ′ : Moreover, if all 2-torsion points on J are defined over K, then any isotropic subgroup of J [2] is defined over K. Hence, the isogeny is also defined over K.
(2) If δ = 0, then J/G is isomorphic to a product of two elliptic curves.

Proof of Main Theorems
In this section, we show our Main Theorems stated in Section 1 (specifically, the proofs of Main Theorem A and B are given in Subsection 3.1 and 3.2, respectively).We use the same notations as in previous sections, and we consider all curves over a field of characteristic p ≥ 3.

Proof of Main Theorem A
First of all, we show the following proposition (a partial result of Main Theorem A).
Proposition 3.1.Assume that the genus-2 curve is superspecial.Then λ, µ and ν belong to Proof.We divide into three cases by the reduced automorphism group of C as in Proposition 2.8.
(1) The case that RA(C) ∼ = C 5 : Recall that the curve C is isomorphic to (2) The case that RA(C) ⊃ C 2 : Recall from Proposition 2.8 that C is isomorphic to where a and b belong to the algebraic closure of F p 2 .Using Lemma 2.9, there exist t 1 and t 2 such that and two elliptic curves Here, it is known [1, Proposition 3.1] that t i and 1 − t i for i = 1, 2 are fourth powers in F p 2 .Thereby, we obtain that a and b are also fourth powers in F p 2 .This implies that we can write Then λ, µ and ν obtained by transforming to a Rosenhain form of C belong to F p 2 , as mentioned in Subsection 2.1.
(3) The case that RA(C) = {1}: It is well-known [3, p. 166] that C descends to a maximal curve C ′ defined over F p 2 , where the square F 2 of the Frobenius map F is equal to −p.Let C ′ be written as where f (X) ∈ F p 2 [X] is a square-free polynomial of degree 6 and κ belongs to F p 2 .Then P i := (a i , 0) is a Weierstrass point of C, and moreover D i,j := [P i ]−[P j ] with i = j is a 2-torsion point on J := Jac(C).
Here, the Mumford representation (cf.[21, Section 13]) for D i,k is given as (u i,k , 0) with and hence a i + a k belongs to F p 2 .Since a j + a k belongs to F p 2 similarly, we obtain that a i − a j ∈ F p 2 .Then, as studied in Subsection 2.1, for all Rosenhain forms we see that λ, µ and ν also belong to F p 2 since these are obtained as a i − a j 's quotients.Now, we denote by G := Gal(F p 2/F p 2), then it is known [19, Section 4] that there is a bijection from the set of F p 2 -forms of C ′ to H 1 (G, Aut(C ′ )), which is isomorphic to Z/2Z by the assumption.Hence C is isomorphic to for κ ′ = 1 or ε with a non-square element ε in F p 2 .In any case, all λ, µ and ν belong to F p 2 as desired.
Therefore, the proof is done.
Next, given a Rosenhain form of a superspecial genus-2 curve C, we compute Rosenhain forms of C ′ which are Richelot isogenous to C, according to Proposition 2.13.We consider the superspecial genus-2 curve with {a 1 , a 2 , a 3 , a 4 , a 5 } = {0, 1, λ, µ, ν} and a quadratic splitting We remark that all a i belong to F p 2 by Proposition 3.1.Moreover, we define the following three values In the following, we choose √ D 1 , √ D 2 and √ D 3 of a square root of D 1 , D 2 and D 3 (these values are defined to be elements of F p 2 , but they will turn out to be elements of F p 2).Then, three polynomials H 1 , H 2 and H 3 defined in Proposition 2.13 can be calculated as where we define α i , β i and γ i for i ∈ {1, 2} to be elements of F p 2 as follows: , As mentioned in Subsection 2.3, the genus-2 curve is Richelot isogenous to C, and hence C ′ is also superspecial by the assumption.The transformation Then λ ′ , µ ′ and ν ′ are elements of F p 2 by using Proposition 3.1 again.One can check that and hence Tedious computation shows that which implies that D 3 is a square in F p 2 (and hence D 2 is also a square in F p 2 ).
For example if we take (a 1 , a 2 , a 3 ) = (0, 1, λ), then we obtain D 3 = λ, which turns out to be a square in F p 2 from the above discussion.Similarly we can show that other 8 values are also squares in Before the proof of the second assertion of Main Theorem A, we show the following lemma: and hence √ D 2 D 3 is a square in F p 2 .Moreover, tedious computation shows that Here, we let b 12 and b 13 elements of

Proof of Main Theorem A (2). It follows from Lemma 3.2 that the value
is a fourth power in F p 2 For example, if we take a 1 = 0, then we obtain D 2 D 3 = λµν, which turns out to be a fourth power in F p 2 .Similarly, one can show that other 4 values are also fourth powers in F p 2 .

Proof of Main Theorem B
First, we show the following propositions (a partial result of Main Theorem B).

Lemma 3.3. Assume that the genus-2 curve
is superspecial.Then, the curve C is maximal or minimal over F p 2 .Moreover, we have the following: • The case of p ≡ 3 (mod 4): The curve C is maximal over F p 2 if and only if 1 − a is a square in F p 2 .
• The case of p ≡ 1 (mod 4): The curve C is maximal over F p 2 if and only if 1 − a is not a square in F p 2 .
Proof.Recall from Subsection 2.2 that the Jacobian variety of C is (2, 2)-isogenous to This isogeny is defined over F p 2 .Indeed, recall from (2.5) and (2.6) that this is explicitly written by a and b, and it follows from the proof of Proposition 3.1 that both a and b are squares in F p 2 from the superspeciality of C.This fact means that C is maximal (resp.minimal) if and only if both E i are maximal (resp.minimal).
• The case of p ≡ 3 (mod 4): Two elliptic curves is also a square (resp.non-square).This implies that both E 1 and E 2 are maximal (resp.minimal) over F p 2 , and hence the curve C is also maximal (resp.minimal) over F p 2 .
• The case of p ≡ 1 (mod 4): Two elliptic curves v 2 = u(u − 1)(u − t i ) for i = 1, 2 are minimal over F p 2 .Assume that 1 − a is a square (resp.non-square) in F p 2 , then b(1 − a) is also a square (resp.non-square).This implies that both E 1 and E 2 are minimal (resp.maximal) over F p 2 , and hence the curve C is also minimal (resp.maximal) over Therefore, this lemma is true.
Proposition 3.4.Assume that the genus-2 curve is superspecial and RA(C) ⊃ C 2 .Then, we have the following: • The case of p ≡ 3 (mod 4): The curve C is maximal over F p 2 .
• The case of p ≡ 1 (mod 4): The curve C is minimal over Proof.Recall from Subsection 2.2 that the curve C has a form where a and b are squares in F p 2 .Here, it suffices to show this proposition holds for one Rosenhain form of it by Lemma 2.4 and Main Theorem A(1).Set (a 1 , a 2 , a 3 gives the equation where λ, µ, ν are given in (2.3).Here, this κ is a square in F p 2 if and only if 1 − a is a square in F p 2 .Indeed, recall from Lemma 2.9 that we can write where t i and 1 − t i are fourth powers in In the following, we divide into two cases depending on whether p ≡ 3 (mod 4) or p ≡ 1 (mod 4).
• The case of p ≡ 3 (mod 4): It follows from Lemma 3.3 and the above discussion that the curve in (3.9) is maximal if and only if 1 − a is a square in F p 2 .Since this condition is equivalent to that κ is a square in F p 2 , then the curve C : • The case of p ≡ 1 (mod 4): It follows from Lemma 3.3 and the above discussion that the curve in (3.9) is minimal if and only if 1 − a is a square in F p 2 .Since this condition is equivalent to that κ is a square in F p 2 , then the curve C : Therefore, this proposition is true.
Proposition 3.5.Assume that two genus-2 curves Proof.Here, we use notations in Subsection 3.1.Thanks to Main Theorem A (1), all α 1 , α 2 , β 1 , β 2 , γ 1 and γ 2 are elements of F p 2 .Hence, it follows from Proposition 2.13 (1) that a Richelot isogeny φ : Jac(C) → Jac(C ′ ) is defined over F p 2 , where C ′ is the form in (3.8).The transformation Then κ is a square in F p 2 by using Lemma 3.2, and hence this proposition is true (we note that we need only prove that for one Rosenhain form of C ′ by Lemma 2.4).
Proof of Main Theorem B. By using Proposition 3.4, this assertion holds for C such that the Jacobian variety of C is (2, 2)-isogenous to the product of two elliptic curves.Moreover, by using Proposition 3.5, this assertion holds also for C ′ such that C and C ′ are Richelot isogenous.By doing this repeatedly, we complete the proof for all genus-2 curves (recall from Algorithm 1 that this procedure ends in finite times).

Applications of Main Theorems
In this section, we give some results obtained by applying Main Theorems.In Subsection 4.1, we give another proof that there does not exist a superspecial genus-2 curve of characteristic p = 3.In Subsections 4.2 and 4.3, we will show that similar results as Main Theorem B hold for superspecial genus-3 and genus-4 hyperelliptic curves whose automorphism groups contain Z/2Z × Z/2Z.
4.1 Another proof of non-existence of superspecial genus-2 curve for p = 3 Ibukiyama-Katsura-Oort [7] showed that there are no superspecial genus-2 curves in characteristic p = 3, by computing the class numbers of quaternion hermitian forms.In the following, we give another proof of this.The next corollary holds for general p ≥ 3.
Corollary 4.1.Let S ⊂ F p 2 be the set of all elements s = 0, 1 such that both s and 1 − s are squares in F p 2 .If the genus-2 curve C : Proof.This is a direct consequence of Main Theorem A(1).

Application to genus-3 hyperelliptic curves
Moriya-Kudo studied the superspeciality of genus-3 hyperelliptic curves D such that Aut(D) ⊃ Z/2Z × Z/2Z in [13].They showed that such D can be written as for a, b, c ∈ K, and computed the number of isomorphism classes of superspecial D for small primes p ≤ 200.
In the following, we show that if D is superspecial, then a, b, c belongs to F p 2 and moreover D is maximal or minimal over F p 2 .
Theorem 4.3.Assume that a genus-3 hyperelliptic curve is superspecial.Then, we have the following statements: (1) Each a, b, c is a square in F p 2 .
(2) If p ≡ 3 (mod 4), then the curve D is maximal over F p 2 .Otherwise, the curve D is minimal over F p 2 .
Proof.As shown in [13, Section 2], the curve D is birational to the fiber product E × P 1 C where By the assumption that D is superspecial, then we have that E is supersingular and C is also superspecial.We consider the change of variables This transformed the curve E into the form (2) Using Auer-Top's result [1, Proposition 2.2], a supersingular elliptic curve v 2 = u(u − 1)(u − λ) is maximal (resp.minimal) over F p 2 when p ≡ 3 (resp.p ≡ 1), and so is the elliptic curve κv We see that E is maximal (resp.minimal) over F p 2 when p ≡ 3 (resp.p ≡ 1) since the transformation of (4.10) is defined over F p 2 .Moreover C is maximal (resp.minimal) over F p 2 when p ≡ 3 (resp.p ≡ 1) by using Main Theorem B. As the birational map D → E × P 1 C is defined over F p 2 , hence this theorem is true.

Application to genus-4 hyperelliptic curves
Similarly to the genus-3 case, Ohashi-Kudo-Harashita [18] studied the superspeciality of genus-4 hyperellitpic curves D ′ satisfying Aut(D ′ ) ⊃ Z/2Z × Z/2Z.They showed that such D ′ can be written as for a, b, c, d ∈ K, and computed the number of isomorphism classes of superspecial D ′ for all primes p ≤ 200.They also expected [18,Remark 3] that superspecial D ′ are all maximal or minimal over F p 2 .In the following, we prove their conjecture (Theorem 4.4).In addition, we give a simple criterion in terms of a, b, c, d that tells whether D ′ is maximal or minimal over F p 2 (Corollary 4.5).(2) The curve D ′ is maximal or minimal over F p 2 .
Proof.As shown in [18, Section 3], the curve D ′ is birational to the fiber product C 1 × P 1 C 2 where By the assumption that D ′ is superspecial, then we obtain that two curves C 1 and C 2 are also superspecial.We consider the change of variables and hence a, b, c and d are all squares in F p 2 .
• If 1 − a is a square in F p 2 , then two values κ = 1 − a and κ ′ = −(1 − a)bcd are squares in F p 2 .Since two transformations (4.11) and (4.12) are defined in F p 2 , and thus C 1 and C 2 are maximal (resp.minimal) over F p 2 if and only if p ≡ 3 (resp.p ≡ 1).As the birational map D ′ → C 1 × P 1 C 2 is defined over F p 2 , and hence D ′ is also maximal (resp.minimal) over F p 2 when p ≡ 3 (resp.p ≡ 1).
• If 1 − a is not a square in F p 2 , then κ = 1 − a and κ ′ = −(1 − a)bcd are also not squares in F p 2 .Since two transformations (4.11) and (4.12) are defined in F p 2 , and thus C 1 and C 2 are minimal (resp.maximal) over F p 2 if and only if p ≡ 3 (resp.p ≡ 1).As the birational map D ′ → C 1 × P 1 C 2 is defined over F p 2 , and hence D ′ is also minimal (resp.maximal) over F p 2 when p ≡ 3 (resp.p ≡ 1).
In any case, this theorem is true.
) Using Main Theorem A(1), all the 9 values a, b, c, 1 − a, 1 − b, 1 − c, a − b, b − c, c − a are squares in F p 2. Hence, we obtain the first assertion of this theorem.

Corollary 4 . 5 .•
Suppose that D ′ is superspecial, then the following are true:• If p ≡ 3 (mod 4), then D ′ is maximal if and only if a/all 1 − a, 1 − b, 1 − c, 1 − d is a square in F p 2 .If p ≡ 1 (mod 4), then D ′ is maximal if and only if a/all 1 − a, 1 − b, 1 − c, 1 − d is not a square in F p 2 .Proof.With notations in the proof of Theorem 4.4, all values squares in F p 2 .This implies all 1 − a, 1 − b, 1 − c, 1 − d are squares or none of these is a square.Hence, this corollary directly follows from the proof of Theorem 4.4 (2).
then the curve C coincided with the second case in Proposition 2.8 (i.e.RA(C) ⊃ C 2 ) by [11, Proposition 4.3].Lemma 2.9.The curve C of the form (2.4) is superspecial if and only if there exist t 1 and t 2 such that 12, Algorithm 7.1]).Calculating superspecial genus-2 curves using Richelot isogenies.Require: A rational prime p ≥ 7. Ensure: A list L of all superspecial genus-2 curves over F p 2 .1: Compute the set SsgEll(p 2 ) of F p 2 -isomorphism classes of supersingular elliptic curves over F p 2 .For each pair (E, E ′ ) of elements in SsgEll(p 2 ), compute the curves C whose Jacobians are (2, 2)-isogenous to E × E ′ (see [6, Section 3]).If C is not isomorphic to an element of L, then adjoin it to L. 4: Write L = {C 1 , . . ., C n }, and set i ← 1. 5: Compute the genus-2 curves C ′ which are Richelot isogenous to C i .If C ′ is not isomorphic to an element of L, then set N ← #L, C N +1 ← C ′ and adjoin it to L. 6: If i < #L, then set i ← i + 1 and go back to Step 5. 7: return L. Remark 2.11.As mentioned in Subsection 2.2, the Jacobian variety of genus-2 curve C is (2, 2)-isogenous to the product of two elliptic curves if and only if RA(C) ⊃ C 2 .Hence, we see that all the curves C generated in Step 3 satisfy RA(C) ⊃ C 2 .
2: Set L ← ∅. 3: [7,re ζ denotes a primitive fifth root of unity.It suffices to show that ζ is an element of F p 2 when C is superspecial, since all Rosenhain invariants of C can be written as a fractional expression of ζ.It is well-known[7, Proposition 1.13] that this curve is superspecial if and only if p ≡ 4 (mod 5), and hence one can check that ζ p 2= ζ when p ≡ 4 (mod 5).