Transport fluctuations in integrable models out of equilibrium

We propose exact results for the full counting statistics, or the scaled cumulant generating function, pertaining to the transfer of arbitrary conserved quantities across an interface in homogeneous integrable models out of equilibrium. We do this by combining insights from generalised hydrodynamics with a theory of large deviations in ballistic transport. The results are applicable to a wide variety of physical systems, including the Lieb-Liniger gas and the Heisenberg chain. We confirm the predictions in non-equilibrium steady states obtained by the partitioning protocol, by comparing with Monte Carlo simulations of this protocol in the classical hard rod gas. We verify numerically that the exact results obey the correct non-equilibrium fluctuation relations with the appropriate initial conditions. Copyright J. Myers et al. This work is licensed under the Creative Commons Attribution 4.0 International License. Published by the SciPost Foundation. Received 28-06-2019 Accepted 02-12-2019 Published 20-01-2020 Check for updates doi:10.21468/SciPostPhys.8.1.007

functions in transport setups of truly interacting many-body models in order to gain a deeper understanding of non-equilibrium physics.
Fluctuations in non-equilibrium transport can be studied by analysing the statistics of the number of particles, their energy, or any charge they carry, passing through an interface in a bipartition of the system, see Figure 1. Exact results for transport SCGFs have been obtained in various systems (at various levels of mathematical rigour). For instance, exact formulae are known in non-equilibrium steady states (NESSs) of some stochastic classical gases such as exclusion processes [37,40,41]; these are understood within macroscopic fluctuation theory [43][44][45][46][47] based on diffusive hydrodynamics. Some results have also been obtained in open quantum chains, see e.g. [48,49]. Such stochastic or open models, however, make assump- Figure 1: Schematic illustration depicting counting statistics in a steady state regime. One "counts" the number of particles (or their energy or charge) passing a given coordinate during a large time interval and then gathers the statistics of these large numbers, scaled with time.
tions about the external baths. It is crucial to understand intrinsic transport fluctuations in deterministic, isolated, quantum and classical systems, where exact many-body interactions are fully taken into account. In an ensemble formulation, fluctuations originate from those in the initial state. Despite many efforts, only a few results exist: free-fermions with the celebrated Lesovik-Levitov formula [50][51][52], harmonic chains [53] and free field theory [54,55], particular integrable impurity models [56], and one-dimensional critical systems [57,58]; see the review [59]. Some results also exist for fluctuation statistics of other quantities, not related to transport, in certain integrable models, see for instance [60][61][62][63]. A full grasp of counting statistics for transport in interacting many-body systems, especially where integrability and ballistic processes dominate, remains an open problem.
In this work, we obtain the first (to our knowledge) model-agnostic exact expression for transport SCGFs in homogeneous stationary states of interacting one-dimensional integrable systems. Our analytical approach involves a new and completely general framework based on large deviation theory and Euler-scale linear fluctuating hydrodynamics that gives access to exact SCGFs for ballistic transport, developed in a companion paper by two of us (BD and JM) [92].
The states considered are very general, and include current-carrying NESSs. In particular, they include NESSs obtained by the partitioning protocol [15,16,[19][20][21][22][57][58][59]64,65,[67][68][69][70][71], where an inhomogeneous, "unbalanced" initial condition generates, at large times, a homogeneous stationary current-carrying state. We emphasise that although the theory applies to transport statistics in homogeneous stationary states, this statistics can be evaluated from transfer measurements starting at the initial time of the protocol, as the large-time, stationary region dominates. The expression applies to all models whose large-scale dynamics is gov-erned by GHD, and to transport of all local conserved quantities they admit. This includes the Lieb-Liniger model [72,73] which has been shown to describe cold atomic gases in quasione-dimensional traps [74][75][76] (see e.g. the experiments [5,25] where the integrability of the Lieb-Liniger model played an important role, and the book [77] for a review), and many other quantum field theories, as well as integrable quantum chains, classical field theories, and classical gases such as the hard rod gas [78,79] and soliton gases [80][81][82][83][84].
We provide explicit checks on the predictions for the first few transport cumulants by comparing with Monte Carlo simulations of the hard rod gas. For this purpose, we explicitly implement the partitioning protocol in the hard rod gas, and measure the total energy transferred from the initial time of the protocol. We find very convincing agreement with the theory. We also verify numerically that the exact expression in the Lieb-Liniger model satisfies the nonequilibrium fluctuation relations of Gallavotti-Cohen type [85][86][87][88][89][90].
The paper is organised as follows. In section 2 we review the large deviation theory for non-equilibrium transport. In section 3 we outline the general theory of fluctuations in ballistic transport based on Euler-scale identities. In section 4 we review aspects of the thermodynamic Bethe ansatz that will be useful in this work. In section 5 we present our main result, the exact full counting statistics for transport in integrable models. In section 6 we apply this result to the hard rod gas, providing Monte Carlo verification, and in section 7 we apply it to the Lieb-Liniger model, verifying the non-equilibrium fluctuation relations. Finally, we conclude in section 8. A series of appendices provide supporting calculations.

Large deviation theory for transport
This section provides background on large deviation theory (LDT), and introduces the scaled cumulant generating function (SCGF) for transport of conserved quantities in the context of integrable models. We also briefly recall some aspects of non-equilibrium fluctuation relations (FRs). The setup is as in fig. 1, specialised to one dimension -the interface is then a single point.

Rate functions and multiple conservation laws
Large deviation theory focuses on fluctuating quantities J (t) which are extensive with respect to some parameter t, and whose densities J (t) /t take almost-sure values in the extensive limit t → ∞. A standard example is the energy in equilibrium thermodynamics, with t being the volume. According to the large deviation principle [42], such extensive quantities have probability distributions that are exponentially peaked at the almost-sure value; in the cases of interest here, this takes the form The function I( j) is referred to as the large-deviation rate function. It describes the probabilities of rare but significant events where the quantity J (t) deviates "macroscopically" from t.
The framework is general enough to encompass fluctuations in transport, and systems that are far from equilibrium, see e.g. [91] for stochastic processes. In the setup of fig. 1 which we consider in the present paper, J (t) is the total current of some conserved charge that has passed through the interface in a time t, and the state is a homogeneous steady state. Recall that the evolution is deterministic, but the state, at time t, is fluctuating due to the ensemble description of the initial condition leading to the probability distribution we denote as P(· · · ) above.
In order to describe more precisely the state and the total current J (t) , we consider a system with a certain number of (local or quasi-local) conserved quantities Q i = dx q i (x, 0). This number will be taken to infinity, as we are interested in integrable models which, in the thermodynamic limit, admit an infinite number of conserved quantities. Consider the associated local conservation laws indexed by i, with current density j i . States where entropy is maximised with respect to all local conservation laws are characterised by as many Lagrange parameters β i as there are conservation laws and, formally, have probability measure or density matrix proportional to In integrable systems, these probability measures are referred to as generalised Gibbs ensembles (GGEs) [6][7][8][9][10]. The infinite sum over the conserved quantities in (3) must be dealt with carefully: a precise definition of GGEs requires an appropriate completion of the space of conserved quantities [9]. In this sense, i β i Q i should be understood as a particular "pseudolocal" charge, characterised by coefficients β i in some basis decomposition. As is customary, we refer to GGEs with this general understanding. We will denote averages by 〈· · ·〉 β where β is the vector of Lagrange parameters β i . These are the homogeneous steady states that we will concentrate on in this paper. GGE states include many (homogeneous) NESSs. Indeed, the fundamental characteristic of a non-equilibrium steady state is that, despite being stationary, it breaks time-reversal invariance. As integrable systems admit conserved charges that break time-reversal symmetry, including the total momentum, many GGEs are non-equilibrium, current-carrying states. Physically, this corresponds to the fact that the presence of appropriate conserved quantities allows ballistic propagation, where currents are sustained without the need for an external force. A paradigmatic example of a NESS is that emerging from the partitioning protocol [64,65], which is referred to as the Riemann problem in hydrodynamics (see e.g. the lecture notes [66]). In this protocol, the steady state is formed, at very large times, by deterministic or unitary evolution from an initial inhomogeneous state which is homogeneous far to the left and right (x → ±∞), as e − i β i l Q i (left) and e − i β i r Q i (right). Despite the inhomogeneous initial condition, at infinite times, in any finite region around the central position, the state is expected to become homogeneous. In integrable systems, this state is a GGE. Such NESSs emerging from the partitioning protocol were constructed for integrable models in [21,22,26]: the β i 's for the NESS were obtained as functions of the β i l 's and β i r 's of the initial condition of the protocol. We will make use of these results below.
We focus on the total transfer of some particular charge Q i * , say from the left to the right of the system, in time t, see fig. 1. This can be, for instance, the number of particles (if particle number is conserved), the electric charge (in systems with U(1) symmetry), the energy, or any other conserved quantity. We are then interested in the total current passing by the origin, One expects (1) to hold for this quantity.

Scaled cumulant generating function and fluctuation relations
In a NESS, the average of J (t) /t is given by the almost-sure value. More generally, consider the scaled cumulants c n of the transferred quantity, or rather their generating function, the SCGF: By the Gärtner-Ellis theorem, if this limit exists and the result is differentiable, then the Legendre-Fenchel transform of F (λ) gives the large deviation rate function I( j) (see e.g. [42]). Note that if in fact the limit exists at each order in λ, then all the cumulants of J (t) scale like t, that is where the superscript c means that these are connected averages. The scaled cumulants can be expressed in terms of the average current and its connected time-integrated correlation functions. For example 2 where we recall that i * is the index of the charge, and corresponding current, we are interested in. The quantity c 2 is referred to as the zero-frequency noise in mesoscopic physics, and was dubbed the Drude self-weight in [32]. In sections 6 and 7 we will consider energy transfer, making j i * more concrete. Key ingredients of the general theory of NESSs are fluctuation relations, which compare the probabilities of "forward" and "backward" currents; see the reviews for classical [38,[93][94][95] and quantum [39,96,97] systems. For currents obeying (1), the fluctuation relations are reflected in fundamental symmetries of the SCGF connecting scaled cumulants in a non-trivial way: where ν is a constant encoding properties of the force or external baths generating the NESS. This formula applies, for instance, in the NESS emerging from the partitioning protocol described in subsection 2.1. Indeed, under certain conditions -if both the dynamics and the charge Q i * are time-reversal invariant and the initial state has an imbalance in Q only,

Fluctuations from Euler-scale hydrodynamics
The general theory of fluctuations for one-dimensional systems supporting ballistic transport, which we will refer to as the ballistic fluctuation formalism, is developed in [92]. This is the approach that we will use in order to access fluctuations in integrable systems. Explicitly, the theory shows how to construct F (λ), as defined in subsection 2.2, using Euler-scale identities.
Possible corrections to the Euler scale of diffusive and other types would provide subleading corrections to ballistic fluctuations

Flux Jacobian
Consider the averages of all local conserved densities, 〈q i 〉 = 〈q i 〉 β = 〈q i (0, 0)〉 β , and the current averages 〈j i 〉 = 〈j i 〉 β = 〈j i (0, 0)〉 β . We can write 〈j i 〉 as functions of 〈q i 〉 by inverting the relation between 〈q i 〉 and the Lagrange parameters β i . This functions describe the equations of state: in this form currents are sometimes referred to as "fluxes". From the equations of state we construct the flux Jacobian As this matrix plays a fundamental role in the ballistic fluctuation formalism, it is useful to recall some of the important equations where it is involved. The physical interpretation of the flux Jacobian is that it describes the flow of conserved quantities within maximal entropy states. Indeed, first, it is naturally involved in the Euler hydrodynamic equations for the system. These are the equations for the evolution of large-wavelength, low-frequency inhomogeneous states, and are obtained by applying the conservation laws (2) on densities and currents averaged within local entropy-maximised states [100]. Using the flux Jacobian, the Euler equations are written as equations for the averages 〈q i 〉 β(x,t) , By linear-response theory, A j i is also involved in evolution equations for space-time dependent connected correlation functions within stationary, homogeneous, maximal entropy states [100], Correspondingly, it is related to the rate at which correlation functions spread [101], The equations above lead to the observation that eigenvalues of the flux Jacobian correspond to velocities at which perturbations travel within a homogeneous state.

Flow equation and SCGF
Two equations form the backbone of the ballistic fluctuation formalism, the flow equation and an equation showing how this can be used to obtain the SCGF. We start with the flow equation. In the ballistic fluctuation formalism, one defines the state 〈O〉(λ) by biasing the measure e − i β i Q i , multiplying it by the operator generating the charge transport of interest, e λ dt j i * (0,t) . Here λ should be seen as the conjugate parameter for the particular quantity of interest indexed by i * as per (5) with (4). 3 It turns out that a state defined in this way is still a stationary, homogeneous, maximal entropy state [92]. The flux Jacobian is used in order to define a relation that characterises how the conserved quantities are affected by this λ-modification, a flow equation. This equation takes the form [92] where sgn(A) is the matrix obtained by diagonalising A and taking the sign of its eigenvalues. A motivation for this result can be obtained as follows. For simplicity let us consider the case where a single conserved quantity is present, so that A is a number, the velocity of a perturbation within the homogeneous state.
By definition of the λ-modified state, ∂ λ 〈j〉(λ) = dt 〈j(0, t)j(0, 0)〉 c (λ). On the right-hand side, by linear response in the limit x, t → ∞ with x/t constant (Euler scaling limit), the current is related to the corresponding charge multiplied by its velocity through the medium, so we can replace j(x, t) by Aq(x, t). Solving the hydrodynamic equation (11) by the method of characteristics, the correlation function is supported on x = At, hence we can use dx = |A|dt. Therefore On the other hand, ∂ λ 〈j〉(λ) = A∂ λ 〈q〉(λ). This gives (13) specialised to the case of a single conserved quantity.
It is useful to recast (13) in a different form so as to expose the λ-dependence in the Lagrange multipliers: This is the flow equation at the basis of the general theory. The flow equation can be used to determine the SCGF. This is achieved by first solving for β i (λ) and considering the λ-dependent currents 〈j i 〉 β(λ) ≡ 〈j i 〉(λ). Then, the general theory predicts that [92], This equation generalises the relationship between F (λ) and the cumulants (see (5) and (7)) for λ = 0. The average currents 〈j i 〉 and the flux Jacobian A j i are known exactly in integrable models, see [21,22,102] and [32]. Combining these exact results with the above formalism 4 gives an expression for F (λ). First, we must review the Thermodynamic Bethe Ansatz (TBA) formalism. The TBA description of integrable models will then be amenable to the application of the ballistic fluctuation formalism.

Thermodynamic Bethe Ansatz
In this section we review the powerful description of integrable models in the thermodynamic limit using the language of the Thermodynamic Bethe Ansatz (TBA).
In a wide family of many-body integrable systems, GGEs (introduced in section 2) are efficiently described via the TBA [103,104] in terms of "quasiparticles", whose scattering is elastic and factorises into two-body processes. The TBA is powerful enough to describe thermodynamics of not only quantum, but also classical models (including field theories, gases and chains). Exact solutions for the NESSs from the partitioning protocol in integrable models were expressed in the language of TBA in [21,22,26]. Quasiparticles are parametrised by a spectral parameter θ , which, in general, encodes both their momenta and type. Here, for simplicity, we will consider θ ∈ with a single particle type. Each quasiparticle θ carries a quantity h i (θ ) of charge Q i , for instance momentum and energy, which we will denote by p(θ ) 4 The validity of the ballistic fluctuation formalism rests on the assumption of strong enough decay of current correlation functions at large times [92]: essentially the time-integrated correlation functions (7) should be convergent. In integrable models, dynamical two-point correlation functions generically decay, at large times, as 1/t [32,34]. However, from [32, Eq 4.55], one can see that current two-point functions decay more rapidly along the time direction, making them integrable, with finite value given by [32,Eq 1.4]. Likewise, higher-point correlation functions are expected to decay strongly enough [34]. The arguments for the ballistic fluctuation formalism in fact require, in their current form, strong enough decay in a neighbourhood of the time direction [92]; a precise analysis of this in integrable models is left for future works. and E(θ ) respectively. The generalised specific free energy is given by dp(θ ) 2π F(ε(θ )) where the pseudoenergy ε(θ ) involves the Lagrange parameters and satisfies the non-linear integral equation Here, the "differential scattering phase" ϕ(θ , α) encodes the microscopic interactions, and is related to the two-body scattering matrix. We assume ϕ(θ , α) to be symmetric for simplicity -in many integrable models, there is a choice of spectral parameter where this is the case.
The TBA free energy function F(ε) depends on the statistics of the quasiparticles: for instance, for bosons, −e −ε for classical particles, 1/ε for classical radiative modes [34]. Intuitively, the pseudoenergy ε(θ ) of a quasiparticle θ determines the amount this quasiparticle contributes to the GGE probability distribution. It is a modification of the form it would have in free theories that takes into account the interaction with the other quasiparticles. It is important to note that instead of the Lagrange parameters β i , the pseudoenergy can also be used to fully characterise the GGE. The equations of state in GGEs were found in [21,22] and proven for relativistic field theory in [102], with the exact currents written as Here n(θ ) is referred to as the occupation function, and, like the pseudoenergy, is also sufficient to fully characterise the GGE. The superscript "dr" in h dr i refers to a fundamental operation within the TBA formalism, the dressing transformation. In a similar fashion to the pseudoenergy, the dressing transformation modifies a bare quantity, in this case h i , by taking into account the interaction with the other quasiparticles. The dressing transformation of some quantity g(θ ) is defined through the linear integral equation Using the dressing transformation, the flux Jacobian A j i , introduced in the previous section, was evaluated exactly in [32]. A consequence of the expression found there is that A j i is diagonalised by the dressing transformation: the vectors h dr i (θ ), for fixed θ , are its eigenvectors. The corresponding eigenvalues are the effective velocities of the generalised fluids, given by v eff (θ ) = (E ) dr /(p ) dr . Effective velocities describe the velocity of quasiparticles through the medium, given the interactions with other quasiparticles. More precisely, the result of [32] can be recast into the explicit form where here h j dr (θ ) are the orthonormal conjugates to h dr i under the L 2 ( ) inner product, i.e., dθ h dr i (θ )h j dr (θ ) = δ j i (with Kronecker delta, as the set of indices i is taken to be discrete). 5 By assumed completeness of the set of functions h dr j (θ ), we have In the Euler fluctuation theory, we are interested in sgn(A) j i , which is given by The example systems used in this work are the classical hard rod gas in section 6, and the quantum Lieb-Liniger gas in section 7. In both cases, there is only a single quasiparticle type. Furthermore these are both Galilean systems, so that θ can be taken as the quasiparticle velocity. The quasiparticle momentum and energy are given by p(θ ) = θ and E(θ ) = θ 2 /2 respectively, where we set the mass to unity.

Exact transport fluctuations in integrable models
We now turn to writing (14) and (15) for integrable models. This gives us an exact expression for the full counting statistics F (λ) of any total current, in terms of TBA quantities and a pseudoenergy function satisfying a flow-equation. From this, all cumulants can be obtained order by order in terms of TBA quantities in the original state. We believe this to be a remarkable result as, to our knowledge, no such widely applicable expression exists for interacting integrable models. The result naturally generalises the known expressions for free-fermion and other quadratic models [50][51][52][53][54][55], and for one-dimensional critical systems [57][58][59], see Appendix A and the discussion in [92]. However, its connection to the exact SCGF found in integrable impurity models [56] is not understood yet.
The exact expression for F (λ) is presented in (25).
An expression for F (λ) can now be obtained using (15) and the solution of (24) in (17). We will show below that where the sets λ ± (θ ) are the turning points of the sign of the effective velocity: The proof of (25) proceeds as follows. The idea is to take a derivative of (25) with respect to λ and show, in accordance with (15), equality with 〈j i 〉 from (17). We first take the derivative on the first line of the right-hand side of (25). Using the Leibniz Rule, two terms emerge. In the first, the derivative is applied on sgn(v eff (θ ; λ)), giving a δ-function contribution (under the integral), and thus the term On the other hand, taking the λ-derivative on the second line of the right-hand side of (25), we also obtain a δ-function contribution, which occurs when an element of the set λ a enters the interval [0, λ]. This contribution therefore has the form By a change of variables, we have and we see that (27) cancels (28). Finally, we are left with the second term from application of the Leibniz rule on the first line of the right-hand side of (25), the term in which the λderivative acts on the factor F(ε(θ ; λ)) − F(ε(θ ; 0)) . Using (24), we obtain (17), with the λ-dependent state n(θ ; λ). The final step is to check that F (0) = 0, which is trivially true. This completes the proof. Eq. (25) is an exact general result for the SCGF -or full counting statistics -in GGEs of arbitrary integrable models. The key development, the inclusion of interactions, is contained within v eff (θ ; λ) and ε(θ ; λ). The form of the result separates the effects of the fluctuations in the state, encoded within the free energy function F(ε), from the effects of the interactions.
The state fluctuations give rise to transport fluctuations, but in a way that is affected by the interactions, as the quasiparticle velocities and charges depend on the fluctuating state. Explicitly, the function F (λ) is obtained by solving (24) (numerically, or order by order in λ), and by then using the resulting pseudoenergy in order to evaluate the TBA quantities involved in (25), and integrating over the spectral parameter.
This result can be applied to any model with known TBA, opening up a diverse range of interacting quantum models for which we can obtain information about the statistics of flows. Importantly, the result agrees with the Lesovik-Levitov formula for free-fermions (appendix A). In order to illustrate this method we apply (25) to obtain new results in the classical hard rod gas and the quantum Lieb-Liniger model in the next sections.

Cumulants
Before we consider the specific models discussed above, we first show how to obtain cumulants from the expression (25). The first few cumulants provide important information about the shape of the distribution, and are the most accessible to numerical simulations and experiment; these are arguably the most important outcome of our expression for F (λ).
The cumulants are evaluated from (25) . The first cumulant is the average current, given in (17). For the second cumulant, omitting the θ -dependence of the integrand for lightness of notation, we obtain where ρ p = n(p ) dr /(2π) is the quasiparticle density, and f = −d log n/dε is known as the statistical factor. The expression in (30) was already evaluated exactly in [32] by different methods, and follows as a consequence of current-current sum rules [101]. Our expression is in agreement with this, providing an important check on our result. The higher cumulants are new, and in particular (again omitting the explicit θ -dependence of the integrand), wheref = −(d log f /dε + 2 f ) and s = sgn(v eff ). We have also evaluated c 4 , the result of which is presented in appendix B, but higher cumulants quickly become cumbersome. Details on the calculation of these quantities can also be found in appendix B. In [32], a natural linearresponse formulation was also shown to reproduce c 2 . The present results for c k agree with a generalisation of this linear-response formulation (see appendix C).
In the next section we confirm these exact predictions in the classical hard rod gas by direct numerical simulation, thereby verifying (25) while simultaneously obtaining new results for the paradigmatic hard rod gas.

Classical hard rod gas
In this section we use Monte Carlo simulations to verify the newly-found expressions for cumulants based on (25). This requires the specialisation of the above general expressions to the hard rod gas.
The hard rod gas is a one-dimensional classical system of rods of length a whose whose only interactions are elastic collisions. Upon colliding, the rods swap velocities. The hydrodynamic description of the gas was derived rigorously in [78]. In our notations, F(ε) = −e −ε , n(θ ) = e −ε(θ ) , f (θ ) = 1, and the interactions are defined by ϕ(θ , α) = −a. In order to verify (25), we specialise to the hard rod gas and compare the predictions of the first four cumulants of the energy flow (h i * (θ ) = θ 2 /2) with direct Monte Carlo simulations of the gas. Using the exact TBA description [26], we first evaluate the predicted cumulants in a NESS from the partitioning protocol with initial left and right states that are thermal and boosted with different temperatures and boost velocities. See appendix D for a derivation of thermal distributions in the hard rod gas; these are normal distributions, proportional to exp(β(v − v 0 ) 2 /2) where v 0 describes the boost velocity and β the temperature of the bath. We then simulate the gas by running the (deterministic) hard rod dynamics from a sampled initial condition, where the initial left and right halves of the line are sampled with the prescribed left and right thermal boosted states. We add up the energy of the rods that pass through the centre of the system up to time t. This is done for multiple samples, from which we extract the cumulants and then scale by time. At large times, these numerical results are expected to agree with the cumulants evaluated in the NESS itself. 6 Figure 2: Insets highlight the agreement between theoretical predictions and Monte Carlo simulation of the first four energy flow cumulants in the hard rod gas. Theoretical predictions from (25) are the red lines, Monte Carlo results are the blue dots with error bars. The initial velocities of the rods are drawn from normal distributions, with mean 8 and variance 15, and mean −3 and variance 10, for the left and right system halves, respectively. Other parameters are: rod length a = 0.56; 10 5 particles; 2 × 10 7 Monte Carlo samplings; initial system length 10 5 . Rod densities are fixed by the velocity variances in thermal distributions. The scaling parameter for the y-axis isv 3 /a wherev is the average rod speed. Error bars are found via bootstrap re-sampling using 3000 samples. Times plotted are chosen so as to reach the effective steady state before boundary effects arise; higher cumulants, which are affected by rarer events with faster moving rods, are sensitive to finite-size effects sooner.
The Monte Carlo error bars are obtained via the bootstrap sampling method which entails re-sampling with replacement from the obtained data set and calculating "alternative" values of the required cumulant [105]. The standard deviation of these values represents the associated uncertainty. Figure 2 shows cumulants of the steady state energy flow in the hard rod gas realised by Monte Carlo simulation, compared with results predicted from generalised hydrodynamics. It is clear that within error bars the prediction from (25) is successful -see appendix D for details on theoretical cumulant calculations in the hard rod gas, and appendix E for details on the Monte Carlo numerical simulation. Here, by boosting, the initial partitions are not just put into contact, but are thrust into each other. This is a highly non-trivial setup and the accurate prediction displays the power of the formalism employed here, providing strong evidence that (25) is correct. fact can be observed, for generic observables, from the expressions for correlation functions in inhomogeneous states found in [34]. We note that in particular, the discussion in [34, sect 5.2.1] was inaccurate in claiming that the factor V (θ ) would remain.

Quantum Lieb-Liniger gas
A different check on (25) is to confirm the expected non-equilibrium fluctuation relations (8). As mentioned at the end of section 2, general arguments suggest that the fluctuation relations should hold for the SCGF in the NESS from the partitioning protocol. We do not yet have an analytical proof of (8) from (25); this is nontrivial, as the fluctuation relations involve finite shifts of the generating parameter λ, while (25) is expressed in terms of the solution to a flow equation, which is local in λ. Nevertheless, one may verify the symmetry (8) by numerically solving the flow equation (24) and evaluating (25).
In order to provide verifications of our results beyond classical models, we choose to check the fluctuation relations for the energy current in the quantum Lieb-Liniger model. This model is important in the context of integrability as recent advances have rendered it accessible through cold atom experiments, see the book [77].
The Lieb-Liniger model describes a one-dimensional gas of Bose particles with δ-function interactions. Specialising Eq. (25) to this model, we obtain explicit predictions for all the large-scale cumulants for transport, including for the total number of particles transferred (h i * (θ ) = 1) and the total energy (h i * (θ ) = θ 2 /2). Again we analyse the energy SCGF in the partitioning protocol NESS (using its exact TBA description [21]) with initial states set by different purely thermal baths, at inverse temperatures β l and β r . We set F(ε) = − log(1+e −ε ), n(θ ) = 1/1+e ε(θ ) , and f = 1−n, while interactions are defined by ϕ(θ , α) = 4c/((θ −α) 2 +4c 2 ) where c is the coupling strength. The equation (24) is solved numerically using an iterative approach known as Picard's method [106]. The SCGF is plotted in fig. 3; it is convex as it should be [42], and grows sharply near the values −β r and β l . These are the values at which divergences in the SCGF occur in free bosonic models (and also in conformal field theory [57]), thus suggesting that at these values, the free bosonic physics of the Lieb-Liniger model domi-nates. The plot also indicates that the energy flow in the Lieb-Liniger model, with these initial conditions, satisfies the non-equilibrium fluctuation relations (8). Appendix F provides more extensive numerical verifications of the fluctuation relations by exploring a range of parameters in the Lieb-Liniger model and shows numerical evidence in the hard rod gas too.
The validity of the fluctuation relations in the Lieb-Liniger model and hard rod gas provides further support both for (25), and for the general consistency of the theory of non-equilibrium transport.

Conclusion
In this paper, we have obtained the exact SCGF, or full counting statistics, for transport of arbitrary conserved quantities in a wide family of integrable models, and in arbitrary GGEs, including non-equilibrium steady states. The results have been obtained by combining recent developments in integrable systems in the context of generalised hydrodynamics [21,22], in particular the flux Jacobian obtained in [32], with a new ballistic fluctuation formalism developed in [92]. They significantly generalise previous expressions and studies in free particle models [50][51][52][53][54][55] and in one-dimensional conformal field theory [57][58][59]. To our knowledge, these are the first exact results for transport SCGFs in interacting homogeneous integrable systems, and provide an entirely new application of the hydrodynamic theory of integrable systems. The SCGF allows one to extract, order by order, exact expressions for the scaled transport cumulants purely in terms of quantities from the thermodynamic Bethe ansatz. We have provided explicit expressions for the first few cumulants. The results can be immediately applied, for instance, to the paradigmatic classical hard rod gas, the quantum Lieb-Liniger model, as well as other classical and quantum chains and field theories such as the sinh-Gordon and sine-Gordon model and the Heisenberg chain, and to soliton gases [80][81][82][83][84]. Importantly, we have explicitly verified the validity of the formalism by comparing the exact formulae for cumulants with Monte Carlo simulations in the classical hard rod gas. We have also explained how to apply the formalism to the quantum Lieb-Liniger gas, and we have checked, by numerically evaluating the exact expression, that the SCGF satisfies the non-equilibrium fluctuation relations both in the classical hard rod and quantum Lieb-Liniger gases.
Many questions arise from the present results. First, a more in-depth analysis of the SCGF and its properties would be very interesting, including an analytic proof of the fluctuation relations. It would particularly useful if simplifications of the general formula (25) could be found, allowing for a better analysis of the SCGF at large or complex values of the generating parameter λ. For instance, the analytic structure of the SCGF in the complex λ-plane would provide information about the structure of transport degrees of freedom, see [107]. Applications to other integrable models would be very desirable. As our main results, even though accurate, are not derived in a mathematically rigorous fashion, it is paramount to have comparisons with tDMRG studies for quantum models. Furthermore, as explained in [92], the SCGF gives the exact exponential decay of dynamical two-point correlation functions of twist fields; the latter, in many cases, represent order parameters, and examples are the exponential fields in the sine-Gordon model. It would be useful to verify the predicted exponents, and further study their consequences. Finally, it would be interesting to explore the empirical counting statistics of the Lieb-Liniger gas in experiments on cold atomic gases, and compare them with our theoretical results. Tantalisingly, generalisations to inhomogeneous non-stationary situations might also be possible with current technology within GHD.

A Specialisation to the Lesovik-Levitov formula
In free-fermion models, there is a well-known formula for the SCGF for particle transfer through an impurity between two "leads", the Lesovik-Levitov formula [50]. The Lesovik-Levitov formula specialised to pure transmission (that is, without an impurity) should agree with our formula (25), specialised to free-fermionic particles, to the steady state arising from an initial imbalance in the partitioning protocol, and to the study of particle transfer. Here we verify this in a very simple example, corresponding to the choice of free massless, chargeless fermionic leads, which have linear dispersion relation. In this case, the Lesovik-Levitov formula takes the form [52] where n j (ω) is the Fermi occupation function for the initial left, j = l, and right, j = r, reservoirs; for instance, with temperatures T j and chemical potentials µ j ", we have, Here ω plays the role of an energy; it is not bounded from below because of the linear dispersion relation. In our formalism, we have two particle types, σ = ±1, corresponding to the right-movers and left-movers of the massless free-fermion theory. We may choose momentum p(θ , σ) = θ ; the energy function takes the form E(θ , σ) = σθ so that the velocity is v(θ , σ) = σ. The theory is free, hence this also equals the effective velocity, and the dressing operation is trivial. The non-equilibrium steady state in free-fermion models has been known exactly for some time [67,68], and, in our notations, has pseudoenergy given by This embodies the independent thermalisation of right-and left-movers with respect to the initial left and right states, respectively. Solving (24) we find and (25) becomes Changing variable to ω = σθ , followed by some simple algebraic manipulations, it can be seen this agrees with (32).
Calculating λ-derivatives of (25) requires the following identities, gleaned from understanding the integral-operator structure of the dressing operator: where s(θ ; λ) = sgn v eff (θ ; λ) , and X (θ ) and Y (θ ) stand for any two quantities within the GHD description. Going forward we use the λ-dependent state n(θ ; λ) which is defined by (37). The λdependent current is obtained from the expression At λ = 0 this correctly produces the steady-state current as given by the first expression in (17). In order to ensure the next calculations are more readable, the θ -dependence in the notation is suppressed with the understanding that all terms inside the θ integrals are θ dependent. Furthermore, the following simplified notation is introduced: The second cumulant c 2 is found by taking a λ-derivative of the λ-dependent current and setting λ = 0, where in the second line we used (37) and (38) while the third line required (39). At λ = 0 this correctly reproduces c 2 from the literature [32].
For higher-order derivatives special care of the terms ∂ λ s(λ) is necessary. Recall s(λ) is a sign function and the derivative of this produces a δ-function. The δ-function leads to terms evaluated at θ * (λ) where v eff (θ * (λ); λ) = 0. This can be problematic, as in the partitioning protocol considered in this work, n(θ * (λ)) is ill-defined. However, for c 3 the ambiguity resolves fairly straightforwardly. On taking the derivative of ∂ λ 〈j(λ)〉 there is a term that contains ∂ λ sgn v eff (θ ; λ) = δ(v eff (θ ; λ))∂ λ v eff (θ ; λ). The trick comes from recalling from the def- The δ-function sets v eff = 0 which ensures we do not need to evaluate n(θ * (λ)). The remaining terms all follow from use of (37), (38) and (39) which leads to wheref = −(d log f /dε + 2 f ) and s 2 (λ) = 1 was used throughout. The final expression (31) for c 3 is obtained by recalling again the identities (E ) dr = v eff (p ) dr , |v eff | = v eff sgn(v eff ), and ρ p = n(p ) dr /(2π) before finally setting λ = 0. Although the results are exact, one can see the increasing complexity of the required manipulations for higher cumulants. To obtain c 4 involves the same steps as above, first using (37) and (38) followed by acting on the term gained from ∂ λ (E ) dr with (39). However, a further complication arises when considering the term ∂ λ (s f H 2 ) dr (λ). We now explain the specific issue and how to overcome it but we do not repeat manipulations already covered in the calculations of c 2 and c 3 ..
In order to calculate ∂ λ (s f H 2 ) dr (λ), consider the integral representation of a dressed object. From (18), the dressing operator is h dr (θ ) = h(θ ) + dα 2π ϕ(α, θ )n(α)h dr (α). With this definition where we have displayed only the first three terms of the infinite sequence arising from the iterative equation defined by the dressing operator. Everything is fairly straightforward except that the derivatives of s(θ ; λ) do not resolve the issues of evaluating n(θ * (λ)) as in c 3 before. To get around this issue, consider splitting the integrals above such that dθ s(θ * (λ)) = − θ * (λ) −∞ dθ + ∞ θ * (λ) dθ . Then using the Leibniz integral rule, the boundary terms which come from ∂ λ dθ s(θ * (λ)) cancel each other out. This removes the ambiguity from (43), as is to be expected since the sign function entered our initial calculations as a shorthand. In fact, it is possible to do all calculations without the explicit use of this function, instead computing under split integrals from the start so that there is never a question of ambiguity. With this issue resolved we write The rest of the calculation, although tedious, follows the same principles as before. For comparative purposes we write c 4 in the more formal notation used in (31) for c 3 : wheref = −(d log( ff )/dε + 3 f ).

C Cumulants from a linear response principle
We show that the cumulants obtained by taking λ-derivatives of (25), can also be obtained by following a linear response principle, generalising the linear-response formulation of the second cumulant found in [32].
The linear response formulation for the cumulants, in a given state of the system, is obtained by considering a certain partitioning protocol with respect to that state. Specifically, the required partitioning protocol is that whose initial condition, on the left/right, is the system state perturbed by ±(µ/2)Q, where Q is the conserved charge of interest. One then looks at the NESS emerging from this partitioning protocol. Here we show that taking the µ-derivative of the occupation function representing this NESS, evaluated at µ = 0, results in the same expression as that obtained by taking the λ-derivative at λ = 0. By recursively applying this procedure, one can then obtain all λ derivatives.
Recall the expression for the TBA pseudoenergy (16): where w(θ ) is a source term defining the initial state -in (16) we used w(θ ) = i β i h i (θ )).
As mentioned, the basis of the linear-response formulation of the cumulants in a particular state with occupation function n(θ ), is to first evaluate the occupation function for the NESS emerging from the partitioning protocol with initial condition where both halves are set to the state under consideration, but with a "perturbation" by ±(µ/2) Q in the left and right GGEs, respectively. The NESS occupation function, solution to this partitioning protocol, is given in [21,22], and will be denoted [n] µ (θ ).
It takes the form [n] µ (θ ) = n l;µ (θ )Θ(v eff µ (θ )) + n r;µ (θ )Θ(−v eff µ (θ )) where n l,r;µ (θ ) are constructed from the modified source terms of the pseudoenergy corresponding to the initial state of the protocol, w l,r;µ (θ ) = w(θ ) ± (µ/2)h(θ ), and v eff µ (θ ) is evaluated in the state [n] µ (θ ). Consider the µ-derivative of [n] µ (θ ). We may recast the form of the solution [n] µ (θ ) in terms of the pseudoenergy [ε] µ (θ ), as they are related in a simple algebraic way. Clearly, The first factor was presented in the main text: ∂ ε n = −n f . By the linear-response construction and using the definition of the dressing operation, the second factor is ∂ µ [ε] µ (θ ) = ∂ µ ε l;µ (θ ) if v eff µ (θ ) > 0, and ∂ µ [ε] µ (θ ) = ∂ µ ε r;µ (θ ) if v eff µ (θ ) < 0, with a delta-function contribution at v eff µ (θ ) = 0. Using ∂ µ ε l,r;µ = ±h dr l,r;µ and the fact that h dr l,r;0 = h dr , the delta-function contribution vanishes at µ = 0. We are left with Comparing this equation to (37), which is a re-expression of (24), we observe that The equality does not hold in general when the derivatives are evaluated at µ = 0 and λ = 0. However, since the equality holds for every state, we can follow the same procedure starting with the λ-dependent state n(θ ; λ), and considering a µ-modification of it. We obtain In short, the method outlined here gives an alternative way of expressing the λ-flow: the first-order variation of the state in λ is equated with its first-order variation in another parameter, µ, obtained by first applying an inhomogeneous perturbation with opposite chemical potentials ±µQ/2 on the left and right halves -a bias -to the state n(·; λ), and then letting the state evolve for an infinite time towards the emerging steady state, getting [n(·; λ)] µ . Again, the equality holds only for first variations; there is in general no equality for second and higher derivatives (except for free-particle models), and no group property, [[n] µ ] µ = [n] µ+µ . Thus, this approach does not provide a finite-λ solution to the flow, but a re-writing of the flow equation.

D The hard rod gas and its thermal distribution
The hard rod (HR) gas provides a simple model in which to test our results. We here explain how to generate the inputs for the theoretical predictions of c 1 , c 2 , c 3 and c 4 plotted in fig. 2.
To obtain the theoretical values for the cumulants, the following are required: the conserved quantity h(θ ); the occupation function n(θ ) together with the related pseudoenergy ε(θ ) and particle density ρ p (θ ), the dressing operation, the effective velocity v eff (θ ), and the statistical factor f (θ ). Here θ is the velocity and we take unit mass.
As stated in the main text, in the HR gas the differential scattering amplitude is given by ϕ(θ , α) = −a where a is the rod length. The constant interaction term simplifies the dressing operation (see again the main text), giving This produces further simplifications of v eff (θ ) since v eff (θ ) = (E ) dr (θ )/(p ) dr (θ ). Further, in the HR gas f (θ ; λ) = 1 (independent of the state) and as this is a gas of classical particles with free energy function F(ε) = e −ε . The particle density is given by ρ p (θ ) = n(θ )(p ) dr ((θ ))/(2π) which, using p (θ ) = 1 and (51), is easily shown to yield Since the differential scattering phase is constant in the HR gas, the pseudoenergy can be expressed as ε(θ ) = w(θ ) + z, where the constant z satisfies The equation for z is solved using the Lambert-W function as z = W (ad).
For the particular situation of interest, we are concerned with energy currents so h(θ ) takes the simple form θ 2 /2. For the HR gas in the steady state arising from the partitioning protocol, a result of [26] provides the exact expression for n(θ ) in terms of the occupation functions n l (θ ) and n r (θ ) in the initial left and right baths of the protocol. Here, the initial state is fixed using two boosted thermal distributions. In order to apply the result of [26], we therefore only need to describe what form n(θ ) takes for thermal distributions in the HR gas; Galilean boosting is simply a shift of θ . To obtain a thermal distribution in the HR gas, one may naively assume that fixing the source term w(θ ) of the pseudoenergy (46) to be Gaussian is sufficient. However, we show that for truly thermal distributions, the starting rod density per unit length must also be fixed in a particular way.
This is how the initial thermal densities are constructed for the Monte Carlo simulation of the hard rod gas. Since we investigate boosted thermal distributions, we use such Gaussian distributions with non-zero means; the above details remain unaffected other than in the final equality θ → θ − µ.

E Monte Carlo details
We here describe in detail the Monte Carlo procedure used to obtain c 2 , c 3 and c 4 for the HR gas in the partitioning protocol used in fig. 2. In the partitioning protocol the system is split into two halves defined by different boosted thermal distributions for the left and right side of the partition (see appendix D above). This defines both the rod velocities, through sampling from a Gaussian distribution, and the rod densities, through (56). On the left side of the partition we used a Gaussian with a mean of 8 and standard deviation of 15, on the right a mean of −3 and standard deviation of 10. The initial length scale in the system is defined by the distance between the leftmost rod of the left partition and the rightmost rod of the right  partition. To ensure we study a system where interactions are important while also avoiding packing the rods too densely, we enforce the initial length scale to be half-populated by rods, taking into account rod lengths. It is easy to show that the initial length scale and the rod length are uniquely determined by the choice of rod number, left/right Gaussian parameters and the constraint the initial length scale is half-filled with rods. We used 10 5 rods in our simulation. We stress again that all the stochasticity is contained within the initial conditions as the initial rod velocities are randomly drawn from Gaussian distributions but, the time evolution is deterministic. For a given realisation of initial velocities, we count the total amount of energy that passes through the midpoint of the system during a long time interval t. To gain statistics on the energy flow, we allow multiple realisations of initial rod velocities and record the total energy flow for each. From the data collected the scaled cumulants can be determined.

F Numerical evidence for fluctuation relations
We provide further numerical evidence that the SCGF given in (25) satisfies fluctuation relations (FRs). Recall from (8), and the discussion below it, that in our setup FRs take the form Figure 6: Plot of the energy flow SCGF for the hard rod model using equation (25). For this plot the parameters used are β l = 1, β r = 5 and rod length = 0.1. Once again the dotted line is the expected FR symmetry point and the curve is reflected to indicate how symmetrical it is.
where β l and β r are the left and right inverse temperatures in the partitioning protocol. Thus the FRs are exposed by a symmetry in the plot of the SCGF about the point (β l − β r )/2. We stress that the figures in this section are not produced via Monte Carlo simulations but rather represent numerical solutions for (25) for various model scenarios. In fig. 4 we plot the SCGF for the Lieb-Liniger model with different temperatures but the same interaction strength c. fig. 5 displays the results of varying the interaction strength while maintaining the same temperatures. In order to be complete, fig. 6 shows HR-specific results where we use similar parameters as for the previous plots. In all cases the symmetry is prominent which provides strong numerical evidence that our exact SCGF formula does indeed satisfy FRs.