Scaling limits for the critical Fortuin-Kastelyn model on a random planar map II: local estimates and empty reduced word exponent

We continue our study of the inventory accumulation introduced by Sheffield (2011), which encodes a random planar map decorated by a collection of loops sampled from the critical Fortuin-Kasteleyn (FK) model. We prove various \emph{local estimates} for the inventory accumulation model, i.e., estimates for the precise number of symbols of a given type in a reduced word sampled from the model. Using our estimates, we obtain the scaling limit of the associated two-dimensional random walk conditioned on the event that it stays in the first quadrant for one unit of time and ends up at a particular position in the interior of the first quadrant. We also obtain the exponent for the probability that a word of length $2n$ sampled from the inventory accumulation model corresponds to an empty reduced word, which is equivalent to an asymptotic formula for the partition function of the critical FK planar map model. The estimates of this paper will be used in a subsequent paper to obtain the scaling limit of the lattice walk associated with a finite-volume FK planar map.

In [She11], Sheffield introduces a method to encode a (critical) FK planar map, i.e. a pair consisting of a random planar map M and a set S of edges on M sampled from the uniform distribution on such pairs weighted by the partition function of the critical Fortuitn-Kastelyn (FK) model, by certain words in an alphabet of five symbols. This word, in turn, gives rise to a two-dimensional lattice walk. This encoding is called the hamburger-cheeseburger bijection because it has a natural interpretation as an inventory accumulation process of a certain burger restaurant. The hamburger-cheeseburger bijection generalizes a bijection due to Mullin [Mul67] (see also [Ber07]) and is equivalent for a fixed choice of M to the bijection described in [Ber08,Section 4].
In addition to its interest as a tool for studying FK planar maps, the hamburger-cheeseburger bijection serves as the main source of discrete intuition behind the recent work [DMS14] which introduce the "peanosphere construction" to encode a conformal loop ensemble (CLE κ ) on a Liouville quantum gravity (LQG) surface with parameter γ = 4/ √ κ. The main result in [She11] is that the lattice walk constructed from the word associated with an infinite-volume FK-weighted random planar map converges in the scaling limit to a positively correlated two-sided Brownian motion, which is the same Brownian motion appeared in the Peano sphere theory of the corresponding LQG in [DMS14]. In this sense, [She11] can be seen as a scaling limit result from FK planar maps to the corresponding LQG in a certain topology.
There have been several recent works regarding the hamburger-cheeseburger approach to critical FK planar maps. In the article [GMS15] the present authors and C. Mao improved the topology in the convergence to LQG in [She11] by proving a statement which implies, among other things, the convergence of the quantum areas and quantum lengths associated with macroscopic FK loops. The authors of [BLR15] identified the tail exponents for the laws of several quantities associated with FK loops ( [GMS15] independently proves that the tail is actually regularly varying with the same for several of these quantities). The work [Che15] studies the whole plane version of the hamburger-cheeseburger bijection.
We note that in the special case of a uniform planar map (without loop decoration), there is also another approach based on the bijection of Schaeffer [Sch97], which has met with substantial success. We refer the reader to [Mie09,Le 14] and the references therein for more on this approach.
In this paper, we continue the theme of [GMS15] by studying the fine asymptotic properties of the word associated with critical FK planar maps. In particular, we will prove a variety of "local estimates" which give us up-to-constants asymptotics for the probability that a word sampled from the inventory accumulation model contains a particular number of symbols of each type. Such estimates play a crucial role in the study of small-scale events associated with the inventory accumulation model, e.g. the event that the associated lattice walk ends up at a particular point after a given amount of time. Local estimates are not proven in the works [She11, GMS15,BLR15], which focus mainly on the behavior of the word at large scales. The starting point of the proofs of our local estimates is the bivariate local limit theorem of Doney [Don91].
As an application of our estimates, in Theorem 1.8 we will prove that if we condition on the lattice walk in the hamburger-cheeseburger model to stay in the first quadrant for a certain amount of time and end up at a fix interior point, then the walk converges in the scaling limit to a correlated Brownian bridge conditioned on staying in the first quadrant. As another application, in Theorem 1.10 we obtain the exact exponent of the probability that a word of length 2n reduces to the empty word. The estimates established in this paper will also be used in the forthcoming work [GS15], in which we will prove analogues of the scaling limit results of [She11,GMS15] for the finite-volume version of the model in [She11] (which is encoded by a word of length 2n conditioned to reduce to the empty word); and in [GM15], in which the first author and J. Miller will prove convergence of the full topological structure of FK planar maps to that of a conformal loop ensemble on an independent Liouville quantum gravity surface.
project. The first author was supported by the U.S. Department of Defense via an NDSEG fellowship. The second author was partially supported by NSF grant DMS-1209044.
1.1. Notation. In this section we will introduce some notation which will remain fixed throughout the paper. This notation is in agreement with that used in [GMS15].
Definition 1.1. Let X be a random variable taking values in a finite space Ω. A realization of X is an element x ∈ Ω such that P(X = x) > 0. Notation 1.3. If a and b are two quantities, we write a b (resp. a b) if there is a constant C (independent of the parameters of interest) such that a ≤ Cb (resp. a ≥ Cb). We write a b if a b and a b.
Notation 1.4. If a and b are two quantities which depend on a parameter x, we write a = o x (b) (resp. a = O x (b)) if a/b → 0 (resp. a/b remains bounded) as x → 0 (or as x → ∞, depending on context). We write a = o ∞ Unless otherwise stated, all implicit constants in , , and and O x (·) and o x (·) errors involved in the proof of a result are required to satisfy the same dependencies as described in the statement of said result.
Let Θ := { H , C , H , C , F }. We view elements of Θ as representing a hamburger, a cheeseburger, and hamburger order, a cheeseburger order, and a flexible order, respectively. The set Θ generates semigroup, which consists of the set of all finite words in elements of Θ, modulo the relations Given a word x consisting of elements of Θ, we denote by R(x) the word reduced modulo the above relations, with all burgers to the right of all orders. We also write |x| for the number of symbols in x.
We definite a probability measure on Θ by Let X = . . . X −1 X 0 X 1 . . . be an infinite word with each symbol sampled independently according to the probabilities (4). For a ≤ b ∈ R, let (5) X(a, b) := R X a . . . X b .
We adopt the convention that X(a, b) = ∅ if b < a. By [She11, Proposition 2.2], it is a.s. the case that the "infinite reduced word" X(−∞, ∞) is empty, i.e. each symbol X i in the word X has a unique match which cancels it out in the reduced word.
Notation 1.5. For i ∈ Z we write φ(i) for the index of the match of X i . Notation 1.6. For θ ∈ Θ and a word x consisting of elements of Θ, we write N θ (x) for the number of θ-symbols in x. We also let The reason for the notation d and d * is that these functions give the distances in the tree and dual tree which encode the collection of loops in the bijection of [She11, Section 4.1].
For i ∈ Z, we define Y i = X i if X i ∈ { H , C , H , C }; Y i = H if X i = F and X φ(i) = H ; and Y i = C if X i = F and X φ(i) = C . For a ≤ b ∈ R, define Y (a, b) as in (5) with Y in place of X.
We note that the condition that X(1, 2n) = ∅ is equivalent to the condition that Z n ([0, 2]) ⊂ [0, ∞) 2 and Z n (2) = 0. Let Z = (U, V ) be a two-sided two-dimensional Brownian motion with Z(0) = 0 and variances and covariances at each time t ∈ R given by It is shown in [She11, Theorem 2.5] that as n → ∞, the random paths Z n defined in (7) converge in law in the topology of uniform convergence on compacts to the random path Z of (8).
There are several stopping times for the word X, read backward, which we will use throughout this paper. Namely, let be, respectively, the mth time a hamburger is added to the stack when we read X backward and the number of cheeseburgers minus the number of cheeseburger orders in X(−J H m , −1). Define J C m and L C m similarly with the roles of hamburgers and cheeseburgers interchanged.
where here p and κ are related as in (1). The parameters µ and µ appear as exponents for several probabilities related to the inventory accumulation model studied in this paper. See [GMS15,BLR15] as well as the later results of this paper.
1.2. Statements of main results. Here we will state the main results of this article. The following event will play a key role throughout the paper.
Definition 1.7. For n, h, c ∈ N, we denote by E h,c n the event that X(1, n) contains no orders (i.e. I > n), h hamburgers, and c cheeseburgers.
In terms of the path Z n of (7), E h,c n is the event that Z n stays in the first quadrant for one unit of time and satisfies Z n (1) = (n −1/2 h, n −1/2 c). Our first main result is the following scaling limit result for the path Z n of (7) conditioned on the event E h,c n .
Theorem 1.8. Fix C > 1. For each > 0, there exists n * ∈ N such that the following is true.
For each n ≥ n * and each (h, c) ∈ C −1 n 1/2 , Cn 1/2 2 Z , the Prokhorov distance (with respect to the uniform metric) between the conditional law of Z n given the event E h,c n of Definition 1.7 and the law of a correlated Brownian motion Z as in (8) conditioned to stay in the first quadrant for one unit of time and satisfy Z(1) = (n −1/2 h, n −1/2 c) is at most . See Section 1.3.1 for a precise definition of a Brownian motion under the conditioning of Theorem 1.8.
We note that Theorem 1.8 implies in particular that for any sequence of pairs (h n , c n ) ∈ N 2 such that n −1/2 h n → u > 0 and n −1/2 c n → v > 0, the conditional law of Z n given E hn,cn n converges as n → ∞ to a correlated Brownian motion Z as in (8) conditioned to stay in the first quadrant for one unit of time and satisfy Z(1) = (u, v). Theorem 1.8 extends the scaling limit results [She11, Theorem 2.5] (for the unconditioned law of Z n ) and [GMS15, Theorem A.1] (for the path Z n conditioned to stay in the first quadrant, but without its location at time 1 specified).
If we could allow (h, c) = (0, 0) in Theorem 1.8, we would obtain convergence of the path Z n in the finite-volume version of Sheffield's bijection, which corresponds to a random planar map on the sphere. However, treating this case will take quite a bit of additional work, both because of the additional conditioning near the tip of the path (it has to stay in the first quadrant despite being very close to the origin) and because difficulties resulting from the presence of flexible orders. The (h, c) = (0, 0) case will be treated in the sequel [GS15] to this paper. Theorem 1.8 is in some sense an intermediate step toward a proof of convergence of the path Z n conditioned on empty reduced word, but we will actually use only the estimates involved in the proof of Theorem 1.8 in [GS15], not the statement of Theorem 1.8 itself.
Theorem 1.8 is also noteworthy in that it gives a scaling limit statement for a non-Markovian random walk conditioned on a very low probability event toward a certain conditioned correlated Brownian motion. This result fits into a large body of literature concerning scaling limits of conditioned random walks. See [Lig68, Bol76, Igl74, Don85, CC13, Soh10, Shi91, Gar11, DW11, GMS15] and the references therein. Remark 1.9. As a consequence of [GMS15, Theorem 1.9] and Theorem 1.8, one can also obtain an analogue of the cone time convergence statement [GMS15, Theorem 1.9] in the setting of Theorem 1.8. A very similar argument will be given in [GS15] to prove the analogous statement for random planar maps on the sphere, so we do not give the details here.
Our second main result gives the exponent for the probability of the event that a word of length 2n sampled according to the probabilities (4) reduces to the empty word.
Theorem 1.10 confirms a prediction of Sheffield [She11, Section 4.2] that P (X(1, 2n) = ∅) has polynomial decay, and in fact yields the exact tail exponent. We note that a weaker lower bound, namely that P (X(1, 2n) = ∅) n −3 , is obtained in [Che15], but no upper bound is proven in that paper (although a trivial, but far from optimal, polynomial upper bound of n −3/2+on(1) follows from the fact that the total number of burgers in X(1, i) minus the total number of orders in X(1, i) evolves as a simple random walk).
In the course of proving Theorems 1.8 and 1.10, we will also prove several "local" estimates for quantities associated with the inventory accumulation model, i.e. estimates for the probability that a certain random word contains a specified number of symbols of a given type. Local estimates like the ones in this paper are necessary for studying finer properties of the model, like questions about the event of Definition 1.7 or the event {X(1, 2n) = ∅}. This paper provides a toolbox of local estimates which are applicable whenever one is interested in small scale properties of the word X. Such estimates will be used, for example, in the sequel [GS15] to this work to obtain scaling limit results for the path Z n of (7) when we condition on {X(1, 2n) = ∅}.

Preliminaries.
1.3.1. Brownian motion conditioned to stay in the first quadrant. The statement of Theorem 1.8 refers to a correlated Brownian motion as in (8) conditioned to stay in the first quadrant for one unit of time and satisfy Z(1) = (u, v) for some fixed (u, v) ∈ (0, ∞) 2 . In this subsection we will describe how to make sense of this object. We first recall how to make sense of a correlated Brownian motion Z conditioned to stay in the first quadrant (see [GMS15,Section 2.1] and [Shi85] for more detail).
In [Shi85], Shimura constructs an uncorrelated two-dimensional Brownian motion conditioned to stay in the cone {z ∈ C : 0 ≤ arg z ≤ θ} for one unit of time. By choosing θ = θ(p) appropriately and applying a linear transformation which takes this cone to the first quadrant, we obtain a path Z which we interpret as the correlated two-dimensional Brownian motion Z in (8) conditioned to stay in the first quadrant for one unit of time. We note that the law of Z is uniquely characterized by the conditions that Z(t) a.s. lies in the interior of the first quadrant at each fixed time t ∈ (0, 1); and for each t ∈ (0, 1), the conditional law of Z| [t,1] given Z| [0,t] is that of a Brownian motion with variances and covariances as in (8) started from Z(t) and conditioned on the positive probability event that it stays in the first quadrant for 1 − t units of time (see [GMS15, Lemma 2.1]). Given (u, v) ∈ (0, ∞) 2 , the law of a Brownian Z conditioned to stay in the first quadrant for one unit of time and satisfy Z(1) = (u, v) is the regular conditional law of the path Z described above given { Z(1) = (u, v)}. This law can be sampled from as follows. First fix t ∈ (0, 1) and sample Z| [0,t] from the law of a Brownian motion with variances and covariances as in (8) conditioned to stay in the first quadrant for t units of time weighted by f 1−t denotes the density with respect to Lebesgue measure of the law of a Brownian motion as in (8) started from z conditioned to stay in the first quadrant for 1 − t units of time. Then, conditioned on Z| [0,t] , sample a Brownian bridge from Z(t) to (u, v) in time 1 − t conditioned to stay in the first quadrant, and concatenate this Brownian bridge with our given realization of Z| [0,t] .
By Brownian scaling, one obtains the conditional law of a Brownian motion as in (8) conditioned to stay in the first quadrant for a general t > 0 units of time and satisfy Z(t) = (u, v) ∈ (0, ∞) 2 .
The following is the analogue of [GMS15, Lemma 2.1] when we further condition on the terminal point of the path. The proof can be found in [MS15].
Lemma 1.11. Fix (u, v) ∈ (0, ∞) 2 . Let Z have the law of a correlated Brownian motion as in (8) conditioned to stay in the first quadrant for one unit of time and end up at (u, v). Then Z satisfies the following two conditions.
(2) For each t ∈ (0, 1), the regular conditional law of Z| [t,1] given Z| [0,t] is that of a Brownian bridge from Z(t) to (u, v) in time 1 − t with variances and covariances as in (8) conditioned on the (a.s. positive probability) event that it stays in the first quadrant.
The function f is called slowly varying if f is regularly varying of exponent 0. Every function f which is regularly varying of exponent α can be represented in the form f (t) = ψ(t)t −α , where ψ is slowly varying. For each slowly varying function ψ, there exists t 0 > 0 and bounded functions a, b : [0, ∞) → R with lim t→∞ b(t) = 0 such that for t ≥ t 0 , We refer the reader to [BGT87] for more on regularly varying functions.
The following lemmas are proven in [GMS15, Section A.2]. We recall the definition of the exponent µ from (11) and the definition of I from (9).
Lemma 1.12. The law of I is regularly varying with exponent µ, i.e. there exists a slowly varying function ψ 0 : [0, ∞) → (0, ∞) such that Lemma 1.13. Let P be the smallest j ∈ N for which X(−j, −1) contains no orders. Then the law of P is regularly varying with exponent 1 − µ, i.e. there exists a slowly varying function ψ 1 : [0, ∞) → (0, ∞) such that We will treat the functions ψ 0 and ψ 1 as fixed throughout this paper.
1.4. Outline. The remainder of this article is structured as follows. In Section 2, we will use the bivariate local limit theorem of [Don91] to prove various "local" estimates for the pairs (J H m , L H m ) of (10). The times J H m are especially useful because each X(−J H m , −1) contains no flexible orders; and because the law of the pair (J H 1 , L H 1 ) is in the normal domain of attraction for a bivariate stable law (see Lemma 2.1 below).
In Section 3, we will use the results of Sections 2 to obtain local estimates for the probability that the word X 1 . . . X n contains no orders and a particular number of burgers of each type. Some of the more technical arguments needed for the proofs in this section are relegated to Appendix A. From these estimates we will deduce Theorem 1.8.
In Section 4, we will use the estimates of Sections 2 and 3 to obtain estimates for the probability that a word has few orders and approximately a given number of burgers of each type. These estimates will be used in the proof of the upper bound in Theorem 1.10 as well as in [GS15].
In Section 5, we will complete the proof of Theorem 1.10. The proof of the lower bound follows from a relatively straightforward argument which is similar to those given in [GMS15, Section 2] (in fact, a version of this argument appeared in a previous version of [GMS15]). The proof of the upper bound is more complicated, and requires the estimates of Section 4 as well as some additional estimates, including a modification of the estimate [GMS15, Lemma 2.8] for the number of flexible orders in a reduced word.

Local estimates for times when hamburgers are added
In this section, we will consider a "local limit" type result (i.e. a uniform convergence statement for densities) for the pairs (J H m , L H m ) introduced in (10). This result will turn out to be a straightforward consequence of the bivariate local limit theorem for stable laws proven in [Don91]. We will then prove some refinements on this result in Section 2.2. Most of the estimates of this section will be used in the proofs of Theorems 1.10 and 1.8. However, this section also has the following broader purpose. As we will see in Sections 3 and 4 below, local estimates for the pairs (J H m , L H m ) are the basic tools for the proofs of many other local estimates and scaling limit results for the inventory accumulation model considered in this paper; see also [GS15,GM15] for more applications of these estimates. This section can be read as a general collection of estimates for the pairs (J H m , L H m ) which can be used to establish whatever additional local estimates one might need for Sheffield's inventory accumulation model.
Proof. Suppose we have (using [She11, Theorem 2.5] and the Skorokhod theorem) coupled (Z n ) with Z in such a way that Z n → Z uniformly on compacts a.s. Let τ m := m −2 J H m . We observe that τ m is the smallest t > 0 for which U m 2 (−t) = 1. Since Z a.s. crosses the line {(x, y) ∈ R 2 : x = 1} immediately after hitting this line when run in the reverse direction, it follows that a.s. τ m → τ . By uniform convergence, a.s. V (−τ m ) → V (−τ ). By symmetry, we have the analogous statements for τ * and U (−τ * ). Thus (12) holds.
The time τ has the law of a stable random variable with index 1/2 and skewness parameter 1, and (12) implies that J H m is in the normal domain of attraction for this law. By the elementary theory of stable processes, we infer that (13) holds.
The process Z is a linear function of a standard two-dimensional Brownian motion. Therefore the law of V (−τ ) are given by an affine transformation of a Cauchy distribution. Since V m 2 (−τ m ) is equal to m −1 times the sum of the m iid random variables d(X(−J H k , −J H k−1 −1)) for k ∈ [1, m] Z , we conclude as above that (2.1) holds.
From Lemma 2.1, we obtain the following statement, which will play a key role in the remainder of this paper. The local limit result (14) now follows from Lemma 2.1 and the local limit theorem for bivariate stable laws [Don91, Theorem 1].
When we apply the estimate of Proposition 2.2, it will be convenient to have a tail estimate for the limiting density g.
Lemma 2.3. Let g be as in Proposition 2.2. Then we have for constants a 0 , a 1 , a 2 , a 3 > 0 depending only on p. In particular, g is bounded.
Proof. The function g is the joint density of (τ, V (τ )), where τ is the first time the Brownian motion U in (8) hits −1 and V is the other Brownian motion in (8). Thus marginal density of τ is given by t for constants C 1 > 0 and a 1 > 0 depending only on p. We can write V = V + a 3 U , where a 3 is a constant depending on p and V is a constant times a standard linear Brownian motion independent from U . Therefore, the conditional density of V (τ ) given τ is given by for constants C 2 > 0 and a 2 > 0 depending only on p. Combining these formulae yields the lemma.
We want to prove an analogue of Lemma 2.1 for (roughly speaking) times at which hamburger orders are added when we run forward. For this we need the following basic fact, whose proof is left to the reader.
Lemma 2.4. Let (ξ j ) be a sequence of iid non-negative random variables. For m ∈ N, let S m := m j=1 ξ j . Let (N n ) be an increasing sequence of positive integer-valued random variables such that N n /n a.s. converges to a constant q > 0. For n ∈ N, let S n := S Nn . Suppose there is a random variable X and an α > 0 such that n −α S n → X in law. Then m −α S m → q −α X in law.
Lemma 2.5. For m ∈ N, let I H m be the mth smallest i ∈ N for which X(1, i) contains no hamburgers.
Also let τ be the smallest t > 0 for which U (t) = −1. Then Furthermore, there is a constant a 0 > 0 such that Let τ m := m −2 I H m . We claim that τ m → τ in law. Suppose we have (using [She11, Theorem 2.5] and the Skorokhod theorem) coupled (Z m 2 ) with a correlated Brownian motion Z as in (8) in such a way that Z m 2 → Z uniformly on compacts a.s. Observe that For δ > 0, let τ δ be the first time t > 0 such that U (t) = −1 + δ. Suppose given > 0. We can find δ > 0 such that with probability at least 1 − , we have τ − τ δ ≤ . By [GMS15, Lemma 2.8], we can find m * = m * ( ) ∈ N such that for m ≥ m * , it holds with probability at least 1 − that m −1 N F X(1, I H m ) ≤ δ. By (18), for m ≥ m * , it holds with probability at least 1 − 2 that |τ m − τ | ≤ . Since is arbitrary, this implies τ m → τ in probability, hence also in law.
By Lemma 2.4, we have (16). We now obtain (17) in exactly the same manner as in Lemma 2.1.
Corollary 2.6. There is a constant a 0 > 0 such that for n ∈ N, Proof. The event that n = J H m for some m ∈ N is the same as the event that X(−n + 1, −1) contains no hamburger orders or flexible orders and X −n = H . By translation invariance this probability is the same as the probability that X(1, i) contains a hamburger for each i ∈ [1, n] Z , i.e. the probability that I H 1 > n, with I H 1 as in Lemma 2.5. The statement of the corollary now follows Lemma 2.5.

2.2.
Regularity and large deviation estimates. In this section we will prove two (closely related) types of results, which sharpen the estimates which come from Proposition 2.2: estimates for the probability that (J H m , L H m ) = (k, l) when k and l are far from m 2 and m, respectively; and regularity estimates for the conditional law of X 1 . . .
with a > 0 a universal constant and the implicit constants depending only on p.
Proof. Let (Y m ) be an iid sequence of positive stable random variables of index 1/2. By Lemma 2.1, we can find a constant A > 0, depending only on p, and a coupling of two copies (Y 1 e −am 2 /R for an appropriate constant a > 0 as in the statement of the lemma. This yields (19) and (20).
To prove (21), let ( Y m ) be an iid sequence of positive stable random variables of index 1. By Lemma 2.1, we can find a constant A > 0 (depending only on p) and a coupling of two copies ( Y 1 m ) and with a 0 > 0 a universal constant and the implicit constant depending only on p. Furthermore, there is a universal constant a 1 > 0 such that for R > 0 we have with the implicit constant depending only on p.
Proof. It is clear from Proposition 2.2 and Lemma 2.3 that for any m ∈ N and any (k, l) ∈ N × Z, we have (24) Then we have By (24) and independence, for each i ∈ {1, 2}, the conditional probability that (J H m , L H m ) = (k, l) given any realization of (J H,i m , L H,i m ) is at most a constant (depending only on p) times m −3 . Hence This yields (22). For (23), we first use (26) to get On the other hand, by the third inequality in (22) applied with either m or m − m in place of m, we have Combining these estimates yields (23) with a 1 = a 1 ∧ (a 0 /4).
To complement Lemma 2.8, we also have a lower bound for the probability that (J H m , L H m ) = (k, l) and the word X(−J H m , −1) has certain unusual behavior.
Lemma 2.9. Fix C > 1 and > 0. For sufficiently large m ∈ N (how large depends only on C and ) with the implicit constant depending only on and C.
Proof. Fix δ > 0 to be chosen later, depending only on and C, and let m δ : By [She11, Theorem 2.5] (c.f. the proof Lemma 2.1) we and find m * ∈ N, depending only on C, , and with the implicit constant depending only on C, , and δ. Note that on E k,l m (δ) we have N C (X(−J m δ , −1)) ≥ 1 2 C −1 . By Lemma 2.10 and independence, if δ is chosen sufficiently small, depending only on C, then we have with the implicit constant depending only on C, , and δ. By combining this with (27), we obtain the statement of the lemma.
From Lemma 2.8, we obtain a regularity estimate when we condition on a particular realization of (J H m , L H m ).
Lemma 2.10. For each C > 1 and each q ∈ (0, 1), there exists A > 0 and m * = m * ∈ N, depending only on C and q, such that for m ≥ m * and (k, Proof. By (23) of Lemma 2.8, we can find a > 0, depending only on C, such that for each A > 0, each with the implicit constant depending only on C. By Proposition 2.2, we can find m * ∈ N, depending only on C, such that for m ≥ m * and (k, with the implicit constant depending only on C. Combining these observations yields the statement of the lemma. Finally, we have a regularity estimate for X −n . . . X −1 given only that n = J H m for some (unspecified) m ∈ N.
Lemma 2.11. For n ∈ N, let E n be the event that n = J H m for some m ∈ N. For each q ∈ (0, 1), is a constant A > 0 depending only on q such that for each n ∈ N, Proof. By the same argument used to prove (23) of Lemma 2.8, but with only the value of J H m (not the value of L H m ) specified, for each m ∈ N and A > 0 we have with a 0 > 0 a universal constants and the implicit constant depending only on p. Hence for each C > 0, For any given α > 0, we can choose C sufficiently large and then A sufficiently large relative to C such that this integral is at most αn −1/2 . By Lemma 2.6, with the implicit constant depending only on p. We conclude by choosing α sufficiently small relative to q and dividing.

Local estimates with no orders
3.1. Setup. In this subsection, we will use the results of Sections 2 to establish sharp estimates for the probability that the word X(1, n) contains no orders and a specified number of burgers of each type, and for the conditional law of the word X 1 . . . X n given that this is the case. These estimates will eventually lead to a proof of Theorem 1.8. Before we commence with the proofs, we describe the notation we will use throughout this section and make some elementary observations about the objects involved.
Recall the definition of the event E h,c n from Definition 1.7, the time I from (9), the exponent µ from (11), and the slowly varying function ψ 0 from Lemma 1.12. We also introduce the following additional notation.
with N H , N C , and R as in Section 1.1.
N C (X(1, i)) = m) and X i+1 is a hamburger (resp. cheeseburger) which is not consumed before time See Figure 1 for an illustration.
For r ∈ N, let J H n,r be the smallest j ∈ N for which X(n − j, n) contains r hamburgers and set L H n,r := d * X(n − J H n,r , n) . That is, (J H n,r , L H n,r ) are defined in the same manner as the pairs (10) but with the word read backward from n rather than from −1.
The main idea of the proofs of the above propositions is to condition on a realization of the word X up to time K H n,m for some m ∈ N; then read the word backward from time n and apply the results of Section 2 to estimate the pairs (J H n,r , L H n,r ). The next two lemmas are the basic tools needed to accomplish this.
Lemma 3.2. Let D be defined as in (6). For (h, c) ∈ N 2 and m ∈ [1, h − 1] Z , the event E h,c n is the same as the event that Proof. It is clear that K H n,m > 0 on E h,c n . On the event {K H n,m > 0}, there is some j ∈ N for which n − J H n,j = K H n,m + 1. Since X(n − J H n,j , n) contains no hamburger orders or flexible orders, it follows that for this choice of j we have The statement of the lemma follows. . . X n given any realization x of X 1 . . . X K H n,m for which 0 < K H n,m < I is the same as its conditional law given the event Proof. The first statement is immediate from translation invariance. To verify this second statement, we observe that for each k ≤ n, the event {K H n,m = k} ∩ {K H n,m < I} is the same as the event that X(1, k) contains no orders and exactly m hamburgers; and that X k+1 is a hamburger which does not have a match in [k + 2, n] Z , i.e. k + 1 = n − J H n,r for some r ∈ N. Since X 1 . . . X k is independent from X k+1 . . . X n , it follows that the conditional law of X k+1 . . . X n given {X 1 . . . X K H n,m = x} is the same as its conditional law given that n − |x| − 1 = J H n,r for some r ∈ N. Fix (h, c) ∈ N 2 , n ∈ N, and m ∈ N with m < h. Let x be any realization of X 1 . . . X K H n,m for which 0 < K H n,m < I, so that c(x) is the corresponding realization of Q H n,m . Lemmas 3.2 and 3.3 law together yield the following formulae, which we will use frequently in the remainder of this subsection as well as in Appendix A.
with R n (x) as in (29); and 3.2. Upper and lower bounds. In this subsection we will prove estimates for the probability of the event E h,c n of Definition 1.7. We start with the lower bound, which is easier. Proposition 3.4 (Lower bound). Let ψ 0 be the slowly varying function from Lemma 1.12. For each with the implicit constant depending only on p.
Proof. Fix C > 1. For h ∈ N and δ > 0, let m δ h := (1 − δ)h and r δ h := δh . By Lemma 2.10, we can find A > 0, depending only on p, such that for each h ∈ N and each (k, l) ∈ [ 1 with the implicit constant depending only on p.
To prove our upper bound for the probability of E h,c n , we first need the following lemma.
Lemma 3.5. Let ψ 0 be the slowly varying function from Lemma 1.12. For each m ∈ N, we have with the implicit constant depending only on p.
Proof. For m ∈ N, let I m be the smallest i ∈ N for which N H Let x be any realization of X 1 . . . X Im for which I m < I. Then for k ∈ [1, k m ] Z , .
Since R(x) contains no orders and at least m/2 burgers of each type, and since 2 k−1 ≤ m 2 , it follows for universal constants a 0 , a 1 > 0. By averaging over all realizations of X 1 . . . X Im for which I m < I, we obtain By Lemma 1.12, Therefore, (35) is at most a constant (depending only on p) times Proposition 3.6 (Upper bound). Let ψ 0 be the slowly varying function from Lemma 1.12. For each with the implicit constant depending only on p.
define K H n,m h and K C n,mc as in Section 3.1. On the event E h,c n , both K H n,m h and K C n,mc are < n.
By symmetry, it suffices to show that and (38) To this end, fix a realization x of X 1 . . . X K H n,m h for which 0 < K H n,m h < I. By (30), we obtain with J H n,r h and L H n,r h are as in Section 3.1 and R n (x) as in (29). By Lemma 2.6, (40) P (R n (x)) (n − |x|) −1/2 with the implicit constant depending only on p. By Lemma 2.8, with the implicit constant depending only on p. Hence (39) yields By averaging over all choices of the realization x for which 0 < K H n,h < I and c(x) ≥ m c , we obtain (37).
For (38), we observe that if 0 < K H n,h < I and N C X(1, K H n,h ) ≥ m c , then Hence (38) follows from Lemma 3.5.
3.3. Regularity estimates. In this subsection we will consider some regularity results for the conditional law of X 1 . . . X n given E h,c n . Our first proposition tells us, roughly speaking, that the pair (K H n,m , Q H n,m ) is unlikely to be too far from (n, c) if m is close to h and we condition on E h,c n .
Our next result tells us that if we condition on E h,c n and a sufficiently nice realization of X 1 . . . X K H n,m for m slightly smaller than h, then it is unlikely that |X(K H n,m + 1, i)| is very large for any i ∈ [K H n,m + 1, n] Z . 3.4. Continuity estimates. In this subsection we will prove some lemmas to the effect that the conditional probability of E h,c n given a realization of X 1 . . . X K H n,m for m slightly smaller than h does not depend too strongly on the realization. Throughout this subsection we define the sets U δ n (A, h, c) as in (41) and let m δ h := (1 − δ)h be as in Proposition 3.7.
By Lemmas 2.10 and 2.11, we can find δ * > 0, depending only on α, A, and C, such that for each δ ∈ (0, δ * ] there exists n 0 * = n 0 * (δ, C, A, α) ∈ N such that for n ≥ n 0 * , we have By Lemma 2.6, there is a constant a 0 > 0, depending only on p, such that for each δ ∈ (0, δ * ] there exists n 1 * = n 1 * (δ, C, A, α) ∈ N such that for n ≥ n 1 * and each realization x as above, Hence if δ ∈ (0, δ * ] and n ≥ n 1 * , By Proposition 2.2 (in particular, by continuity of the function g of that proposition), we can find ζ > 0, depending only on δ, C, and q, and n 2 * = n 2 * (δ, C, α) ≥ n 1 * such that for any n ≥ n 2 * , any two pairs By combining this with (45) and choosing α sufficiently small, depending only on q, we obtain the statement of the proposition.
Let n ≥ n * , (h, c) ∈ C −1 n 1/2 , Cn 1/2 Z , and let x be a realization of X −K n,m δ h . . . X −1 for which P k,l n,m (ζ) occurs. By applying (44) with (h, c) = (h , c ) and averaging over all choices of realization x for which P k,l n,m (ζ) occurs, we obtain By Bayes' rule, .
By combining this with (47) we conclude.
3.5. Proof of Theorem 1.8. In this subsection we will prove Theorem 1.8.
. Also set u δ := (1 − δ)u. The Prokhorov distance between any two of the following three laws is at most .
(1) The regular conditional law of Proof. Since τ u is the last t ∈ [0, 1] for which U crosses u, we infer from the Markov property of Z that for each s ∈ (0, t), the regular conditional law of Z| [0,s] given Z| [0,s] and {(τ u δ , V (τ u δ )) = (t, v )} is that of a correlated Brownian bridge from Z(s) to (u δ , v ) in time t − s conditioned to stay in the first quadrant. By Lemma 1.11, the regular conditional law of Z| [0,t] given {(τ u δ , V (τ u δ )) = (t, v )} is P u δ ,v t . By a similar argument, the regular conditional law of Z u,v | [0,τu δ ] given {(τ u δ , V u,v (τ u δ )) = (t, v )} is also given by P u δ ,v t . Since the law P u,v t depends continuously on its parameters (see Section 1.3.1), it follows that when δ is small and (t, v ) ∈ [1 − δ 2 , 1] × [v − δ, v + δ], the Prokhorov distance between the law of Z u,v | [0,t] and the law P u δ ,v t is at most .
Since this holds for each choice of (k, l) ∈ U δ n (A, h, c) and by our choice of A, it follows that the Prokohorov distance between the conditional law of Z n | [0,1−A 2 δ 2 ] given E h,c n and the conditional law of Z h/n 1/2 ,c/n 1/2 | [0,t−A 2 δ 2 ] is at most 4 . By (48), our choice of δ 1 * , and (50), it follows that the Prokhorov distance between the conditional law of Z n | [0,1] given E h,c n and the conditional law of Z h/n 1/2 ,c/n 1/2 | [0,1] is at most 8 . Since is arbitrary we conclude.

Local estimates with few orders
In the previous section, we proved various estimates associated with the event that a word contains no orders and a particular number of burgers of each type. In this subsection we will use the results of the previous subsections to prove analogous estimates for the event that a word contains a small number of orders and approximately a particular number of burgers of each type. The estimates of this section are needed for the proof of the upper bound in Theorem 1.10, and will also be used in [GS15].
We will start in Section 4.1 by proving a regular variation type estimate for the probability that there is a time j in a given discrete interval with the property that X(−j, −1) contains no orders. In Section 4.2 we will state and prove our local estimates. 4.1. Probability of a time with no orders in a small interval. In this section we will prove a sharp estimate for the probability that there is a time slightly smaller than n for which X(−j, −1) contains no orders. We recall the definitions of regular varying and slowly varying from Section 1.3.2.
To prove Lemma 4.3 we need some basic facts about regularly varying functions. We leave the proof of the first fact to the reader.  k, n] Z . Assume that the functions t → P(Y 1 ≥ t) and t → P ( t = S m for some m ∈ N) are regularly varying with exponents α and 1 − α, respectively, so that in particular P (n = S m for some m ∈ N) = ψ(n)n −(1−α) for some slowly varying function ψ. There is a slowly varying function ψ, depending only on the law of Y 1 , such that Proof. For n ∈ N and k ∈ [1, n] Z , let M k n be the largest m ∈ N for which S m ∈ [n − k, n] Z if such a time exists and M k n := n + 1 otherwise. Then we have For i ∈ [n − k, n] Z , the event {S M k n = i} is the intersection of the event that i = S m for some m ∈ N and the event that for this m, we have Y m+1 ≥ n − i + 1. By the Markov property, the conditional probability of the latter event given the former is the same as the probability that Y 1 ≥ n − j + 1. Thus where f (i) := P (i = S m for some m ∈ N) and g(i) := P (Y 1 ≥ i). Since f (n) = ψ(n)n −(1−α) , we have By Lemma 4.2, t → t j=1 g(j) is regularly varying of exponent −(1 − α), so there is a slowly varying function ψ such that k j=1 g(j) = ψ(k)k 1−α .
The statement of the lemma follows.
Proof of Lemma 4.1. Let P 0 = 0 and for m ∈ N, let P m be the mth smallest j ∈ N for which X(−j, −1) contains no orders. Then the increments P m −P m−1 are iid, and by [GMS15, Lemma A.8], P 1 is regularly varying with exponent 1 − µ. By translation invariance, P (∃ m ∈ N such that P m = n) = P (I > n) .
By Lemma 1.12, this quantity is regularly varying in n with exponent µ and slowly varying correction ψ 0 . The statement of the lemma now follows from Lemma 4.3.

Statement and proof of the estimates.
In this subsection we will use the following notation.
Let J h,c n,k,r be the minimum of n + 1 and the smallest j ∈ [n − k, n] Z for which (51) holds.
For m ∈ N, let J H m and L H m be as in (10). Let E h,c n,k,r be the event that the following is true: Since X(−J H h , −1) contains no hamburger orders or flexible orders, it follows that E h,c n,k,r ⊂ E h,c n,k,r . The main result of this section is the following proposition, which is an analogue of Propositions 3.4 and 3.6 of Section 3 with the event E h,c n,k,r or E h,c n,k,r in place of the event E h,c n . We also include a regularity estimate.
Proposition 4.4. Suppose we are in the setting described just above. Let ψ 0 be the slowly varying function of Lemma 1.12 and let ψ 2 be the slowly varying function of Lemma 4.1. Fix C > 1. Suppose n, k, r, h, c ∈ N with k ≤ n, C −1 k ≤ r 2 ≤ Ck, and r ≤ C(h ∧ c).
(1) For each n, h, c, r, k as above, we have with the implicit constants depending only on C.
(2) There exists m * ∈ N, depending only on C, such that for each n, h, c, r, k as above with n, h, c, r, k ≥ m * and (h, c) ∈ C −1 n 1/2 , Cn 1/2 2 Z , we have P E h,c n,k,r ψ 0 (n)ψ 2 (k)n −1−µ k 1+µ with the implicit constants depending only on C.
(3) For each q ∈ (0, 1), there exists A > 0 and m * ∈ N (depending only on C and q) such that for each n, h, c, r, k as above with n, h, c, r, k ≥ m * and (h, c) ∈ C −1 n 1/2 , Cn 1/2 2 Remark 4.5. Only assertion 1 of Proposition 4.4 is needed for the proof of Theorem 1.10. However, the other assertions do not take much additional effort to prove and will be used in [GS15].
We will extract Proposition 4.4 from the following lemma, which in turn is a consequence of the results of Section 3 together with Lemma 4.1.
Lemma 4.6. For n, k ∈ N, let P n,k be the largest j ∈ [n − k, n] Z for which X(−j, −1) contains no orders (or P n,k = 0 if no such j exists). For n, k, r ∈ N and (h, c) ∈ N 2 , let E h,c n,k,r be the event that P n,k > 0 and N H X(−P n,k , −1) − h ≤ r, N C X(−P n,k , −1) − c ≤ r.
(1) For each n, h, c, r, k as above, we have with the implicit constants depending only on C.
(2) There exists n * ∈ N (depending only on C) such that for each n ≥ n * and each n, h, c, r, k as above with (h, c) ∈ C −1 n 1/2 , Cn 1/2 2 Z , we have P E h,c n,k,r ψ 0 (n)ψ 2 (k)n −1−µ r 2 k µ with the implicit constants depending only on C.
(3) For each q ∈ (0, 1), there exists A > 0 and n * ∈ N (depending only on C and q) such that for each n, h, c, r, k as above with n ≥ n * and (h, c) ∈ C −1 n 1/2 , Cn 1/2 2 Proof. Observe that with ψ 0 as in Lemma 1.12, ψ 2 as in Lemma 4.1, and the implicit constants depending only on p.
For m ∈ [n − k, n] Z , the event {P n,k = m} is the same as the event that X(−m, −1) contains no orders and there is no j ∈ [m + 1, n] for which X(−j, −m + 1) contains no orders. Hence the conditional law of X −m . . . X −1 given {P n,k = m} is the same as its conditional law given that X(−m, −1) contains no orders. By Lemma 1.12 and Proposition 3.6, it follows that for each m ∈ [n − k, n] Z , with the implicit constant depending only on p. By Proposition 3.4, for each C > 1 there exists n * ∈ N such that for each n ≥ n * and each (h, c) ∈ (2C) −1 n 1/2 , 2Cn 1/2 2 Z , with the implicit constant depending only on C. By Theorem 1.8, for each C > 1 and q ∈ (0, 1), there exists A > 0 and n * ∈ N (depending only on C and q) such that for each n ∈ N, each m ∈ [n − k, n] Z , and each (h, c) ∈ (2C) −1 n 1/2 , 2Cn 1/2 Z × 2 , we have We obtain assertion 1 by combining (54) and (55) then summing over all (h , c ) We similarly obtain assertion 2 from (54) and (56). Assertion 3 is immediate from (57).
The following lemma will be used to deduce Proposition 4.4 from Lemma 4.6.
Lemma 4.7. For n, k, r, h, c ∈ N, let P n,k and E h,c n,k,r be defined as in Lemma 4.6. Let E h,c n,k,r be defined as in (51) and let J h,c n,k,r be as in the discussion just after. For each C > 1 and each q ∈ (0, 1), there is an m * ∈ N and a B > 0, depending only on C and q, such that for each n, h, c, r, k ∈ N with k ≤ n, C −1 k ≤ r 2 ≤ Ck, and r ≤ C(h ∧ c) and each realization x of X −J h,c n,k,r . . . X −1 for which E h,c n,k,r occurs, we have Proof. Given n, h, c, r, k and a realization x as in the statement of the lemma, let F (x; B) = F h,c n,k,r (x; B) be the event that there is a j ∈ [|x| + k, |x| + Br 2 ] Z such that X(−j, −|x| − 1) contains no orders and between r and Br burgers of each type. Then we have By [She11, Theorem 2.5], we can find B 0 > C 2 (≥ k/r 2 ) such that for each r > 0, it holds with probability at least 1 − q/3 that the word X(−|x| − B 0 r 2 , −|x| − 1) contains at least r burgers of each type. By Lemma 1.13 and the Dynkin-Lamperti theorem [Dyn55,Lam62], we can find B 1 > B 0 , depending only on q, such that with probability at least 1−q/3, there is a j ∈ [|x|+B 0 r 2 , |x|+B 1 r 2 ] Z such that X(−j, −|x| − 1) contains no orders. By a second application of [She11, Theorem 2.5], we can find B 2 > 0 such that with probability at least 1−q/3, we have sup j∈[|x|+1,|x|+B1r 2 ] Z |X(−j, −|x|−1)| ≤ B 2 r.
Since J h,c n,k,r is a stopping time for X, read backward, the word . . . X −|x|−2 X −|x|−1 is independent from the event {X −J h,c n,k,r . . . X −1 = x}. By combining these observations, we obtain (58) with B = Proof of Proposition 4.4. Suppose given n, k, r, h, c as in the statement of the proposition and define the event E h,c n,k,r as in Lemma 4.6. By Lemma 4.7, we can find B > 0, depending only on C, such that P E h,c n+Br 2 ,Br 2 −k,Br | E h,c n,k,r ≥ 1 2 .
By combining this with assertion 1 of Lemma 4.6, we obtain assertion 1 of the present proposition.
From now on we assume further that that (h, c) ∈ C −1 n 1/2 , Cn 1/2 Z . To obtain assertion (2), let P h,c n,k,r be the smallest j ∈ [n − k, n] Z for which N H (X(−j, −1)) − h ≤ r and N C (X(−j, −1)) − c ≤ r, or P h,c n,k,r = n + 1 if no such j exists. Observe that P h,c n,k,r is a stopping time for the filtration generated by X, read backward; and P h,c n,k,r ≤ n on E h,c n,k,r . By assertion 2 of Lemma 4.6, if n is chosen sufficiently large (depending only on C) then (and since C −1 r 2 ≤ k ≤ Cr 2 ) we can find m * ∈ N, depending only on C, such that for n, h, c, k, r as above with n, h, c, k, r ≥ m * , implicit constant depending only on C. By (59) (applied with slightly perturbed values of n, r, h, and c) we obtain assertion 2. It remains to prove assertion 3. For A > 0, let By Lemma 4.7, we can find a B > 1, depending only on C, such that for each n, h, c, k, r as above, we have where E := E n+Br 2 ,Br 2 −k,Br . By assertions 1 and 2 of Lemma 4.6 together with assertions 1 and 2 of the present lemma, there is an m * ∈ N, depending only on C, such that for n, h, c, r, k as above with n, h, c, r, k ≥ m * , we have with the implicit constant depending only on C.
By assertion 3 of Lemma 4.6, for each α > 0 we can find A > 0 and m * ≥ m * , depending only on C and α, such that for m ≥ m * , we have with the implicit constant depending only on C. We now conclude by choosing α smaller than q divided by this implicit constant.

Empty reduced word exponent
In this section we will prove Theorem 1.10. The proof of the lower bound for P(X(1, 2n) = ∅) is easier, and is given in Section 5.1. The argument is similar to some of the proofs given in [GMS15, Section 2] (and in fact appeared in an earlier version of that paper). In Section 5.2, we will prove some estimates which are needed for the proof of the upper bound, namely a variant of [GMS15, Lemma 2.8] which tells us that a word with few hamburger orders is very unlikely to contain too many flexible orders; and an estimate to the effect that the path Z n is unlikely to stay close to the boundary of the first quadrant for a long time. In Section 5.3, we use the estimates of Section 4 and Section 5.2 to prove the upper bound in Theorem 1.10.

Lower bound.
In this subsection we will prove the lower bound in Theorem 1.10. The content of this subsection appeared in an earlier version of [GMS15], but was moved to its present location to present a more logical progression of ideas. We thank Cheng Mao for his contributions to this subsection. First we need to estimate an appropriate probability for Brownian motion.
Proof of Theorem 1.10, lower bound. We find it more convenient to prove the lower bound with X(−2n, −1) in place of X(1, 2n) (which we can do by translation invariance). Fix δ > 0 and C > 100, to be chosen later. Let k n be the smallest k ∈ N such that δ k n ≤ 1 and for k ∈ [0, k n ] Z let m k n = δ k n . Let µ be as in (11) and fix ν ∈ (1 − µ, 1/2).
Let b H 0 (resp. b C 0 ) be the number of hamburgers (resp. cheeseburgers) in X(−2n, −n − 1). For be the number of hamburgers (resp. cheeseburgers) in X(−2n, −m k n − 1). Let G n,0 be the event that X(−2n, −n − 1) contains no burgers, at least 7C −1 n 1/2 hamburger orders, at least 7C −1 n 1/2 cheeseburger orders, and at most Cn 1/2 total orders. For k ∈ [1, k n ] Z , let G n,k be the event that the following is true.
By [GMS15, Lemma 2.3], if C is chosen sufficiently large then we have P(G n,0 ) ≥ n −µ+on(1) . By inspection, if k ∈ [1, k n ] Z and m k n is sufficiently large then on G n,k , the word X(−2n, −m k n − 1) contains no orders and (60) By [She11, Theorem 2.5], [GMS15, Corollary 5.2], and Lemma 5.1, we can choose m * ∈ N, independent of n, in such a way that there is a deterministic constant q ∈ (0, 1), independent of n and δ, such that whenever k ∈ [1, k n ] Z with m k n ≥ m * , (60) holds on the event G n,k and Let k * be the largest k ∈ [1, k n ] Z for which m k n ≥ m * . Then with the o δ (1) independent of n. It follows from (60) that on k * k=0 G n,k , the word X(−2n, −m k n − 1) contains no orders and fewer than m k * n burgers. Since m * does not depend on n and m k * n ≤ δ −1 m * , we have (62) with the implicit constant independent of n. By combining (61) and (62) and using that δ is arbitrary, we obtain the upper bound in Theorem 1.10.
5.2. Some miscellaneous estimates. In this subsection we will prove some estimates which are needed for the proof of the upper bound in Theorem 1.10. First we prove a variant of [GMS15, Lemma 2.8] where we consider the number of hamburger orders in a word, rather than the length of the word.
To prove Lemma 5.2, we first require the following further lemma.
Lemma 5.3. Let µ be as in (11). For m ∈ N, let I H m be the mth smallest i ∈ N for which the word X(1, i) contains no hamburgers. Then for each ν > µ , we have Proof. For l ∈ N, let N l be the lth smallest m ∈ N such that X(1, I H m ) contains no cheeseburgers (equivalently no burgers). Let M m := sup{l ∈ N : N l ≤ m}. By [GMS15, Lemma 2.7], for each sufficiently large C > 1 we have Note that a hamburger can only be added to the stack at one of the times I H k for k ∈ N. Hence on the event (65), we have N 1 ≥ m, so Observe that N F By summing this estimate over [m, ∞) Z , we find that the probability that there exists even a single Suppose there exists n ∈ N such that h n := N H (X(1, n)) ≥ m and N F (X(1, n)) ≥ h 2ν n . For each such n, let m n be the largest k ∈ N such that I H k ≤ n. We clearly have m n ≥ h n , so by the above estimate it holds except on an event of probability o ∞ m (m) that m n ∈ [h n , 8h n ] Z for each such n.
Therefore, for each such n we have m n ≥ m and N F X(1, I H mn ) ≥ (m n /8) ν . We now obtain (63) by means of Lemma 5.3.
Next we will prove a result to the effect that it is very unlikely that the path n → D(n) of Section 1.1 stays close to the coordinate axes for a long time.
The events E k n (r) are independent. By [She11, Theorem 2.5], there is a q > 0, independent of n and r, such that P E k n (r) c ≥ q for each n ∈ N, each r ≥ n ν1 , and each k ∈ [n 1−2ν2 , r −2 n] Z . Hence it follows from (68) that for r ≥ n ν1 , we have for an appropriate choice of a as in the statement of the lemma. It is clear that P (G n (r) ∩ F n ) is increasing in r, so for a general choice of n ∈ N and r > 0, we have . This yields (67).

Upper bound.
We are now ready to complete the proof of Theorem 1.10.
For n ∈ N, let N 0 n := n/2 and let K 0 n be minimum of n+1 and the smallest j ≥ N 0 n such X(−j, −1) contains at least n 1/2−ζ hamburger orders and at least n 1/2−ζ cheeseburger orders. Inductively, if k ∈ N and N k−1 n and K k−1 n have been defined, define N k n and K k n as follows. • Let N k n be the smallest j ≥ 2n − 2n (ν k +ζ) such that X(−j, −1) contains at most n ν k +ζ orders. • Let K k n be the minimum of 2n − n 2ν k and the smallest j ≥ N k n such that X(−j, −1) contains at least n ν k −ζ hamburger orders and at least n ν k −ζ cheeseburger orders.  , 1/2) and a small ζ > 0. We first grow the word X backward up to a stopping time K 0 n between N 0 n = n/2 and n such that it holds on event of probability 1−o ∞ n (n) that the word X(−K 0 n , −1) contains at least n 1/2−ζ hamburger orders and at least n 1/2−ζ cheeseburger orders. Then we iterate the following procedure for k ∈ N: grow until the first time N k n after K k−1 n at which we have at most n ν k +ζ orders; then, if we do not have at least n ν k −ζ hamburger orders and at least n ν k −ζ cheeseburger orders, grow until the first time K k n at which we have n ν k −ζ hamburger orders and at least n ν k −ζ cheeseburger orders. It holds except on an event of probability o ∞ n (n) that this latter time is finite by Lemma 5.4. Furthermore, using Lemma 5.2, we obtain that it holds except on an event of probability o ∞ n (n) that each of the words X(−K k n , −1) contains at most n ν k+1 flexible orders (this is our reason for considering increments of size n ν k ). The figure shows three iterations of this procedure. Segments of the path corresponding to words of the form X N k n . . . X −K k−1 n are shown in blue and those corresponding to words of the form X −K k n . . . X −N k n −1 are shown in red. Note that it is possible that K k n = N k n (which is the case for k = 2 here).
Observe that the times N k n and K k n are stopping times for the word X, read backward. Let E 0 n be the event that K 0 n ≤ n, X(−K 0 n , −1) contains no burgers, and N F X(−K 0 n , −1) ≤ n ν .
Next we will show that it is very unlikely that X(−2n, −1) = ∅ and K k n ≥ 2n − n ν k . To this end, suppose (70) holds, X(−2n, −1) = ∅, and K k n > N k n . Then X(−N k n , −1) either has fewer than n ν k −ζ hamburger orders or fewer than n ν k −ζ cheeseburger orders. Assume without loss of generality that we are in the former setting. Let K k n be the smallest j ≥ N k n + 1 for which X(−j, −N k n − 1) contains at least n ν k −ζ hamburger orders. By (70) and Lemma 5.4, if X(−2n, −1) = ∅ then except on an event of probability o ∞ n (n) we have K k n ≤ 2n − (3/2)n 2ν k . If K k n > K k n , then X(− K k n , −1) contains at most n ν k −ζ + 1 hamburger orders and at most n ν k −ζ cheeseburger orders. By Lemma 5.2 (c.f. the argument above), if this is the case then except on an event of probability o ∞ n (n), the word X(− K k n , −1) contains at most n ν k+1 flexible orders. Hence if K k n ≥ 2n − n ν k and X(−2n, −1) = ∅, then except on an event of probability o ∞ n (n), we have sup By Lemma 5.4, the probability that this is the case is of order o ∞ n (n). It follows that the probability that X(−2n, −1) = ∅ and condition 1 in the definition of E k n fails to occur is o ∞ n (n). We have K k n ≥ N k n ≥ 2n − n 2(ν k +ζ) by definition, so [She11, Lemma 3.13] implies that except on an event of probability at most o ∞ n (n), we have (71) sup If X(−2n, −1) = ∅, then X(−2n, −K k n −1) contains at least |X(−K k n , −1)| burgers. From this and (71), we infer that condition 2 in the definition of E k n holds with probability at least 1 − o ∞ n (n). It is clear that condition 3 in the definition of E k n occurs whenever X(−2n, −1) = ∅. By Lemma 5.2, applied as in the argument leading to (70) (but with 2ζ in place of ζ) the probability that condition 2 in the definition of E k n occurs but condition 4 in the definition of E k n fails to occur is of order o ∞ n (n). This completes the proof of (69). (1 + o n (1))n 1/2−ζ k = 1 (1 + o n (1))n ν k−1 −ζ k ∈ [2, k] Z hamburgers, and similarly for cheeseburgers; and the total number of orders in X(−K k n , −K k−1 n − 1) is at most n ν k +2ζ . Furthermore, by condition 4 in the definition of E k−1 n (or the definition of E 0 n if k = 1) and condition 3 in the definition of E k n , the word X(−K k n , −1) contains at most N H X(−K k n , −1) + n ν k hamburgers, and similarly for cheeseburgers. Since K k−1 n ∈ 2n − n 2(ν k−1 +ζ) , 2n − n 2ν k−1 Z , we infer from assertion 1 of Proposition 4.4 (applied with h = N H X(−K k n , −1) +n ν k , c = N C X(−K k n , −1) + n ν k , 2n − K k−1 n in place of n, k n 2ν k +4ζ , and r n ν k +2ζ ) that for k ∈ [2, k] Z , with the o ζ (1) depending on k but not n. By [GMS15, Proposition 5.1], we also have P E 0 n ≤ n −µ+on(1) . Therefore, By combining this with (69), we get P (X(−2n, −1) = ∅) ≤ n −1−2µ+2(1+µ)ν k +o ζ (1)+on(1) .
Appendix A. Proof of Proposition 3.7 In this appendix, we will prove Proposition 3.7, which is the key input in the proofs of Propositions 3.8 and 3.9. Throughout this appendix we continue to use the notation of Section 3.1.
A.1. Brownian motion estimates. In this section we will prove some estimates for Brownian motion which are related to the scaling limits of the quantities considered in Section 3.1. We start with some basic calculations for an unconditioned Brownian motion.
Lemma A.1. Let B be a standard linear Brownian motion. For u ∈ R, let τ u be the last time t ∈ [0, 1] such that B s > u for each s ∈ (t, 1]; or τ u = 0 if no such time exists. The density of τ u restricted to the event τ u > 0 is given by Proof. Let σ u be the first time B hits u and set B s := B s+σu − B σu and τ u := sup{s ∈ [0, 1 − σ u ] : B s = 0}. Then B is a standard linear Brownian motion independent from σ u . The time τ u is equal to τ u − σ u on the event { B s > 0 ∀s ∈ ( τ u , 1 − σ u ]}, which by symmetry has probability 1/2, even if we condition on τ u . The conditional law of τ u given σ u is given by the arcsine distribution, The law of σ u is given by |u| √ 2π s −3/2 e −u 2 /2s ds, so we have By differentiating, we get that the density of τ u is given by Lemma A.2. Let Z = (U, V ) be a correlated two-dimensional Brownian motion as in (8). Fix T > 0.
For u ∈ R, let τ u be the last time t ∈ [0, T ] such that U (s) > u for each s ∈ (t, T ]; or τ u = 0 if no such time exists. The joint density of τ u and V ( τ u ) on the event { τ u > 0} is given by for constants a 0 , a 1 , a 2 , a 3 > 0 depending only on p.
Proof. First consider the case where T = 1. The density of τ u with respect to Lebesgue measure on the event { τ u > 0} is computed in Lemma A.1. The Brownian motion V can be written as the sum of a constant a 1 (depending only on p) times U ; and a Brownian motion V which is independent from U . On the event { τ u > 0}, we therefore have V ( τ u ) = V ( τ u ) + a 1 u. Hence the conditional law of V ( τ u ) given τ u on the event { τ u > 0} is that of a Gaussian random variable with mean a 1 u and variance a constant depending only on p times τ u . This yields the formula (73) in the case T = 1. For general T > 0, we have by Brownian scaling that where τ u (1) denotes the time τ u defined with T = 1. This yields the formula (73) in general.
From Lemma A.2, we obtain an estimate for a Brownian motion conditioned to stay in the first quadrant.
with the implicit constant in the upper bound independent of 1 , 2 , and a and uniform for (u, v) ∈ (0, ∞) 2 ; and the implicit constant in the lower bound independent of 1 and 2 and uniform for (u, v) ∈ [C −1 , C] for each C > 1. Furthermore, for ζ > 0 and b > 0, let F u,b (ζ) to be the event that there is a t ∈ [0, τ u ] such that U (t) ≤ ζ and V (t) ≥ b. Then we have with the o ζ (1) depending only on ζ and b and the implicit constant uniform for (u, v) ∈ (0, ∞) 2 .
Proof. We first prove a slightly more general statement with Z replaced by the unconditioned correlated Brownian motion Z = (U, V ). For u ∈ R and T > 0, let τ u (T ) be the last time t ∈ [0, T ] such that U (s) > u for each s ∈ (t, T ]; or τ u (T ) = 0 if no such time exists. For 1 , 2 > 0, u, v > 0, a ∈ [0, 1), and T > 0, let with the implicit constant in the upper bound depending only on p (and in particular uniform for (u, v) ∈ R 2 ) and the implicit constant in the lower bound depending only on a and uniform for (u, v) in compact subsets of (0, ∞) 2 .
It remains to transfer the estimate to Z. For 1 , 2 > 0 and u, v > 0, let Let σ be a stopping time for Z. For z ∈ (0, ∞) 2 , let P z denote the law of the correlated Brownian motion (8) started from z and for T > 0 let G T be the event that this Brownian motion stays in the first quadrant until time 1 − t 0 . By the Markov property of Z and (74) for the unconditioned Brownian motion Z, we have (77) . By (76) and [Shi85,Equation 4.2], this quantity is at most a constant (depending only on p) times with µ as in (11). If we take σ = 1/2, say, then by [Shi85,Equation 4.2], E | Z(σ)| −2µ < ∞. We thus obtain the upper bound in (74).
On the other hand, if we let σ be the smallest t ∈ [0, 1] for which U (t) ≤ ζ and V (t) ≥ b (or σ = ∞ if no such u exists) then with F u,b (ζ) as in (75), we have Since Z a.s. does not hit the boundary of the first quadrant after time 0, it follows that P (σ < ∞) = o ζ (1), at a rate depending only on b. By choosing this σ in our calculation above, we find that the event of (75) has probability at most a constant times It remains to prove the lower bound in (74). To this end, fix C > 1. Observe that for each T > 0, the regular conditional law of Z| [0, τu(T )] given an realization of ( τ u (T ), Z( τ u (T ))) for which τ u (T ) > 0 is that of a Brownian bridge from 0 to Z( τ (T )) in time τ u (T ). Hence if we let A be the event that inf t∈[0, τu(T )] U (t) and inf t∈[0, τu(T )] V (t) are each at least −(4C) −1 , then for (u, v) ∈ [(2C) −1 , 2C] 2 , P A | E 1 , 2 u,v (T ) is at least a positive constant depending only on C and T . By (76), for such a pair (u, v) we have with implicit constants depending only on C and T . By [Shi85, Theorem 2], for t 0 ∈ (0, 1) we have that P Z(t 0 ) ∈ [(4C) −1 , (2C) −1 ] 2 is at least a positive constant depending only on t 0 and C. By (77), We want to use the above lemmas to prove estimates for the word X conditioned on {I > n}. To do this we need the following fact.
Lemma A.4. Let Z = ( U , V ) have the law of a correlated Brownian motion as in (8) conditioned to stay in the first quadrant until time 1. For u > 0, let τ u be the last time t ∈ [0, 1] such that U (s) > u for each s ∈ (t, 1]; or τ u = 0 if no such time exists. Define the times K H n,m and the quantities Q H n,m as in Section 3.1. For each > 0 and C > 1, there exists n * = n * ( , C) ∈ N such that for each n ≥ n * and each m ∈ [C −1 n 1/2 , Cn 1/2 ] Z , the Prokhorov distance between the conditional law of (Z n , n −1 K H n,m , n −1/2 Q H n,m ) given {I > n} and the law of ( Z, τ m/n 1/2 , V (τ m/n 1/2 )) is at most .
Proof. By [GMS15, Theorem A.1] and the Skorokhod theorem, we can find a coupling of a sequence of words ( X n ) distributed according to the conditional law of the word X given {I > n}; and the path Z such that in this coupling Z n → Z uniformly a.s. on [0, 1], where Z n = ( U n , V n ) is the path constructed from the word X n as in (7). For u > 0, let τ n u be the last time t ∈ [0, 1] for which U n (s) > u for each s ∈ (t, 1]; and otherwise let τ n u = 0. If we construct the pair (n −1 K H n,m , n −1/2 Q H n,m ) as in Section 3.1 from the word X n , then for m ∈ N, (n −1 K H n,m , n −1/2 Q H n,m ) = (τ n m/n 1/2 + o n (1), V n (τ n m/n 1/2 ) + o n (1)).
Fix > 0 and C > 1. We observe the following.
Lemma A.6. For each C > 1, there exists δ * > 0 (depending only on C) such that for each δ ∈ (0, δ * ], there exists n * = n * (δ, C) ∈ N such that for n ≥ n * and (h, c) ∈ C −1 n 1/2 , Cn 1/2 2 Z , we have with the implicit constant depending only on C. By Lemma A.5, for any δ ∈ (0, δ * ], we can find n * = n * (δ, C) ∈ N such that for n ≥ n * and (h, c) as in the statement of the lemma, we have with the implicit constant depending only on C. By combining this with (82), we obtain the statement of the lemma.
In the case k 1 ≥ 0, Proposition 2. with a 0 > 0 and the implicit constants depending only on C, and the o δ 2 n (1) depending only on δ 2 n (and in particular not on x, k 1 , or k 2 ). It follows that we can find n * = n * (δ, C) such that for each (k 1 , k 2 ) ∈ [0, k δ ] Z × [0, k δ ] Z , and each realization x as above, we have for a constant a 0 > 0 depending only on C. By combining this with (84) we obtain (83) in the case k 1 < 0.