L Chekhov

B Eynard

O Marchal

Topological expansion of the Bethe ansatz, and quantum algebraic geometry

Keywords: real eigenvalues

In this article, we solve the loop equations of the β-random matrix model, in a way similar to what was found for the case of hermitian matrices β = 1. For β = 1, the solution was expressed in terms of algebraic geometry properties of an algebraic spectral curve of equation y 2 = U(x). For arbitrary β, the spectral curve is no longer algebraic, it is a Schrödinger equation ((

In this article, we find a solution of loop equations, which takes the same form as the topological recursion found for β = 1. This allows to define natural generalizations of all algebraic geometry properties, like the notions of genus, cycles, forms of 1st, 2nd and 3rd kind, Riemann bilinear identities, and spectral invariants F g , for a quantum spectral curve, i.e. a D-module of the form y 2 -U(x), where [y, x] = . Also, our method allows to enumerate non-oriented discrete surfaces.

6.4 Form-cycle duality . . . . . . . .

Introduction

Spectral invariants and algebraic geometry

In [START_REF] Eynard | Topological expansion for the 1-hermitian matrix model correlation functions[END_REF][START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF], was presented the definition of spectral invariants F g for any algebraic plane curve, i.e. given by a polynomial equation E(x, y) = i,j E i,j x i y j = 0.

Those invariants F g (E) are defined in terms of algebraic geometry quantities defined on the Riemann surface of equation E(x, y) = 0. Their definition involves residues at branchpoints of some meromorphic forms. Their definition provides a natural basis of meromorphic forms of 1st, 2nd and 3rd kind, and a natural framework for all algebraic geometry notions.

1 Moreover, the invariants F g of [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF] have many nice properties, for instance their deformations under changes of the complex structure of E is given by some "special geometry" relations, and provide a natural form-cycle duality. Also, they are invariants under changes of E which conserve the symplectic form dx ∧ dy in C × C, they have nice modular properties, and finally, they define the tau-function of some dispersionfull integrable system associated to E.

Also, those invariants F g have deep relationships with enumerative geometry, for instance they have been related to the Kodaira-Spencer theory [START_REF] Dijkgraaf | Two Dimensional Kodaira-Spencer Theory and Three Dimensional Chern-Simons Gravity[END_REF], to combinatorics of discrete surfaces (maps), to intersection theory [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF][START_REF] Eynard | Recursion between Mumford volumes of moduli spaces[END_REF], and they are conjectured to be equal to the Gromov-Witten invariants of some toric Calabi-Yau target 3-folds [START_REF] Bouchard | Remodeling the B-model[END_REF].

Algebraic geometry on "quantum" curves

Here, our goal is to define those notions for a "quantum curve", where E(x, y) is a non-commutative polynomial of x and y:

E(x, y) = i,j E i,j x i y j , [y, x] = .
The notion of quantum curve has arised in many ways in the litterature [START_REF] Dijkgraaf | Quantum Curves and D-Modules[END_REF], and is also called D-modules, i.e. a space of functions quotiented by Ker E(x, y), where y = ∂/∂x.

In other words, one has to study functions ψ(x) such that:

E(x, ∂ x ).ψ(x) = 0.

In our attempt to define the spectral invariants analogous to those of [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF] for such Dmodules, we are naturally led to define all analogous properties of algebraic geometry. For instance we define the notions of branch points, sheets, genus, cycles, forms, Bergman kernel, and so on... Because of non-commutativity, some notions like branch-points, cuts and sheets, become "blurred" or "non-localized", i.e. the branchpoint is no longer a point, but a "region" of the complex plane, and cuts are asymptotic accumulation lines of points.

But, otherwise, it is surprising to find that almost all relationships of classical algebraic geometry, remained unchanged when = 0, for instance the Riemann bilinear identity, the Rauch variational formula, and the topological recursion defining the spectral invariants.

Moreover, we shall find, that in order for our quantities to make sense, we must have a "vanishing monodromy" condition, which can be interpreted as a Bethe ansatz, and this gives a geometrical interpretation of the Bethe ansatz.

Let us also mention that in a previous article [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF], we treated a special case, where the Schrödinger potential U(x) was quantized, and we shall see, under the light of this new work, that it was the case of a degenerate quantum surface, with no branchpoints.

Hyperelliptical case

Here, for simplicity, we shall restrict ourselves to polynomials of degree 2 in y (called hyperelliptical in algebraic geometry), of the form:

E(x, y) = y 2 -U(x) , [y, x] =
i.e. to the Schrödinger equation:

2 ψ ′′ = Uψ.
We leave the higher degree case for a further work.

Link with β matrix models

The spectral invariants F g were first introduced for the solution of loop equations arising in the 1-hermitian random matrix model [START_REF] Eynard | Topological expansion for the 1-hermitian matrix model correlation functions[END_REF][START_REF] Chekhov | Hermitean matrix model free energy: Feynman graph technique for all genera[END_REF]. They were later generalized to other hermitian multi-matrix models [START_REF] Chekhov | Free energy topological expansion for the 2-matrix model[END_REF][START_REF] Eynard | Topological expansion of the chain of matrices[END_REF].

There exist other matrix models, which are defined with non hermitian matrices. In fact it is well known since Wigner [START_REF] Mehta | Random matrices (3e edition)[END_REF] that depending on the symmetry of the problem, it is sometimes interesting to have matrices that are not hermitian. (For example, realsymmetric, unitary, orthogonal or quaternionic, ...). Therefore, it seems reasonable to extend the definition of the spectral invariants for those other models. Those other matrix models are often called β-ensembles, and they are classified by an exponent β. The 3 Wigner ensembles (see [START_REF] Mehta | Random matrices (3e edition)[END_REF], and we changed β → β/2) correspond to β = 1 (hermitian case), β = 1/2 (real symmetric case), β = 2 (real self-dual quaternion case), but it is easy to define a β one-matrix model for any other value of β (see section 9 for more details).

In [START_REF] Chekhov | Matrix eigenvalue model: Feynman graph technique for all genera[END_REF], a first attempt to generalize the solution of [START_REF] Eynard | Topological expansion for the 1-hermitian matrix model correlation functions[END_REF] to other matrix models was proposed, but it was not as nice as the topological recursion of [START_REF] Eynard | Topological expansion for the 1-hermitian matrix model correlation functions[END_REF]. In [START_REF] Chekhov | Matrix eigenvalue model: Feynman graph technique for all genera[END_REF], it was assumed that β = O(1) when the size N of the random matrix becomes large, and it was found that all spectral invariants were related to a double series expansion of the form:

g,k N 2-2g-k ( β -1/ β) k F g,k
The coefficients F g,k were computed in [START_REF] Chekhov | Matrix eigenvalue model: Feynman graph technique for all genera[END_REF]. Here, in this article, we shall work at fixed = ( √ β -1/ √ β)/N, instead of fixed β, i.e. we shall define the resummed F g 's as:

F g ( ) = k k F g,k .
The F g,k 's of [START_REF] Chekhov | Matrix eigenvalue model: Feynman graph technique for all genera[END_REF] can be recovered by computing the semi-classical small expansion of F g ( ). In this article we shall argue that F g ( ) is the natural generalization of the symplectic invariants of [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF] for a "quantum spectral curve" E(x, y) with [y, x] = .

The tool which we use for studying the β-matrix model, is the loop equation method. Loop equations are related to the invariance of an integral under change of variable. They can be obtained by integrating by parts. Loop equations for the β-matrix model have been written many times [START_REF] Dumitriu | Matrix models for beta ensembles[END_REF][START_REF] Eynard | Asymptotics of skew orthogonal polynomials[END_REF], and here we show how to solve them order by order in 1/N, at fixed .

The β-matrix model and its loop equations are explained in section 9.

Schrödinger equation and Bethe ansatz 2.1 Schrödinger equation, generalities and notation

Let:

2 ψ ′′ (x) = U(x) ψ(x) (2.1)
be a Schrödinger equation with U(x) a polynomial. Let U(x) be a polynomial of degree 2d, and define the polynomial "potential" V (x) of degree d + 1 by its derivative:

V ′ (x) = 2 ( √ U ) + = d k=0 t k+1 x k (2.2)
where () + means the polynomial part of the Laurent series at x → ∞. We also define:

P (x) = V ′2 (x) 4 -U(x) - V ′′ (x) 2 (2.3)
so that P is a polynomial of degree d -1.

Eventually, we define:

t 0 = lim x→∞ xP (x) V ′ (x) (2.4)
Remark 2.1 Just in order to give names to those parameters, let us say that in the language of integrable systems, the coefficients t 0 , t 1 , t 2 , . . . , t d+1 are called the "Casimirs", and the remaining coefficients of P are the "conserved charges". They will play a special role later on in this article. In matrix model language (see section 9), t 1 , . . . , t d+1 are called the times associated to the potential V (x), t 0 is often called the temperature, and the remaining coefficients of P are called "filling fractions". In the language of algebraic geometry, parameters t k with k ≥ 1 are coupled to 2nd kind meromorphic differential forms, t 0 is coupled to 3rd kind, and the remaining coefficients of P are coupled to 1st kind holomorphic differentials, see section 6 about form-cycle duality.

Stokes Sectors

From the study of the Schrödinger equation we know that the function ψ(x) is subject to the Stokes phenomenon, i.e. although ψ(x) is an entire function, its asymptotics look discontinuous near ∞. We therefore need to introduce properly the Stokes sectors by defining the following quantities: Let

θ 0 = Arg(t d+1 )
be the argument of the leading coefficient of V (x).

We define the Stokes lines going to ∞ as:

L k = x / Arg(x) = - θ 0 d + 1 + π k + 1 2 d + 1 (2.5)
Those are the lines where ReV (x) vanishes asymptotically. We define the sectors:

S k = Arg(x) ∈] - θ 0 d + 1 + π k -1 2 d + 1 , - θ 0 d + 1 + π k + 1 2 d + 1 [ (2.6)
i.e. S k is the sector between L k-1 and L k . Notice that in even sectors we have asymptotically ReV (x) > 0 and in odd sectors we have ReV (x) < 0.

Stokes phenomenon

Any solution of a linear equation, is analytical where the coefficients of the equation are analytical, and it may possibly have essential singularities where the coefficients are singular. Here, U(x) is an entire function with a singularity (a pole), only at ∞, thus, any solution ψ is an entire function with a possible essential singularity at ∞. The asymptotics of ψ near ∞ are subject to the Stokes phenomenon. This means that, although ψ is analytical in the whole complex plane, its asymptotics at infinity may change from sectors to sectors.

From the study of the Schrödinger equation it is known that in each sector S k , ψ(x) has a large x expansion:

ψ(x) ∼ S k e ± 1 2 V (x) x C k (A k + B k x + . . . )
and the sign ±, may jump discontinuously from one sector to another as well as the numbers A k , B k , C k , . . . (and in general, all the coefficients of the series in 1 x j at infinity).

Decreasing solution

Let us consider a specific solution ψ(x) of the Schrödinger equation which is exponentially decreasing in some even sector at infinity. For writing convenience, we will choose ψ(z) = ψ 0 (z) a decreasing solution in sector S 0 . Without further indication, ψ(z) is now understood to be ψ 0 (z) in the rest of the article. Note that this choice is quite arbitrary at the moment, and one should wonder if the quantities we are about to compute depend on this choice, but we are presently not able to answer this question properly, and leave it for further study.

An important and useful result is the Stokes theorem which claims that if the asymptotics of ψ(x) is exponentially small in some sector, then the same asymptotics holds in the two adjacent sectors (and therefore ψ(x) is exponentially large in those two sectors).

In the general case, (i.e. a generic potential U(x)) our solution ψ(x) is decreasing only in sector 0, and is exponentially large in all other sectors. But if the Schrödinger potential U(x) is non-generic (quantized), then there may exist several sectors in which ψ(x) is exponentially small. Due to Stokes theorem, if ψ is exponentially small in some sectors then it must be exponentially large in the adjacent sectors, this implies that there are at most d + 1 sectors in which ψ is exponentially small. The case studied in [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] was the most degenerate case, such that ψ is exponentially small in d + 1 sectors.

Zeroes of ψ

The main difference with our previous article [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] is that we will not restrict ourselves to the case where ψ(x) is a quasi-polynomial which can only be obtained with very non-generic potential U(x). Here ψ(x) is an entire function with an essential singularity at ∞, and with isolated zeroes labelled s i :

ψ(s i ) = 0 (2.7)
In particular, the number of zeroes of ψ may be finite or infinite.

If ψ(x) has an infinite number of zeroes, it is known that the zeroes may only accumulate near ∞, and only along the Stokes half-lines L j 's bordering the sectors (see fig. 2). In fact, there is an accumulation of zeroes along the half-line L j if and only if ψ is exponentially large on both sides of the half-line.

For example in the case where ψ(x) = ψ k (x) is a solution that exponentially decreases in sector k then it implies that there is no accumulation of zeroes along the half-lines L k and L k-1 .

If U(x) is generic, then ψ has an infinite number of zeroes, and the zeroes accumulate at ∞ along all half-lines L j with j = 1, 2d + 1 (because remember that ψ is implicitely assumed to be ψ 0 which decreases in sector 0), i.e. there are generically 2d half-lines of zeroes. The situation is illustrated in fig 2. If U(x) is non-generic (quantized), then there are additional sectors in which ψ is exponentially small, and thus there can be no zeroes accumulating along the two halflines bordering these sectors. Remember that from Stokes theorem, each time we have a new sector in which ψ is decreasing, we have two half-lines less of zeroes. Therefore, the number of half-lines of zeroes is always even, and we call it: Definition 2.1 The genus g of the Schrödinger equation is defined by:

2g + 2 = # half-lines of zeroes (2.8)
And if ψ has a finite number of zeroes (i.e. there is no half-line of zeroes), we define

g = -1. We have -1 ≤ g ≤ d -1 (2.9)
Note also that the definition of g a priori depends on the choice of the solution ψ = ψ 0 since two different solutions of the same Schrödinger equation may have different numbers of semi-lines of zero accumulation.

An exception, is in the special cases g = -1 where it is easy to see that every choice of ψ = ψ 2k would give the same value of g.

Indeed, consider g 2k and g 2k ′ be the genus defined from the solutions ψ 2k exponentially small in sector S 2k and ψ 2k ′ exponentially small in sector S 2k ′ : if g 2k = -1, this means that ψ 2k is exponentially small in all even sectors, in particular in sector S 2k ′ , and therefore ψ 2k ∝ ψ 2k ′ , and therefore g 2k ′ = -1.

Case g = -1

The case g = -1 was studied in [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF]. This is the case where ψ has only a finite number of zeroes, it is a quasipolynomial:

ψ(x) e 2 V (x) = polynomial.
(2.10)

Notice that in order to diminish g by 1, we need to quantize one parameter of U, and therefore to reach g, we need to quantize d -1g parameters. In particular, to reach g = -1, we need to quantize d parameters, i.e. P is completely fixed in terms of V ′ , and in particular, t 0 is quantized.

In the applications to random matrices, t 0 is usually a free parameter (called the temperature) and is never considered quantized, and therefore the case g = -1 is never obtained in random matrices.

Another way to say that, is that the case g = -1 has no → 0 classical limit, and therefore in classical geometry we always have g ≥ 0.

Resolvent

The first ingredient of our strategy is to define a resolvent similar to the one in matrix models.

Definition 2.2 We define the resolvent for a generic solution ψ by:

ω(x) = ψ ′ (x) ψ(x) + V ′ (x) 2 (2.11)
It is clear that this function is analytical except at the zeros of ψ(x) where it has simple poles with residue :

ω(x) ∼ x→s i x -s i + reg. (2.12)
It also has a possible essential singularity at infinity with the same location of discontinuities as ψ(x). Eventually, note again that the definition of ω(x) depends on the choice of ψ(x).

Sheets

In sector S k we have the asymptotic:

ψ(x) ∼ S k e η k 2 V (x) x -η k t 0 -d 1+η k 2 (A k + B k x + . . . ) (2.13)
where η k = ±1. That translates for the resolvent to:

ω(x) ∼ x→∞ k 1 + η k 2 (V ′ (x) - d x ) - η k t 0 x + O(1/x 2 ), (2.14)
Therefore it depends if the solution ψ is exponentially big or small in sector k (and of course on the parity of k). For a generic g = d -1 solution which is exponentially big in every sector except S 0 (and thus has an alternating sign in the exponential) then η k = (-1) k (except η 0 = -1).

Definition 2.3 We call "physical sheet", the union of sectors where η k = -1, in those sectors we have:

ω(x) ∼ t 0 x + O(1/x 2 ) (2.15)
Notice that the sectors S 0 , S 1 and S 2d+1 are always in the physical sheet. And we call "second sheet", the union of sectors where η k = +1, in those sectors we have:

ω(x) ∼ V ′ (x) + O(1/x) (2.16)
This definition comes from the analogy with the resolvent in matrix model (see section 9 for details). For a generic potential U(x), all odd sectors are in the physical sheet, and all even sectors except S 0 are in the second sheet.

Notice that if g = -1, there is only the physical sheet, i.e. there is no second sheet.

The Bethe ansatz

In the polynomial case studied before [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF], a key ingredient for establishing results was the Bethe ansatz. This ansatz basically deals with the behaviour of ω(x) around zeroes of ψ. The zeroes of ψ are called "Bethe roots". The Bethe ansatz can be formulated in many ways. One way to formulate it, is to say that 1/ψ 2 has no residue at the s i 's:

Res s i 1 ψ 2 (x) = 0 (2.17)
in this way, it will play a key role in defining contour integrals, because all integrals of the type dx/ψ 2 (x) are insensitive to the exact location integration path with respect to the s i 's, i.e. such integrals will depend only on the homotopy classes of paths.

Equation (2.17) can also be formulated, in a form very similar to the Bethe ansatz in the Gaudin model [START_REF] Gaudin | La fonction d'onde de Bethe[END_REF][START_REF] Babelon | Introduction to Classical Integrable Systems[END_REF] as follows:

Theorem 2.1 The roots s i of ψ satisfy the Bethe ansatz:

∀ i , V ′ (s i ) = 2 lim x→s i ω(x) -x -s i . (2.18)
It is a regularized version of the Bethe equation for Gaudin model:

∀i , V ′ (s i ) " = " 2 j =i 1 s i -s j
when the number of zeros is infinite and the sum is ill-defined.

proof:

This theorem is a classical result and is easy, it just consists in rewriting the Schrödinger equation as a Ricatti equation. We proceed the same way as in [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] and compute:

V ′ (x)ω(x) -ω 2 (x) -ω ′ (x) = V ′ (x)( ψ ′ (x) ψ(x) + V ′ (x) 2 ) - V ′ (x) 2 4 + V ′ (x) ψ ′ (x) ψ(x) + 2 ψ ′ (x) 2 ψ 2 (x) - ψ ′′ (x) ψ(x) - ψ ′2 (x) ψ 2 (x) + V ′′ (x) 2 = V ′ (x) 2 4 -2 ψ ′′ (x) ψ(x) - V ′′ (x) 2 = V ′ (x) 2 4 -U(x) - V ′′ (x) 2 = P (x) (2.19)
which is a polynomial in x, of degree d -1.

From its definition, it is clear that ω 2 + ω ′ has no double pole at the s i 's, but it could have simple poles. Consider now a zero s i of ψ, and define: ωi (x) = ω(x)xs i Then, ωi (x) is regular at x = s i , and we may compute ωi (s i ). Compute:

Res x→s i ω 2 (x) + ω ′ (x) = Res x→s i ω2 i (x) + 2 ωi (x) x -s i + 2 (x -s i ) 2 + ω′ i (x) - 2 (x -s i ) 2 = Res x→s i 2 ωi (x) x -s i = 2 ωi (s i ) (2.20)
On the other hand we have, from eq. (2.19) we have:

Res x→s i ω 2 (x) + ω ′ (x) = Res x→s i V ′ (x)ω(x) -P (x) = Res x→s i V ′ (x)ω(x) = V ′ (s i ) (2.21)
Therefore we find :

∀ i , V ′ (s i ) = 2 ωi (s i ).
This equation is the Bethe equation for the roots s i 's. Note that the potential V ′ (x) is completely determined by the data of the potential U(x) and does not depend on ψ.

In particular, in the case where there are only a finite number of s i 's we recognize the Bethe equation for Gaudin model [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF]:

∀i , V ′ (s i ) = 2 j =i 1 s i -s j
which were completely defining the s i 's.

3 Towards a "Quantum Riemann Surface"

From the definition of our non-commutative spectral curve (i.e the Schrödinger equation), it is tempting to generalize the classical notions kwown in algebraic geometry and Riemann surfaces to our "quantum" case ("quantum" is not to be understood as "quantized" but as "non-commutative" [y, x] = ). For a Riemann surface, the central notions are those of cuts, sheets, genus, cycles and meromorphic differentials forms of 1st, 2nd and 3rd kind. In our context, the picture needs a proper adaptation in order to recover the terminology of Riemann surfaces and algebraic geometry.

In this section we will define the notions of genus, A-cycles, B-cycles and the first kind differentials dual to them. Here, let us assume that g ≥ 0.

Cuts

First, we like to think of the 2 sheets, as the sectors which correspond to the 2 possible behaviors of the resolvent at ∞: ω(x) ∼ t 0 /x (physical sheet) or ω(x) ∼ V ′ (x) (second sheet).

Then, we consider the cuts as sets of roots s i 's. In some sense, each pair of half lines of accumulation of zeroes can be thought of as a cut.

Definition 3.1 We define cuts as pairs of half-lines of zeroes.

There is some arbitrariness in grouping the half-lines of zeroes by pairs.

There is g + 1 cuts, like in classical algebraic geometry, and notice that the case g = -1 which has no classical counterpart, has no cuts.

Notice that, contrarily to classical geometry, where the endpoints of the cuts are zeroes of U(x), here the endpoints are somehow blurred, we may move a finite number of s i 's from one cut to another.

Cycles

In standard algebraic geometry, the non-contractible A-cycles are often thought of as surrounding cuts in the physical sheet, and their dual B-cycles are going through the cuts, from one sheet to the other, see fig 3.

A-Cycles

Consider the complex plane from which we remove the second sheet (sectors where ω(x) ∼ V ′ (x)). It is clear that it contains g + 1 sectors near ∞, and there are g homologically linearly independent contours which link them.

Definition 3.2

We define A-cycles A 1 , . . . , A g as g linearly independent noncontractible contours going from ∞ to ∞ in the physical sheet.

A choice of A-cycles is not unique. Remark that this notion really makes sense only for g ≥ 1.

Notice that each time ψ(x) ∼ e -V (x)/2 in an even sector, it means it is exponentially small and thus it also behaves like e -V (x)/2 in the neighboring odd sectors. That means that we can always choose A-cycles going from odd sector to odd sector.

Since the first sheet and second sheet are separated by half-lines of accumulations of zeroes, every A-cycle surrounds an even number of such half-lines of accumulations of zeroes, i.e. surrounds the cuts in the physical sheet. Like in standard algebraic geometry, the cuts are identified as pairs of half-lines of zeroes accumulations and the A cycles are going enclosing these cuts.

Examples

In the generic case g = d -1, we can define d A-cycles but only d -1 are linearly independent. See picture where d = 7: We clearly see that the dashed contour is not linearly independent with the others since the global sum of the contours (dashed included) is contractible in the physical sheet.

For a non-generic case, there are sectors at infinity where ψ is exponentially small. In these cases, the definition of the contours need some adaptations because these sectors correspond to "degenerate" cuts. Here are a few examples of how to deal with these cases. Basically, each time there are two sectors where ψ is small we can replace one of the standard A cycle, by a  cycle (sometimes called also "degenerate" A cycles) that connect them. Here are some examples of the contours in more and more peculiar situations for d = 7: It is then easy to generalize the method in more sophiticated situations. In the extreme case where ψ is exponentially small in all even sectors, there are only d independant "degenerate"  cycles and no A cycles, the genus is g = -1. This is the polynomial case studied in [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] where there are no A cycles.

exp(-V/(2h)) exp(+V/(2h)) exp(+V/(2h)) A cycles Line of accumulation of zeroes 2 exp(+V/(2h)) exp(+V/(2h)) exp(+V/(2h)) exp(+V/(2h)) exp(+V/(2h)) exp(+V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(-V/(2h)) 0
From the definitions, it is easy to see that the genus g defined above corresponds to the number of independant A cycles (we exclude the  cycles). It is also obvious that the sum of independant A and  cycles always equals d -1.

B-Cycles

As in classical algebraic geometry, it is standard to define the B cycles with an origin lying in the non-independant cut. Moreover, although it would be possible to define B cycles attached to the  cycles, we prefer limiting ourselves to the definition of B cycles attached only to the A cycles. Basically, they start from the non-independant cut, goes through their corresponding A cycle and end at infinity in the same sector as their corresponding A cycle. As there are two sectors in which their corresponding A cycle ends, we double them so that one goes into one sector and the other one in the second sector. We also choose the whole so that they intersect only with their corresponding A-cycles:

A α ∩ B β = 2δ α,β (3.1)
This definition is easier understandable with the following pictures: Generic case:

B cycles exp(-V/(2h)) exp(-V/(2h))
(-V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(+V/(2h))
Degenerate A-cycles

First kind functions

After defining the cycles, another important step is to define the equivalent of the first, second and third kind differentials. In this section, we propose a definition of the first kind differentials. Let h k , k = 1, . . . , d -1, be a basis (arbitrary for the moment, but we will choose it orthonormal later on), of the complex vector space of polynomials of degree ≤ d -2.

To have more convenient notation, we will label the Â-cycles as

A α , g + 1 ≤ α ≤ d -1 and the standard A are labelled A α , 1 ≤ α ≤ g.
Consider the following functions:

v k (x) = 1 ψ 2 (x) x ∞ 0 h k (x ′ ) ψ 2 (x ′ ) dx ′ , deg h k ≤ d -2. (3.2)
Notice that, thanks to the Bethe ansatz, v k (x) has double poles with vanishing residues at the s j 's (the zeroes of ψ), and behaves like O(1/x 2 ) in sector S 0 and in sectors where ψ is exponentially large. (because the polynomial is of degree less than d -2). Therefore, the following integrals are well defined:

I k,α = Aα v k (x) dx , α = 1, . . . , g, k = 1, . . . , d -1. (3.3)
For the degenerate contours Âα , we cannot take the integral since it would not converge. We define instead:

I k,α = Âα h k (x) ψ 2 (x) dx , α = g + 1, . . . , d -1, k = 1, . . . , d -1. (3.4)
The matrix I k,α with k, α = 1, . . . , d -1 is a square matrix, which gives a pairing between the set of paths { A α , Âα } and the space of polynomials of degree at most d -2. Let us choose a basis h k , dual to the A-cycles, i.e.:

I k,α = δ k,α . (3.5)
Choosing this set of polynomials gives then the following relations:

∀ i = 1, . . . , g, j = 1, . . . , d -1 , A i v j (x) dx = δ i,j (3.6
)

∀i = g + 1, . . . , d -1, j = 1, . . . , d -1 : Âi h j (x) ψ 2 (x) dx = δ j,i (3.7)
Moreover, from the definitions, we get an asymptotic expression of v k (x) at infinity:

Theorem 3.1 The functions v k (x) with k ≤ g are such that: k = 1, . . . , g, v k (x) = O(x -2 ) (3.8)
in all sectors at infinity. And the functions v k (x) with g + 1 ≤ k ≤ d -1 are such that:

k = g + 1, . . . , d -1, v k (x) = O(x -2 ) (3.9)
in all sectors except in the sector where Âk ends, where we have:

v k (x) = 1 ψ(x) 2 + O(1/x 2 ).
(3.10)

proof:

In sector ∞ 0 , we clearly have v k (x) ∼ O(x deg h k -d ) = O(x -2
). And in a sector S i where ψ is exponentially small we have:

v k (x) = 1 ψ 2 (x) x ∞ i h k (x ′ ) ψ 2 (x ′ ) dx ′ + ∞ i ∞ 0 h k (x ′ ) ψ 2 (x ′ ) dx ′ , (3.11)
and due to our choice of basis eq. (3.5), we have

v k (x) = δ i,i k ψ(x) 2 + 1 ψ 2 (x) x ∞ i h k (x ′ ) ψ 2 (x ′ ) dx ′ = δ i,i k ψ(x) 2 + O(1/x 2 ), (3.12)
in sector S i . We claim that the function v k (x) k = 1, . . . , g are the generalization of holomorphic forms (1st kind differentials). Remark 3.1 Classical limit.

The small BKW expansion

ψ ∼ e ± 1 2 R √ U gives: v k (x) ∼ ±h k (x) U (x) (3.13)
and v k (x)dx are indeed the holomorphic forms on the algebraic curve y 2 = U (x).

Riemann matrix of periods

An interesting quantity in standard algebraic geometry is the Riemann matrix of periods which is the integrations of the holomorphic differentials over B-cycles. Now that we have defined properly the cycles, we can define a similar "quantum" Riemann period matrix τ i,j , i, j = 1, . . . , g by:

τ i,j def = B i v j (x) dx. (3.14)
Note that this definition makes sense since v j (x) (j = 1, . . . , g) behaves as O(1/x 2 ) in the sectors where the B-cycles go. Also, thanks to the Bethe ansatz, v j has no residue at the roots s i 's, therefore those integrals depend only on the homology class of B-cycles, and not on a representent.

Like for the classical Riemann matrix of periods we have the following property:

Theorem 3.2
The period matrix τ is symmetric: τ i,j = τ j,i .

proof:

We anticipate on results which shall be proved later, but which don't depend on this theorem. The proof comes directly from theorem 4.10 below, since:

B β dx Bα B(x, z)dz = 2iπ B β dxv α (x) = 2iπτ β,α
and from the symmetry theorem 4.11 for the Bergman kernel B(x, z) = B(z, x):

B β dx Bα B(x, z)dz = Bα dz B β dxB(x, z) = 2iπ Bα dzv β (z) = 2iπτ α,β .

Filling fractions

In random matrices, the notion of filling fractions, is just the A-cycle integrals of the resolvent. Here, we easily generalize it by the definition: Definition 3.3 The filling fractions ǫ 1 , . . . , ǫ d are defined as follows:

α = 1, . . . , g, ǫ α = 1 2iπ Aα ω(x) - t 0 x + t 0 n α (d + 1) (3.15)
where the integer n α is half the number of Stokes half-lines surrounded by the cycle A α .

In other words, 2nα 2d+2 corresponds to the angular fraction of the complex plane defined by the cycle A α .

For α = g + 1, . . . , d -1 we define

α = g + 1, . . . , d -1, ǫ α = 0 (3.16)
And for α = d, we choose a non-independent A-cycle A d , which surrounds all the s i 's which are not surrounded by A 1 , . . . , A g , and define:

ǫ d = 1 2iπ A d ω(x) - t 0 x + t 0 n d (d + 1) (3.17)
Note that this definition makes sense because all the cycles A α go from an infinity where ω(x) -t 0

x ∼ O 1 x 2 . Note also that this definition depends on the exact locus of the contour A α and not only on its homotopy class, since ω(x) has simple poles at the s i 's with residue . If we deform the contour A α , the filling fractions can change by some integer times .

In other words, the filling fractions are "blurred" when = 0, they are defined modulo an integer times . In the classical limit → 0, they become deterministic.

We have:

Theorem 3.3 d α=1 ǫ α = t 0 (3.18)
proof:

When we perform the sum over the contours A α , the contour A d was defined as the "complementary" of the others, i.e. so that the sum is contractible. Since the function x → ω(x)t 0 /x is integrable at infinity, we find that its global integral is null. With the same argument, it is easy to see that d α=1 n α = (d + 1) because we take all Stokes lines once and only once. Therefore we get:

d α=1 ǫ α = 0 + t 0 d + 1 d α=1 n α = t 0 .
Note that it also tells us that only d -1 of the epsilon's are independant. Remark 3.2 In the case g = -1, the only filling fraction is ǫ d = t 0 , and it is also the sum of residues of ω at the s i 's:

ǫ d = t 0 = i Res s i ω = #{s i }
This shows again, that g = -1 corresponds to a case where t 0 is quantized, namely t 0 is an integer times :

t 0 / ∈ N.

Kernels

One of the key geometric objects in [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] and in [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF], is the "recursion kernel" K(x, z).

It was used in the context of matrix models, to find a solution of loop equations. Here, it will also allow us to define the 3rd and 2nd kind differentials.

The recursion kernel K

First we define:

K(x, z) = 1 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ x ′ -z (4.1)
and for each α = 1, . . . , g, we choose a point P α ∈ A α and we define:

C α (z) = Aα dx ′′ ψ 2 (x ′′ ) Pα ∞ 0 ψ 2 (x ′ ) dx ′ x ′ -z + Aα dx ′′ ψ 2 (x ′′ ) x ′′ Pα ψ 2 (x ′ ) dx ′ x ′ -z (4.2)
where in the last integral, the integration contour between P α and x ′′ , is along A α . This is described in fig. 4. For each α = g + 1, . . . , d -1, we define:

Infinity
C α (z) = Âα ψ 2 (x ′ ) dx ′ x ′ -z . (4.3)
We now need to describe the domain of definition of these functions. First, one can see that for a fixed x, these functions are defined for z outside of some "cuts" (see figure 4)

• Choose a path between ∞ 0 and x, then K(x, z) is defined for z outside of this path. Across the path ]∞ 0 , x], K(x, z) has a discontinuity:

δ K(x, z) = 2iπ ψ 2 (z) ψ 2 (x) (4.4)
• For each α = 1, . . . g, choose a path between ∞ 0 and P α , then C α (z) is defined for z outside of this path, and outside A α . Across the path ]∞ 0 , P α ], C α (z) has a discontinuity:

δC α (z) = 2iπ ψ 2 (z) Aα dx ′′ ψ 2 (x ′′ ) (4.5)
and across the path A α , C α (z) has a discontinuity:

δC α (z) = 2iπ ψ 2 (z) z Pα dx ′′ ψ 2 (x ′′ ) (4.6)
• For each α = g + 1, . . . , d -1, C α (z) is defined for z outside of the path Âα . Across the path Âα , C α (z) has a discontinuity:

δC α (z) = 2iπ ψ 2 (z) (4.7)
From these remarks, we now define the recursion kernel K(x, z) by: Definition 4.1 Definition of the recursion kernel:

K(x, z) = K(x, z) - d-1 α=1 v α (x) C α (z) (4.8)
it is defined for z outside the cuts mentionned above.

For a fixed z, the analytical properties in x of K(x, z) are the same as those of K(x, z) since all v α (x) are analytic. For a fixed z, the primitive of ψ 2 (x ′ ) dx ′

x ′ -z can be defined locally but not globaly on the complex plane. In fact there is a logarithmic cut to be arbitrarily chosen on ]∞ 0 , z]. Anywhere out of this cut the function x → K(x, z) is analytic.

Properties of kernel K

The definition of the kernel K(x, z) might seem arbitrary at first glance. But in fact, the main reason for the introduction of such kernel is that it has many interesting properties:

It is clear from our definitions that:

Theorem 4.1 For a given z, the kernel K behaves like:

K(x, z) ∼ O(x -2 ) (4.9)
when x → ∞ in all sectors.

proof:

The result is obvious for sector S 0 and for sectors where ψ is exponentially big. When it is not, the fact that we substract C α , α = g + 1, . . . , d -1 gives the result. Theorem 4.2 We have in all sectors at infinity :

K(x, z) ∼ z→∞ O(z -d ).
(4.10)

More precisely we have:

K(x, z) ∼ - ∞ k=d-1 K k (x) z k+1 (4.11) with Kk (x) = 1 ψ 2 (x) x ∞ 0 x ′k ψ 2 (x ′ ) dx ′ , (4.12)
and

K k (x) = Kk (x) - g α=1 v α (x) Aα Kk (x ′ ) dx ′ - d-1 α=g+1 v α (x) Aα ψ 2 (x ′ ) x ′k dx ′ . (4.13) proof: It is clear that K(x, z) ∼ - ∞ k=0 Kk (x) z k+1 (4.14)
where

Kk (x) = 1 ψ 2 (x) x ∞ 0 x ′k ψ 2 (x ′ ) dx ′ , (4.15)
and therefore

K k (x) = Kk (x) - g α=1 v α (x) Aα Kk (x ′ ) dx ′ - d-1 α=g+1 v α (x) Aα ψ 2 (x ′ ) x ′k dx ′ (4.16) Now, if k ≤ d -2, notice that x ′k is a polynomial of degree ≤ d -2,
and it is thus a linear combinations of h α (x)'s:

x ′k = d-1 β=1 b k,β h β (x ′ ) (4.17)
This implies:

Kk (x) = d-1 β=1 b k,β v β (x) (4.18)
Taking now the integral over an A cycle and using the normalization choice of

h k (x) gives: If α ≤ g Aα Kk (x ′ ) dx ′ = b k,α (4.19) and if α > g Aα ψ 2 (x ′ ) x ′k dx ′ = b k,α (4.20)
This implies that K k (x) = 0 if k ≤ d -2, and therefore

K(x, z) = O(z -d ). (4.21)
Theorem 4.3 Let α = 1, . . . , g, and z on the side of A α which does not contain ∞ 0 , then:

Aα K(x, z) dx = 0 (4.22)
proof:

Notice that if z is on that side of A α , we have C α (z) = Aα K(x, z) dx, and therefore

Aα K(x, z) dx = 0. In fact one can see that the addition of the part with the C α (z) was just put there to cancel out the A-cycle integrals.

Third kind differential: kernel G(x, z)

The second important kernel to define is the equivalent of the third kind differential.

In [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] this kernel was computed from K by derivation, and we use the same definition.

Definition 4.2

We define the kernel G(x, z) by:

G(x, z) = -ψ 2 (z) ∂ z K(x, z) ψ 2 (z) = 2 ψ ′ (z) ψ(z) K(x, z) -∂ z K(x, z) (4.23)
From an easy integration by parts we find:

G(x, z) = - 1 x -z + 2 ψ 2 (x) x ∞ 0 dx ′ x ′ -z ψ 2 (x ′ ) ψ ′ (x ′ ) ψ(x ′ ) - ψ ′ (z) ψ(z) - α v α (x) ψ 2 (z)∂ z C α (z) ψ 2 (z) (4.24)
which shows that near x = z we have G(x, z) ∼ 1 z-x , i.e. there is a simple pole of residue 1 at z = x. Note in particular that 1

x ′ -z ψ ′ (x ′ ) ψ(x ′ ) -ψ ′ (z) ψ(z)
has no singularity at x ′ = z and therefore for a fixed z, there is no more any logarithmic cut ]∞, z] as we had for K(x, z).

Note again that a priori, this function of z has the same lines of discontinuity as the kernel K(x, z). But notice that the definition of G ensures that all discontinuities of K which are proportional to ψ 2 (z) cancel.

Theorem 4.4 G(x, z) is an analytical function of x, with a simple pole at x = z with residue -1, and double poles at the s j 's (zeros of ψ(x)) with vanishing residue, and possibly an essential singularity around ∞.

G(x, z) is an analytical function of z, with a simple pole at z = x with residue +1, simple poles at z = s j , and with a discontinuity across A α -cycles with α = 1, . . . , g (and thus no discontinuity on Âα ):

δG(x, z) = -2iπ v α (x) (4.25) proof: K(x, z) is discontinuous when z crosses either ]∞ 0 , x],
]∞ 0 , P α ] or A α . However, the discontinuity of K(x, z) across ]∞ 0 , x], ]∞ 0 , P α ], and Âα is proportional to ψ 2 (z), and this means by derivation that G(x, z) is not discontinuous there. Across A α with α ≤ g, the discontinuity of K(x, z) is given by eq. (4.7), and thus, the discontinuity of

G(x, z) is δG(x, z) = -2iπ v α (x).
Since K(x, z) is regular when z = s j , then it is clear that G(x, z) has simple poles at z = s j , with residue -2 K(x, s j ).

In the variable x, it is clear from the definition and from the Bethe ansatz 2.18, that K(x, z) has double poles at x = s j without residue, and this properties follows for G(x, z).

lim z→∞ k G(x, z) = G(x, ∞ k ) = η k t d+1 K d-1 (x) (4.27)
where

η k = ±1 is such that ψ ∼ e η k V /2 in sector S k .
proof:

The large x behavior follows from theorem 4.1. The large z behavior is given by theorem 4.2, i.e. G(x, z)

∼ η k V ′ (z)K(x, z) ∼ η k t d+1 K d-1 (x).
The sign depends on the behavior of the solution in this sector. .

Semi-classical limit

We claim that this kernel is the quantum version of the third kind differential. Indeed, in classical algebraic geometry a third kind differential is characterized by analyticity except a simple pole with non vanishing residue and a proper normalization on Acycles. Here, apart from the discontinuity along the A-cycles which is expected since these contours represent the "quantum cuts", we have analyticity (apart from the s i 's which also define the cuts), a simple pole with residue and a good normalization on A-cycles.

In the BKW semiclassical expansion we have ψ ∼ e ±1 R √ U and thus

K(x, z) ∼ 2 x -z 1 U(x) (4.29) and K(x, z) ∼ 1 x -z 1 2 U(x) - α v α (x) C α (z) (4.30) and G(x, z) ∼ 2 U(z)K(x, z) ∼ 1 x -z U(z) U(x) -2 α v α (x) C α (z) U(z) (4.31)
The form G(x, z)dx has thus a simple pole at x = z, in the physical sheet with residue +1 and in the other sheet with residue -1, and it is normalized on A-cycles A i G(x, z)dx = 0. This is indeed the usual 3rd kind differential in classical algebraic geometry.

The Bergman kernel B(x, z)

In classical algebraic geometry, the Bergman kernel is the fundamental second kind differential, it is the derivative of the 3rd kind differential, and it is another major tool in classical algebraic geometry. Following the same definition as in [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF], we define:

B(x, z) = - 1 2 ∂ z G(x, z). (4.32)
The kernel B is going to be called the "quantum" Bergman kernel.

Theorem 4.7 B(x, z) is an analytical function of x, with a double pole at x = z with no residue, and double poles at the s j 's with vanishing residues, and possibly an essential singularity around ∞. B(x, z) is an analytical function of z, with a double pole at z = x with no residue, and double poles at the s j 's with vanishing residues, and possibly an essential singularity around ∞. In particular it has no discontinuity along the A cycles, it is defined analytically in the whole complex plane except at those double poles.

proof:

Those properties follow easily from those of G(x, z) of theorem 4.4. In particular, it is important to notice that the only discontinuity of G(x, z) is along the A-cycles, and is independent of z, therefore B(x, z) has no discontinuity there. proof: Follows from the large x and z behaviors of G(x, z).

Theorem 4.9 B satisfies the loop equations:

(2 ψ ′ (x) ψ(x) + ∂ x ) B(x, z) - 1 2(x -z) 2 + ∂ z ψ ′ (x) ψ(x) -ψ ′ (z) ψ(z) x -z = P (0) 2 (x, z) (4.35)
where

P (0) 2 (x, z) is a polynomial in x of degree at most d -2. And (2 ψ ′ (z) ψ(z) + ∂ z ) B(x, z) - 1 2(x -z) 2 + ∂ x ψ ′ (x) ψ(x) -ψ ′ (z) ψ(z) x -z = P (0) 2 (z, x) (4.36)
where

P (0) 2 (z, x) is a polynomial in z of degree at most d -2.
proof: This theorem is crucial for all what follows, and its proof is rather non-trivial. Since it is very long and technical, we present the proof in appendix A. Those equations are indeed the loop equations for the 2-point function in the β matrix model, see section 9. proof:

The vanishing of A-cycle integrals in the x variable is by construction and can be seen as the consequence of the same result known for G(x, z) on one side of A and the fact that B(x, z) has no discontinuity along the A-cycles. (Therefore, the nullity extend on both sides which no longer need to be treated separately).

For the z variable, notice that if

A α =]∞ i , ∞ j [ goes from ∞ i to ∞ j
, where both ∞ i and ∞ j are in the physical sheet, we have:

Aα B(x, z)dz = ∞ j ∞ i B(x, z)dz = - 1 2 (G(x, ∞ j ) -G(x, ∞ i )) (4.39)
and from theorem 4.5 G(x, ∞ i ) = η i t d+1 K d-1 (x), we get:

Aα B(x, z)dz = ∞ j ∞ i B(x, z)dz = η i -η j 2 t d+1 K d-1 (x) (4.40)
and since ∞ i and ∞ j are both in the physical sheet we have η i = η j = -1, and therefore And similarly, when performing the integral over B α , the contribution from infinities cancels out since the contour goes in the same sheet. But since B α intersects its corresponding A α (and only this one) where the primitive -1 2 G(x, z) is discontinous, the result is the jump of G(x, z) along this A α , that is to say iπv α (x). Eventually, since B α and A α intersect twice, we find eq. (4.10).

One of our key theorems is:

Theorem 4.11 B(x, z) is symmetric B(x, z) = B(z, x) (4.42)
proof:

The proof relies essentially on the fact that B(x, z) satisfies the loop equation in the two variables. We have:

(2 ψ ′ (z) ψ(z) + ∂ z ) (2 ψ ′ (x) ψ(x) + ∂ x ) (B(x, z) - 1 2(x -z) 2 ) 29 = (2 ψ ′ (z) ψ(z) + ∂ z ) P (0) 2 (x, z) -∂ z ψ ′ (x) ψ(x) -ψ ′ (z) ψ(z) x -z = (2 ψ ′ (x) ψ(x) + ∂ x ) P (0) 2 (z, x) -∂ x ψ ′ (x) ψ(x) -ψ ′ (z) ψ(z)
xz (4.43) This implies:

(2 ψ ′ (z) ψ(z) + ∂ z ) P (0) 2 (x, z) -( 2
ψ ′ (x) ψ(x) + ∂ x ) P (0) 2 (z, x) = (2 ψ ′ (z) ψ(z) + ∂ z )∂ z ψ ′ (x) ψ(x) -ψ ′ (z) ψ(z)
xz

-(2 ψ ′ (x) ψ(x) + ∂ x )∂ x ψ ′ (x) ψ(x) -ψ ′ (z) ψ(z) x -z = 2 U(x) -U(z) (x -z) 2 - U ′ (x) + U ′ (z) x -z (4.44)
and therefore:

(x -z) 2 (2 ψ ′ (z) ψ(z) + ∂ z ) P (0) 2 (x, z) + 2U(z) + (x -z)U ′ (z) = (x -z) 2 (2 ψ ′ (x) ψ(x) + ∂ x ) P (0) 2 (z, x) + 2U(x) + (z -x)U ′ (x) def = R(x, z) (4.45)
Here, the first line is a polynomial in x, whereas the second line is also a polynomial in z. Therefore, R(x, z) is a polynomial in both variables, of degree at most d in each variable. Moreover, we must have:

R(x, x) = 2U(x) (4.46)
Therefore we must have:

R(x, z) = 1 2 1 2 V ′ (x)V ′ (z) - V ′ (x) -V ′ (z) x -z -P (x) -P (z) + (x -z) 2 R(x, z) (4
.47) where R(x, z) is a polynomial of both variables of degree at most d -2 in each variable.

Putting this back into 4.45 and using the symmetry x ↔ z it implies that:

(2

ψ ′ (z) ψ(z) + ∂ z ) (P (0) 2 (x, z) - P (0) 2 (x, z)) = R(x, z) -R(z, x) (4.48)
Then, we can decompose the r.h.s into the basis h α (x)h β (z) introduced in 3.6:

R(x, z) -R(z, x) = d-1 α,β=1 ( Rα,β -Rβ,α )h α (x)h β (z) (4.49)
Integrating the differential equation eq. (4.48) then gives:

P (0) 2 (x, z) - P (0) 2 (x, z) = d-1 α,β=1 ( Rα,β -Rβ,α )h α (x) v β (z) + A 1 (x) (4.50)
where A 1 (x) is some integration constant. Then using the loop equations 4.9 we find by substraction that:

2 ψ ′ (y) ψ(y) + ∂ y (B(y, z) -B(z, y)) = P (0) 2 (y, z) - P (0) 2 (y, z) (4.51)
and again, integrating this differential equation we find:

B(x, z) -B(z, x) = d-1 α,β=1 ( Rα,β -Rβ,α )v α (x) v β (z) + A(x) + Ã(z) (4.52)
where (2ψ ′ /ψ + ∂)A = A 1 , and Ã(z) is some other integration constant.

The large x and large z behavior of B imply that A(x) = Ã(z) = 0. We thus get:

B(x, z) -B(z, x) = α,β ( Rα,β -Rβ,α ) ṽα (x)ṽ β (z) (4.53)
Then, using theorem 4.10 that is to say by 4.53 that the Bergman kernel is symmetric.

We claim that all these properties are essential to name this function a "quantum Bergman kernel". Indeed, the symmetry is absolutely necessary and is completely nontrivial. The fact that B(x, z) has no discontinuity is also essential since in standard algebraic geometry, it is defined everywhere on the Riemann surface. Using all these kernels and their properties, we can then generalize easily the recursion of [START_REF] Eynard | Topological expansion for the 1-hermitian matrix model correlation functions[END_REF][START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] defining the correlation functions.

R(x) = 1 ψ 2 (x) x ∞ 0 r(x ′ ) ψ 2 (x ′ ) dx ′ (4.56)
where r(x) is a rational function of x, which behaves at most like O(x d-2 ) at large x, and whose poles r i are such that:

Res x→r i ψ 2 (x) r(x) = 0 (4.57)
and for all degenerate Âα cycles Âα

ψ 2 (x ′ )r(x ′ ) dx ′ = 0. (4.58)
It is easy to see, that with this definition, the holomorphic forms v α (x), the kernels G(x, z) and B(x, z) are meromorphic forms of x.

Analiticity properties

A meromorphic forms R(x), has poles at x = r i the poles of r(x), with degree 1 less than that of r, it behaves like O(x -2 ) in all sectors of the physical sheet. From the Bethe ansatz, it has double poles at the s i 's, with vanishing residues.

In particular, it has an accumulation of poles along the half-lines L i of accumulations of zeroes of ψ.

Also, notice that the following integrals are well defined, and independent of homotopic deformations of A α (in particular independent of where are the s i 's): Aα R(x)dx.

(4.59)

The integration contours around branch-points

Let us choose some contour C i , such that each C i surrounds (in the trigonometric direction) a half-line L i of accumulation of zeroes. In other words it surrounds a "branch point". Let us also assume that i C i surrounds all roots of ψ, i.e. each root of ψ is enclosed in one C i . We also assume that contours C i and A α do not intersect (they have vanishing intersection numbers):

∀i = 1, . . . , 2g + 2, , ∀α = 1, . . . , d -1, C i ∩ A α = 0 (4.

Riemann bilinear identity

For the Riemann bilinear identity, we need the following useful lemma, which we shall use very often in this article:

Lemma 4.1 For every analytical function f (x) which behaves at infinity at most like f (x) = O x d-2 in all directions, and such that it has no singularities inside every contour C i (and thus must be regular at the root s j 's) we have, for x 0 outside of all A-cycles (i.e. on the same side as ∞ 0 ) :

∀i , 1 2iπ C i dx K(x 0 , x) f (x) = 0 proof:
Clearly, the contours C i enclose no singularity of K(x 0 , x)f (x) and can be contracted to 0.

Then we can write the bilinear Riemann identity: Theorem 4.12 Riemann bilinear identity Consider a meromorphic form R(x), with poles r i .

Then we have for x outside of all A-cycles (i.e. on the same side as ∞ 0 ):

R(x) = - i Res r i G(x, z)R(z)dz + g α=1 v α (x) Aα R(z) dz. (4.61)
proof: Since G(x, z) = 1/(zx) + . . . , we write Cauchy formula:

R(x) = Res z→x G(x, z) R(z) dz (4.62)
and we deform the contour of integration from a small circle around x, to contours enclosing all other singularities, i.e. the r i 's and the s i 's. By doing so, G(x, z) has to cross the A-cycles, and picks a discontinuity equal to 2iπ v α (x) i.e. independent of z, so the contour integral of the product factorizes for each A α . We thus arrive to:

R(x) = - i Res r i G(x, z)R(z)dz - i 1 2iπ C i G(x, z)R(z)dz + g α=1 v α (x) Aα R(z) dz. (4.63)
Then, we need to compute

C i G(x, z)R(z)dz.
Write that G(x, z) = ψ 2 (z) ∂ z K(x, z)/ψ 2 (z), and integrate by parts:

C i G(x, z)R(z)dz = - C i K(x, z)r(z)dz
and using lemma 4.1, we see that this vanishes.

Definition of correlators and free energies

In this section, we define the quantum deformations of the correlation functions introduced in [START_REF] Eynard | Topological expansion for the 1-hermitian matrix model correlation functions[END_REF][START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF]. Although the following definitions are inspired from (non hermitian) matrix models (see section 9), they are valid in the present framework of an arbitrary Schrödinger equation, not necessarily linked to a matrix model. The special case of their application to matrix models will be discussed in section 9.

Definition of correlators

Definition 5.1 We define the following functions W (g) n (x 1 , . . . , x n ) called n-point correlation function of "genus" g by the recursion1 :

W (0) 1 (x) = ω(x) , W (0) 2 (x 1 , x 2 ) = B(x 1 , x 2 ) (5.1) W (g) n+1 (x 0 , J) = 1 2iπ 2g+2 i=1 C i dx K(x 0 , x) W (g-1)
n+2 (x, x, J)

+ g h=0 ′ I⊂J W (h) |I|+1 (x, x I )W (g-h) n-|I|+1 (x, J/I) (5.2)
where J is a collective notation for the variables J = {x 1 , . . . , x n }, and where ′ means that we exclude the terms (h = 0, I = ∅) and (h = g, I = J), and where:

W (g) n (x 1 , ..., x n ) = W (g) n (x 1 , ..., x n ) - δ n,2 δ g,0 2 1 (x 1 -x 2 ) 2
(5.3)

Here x 0 and all the x ′ i s are outside of the A-cycles, i.e. on the same side as ∞ 0 . The contour C i (defined in section 4.4.3) is a contour which surrounds the branchpoint L i , i.e. a half-line of accumulation of zeroes, and chosen such that every s j is surrounded by exactly one C i , and such that C i doesn't intersect any A-cycle. Very often we shall write

C = 2g+2 i=1 C i . (5.4)
Appart from the precise definition of the kernel K, this definition is exactly the same topological recursion as in [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF], a sum of residues around all branchpoints of the same expression. In other words, the topological recursion is independent of .

To shorten equation we will introduce the notation:

U (g) n (x, J) = W (g-1) n+2 (x, x, J) + I⊂J W (h) |I|+1 (x, x I )W (g-h)
n-|I|+1 (x, J/I)

+ j ∂ x j W (g) n (x, J/{j}) -W (g) n (x j , J/{j}) (x -x j ) (5.5)
To get:

Theorem 5.1 W (g) n+1 (x 0 , J) = 1 2iπ C dx K(x 0 , x) U (g) n (x, J) (5.6)
proof:

The only difference with the definition, is when we face a term like B(x, x j )W (g) n (x, J/{j}). (note that there are twice this term). It can be split into two terms: B(x, x j )W (g) n (x, J/{j}) and

1 (x-x j ) 2 W (g) n (x, J/{j}). The second term compen- sate exactly the ∂ x j W (g) n (x,J/{j}) (x-x j )
. Thus, the only difference between the two definitions is the term:

1 2iπ C dx K(x 0 , x) j ∂ x j W (g) n (x j ,J/{j}) (x-x j )
. Therefore the definitions are only the same if these terms are null. This is the case because of Lemma 4.1.

Properties of correlators

The main reason of definition. 5.1, is because the W (g) n 's have many beautiful properties, which generalize those of [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF], and in particular they provide a solution of loop equations. We shall prove the following properties:

Theorem 5.2 Each W (g) n (x 1 , . . . , x n ) with 2 -2g -n < 0,
is an analytical functions of all its arguments, with poles only when x i → s j . Moreover, it vanishes at least as O (1/x 2 i ) when x i → ∞ in all sectors. It has no discontinuity across A-cycles.

proof: in appendix B Theorem 5.3 For all (n, g) = (0, 0) we have ∀α ≤ g :

Aα W (g) n+1 (x 0 , x 1 , ..., x n )dx 1 = 0 (5.7) ∀α ≤ g : Aα W (g) n+1 (x 0 , x 1 , ..., x n )dx 0 = 0 (5.8)
proof:

We clearly have these properties for W (0) 2 (x 0 , x 1 ). By an easy recursion, the first property holds for x 1 , . . . , x n . The case of the variable x 0 is special and requires explanation. Indeed for fixed values of x 1 , ..., x n , the dependance in x 0 comes from K(x 0 , x). The theorem then comes from a permutation of integrals. Indeed, since the contour C never crosses any A-cycles by prescription then we can permute the integrals in x and x 0 . The nullity of the integral for K(x 0 , x) in 4.3 then gives the result. Theorem 5.4 For 2 -2gn < 0, the W (g) n 's satisfy the loop equation, i.e. Virasorolike constraints. This means that the quantity:

P (g) n+1 (x; x 1 ..., x n ) = 2 ψ ′ (x) ψ(x) W (g) n+1 (x, x 1 , ..., x n ) + ∂ x W (g) n+1 (x, x 1 ..., x n ) + I⊂J W (h) |I|+1 (x, x I )W (g-h) n-|I|+1 (x, J/I) + W (g-1)
n+2 (x, x, J)

+ j ∂ x j W (g) n (x, J/{j}) -W (g) n (x j , J/{j}) (x -x j ) (5.9)
is a polynomial in the variable x, of degree at most d -2.

proof:

in appendix C can also be written:

W (0) 3 (x 1 , x 2 , x 3 ) = 4 2iπ i C i B(x, x 1 )B(x, x 2 )B(x, x 3 ) Y ′ (x) dx (5.

10) (this can be seen as a quantum version of Rauch variational formula)

proof:

in appendix D Theorem 5.7 For 2-2g-n < 0, W (g) n (x 1 , . . . , x n ) is homogeneous of degree 2-2g-n: ∂ ∂ + d+1 j=0 t j ∂ ∂t j + g i=1 ǫ i ∂ ∂ǫ i W (g) n (x 1 , . . . , x n ) = (2 -2g -n) W (g) n (x 1 , . . . , x n ) (5.11)
proof: Under a change t k → λt k , → λ , ǫ i → λǫ i , the Schrödinger equation remains unchanged, and thus ψ is unchanged. The kernel K is changed to K/λ and nothing else is changed. By recursion, W (g) n is changed by λ 2-2g-n .

Deformations

In this section, we will consider the variations of correlators W (g) n under infinitesimal variations of the Schrödinger potential U(x) or . Infinitesimal variations of the resolvent ω(x) can be decomposed on the basis of "meromorphic forms", and forms can be put in duality with cycles. The duality kernel pairing is the Bergman kernel. We will find in this section, that the classical = 0 formulae remain valid for = 0, and generalize the corresponding form-cycle duality in special geometry.

Variation of the resolvent

Let's consider an infinitesimal polynomial variation:

U → U + δU , → + δ
where δU is a polynomial of degree: deg δU ≤ 2d. Since we have written U = V ′2 /4 -V ′′ /2 -P , we have:

δU = V ′ 2 δV ′ -2 δV ′′ - δ 2 δV ′′ -δP (6.1) with δV ′ (x) = d+1 k=1 δt k x k-1 , (6.2)
and δP is of degree at most d -1:

δP = (t d+1 δt 0 + t 0 δt d+1 )x d-1 + lower degree. (6.3)
Let us compute δψ, or more precisely f = δ ln ψ = δψ/ψ, let us write it:

δψ(x) = f (x)ψ(x) (6.4)
The Schrödinger equation 2 ψ ′′ = Uψ implies:

2 (f ψ) ′′ -Uf ψ = δUψ -δ 2 ψ ′′ (6.5) i.e. 2 (f ′′ ψ + 2f ′ ψ ′ ) = (δU -2 δ U) ψ (6.6)
Multiplying by ψ we get:

2 (f ′ ψ 2 ) ′ = (δU -2 δ U) ψ 2 (6.7) i.e.: δ(ψ ′ /ψ) = f ′ (x) = 1 2 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) (δU(x ′ ) -2 δ U(x ′ )) dx ′ . (6.8) therefore, since ω = V ′ /2 + ψ ′ /ψ: δω(x) = δV ′ (x) 2 + δ ψ ′ (x) ψ(x) + 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) (δU(x ′ ) -2 δ U(x ′ )) dx ′ .
(6.9) If we write:

δU = V ′ 2 δV ′ -2 δV ′′ - δ 2 V ′′ -δP (6.10)
where δP is of degree at most d -1, and V ′ /2 = ωψ ′ /ψ, we have by integration by parts:

δω(x) = 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) ω(x ′ )δV ′ (x ′ ) -δP (x ′ ) -δ (ω ′ (x ′ ) - 1 2 V ′′ (x ′ )) dx ′ . (6.11)

Decomposition of variations

U(x) is a polynomial of degree 2d, it has 2d + 1 independent coefficients. If we assume that we have a solution of genus g < d -1, this means that U is non generic, and satisfies d -1g constraints. In the space of all possible U's, we shall consider the submanifold corresponding to U of genus g, which is a submanifold of dimension dim = d + 2 + g (6.12)

and we shall consider variations of U within that submanifold. Variations transverse to the genus g submanifold, are variations of higher genus and should be computed within a higher genus submanifold.

Instead of the d + 2 + g independent coefficients of the polynomial U, it is more convenient to choose a system of "flat" coordinates in our genus g submanifold, given by: t 0 , t 1 , . . . , t d+1 , ǫ 1 , . . . , ǫ g . (6.13)

We have indeed d + 2 + g coordinates.

Let us write the variations as:

δU = d+1 k=0 U t k δt k + g i=1 U ǫ i δǫ i + U δ . (6.14)

Variations relatively to the filling fractions

For the filling fraction δǫ α we have δV ′ = 0 and thus:

δU(x) = -δP (x) (6.15)
where deg δP ≤ d -2, so we decompose it on the basis of h α 's:

δP (x) = α ′ c α ′ h α ′ . (6.16)
and therefore, from eq. (6.9):

δω(x) = - α ′ c α ′ v α ′ (x). (6.17) Since 2iπǫ α ′ = A α ′ ω, we have: 2iπ δ α,α ′ = A α ′ δω = - α ′′ A α ′ c α ′′ v α ′′ = -c α ′ (6.18)
This implies:

U ǫα (x) = 2iπh α (x) (6.19)
and

δ ǫ i ω(x) = 2iπ v α (x) = Bα B(x, z) dz. (6.20)
We shall say that the flat coordinate ǫ α is dual to the holomorphic form v α , which is itself dual to the cycle B α :

ǫ α " = " 1 2iπ Aα ω , δ ǫα ω = 2iπ v α = Bα B.
(6.21)

Variations relatively to t 0

We have:

δU(x) = -δP (x) = -t d+1 x d-1 + Q(x) (6.22)
where deg Q ≤ d -2. Using eq. ( 6.9) we get:

δω(x) = 1 ψ 2 (x) x ∞ 0 (-t d+1 x ′d-1 + Q(x ′ )) ψ 2 (x ′ ) dx ′ (6.23)
and the polynomial Q is chosen such that A i δω = 0 so that when decomposing Q(x) on the basis v α (x) and performing integrals over A-cycles one finds the coefficients of the decomposition as integrals. Therefore we have:

δω(x) = -t d+1 K d-1 (x) = -t d+1 Kd-1 (x) - g α=1 v α (x) Aα Kd-1 (x ′ ) dx ′ - d-1 α=g+1 v α (x) Aα ψ 2 (x ′ ) x ′d-1 dx ′ (6.24)
where

Kk (x) = 1 ψ 2 (x) x ∞ 0 x ′k ψ 2 (x ′ ) dx ′ , (6.25) and K k (x) is the k th term in the large z expansion of K(x, z) = -∞ k=0 K k (x,z) z k+1 com- puted in theorem 4.2. From theorem 4.5 we have G(x, ∞ i ) = η i t d+1 K d-1 (x). This shows that δ t 0 ω(x) = G(x, ∞ 0 ) = 1 2 (G(x, ∞ 0 ) -G(x, ∞ -)) = ∞ - ∞ 0 B(x, z) dz (6.26)
where ∞ 0 is in the physical sheet, and ∞ -is any infinity chosen in the second sheet.

We shall say that the flat coordinate t 0 is dual to the 3rd kind meromorphic form -2G(x, ∞ 0 ), which is itself dual to the chain [∞ 0 , ∞ -]:

t 0 = Res ∞ 0 ω , δ t 0 ω = -2G(x, ∞ 0 ) = ∞ - ∞ 0 B(x, z) dz (6.27)
where Res means the coefficient of 1/z in the given sector.

Variation relatively to t

k , k = 1 . . . d
For k = 1, . . . , d we have:

U t k (x) = V ′ (x) 2 x k-1 -Q(x) , deg Q ≤ d -2 (6.28)
and Q is chosen such that A i δω = 0. Using eq. ( 6.9) we write:

δω(x) = δ ω(x) - α v α (x) Aα δ ω(x ′ ) dx ′ (6.29)
where

δ ω(x) = 1 ψ 2 (x) x ∞ 0 V ′ (x ′ ) 2 x ′k-1 ψ 2 (x ′ ) dx ′ (6.30) Since V ′ (x ′ ) = j t j+1
x ′j , we have:

2δω(x) = d j=0 t j+1 K k+j-1 (6.31)
Let us compare it with the large z behaviour of G(x, z) in the physical sheet. We have:

G(x, z) = V ′ (z) K(x, z) + O(z -d-1 ) (6.32) which means that the large z expansion of G(x, z) = k G k (x) z -k is given for k = 1, . . . , d by: G k (x) = - d j=0 t j+1 K k+j-1 (6.33) and therefore δω(x) = - 1 2 G k (x) (6.34)
If we write the large z expansion of B(x, z) in the physical sheet, we have

B(x, z) = k B k (x) z -k-1 = - 1 2 k k G k (x, z)z -k-1 (6.35)
and thus

δ t k ω(x) = 1 k B k (x) = Res ∞ 0 z k k B(x, z) dz (6.36)
We shall say that the flat coordinate t k is dual to the 2nd kind meromorphic form

1 k B k (x)
, which is itself dual to a residue of B.

Variations relatively to t d+1

When k = d + 1, we have a few additional terms of degree > d -2:

U t d+1 (x) = V ′ (x) 2 x d - d 2 x d-1 -t 0 x d-1 -Q(x) , deg Q ≤ d -2 (6.37)
and Q is chosen such that A i δω = 0. Using eq. ( 6.9) we write:

δω(x) = δ ω(x) - α v α (x) Aα δ ω(x ′ ) dx ′ (6.38)
where

δ ω(x) = 1 ψ 2 (x) x ∞ 0 V ′ (x ′ ) 2 x ′d - d 2 x ′d-1 -t 0 x ′d-1 ψ 2 (x ′ ) dx ′ (6.39)
In other words we have:

2δω(x) = d j=0 t j+1 K d+j -d K d-1 -2t 0 K d-1 (6.40)
Let us compare it with the large z behaviour of G(x, z). We have:

G(x, z) = (V ′ (z) - 2t 0 z ) K(x, z) -∂ z K(x, z) + O(z -d-2 ) (6.41) which means that the large z expansion of G(x, z) = k G k (x) z -k is given for k = d+1 by: G d+1 (x) = - d j=0 t j+1 K d+j + d K d-1 + 2t 0 K d-1 (6.42) and therefore δω(x) = - 1 2 G d+1 (x) (6.43)
If we write the large z expansion of B(x, z), we have

B(x, z) = k B k (x) z -k-1 = - k 2 k G k (x, z)z -k-1 (6.44)
and thus

δ t d+1 ω(x) = 1 d + 1 B d+1 (x) = Res ∞ 0 z d d B(x, z) dz (6.45)
We shall say that the flat coordinate t d+1 is dual to the 2nd kind meromorphic form

1 d+1 B d+1 (x)
, which is itself dual to a residue of B.

Variation relatively to

We have:

δ ω(x) = - 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) ω ′ (x ′ ) - 1 2 V ′′ (x ′ ) -δ P (x ′ ) dx ′ (6.46)
where δ P is a polynomial of degree ≤ d -2 chosen so that A i δω = 0. For the moment, we have not found a good way of writing this expression as an integral with B, and we leave that question for a future work.

Form-cycle duality

Notice that in all cases, except δ , there exist a cycle δω * and a function Λ * δω such that:

δω(x) = δω * B(x, z) Λ * δω (z) dz. (6.47)
We will use this generic notation later on in order to avoid specifying the 3 different cases.

Under a suitable reparametrization z → z ′ such that dz ′ = Λ * δω (z) dz, we say that δω * in the variable z ′ is the cycle dual to the "meromorphic form" δω.

Variation of higher correlators

The following theorem allows to compute the infinitesimal variation of any W (g) n under a variation of the Schrödinger equation. It tells about the "complex structure deformation" of our quantum Riemann surface. It can be regarded as special geometry relations. Theorem 6.1 Under an infinitesimal deformation U → U + δU, we have:

δW (g) n (x 1 , . . . , x n ) = δω * W (g) n+1 (x 1 , . . . , x n , x ′ ) Λ * (x ′ ) dx ′ (6.48)
where (δω * , Λ * δω ) is the dual cycle to the deformation of the resolvent ω → ω + δω.

proof:

The loop equation for W

(g) n (x, J) is: (2ω(x) -V ′ (x) + ∂ x ) W (g) n (x, J) + U (g) n (x, x; J) = P (g) n (x, J) (6.49)
taking a variation δ we have:

(2ω(x) -V ′ (x) + ∂ x ) δW (g) n (x, J) + (2δω(x) -δV ′ (x))W (g) n (x, J) + δU (g) n (x, x; J) = δP (g) n (x, J) (6.50)
notice that δP

(g) n (x, J) is a polynomial in x, of degree at most d -2.
On the other hand, consider the loop equation for W (g) n+1 (x, J, x ′ ) and multiply it by Λ * (x ′ ) and integrate x ′ along ω * , one gets: n+1 (x, x; J, x ′ )Λ * (x ′ )dx ′ and using 6.9:

(2ω(x) -V ′ (x) + ∂ x ) ω * W (g) n+1 (x, J, x ′ )Λ * (x ′ )dx ′ + ω * δU (g) n+1 (x, x; J, x ′ )Λ * (x ′ )dx ′ = ω * P (g) n+1 (x, J, x ′ )Λ * (x ′ )dx ′ (6.
(2ω(x) -V ′ (x) + ∂ x ) ω * W (g) n+1 (x, J, x ′ )Λ * (x ′ )dx ′ -δW (g) n (x, J) = δP (g) n (x, J) - ω * P (g) n+1 (x, J, x ′ )Λ * (x ′ )dx ′ = i α i (J) h i (x) (6.52)
where the right hand side is a polynomial of degee at most d -2 in x, which can be decomposed on the basis h i (x). Solving the differential equation gives:

ω * W (g) n+1 (x, J, x ′ )Λ * (x ′ )dx ′ -δW (g) n (x, J) = i α i (J) v i (x) (6.53) but since W (g) n and W (g)
n+1 are normalized on A-cycles, this implies α i = 0, i.e.:

ω * W (g) n+1 (x, J, x ′ )Λ * (x ′ )dx ′ = δW (g) n (x, J) (6.54)
7 Free energies

We use the variations and theorem 5.7 to define the F g 's.

Theorem 5.7 gives:

(2 -2g -n -∂ ) W (g) n = t 0 ∂ t 0 + d+1 k=1 t k ∂ t k + g i=1 ǫ i ∂ ǫ i W (g) n (7.1)
And in the previous section, we have seen how to write the derivatives of

W (g) n as integrals of W (g) n+1 , that gives: (2 -2g -n -∂ ) W (g) n = Ĥ. W (g) n+1 (7.2)
where Ĥ is the linear operator acting as follows:

Ĥ.f (x) = t 0 ∞ - ∞ 0 f + d+1 j=1 Res ∞ 0 t j x j j f + g i=1 ǫ i B i f. (7.3)
Those equations allow to define W

= F g for n = 0 and g ≥ 2 as: Definition 7.1 We define F g for g ≥ 2 such that:

(2 -2g -∂ ) F g = Ĥ. W (g) 1 (7.4)
It would remain to find the correct definitions of F 0 (called the prepotential) and F 1 . F 0 and F 1 should be such that under every deformation δ

= ∂ t k , ∂ t 0 , ∂ ǫ i we should have δF g = H δ W (g) 1 . (7.5)
For example ∂F 0 /∂t k = Res x k ω(x)/k i.e. the coefficient of the term 1/x k-1 in the expansion of ω(x) near ∞ 0 .

We leave the definitions of F 0 and F 1 for a future work.

Classical and quantum geometry: summary

Let us summarize the comparison between classical algebraic geometry, and its quantum counterpart introduced here.

of size N, E N,1/2 is the set of real symmetric matrices of size N and E N,2 is the set of quaternion self dual matrices of size N (see [START_REF] Mehta | Random matrices (3e edition)[END_REF]). Alternatively, we can integrate over the angular part and get an integral over eigenvalues only [START_REF] Mehta | Random matrices (3e edition)[END_REF]:

Z = dλ 1 . . . dλ N ∆(λ) 2β N i=1 e -N √ β t 0 V (λ i ) (9.2)
where ∆(λ) = i<j (λ jλ i ) is the Vandermonde determinant.

This allows to generalize the matrix model to arbitrary values of β. In particular, we shall choose β of the form:

β = N 2t 0 1 ± 1 + 4t 2 0 2 N 2 (9.3) i.e. = t 0 N β - 1 √ β . (9.4)
Notice that = 0 correspond to the hermitian case β = 1, and →corresponds to β → 1/β.

Correlators and loop equations

Then we define the correlators:

W k (x 1 , . . . , x k ) = β k/2 i 1 ,...,i k 1 x 1 -λ i 1 . . . 1 x k -λ i k c (9.5)
and

W 0 = F = ln Z. (9.6)
And we assume (this is automatically true if we are considering formal matrix integrals), that there is a large N expansion of the type (where we assume = O(1)):

W k (x 1 , . . . , x k ) = ∞ g=0 (N/t 0 ) 2-2g-k W (g) k (x 1 , . . . , x k ) (9.7) W 0 = F = g (N/t 0 ) 2-2g W (g) 0 = g (N/t 0 ) 2-2g F g . (9.8)
The loop equations are obtained by integration by parts, for example:

0 = i dλ 1 . . . dλ N ∂ ∂λ i 1 x -λ i ∆(λ) 2β j e -N √ β t 0
V (λ j ) (9.9) gives:

0 = i 1 (x -λ i ) 2 + 2β j =i 1 x -λ i 1 λ i -λ j - N √ β t 0 V ′ (λ i ) x -λ i = i 1 (x -λ i ) 2 + β j =i 1 x -λ i 1 x -λ j - N √ β t 0 V ′ (λ i ) x -λ i = i 1 -β (x -λ i ) 2 + β j 1 x -λ i 1 x -λ j - N √ β t 0 V ′ (λ i ) x -λ i = (β -1) 1 √ β W ′ 1 (x) + β( 1 β W 2 1 (x) + 1 β W 2 (x, x)) - N √ β t 0 1 √ β V ′ (x)W 1 (x) - i V ′ (x) -V ′ (λ i ) x -λ i (9.10)
We define the polynomial

P 1 (x) = β i V ′ (x) -V ′ (λ i ) x -λ i = (V ′ W 1 ) + . (9.11)
We thus have:

W 2 1 (x) + N t 0 W ′ 1 (x) + W 2 (x, x) = N t 0 (V ′ (x)W 1 (x) -P 1 (x)) (9.12)
Using the expansion eq. (9.7), that gives the Ricatti equation

W (0) 1 (x) 2 + ∂ x W (0) 1 (x) = V ′ (x)W (0) 1 (x) -P (0) 1 (x) (9.13)
which is satisfied by ω(x): .14) generalizing to the integration by parts of

W (0) 1 (x) = ω(x). ( 9
0 = i dλ 1 . . . dλ N ∂ ∂λ i 1 x -λ i i 1 ,...,i k k j=1 1 x j -λ i j ∆(λ) 2β j e -N √ β t 0 V (λ j ) (9.15)
and using the expansion eq. (9.7) to higher orders in t 0 /N, one gets the loop equations of theorem 5.4, where

P k+1 (x; x 1 , . . . , x k ) = g (N/t 0 ) 2-2g-k P (g) k+1 (x; x 1 , . . . , x k ) = β k/2 i V ′ (x) -V ′ (λ i ) x -λ i i 1 ,...,i k k j=1 1 x j -λ i j c
. (9.16) In other words, the correlation functions of β matrix models, obey the topological recursion of def. 5.1.

Remark:

In [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF], a solution of loop equations for the β-matrix ensemble was proposed, but that solution was such that U(x) was non-generic, corresponding to g = -1, and that ψ(x) had only a finite number of zeroes. This case implied that t 0 was quantized. Generic matrix models cannot correspond to that situation.

That solution was thus not very useful for actual matrix models. Here instead, we have the solution for every U(x), i.e. every contour of integration for the λ i 's, and therefore we have the solution of loop equations for the actual matrix model.

Example: real eigenvalues

Very often, we are interested in a matrix model with real potential V (x) of even degree (i.e. d is odd) and such that the eigenvalues are integrated along the real axis. The resolvent ω(x) is the Stieljes transform of the density of eigenvalues:

ω(x) = t 0 √ β N R ρ(x ′ ) dx ′ x -x ′ , ρ(x) = i δ(x -λ i ) (9.17)
Let us consider that it is defined by this integral in the upper half-plane for x ∈ H + , and it is extended to the lower half-plane by analytical continuation. By definition, ω(x) is regular in the upper half-plane, therefore we look for a ψ(x) which has no zero in the upper half-plane, i.e. no zero on the half-lines L 0 , L 1 , . . . , L d-1 . I.e. it has at most d + 1 half-lines of zeroes , and thus:

g ≤ d -1 2 .
10 Non-oriented Ribbon graphs

Consider the set of all closed connected ribbon graphs obtained by gluing the pieces represented in fig. 6. Closed means every half-edge is glued to another half-edge.

Connected means every vertex is connected to any other vertex. See for example fig. 7.

We define the genus of such a ribbon graph G as follows. We replace every twisted edge of G by a non-twisted one, we thus obtain another ribbon graph G ′ , which is oriented. We define the genus of G equal to that of G ′ : Since the left hand side is fixed, we see that the number and size of vertices are bounded, so that there is only a finite number of possible oriented ribbon graphs G ′ . Since G ′ has a bounded number of edges, there is only a finite number of possibilities of twisting them, i.e. there are also only a finite number of graphs G.

g(G) = g(G ′ ).

Generating functions

In order to enumerate the sets M

W (g) k (x 1 , . . . , x k ; t 3 , . . . , t d+1 , β; t 0 ) = β -k/2 v ′ ≥1 t v ′ 0 G∈M (g) k (v ′ ) 1 #Aut(G) t n 3 (G) 3 t n 4 (G) 4 . . . t n d+1 (G) d+1 x l 1 (G) 1 x l 2 (G) 2 . . . x l k (G) k β -e(G) (β -1) q(G) +δ k,1 δ g,0 δ q,0 t 0 x 1 + δ k,2 δ g,0 δ q,0 1 2 (x 1 -x 2 ) 2 .
(10.1)

• on the other side of the marked edge, there is the marked vertex i = 0, of size l i ≥ 1. We then shrink the marked edge to concatenate the two vertices into one marked vertex of degree l 0 + l i -1. The orientation is inherited from the initial marked vertex, and the marked edge is chosen as the first edge to the left of the shrinked edge. It is also clear that we don't change the genus. Since we forget the marking of the other face, we shall get a symmetry factor l i , corresponding to the l i places where we glue to the i th marked vertex. We thus get a ribbon graph in M (g) l 0 +l i -1,L/{l i } , and this is weighted with weight l i .

• on the other side of the marked edge, there is the same marked vertex 0. Again we shall shrink the marked edge, i.e. shrink the 2 single lines. Several sub-situations may occur: * if the edge is untwisted, shrinking the 2 single lines splits the marked vertex of size l 0 + 1 into two vertices of size l ′ and l 0l ′ -1. They inherit their orientation and marked edge from the initial marked vertex. We have increased the number of marked vertices by 1. The two new vertices are either connected together, or not.

* * If they are not connected, this means that the number of other marked vertices and the genus simply add up. We thus get two ribbon graphs in M l ′ ,l 0 -l ′ -1,L , and this is weighted with weight 1/β. * if the edge is twisted, shrinking the 2 single lines doesn't split the marked vertex. Instead we get a new vertex of size l 0 -1. We assign to it the orientation of the halfvertex situated left of the marked edge, and we mark the edge left of the initial one. We have decreased q by 1, and the genus is unchanged. We thus get a ribbon graph in M (g) l 0 -1,L , and this is weighted with weight (1 -1/β) l 0 (indeed, there are l 0 places where we can glue the marked edge).

(g ′ ) l ′ ,L ′ × M (g-g ′ ) l 0 -l ′ -1,L/L ′ ,
For the generating function, those bijections read:

x W (g) k+1 (x, X L ) = d j=2 t j+1 x j W (g) k+1 (x, X L ) + 1 √ β k i=1 ∂ x i W (g) k (x, X L/{x i } ) -W (g) k (x i , X L/{x i } ) x -x i + 1 √ β g ′ ,L ′ ⊂L W (g ′ ) 1+#L ′ (x, X L ′ )W (g-g ′ ) 1+k-#L ′ (x, X L/L ′ ) + 1 √ β W (g-1) k+2 (x, x, X L ) +(1 - 1 β ) ∂ x W (g) k+1 (x, X L ) + 1 √ β P (g) k+1 (x, X L ) (10.2)
we define

V ′ (x) = β x - d j=2 t j+1 x j (10.3)
and the last term P (g) k+1 (x; X L ) accounts for all the boundary terms, and it is necessarily equal to:

P (g) k+1 (x; X L ) = V ′ (x) W (g) k+1 (x; X L ) + . (10.4)
This can be rewritten:

V ′ (x) W (g) k+1 (x, X L ) = k i=1 ∂ x i W (g) k (x, X L/{x i } ) -W (g) k (x i , X L/{x i } ) x -x i + g ′ ,L ′ W (g ′ ) 1+#L ′ (x, X L ′ )W (g-g ′ ) 1+k-#L ′ (x, X L/L ′ ) +W (g-1) k+2 (x, x, X L ) + ∂ x W (g) k+1 (x, X L ) +P (g) k+1 (x, X L ) (10.5) where = β -1/ β.
In other words, the W

n 's defined in section 5 provide a solution to Tutte's equations. They are the generating functions counting our non-oriented ribbon graphs. One just needs to find the polynomial P (0) 1 (x), i.e. U(x), and the choice of ψ which is such that W (0) 1 is a formal power series in t 0 .

Conclusion

In this article, we have defined some "quantum" versions of quantities known in algebraic geometry and applied them to the resolution of the loop equations in the arbitrary β-random matrix model case, and in particular the enumeration of some non-orientable ribbon graphs.

Our formalism recovers standard algebraic geometry and the invariants of [START_REF] Eynard | Topological expansion of the Bethe ansatz, and noncommutative algebraic geometry[END_REF] in the classical limit → 0.

Instead of an albebraic equation, we have to deal with a differential equation, which we interpreted as a "quantum spectral curve", and we were able to generalize the basic notions arising in classical algebraic geometry, like genus, sheets, branchpoints, meromorphic forms, of 1st kind, 2nd kind, 3rd kind, matrix of periods,... It is surprising to see that the notion of branchpoints become "blurred", a branchpoint is no longer a point, but an asymptotic accumulation line. Also, there are two sheets, corresponding of the two possible large x asymptotic behaviors of ψ(x) ∼ exp ±V /2 , but in fact any solution is a linear combination of these two, so that we could say that we are always in a "linear superposition" of two states like in quantum mechanics.

Another surprising thing, is that, in order for any cohomology theory to make sense, we need the cycle integrals of any forms to depend only on the homology class of the cycles, i.e. we need all forms to have vanishing residues at the s i 's. This "nomonodromy" condition is equivalent to a Bethe ansatz satisfied by the s i 's, like in the Gaudin model [START_REF] Babelon | On the Bethe Ansatz for the Jaynes-Cummings-Gaudin model[END_REF]. This provides a geometric interpretation of the Bethe ansatz, as the condition for cohomology to make sense. However, we still lack of a complete understanding of the situation, since most of our results explicitely depend on an initial sector S 0 which we choose, whereas in algebraic geometry most of them only depend on the spectral curve and not on its parametrization. For instance the genus itself depends on a choice of sector. In some sense, the genus is no longer deterministic. Moreover, we still lack the proper definition of the spectral invariants F g , indeed we have defined the F g 's only through solving a differential equation with respect to , which is not as explicit as [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF] or [START_REF] Chekhov | Matrix eigenvalue model: Feynman graph technique for all genera[END_REF]. Out of the F g 's, we could expect the possibility to make the link with integrable systems and define a "quantum Tau-function", like in [START_REF] Eynard | Invariants of algebraic curves and topological expansion[END_REF]. Also, we restricted ourselves to the case of hyperelliptic curves, i.e. second order differential equations, or also a 1-matrix model. In a forthcoming paper, we shall generalize all this construction to arbitrary linear differential equations of any order, and generalize to a 2-matrix model. This work is underway, almost finished and the article is being written at this time. As for the hyperelliptical case, the notions of genus, sheets, branchpoints, forms, W (g) n 's ... can be defined. Again there is a Bethe ansatz ensuring a no-monodromy condition so that all cycle integrals depend only on the homology class of cycles. So, there is no qualitative change, the difference is only technical, because the hyperelliptical case has big simplifications due to the involutive symmetry. The difference between the hyperelliptical case and the general case is comparable to the difference between [START_REF] Eynard | Topological expansion for the 1-hermitian matrix model correlation functions[END_REF] and [START_REF] Chekhov | Free energy topological expansion for the 2-matrix model[END_REF], i.e. the definition of the kernel K is really more complicated, and there is a rather "big" technical step.

Then is would be interesting to see if the F g 's have some sort of symplectic invariance, or more precisely some "canonical invariance", i.e. are unchanged under any change (x, y) → (x, ỹ) such that [ỹ, x] = [y, x] = .

Finally, let us mention that we have developped a new geometrical approach to the study of D-modules, and it would be interesting to see how to relate it to more standard approaches, and also to the resurgence theory for studying the Schrödinger equation. and therefore:

(2 ψ ′ (x) ψ(x) + ∂ x ) B(x, z) - 1 2(x -z) 2 + ∂ z ψ ′ (x) ψ(x) -ψ ′ (z) ψ(z) x -z = 0 (A.4)
This proves eq. ( 4.35), with:

P (0) 2 (x, z) = - g α=1 h α (x) Aα B(x ′′ , z)dx ′′ - d-1 α=g+1 h α (x) Aα dx ′′ ∂ x ′′ ψ 2 (x ′′ ) B(x ′′ , z). (A.5)
Let's now proove the second loop equation for B(x, z):

Similarly, let us compute (2 ψ ′ (z) ψ(z) + ∂ z ) B(x, z): (2 ψ ′ (z) ψ(z) + ∂ z ) B(x, z) = 1 2 (2 ψ ′ (z) ψ(z) + ∂ z ) ∂ z (2 ψ ′ (z) ψ(z) -∂ z ) K(x, z) (A.6) Notice that the operator Û (z) = 1 2 (2 ψ ′ (z) ψ(z) + ∂ z ) ∂ z (2 ψ ′ (z) ψ(z) -∂ z ), is equal to: Û (z) = - 1 2 ∂ 3 z + 2U(z)∂ z + U ′ (z) (A.7)
which is also known in the litterature as the Gelfand-Dikii operator [START_REF] Di Francesco | 2D Gravity and Random Matrices[END_REF] (The Gelfand-Dikii differential polynomials R k (U) are computed recursively by R 0 = 1 and ∂ z R k+1 = Û .R k ), which plays a key role in the KdV hierarchy.

However, independently of any relationship with KdV, we get:

(2 ψ ′ (z) ψ(z) + ∂ z ) B(x, z) = 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ Û(x ′ ). 1 x ′ -z = 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ - 3 (x ′ -z) 4 + 2U(z) (x ′ -z) 2 + U ′ (z) x ′ -z (A.8)
We integrate the first term by parts three times, and we write Y = ψ ′ /ψ (we have

Y ′ + Y 2 = U): (2 ψ ′ (z) ψ(z) + ∂ z ) B(x, z) = 1 (x -z) 3 - 2 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ Y (x ′ ) (x ′ -z) 3 + 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ 2U(z) (x ′ -z) 2 + U ′ (z) x ′ -z = 1 (x -z) 3 + Y (x) (x -z) 2 - 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ Y ′ (x ′ ) + 2Y 2 (x ′ ) (x ′ -z) 2 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ 2U(z) (x ′ -z) 2 + U ′ (z) x ′ -z = 1 (x -z) 3 + Y (x) (x -z) 2 + 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ Y ′ (x ′ ) (x ′ -z) 2 + 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ 2(U(z) -U(x ′ )) (x ′ -z) 2 + U ′ (z) x ′ -z = 1 (x -z) 3 + Y (x) (x -z) 2 - Y ′ (x) x -z + 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ Y ′′ (x ′ ) + 2Y (x ′ )Y ′ (x ′ ) (x ′ -z) 2 + 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ 2(U(z) -U(x ′ )) (x ′ -z) 2 + U ′ (z) x ′ -z = 1 (x -z) 3 - ∂ ∂x Y (x) x -z + 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ 2(U(z) -U(x ′ )) (x ′ -z) 2 + U ′ (z) + U(x ′ ) x ′ -z (A.9)
This implies that:

(2 ψ ′ (z) ψ(z) + ∂ z ) B(x, z) - 1 2(x -z) 2 + ∂ ∂x Y (x) -Y (z) x -z = 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ 2(U(z) -U(x ′ )) (x ′ -z) 2 + U ′ (z) + U(x ′ ) x ′ -z = Q(z, x) (A.10)
which is clearly a polynomial in z. Taking integrals over x along A α does not change its structure in z, and therefore:

(2 ψ ′ (z) ψ(z) + ∂ z ) B(x, z) - 1 2(x -z) 2 + ∂ ∂x Y (x) -Y (z) x -z = 1 ψ 2 (x) x ∞ 0 ψ 2 (x ′ ) dx ′ 2(U(z) -U(x ′ )) (x ′ -z) 2 + U ′ (z) + U(x ′ ) x ′ -z = P (0) 2 (z, x) (A.11)
is of the required form. By looking at the behavior of the various terms in the LHS of eq. ( 4.36) when z → ∞, we find that P (0) 2 (z, x) is a polynomial of degree at most d -2 in z.

B Appendix: Proof of theorem 5.2

Theorem 5.2 Each W (g) n (x 1 , . . . , x n ) with 2 -2gn < 0, is an analytical functions of all its arguments, with poles only when x i → s j . Moreover, it vanishes at least as O (1/x 2 i ) when x i → ∞ in all sectors. It has no discontinuity across A-cycles.

proof:

We proceed by recursion on 2g + n. The theorem is true for

W (0)
2 . Assume it is true up to 2g + n, we shall prove it for W (g) n+1 (x 0 , x 1 , . . . , x n ).

Then, notice that K(x, z) has a logarithmic cut along ]∞ 0 , x], and the discontinuity across that cut is:

δ K(x, z) = 2iπ ψ 2 (z) ψ 2 (x) (C.3) U (g)
n has no singularity outside of C, and thus we can deform the contour into a contour enclosing only the logarithmic cut of K(x, z), and therefore:

1 2iπ C dz K(x, z) U (g) n (z, J) = - 1 x ∞ 0 dz ψ 2 (z) ψ 2 (x) U (g) n (z, J) (C.4)
We then apply the operator: 2 ψ ′ (x) ψ(x) + ∂ x , that gives:

(2 ψ ′ (x) ψ(x)

+ ∂ x ) 1 2iπ C
dz K(x, z) U (g) n (z, J) = -U (g) n (x, J) (C.5) and therefore: proof:

P (g) n+1 (x, J) = (2 ψ ′ (x) ψ(x) + ∂ x ) W (g) n+1 (x, J) + U (g) n (x, J) = -(2 ψ ′ (x) ψ(x) + ∂ x ) α v α (x) 2iπ C dz C α (z) U (g) n (z, J) = - α h α (x)
The definition of W (0) 3 is: proof:

W (0) 3 (x 0 , x 1 , x 2 ) = 1 iπ C dx K(x 0 , x)B(x, x 1 )B(x, x 2 ) = 1 4iπ C dx K 0 G ′ 1 G ′ 2 -2 Y K ′ 0 K ′ 1 K ′ 2 -Y ′2 K 0 K 1 K 2 = 1 8iπ C dx W (
The special case of W (0) 3 is proved in appendix D.1 above. It is obvious from the definition that W (g) n+1 (x 0 , x 1 , . . . , x n ) is symmetric in x 1 , x 2 , . . . , x n , and therefore we need to show that (for n ≥ 1):

W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = 0 (E.1)
where J = {x 2 , . . . , x n }. We prove it by recursion on -χ = 2g -2 + n. Assume that every W where ′ means that we exclude the terms (I = ∅, h = 0) and (I = J, h = g). Notice also that W (g-1)

n+2 = W (g-1) n+2

because n ≥ 1. Then, using the recursion hypothesis, we have:

W (g) n+1 (x 0 , x 1 , J) = 2 C
dx K(x 0 , x) B(x, x 1 )W (g) n (x, J)

+ C dx C dx ′ K(x 0 , x)K(x 1 , x ′ ) W (g-2)
n+3 (x, x, x ′ , x ′ , J) Now, if we compute W (g) n+1 (x 1 , x 0 , J), we get the same expression, with the order of integrations exchanged, i.e. we have to integrate x ′ before integrating x. Notice, by moving the integration contours, that:

C dx C dx ′ - C dx ′ C dx = - C dx 1 2πi Res x ′ →x (E.4)
Moreover, the only terms which have a pole at x = x ′ are those containing B(x, x ′ ). Therefore:

W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = 2
C dx (K(x 0 , x) B(x, x 1 ) -K(x 1 , x) B(x, x 0 )) W (g) n (x, J)

-2 C dx 1 2iπ
Res

x ′ →x K(x 0 , x)K(x 1 , x ′ ) B(x, x ′ ) 2W (g-1)
1+n (x ′ , x, J) + 2 The last term can be integrated by parts, and we get:

W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = 2
C dx (K(x 0 , x) B(x, x 1 ) -K(x 1 , x) B(x, x 0 )) W (g) n (x, J)

+ 1 2 C dx K ′ (x 0 , x)K(x 1 , x) -K(x 0 , x)K ′ (x 1 , x) 2W (g-1)
1+n (x, x, J) + 2 C dx (K(x 0 , x) B(x, x 1 ) -K(x 1 , x) B(x, x 0 )) W (g) n (x, J)

+ C
dx K ′ (x 0 , x)K(x 1 , x) -K(x 0 , x)K ′ (x 1 , x) P (g) n (x, J)

+(Y (x) -∂ x )W (g) n (x, J) + j ∂ x j W (g)
n-1 (x j , J/{x j })

xx j (E.8)

Since P (g) n (x, J) and W (g) n-1 (x j , J/{x j }) are entire functions of x, we can use the usual thorem 4.1 to say that they do not contribute. (Note again that we choose the logarithmic cut of K 1 inside the contour C, and that we can do that because the contour C contains x 1 .) W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = 2

C dx (K(x 0 , x) B(x, x 1 ) -K(x 1 , x) B(x, x 0 )) W (g) n (x, J) + 2

C dx K ′ (x 0 , x)K(x 1 , x) -K(x 0 , x)K ′ (x 1 , x)

(Y (x) -∂ x )W (g) n (x, J)
66 (E.9)

Notice that:

K ′ 0 K 1 -K 0 K ′ 1 = - 1 (G 0 K 1 -K 0 G 1 ) (E.10)
and B = -1 2 G ′ , therefore:

W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = -2 C dx (K 0 G ′ 1 -K 1 G ′ 0 ) W (g) n (x, J) - 1 2 C dx G 0 K 1 -K 0 G 1 (Y (x) -∂ x )W (g) n (x, J) (E.11)
we integrate the first line by parts:

W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = C dx (K ′ 0 G 1 -K ′ 1 G 0 ) W (g) n (x, J) + C dx (K 0 G 1 -K 1 G 0 ) W (g) n (x, J) ′ - 1 C dx G 0 K 1 -K 0 G 1 (Y (x) -∂ x )W (g) n (
x, J) (E.12) Notice that:

K ′ 0 G 1 -G 0 K ′ 1 = - Y (K 0 G 1 -G 0 K 1 ) (E.13)
So we find W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = 0 (E.14)

; Figure 8: When we shrink the single lines of a marked edge, several possibilities may occur: 1) the other side is an umarked vertex of order j + 1, we get a new vertex of order l 0 + j; 2) the other side is a marked vertex of order l i , we get a new vertex of order l 0 + l i -1; 3)4) the other side is the same vertex and the edge is untwisted. Then shrinking the edge splits the vertex into two vertices, this may disconnect the graph or not; 5) the other side is the same vertex and the edge is twisted. Then shrinking the edge doesn't disconnect the vertex.

Figure 1 :

 1 Figure 1: Example of sectors for a potential of degree deg V = 3, i.e. d = 2. If deg V = d + 1 there are 2d + 2 sectors.

Figure 2 :

 2 Figure2: The zeroes of ψ accumulate near ∞ along the half-lines bordering sectors where ψ 0 is exponentially large on both sides. In particular, there is no accumulation of zeroes along L 0 and L 2d+1 .

Figure 3 :

 3 Figure 3: Representation in two sheets of a Riemann surface of genus 1.

  From then it is easy to generalize into more complicated frames: V/(2h)) exp(-V/(2h)) exp(-V/(2h)) exp(-V/(2h))

Figure 4 :

 4 Figure 4: Picture of the path of integration used for the definition of the kernel K(x, z).

Theorem 4. 5 G

 5 (x, z) = O(1/x 2 ) (4.26) when x → ∞ in all sectors.And at large z in sector S k :

Theorem 4 . 6

 46 Let α = 1, . . . , g, and z on the side of A α which does not contain ∞ 0 , then: Aα G(x, z) dx = 0 (4.28) proof: Immediate from theorem 4.3

4. 3 . 1

 31 Properties of the Bergman kernel Theorem 4.8 B(x, z) = O(1/x 2 ) (4.33) when x → ∞ in all sectors. And B(x, z) = O(1/z 2 ) (4.34) when z → ∞ in all sectors.

Theorem 4 . 10

 410 We have for every α = 1, . . . , g: Aα B(x, z) dx = 0 , Aα B(x, z) dz = 0 (4.37) and Bα B(x, z) dz = 2iπv α (x) (4.38)

4. 4

 4 Meromorphic forms and properties 4.4.1 Definition of meromorphic forms Definition 4.3 A meromorphic form R(x) is defined as:

Theorem 5 . 5

 55 Each W (g) nis a symmetric function of all its arguments.proof:in appendix E, with the special case of W

Figure 6 :

 6 Figure 6: Consider the set of ribbon graphs obtained by gluing those vertices. Marked vertices are of degree l ≥ 1, they are oriented and have one marked half-edge. Unmarked vertices are unoriented, and are of degree ≥ 3. Vertices are glued together by their half-edges, either twisted (with weight 1/β) or untwisted (with weight 1 -1/β).

kDefinition 10 . 2

 102 (v ′ ), we define the following generating functions: We define:

C 6 Theorem 5 . 6

 656 dz C α (z) U (g) n (z, J) (C.6)which is indeed a polynomial of x of degree at most d -2.D Appendix:Proof of theorem 5.The 3 point functionW , x 1 )B(x, x 2 )B(x, x 3 ) Y ′ (x) (D.1)where Y (x) = -2 ψ ′ (x) ψ(x)

  function of all its arguments.

  k -2 ≤ 2g + n is symmetric. We have: n+2 (x, x, x 1 , J) + 2 B(x, x 1 )W(g) n (x, J)

  3+|I| (x ′ , x, x, I)W (g-1-h) n-|I| (x ′ , J/I) (x, J/I) W (h-1) 3+|I| (x, x ′ , x ′ , I) ′ | (x ′ , x, I ′ )W (h-h ′ ) 1+|I|-|I ′ | (x ′ , I/I ′ ) (E.3)

5 ) 2 C 2 C 2 C

 5222 The residue Res x ′ →x can be computed:W (g) n+1 (x 0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = dx (K(x 0 , x) B(x, x 1 ) -K(x 1 , x) B(x, x 0 )) W (g) n (x, J) -C dx K(x 0 , x) ∂ ∂x ′ K(x 1 , x ′ ) dx (K(x 0 , x) B(x, x 1 ) -K(x 1 , x) B(x, x 0 )) W (g) n (x, J) -C dx K(x 0 , x)K ′ (x 1 , x) x 0 , x)K(x 1 , x ′ ) ∂ ∂x ′ 2W (g-1) 1+n (x ′ , x, J) + 2 h ′ I∈J W (g-h) n-|I| (x, J/I)W (h) 1+|I| (x ′ , I) x ′ =x = dx (K(x 0 , x) B(x, x 1 ) -K(x 1 , x) B(x, x 0 )) W (g) n (x, J) 65 -C dx K(x 0 , x)K ′ (x 1 , x)

  0 , x 1 , J) -W (g) n+1 (x 1 , x 0 , J) = 2

  and this is weighted with weight 1/β. * * If they are connected, we see that we get a new ribbon graph, with one more vertex, 1 less edge, and we have not changed the connectivity of single lines. The genus has thus decreased by 1. We thus get a ribbon graph in M

	(g-1)

here g is any given integer, it has nothing to do with the genus g of the spectral curve.

Acknowledgments

We would like to thank O. Babelon, M. Bergère, G. Borrot, P. Di Francesco, S. Guillermou, V. Pasquier, A. Prats-Ferrer, A. Voros for useful and fruitful discussions on this subject. The work of B.E. and O.M. is partly supported by the Enigma European network MRT-CT-2004-5652, ANR project GranMa "Grandes Matrices Aléatoires" ANR-08-BLAN-0311-01, by the European Science Foundation through the Misgam program, by the Quebec government with the FQRNT. O. Marchal would like to thank the CRM (Centre de recheche mathématiques de Montréal, QC, Canada) for its hospitality.

The branchpoints are paired (in an arbitrary way) to form cuts, and the two sheets are glued along the cuts. Another possibility, is to draw a cut from each branchpoint to ∞. The A-cycles surround pairs of branchpoints in the physical sheet. There are also some degenerate branchpoints, which correspond to cuts of vanishing length.

| y 2 -U(x) , [y, x] = , plane curve:

where C i surrounds the branchpoint

Application: Matrix models

The reason why we introduced those W (g) n 's is because they satisfy the loop equations for β-random matrix ensembles.

Consider a (possibly formal) matrix integral:

where V (x) is some polynomial, and where E N,1 = H N is the set of hermitian matrices

The genus of G ′ is computed as usual for oriented ribbon graphs, from the Euler characteristics of G ′ :

where single lines are the lines bordering each side of the ribbon edges. One should follow single lines and see how many connected single lines a graph contains. Obviously G and G ′ have the same number of fat vertices and fat edges (each edge containing two single lines), but they may have different number of single lines.

This defines what we call the genus g of a ribbon graph.

For a given Ribbon graph G we call:

, be the set of ribbon graphs G with k marked vertices, q twisted edges, and of genus g, and such that G ′ has v(G ′ ) = v ′ connected single-lines, .

proof:

The number of vertices of G ′ is:

The number of edges is twice the number of half-edges, i.e.

#{edges} =

That gives:

Projective plane Klein Bottle Torus It is a formal series in powers of t 0 . Most often, for readability, we shall write only the dependence in the x i 's:

Also, for k = 0 we write W (g) 0 = F g .

Tutte's recursive equations

Tutte's equation is a recursion on the number of edges to construct the ribbon graphs. It consists in finding a bijection between ribbon graphs of various ensembles, by recursion on the number of edges. Let M (g) l 1 ,...,l k be the set of ribbon graphs of genus g, and with k marked vertices of size l 1 , . . . , l k .

Consider a ribbon graph G ∈ M (g) l 0 +1,L where L = {l 1 , . . . , l k }, with marked vertices of degrees l 0 + 1, L.

Consider the marked edge of marked face 0. It is either twisted or untwisted. Several mutually exclusive situations may occur (see fig 8):

• on the other side of the marked edge, there is an unmarked vertex of size j + 1 with j ≥ 2. We then shrink the marked edge to concatenate the two vertices into one marked vertex of degree l 0 + j. The orientation is inherited from the initial marked vertex, and the marked edge is chosen as the first edge to the left of the shrinked edge. It is clear that we don't change the number of single lines in G or G ′ . We decrease the number of vertices and edges by 1, so we don't change the genus. We thus get a ribbon graph in M (g) l 0 +j,L , and this is weighted with weight t j+1 (1/β + (1 -1/β)) = t j+1 .

A Appendix:

Proof of the loop equation for B(x, z)

Let's first proove the first loop equation for B(x, z): Let's define:

i.e. we have:

, it suffices to prove eq. (4.35) for B(x, z).

Let us compute:

(2

The integrand U (g) n of theorem 5.1 is singular only at x = s j 's. As long as x 0 is away from the s j 's, we can continuously deform the A-cycles and the contour C in order to have x 0 outside of the A-cycles, and the integral can be evaluated and is analytical in x 0 . When x 0 approaches s i , we define Ĉi , a contour which surrounds all roots except s i , i.e:

The integral over Ĉi can be evaluated and is convergent, thus it is analytical in x 0 .

From the recursion hypothesis, all terms in the integrand are meromorphic in the vicinity of s i , and thus the residue at s i can be computed by taking a finite Taylor expansion of K(x 0 , x) = k (xs i ) k K i,k (x 0 ) in the vicinity of x → s i . The result is a finite sum of terms of the type K i,k (x 0 ). It is easy to see from the definition of K, that each K i,k (x 0 ) has only poles at x 0 = s i . Thus we have proved that W (g) n+1 has poles at the s i 's in its first variable.

In the other variables, the result comes from an obvious recursion.

C Appendix:

Proof of theorem 5.4

In this subsection we prove theorem 5.4, that all W (g) n 's satisfy the loop equation.

n+2 (x, x, J)

proof:

From the definition we have:

where we have written for short K p = K(x p , x), G p = G(x p , x), and derivative are w.r.t. x. Note also that introducing K 1 and K 2 makes appear some additional and arbitrary logarithmic cuts from x 1 to ∞ 0 and from x 2 to ∞ 0 . But these cuts can be chosen arbitrarily since from the definition of W (0) 3 (x 0 , x 1 , x 2 ) it should not depend on that. Remember also that to use this definition of W (0) 3 we need to assume that x 1 and x 2 are not circled by the contour C. Therefore we can choose the logarithmic cut of K 1 and K 2 inside the contour C like we have done it for x 0 . We now see that for example K 0 K 1 K 2 has no singularity outside C and thus will not contribute because of theorem 4.1. Many other manipulations involving globally defined functions with no singularities outside C can be done.

For example, using the Ricatti equation

This expression is clearly symmetric in x 0 , x 1 , x 2 as claimed in theorem 5.5.

Let us give an alternative expression, in the form of the Verlinde or Krichever formula.

proof:

In order to prove formula D.4, compute:

Notice that Y 2 = 2 Y ′ + 4U, thus we may replace Y 3 /Y ′ by 2 Y , and Y 2 by 2 Y ′ and Y Y ′ by Y ′′ , for the same reasons as before. Thus: