Stieltjes-Bethe equations in higher genus and branched coverings with even ramifications

We describe projective structures on a Riemann surface corresponding to monodromy groups which have trivial $SL(2)$ monodromies around singularities and trivial $PSL(2)$ monodromies along homologically non-trivial loops on a Riemann surface. We propose a natural higher genus analog of Stieltjes-Bethe equations. Links with branched projective structures and with Hurwitz spaces with ramifications of even order are established. We find a higher genus analog of the genus zero Yang-Yang function (the function generating accessory parameters) and describe its similarity and difference with Bergman tau-function on the Hurwitz spaces.


Introduction
Let L be a Riemann surface of genus g. Consider the scalar differential equation of second order on L: (∂ 2 − U )ϕ = 0 (1.1) where the potential U is allowed to have first and second order poles on L. The equation (1.1) is invariant under the choice of the local coordinate if the solution ϕ transforms under a local coordinate change as a −1/2-differential while U transforms as 1/2 of projective connection [10].
In a local coordinate ξ on L one can write ϕ = φ(ξ)(dξ) −1/2 and U = u(ξ)(dξ) 2 ; then (1.1) takes the form φ ξξ − uφ = 0 . (1. 2) The ratio F =φ/ϕ of two linearly independent solutions of (1.1) (called the "developing map") satisfies the Schwarzian equation is the Schwarzian derivative. Denote poles of potential u by p 1 , . . . , p s and consider a set of 2g+s generators of the fundamental group π 1 (L\{p i } s i=1 , x 0 ) (x 0 is a non-singular point of potential u) which satisfy the standard relation The vector (φ, ϕ) of two linearly independent solutions of (1.1) which are defined in a neighbourhood of x 0 transforms under analytical continuation along any contour γ ∈ π 1 (L, x 0 ) as follows: where the monodromy matrix M γ is a priori defined only up to a sign due to spinorial nature of the solutions (ϕ,φ). The corresponding transformation of the solution F =φ/ϕ of the Schwarzian equation (1.3) looks as follows: (1.6) these transformations define the P SL(2, C) monodromy group of the equations (1.1), (1.3). The lift of this P SL(2, C) monodromy group to SL(2, C) (both for holomorphic and meromorphic potentials) was discussed in [8,1,15].
There exist several types of monodromy groups which attracted attention over the years: • Trivial SL(2) monodromy groups in genus 0, when for each γ we have M γ = I (for genus 0, due to existence of a distinguished coordinate x, one can talk about SL(2) monodromy representation of (1.1)). The monodromy-free potentials with second order poles on the Riemann sphere were extensively studied starting from classical works of Heine [11] and Stieltjes [21,22,23]. In terms of a solution ϕ of (1.1) the monodromy-free condition is equivalent to requirement that all residues of ϕ −2 vanish; this implies a system of algebraic equations for poles and zeros of ϕ. Remarkably, this system also appears in the construction of energy eigenstates for quantum sl(2) Gaudin system [9,26] where it is known as the system of Bethe equations. Coefficients at ξ −1 (ξ is a local parameter) at poles of u are classically known as accessory parameters; in the theory of Gaudin's systems these coefficients correspond to energy eigenvalues. When all monodromies are trivial the accessory parameters are given by derivatives of certain "potential" function which can be interpreted as logarithm of discriminant of a rational function φ (see for example formula (3.52) of [7]); this function also carries the name of "Yang-Yang" function [19].
Counting monodromy-free potentials with fixed poles of ϕ on the Riemann sphere (i.e. counting solutions of Bethe's equations with given poles of ϕ) is a non-trivial combinatorial problem solvable in terms of Catalan's numbers (see for example [24]).
• Monodromy groups (in any genus) corresponding to so-called "branched projective structures" introduced in [16,17] and studied more recently in [2]. Branched projective structures are defined by the condition that all SL(2) monodromies of equation (1.1) corresponding to generators γ i , i = 1, . . . , s are equal to (−1) r I (where r is the order of the corresponding branch point) while P SL(2, C) monodromies along generators α i and β i (monodromies of (1.1) along α i and β i are defined only up to a sign) form a representation of π 1 (L, x 0 ). In genus zero branched projective structures with even orders of branching are therefore described by solutions of (1.1) with trivial SL(2) monodromies.
In this paper we consider solutions of equations (1.1) and (1.3) on a Riemann surface of an arbitrary genus which correspond to trivial monodromy groups of equation (1.1). "Triviality" here means that all SL(2) monodromies M γ j are equal to I while all monodromies M α j , M β j (which are defined only up to a sign) are equal to ±I. We formulate higher genus analogs of Stieltjes-Bethe equations and introduce two possible definitions of higher genus accessory parameters together with their generating functions. In analogy to genus zero case the higher genus Stieltjes-Bethe equations define stationary points of a generating function in higher genus (this function generalizes the "Yang-Yang" function of [7] to higher genus). The case of genus 1 is treated in detail, closely following the classical genus zero case.
As an intermediate step we discuss branched projective structures corresponding to Abelian monodromy groups where all monodromy matrices M α j and M β j are upper-triangular and have unit diagonal. In genus 1 such monodromy groups correspond to solutions of Bethe equations for XYZ Gaudin's model [27]).
On the other hand, choosing the developing map F as a starting point of construction of monodromyfree potentials on a Riemann surface, we show that such potentials correspond to branched coverings of CP 1 with even orders of all branch points.
To describe these results in more technical terms assume that one of solutions ϕ of equation (1.1) is a meromorphic section of χ −1 where χ is one of 2 2g spin line bundles over L. Moreover, assume that all zeros x 1 . . . x n of ϕ are simple and multiplicities of its poles y 1 , . . . , y m equal to r 1 , . . . , r m . Let us label these points in a universal fashion by introducing the divisor (ϕ) = m+n j=1 d j p j such that −2(ϕ) is canonical. Choosing a fundamental polygonL of L in a way compatible with a chosen Torelli marking one can write ϕ as follows in terms of prime-forms (up to a multiplicative constant): where the prime-forms E(x, p j ) are evaluated at p j with respect to an arbitrary local coordinate. The holomorphic and non-vanishing "multidifferential" C(x) is given by (3.6); its properties are discussed in detail in ( [6], p.9-11); K x is the vector of Riemann constants with initial point x. Vectors β 1,2 ∈ Z g /2 are defined by equation −A x ((ϕ)) + K x + Ωβ 1 + β 2 = 0 where A x is the Abel map with initial point x and Ω is the period matrix of L (such vectors exist since the divisor −2(ϕ) is canonical). Triviality of SL(2) monodromies M γ j around poles x j is then equivalent to the system of equations Equations (1.8) guarantee that the potential u is non-singular at {x j }. Using the explicit form (1.7) of ϕ one can write equations (1.8) in a form analogous to genus 0 Stieltjes-Bethe equations: for k = 1, . . . , n − 1. Equations (1.9) are invariant under the change of local coordinates near {x j } and {y j }. Vanishing of P SL(2) monodromies M α j , M β j is equivalent to vanishing of corresponding periods of ϕ −2 : (1.10) Altogether (1.9) and (1.10), together with the requirement that divisor −2(D) is canonical give 3g + n − 1 conditions. If the Riemann surface L remains fixed the number of parameters is m + n (positions of {y j } m j=1 and {x j } n j=1 ); if L is allowed to vary we have 3g − 3 + m + n parameters. The difference i.e. the dimension of the space of monodromy-free potentials with m poles on Riemann surfaces of genus g equals m − 2. This means that generically one can not fix moduli of L and positions of {y j } arbitrarily for g ≥ 1; this situation is different from the case g = 0.
Choose a system of local coordinate ξ k near points of divisor D such that ξ k (p k ) = 0. We denote local coordinates near y k by ξ k , k = 1, . . . , m and near x k by ξ m+k , k = 1, . . . , n.
The potential u behaves as follows as x ∼ y k : 12) and the prime-forms are evaluated at {x k , y k } with respect to local coordinates {ξ k } m+n k=1 (H k don't depend on the choice of local coordinates near {x k }). As well as in the genus zero case, the higher genus Stieltjes-Bethe equations (1.9) and accessory parameters H k can be conveniently described in terms of one function: The function τ Y Y is considered as a function of {x k }, {y k } for a fixed Riemann surface L. Namely, Stieltjes-Bethe equations (1.9) are equivalent to conditions ∂ ∂ξ j+m ξ j+m =0 log τ Y Y = 0 , j = 1, . . . , n − 1 (1.14) while the accessory parameters H k are given by The function W = 2 log τ Y Y in genus zero is called the Yang-Yang function [19,7]; (1.14) is the natural analog of this function in higher genus. The genus zero version of Stieltjes-Bethe equations arises in construction of energy eigenstates in the XXX Gaudin's model; the accessory parameters are then equal to eigenvalues of commuting Hamiltonians [26]. Equations (1.9) in the genus one case, as well as the corresponding accessory parameters, arise in a similar way in solution of the XYZ Gaudin's model [27]; however, the period conditions (1.10) don't play an obvious role there. We are not aware of any existing generalization of these quantum models to higher genus case where higher genus Stieltjes-Bethe equations (1.9) would play a role. We expect these models to be quantum versions of SL(2) generalized Hitchin's systems.
Solution of higher genus system (1.9), (1.10) is difficult even in genus zero case. However, there is a simple alternative way of constructing the "monodromy-free" potentials of equation (1.1) whose starting point if the developing map F . Namely, triviality of monodromies of equation (1.1) (understood in the above sense) implies that F is a meromorphic function on L with simple poles and branch points of even order: Moreover, √ dF is a meromorphic section of a spin line bundle over L and are two linearly independent solutions of (1.1) which are singular only at y 1 , . . . , y m . Corresponding SL(2) monodromies around points x k as well as P SL(2) monodromies along (α j , β j ) are trivial.
This proposition gives a meromorphic potential of (1.1) starting from an an arbitrary branch covering of given genus with even ramifications. Positions of branch points are given by critical values z j = F (y j ) of function F i.e. by values of F at singularities of potential U . Therefore, we can not independently define moduli of L and positions of singularities of U on L: changing positions of z j also changes L. This phenomenon is of course related to the fact that in higher genus the total number of equations (1.9), (1.10) may exceed the number of variables {x j , y k }. In this formulation the problem of counting monodromy-free potentials for fixed z 1 , . . . , z m can be naturally formulated as (largely unsolved) problem of computation of Hurwitz numbers with even multiplicities of branch points. We notice also that according to Theorem 1.1 all monodromy-free potentials on a Riemann surface of higher genus are naturally divided into 2 2g equivalence classes, depending on spin line bundle defined by divisor (dF )/2.
The paper is organized as follows. In Section 2 we remind the construction of monodromy-free potentials of (1.1) in genus 0 and treat the parallel case of genus 1. In Section 3 we discuss monodromyfree equations (1.1) on Riemann surfaces of genus g, and their links with Hurwitz spaces with branch points of even multiplicity. We formulate higher genus analog of Bethe-Stieltjes equations and find generating function of corresponding accessory parameters (the "Yang-Yang function"). We also propose an alternative and more invariant way of defining accessory parameters in higher genus case and discuss their generating function.
2 Trivial monodromy representations, Stieltjes-Bethe equations and accessory parameters in genera 0 and 1

Genus zero
We start from reviewing a few facts about monodromy-free equations (1.1) and (1.3) in genus 0. In this case one can use the natural coordinate x on C obtained via stereographic projection of the Riemann sphere.
Assume that the potential u is a rational function of x with poles of order not higher than 2. Then triviality of P SL(2) monodromy representation of the Schwarzian equation is equivalent to rationality of the developing map F (x). In turn, the developing map defines two linearly independent solutions of the linear equation Rationality of solutions φ 1,2 (2.3) of the second order linear equation (2.2) i.e. triviality of the SL(2, C) monodromy representation of (2.2) is a stronger requirement than triviality of P SL(2) monodromy of the Fuchsian equation (2.1).. Namely, rationality of φ 1,2 is equivalent to the condition that F x is the square of a rational function i.e. that all poles and zeros of F x have even order. In terms of F it means that all critical points of F are of even order and all poles are of odd order.
Assume that poles of F are simple and denote them by x 1 , . . . , x n . Critical points of F are denoted by y 1 , . . . , y m and their multiplicities by 2r 1 , . . . , 2r m ; we have n − m j=1 r j = 1. On Riemann sphere there is unique (up to a Möbius transformation) meromorphic spinor with one simple pole; this spinor is given by (dx) 1/2 . Dividing expressions (2.3) by (dx) 1/2 one gets coordinateinvariant combinationsφ Rational functions F with these degrees of critical points and poles form Hurwitz space which we denote H 0 [2r] where r = (r 1 , . . . , r m ).

Remark 2.1
We emphasize the difference between the triviality of the P SL(2) monodromy representation of the Schwarzian equation (2.1) and the triviality of the SL(2) monodromy representation of the linear equation (2.2). Namely, the monodromy representation of (2.1) is trivial iff the developing map F is a rational function. The monodromy representation of (2.2) is trivial only when in addition all points of the divisor (dF ) are of even order.
On the other hand, if the starting point is a rational solution of (2.2) of the form (2.4) then the rationality of the function F (and, therefore, the rationality of the solutionφ (2.3)) is equivalent to vanishing of all residues of φ −2 dx: (the residue at x n vanishes automatically since the sum of residues at all x j is 0). Equations (2.5) are the famous Stieltjes-Bethe equations Equations (2.6) arise in the construction of eigenstates of Hamiltonians in quantum Gaudin's model [9,26]. For given critical points y j and their multiplicities r i the space of solutions of (2.6) has dimension 1 (n − 1 equations for n variables {x i }). If one of x i is fixed to be, say, 0 or ∞ then the computation of the number of solutions of (2.6) becomes a non-trivial combinatorial problem whose solution is given is terms of Catalan's numbers (see for example [24]).
A different combinatorial problem arises if one is interested in the number of solutions of the system (2.5) or (2.6) for given critical values z j = F (y j ) of the n-sheeted branched covering z = F (x) of genus 0 defined by function F . This problem is the problem of computation of Hurwitz numbers in genus 0 for higher order branch points; to the best of our knowledge it does not have a satisfactory solution except the well-studied case when all branch points are simple except one.

Accessory parameters and their generating function
When all zeros x j of φ are simple the potential u has at most simple poles at {x j }. Moreover, if the linear equation (2.2) is monodromy-free i.e. the Stieltjes-Bethe equation (2.6) hold, one can easily verify (see for example p.37 of [7]) that u is non-singular at all x j . Therefore, it has the following form: are called accessory parameters (see for example [29]). From the point of view of Gaudin's systems H j equal to eigenvalues of (commuting) quantum Hamiltonians corresponding to Bethe eigenstates [26].
for function τ Y Y given by [25,7]: The function τ Y Y is related to function W of [19,7] via τ Y Y = e W/2 . Introducing the following notation for divisor of ϕ: the expression (2.10) can be written in the "discriminant" form: If {x j } and {y j } are independent (2.6) then logarithmic derivatives of τ Y Y with respect to y j give the accessory parameters H j (2.8): due to (2.9) equations (2.13) hold also when {x j } and {y j } are related via Stieltjes-Bethe equations. The definition of accessory parameters H j can be rewritten in coordinate-invariant form as follows: where S dF = −2U is the (meromorphic) projective connection given by S dF (ξ) = {F (ξ), ξ}(dξ) 2 = −2u(x)(dx) 2 and S B is the projective connection given by Schwarzian derivative of coordinate x with respect to any other local coordinate ξ on CP 1 : The projective connection S B (2.16) is nothing but (up to a factor 1/6) the constant term in expansion of the bidifferential near diagonal x = y in a local parameter ξ. Namely, The numerator in (2.14) is a difference of two projective connections i.e. a meromorphic quadratic differential; dividing it by dx we get an abelian differential with well-defined residue. The bidifferential B(x, y) (as well as its generalization to higher genus), carries the name of canonical bidifferential [5], and is also called the Bergman bidifferential [28]; the corresponding projective connection S B is thus called the Bergman projective connection. In coordinate x on CP 1 obviously S B (x) ≡ 0; thus x is the developing map of projective structure given by projective connection S B .
The definition (2.14) of accessory parameters as it stands does not admit a generalization to genus greater than 1 (in genus one case one has a natural choice of global coordinate, thus a straightforward generalization of (2.14) does make sense). In higher genus one can replace x either by one of uniformization coordinates (Fuchsian, Schottky) or by developing map of some chosen projective structure. For example, a natural choice would be to take the developing map corresponding to higher genus Bergman projective connection (which, however, depends on Torelli marking of L).

An alternative definition of accessory parameters and Bergman tau-function
Equations (2.14) can be modified to give an alternative universal definition of accessory parameters which can be generalized to any genus. In this alternative definition one replaces dx in the denominator by another natural 1-form, dF ; then the definition of accessory parameters looks as follows: The generating function for accessory parametersH j with respect to critical values z j is also known; it is given by log(τ 3 B ) where τ B is the so-called Bergman tau-function [13]. Namely, The expression for τ 3 B looks as follows (this expression can be deduced from formulas of [13,14] via simple computation): The equation (2.18), as well as the alternative definition (2.17) of accessory parameters, admits a unique natural generalization to any genus.
Notice the similarity and difference between expressions (2.12) and (2.19): both expressions are singular only along hyperplanes p i = p j but with different degrees.

Parabolic triangular SL(2) monodromies in genus 0
Let equation (2.2) possess one solution φ of the form (2.4) but don't assume the Stieltjes-Bethe equations (2.6) to hold. Then the "second" solutioñ is non-singlevalued on CP 1 : it has logarithmic singularities at {x i } n i=1 . In this case the potential u = φ ′′ /φ generically has poles at all zeros {x j } and poles {y j } of φ.

Trivial SL(2) monodromies in genus one
The genus one case can be treated in parallel to the genus zero case due to existence of a natural coordinate on L. Let L be an elliptic curve with periods 1 and σ (corresponding to some Torelli marking) and with flat coordinate x such that v = dx is the normalized holomorphic differential on L. Then triviality of all P SL(2) monodromies of the Schwarz equation (1.3) is equivalent to the developing map F is a meromorphic function on L.
On the other hand, triviality of SL(2) monodromies M γ i of the linear equation (1.1) around singularities of U is a stronger requirement: it implies that, as in genus zero case, all points of divisor (dF ) have even multiplicity. Then formulas (2.3) again give two linearly independent solutions of equation (1.1) with trivial SL(2) monodromies around poles of U .
The (unique up to a constant) holomorphic spinor on L is given by √ dx; it is a holomorphic section of the only odd spin line bundle (this line bundle corresponds to characteristics [1/2, 1/2] irrespectively of Torelli marking; see the discussion of correspondence between theta-characteristics and spin line bundles in the next section which is devoted to the higher genus case).
Assume that one of solutions of equation (∂ 2 − U )ϕ = 0 is such that ϕ −1 is a meromorphic section of the odd spin line bundle and all of zeros of ϕ are simple.
Positions of poles in x-coordinate will be denoted by y 1 , . . . , y m and positions of zeros by x 1 , . . . , x n ; let (ϕ) = n i=1 x i − m i=1 r i y i and r 1 + · · · + r m = n. Since divisor −2(ϕ) is canonical (that is the same as trivial for g = 1) and divisor −(ϕ) corresponds to the odd spin line bundle one can introduce Then solution ϕ takes the form and θ 1 (x) = θ[1/2, 1/2](x, σ). Using periodicity properties of θ 1 it is easy to verify, taking (2.22) into account, that ϕ is a singlevalued meromorphic function on L.
The second linearly independent solutionφ(x) of equation φ xx − uφ = 0 is as usual given bỹ Due to uniqueness of the spinor (dx) 1/2 which is used to get function φ from the inverse spinor ϕ in a unique way one can define an SL(2) monodromy representation of (2.2) in genus 1 unambigously as monodromy of pair (φ, φ). Namely, the monodromy representation 1 is generated by matrices M α , M β , M x 1 , . . . , M xn with generators of the fundamental group chosen such that For any γ ∈ π 1 (L \ {x j } n j=1 ) the monodromy matrix M γ is again given by with P γ = γ φ −2 dx. We therefore get the following given by (2.24), (2.25), has all trivial SL(2) monodromies on elliptic curve L iff the following equations hold: In analogy to the genus zero case, one can alternatively start the description of monodromyfree potentials from a meromorphic developing map F having n simple poles and m critical points y 1 , . . . , y m of multiplicities 2r 1 , . . . , 2r m ( m i=1 r i = n). Corresponding solutionsφ and φ are then given byφ which are both meromorphic (i.e. the corresponding SL(2) monodromy representation is trivial) if √ F x is also a meromorphic function. Denote critical values of F by z j = F (y j ). The dimension of the moduli space of monodromy-free potentials (allowing the module of L to vary) gives the same number m − 2: a simultaneous shift and simultaneous rescaling of all critical values correspond to shift and rescaling of the developing map F ; this does not change the potential u.
The natural counting problem in this setting is to find the number of inequivalent pairs (L, F ) with given z 1 , . . . , z m . This number equals the Hurwitz number h 1,n (2r 1 , . . . , 2r m ); as well as in the genus zero case such problem does not have a satisfactory solution by now. Notice that in this counting problem the module of the Riemann surface is not fixed.

Stieltjes-Bethe equations on elliptic curve and accessory parameters
Equations (2.29) are direct elliptic analogs of genus zero Stieltjes-Bethe equations (2.6); they can be explicitly written as follows: Similarly to the genus 0 case, equations (2.32) are equivalent to equations (2.9): Equations (2.32) again guarantee that the potential u is non-singular at {x i }. Analyzing the singularity structure of u near y i we get, analogously to (2.7) that the quadratic residue of U (x) = u(x)(dx) 2 at y k equals to r k (r k + 1); therefore, and the accessory parameters H k are given by (2.37) The constant C is not equal to 0, in contrast to genus zero case; it can be expressed in terms of {x j , y j } but we don't need this expression here. The formulas (2.36), (2.37) are obtained by expressing u = φ ′′ /φ = (φ ′ /φ) ′ + (φ ′ /φ) 2 and taking into account that Analyzing the singular parts of u at y j we come to (2.36), (2.37). Accessory parameters H j can be expressed via the developing map F as in (2.14) where x is the flat coordinate on the torus, and the Bergman projective connection is given by the formula (27) and the last formula on p.34 of [5]: Although S B does not vanish in coordinate x (as in genus zero case), it is holomorphic and, therefore, does not contribute to the residue in (2.39).

Proposition 2.2
The accessory parameters H k are given by logarithmic derivatives of function τ Y Y defined by (2.35), with respect to y k : in both cases: when (x j , y j ) are independent (i.e. related only by condition that divisor −2(ϕ) is trivial) and when the Stieltjes-Bethe equations (2.32) hold. The Riemann surface L remains fixed under differentiation.
Proof. The proof is obtained by direct calculation.

Parabolic triangular and trivial monodromy groups in higher genus
Let now g ≥ 2. This case is different from g = 0 or g = 1 by the following reason. In genus zero there exists a unique (up to a Möbius transformation) meromorphic spinor √ dx. This spinor is used to rewrite the second order equation (∂ 2 − U )ϕ = 0 using x as independent variable and φ = ϕ √ dx as dependent variable in the coordinate form φ xx + uφ = 0. In turn, this allows to define the SL(2) monodromy representation. In genus one the transformation from ϕ to φ is performed using the flat coordinate x on elliptic curve and the only holomorphic odd spinor √ dx. For higher genus one can choose the universal coordinate in various ways (say, use the Fuchsian or Schottky uniformization coordinate). Another ambiguity is in the choice of a special spinor used in transformation from ϕ to φ (one natural way to define such spinor is proposed in [1]).
Let us assume that there exists a pair (φ, ϕ) of solutions of (1.1) such that all monodromy matrices have the form Then ϕ is a meromorphic section of a line bundle χ −1 where χ is (one of 2 2g ) spin line bundles over C ( χ 2 is the canonical line bundle); thus deg(ϕ) = 1 − g.
Consider the divisor D of ϕ. Assuming that all zeros of ϕ are simple we have since the divisor −2D is canonical, the divisor −D corresponds to some (even or odd) spin line bundle χ and n − m j=1 r j = 1 − g . Introduce some system of local coordinates {ξ j } near {p j } n+m j=1 such that ξ 1 , . . . , ξ m are local coordinates near y 1 , . . . , y m , respectively while ξ m+1 , . . . , ξ m+n are local coordinates near x 1 , . . . , x n , respectively.
The corresponding potential u has second order poles at points y j of the following form: While the quadratic residue r j (r j +1) is invariant under the change of local coordinate ξ j the coefficients H j (the "accessory parameters") are not. At the points x j the potential has in general poles of first order. The condition of holomorphy of U at x j is given by the following lemma: The proof is an elementary local computation: since φ has a first order zero at x j it can be written in a local coordinate ξ ≡ ξ m+j as follows: φ = aξ(1 + bξ + . . . ). Then which implies the statement of the lemma.

Parabolic triangular monodromies
Choose some canonical basis of cycles (the Torelli marking) . The dual basis of holomorphic differentials v 1 , . . . , v g is normalized by a i v j = δ ij and the period matrix of L is defined by Ω ij = b i v j . Introduce the theta-function Θ(z) = Θ(z, Ω) for z ∈ C g . Choose a fundamental 4g-goñ L of L in a way which agrees with the choice of canonical cycles (a i , b i ) (in fact, the contours forming the sides of the fundamental polygon correspond to a set of generators (α j , β j ) of the fundamental group of L). Denote vector of Riemann constants corresponding to a point x 0 ∈ L by K x 0 and denote the Abel map corresponding to initial point Introduce the prime-form E(x, y) [18] that is a multi-valued (−1/2, −1/2)-form on L. Holonomies of E(x, y) with respect to, say, the first variable x along cycle a j equal 1 while along cycle b j equal For any point p i ∈ D we shall use the notation A half-integer characteristic corresponding to divisor D (3.2) is defined by equation: where β 1,2 ∈ (Z/2) g are vectors with integer or half-integer components; we denote [β] = [β 1 , β 2 ]. Integration contours in (3.5) are chosen inside of the fundamental polygonL. Under a change of Torelli marking by a symplectic transformation and the corresponding change of the fundamental polygon the vectors β 1,2 are transformed according to formulas given on page 8 of [5]. For a contemporary discussion of the theory of theta-characteristics see [4]. Let us also introduce the following multi-valued g(1 − g)/2-differential on L (see (1.17) of [6]): is the Wronskian determinant of basic holomorphic differentials. The differential C(x) is non-singular and non-vanishing on L. Holonomies of C(x) along cycles a j and b j are equal to 1 and respectively.
Proof. The tensor weight of expression (3.9) to the sum of the contribution from C (which equals = − g 2 ) and contribution g−1 2 from the product of prime-forms (which equals to the product of degD = (1 − g) and −1/2). Thus the total tensor weight of φ equals −1/2.
The product of prime-forms gives poles and zeros of necessary degree at divisor D while other factors are non-singular and non-vanishing. It remains to verify that ϕ −2 is a well-defined meromorphic differential on L.
The only term in (3.9) which produces a non-trivial multiplier along cycle a j is the exponential term. The transformation of the exponential term follows from holonomy of the vector of Riemann constants along a j given by (see for example [18]) where e j = (0, . . . , 1, . . . , 0) t with 1 standing at jth place. Thus the holonomy of ϕ along cycle a j equals e 2πi(β 1 ) j = ±1; however, the sign of this holonomy can not be given an invariant meaning independent of the choice of fundamental polygon. What is however important for us in that ϕ −2 has trivial monodromy along all a-cycles. The holonomy of ϕ −2 along cycle b j can be computed multiplying the holonomies (3.4) of the prime-forms with holonomy (3.8) of C(x) and taking into account the definition of vectors β 1,2 (3.5). Another relation which needs to be used in this computation is the holonomy of the vector of Riemann constants along cycle b j : Then the holonomy of ϕ along b j is given by the exponent of the following expression: where the first two terms originate from C(x), the third term gives the holonomy of the exponential term in (3.9), and the sum gives holonomy of the product of prime-forms. Furthermore, using the relations m+n k=1 d k = 1 − g and (3.5) we can rewrite the sum over k in (3.12) as follows which, after substitution into (3.12), gives 14) The first three terms in (3.14) vanish due to the transformation property of the vector of Riemann constants. The terms containing β 1 vanish due to symmetry of matrix Ω. Therefore, the holonomy factor of ϕ along cycle b j formally equals e 2πi(β 2 ) j . We therefore conclude that ϕ −2 is a meromorphic differential on L which proves the proposition: the choice of the square root of the canonical bundle χ whose section is given by ϕ −1 is determined by the choice of divisor D.
Choosing some local coordinate ξ on L we define the following function h(ξ) in the corresponding coordinate chart: Then the potential U can be written in this local coordinate as follows: Proposition 3.2 Define −1/2-differential ϕ on L via (3.9) and introduceφ viã for some base point x 0 . Thenφ and ϕ form a pair of linearly independent solutions of equation (1.1) with potential U given by (3.16). The corresponding P SL(2) monodromy representation looks as follows: for any γ ∈ π 1 (L\{x j } n j=1 ) the monodromy matrix is given by The proof is straightforward. Since ϕ −1 is a meromorphic spinor on L the only source of a nontrivial P SL(2) monodromy is the non-singlevaluedness of the Abelian integral x x 0 ϕ −2 ; the contributions to monodromy matrices are given by periods of ϕ −2 in the lower off-diagonal term as in (3.18).
Notice that the off-diagonal terms of monodromy matrices around points x j are given (up to the factor of 2πi) by residues of ϕ −2 at points x j . Moreover, although P SL(2) monodromies around y j are trivial, the SL(2) monodromies of equation (1.1) around y j are well-defined and are equal either to I or −I, depending on parity of r j .
If we denote the Abelian differential ϕ −2 by W (x) then the Schwarz equation corresponding to these solutions of (1.1) looks as follows: for any local parameter ξ(x).

Projective structures with even branching
The previous construction gives examples of so-called branched projective structures [16,17]. For recent developments in this area we refer to [2,8]. The branched projective structures on a Riemann surface can be characterized in terms of equations (1.1) with meromorphic potential in the following way: all P SL(2) monodromies of the developing map around singularities of U are trivial. The branched projective structures arising in our context are described in the following definition: where ϕ is given by (3.9) (conditions (3.20) are equivalent to the requirement that ϕ −2 is a meromorphic abelian differential of second kind). Then the Abelian integral F (x) =φ/ϕ = x x 0 ϕ −2 gives a developing map of an even branched projective structure. Monodromy matrices along remaining loops (α i , β i ) corresponding to such branched projective structures have the triangular parabolic form (3.18) i.e. these matrices are determined by a-and b-periods of the differential ϕ −2 .
Although this proposition is essentially tautological, the condition of vanishing of residues of ϕ −2 is highly non-trivial for n > 1 since all poles x j of ϕ −2 are of even order. The cases n = 0 (when ϕ −2 is a holomorphic differential with even orders of its zeros) and n = 1 (when ϕ −2 has only one pole of order 2 and zeros of even order zeros of ϕ −2 ) are therefore special. To prove this proposition it is sufficient to notice that for n = 0, 1 conditions (3.20) are empty. Moreover, for n = 0 the starting point of the construction can be any holomorphic abelian differential (say, W ) on L with zeros of even orders 2r 1 , . . . , 2r m . Then √ W is a spinor on L (i.e. a section of one of 2 2g square roots of canonical bundle). One can define the solution ϕ via ϕ = 1/ √ W and the developing map via the abelian integral of W (branched projective structures of this type were discussed in [2]). We notice that such branched projective structures, as well as all other projective structures discussed in this paper, can be divided into 2 2g equivalence classes labelled by spin structure (in particular, they can be naturally divided into the even and odd ones).

Stieltjes-Bethe equations in higher genus and even branched projective structures
For n ≥ 2 conditions (3.20) are non-trivial. Proposition 3.5 Let g ≥ 2, m ≥ 2. Then the triviality of SL(2) monodromies around all points of divisor D is equivalent to the following system of n − 1 equations: is a local parameter near x k . The same convention is used to define C(x k ). Derivatives C ′ (x k ) are taken with respect to the same local parameters. For any two points of divisor D we define E(p j , p k ) = E(x, y) dξ j (x) dξ k (y) x=p j ,y=p k The dimension of the subspace of the moduli space of branched projective structures arising via this construction equals 2g − 2 + m. This dimension is equal to the number of parameters (3g − 3 moduli of L plus n + m points of divisor D) minus the number of conditions (g conditions stating that divisor −2D is canonical and n − 1 equations (3.21)). We recall that the dimension of the moduli space of all branched projective structures (with m branch points and fixed branching orders) equals 6g − 6 + m.
Notice also that the space of branch projective structures obtained via our construction consists of 2 2g components labelled by square roots of canonical line bundle.

Accessory parameters and their generating function
Accessory parameters H j in higher genus are defined by the local behaviour (3.3) of potential u near y j . For solution ϕ given by (3.9) they are given by (the index 2 denotes the derivative of the prime-form with respect to its second variable) which looks as a direct generalization of the of the low genus formulas (2.8) and (2.37).
Notice that the definition (3.23) of accessory parameters in more ambiguous than in genera 0 and 1 where a distinguished coordinate on L exists. In g ≥ 2 accessory parameters H k depend on the choice of local coordinates near all {x j } and {y j }.
Similarly to genera 0 and 1, both the higher genus Stieltjes-Bethe equations (3.21) and accessory parameters (3.23) can be described in terms of a single scalar function.
where the prime-forms are evaluated with respect to the local coordinates {ξ j }: Equivalently (recall that n+m i=1 d i p i = n j=1 x j − m k=1 r k y k ), the formula (3.24) can be written as follows: . (3.26) Comparing the formula for τ Y Y (3.26) with the higher genus Stieltjes-Bethe equations (3.21) and the expressions (3.23) for accessory parameters H j we get the following Proposition 3.6 The higher genus Stieltjes-Bethe equations (3.21) are equivalent to vanishing of derivatives of function τ Y Y (3.26) with respect to zeros x j which in terms of corresponding local parameters ξ k can be written as follows: where the Riemann surface L is assumed to be fixed. The system of equations (3.27) does not depend on the choice of local coordinate ξ m+1 , . . . , ξ m+n near x 1 , . . . , x n . Accessory parameters (3.23) are given by (3.28) Remark 3. 1 We are not aware of existence of a quantum model whose Bethe equations coincide with conditions (3.21) of triviality of SL(2) monodromies around y j . However, we expect that such system (presumably a quantum version of a generalized Hitchin system) should exist, in analogy to genera 0 and 1.
The definition (3.23) of accessory parameters H j can be made less ambiguous if one uses one of special coordinates to write the expansion (3.3) of the potential neat points y j (say, Schottky or Fuchsian uniformization coordinates). Another choice of such coordinate would be to introduce the developing map ζ B (x) of equation (∂ 2 − 1 2 S B )ϕ = 0, where S B is the Bergman projective connection in higher genus. The definition of S B is discussed in detail in [5,28,12,1]: similarly to (2.16), S B is, up to a factor 1/6, a constant term in the expansion of the canonical bimeromorphic differential B(x, y) = d x d y log E(x, y) near the diagonal x = y; S B depends on Torelli marking of L.
The developing map ξ B solves the Schwarzian equation {ξ B (x), ·} = S B (x) (we don't know what monodromy representation corresponds to this equation). Denoting the developing map of equation (1.1) with trivial monodromies by F (which is a meromorphic function with simple poles at {x j } and critical points at y j ) we can write the definition (3.3), (3.23) of accessory parameters H j of (1.1) which corresponds to coordinate ξ B in the following form: If the function τ Y Y (3.24) is also computed using the local coordinate ξ B near all points of divisor (ϕ) then the accessory parameters H B j are obtained as logarithmic derivatives of τ Y Y with respect to ξ B (y j ) as in (3.28).

Trivial monodromies and Hurwitz spaces with even ramifications
A special case of branched projective structures is the case when the developing map has all trivial P SL(2, C) monodromies i.e. the developing map is a meromorphic function on the Riemann surface. If, moreover, such branched projective structure is even then all zeros and poles of the differential dF should be of even degree such that all SL(2) monodromies around y j are equal to I.
Then both solutions, ϕ andφ of (1.1) are sections of χ −1 for some spin line bundle χ over L. This implies vanishing of all periods of the meromorphic differential ϕ −2 , and not only residues at x j i.e. we get the following Proposition 3.7 Let ϕ be a section of line bundle χ −1 given by (3.9) where divisor D is defined by (3.2). Let, moreover, period of 1-form ϕ −2 over any cycle s ∈ H 1 (L \ {x j } n j=1 vanish, i.e.
Then all SL(2) monodromies of equation ( around singularities of U are trivial. All P SL(2) monodromies along generators α j and β j are also trivial.
The dimension of the space S g [r] of the inverse spinors (3.9) corresponding to given r = (r 1 , . . . , r m ) on Riemann surfaces of given genus is given by (3.32) is naturally stratified into 2 2g strata corresponding to different spin line bundles over L.
Proof. The number of parameters in (3.9) equals 3g − 3 + n + m − g = 2g − 3 + n + m (which is the sum of the dimension of moduli space of Riemann surfaces and number of points of divisor D such that divisor −2D is canonical). The number of conditions in (3.30), (3.31) equals 2g + n − 1. The difference of these two numbers equals m − 2, as stated.
If ϕ satisfies conditions (3.30), (3.31) then the developing map i.e. the Abelian integral . If the coverings corresponding to functions F and αF + β are identified for any α, β ∈ C (such coverings correspond to the same ϕ, up to a multiplicative constant), we get the quotient H g [2r]/{F ∼ αF + β} which is naturally identified with the space S g [r] of monodromy-free potentials with double poles with quadratic residues given by (3.3) .
The natural coordinates on the space H g [2r] are the critical values of function F : z j = F (y j ) , j = 1, . . . , m (3.35) By transformation of the form z → αz + β one can always put z 1 = 0, z 2 = 1. Then the remaining m − 2 critical values z 3 , . . . , z m can be used as local coordinates on the space of monodromy-free potentials.
The above discussion can be summarized as follows. √ dF is a meromorphic section of a spin line bundle over L, the equation (1.1) has all trivial SL(2) monodromies and two linearly independent solutions of (1.1) are given bỹ Notice that in Prop.3.8 no restriction on genus is necessary, it is also valid in g = 0 and g = 1 cases.

Alternative definition of accessory parameters and Bergman tau-function on Hurwitz spaces
In the Hurwitz picture one can propose an alternative definition of accessory parameters (denoted bỹ H j ) following the definition (2.18) in genera 0 and 1: The parametersH j are generated by the Bergman tau-function on Hurwitz space with respect to critical values z j : 2 ∂ ∂z j log(τ This makes the product of prime-forms in (3.40) significantly different from the product of primeforms in (3.24) which are evaluated in an arbitrary system of local coordinates near {p j } (specifying these coordinates to be given by the "Bergman" coordinate ξ B one gets accessory parameters in the form (3.29)).
The difference in the evaluation of prime-forms (3.43) in (3.40) and (3.25) in (3.24) implies, in particular, different asymptotics near the boundary, when two points of the divisor D coalesce. Namely, denoting by t a coordinate near the boundary of moduli space which corresponds to merging of p j and p k the function τ Y Y behaves in the limit t → 0, similarly to the genus zero case (2.10) as The asymptotics of τ 3 B , on the other hand, looks as follows as t → 0 (similarly to genus 0 formula (2.19)): (3.44) Notice also that variation with respect to z j in (3.39) changes the conformal structure of the Riemann surface L, in contrast to variation with respect to positions of y j in formulas (3.28) for H j .
Finally, we would like to mention an open question of computing the "Yang-Yang" function in a different context, when the monodromy representation of (1.1) is generic [19]. Then the Yang-Yang function is defined as generating function between complex Fenchel-Nielsen coordinates on an SL(2) character variety and canonical coordinates on T * M g,n . In this formulation the problem of computation of τ Y Y is more complicated; a partial result towards description of this function was obtained in [1] where it was shown that τ Y Y transforms as a section of Hodge line bundle over M g,n under a change of Torelli marking.