Functional Equations and Separation of Variables for Exact g-Function

The g-function is a measure of degrees of freedom associated to a boundary of two-dimensional quantum field theories. In integrable theories, it can be computed exactly in a form of the Fredholm determinant, but it is often hard to evaluate numerically. In this paper, we derive functional equations---or equivalently integral equations of the thermodynamic Bethe ansatz (TBA) type---which directly compute the g-function in the simplest integrable theory; the sinh-Gordon theory at the self-dual point. The derivation is based on the classic result by Tracy and Widom on the relation between Fredholm determinants and TBA, which was used also in the context of topological string. We demonstrate the efficiency of our formulation through the numerical computation and compare the results in the UV limit with the Liouville CFT. As a side result, we present multiple integrals of Q-functions which we conjecture to describe a universal part of the g-function, and discuss its implication to integrable spin chains.


Introduction
General motivation In two-dimensional quantum field theories, there exists a function called the c-function [1] which provides a measure of degrees of freedom in the theory. Two important properties of the c-function are that it monotonically decreases along the RG flow and that it is stationary at fixed points and coincides with the conformal anomaly.
In [2], Affleck and Ludwig introduced an analogue of the c-function for theories in two dimensions with a boundary. The quantity, called the g-function or the boundary entropy, is defined as an overlap between the boundary state and the ground state. Although it may not be obvious from its definition, the g-function is a measure of degrees of freedom associated to a boundary. A justification of this claim comes from its monotonicity along the RG flow, which was proven in [3] 1 .
tities. For instance, the form factor of local operators, which might seem like the next step in complexity, is not known 2 in general even in the infinite volume. One of the difficulties comes from the fact that they are "O(1) quantities": While the spectrum (in particular the ground-state energy) can be read off easily from the asymptotic behavior of the Wick-rotated partition function Z ∼ e −RE , the computation of other observables requires us to determine the O(1) piece of the partition function or the partition function with operator insertions. (See section 2 for more details.) One of the rare exceptions 3 is the g-function, for which one can generalize the analysis for the spectrum and perform the computation exactly and systematically. In this respect, the g-function stands at a unique position in the study of integrability; it is an O(1) quantity much like other observables but nevertheless exactly computable in the finite volume. For this reason, it would be fruitful to further develop the techniques to compute the g-functions in integrable theories and see how far we can get.
Relation to N = 4 supersymmetric Yang-Mills Yet another motivation comes from planar N = 4 supersymmetric Yang-Mills theory (N = 4 SYM) in four dimensions. It was found more than a decade ago [21] that the computation of the spectrum of local operators in N = 4 SYM can be mapped to the computation of the energy in integrable spin chains. Following the "textbook" prescription mentioned above, a complete determination of the spectrum was achieved 4 in [24][25][26][27][28].
A natural next step along this line is to compute correlation functions of local operators. It was found in [29][30][31][32][33][34] that they can be decomposed into basic building blocks called the hexagon form factors, which were determined in [29] exactly. However, to actually compute correlation functions of operators of finite lengths, one needs to sum over all possible intermediate states which appear in the hexagon-form-factor expansion. This leads to an infinite series which is in practice hard to evaluate.
More recently, it was found in [11,12] that a special class of three-point functions can be computed exactly using the techniques of the g-functions. The result is given in a closed form as the Fredholm determinant and is by far more compact and practical than the infinite series in the hexagon approach. Nevertheless, the Fredholm determinant is still rather complicated to evaluate and it would be worth seeking a further reformulation. Although the results in this paper cannot be applied directly to N = 4 SYM, we think that they provide the first step towards such a goal.
Structure of the paper The rest of this paper is organized as follows. In section 2, we review the derivation of the Fredholm-determinant formula for the g-function in integrable theories. Besides explaining the derivation for general integrable models, we also write down 2 Although there are some results for two-particle form factors, the results for multiparticle form factors are not known in general. 3 Other important exceptions are the vacuum one-point functions and the finite-volume diagonal form factors in sine-Gordon and sinh-Gordon theories [16][17][18][19][20]. However, these results rely heavily on specific properties of these theories and do not seem as universal as g-functions. 4 A more elegant and efficient formalism called the quantum spectral curve was developed in [22,23].  (4) in which L plays the role of time. Equating two expansions in the R → ∞, we obtain the TBA formulation for the g-function (7).
explicit formulae for the sinh-Gordon theory. In section 3, we explain how to rewrite the g-functions in the sinh-Gordon theory into functional equations and the TBA-type integral equations. The section also contains a concise review of the results by Tracy and Widom on the relation between the Fredholm determinant and TBA. In section 4, we use the TBA-type equations that we derived and compute the g-function numerically. The main purpose is to show the efficiency of our formulation and to compare the result in the small radius limit with the result computed by CFT. In section 5, we present multiple integrals which we conjecture to describe a universal part of the g-function in the sinh-Gordon theory. The resulting expression resembles integrals in the separation of variables approach and generalizes the result by Lukyanov [35] on the finite-volume one-point functions. We also mention possible applications of our argument to the overlaps between boundary states and Bethe states in integrable spin chains. In section 6, we summarize the results and discuss the future directions. Technical details are often relegated to the appendices.

Review of the derivation of the g-function
To discuss the g-function in integrable theories, we consider a partition function of a cylinder with circumference L and length R whose boundaries are contracted with boundary states 5 B| and |B (see figure 1). This partition function, which we denote by Z, can be computed in two different channels. The first one is the "closed string" channel in which we regard R as the Euclidean time direction. Inserting a complete set of states ψ c on the circle of circumference L, we obtain an expansion of the partition function, where E ψc (L) is the energy of the state ψ. To isolate the contribution from the ground state |Ω , we consider the limit R → ∞. Then we can approximate the partition function as where g is the g-function defined by To compute the g-function using integrability, we need to consider the other channel; namely the "open string" channel in which we regard L as the Euclidean time direction. Inserting a complete set of states ψ o on the segment of length R, the partition function can be expanded as where E ψo is the energy of the state ψ o . Equating the two expansions (1) and (4) and taking the limit R → ∞, we obtain Now the right hand side of (5) can be identified with the thermal partition function at temperature 1/L in the infinite volume limit (R → ∞). To proceed, we furthermore assume that the boundary state |B does not break integrability. In other words, we assume that |B belongs to a class of integrable boundary states introduced in [36]. In such a case, we can apply the standard arguments of the thermodynamic Bethe ansatz and compute the thermal partition function. Namely we replace the sum over states with a path integral of densities of particles ρ lim R→∞ ψo As is evident from the expression, this path integral is dominated by the saddle point in the R → ∞ limit. One should however note that the saddle-point value of the action S[ρ * ] only gives the exponential piece in (5), e −RE Ω . In order to compute the g-function, one also needs to include the one-loop fluctuation around the saddle point and the O(1) normalization constant N . For details of the derivation, see for instance [8][9][10] and section 6 of [11].
Combining all the factors, one obtains a closed-form expression for the g-function. The result for a theory with a single species of particles without bound states reads [7][8][9]11] Here Det's are the Fredholm determinants and the operatorsĜ's are defined bŷ 6 The result can be generalized to theories with multiple species of particles and with bound states as shown in [9,11]. However, the resulting expression is divergent in general and one needs some regularization as pointed out in [37]. Nevetheless, the case relevant for the three-point function in N = 4 SYM seems free of divergences and the regularization seems unnecessary [11]. and the kernels K ± are given in terms of the S-matrix S(u, v) as The only factor which is sensitive to the details of the boundary state is Θ(u), and is given in terms of the reflection factor R(u) as Finally, (u) is the pseudo-energy which satisfies the TBA equation where E(u) = m cosh u is the energy of the excitation (in the open string channel) and * is the convolution A * B := dv 2π A(u, v)B(v). The result (7) in principle gives a nonperturbative expression for the g-function in integrable theories. However, the computation is rather complicated because of the Fredholm determinants. To evaluate the Fredholm determinants in practice, we either need to approximate them by finite-dimensional determinants or expand them in a series. For instance, the two determinants in the ratio can be combined into a single series given by with u n+1 ≡ u 1 and K s (u − v) = 1 i ∂ u log S(u, v). The purpose of this paper is to derive an alternative expression for the g-function which is more suited for the numerical evaluation, and in particular, surpasses the multiple integrations.

g-Functions in sinh-Gordon
We will consider the simplest interacting quantum field theory in two dimensions: the sinh-Gordon theory. In order to set up the notations, we will quickly review a few well-known facts about this model. The sinh-Gordon is an integrable theory defined by the Lagrangian containing two parameters: the coupling b and the cosmological constant µ. Its spectrum consists of a single massive particle whose mass m is known in terms of the parameters in the Lagrangian (see [38] and appendix B for more details on this relation). The corresponding scattering is encoded in the following S-matrix, where the parameter p is related to the coupling constant b by the relation p = b 2 (1 + b 2 ) −1 and throughout this work we will focus on the self-dual point for which b = 1.
We will consider this model defined on geometries with specific boundaries that preserve integrability. These integrable boundary conditions can be derived from the boundary data associated to the lowest breather of the sine-Gordon model by the appropriate analytic continuation. Namely, we have that the sine-Gordon reflection matrix was determined in [36,39] and given by, from where we can obtain the sinh-Gordon [40,41] one by setting where η, ϑ are parameters characterizing the boundaries. With these results, the g-function is fully determined through (7).

Tracy-Widom TBA
Fredholm determinants often provide a representation for several physical quantities that go well beyond the g-functions. Examples include two-point functions in some 2d integrable models [42], the S 3 partition functions of supersymmetric gauge theories [43][44][45][46][47], nonperturbative formulation of topological string [48], certain correlation functions and amplitudes in N = 4 SYM [49][50][51][52][53][54][55][56], N = 2 supersymmetric index in two dimensions [57], and the partition function of 2d polymers [58,59]. In the last two cases, it was pointed out by Zamolodchikov [59] that such determinants are unexpectedly related to the solution of a set of integral equations reminiscent of the Thermodynamic Bethe Ansatz. This connection was later proven by Tracy and Widom in [13]. For these reasons, we will call this set of equations Tracy-Widom TBA 7 . Once proven, the relation between Fredholm determinants and functional equations was largely explored and further improved with great success in the context of the evaluation of the topological string partition function. Here, we will build on the Tracy-Widom proof and generalize it to our current case.

Functional Equations
In our context, we deal with Fredholm determinants of the operatorsĜ andĜ ± , see (7). Let us start by representing each of them as a formal power series in the kernel. For example, the determinant involvingĜ can be written as with u n+1 = u 1 and we have introduced the bookkeeping parameter z that might be set to one to recover the original problem. We have also defined the dressed kernel by and the j-th convolution of a kernel K * j as with f * g ≡ dvf (u, v)g(v, w). Analogously, we can rewrite the Fredholm determinant involvingĜ + in terms of a dressed kernel defined in a similar way from K + , that we denote from now on by K + . The important property of these kernels that will make our analysis possible is that both can be brought to the following form after using the explicit expression of the S-matrix in (14), where we define for = s, and for the kernel = +, The kernels of type (20) are particularly interesting because they admit a recursive representation [13] from which one can derive functional equations for them. We highlight in the main text some important steps of this derivation and leave the details to the appendix A.

Lemma by Tracy and Widom
The starting step is the following lemma proven by Tracy and Widom [13], which decomposes the kernels (20) in terms of some auxiliary functions of a single argument φ j (u), Here φ j are defined recursively by or equivalently by where K * j is the j-th convolution defined in (19). In order to show (23), we introduce the bra-ket notations of quantum mechanics. We can then reexpress (25) as where |E φ j and |E are kets which correspond to the following "wave functions", Similarly, the "wave functions" for the bra states E | are given by 8 Proof of the lemma Using this representation and the equation (20), one can show the following operator equation (here we drop the subindices to make the notation less cluttered, since the Lemma is analogous for both kernels): Using (29), we can explicitly compute (anti)commutators ofM andK n for small n: 8 Since E(u) is real in our case, this coincides with the standard definition of the bra state in quantum mechanics. When E(u) is complex, in the standard definition, we have E|u =Ē(u) withĒ being the complex conjugate of E. Therefore in that case it is more natural to replace the right hand side of (29) with |E Ē |.

From this, it should be clear what the pattern is. Namely the result for general n iŝ
To prove this, we use the mathematical induction. We will not fully explain the proof since it is straightforward. The main step of the proof is the identitŷ We can bring (32) into a more convenient form by sandwiching both sides with u| and |v . We then get Using the reality of E and the kernel K and the definition of φ j given in (26), the right hand side can be re-expressed as Equating this with the left hand side, we arrive at the formula (23).
Baxter-like equations Owing to the following property of the cosh kernel, the representation (24) implies a system of Baxter-like functional relations (see appendix A for more details), with δ s = 1, δ + = 2 and v = (1 + e ) −1/2 1 + e . The functions P and Q are built out of the φ j as For notational purposes, we also use the superscripts ± to denote shifts by ±iπ/4 in the argument of a generic function f : Functional equations We would like now to convert the Baxter-like equations (37) into some functional equations for the kernels K . It proves useful to split them into their even and odd components defined aŝ so that for example, and similarly for R o .
Here and in what follows we omit the z dependence of R o and R e in order to make the notation simpler. Finally, we will be interested in computing the trace of the j-th convolution of the kernel (see expression (17)) for which we conveniently define Owing to the lemma (23), the kernels have a simple form when written in terms of the Baxter-like functions Q and P , We would like now to use (37) to find functional relations involving R e (u) and R o (u). It turns out that one needs an additional auxiliary function η built out of a combination of P and Q in order to close the system of equations. We refer the reader to the appendix A where the full details are provided. Here we simply quote the final result, where the tilde functionR e andR o have a very simple relation with the corresponding untilde ones given in the appendix A. These equations are the basis for the Tracy-Widom TBA to be derived in the next section.

Inversion and Tracy-Widom TBA
We will now discuss how to use the system of functional equations (44), (45) and (46), along with certain analytic properties of the functions involved, to obtain integral equations that determine R e and R o uniquely. The basic idea behind the inversion of this type of functional equations is to consider them in Fourier space where the non-local relations become local as the shifts in the argument can be easily undone. However, that can only be performed provided one has some analytic control of the equations. More precisely, in order to Fourier transform them one must ensure that the transform itself converges. Besides that, to undo the shifts one must account for the singularities (if any) as the integration contour is deformed.
For the kernel = s, these conditions have already been thoroughly studied by Tracy and Widom [13] and we will not redo that analysis here. The outcome is that the two sides of the functional equations are free of singularities within the strip | u| < π/4 and they are L 2 functions. Therefore it is safe to Fourier transform them and undo the shifts in the standard way to obtain the first set of Tracy-Widom TBA equations, For the kernel = +, although the inversion of the equations (44) and (45) is analogous due to the same analytic properties, the inversion of (46) is slightly different. By definition (see appendix A), η + contains poles at u = ±iπ/4 and the RHS of equation (46) contains a pole at u = 0. To correctly invert it we introduce an i -prescription and do the Fourier transform with an integration contour parallel to the real axis at u − i with u ∈ R. We can then freely shift the η + + to the real axis. We can also shift η − + to the real axis, at the price of adding the contribution of half the residue of the pole at u = −iπ/2 that crossed the contour along the way. That contribution can be traded by a principal value integration. After some straightforward manipulations, we arrive at the following integral equations where in the first equation the integral is performed in the principal value sense. These equations are the main result of the paper. It is now simple to implement and very efficiently iterate them numerically. This is the subject of the next section.

Numerics and comparison with CFT
In this section, we will make some tests of the Tracy-Widom TBA equations. We first solve them numerically and compare the results with the brute force numerical evaluation of the Fredholm determinants. We then study the limit of small radius and make contact with some analytic results available from the boundary Liouville theory.

Numerical evaluation of Fredholm determinants and checks
In order to numerically implement the Tracy-Widom TBA equations (47) and (48), we will consider a power series expansion in z of each of the functions involved 9 We then plug these expressions in (47) and (48)  , provided we have first solved the standard bulk TBA which enters in the seed for this recursion through (u). The first few terms obtained in this way read as follows where the principal value integral in the second formula only applies to = + and becomes an ordinary integral for = s. The higher order terms are lengthier but equally straightforward to be obtained. We can then compute each term in the series expansion of the Fredholm determinant (17) by the formulas With this method, we can truncate the sum in (17) Table 1: We have computed the first few powers of the two kernels using both the Tracy-Widom TBA and by performing the multiple integrations. While through the TBA it is straightforward to generate arbitrary high powers of the kernel with very high precision, we find the direct integration to be feasible to a certain precision for the first few powers but much more demanding beyond that. We show here the agreement between both approaches to some precision for the choice mL = 1. The digits in bold are significant (on the TBA side one can easily increase the accuracy).  Table 2: A few examples of the g-function for a choice of the boundary parameters (η = π/2 and ϑ = 0) and for different values of the sinh-Gordon mass and radius. The sum (17) was truncated to 10 terms. We only show the significant digits, but one can straightforwardly increase the accuracy.
compare the formulas for the n-th term of the expansion with the direct computation of the corresponding n-th fold integral. The results showing agreement between both approaches are summarized in table 1.
We can finally assemble together the Fredholm determinant with the remaining ingredients of the g-function as in (7), namely the expression of the reflection and bulk scattering matrices, and get explicit numbers out for a given choice of the sinh-Gordon radius L and mass m. A few examples are given in table 2.

Boundary sinh-Gordon and Liouville conformal data
Having at hand all the tools to determine the g-function to very high precision, we can proceed to make a comparison with the expected CFT behavior in the limit of R → 0.

sinh-Gordon in the UV
Let us recall the "open string" channel formulation of the (boundary) sinh-Gordon. The bulk theory is defined by the Lagrangian density (13) integrated over a strip of width R. To this Lagrangian we add boundary interacting terms on the left and right boundaries which we choose to be the same for simplicity. Each integrable boundary is furthermore characterized by the two complex parameters η and ϑ encoded in the reflection matrix (15). Again for simplicity, we will set ϑ = 0 such that the boundary problem is fully characterized by a single parameter. In summary, we end up with the following Lagrangian where the cosmological constant µ B is related to the parameter η by [60,61] and we will often use instead the parameter s defined by πs = b η, as s is self-dual under the duality transformation b → 1/b.
As described in [62], owing to the scaling properties of the operator cosh(2bφ) we can rescale the width of the strip to 2π, and incorporate the R dependence on the cosmological constants. We obtain In the ultraviolet limit R → 0, we can neglect one of the exponentials of the interacting term so that the theory gets reduced to the boundary Liouville. Switching to the "closed string" channel, it is then natural to expect that the g-function is related to the overlap of a bulk and boundary states in Liouville theory. The goal of this section is to make this connection more precise.
Let us describe the bulk and boundary states in both theories using the "closed string" channel formulation. A more intuitive way of thinking of the space of states in the (bulk) Liouville theory consists in studying the quantum mechanical model of the zero mode of the Liouville field φ(x). This is obtained by considering a field configuration which is constant over space, In this approximation, the states are characterized by the eigenvalue P of the canonical momentum conjugate to the zero mode, which is a continuous parameter (often called Liouville momentum), and discrete modes.
If we furthermore restrict ourselves to the classical limit where b → 0 and take the momentum P to be also of order b, then the nontrivial dynamics gets restricted to the zero mode φ 0 with the additional discrete modes being negligible (this is the so-called minisuperspace approximation).
We can also use the same approximation for the bulk sinh-Gordon theory. We define φ 0 analogously to (55) and the corresponding conjugate momentum P (L), which is now a function of the radius L. In the UV limit, the ground-state energy E(L) = −πc eff /6L approaches the CFT behaviour where the effective central charge becomes the Liouville central charge, c eff → c L = 1 − 24P 2 with P being the Liouville momentum. In the limit L → 0 we expect the effective central charge to have the same dependence on the momentum up to corrections in L [62], where P (0) coincides with the Liouville momentum. From now on, we will omit its L dependence and simply denote it by P . In this minisuperspace approximation, the bulk ground-state is described by a wave-function ψ P (φ 0 ) satisfying the Schödinger equation which in this case takes up the form of an hyperbolic Mathieu equation, As we focus on the region for φ 0 > 0, the left wall of the potential localized at 2bφ 0 ∼ log(µ L 2π 2 ) has a small effect on the solution in the CFT limit and we expect it to converge to the Liouville wave-function, see figure 2, where K 2iP/b is a modified Bessel function. On the other hand, for φ 0 < 0 we expect to have the mirror solution, obtained from the above by P → −P and φ 0 → −φ 0 . Around the middle region, log(µ L 2 ), both potential walls are far apart and one expects the wave-functions to be well approximated by a plane wave. Taking the plane-wave limit of the region φ 0 > 0 (which amounts to take φ 0 → −∞ in (58)) we obtain, with the (classical) reflection matrix S cl (P ) given by By considering the same plane-wave limit in the region φ 0 < 0 and requiring compatibility of both wave-functions, we obtain the quantization condition of the momentum P , This is the classical version (b → 0) of the quantization condition described in [62]. We will use it to define the momentum as a function of L. In particular, from this relation, we get that for the ground-state, the momentum P goes to zero as L → 0, We then conclude that the ground state of sinh-Gordon gets mapped in its CFT limit into a state of zero-momentum in the Liouville theory.  Figure 2: The sinh-Gordon potential and the corresponding wave-function. In the two colored regions, we can approximate the wave-function by the corresponding Liouville one.
In the middle region, they reduce to plane waves and requiring their compatibility enforces the quantization condition (61).

Liouville boundary data
The object of interest for comparison with sinh-Gordon g-function is the bulk one-point function of the boundary Liouville theory whose formula was bootstrapped in [63]. In terms of the Liouville momentum P and the boundary parameter s (see discussion around (53)), its expression reads where the bulk states are normalized according to An immediate problem with this expression for comparison with the g-function is the existence of the IR singularity manifest in the pole at P = 0, which is precisely the point we are interested in. We would like to find the correct prescription to subtract this pole and obtain a finite result. This is generally a nontrivial problem but we can obtain some insight by studying it within the minisuperspace approximation and eventually guess the full quantum result from it.
Classically, the one-point function B s |v P cl boils down to the overlap between the bulk and boundary wave-functions. The bulk wave-function is a solution of the Schrödinger equation (57) while the boundary one is related to the boundary Lagrangian by and the classical sinh-Gordon one-point function is simply where the superscript 'cl' emphasises that this is the classical result. Rather than attempting at computing this integral, let us relate it to B s |ψ P cl L in this limit. For that we split the integration in two regions, φ 0 < 0 and φ 0 > 0, In each of these regions and in the limit L → 0, the integrand is well approximated by the corresponding Liouville counterparts, We can complete the integration regions over the full real axis and compensate with the appropriate subtractions. We obtain where in the second line we have computed the pole subtractions by approximating the corresponding wave-functions by plane-waves. Interestingly, the second line is independent of the boundary parameter s and as such we rather consider the one-point function relative to a reference boundary state with parameter s 0 , The above classical considerations suggest that the full quantum U s 1 ,s 0 (P ) is given in terms of the Liouville one-point function as where we have accounted for the normalization (64) 10 . We would like to compare this quantity with the g-function, or rather, the difference of g-functions for two different boundary parameters s 1 and s 0 . The g-function can be plotted as an approximate function of P , where P is determined by the quantum version of (61), see appendix B for details. We expect that for very small radius L or, equivalently very small P , the relation (61) becomes more accurate and P defined as such approaches the Liouville momentum. The results are shown in figure  3. We have made the comparison for many different choices of the boundary parameters and here we display two such choices for illustration. In all cases, it became apparent that for small momentum there is a qualitative agreement between both quantities. We should emphasize that this match is, nevertheless, not expected to be optimal away from P = 0 as the relation (61) is approximate and, adding to this, the small radius limit is numerically harder to achieve. It would be interesting to better understand how to exactly solve the Tracy-Widom TBA in the UV limit along the lines of [41] for the sinh-Gordon UV central charge and perform a more analytic comparison with Liouville.

Separation of variables and g-function
In this section, we present multiple integrals which we conjecture to describe a universal part of the g-functions in the sinh-Gordon theory. It is a natural generalization of the formula for the finite-volume one-point function by Lukyanov [35], which is based on Skylanin's separation of variables (SoV) [15]. We first explain basic properties of Lukyanov's integral formula to motivate our proposal. We then present our conjecture and discuss its properties. Unlike the other sections, here we consider the sinh-Gordon theory at generic coupling b.

Q-Function and Lukyanov's formula
Lukyanov's formula is written in terms of the Q-function, which was first discussed by Zamolodchikov in [64]. It is related to the pseudo-energy of TBA as 11 and satisfies the functional identity with a ≡ (1 − b 2 )/(1 + b 2 ) and Q [±2a] (u) ≡ Q(u ± iaπ 2 ). Another important quantity is the T -function which is defined by 12 Using (73), one can show the periodicity of the T -function Thanks for the duality of the sinh-Gordon theory b ↔ b −1 , one can define a dual T -function, which satisfies the dual periodicityT These functional equations were originally derived for the ground state but they are expected to hold also for excited states [18,64].
In [35], Lukyanov wrote down a multiple-integral formula for the one-point function in the finite volume. Specializing it to the identity operator, we obtain the following expression for the norm of the state Ω|Ω = lim N →∞ I N , with ∆(θ j , θ k ) ≡ (2 sinh ν(θ j − θ k )) (2 sinhν(θ j − θ k )) , Using the Vandermonde determinant formula, this can be re-expressed as Next we expand one of the determinants into a sum over permutations. Owing to the antisymmetry of the rest of the integrand, all the permutations give the same answer. We can thus pick the simplest one σ j = j and multiply the overall factor (2N + 1)!. After doing so, we expand the other determinant to get One can then re-organize this into a determinant of size 2N + 1, with Before ending this subsection, let us point out one interesting property of the formulae (78) and (83) which was not discussed in the literature. For this purpose, we first conjecture that (78) and (83) can be generalized to the overlap between arbitrary excited states Ψ 1 |Ψ 2 by the replacement where Q 1,2 denotes the Q-function for the state Ψ 1,2 . We should emphasize that this is purely a conjecture unlike (78), which was derived from the lattice discretization. Nevertheless it reproduces the salient feature of the overlap, namely the orthogonality of different eigenstates. To see this, we consider the T -functions associated to these states Since they satisfy the periodicity condition (75), one can expand them as Let us next consider a vector a ≡ (. . . , a and multiply it to the matrix We then get Here we used the Baxter equations (86) in the second line. In the third line, we shifted the arguments of the terms denoted in red by iπ(1 − a)/2 using the periodicity of e 2νjθ .
The result (90) shows that the matrix M (1,2) has a zero eigenvalue. From this (and (83)), it immediately follows that the conjectured formula for the overlap Ψ 1 |Ψ 2 vanishes unless they have the same T -functions T 1 = T 2 .

Conjecture for g-function
Factorization of norm To motivate our proposal for the g-function, let us first show that the determinant expression for the norm (83) can be factorized into a product of two smaller determinants whenever the Q-function is parity symmetric Q(−θ) = Q(θ). Using the parity symmetry, we rewrite the matrix element M j,k as We next re-order the rows and the columns of M and bring it into a block-matrix form, with 1 ≤ s, t ≤ N . We then add and subtract rows and columns of M without modifying its determinant to get This shows that det M can be factorized into with Here we used the parity symmetry of the Q-function and rewrote (Q(θ)) 2 as Q(θ)Q(−θ) for later convenience.
Conjecture for g-function The expression (95) resembles the factorization of the Gaudin norm of parity-symmetric Bethe states in integrable spin chains 13 . In that case, one of the factors gives an universal part of the overlap between the boundary state and the Bethe state, which does not depend on the details of the boundary state. Now, from the analogy with the Gaudin norm, we conjecture that the overlap between the boundary state and the ground state is given by B|Ω ∝ det M − . Together with the expression for the norm Ω|Ω = det M , this leads to the following conjecture for the universal part of the g-function, which is given by a ratio of the Fredholm determinants (7) Det(1 −Ĝ) Here N is a possible normalization factor which cannot be determined by this simple argument.
Note that the full g-function is given by a product of (97) and the overall factor which depends on the reflection matrix (see (7)). Since the overall factor is given in terms of the pseudo-energy, it is straightforward to express it in terms of Q-function as SoV-like integral for g-function One can also rewrite our conjecture into multiple integrals, which can be viewed as a generalization of Lukyanov's formula. Since det M is given by Lukyanov's formula, our task is to rewrite the denominator det M − into multiple integrals. To do so, we note that 2 sinh(nαθ) is 2 sinh αθ times a polynomial of 2 cosh αθ of degree n − 1: 2 cosh(nαθ) = (2 sinh αθ) × (2 cosh αθ) n−1 + · · · . (99) Therefore, by adding and subtracting rows and columns, we can replace M − with the following M − without changing its determinant (det M − = det M − ): Now using the Vandermonde determinant formula, one can re-express det M − ≡ I N as follows: with 13 See for instance [65] and references therein.
Combined with Lukyanov's formula (78), the expression (101) gives the SoV-like integral representation for the ratio of Fredholm determinants, We must admit that our proposal is incomplete since we were unable to specify 14 the (possible) normalization factor N . Nevertheless we think that the results and the arguments presented here are useful for several reasons: First, despite incompleteness, our proposal reproduces one of the most important properties of the overlap B|ψ ; namely the overlap is nonzero only when the state |ψ is parity-symmetric. See below for the derivation. Second, in appendix R of [11], a similar integral representation was derived for an overlap between the boundary state and the Bethe state in the XXX spin chain. There, it was derived by rewriting an exact expression for the overlap [68]. However one can alternatively arrive at the same expression by following our argument as we show in appendix C; namely by rewriting the SoV integral for the norm [69] and factorizing it into two pieces. Such a trick would be useful for guessing the integral representation for the overlaps in higher-rank spin chains, for which the SoV integrals for the norms were discussed in [70,71].
Selection rule One of the important properties of the integrable boundary state is that it is annihilated by the action of higher conserved charges which are odd under the parity transformation [36]. Owing to this property, the overlap B|ψ will vanish if the state |ψ is not parity-symmetric. We now show that our proposal reproduces this selection rule; namely det M − vanishes if the Q-function is not parity-symmetric, Q(θ) = Q(−θ).
The derivation is similar to the proof of orthogonality. The starting point is to consider a linear combination of T -functions, T (θ) − T (−θ). If the state is not parity symmetric, this does not vanish and can be expanded as since it is periodic with period iπ(1 + a)/2 and odd under θ → −θ. We then consider a vector and multiply it to M − . This leads to This shows that M − has a zero eigenvalue and therefore we have det M − = 0.

Conclusion
In this paper, we reformulated the g-functions in the sinh-Gordon theory in terms of the TBA-like integral equation, which we called the Tracy-Widom TBA. The resulting integral equation is more efficient than the results based on the Fredholm determinants. We only performed the analysis for a specific theory but we hope our result paves the way towards finding a more efficient formalism for g-functions in general integrable theories. Below we mention several future directions.
Excited-state g-function One promising direction is to study the excited-state g-functions discussed first in [9] and computed in a full form in [11,12], see also [72]. For excited states, the result is given by a generalization of the Fredholm determinant which involves both integrals and sums. It would be interesting to see whether and how our analysis carries over to such cases. Another related question is to understand the analytic continuation of the Tracy-Widom TBA. In standard TBAs, the analytic continuation allows us to compute the spectrum of the excited states [73]. It would thus be interesting to see if some analytic continuation of the Tracy-Widom TBA gives the excited-state g-function.
Generalization to other theories Another immediate question is whether one can generalize the analysis of this paper to more general integrable field theories. In particular, the generalization to theories with bound states and/or internal degrees of freedom would be important since the Fredholm determinant for such theories takes an even more complicated form, and there are also conceptual points to be understood 15 .
Application to N = 4 SYM Once these two generalizations are achieved, an obvious next step is to apply this formalism to N = 4 SYM in which a special class of three-point functions can be computed by the excited-state g-functions. Such a reformulation would allow us to perform the numerical computation more efficiently and understand how the finite-coupling g-function interpolates between the weak and strong coupling results.
Putting it into a broader context, it would be important to find functional/integral equations which directly compute the correlation functions of N = 4 SYM. Currently the most advanced method for computing the correlation functions from integrability is the hexagon formalism [29]. Although it in principle provides a way to compute nonperturbative correlation functions, it is desirable to find an alternative since the hexagon formalism gives an infinite series of the intermediate states which is sometimes hard to evaluate. Recently there are some hints [74][75][76] that the correlation functions may be reformulated as integrals of the so-called Quantum Spectral Curve [22,23]-the most efficient formalism for computing the spectrum. However, even if this is achieved, it is not totally clear if such integrals are really tractable 16 at finite coupling. Thus it would be important to find an analogue of TBA or Quantum Spectral Curve which directly computes the correlation functions. We hope our work provides a small step towards such an ambitious goal.
Application to S 3 partition function In this paper, we generalized the Tracy-Widom TBA in [13,14] to the kernel given by (22). The same kernel shows up also in the computation of the S 3 partition functions of superconformal Chern-Simons theory with orthosymplectic gauge groups [77][78][79][80][81]. It should therefore be possible to derive the Tracy-Widom TBA for those theories and use it to analyze nonperturbative corrections.
Separation of variables Another important future problem is to sharpen our conjecture for the SoV-like integral (and correct it if needed) by starting from the lattice discretization [35,66,67] and taking the continuum limit. It would also be interesting to apply our argument to higher-rank and/or non-compact 17 spin chains and guess the SoV representation for the overlap between the boundary state and the Bethe state.
Other directions Our result for the g-function has a "double-layer" structure. To compute it, we first solve the standard TBA and then plug the result into the Tracy-Widom TBA. This might appear slightly unusual, but a similar double-layer structure shows up in the analysis of the wall crossing of the 2d-4d coupled system [83] (see for instance (5.21)-(5.24)). It would be interesting 18 to compare the two and understand the similarities and differences. A somewhat related question is whether our result has any implication to the ODE/IM correspondence [84] 19 . The ODE/IM correspondence allows us to compute the spectrum of certain Schrödinger equations from a standard TBA. It would be interesting to find counterparts of the g-function 20 and the Tracy-Widom TBA in that context. 16 In fact, the SoV-like integral we conjectured in this paper is very hard to evaluate in practice. 17 The Gaudin-like determinant formula for the overlap in the SL(2) spin chain was conjectured in [11] and proven recently in [82]. In appendix C, we present a conjecture for the SoV representation of such overlaps. 18 It would be fascinating if one can directly relate the two by considering some supersymmetric integrable theories with boundaries. 19 See also the review [85] and more recent developments [86,87]. 20 A natural guess is a wave function itself.

Acknowledgement
We thank Alba Grassi

A Derivation of the functional equations
In this appendix we provide the technical details of our derivation of the functional equations for the Fredholm determinants and K (u, v) is defined by For the kernel K s , the steps are completely analogous to the Tracy and Widom proof [13]. The result for the kernel K + is new as far as we know.
Baxter-like functional equation For convenience, we will redefine here the auxiliary functions φ j as so that the recursion obeyed by ψ j now reads We now convert this representation into a functional equation by using the identity (36), where δ s = 1 and δ + = 2 and we have used that ψ +j (−u) = ψ +j (u). A more useful recursion relation for what follows can be obtained by defining new functions P (u) and Q (u) out of the ψ j (we have also written them in (38) in terms of φ j ), which immediately allows us to arrive at the Baxter-like equations (37), provided we use that (u) is an iπ-periodic function. We can easily determine the asymptotic behavior of these functions directly from their definition (113). In fact, we have that lim u→∞ ψ j (u) = 0 for j > 0 while for j = 0 the asymptotics are lim u→∞ ψ 0 (u) = 1+e (u) 2 E (u). With this we obtain that, Useful identity We will now prove an identity that will play an important role in the derivation, We follow similar steps as in [13]. Let us start by defining the functions S (u) as From the equations (37) it follows that S − = −S + and therefore S (u) is iπ/2-periodic. From the definition of S (u) one can show that this function is analytic in the strip [−iπ/2, iπ/2] (a rigorous proof of all these statements can be found in [13]). This then implies that the function is analytic and bounded. For the case of = +, the apparent singularities at u = iπ/4 + πn with n ∈ Z, are in fact cancelled by the numerator. Indeed, say at u = iπ/4 we have that S + (iπ/4) = Q + (iπ/2)Q + (0) − P + (iπ/2)P + (0) .

Final functional equations
We now have all the tools at hand to derive some functional equations involving R e and R o which can be expressed in term of P and Q through (43). Again, once we determine these functions, we are able to compute each term in the series expansion of the Fredholm determinant (17). The derivation of the functional equations works similarly for both kernels = s, + with some small differences in explicit formulae and therefore we will derive them both simultaneously. As noted in [13], it proves useful to introduce an auxiliary function out of a particular combination of P and Q, namely What we will show now is that with η , R e and R o we can find a closed system of functional equations that we will later be able to invert and determine these three functions explicitly.
Note that thanks to the identity (115) derived before, we can equally write (121) as The first functional equation is immediately obtained by taking the product of the previous two equations and taking the logarithm, getting whereR e s (u) = R e s (u) andR e + (u) = cosh(2u) cosh(u) 2 R e + (u). By considering the difference of the logarithmic derivatives of equations (121) and (122) we obtain yet another functional equation 2i η η 2 + 1 = 2i arctan(η ) =R The last equation is again obtained from a combination of (121) and (122). By shifting the argument of (121) as u → u − iπ 4 and (122) as u → u + iπ 4 we obtain and where we used E ++ = −E −− which itself follows from the periodicity ++ = −− . We then sum these two equations and use the relation (37) to arrive at where we remind that δ s = 1 and δ + = 2.

B Details on the comparison with Liouville boundary data
In this appendix, we elaborate on the comparison with the Liouville bulk one-point function.
We have expressed the g-function in terms of a momentum P which is defined as a function of L by the quantum version of (61) (see [62]), where S(P ) is the reflection matrix The cosmological constant µ is related to the sinh-Gordon mass by For the self-dual sinh-Gordon studied in this paper, we express the results in terms of the mass using (130) and finally set b = 1. Another practical way of finding the relation between momentum and the sinh-Gordon radius L has been applied in [62] and uses the bulk TBA, from which we compute the effective central charge For small L, c eff is approximately related to the momentum by which we can use to go from L to P or vice-versa.

C Factorization of SoV integral in spin chains
In this appendix, we apply the argument presented in section 5 to the SU(2) (XXX) spin chain and reproduce an integral representation for the overlap between the boundary state and the Bethe state, which was first derived in appendix R of [11]. We also apply the same argument to the SL(2) spin chain and conjecture the SoV integral representation for the exact overlap [11,82].

SU(2) spin chain
To simplify the discussion, we assume that the length of the spin chain L is even and is twice the number of magnons m. The integral representation for more general cases can be derived from it by following the argument in appendix R of [11].
The starting point is the SoV integral for the norm [69] u|u ∝ where |u is the onshell Bethe state with rapidities u = {u 1 , . . . , u m }, while Q(x) and Q θ (x) are given by with θ j being the inhomogeneities. The contour C encircles all the poles in the integrand θ j ± i 2 . Now, up to a θ-dependent prefactor, the integral (134) coincides with the following slightly different integral The equivalence between the two follows from the identity and the fact that the extra factor f gives a θ-dependent overall constant k (−1) L 2 exp (πLθ k ), regardless of which poles in the integrand we choose to pick 21 .
Using the Vandermonde determinant formula, we can rewrite (136) into a determinant of a L × L matrix u|u ∝ det (M j,k ) 1≤j,k≤L , with x j−1 e π(2k−L−2)x .
In particular M j, L+2 2 = 0 for odd j. Given this structure, it is natural to re-group j into even and odd integers and k into { L 2 + 1, . . . , L} and { L 2 , . . . , 1}. As a result, we get the following block-matrix structure 21 Owing to the Vandermonde factor (x j − x k )(e 2πxj − e 2πx k ), we can only pick one from each set {θ k + i 2 , θ k − i 2 }. This leaves us 2 L choices of poles (up to permutations). It is straightforward to verify that f gives the same answer k (−1) where A and B are L 2 × ( L 2 − 1) matrices, and a, a and b are L 2 -component vectors: We can then show that the determinant factorizes as whereÃ andB are square matrices of size L/2, Here we replaced Q(x)Q(x) with Q(x)Q(−x) using the parity symmetry.
From the analogy with the Gaudin norm, it is reasonable to conjecture that one of the determinants, detÃ or detB, describes the overlap between the boundary state and the Bethe state. Applying the argument in section 5.2 and using the Baxter equation one can show that detÃ reproduces the selection rule; namely it vanishes unless the Qfunction is parity-symmetric. Therefore, we expect detÃ is the one that corresponds to the overlap.
To make contact with the result in [11], we need to rewrite detÃ into multiple integrals. To do so, we use the fact that 2 cosh(αnx) is a polynomial of 2 cosh αx of degree n, 2 cosh(αnx) = (2 cosh αx) n + · · · . (146) We can then add and subtract rows and columns, and replaceÃ with the following matrix without changing its determinant x 2j−1 (2 cosh(2πx)) k−1 .
Conjecture for SL(2) spin chain The same argument applies also to the non-compact SL(2) spin chain. The SoV-integral representation for the norm was written down in [88] (see also (G.43) of [49]), and it reads where L is the length of the spin chain which we assume to be even while Q(x) is the Q-function with u s being the rapidities of magnons. As with the SU(2) spin chain, the integral (150) can be converted into a determinant using the Vandermonde formula, with If the state is parity-symmetric, one can rewrite this as 23 We can then use the same trick as in the SU(2) spin chain; namely we reorder, add and subtract rows and columns. As a result, we obtain the following factorized expression: whereÃ andB are the matrices of size L 2 − 1 and L 2 respectively and read Among the two determinants detÃ and detB, the one that reproduces the selection rule is detÃ. We thus expect that the overlap is given by detÃ. To convert it into multiple integrals, we use the identity (99) and the Vandermonde formula. As a result, we get 23 Note that the roles of even and odd j's are swapped here as compared to (140) since the contour C in (140) is invariant under the parity x → −x while the contour here changes the orientation.
with∆(x, y) given by (149). We conjecture that (157) gives the SoV representation for the overlap between the boundary state and the Bethe state. Of course, to use this formula in practice, we need to determine a constant of proportionality. In principle, this should be doable by comparing (157) and the results in [11,82]. It would be an interesting future problem to carry this out and prove our conjecture (157) (and correct it if needed).