Contents
1 Introduction 4 1.1 Preview of Our Results 6 1.2 Our Techniques and Contributions 7 1.3 Related Literature 9
2 Problem Formulation and Preliminaries 11 2.1 Bayesian Optimal Stopping 11 2.2 Martingale Preliminaries 12
3 Approximation Algorithms 13 3.1 Warm-up: Approximation Algorithms via Primal Improvement 14 3.1.1 Algorithm 15 3.1.2 Analysis of the Primal Algorithm 17 3.2 Approximation Scheme via Iterative Primal-Dual Improvement 18 3.3 Efficient Implementation of Algorithm 2 23 3.4 Completing the Proof of Theorem 3: Analysis of Algorithm 2 25 3.4.1 Proof of Theorem 3 26 3.4.2 Proof of Lemma 5 26
4 Competitive Algorithms 29 4.1 Hard Instance of Theorem 4 30 4.2 Algorithm of Theorem 4 35
5 Conclusion and Open Questions 36
A Omitted Proofs from Section 1 40 A.1 Performance of History-oblivious Algorithms 40 A.2 Constructing Value Oracle from PMFs in IID and NON-IID Models 42 A.3 Hardness of Approximation with Sampling Oracles 42
Introduction
Online algorithms are traditionally analyzed under either adversarial or stochastic independent and identically distributed (IID) inputs; the former model can be overly pessimistic while the latter is too optimistic. To bridge this gap, researchers have developed several approaches that go beyond worst-case (see Roughgarden [33 ] for a survey).
We propose a Bayesian framework for online algorithm design in which a prior over world models induces a mixture distribution over IID inputs. Through the observations in the online phase, the algorithm learns about the world while making decisions. This model interpolates between adversarial and IID models, and captures the stochastic correlations in the input. Within this Bayesian framework, we develop a theory of optimal stopping—a canonical online selection problem—and use it to design and analyze new algorithms.
Bayesian setup. In our model, the ground truth world H H H is drawn from K K K worlds according to a known prior π \pi π but is hidden to the decision-maker. The world H H H then determines the distribution of n n n IID observations X 1 , ⋯ , X n X_1,\cdots,X_n X 1 , ⋯ , X n . The decision-maker selects one observation irrevocably without knowing the future observations or H H H , and its reward is the value of the selected observation. This model interpolates smoothly between classical settings: the known distribution prophet inequalities model of Samuel-Cahn [35 ] corresponds to our setup when the prior has a single component and the observations are conditionally independent given the world; conversely, by Yao’s minimax principle, the unknown IID model corresponds to arbitrary mixtures with any number of components, i.e., K = ∞ K=\infty K = ∞ .2 Our setup can then capture the spectrum between these two extremes, providing the flexibility to model various levels of uncertainty for decision-making. In fact, our results are for more general models, where (i) the observations are conditionally independent given H H H but may have different distributions, or (ii) even conditional on H H H , the observations may be correlated.
A key advantage of this Bayesian model is that it provides a framework for designing and analyzing online algorithms that learn while making decisions. The two extreme models discussed above often obscure the value of online learning: when the distribution is known, there is nothing to learn; when it is unknown, an elegant result of Correa et al. [11 ] shows that no amount of additional online learning can overcome the worst-case barrier of 1 / e 1/e 1/ e , which the classical secretary rule Dynkin [17 ] already attains. In our setup, by contrast, the decision-maker learns about the world as it decides. Each observation updates the posterior over H H H and, with it, the decision-maker’s beliefs about future observations. Waiting is therefore valuable for two reasons: a later observation may be larger, and earlier observations may reveal which world generated the sequence. Indeed, the next example shows that in the intermediate regime 1 < K < ∞ 1 < K < \infty 1 < K < ∞ , an algorithm that ignores what it learns can be far from optimal.
Example 1. Suppose K = 2 K = 2 K = 2 , n = 3 n = 3 n = 3 , and 0 < ε < 1 0 < \varepsilon< 1 0 < ε < 1 . Conditional on the world, the observations are IID, with the prior and conditional probabilities given below.
Observing a 0 completely identifies H H H and is essential to obtain near-optimal performance. To see this, consider a “history-oblivious” algorithm that does not use the observations before time t t t to decide whether or not to accept X t X_t X t . It is obvious that a reasonable algorithm would never accept 0 and would always accept 1 / ε 3 1/\varepsilon^3 1/ ε 3 . Thus, it is easy to see that there are only two reasonable history-oblivious algorithms: one that accepts X 1 = 1 / ε X_1 = 1/\varepsilon X 1 = 1/ ε , and one that would reject X 1 = 1 / ε X_1 = 1/\varepsilon X 1 = 1/ ε but would accept X 2 = 1 / ε X_2 = 1/\varepsilon X 2 = 1/ ε . A simple calculation shows that the latter performs better and its expected reward is 4 − O ( ε ) 4 - O(\varepsilon) 4 − O ( ε ) . By contrast, the optimal dynamic programming algorithm obtains a reward of 5 − O ( ε ) 5 - O(\varepsilon) 5 − O ( ε ) . Consequently, letting ε → 0 \varepsilon\to0 ε → 0 demonstrates that an algorithm that does not learn from its observations—in this case, checking whether X 1 = 0 X_1 = 0 X 1 = 0 —has a suboptimal performance. In fact, in Appendix § 6 .§ 1 , we extend this construction to show that the gap between history-oblivious and optimal algorithms can be arbitrarily large.
This example shows that a good Bayesian algorithm must adapt its decisions to what it learns from past observations. Such adaptivity has been largely absent from prior work on algorithms with partial information.3 The reason is that while adaptivity enables better algorithms, finding good adaptive policies is, in general, computationally challenging.
Research questions. The Bayes-optimal policy is the best adaptive algorithm: it solves a dynamic program (DP) over all reachable histories (roughly corresponding to posteriors) and thereby accounts for both the value of learning and the value of waiting. It is thus the natural benchmark for Bayesian algorithms, and it is tighter than the offline prophet, i.e., the benchmark that knows the input sequence. However, the state space of this dynamic program contains every reachable history and posterior, which can be exponentially large. This raises our first research question about approximating the Bayes-optimal algorithms, i.e., philosopher inequalities [29 , 5 ] in Bayesian optimal stopping: Can we design polynomial-time approximations of the Bayesian optimal stopping algorithms? Is there a gap between polynomial-time algorithms and the Bayes-optimal one?
The above question concerns computational barriers, i.e., how well a polynomial-time algorithm can approximate the Bayes-optimal policy. Our second question concerns information-theoretic barriers. We would like to derive prophet inequalities that bound the worst-case ratio between online algorithms and the offline prophet that knows the input sequence upfront. At both extremes of our model, this question is well understood. When K = 1 K = 1 K = 1 and the observations are independent, Krengel and Sucheston [26 ] and Samuel-Cahn [35 ] showed that the best competitive ratio is 1 / 2 1/2 1/2 , which led to many extensions (e.g., Kleinberg and Weinberg [25 ] , Rubinstein et al. [34 ] ); when the observations are also identically distributed, the best competitive ratio improves to ≈ 0.745 \approx0.745 ≈ 0.745 (Hill and Kertz [21 ] , Correa et al. [13 ] ). When K = ∞ K = \infty K = ∞ , the minimax principle reduces the problem to the setting where the distribution is unknown: for conditionally IID observations, the secretary algorithm of Dynkin [17 ] is 1 / e 1/e 1/ e -competitive, and Correa et al. [11 ] showed that no algorithm does better. For 1 < K < ∞ 1 < K < \infty 1 < K < ∞ , however, the best-possible competitive ratio is not known.
How does the best competitive ratio depend on the number of worlds K K K ? Is there a separation between the computational and information-theoretic barriers?
Preview of Our Results
Our results answer both questions. To state them, we distinguish between three formulations of the Bayesian problem: (i) in the IID model, the observations are conditionally IID given H H H ; (ii) in the NON-IID model, they are conditionally independent given H H H but may have different distributions; and (iii) in the CORREL model, they may be correlated even conditional on H H H . We compare online algorithms against two benchmarks: the Bayes-optimal policy (ON) and the offline prophet (OFF), who observes the whole sequence upfront. The next theorem summarizes our findings; the formal statements are Theorems 3–4 and Proposition 2. Below, ∣ I ∣ |\mathcal{I}| ∣ I ∣ denotes the input size.
Theorem 1 (Informal). For the Bayesian optimal stopping problem, there exists a ( 1 − ε ) (1-\varepsilon) ( 1 − ε ) -approximation of ON with runtime poly ( ∣ I ∣ log ∗ ∣ I ∣ + 1 / ε ⋅ ( 1 / ε ) 1 / ε 2 ) \operatorname{poly}\left(|\mathcal{I}|^{\log^{*}|\mathcal{I}|+1/\varepsilon}\cdot(1/\varepsilon)^{1/\varepsilon^{2}}\right) poly ( ∣ I ∣ l o g ∗ ∣ I ∣ + 1/ ε ⋅ ( 1/ ε ) 1/ ε 2 ) , whereas no online algorithm is substantially more competitive against OFF than in the worst case. In particular:
For the IID problem, there is a polynomial-time approximation scheme against ON. Against OFF, we obtain a ( 1 / e + 1 / poly ( K ) ) (1/e+1/\operatorname{poly}(K)) ( 1/ e + 1/ poly ( K )) -competitive algorithm, and no algorithm is better than ( 1 / e + 1 / poly ( K ) ) (1/e+1/\operatorname{poly}(K)) ( 1/ e + 1/ poly ( K )) -competitive.
For the NON-IID problem, there is an approximation scheme against ON. Against OFF, we obtain a 1 / ( 2 K ) 1/(2K) 1/ ( 2 K ) -competitive algorithm, and no algorithm is better than 1 / K 1/K 1/ K -competitive.
For the CORREL problem, there is an approximation scheme against ON. Against OFF, the best possible competitive ratio is 1 / n 1/n 1/ n .
Our approximation scheme runs in time poly ( ∣ I ∣ log ∗ ∣ I ∣ + 1 / ε ⋅ ( 1 / ε ) 1 / ε 2 ) \operatorname{poly}\left(|\mathcal{I}|^{\log^*|\mathcal{I}|+1/\varepsilon}\cdot(1/\varepsilon)^{1/\varepsilon^2}\right) poly ( ∣ I ∣ l o g ∗ ∣ I ∣ + 1/ ε ⋅ ( 1/ ε ) 1/ ε 2 ) , where ∣ I ∣ |\mathcal{I}| ∣ I ∣ is the input size (defined formally in § 2.1 ), log ∗ ( x ) \log^*(x) log ∗ ( x ) is the number of times the log function must be applied to x x x before the result is at most 1, and ε ∈ ( 0 , 1 ] \varepsilon\in(0,1] ε ∈ ( 0 , 1 ] is the accuracy parameter. While this is not, strictly speaking, a polynomial-time approximation scheme (PTAS), its runtime is far below the typical poly ( ∣ I ∣ ) log ∣ I ∣ \operatorname{poly}(|\mathcal{I}|)^{\log|\mathcal{I}|} poly ( ∣ I ∣ ) l o g ∣ I ∣ runtime of a quasi-PTAS. In the IID model, and in the NON-IID model with K = O ( 1 ) K = O(1) K = O ( 1 ) , the same scheme is a genuine PTAS (Theorem 3).4
The theorem shows a sharp separation between philosopher and prophet inequalities in the Bayesian set-up. Against ON, the approximation ratio can be made arbitrarily close to 1 in all three models. Against OFF, the competitive ratio degrades with K K K toward its worst-case value: in the IID model, the advantage over the 1 / e 1/e 1/ e guarantee for unknown distributions vanishes inversely polynomially in K K K , and in the NON-IID model the competitive ratio is Θ ( 1 / K ) \Theta(1/K) Θ ( 1/ K ) . In other words, the prophet remains out of reach for online algorithms, whereas the Bayes-optimal policy can be approximated efficiently. This result resolves, in part, the open questions posed by Correa et al. [12 ] for the competitive ratio in our IID setting with finite K K K , saying “[the 1 / e 1/e 1/ e asymptotic bound] leaves open the possibility of better guarantees when the number of candidate distributions is small, a setting we believe is of strong interest to applications.”
Our Techniques and Contributions
Beyond the modeling framework, our technical contributions are as follows.
A primal-dual iterative approach. Our approximation scheme is built around a primal improvement step that converts a competitive algorithm into one with a strictly better approximation ratio, i.e., transforming the guarantee against OFF to a better guarantee against ON through an improved algorithm (Proposition 1). We generalize the notion of competitiveness to be measured against a dual martingale , a term we use to refer to a martingale ( Z t ) t (Z_t)_t ( Z t ) t that satisfies Z t ≥ X t Z_t \ge X_t Z t ≥ X t almost surely for every t t t . Because ( Z t ) t (Z_t)_t ( Z t ) t is a martingale and Z t ≥ X t Z_t \ge X_t Z t ≥ X t , we infer E [ Z τ ] ≥ E [ X τ ] \mathbb{E}[Z_\tau] \ge\mathbb{E}[X_\tau] E [ Z τ ] ≥ E [ X τ ] for any (bounded) stopping time τ \tau τ . Letting τ = τ ∗ \tau= \tau^* τ = τ ∗ be the stopping time of the Bayes-optimal policy, Doob’s optional sampling theorem implies that no online algorithm can obtain more than E [ Z 1 ] = E [ Z τ ] \mathbb{E}[Z_1] = \mathbb{E}[Z_\tau] E [ Z 1 ] = E [ Z τ ] , so E [ Z 1 ] ≥ O N \mathbb{E}[Z_1] \ge\mathrm{ON} E [ Z 1 ] ≥ ON ; we say that an algorithm is α \alpha α -competitive against ( Z t ) t (Z_t)_t ( Z t ) t if it earns at least α ⋅ E [ Z 1 ] \alpha\cdot\mathbb{E}[Z_1] α ⋅ E [ Z 1 ] . A natural starting point is the Doob martingale of the prophet’s reward, Z t = E [ max s ∈ [ n ] X s ∣ F t ] Z_t = \mathbb{E}[\max_{s\in[n]} X_s \mid\mathcal{F}_t] Z t = E [ max s ∈ [ n ] X s ∣ F t ] , against which competitiveness is the usual competitiveness against OFF.
The improvement step, Algorithm 1, takes as input a dual martingale ( Z t ) t ∈ [ n ] (Z_t)_{t\in[n]} ( Z t ) t ∈ [ n ] and an algorithm A \mathcal{A} A that is α \alpha α -competitive against it, and returns an improved algorithm that is a α + \alpha^+ α + -approximation (against ON), where α + = ( 1 + ln ( 1 / α ) ) − 1 > α \alpha^+ = (1+\ln(1/\alpha))^{-1} > \alpha α + = ( 1 + ln ( 1/ α ) ) − 1 > α . To do so, Algorithm 1 randomizes between two subroutines. With some probability, it runs the α \alpha α -competitive baseline A \mathcal{A} A . With the remaining probability, it runs a dual-threshold subalgorithm A t h r \mathcal{A}_{\mathrm{thr}} A thr , which draws a (random) cutoff Q ∈ [ α , 1 ] Q \in[\alpha,1] Q ∈ [ α , 1 ] and accepts the first X t X_t X t with X t ≥ Q ⋅ Z t X_t \ge Q \cdot Z_t X t ≥ Q ⋅ Z t . The two subroutines complement each other. On sample paths where some observation is large relative to the dual martingale, i.e., X t / Z t ≥ q X_t/Z_t \ge q X t / Z t ≥ q for some t t t , A t h r \mathcal{A}_{\mathrm{thr}} A thr with cutoff q q q stops and collects at least a q q q fraction of the dual value. Conversely, the baseline algorithm covers other sample paths on which every ratio X t / Z t X_t/Z_t X t / Z t is small, i.e., the gap between the observations and the dual martingale is large. Proposition 1 shows that this mixture is an α + \alpha^{+} α + -approximation of ON, where α + > α \alpha^{+} > \alpha α + > α for every α ∈ ( 0 , 1 ) \alpha\in(0,1) α ∈ ( 0 , 1 ) ; for instance, starting from the 1 / e 1/e 1/ e -competitive secretary algorithm in the IID model gives a 1 / 2 1/2 1/2 -approximation by one step improvement.
Since α + > α \alpha^{+} > \alpha α + > α , it is natural to apply the improvement step again, with the improved algorithm as the new baseline. However, the improvement step cannot be applied directly to its own output. It requires a baseline that is competitive against a dual martingale, whereas Proposition 1 only shows that the output approximates ON. We resolve this by showing that the improvement step also produces a new, tighter dual martingale against which its output is competitive, which turns the primal improvement into a primal-dual one. Specifically, let M = Z n M = Z_n M = Z n be the terminal value of ( Z t ) t (Z_t)_t ( Z t ) t and define ρ = max t X t / Z t ≤ 1 \rho= \max_t X_t/Z_t \le1 ρ = max t X t / Z t ≤ 1 on each sample path. We show that the output of Algorithm 1 is α + \alpha^{+} α + -competitive against the Doob martingale of the shrunken certificate M ⋅ max { ρ , α } M \cdot\max\{\rho,\alpha\} M ⋅ max { ρ , α } , which still dominates ( X t ) t (X_t)_t ( X t ) t and is tighter than M M M . Algorithm 2 pairs the primal improvement with this dual multiplicative shrinkage , producing pairs ( A j , Z ( j ) ) (A_j,Z^{(j)}) ( A j , Z ( j ) ) in which A j A_j A j is α j \alpha_j α j -competitive against Z ( j ) Z^{(j)} Z ( j ) , with
α 0 ≤ α 1 ≤ ⋯ < 1 , E [ Z 1 ( 0 ) ] ≥ E [ Z 1 ( 1 ) ] ≥ ⋯ ≥ O N , α j + 1 = ( 1 + ln 1 / α j ) − 1 . \alpha_0 \le\alpha_1 \le\cdots< 1,\qquad\mathbb{E}[Z_1^{(0)}] \ge\mathbb{E}[Z_1^{(1)}] \ge\cdots\ge\mathrm{ON},\qquad\alpha_{j+1} = \left(1+\ln1/\alpha_j\right)^{-1}. α 0 ≤ α 1 ≤ ⋯ < 1 , E [ Z 1 ( 0 ) ] ≥ E [ Z 1 ( 1 ) ] ≥ ⋯ ≥ ON , α j + 1 = ( 1 + ln 1/ α j ) − 1 .
Thus, our construction approaches ON simultaneously from below, through improving algorithms, and from above, through shrinking dual certificates. The recursion reaches a constant after O ( log ∗ 1 / α 0 ) O(\log^{*} 1/\alpha_0) O ( log ∗ 1/ α 0 ) steps and reaches 1 − ε 1-\varepsilon 1 − ε after O ( 1 / ε ) O(1/\varepsilon) O ( 1/ ε ) further steps. To start this process, the initial dual martingale is the Doob martingale from the prophet’s reward, i.e, Z t ( 0 ) = E [ max s ∈ [ n ] X s ∣ F t ] Z_t^{(0)} = \mathbb{E}[\max_{s \in[n]} X_s \mid\mathcal{F}_t] Z t ( 0 ) = E [ max s ∈ [ n ] X s ∣ F t ] . As baselines, we use the secretary algorithm in the IID model (α 0 = 1 / e \alpha_0 = 1/e α 0 = 1/ e ), the 1 / 2 1/2 1/2 -competitive threshold algorithm of the world h ⋆ h^{\star} h ⋆ with the largest contribution to OFF in the NON-IID model (α 0 = 1 / 2 K \alpha_0 = 1/2K α 0 = 1/2 K ), and accepting the time step t ⋆ t^{\star} t ⋆ with the largest contribution to OFF in the CORREL model (α 0 = 1 / n \alpha_0 = 1/n α 0 = 1/ n ). Putting these together, Algorithm 2 returns the desired approximation scheme for the Bayesian optimal stopping problem.
Efficient approximation of dual martingales. The main obstacle to implementing Algorithm 2 is that the martingales Z ( j ) Z^{(j)} Z ( j ) cannot be computed exactly. They are defined recursively: evaluating Z t ( j ) Z_t^{(j)} Z t ( j ) at a history h t h_t h t requires averaging the certificate M j = Z n ( j ) M_j = Z_n^{(j)} M j = Z n ( j ) over all continuations of h t h_t h t , and M j M_j M j on each continuation depends on Z ( j − 1 ) Z^{(j-1)} Z ( j − 1 ) at all of its prefixes. What makes approximation possible is that our dual shrinkage is local: it rescales the certificate on each sample path using only quantities along that path. Hence, Z t ( j ) ( h t ) Z_t^{(j)}(h_t) Z t ( j ) ( h t ) can be estimated by Monte Carlo, sampling continuations of h t h_t h t and recursively estimating Z t ( j − 1 ) Z_t^{(j-1)} Z t ( j − 1 ) along each of them. By contrast, the optimal dual martingale, like the Snell envelope, is determined by backward induction over the entire scenario tree. To obtain estimates that are accurate within a multiplicative factor, we sample from a change of measure that reweights each path by its prophet reward, so that rare paths with large rewards are not missed. The resulting estimator runs in time poly ( 2 j 2 ∣ I ∣ j + 1 ) \operatorname{poly}(2^{j^2}|\mathcal{I}|^{j+1}) poly ( 2 j 2 ∣ I ∣ j + 1 ) , which gives an approximation scheme in general and a PTAS whenever α 0 \alpha_0 α 0 is a constant (the IID model, and the NON-IID model with K = O ( 1 ) K = O(1) K = O ( 1 ) ).
Hardness of prophet inequalities. To understand the information-theoretic barriers in this problem, we construct an IID instance in which no online algorithm is better than ( 1 / e + O ( 1 / K ) ) (1/e+O(1/\sqrt{K})) ( 1/ e + O ( 1/ K )) -competitive. A minimax argument shows that 1 / e 1/e 1/ e is the best constant as K → ∞ K \to\infty K → ∞ [12 Theorem 5.1] ; our construction is explicit and quantifies the dependence on K K K . The instance must balance two requirements. On the one hand, observations should not quickly reveal the world; otherwise an online algorithm could identify it and tailor its thresholds. On the other hand, the worlds must differ enough that their prophet rewards diverge. We achieve both with a set of distributions that have nested supports and such that observed samples are minimally informative, making the posterior change only mildly. Analyzing the Bayesian DP directly on this instance is difficult because the posterior still evolves and its analysis is intricate. Instead, we bound the reward of every online algorithm by constructing an explicit dual martingale and by then comparing that with OFF. An interesting takeaway of our paper is that dual martingales can serve both for algorithm design and for impossibility results in Bayesian models.
We complement this hardness result with a ( 1 / e + Ω ( 1 / K 2 ) ) (1/e+\Omega(1/K^2)) ( 1/ e + Ω ( 1/ K 2 )) -competitive algorithm, which adapts the robustness–consistency algorithm of Bai et al. [3 ] by committing to the world with the largest contribution to OFF and setting its parameters in terms of K K K . Moreover, in the NON-IID model, we show that the 1 / 2 K 1/2K 1/2 K -competitive baseline above is optimal up to a factor of 2. Finally, by constructing a martingale-based hard instance, we show that in the CORREL model, 1 / n 1/n 1/ n is the optimal competitive ratio.
Related Literature
Prophet and philosopher inequalities. Prophet inequalities originate with Krengel and Sucheston [26 ] and Samuel-Cahn [35 ] , who showed that the best competitive ratio for independent observations is 1 / 2 1/2 1/2 ; for IID observations, it is ≈ 0.745 \approx0.745 ≈ 0.745 [21 , 13 ] . These results have been extended in many directions, e.g., to matroids [25 ] and posted pricing [18 , 14 ] ; see Lucier [28 ] for a survey. Closest to our work are models with limited distributional knowledge, such as unknown distributions [11 , 12 ] , samples [22 , 10 , 34 ] , inaccurate priors [16 ] , and predictions [3 , 23 ] . While this line of work has mostly focused on the offline benchmark, the online benchmark is an equally natural one, studied through the recently introduced notion of philosopher inequalities [29 ] . For online stochastic matching, approximating the optimal online policy within some constant factor is PSPACE-hard [29 ] , and constant-factor approximations are known [29 , 4 , 5 ] ; see also Anari et al. [1 ] , Dütting et al. [15 ] , Fu et al. [19 ] . More related to our work, Kesselheim et al. [24 ] recently used the minimax principle to reduce the worst-case competitive analysis of online combinatorial problems to Bayesian design under arbitrarily correlated distributions. Through this reduction, they aim to provide a unifying framework for designing competitive algorithms for online combinatorial problems, i.e., to study the information-theoretic barrier. Their main technical idea is to use the posterior of the offline optimum to guide online decisions. Our focus, by contrast, is on Bayesian optimal stopping, which we study across the whole spectrum of uncertainty, parametrized by the prior size K K K and in different models (IID, NON-IID, CORREL). We study both the computational and information-theoretic barriers, and by devising an approximation scheme against ON, we show a separation between the two.
Stochastic control. Our problem is a partially observable Markov decision process with a stopping action [31 ] , and computing optimal policies for such processes is PSPACE-hard in general [30 ] . In applied probability, a rich literature on pricing American options approximates optimal stopping by simulation [27 ] , together with dual upper bounds given by martingales [32 , 20 , 7 , 2 ] ; Brown et al. [6 ] extend this duality to information relaxations of general stochastic dynamic programs. Our dual martingales are closely related to these representations. These methods typically focus more on heuristics than on approximation algorithms with worst-case guarantees. An exception is Chen and Goldberg [8 ] , who give an additive ε \varepsilon ε -approximation that runs in polynomial time for every fixed ε \varepsilon ε , for optimal stopping problems with a bounded rewards assumption. When the offline benchmark has a bounded coefficient of variation, their algorithm is a multiplicative approximation. Their main technical tool is an expansion of the value function that is related to our dual martingales through additive updates. However, we show that under their information-access model which is based on sample oracles, obtaining an approximation ratio better than 6/7 is not possible (see § 2.1 ). We instead assume access to a probability and value oracle and obtain an approximation scheme with no assumption on reward ranges or coefficients of variance—which are typically the hard instances for optimal stopping approximation algorithms.
Problem Formulation and Preliminaries
Bayesian Optimal Stopping
We consider an optimal stopping problem over a horizon [ n ] = { 1 , ⋯ , n } [n]=\{1,\cdots,n\} [ n ] = { 1 , ⋯ , n } . There are K K K possible worlds { 1 , ⋯ , K } \{1,\cdots,K\} { 1 , ⋯ , K } . Each world k k k corresponds to a sequence of distributions ( D t ( k ) ) t ∈ [ n ] (D_t^{(k)})_{t\in[n]} ( D t ( k ) ) t ∈ [ n ] on non-negative reward values v 1 , ⋯ , v m ∈ R + v_1,\cdots,v_m\in\mathbb{R}_+ v 1 , ⋯ , v m ∈ R + . We assume that v 1 , ⋯ , v m v_1,\cdots,v_m v 1 , ⋯ , v m are given parts of the input and the overall bit complexity of the input includes the encoding of these values. The ground truth world H H H is drawn randomly from { 1 , ⋯ , K } \{1,\cdots,K\} { 1 , ⋯ , K } according to the prior distribution π = ( π 1 , ⋯ , π K ) \pi=(\pi_1,\cdots,\pi_K) π = ( π 1 , ⋯ , π K ) . Then, there is a sequence of n n n random rewards ( X 1 , ⋯ , X n ) (X_1,\cdots,X_n) ( X 1 , ⋯ , X n ) , drawn from the joint distribution D ( H ) D^{(H)} D ( H ) conditional on world H H H . While the algorithm designer knows the prior distribution π \pi π and value distributions ( D ( h ) ) h ∈ [ K ] (D^{(h)})_{h\in[K]} ( D ( h ) ) h ∈ [ K ] —formally explained in the next paragraph, it does not observe H H H . When for each h ∈ [ K ] h\in[K] h ∈ [ K ] , the distributions D t ( h ) D_t^{(h)} D t ( h ) are independent and identical across time steps, we call our model the IID case; when they are only independent but not identical; we call it NON-IID; and when they are not even independent, we call it CORREL. If K = 1 K=1 K = 1 , the NON-IID case is the classic prophet inequality problem of Samuel-Cahn [35 ] , whereas the IID case is simply the IID prophet inequality problem of Correa et al. [13 ] .
Our goal is to devise a polynomial-time algorithm A \mathcal{A} A that selects one item from X 1 , ⋯ , X n X_1,\cdots,X_n X 1 , ⋯ , X n of maximal expected value, only knowing the prior over K K K worlds and their corresponding distributions. We measure running time by the number of arithmetic operations and calls to the information oracles defined below, counting each as one unit of time. Our bounds are expressed in terms of the number of worlds K K K , the support size m m m , the horizon n n n , and the accuracy ε \varepsilon ε . We denote the reward of our algorithm by r ( A ) r(\mathcal{A}) r ( A ) .
Information access model. We assume access to two information oracles: (i) a probability oracle that, given any history h t h_t h t and value v q v_q v q , returns Pr [ X t + 1 = v q ∣ F t ] \Pr[X_{t+1}=v_q\mid\mathcal{F}_t] Pr [ X t + 1 = v q ∣ F t ] , where F t \mathcal{F}_t F t is the natural filtration from the history h t h_t h t ; and (ii) a value oracle that returns E [ max t ′ ∈ [ n ] X t ′ ∣ F t ] \mathbb{E}[\max_{t'\in[n]}X_{t'}\mid\mathcal{F}_t] E [ max t ′ ∈ [ n ] X t ′ ∣ F t ] which is the conditional expected reward of OFF given history h t h_t h t . In the IID and NON-IID models, both oracles can be efficiently constructed from the probability mass function (PMF) of each distribution D ( h ) D^{(h)} D ( h ) , where we note that having the PMF is a standard assumption in the prophet inequality literature (see Appendix § 6 .§ 2 for the construction). In this case, the given PMFs also allow us to compute the posterior over worlds exactly by Bayes’ rule. For the CORREL model, however, these oracles are additional computational assumptions, as the input distributions may not have compact representations.
One potential alternative is to assume access to a sample oracle that, given any history h t h_t h t , outputs a fresh sample for the continuation of h t h_t h t from the conditional distribution Pr [ ⋅ ∣ F t ] \Pr[\cdot\mid\mathcal{F}_t] Pr [ ⋅ ∣ F t ] . This is the information model used by Chen and Goldberg [8 ] . However, under such model, we show in Appendix § 6 .§ 3 that even the classical problem with K = 1 K=1 K = 1 admits no approximation scheme and no polynomial-time algorithm can guarantee an approximation ratio better than 6 / 7 6/7 6/7 . This result shows that we need stronger information access models than sampling oracles to obtain near-optimal performance.
Benchmarks. We consider two benchmarks. The first one is the offline benchmark that knows M = max { X 1 , ⋯ , X n } M = \max\{X_1,\cdots,X_n\} M = max { X 1 , ⋯ , X n } upfront. Thus, the expected reward of this benchmark is E [ M ] \mathbb{E}[M] E [ M ] , where the expectation is with respect to the true world H H H and the randomness in X 1 , ⋯ , X n X_1,\cdots,X_n X 1 , ⋯ , X n conditional on H H H . With a slight abuse of notation, we denote the benchmark and its expected reward by OFF. Consequently, we define the competitive ratio by C R ( A ) = E [ r ( A ) ] O F F \mathrm{CR}(\mathcal{A}) = \frac{\mathbb{E}[r(\mathcal{A})]}{\mathrm{OFF}} CR ( A ) = OFF E [ r ( A )] .
The second benchmark we consider is the online benchmark that has the same information as us, but it has unlimited computational power. Indeed, this algorithm and its expected reward correspond to an (exponentially-sized) Bayesian DP. We denote both by ON. Then, the approximation ratio is defined as A R ( A ) = E [ r ( A ) ] O N \mathrm{AR}(\mathcal{A}) = \frac{\mathbb{E}[r(\mathcal{A})]}{\mathrm{ON}} AR ( A ) = ON E [ r ( A )] .
The Bayesian DP has two actions: accept X t X_t X t and terminate, or reject it and continue. Its value-to-go, after observing history h t = ( X 1 , ⋯ , X t ) h_t=(X_1,\cdots,X_t) h t = ( X 1 , ⋯ , X t ) and before making the decision at time t t t , is the Snell envelope S t = V t ( h t ) S_t=V_t(h_t) S t = V t ( h t ) , defined by backward induction:
S n = X n , S t = max { X t , E [ S t + 1 ∣ F t ] } ( t < n ) . (1) S_n=X_n,\qquad S_t=\max\{X_t,\mathbb{E}[S_{t+1}\mid\mathcal{F}_t]\}\quad(t<n). \tag*{(1)} S n = X n , S t = max { X t , E [ S t + 1 ∣ F t ]} ( t < n ) . (1)
Thus, S t S_t S t compares the reward from stopping immediately with the expected reward from continuing optimally, with the conditional expectation incorporating the posterior over worlds. It is the smallest supermartingale dominating ( X t ) t ∈ [ n ] (X_t)_{t\in[n]} ( X t ) t ∈ [ n ] , and thus, E [ S 1 ] = O N \mathbb{E}[S_1]=\mathrm{ON} E [ S 1 ] = ON .
Notation and assumption. For a sample path ω \omega ω of all n n n observations and a time t t t , let ω t \omega_t ω t be the history until time t t t under ω \omega ω , i.e., the t t t -prefix of ω \omega ω . The state space is Ω = { v 1 , ⋯ , v m } n \Omega=\{v_1,\cdots,v_m\}^n Ω = { v 1 , ⋯ , v m } n . Throughout the paper, we assume that E [ max t ′ ∈ [ n ] X t ′ ∣ h t ] > 0 \mathbb{E}[\max_{t'\in[n]}X_{t'}\mid h_t]>0 E [ max t ′ ∈ [ n ] X t ′ ∣ h t ] > 0 for every reachable history h t h_t h t . This assumption is only for notational convenience and can be removed without affecting our results by simply making the algorithm ignore sample paths that violate this assumption.
Martingale Preliminaries
Definition 1. An integrable process ( Z t ) t ∈ [ n ] (Z_t)_{t\in[n]} ( Z t ) t ∈ [ n ] is a martingale with respect to filtration ( F t ) t ∈ [ n ] (\mathcal{F}_t)_{t\in[n]} ( F t ) t ∈ [ n ] if for every t < n t<n t < n , Z t Z_t Z t is F t \mathcal{F}_t F t -measurable, and E [ Z t + 1 ∣ F t ] = Z t \mathbb{E}[Z_{t+1}\mid\mathcal{F}_t]=Z_t E [ Z t + 1 ∣ F t ] = Z t almost surely. Replacing the equality by “≤ \leq ≤ ” defines a supermartingale.
Any F n \mathcal{F}_n F n -measurable random variable M M M is called a terminal random variable . Given a terminal random variable M M M , the corresponding Doob’s martingale is defined as Z t = E [ M ∣ F t ] Z_t=\mathbb{E}[M\mid\mathcal{F}_t] Z t = E [ M ∣ F t ] .5 Conversely, any martingale ( Z t ) t (Z_t)_t ( Z t ) t can be expressed in terms of its terminal value by setting M = Z n M=Z_n M = Z n and noting Z t = E [ Z n ∣ F t ] = E [ M ∣ F t ] Z_t=\mathbb{E}[Z_n\mid\mathcal{F}_t]=\mathbb{E}[M\mid\mathcal{F}_t] Z t = E [ Z n ∣ F t ] = E [ M ∣ F t ] . For any history h t = ( x 1 , … , x t ) h_t=(x_1,\ldots,x_t) h t = ( x 1 , … , x t ) , we write Z t ( h t ) Z_t(h_t) Z t ( h t ) as the value of the martingale at time t t t , conditional on having observed h t h_t h t . Formally, we mean Z t ( h t ) = E [ M ∣ X 1 = x 1 , … , X t = x t ] Z_t(h_t)=\mathbb{E}[M\mid X_1=x_1,\ldots,X_t=x_t] Z t ( h t ) = E [ M ∣ X 1 = x 1 , … , X t = x t ] .
The main property of a martingale is that its (unconditional) expectation remains the same, so that E [ Z 1 ] = ⋯ = E [ Z n ] \mathbb{E}[Z_1]=\cdots=\mathbb{E}[Z_n] E [ Z 1 ] = ⋯ = E [ Z n ] . We now recall Doob’s optional sampling/stopping theorem—a key result from martingale theory—that concerns the expected value of a martingale at stopping times. A random variable τ ∈ [ n ] ∪ ∞ \tau\in[n]\cup\infty τ ∈ [ n ] ∪ ∞ is a stopping time if { τ ≤ t } \{\tau\le t\} { τ ≤ t } is F t \mathcal{F}_t F t -measurable for every t ∈ [ n ] t\in[n] t ∈ [ n ] . A stopping time τ \tau τ is bounded if τ ≤ n \tau\le n τ ≤ n almost surely.
Theorem 2 (Doob’s Optional Sampling Theorem , [cf. 36 ] ). Let ( Z t ) t ∈ [ n ] (Z_t)_{t\in[n]} ( Z t ) t ∈ [ n ] be an integrable martingale, and let τ \tau τ be a bounded stopping time. Then, we have E [ Z τ ] = E [ Z 1 ] \mathbb{E}[Z_\tau]=\mathbb{E}[Z_1] E [ Z τ ] = E [ Z 1 ] .
Next, we define the notion of dual martingales which is central to our paper.
Definition 2. A martingale ( Z t ) t (Z_t)_t ( Z t ) t is a dual martingale for the sequence ( X t ) t (X_t)_t ( X t ) t if, for every t ∈ [ n ] t\in[n] t ∈ [ n ] , we have Z t ≥ X t Z_t\ge X_t Z t ≥ X t almost surely. Moreover, the corresponding terminal random variable Z n Z_n Z n is called a dual certificate .
A dual martingale provides an upper bound on the performance of the optimal algorithm. Indeed, for any bounded stopping time τ \tau τ , Doob’s optional sampling (Theorem 2) implies E [ X τ ] ≤ E [ Z τ ] = E [ Z n ] \mathbb{E}[X_\tau]\le\mathbb{E}[Z_\tau]=\mathbb{E}[Z_n] E [ X τ ] ≤ E [ Z τ ] = E [ Z n ] . Letting τ = τ ∗ \tau=\tau^* τ = τ ∗ be the stopping time corresponding to the optimal algorithm shows the claim. Consequently, we can define the notion of competitiveness against a dual martingale : An algorithm A \mathcal{A} A is α \alpha α -competitive against ( Z t ) (Z_t) ( Z t ) , if r ( A ) ≥ α ⋅ E [ Z 1 ] r(\mathcal{A})\ge\alpha\cdot\mathbb{E}[Z_1] r ( A ) ≥ α ⋅ E [ Z 1 ] . If this holds, because E [ Z 1 ] ≥ O N \mathbb{E}[Z_1]\ge\mathrm{ON} E [ Z 1 ] ≥ ON , we immediately infer that A \mathcal{A} A is an α \alpha α -approximation to the optimum online algorithm as well.
The term dual refers to the following pair of optimization problems:
O N = sup τ stopping time 1 ≤ τ ≤ n E [ X τ ] ≤ inf ( Z t ) t martingale Z t ≥ X t a.s. for every t E [ Z n ] . \mathrm{ON}=\sup_{\substack{\tau\ \text{stopping time}\\1\le\tau\le n}}\mathbb{E}[X_\tau]\le\inf_{\substack{(Z_t)_t\ \text{martingale}\\Z_t\ge X_t\ \text{a.s. for every }t}}\mathbb{E}[Z_n]. ON = τ stopping time 1 ≤ τ ≤ n sup E [ X τ ] ≤ ( Z t ) t martingale Z t ≥ X t a.s. for every t inf E [ Z n ] .
The primal problem chooses a stopping policy to maximize expected reward, whereas the dual problem chooses a dominating martingale to minimize its expected value. The inequality is weak duality, established above by optional sampling. In fact, equality holds: this is strong duality, which our analysis in § 3.2 also establishes.
Approximation Algorithms
In this section, we present our main result, which is a near-polynomial time approximation scheme for the Bayesian optimal stopping problem. In the following theorem, log ∗ \log^* log ∗ denotes the iterated logarithm function.
Theorem 3. For every 0 < ε ≤ 1 0<\varepsilon\le1 0 < ε ≤ 1 , there is an algorithm A \mathcal{A} A such that for any instance of the Bayesian optimal stopping problem in the CORREL model, r ( A ) ≥ ( 1 − ε ) O N r(\mathcal{A})\ge(1-\varepsilon)\mathrm{ON} r ( A ) ≥ ( 1 − ε ) ON and A \mathcal{A} A runs in time poly ( K m n 1 / ε + log ∗ n ⋅ ( 1 / ε ) 1 / ε 2 ) \operatorname{poly}(Kmn^{1/\varepsilon+\log^*n}\cdot(1/\varepsilon)^{1/\varepsilon^2}) poly ( K m n 1/ ε + l o g ∗ n ⋅ ( 1/ ε ) 1/ ε 2 ) . In the special case of the NON-IID model, the exponent of n n n in the
running time is 1 / ε + log ∗ ( min { n , 2 K } ) 1/\varepsilon+ \log^*(\min\{n, 2K\}) 1/ ε + log ∗ ( min { n , 2 K }) , and for the IID model, this exponent is 1 / ε 1/\varepsilon 1/ ε , making this algorithm a polynomial-time approximation scheme.
Notice that if K = O ( 1 ) K = O(1) K = O ( 1 ) so that the number of different worlds is bounded, our algorithm for the NON-IID model is in fact a genuine PTAS.
Remark 1 (Extension to exchangeable observations). The PTAS guarantee for the IID model in Theorem 3 extends to the more general setting where the observations are exchangeable conditional on H H H . Indeed, conditional exchangeability implies unconditional exchangeability, under which the classical secretary algorithm remains 1 / e 1/e 1/ e -competitive against OFF. As we show in this section, the runtime of our approximation scheme depends on the competitive ratio of a baseline algorithm, while the remainder of our analysis applies to arbitrarily correlated observations. Thus, the existence of a 1 / e 1/e 1/ e -competitive baseline yields a PTAS for conditionally exchangeable observations as well, assuming polynomial-time access to the probability and value oracles of § 2.1 . This extends the PTAS guarantee established for the prophet secretary problem by Dütting et al. [15 ] to the Bayesian optimal stopping problem.
The rest of this section establishes Theorem 3. In § 3.1 , we present Algorithm 1 that can transform any competitive algorithm into an approximation algorithm with a strictly better approximation factor; we call this process “Primal Improvement.” § 3.2 develops the Primal-Dual Improvement subroutine which leads to Algorithm 2 that repeatedly uses Algorithm 1 and is the main construction underlying Theorem 3. Next, Section 3.3 explains how to implement Algorithm 2 in polynomial time. Finally, § 3.4 analyzes our final algorithm, thereby establishing Theorem 3.
Warm-up: Approximation Algorithms via Primal Improvement
In this subsection, we present Algorithm 1, a central piece of our overall approximation scheme. As inputs to Algorithm 1, we assume having access to a dual martingale ( Z t ) t (Z_t)_t ( Z t ) t and a baseline algorithm A b a s e A_{\mathrm{base}} A base that is known to be α \alpha α -competitive against ( Z t ) (Z_t) ( Z t ) . Then, Algorithm 1 converts these two inputs into a g ( α ) g(\alpha) g ( α ) -approximation of ON, where g ( x ) = 1 / ( 1 + ln ( 1 / x ) ) > x g(x) = 1/(1 + \ln(1/x)) > x g ( x ) = 1/ ( 1 + ln ( 1/ x )) > x , and provides a performance guarantee strictly better than α \alpha α .
Proposition 1. Consider a Bayesian optimal stopping problem instance. Given a dual martingale ( Z t ) t (Z_t)_t ( Z t ) t and a polynomial-time algorithm A b a s e A_{\mathrm{base}} A base that is α \alpha α -competitive against Z t Z_t Z t (with α ∈ ( 0 , 1 ) \alpha\in(0,1) α ∈ ( 0 , 1 ) ), Algorithm 1 returns a 1 / ( 1 + ln ( 1 / α ) ) 1/(1+\ln(1/\alpha)) 1/ ( 1 + ln ( 1/ α )) -approximation against ON.
While the base algorithm A b a s e A_{\mathrm{base}} A base is itself an α \alpha α -approximation, we can leverage it to obtain a better approximation factor; the multiplicative improvement grows as the baseline performance factor α \alpha α decreases (see Figure 2 in Appendix § 10 ).
Figure 2. Baseline and boosted approximation factors. The boosted factor is strictly larger for 0 < α < 1 0 < \alpha< 1 0 < α < 1 , and both equal 1 at α = 1 \alpha= 1 α = 1 . The multiplicative improvement grows as α \alpha α decreases.
Before presenting the algorithm, we give three immediate implications of Proposition 1 for our models of IID, NON-IID, and CORREL. To use Proposition 1, we must specify a dual martingale and a corresponding α \alpha α -competitive baseline algorithm. Let M = max t ∈ [ n ] X t M = \max_{t\in[n]} X_t M = max t ∈ [ n ] X t be the random variable corresponding to the offline optimum, and let Z t = E [ M ∣ F t ] Z_t = \mathbb{E}[M \mid\mathcal{F}_t] Z t = E [ M ∣ F t ] be its corresponding Doob’s martingale. We use ( Z t ) t (Z_t)_t ( Z t ) t as our dual martingale.
We now specify a baseline competitive algorithm in each model. For the IID model, we use the classical secretary algorithm of Dynkin [17 ] , which is 1 / e 1/e 1/ e -competitive against M M M . For the NON-IID model, we can determine the world h ∗ = arg max h ∈ [ K ] π h E [ O F F ∣ H = h ] h^* = \arg\max_{h\in[K]} \pi_h\mathbb{E}[\mathrm{OFF} \mid H = h] h ∗ = arg max h ∈ [ K ] π h E [ OFF ∣ H = h ] that has the highest contribution to OFF. Then, our baseline algorithm is one that assumes H = h ∗ H = h^* H = h ∗ , and uses the corresponding threshold-based prophet 1 / 2 1/2 1/2 -competitive algorithm for world h ∗ h^* h ∗ ; it follows that this baseline algorithm is 1 / ( 2 K ) 1/(2K) 1/ ( 2 K ) -competitive for the NON-IID Bayesian problem. Finally, for the CORREL model, we pick a timestep t ∗ t^* t ∗ uniformly at random from { 1 , ⋯ , n } \{1,\cdots,n\} { 1 , ⋯ , n } , and accept the observation at time t ∗ t^* t ∗ ; this baseline algorithm chooses the maximum observation with probability 1 / n 1/n 1/ n and is ( 1 / n ) (1/n) ( 1/ n ) -competitive.
Applying Proposition 1 by specifying the above baseline algorithms and the dual martingale ( Z t ) (Z_t) ( Z t ) , the following corollary ensues:
Corollary 1. The Bayesian optimal stopping problem admits a polynomial-time algorithm with approximation factor
{ 1 2 , in the IID model ; 1 1 + ln ( 2 K ) , in the NON-IID model ; 1 1 + ln n , in the CORREL model . \begin{cases}
\frac{1}{2}, & \text{in the IID model};\\
\frac{1}{1+\ln(2K)}, & \text{in the NON-IID model};\\
\frac{1}{1+\ln n}, & \text{in the CORREL model}.
\end{cases} ⎩ ⎨ ⎧ 2 1 , 1 + l n ( 2 K ) 1 , 1 + l n n 1 , in the IID model ; in the NON-IID model ; in the CORREL model .
Algorithm
We now present the details of Algorithm 1. In addition to the baseline algorithm A b a s e \mathcal{A}_{\mathrm{base}} A base , we also use another “dual-threshold” subroutine called A t h r \mathcal{A}_{\mathrm{thr}} A thr . Consequently, with probability γ = ( 1 + ln ( 1 / α ) ) − 1 \gamma= (1+\ln(1/\alpha))^{-1} γ = ( 1 + ln ( 1/ α ) ) − 1 , we run the baseline algorithm and with the remaining probability, we run A t h r \mathcal{A}_{\mathrm{thr}} A thr . The subroutine A t h r \mathcal{A}_{\mathrm{thr}} A thr , explained in Line 5-9, uses the dual martingale ( Z t ) (Z_t) ( Z t ) as thresholds. Concretely, before any observations, A t h r \mathcal{A}_{\mathrm{thr}} A thr draws a random cutoff Q ∈ [ α , 1 ] Q \in[\alpha,1] Q ∈ [ α , 1 ] with density f Q ( q ) ∝ 1 / q f_Q(q) \propto1/q f Q ( q ) ∝ 1/ q . Next, the subroutine accepts the first arriving item X t X_t X t that satisfies X t ≥ Q Z t X_t \ge QZ_t X t ≥ Q Z t . In other words, Q Q Q is the threshold on X t / Z t X_t/Z_t X t / Z t for accepting a newly arriving item.
Notice that our current definition for Z t Z_t Z t is based on the hindsight optimal M M M , which makes the martingale easily computable for every history h t h_t h t using the value oracle assumed in § 2.1 . Nevertheless, we present Algorithm 1 in a more general form in which Z t Z_t Z t may not be possible to evaluate exactly (in polynomial time) and we must approximate it. This more general form will be used in Section 3.3 to develop approximation schemes.
ALGORITHM 1: Primal improvement
Input: (i) A dual martingale ( Z t ) t (Z_t)_t ( Z t ) t ; (ii) An α \alpha α -competitive algorithm A \mathcal{A} A against ( Z t ) t (Z_t)_t ( Z t ) t
Set γ = 1 1 + ln ( 1 / α ) \gamma= \frac{1}{1+\ln(1/\alpha)} γ = 1 + l n ( 1/ α ) 1
With probability γ \gamma γ , run A \mathcal{A} A
With the remaining probability 1 − γ 1-\gamma 1 − γ , run the following algorithm A t h r \mathcal{A}_{\mathrm{thr}} A thr :
Draw Q ∈ [ α , 1 ] Q \in[\alpha,1] Q ∈ [ α , 1 ] with density f ( q ) = 1 q ln ( 1 / α ) f(q)=\frac{1}{q\ln(1/\alpha)} f ( q ) = q l n ( 1/ α ) 1
for all times t = 1 , ⋯ , n t=1,\cdots,n t = 1 , ⋯ , n do
Let h t h_t h t be the history at time t t t
Using fresh randomness, compute L t ( h t ) L_t(h_t) L t ( h t ) such that L t ( h t ) Z t ( h t ) ∈ [ 1 − ε , 1 ] \frac{L_t(h_t)}{Z_t(h_t)}\in[1-\varepsilon,1] Z t ( h t ) L t ( h t ) ∈ [ 1 − ε , 1 ] with probability at least 1 − ε / n 1-\varepsilon/n 1 − ε / n . // A Monte Carlo estimate, as in Lemma 4
If X t ≥ Q L t X_t\ge QL_t X t ≥ Q L t , accept X t X_t X t and terminate
Intuitively, the two subalgorithms A b a s e \mathcal{A}_{\mathrm{base}} A base and A t h r \mathcal{A}_{\mathrm{thr}} A thr extract complementary parts of the optimal reward X τ ∗ X_{\tau^*} X τ ∗ , where τ ∗ \tau^* τ ∗ is the stopping time corresponding to the optimal online algorithm. Writing the classical base value and surplus decomposition of the rewards [28 ] :
X τ ∗ ≤ α Z τ ∗ ⏟ base value + { X τ ∗ − α Z τ ∗ } + ⏟ surplus , X_{\tau^*}\le\underbrace{\alpha Z_{\tau^*}}_{\text{base value}}+\underbrace{\{X_{\tau^*}-\alpha Z_{\tau^*}\}_+}_{\text{surplus}}, X τ ∗ ≤ base value α Z τ ∗ + surplus { X τ ∗ − α Z τ ∗ } + ,
the subroutine A b a s e \mathcal{A}_{\mathrm{base}} A base captures a reward of α Z τ ∗ \alpha Z_{\tau^*} α Z τ ∗ , whereas, as will be shown, A t h r \mathcal{A}_{\mathrm{thr}} A thr roughly captures a fraction of { X τ ∗ − α Z τ ∗ } + \{X_{\tau^*}-\alpha Z_{\tau^*}\}_+ { X τ ∗ − α Z τ ∗ } + . The challenge, however, is that it is not a priori known which component is larger, which is why we randomize between the two subalgorithms.
While A b a s e \mathcal{A}_{\mathrm{base}} A base may not necessarily use any Bayesian information, A t h r \mathcal{A}_{\mathrm{thr}} A thr crucially leverages the Bayesian structure of our problem. The dual martingale Z t Z_t Z t is an approximation (upper bound) to the Snell envelope (1) . Suppose that at some history h t h_t h t , we have Z t ( h t ) = S t ( h t ) Z_t(h_t)=S_t(h_t) Z t ( h t ) = S t ( h t ) . Then it is clear that we should accept X t X_t X t only if it exceeds Z t ( h t ) Z_t(h_t) Z t ( h t ) —corresponding to deterministically setting Q = 1 Q=1 Q = 1 . However, because the actual value of Z t Z_t Z t may differ from S t S_t S t , we use a more permissive threshold Q ∈ [ 0 , 1 ] Q\in[0,1] Q ∈ [ 0 , 1 ] on X t / Z t X_t/Z_t X t / Z t .
The specific randomization of Q Q Q warrants some explanation. To simplify the notation, consider some fixed x = X τ ∗ x=X_{\tau^*} x = X τ ∗ and z = Z τ ∗ z=Z_{\tau^*} z = Z τ ∗ . Our goal is to obtain a reward close to x x x , which can be written in the layer cake representation as x = ∫ 0 1 z ⋅ I [ x ≥ q z ] d q x=\int_0^1 z\cdot\mathbb{I}[x\ge qz]\,\mathrm{d}q x = ∫ 0 1 z ⋅ I [ x ≥ q z ] d q . When A t h r \mathcal{A}_{\mathrm{thr}} A thr accepts an item X t X_t X t , it is guaranteed that X t ≥ q Z t X_t\ge qZ_t X t ≥ q Z t , so we can only be sure of obtaining a reward of at least q Z t qZ_t q Z t ; thus, our collected reward can be lower bounded by q Z t ⋅ I [ X t ≥ q Z t ] qZ_t\cdot\mathbb{I}[X_t\ge qZ_t] q Z t ⋅ I [ X t ≥ q Z t ] . Assume, for the moment, that t = τ ∗ t=\tau^* t = τ ∗ and Z t = z Z_t=z Z t = z . Then, choosing Q ∼ f ( q ) Q\sim f(q) Q ∼ f ( q ) would yield a reward of ∫ 0 1 q f ( q ) z ⋅ I [ x ≥ q z ] \int_0^1 qf(q)z\cdot\mathbb{I}[x\ge qz] ∫ 0 1 q f ( q ) z ⋅ I [ x ≥ q z ] . For this reward to be a constant-factor approximation of x x x , we thus set f ( q ) ∝ 1 / q f(q)\propto1/q f ( q ) ∝ 1/ q ; with appropriate renormalization, this intuition drives our approximation factor. Given that ( Z t ) t (Z_t)_t ( Z t ) t is a martingale, its expectation remains constant, implying E [ Z t ] = z \mathbb{E}[Z_t]=z E [ Z t ] = z in general. The analysis in the next section formalizes this argument and proves that Z t Z_t Z t can be replaced with Z τ ∗ Z_{\tau^*} Z τ ∗ to obtain an approximation factor analysis.
Analysis of the Primal Algorithm.
We will next prove Proposition 1, where we recall that we assume Z t Z_t Z t itself is used instead of the approximation L t L_t L t in Algorithm 1. The argument follows from a careful analysis of A t h r \mathcal{A}_{\mathrm{thr}} A thr , which relies on the evolution of the process ( Z t ) t (Z_t)_t ( Z t ) t . For a fixed q ∈ [ 0 , 1 ] q \in[0,1] q ∈ [ 0 , 1 ] , let r q r_q r q be the expected reward of A t h r \mathcal{A}_{\mathrm{thr}} A thr when Q = q Q=q Q = q and L t = Z t L_t=Z_t L t = Z t at every time t ∈ [ n ] t \in[n] t ∈ [ n ] , and recall that τ ⋆ \tau^\star τ ⋆ is the stopping time of ON. We can now lower bound r q r_q r q as follows.
Lemma 1. For every fixed q ∈ [ 0 , 1 ] q \in[0,1] q ∈ [ 0 , 1 ] , we have r q ≥ q ⋅ E [ Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ] ] r_q \ge q \cdot\mathbb{E}[Z_{\tau^\star} \cdot\mathbb{I}[X_{\tau^\star} \ge qZ_{\tau^\star}]] r q ≥ q ⋅ E [ Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ]] .
Before proving this lemma, we leverage it to establish Proposition 1.
Proof of Proposition 1. Clearly, τ ⋆ \tau^\star τ ⋆ is always at most n n n , and thus it is bounded almost surely. Consequently, Doob’s Optional Sampling Theorem implies E [ Z τ ⋆ ] = E [ Z 1 ] \mathbb{E}[Z_{\tau^\star}] = \mathbb{E}[Z_1] E [ Z τ ⋆ ] = E [ Z 1 ] . Thus, A b a s e \mathcal{A}_{\mathrm{base}} A base has an expected reward of at least α ⋅ E [ Z 1 ] = α ⋅ E [ Z τ ⋆ ] \alpha\cdot\mathbb{E}[Z_1] = \alpha\cdot\mathbb{E}[Z_{\tau^\star}] α ⋅ E [ Z 1 ] = α ⋅ E [ Z τ ⋆ ] .
Recall that Algorithm 1 chooses A t h r \mathcal{A}_{\mathrm{thr}} A thr using a parameter Q ∈ [ α , 1 ] Q \in[\alpha,1] Q ∈ [ α , 1 ] with density f ( q ) = 1 q ln ( 1 / α ) f(q) = \frac{1}{q\ln(1/\alpha)} f ( q ) = q l n ( 1/ α ) 1 . We can thus lower bound the expected reward of Algorithm 1 by
γ α ⋅ E [ Z τ ⋆ ] + ( 1 − γ ) ∫ α 1 r q f ( q ) d q = γ α ⋅ E [ Z τ ⋆ ] + 1 − γ ln ( 1 / α ) ∫ α 1 r q q d q ≥ ( i ) γ α ⋅ E [ Z τ ⋆ ] + 1 − γ ln ( 1 / α ) ∫ α 1 E [ Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ] ] d q = γ α ⋅ E [ Z τ ⋆ ] + γ ∫ α 1 E [ Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ] ] d q = ( i i ) E [ γ α Z τ ⋆ + γ ∫ α 1 Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ] d q ] , (2) \begin{aligned}
\gamma\alpha\cdot\mathbb{E}[Z_{\tau^\star}] + (1-\gamma)\int_{\alpha}^{1} r_q f(q)\,dq
&= \gamma\alpha\cdot\mathbb{E}[Z_{\tau^\star}] + \frac{1-\gamma}{\ln(1/\alpha)}\int_{\alpha}^{1} \frac{r_q}{q}\,dq \\
&\mathrel{\underset{(i)}{\ge}} \gamma\alpha\cdot\mathbb{E}[Z_{\tau^\star}] + \frac{1-\gamma}{\ln(1/\alpha)}\int_{\alpha}^{1} \mathbb{E}[Z_{\tau^\star}\cdot\mathbb{I}[X_{\tau^\star}\ge qZ_{\tau^\star}]]\,dq \\
&= \gamma\alpha\cdot\mathbb{E}[Z_{\tau^\star}] + \gamma\int_{\alpha}^{1} \mathbb{E}[Z_{\tau^\star}\cdot\mathbb{I}[X_{\tau^\star}\ge qZ_{\tau^\star}]]\,dq \\
&\mathrel{\underset{(ii)}{=}} \mathbb{E}\left[\gamma\alpha Z_{\tau^\star}+\gamma\int_{\alpha}^{1}Z_{\tau^\star}\cdot\mathbb{I}[X_{\tau^\star}\ge qZ_{\tau^\star}]\,dq\right], \tag*{(2)}
\end{aligned} γ α ⋅ E [ Z τ ⋆ ] + ( 1 − γ ) ∫ α 1 r q f ( q ) d q = γ α ⋅ E [ Z τ ⋆ ] + ln ( 1/ α ) 1 − γ ∫ α 1 q r q d q ( i ) ≥ γ α ⋅ E [ Z τ ⋆ ] + ln ( 1/ α ) 1 − γ ∫ α 1 E [ Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ]] d q = γ α ⋅ E [ Z τ ⋆ ] + γ ∫ α 1 E [ Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ]] d q ( ii ) = E [ γ α Z τ ⋆ + γ ∫ α 1 Z τ ⋆ ⋅ I [ X τ ⋆ ≥ q Z τ ⋆ ] d q ] , (2)
where ( i ) (i) ( i ) uses Lemma 1, and ( i i ) (ii) ( ii ) uses linearity of expectation.
Now, notice that for values 0 ≤ x ≤ z 0 \le x \le z 0 ≤ x ≤ z , a simple integral derivation gives the layer cake representation
z ∫ α 1 I [ x ≥ q z ] d q = { x − α z } + . z\int_{\alpha}^{1}\mathbb{I}[x\ge qz]\,dq=\{x-\alpha z\}_{+}. z ∫ α 1 I [ x ≥ q z ] d q = { x − α z } + .
Thus, because Z τ ⋆ ≥ X τ ⋆ Z_{\tau^\star}\ge X_{\tau^\star} Z τ ⋆ ≥ X τ ⋆ almost surely, (2) is equal to
E [ γ α Z τ ⋆ + γ { X τ ⋆ − α Z τ ⋆ } + ] = E [ max { γ X τ ⋆ , γ α Z τ ⋆ } ] ≥ γ E [ X τ ⋆ ] = γ ⋅ O N = 1 1 + ln ( 1 / α ) ⋅ O N , (3) \begin{aligned}
\mathbb{E}\left[\gamma\alpha Z_{\tau^\star}+\gamma\{X_{\tau^\star}-\alpha Z_{\tau^\star}\}_{+}\right]=\mathbb{E}\left[\max\{\gamma X_{\tau^\star},\gamma\alpha Z_{\tau^\star}\}\right] \\
&\ge\gamma\mathbb{E}[X_{\tau^\star}]=\gamma\cdot\mathrm{ON}=\frac{1}{1+\ln(1/\alpha)}\cdot\mathrm{ON}, \tag*{(3)}
\end{aligned} E [ γ α Z τ ⋆ + γ { X τ ⋆ − α Z τ ⋆ } + ] = E [ max { γ X τ ⋆ , γ α Z τ ⋆ } ] ≥ γ E [ X τ ⋆ ] = γ ⋅ ON = 1 + ln ( 1/ α ) 1 ⋅ ON , (3)
proving that Algorithm 1 is a 1 1 + ln ( 1 / α ) \frac{1}{1+\ln(1/\alpha)} 1 + l n ( 1/ α ) 1 -approximation and the proposition is established. ■
It remains to prove Lemma 1.
Proof of Lemma 1. For every stopping time σ ≤ n \sigma\le n σ ≤ n , Doob’s Optional Sampling implies E [ Z σ ] = E [ Z 1 ] \mathbb{E}[Z_\sigma]=\mathbb{E}[Z_1] E [ Z σ ] = E [ Z 1 ] . Consider a coupling of the optimal stopping rule τ ⋆ \tau^\star τ ⋆ and A t h r \mathcal{A}_{\mathrm{thr}} A thr with parameter Q = q Q=q Q = q , in which H H H and the values X 1 , … , X n X_1,\ldots,X_n X 1 , … , X n are shared. Define τ q = inf { t : X t ≥ q Z t } \tau_q=\inf\{t:X_t\ge qZ_t\} τ q = inf { t : X t ≥ q Z t } to be the stopping time of A t h r \mathcal{A}_{\mathrm{thr}} A thr , where inf ∅ = + ∞ \inf\varnothing=+\infty inf ∅ = + ∞ , and set X τ q = Z τ q = 0 X_{\tau_q}=Z_{\tau_q}=0 X τ q = Z τ q = 0 on { τ q = ∞ } \{\tau_q=\infty\} { τ q = ∞ } . Let E = { τ q ≤ τ ⋆ } \mathcal{E}=\{\tau_q\le\tau^\star\} E = { τ q ≤ τ ⋆ } be the event that A t h r \mathcal{A}_{\mathrm{thr}} A thr stops no later than ON. Now, apply Doob’s Optional Sampling Theorem to the bounded stopping time τ = τ q ∧ τ ⋆ \tau=\tau_q\wedge\tau^\star τ = τ q ∧ τ ⋆ :
E [ Z τ ] = E [ Z τ 1 [ E ] ] + E [ Z τ 1 [ E c ] ] = E [ Z τ q 1 [ E ] ] + E [ Z τ ⋆ 1 [ E c ] ] . (4) \mathbb{E}[Z_\tau]=\mathbb{E}[Z_\tau\mathbb{1}[\mathcal{E}]]+\mathbb{E}[Z_\tau\mathbb{1}[\mathcal{E}^{c}]]=\mathbb{E}[Z_{\tau_q}\mathbb{1}[\mathcal{E}]]+\mathbb{E}[Z_{\tau^\star}\mathbb{1}[\mathcal{E}^{c}]]. \tag*{(4)} E [ Z τ ] = E [ Z τ 1 [ E ]] + E [ Z τ 1 [ E c ]] = E [ Z τ q 1 [ E ]] + E [ Z τ ⋆ 1 [ E c ]] . (4)
Similarly, we can use the Optional Sampling Theorem for the bounded stopping time τ ⋆ \tau^\star τ ⋆ :
E [ Z τ ⋆ ] = E [ Z τ ⋆ 1 [ E ] ] + E [ Z τ ⋆ 1 [ E c ] ] . (5) \mathbb{E}[Z_{\tau^\star}]=\mathbb{E}[Z_{\tau^\star}\mathbb{1}[\mathcal{E}]]+\mathbb{E}[Z_{\tau^\star}\mathbb{1}[\mathcal{E}^{c}]]. \tag*{(5)} E [ Z τ ⋆ ] = E [ Z τ ⋆ 1 [ E ]] + E [ Z τ ⋆ 1 [ E c ]] . (5)
Observing E [ Z τ ] = E [ Z τ ⋆ ] = E [ Z 1 ] \mathbb{E}[Z_\tau]=\mathbb{E}[Z_{\tau^\star}]=\mathbb{E}[Z_1] E [ Z τ ] = E [ Z τ ⋆ ] = E [ Z 1 ] and combining (4) and (5) gives
E [ Z τ ⋆ 1 [ E ] ] = E [ Z τ q 1 [ E ] ] . (6) \mathbb{E}[Z_{\tau^\star}\mathbb{1}[\mathcal{E}]]=\mathbb{E}[Z_{\tau_q}\mathbb{1}[\mathcal{E}]]. \tag*{(6)} E [ Z τ ⋆ 1 [ E ]] = E [ Z τ q 1 [ E ]] . (6)
On E \mathcal{E} E , we have τ q ≤ n \tau_q\le n τ q ≤ n and therefore
X τ q 1 [ E ] ≥ q Z τ q 1 [ E ] almost surely . (7) X_{\tau_q}\mathbb{1}[\mathcal{E}]\ge qZ_{\tau_q}\mathbb{1}[\mathcal{E}]\quad\text{almost surely}. \tag*{(7)} X τ q 1 [ E ] ≥ q Z τ q 1 [ E ] almost surely . (7)
On E c \mathcal{E}^{c} E c , the reward of A t h r \mathcal{A}_{\mathrm{thr}} A thr is nonnegative. Therefore, (6) and (7) imply
r q ≥ E [ X τ q 1 [ E ] ] ≥ q E [ Z τ q 1 [ E ] ] = q E [ Z τ ⋆ 1 [ E ] ] ≥ q E [ Z τ ⋆ 1 [ X τ ⋆ ≥ q Z τ ⋆ ] ] . r_q\ge\mathbb{E}[X_{\tau_q}\mathbb{1}[\mathcal{E}]]\ge q\mathbb{E}[Z_{\tau_q}\mathbb{1}[\mathcal{E}]]=q\mathbb{E}[Z_{\tau^\star}\mathbb{1}[\mathcal{E}]]\ge q\mathbb{E}[Z_{\tau^\star}\mathbb{1}[X_{\tau^\star}\ge qZ_{\tau^\star}]]. r q ≥ E [ X τ q 1 [ E ]] ≥ q E [ Z τ q 1 [ E ]] = q E [ Z τ ⋆ 1 [ E ]] ≥ q E [ Z τ ⋆ 1 [ X τ ⋆ ≥ q Z τ ⋆ ]] .
The last inequality follows from { X τ ⋆ ≥ q Z τ ⋆ } ⊆ E \{X_{\tau^\star}\ge qZ_{\tau^\star}\}\subseteq\mathcal{E} { X τ ⋆ ≥ q Z τ ⋆ } ⊆ E . Indeed, if the threshold condition holds at τ ⋆ \tau^\star τ ⋆ , then A t h r \mathcal{A}_{\mathrm{thr}} A thr stops no later than τ ⋆ \tau^\star τ ⋆ . The proof is now complete.
Approximation Scheme via Iterative Primal-Dual Improvement
We now turn to the main construction behind Theorem 3. The construction builds on a key observation from Algorithm 1: the martingale ( Z t ) t (Z_t)_t ( Z t ) t need not be the Doob martingale generated by the offline benchmark max t ∈ [ n ] X t \max_{t\in[n]}X_t max t ∈ [ n ] X t . Rather, it suffices to have some dual martingale ( Z t ) t (Z_t)_t ( Z t ) t and a corresponding α \alpha α -competitive baseline algorithm A \mathcal{A} A .
While Algorithm 1 improves the approximation ratio against ON, one cannot simply run it iteratively. The reason is that the next invocation requires an improved baseline competitive algorithm against a dual martingale, but the algorithm itself does not provide such martingale. We therefore need to improve the primal algorithm in tandem with shrinking its dual benchmark, preserving the invariant needed for the next iteration. The Primal-Dual Improvement subroutine does exactly this. Given a dual certificate M M M and an algorithm A \mathcal{A} A known to be α \alpha α -competitive against it, Primal-Dual Improvement yields a tighter dual certificate M + M^{+} M + and a new primal algorithm A + \mathcal{A}^{+} A + that is α + \alpha^{+} α + -competitive against it, with a strictly better competitiveness factor α + > α \alpha^{+}>\alpha α + > α .
Primal-Dual Improvement
Input. A dual certificate M M M and its Doob’s martingale Z t = E [ M ∣ F t ] Z_t = \mathbb{E}[M \mid\mathcal{F}_t] Z t = E [ M ∣ F t ] ; an algorithm A \mathcal{A} A that is α \alpha α -competitive against ( Z t ) t (Z_t)_t ( Z t ) t
Primal update. Apply Algorithm 1 to α \alpha α , A \mathcal{A} A , and ( Z t ) t (Z_t)_t ( Z t ) t , to obtain A + \mathcal{A}^{+} A + . Set α + = α 1 + ln ( 1 / α ) \alpha^{+} = \frac{\alpha}{1+\ln(1/\alpha)} α + = 1 + l n ( 1/ α ) α .
Dual update. Define, on each sample path,
ρ = max t ∈ [ n ] X t Z t , M + = M max { ρ , α } , Z t + = E [ M + ∣ F t ] . \rho= \max_{t \in[n]} \frac{X_t}{Z_t}, \qquad M^{+} = M\max\{\rho,\alpha\}, \qquad Z_t^{+} = \mathbb{E}[M^{+} \mid\mathcal{F}_t]. ρ = t ∈ [ n ] max Z t X t , M + = M max { ρ , α } , Z t + = E [ M + ∣ F t ] .
Output. The triple ( M + , A + , α + ) (M^{+}, \mathcal{A}^{+}, \alpha^{+}) ( M + , A + , α + )
Note that our dual update is valid:
Lemma 2. The process ( Z t + ) t (Z_t^{+})_t ( Z t + ) t is a dual martingale.
Proof. We have
Z t + = E [ M + ∣ F t ] ≥ E [ M max t ′ ∈ [ n ] X t ′ Z t ′ | F t ] ≥ E [ M X t Z t | F t ] = X t Z t E [ M ∣ F t ] = X t Z t Z t = X t . Z_t^{+} = \mathbb{E}[M^{+} \mid\mathcal{F}_t] \geq\mathbb{E}\left[M\max_{t' \in[n]} \frac{X_{t'}}{Z_{t'}} \,\middle|\, \mathcal{F}_t\right] \geq\mathbb{E}\left[M\frac{X_t}{Z_t} \,\middle|\, \mathcal{F}_t\right] = \frac{X_t}{Z_t}\mathbb{E}[M \mid\mathcal{F}_t] = \frac{X_t}{Z_t}Z_t = X_t. Z t + = E [ M + ∣ F t ] ≥ E [ M t ′ ∈ [ n ] max Z t ′ X t ′ F t ] ≥ E [ M Z t X t F t ] = Z t X t E [ M ∣ F t ] = Z t X t Z t = X t .
While Proposition 1 implies that algorithm A + \mathcal{A}^{+} A + is an α + \alpha^{+} α + -approximation, we can show a stronger result:
Lemma 3. The martingale ( Z t + ) t (Z_t^{+})_t ( Z t + ) t is a dual martingale, and the output algorithm A + \mathcal{A}^{+} A + is α + \alpha^{+} α + -competitive against ( Z t + ) t (Z_t^{+})_t ( Z t + ) t .
Since a stronger version of this lemma will be established in the proof of Theorem 3, we do not repeat it here. A consequence of this lemma is that we can repeatedly invoke the Primal-Dual Improvement subroutine, as Algorithm 2 formalizes.
ALGORITHM 2: Iterative primal-dual improvement
Input: An α \alpha α -competitive algorithm A \mathcal{A} A with known α ∈ ( 0 , 1 ) \alpha\in(0,1) α ∈ ( 0 , 1 ) ; an iteration count J J J
Let M 0 ← max t ∈ [ n ] X t M_0 \leftarrow\max_{t \in[n]} X_t M 0 ← max t ∈ [ n ] X t be the terminal random variable for the hindsight optimal OFF.
Initialize A 0 ← A \mathcal{A}_0 \leftarrow\mathcal{A} A 0 ← A , α 0 ← α \alpha_0 \leftarrow\alpha α 0 ← α , and W 0 ← 1 W_0 \leftarrow1 W 0 ← 1 .
for all j = 0 , … , J − 1 j = 0,\ldots,J-1 j = 0 , … , J − 1 do
Let ( M + , A + , α + ) (M^{+},\mathcal{A}^{+},\alpha^{+}) ( M + , A + , α + ) be the output of Primal-Dual Improvement with input ( M j , A j , α j ) (M_j,\mathcal{A}_j,\alpha_j) ( M j , A j , α j )
Set M j + 1 ← M + , A j + 1 ← A + , α j + 1 ← α + M_{j+1} \leftarrow M^{+},\mathcal{A}_{j+1} \leftarrow\mathcal{A}^{+},\alpha_{j+1} \leftarrow\alpha^{+} M j + 1 ← M + , A j + 1 ← A + , α j + 1 ← α +
Return A J \mathcal{A}_J A J
The approximation scheme of Theorem 3 from Algorithm 2. The output A J \mathcal{A}_J A J is our final online algorithm for Theorem 3. The recursive construction defines a mixture of the baseline policy and dual-threshold policies. Concretely, unrolling the recursion provides the following alternative description of A J \mathcal{A}_J A J : We first obtain dual certificates M 0 , M 1 , ⋯ , M J − 1 M_0,M_1,\cdots,M_{J-1} M 0 , M 1 , ⋯ , M J − 1 . Then, we randomly pick one of these dual certificates to use for our stopping decisions. We select M j M_j M j (for 0 ≤ j < J 0 \leq j < J 0 ≤ j < J ) with probability ( 1 − α j + 1 ) ∏ ℓ = j + 2 J α ℓ (1-\alpha_{j+1})\prod_{\ell=j+2}^{J}\alpha_\ell ( 1 − α j + 1 ) ∏ ℓ = j + 2 J α ℓ and we choose the baseline with the remaining probability ∏ ℓ = 1 J α ℓ \prod_{\ell=1}^{J}\alpha_\ell ∏ ℓ = 1 J α ℓ . We then implement the subroutine A t h r \mathcal{A}_{\mathrm{thr}} A thr (in Algorithm 1) with Q ∈ [ α j , 1 ] Q \in[\alpha_j,1] Q ∈ [ α j , 1 ] and dual certificate M j M_j M j . Otherwise if the baseline is chosen, we simply use the baseline algorithm A 0 \mathcal{A}_0 A 0 . It is straightforward to see that this algorithm is equivalent to A j \mathcal{A}_j A j as the output of Algorithm 2.
For now, we are not concerned with the runtime of Algorithm 2. The next subsection explains how this algorithm can be (approximately) implemented efficiently. In the rest of this subsection, we provide the intuition behind Primal-Dual Improvement and Algorithm 2.
Intuition behind Algorithm 2. The central invariant behind our design is the dual identity
E [ M j + 1 ] = α j ⋅ E [ M j ] + ∫ α j 1 E [ M j ⋅ I [ ρ j ≥ q ] ] d q , \mathbb{E}[M_{j+1}] = \alpha_j \cdot\mathbb{E}[M_j] + \int_{\alpha_j}^{1} \mathbb{E}[M_j \cdot\mathbb{I}[\rho_j \ge q]]\,dq, E [ M j + 1 ] = α j ⋅ E [ M j ] + ∫ α j 1 E [ M j ⋅ I [ ρ j ≥ q ]] d q ,
which will be proved in the proof of Theorem 3 in § 3.4 .
The reward of our updated primal algorithm is closely tied to (Dual-Identity): On the one hand, when Algorithm 1 is ran on A j \mathcal{A}_j A j and M j M_j M j —more precisely, on its associated Doob’s martingale ( Z t ( j ) ) t (Z_t^{(j)})_t ( Z t ( j ) ) t —the baseline algorithm A j \mathcal{A}_j A j has a reward of α j ⋅ E [ M j ] \alpha_j \cdot\mathbb{E}[M_j] α j ⋅ E [ M j ] . On the other hand, the dual-threshold algorithm A t h r \mathcal{A}_{\mathrm{thr}} A thr with Q = q Q=q Q = q obtains a reward r q r_q r q related to the second term in (Dual-Identity). Recall that τ q \tau_q τ q is the stopping time of A t h r \mathcal{A}_{\mathrm{thr}} A thr with Q = q Q=q Q = q . Suppose that Z t ( j ) Z_t^{(j)} Z t ( j ) can be exactly evaluated at every time. We thus have:
r q = ∑ t = 1 n E [ X t ⋅ I [ τ q = t ] ] ≥ q ⋅ ∑ t = 1 n E [ Z t ( j ) ⋅ I [ τ q = t ] ] = q ⋅ ∑ t = 1 n E [ E [ M j ∣ F t ] ⋅ I [ τ q = t ] ] = q ⋅ ∑ t = 1 n E [ M j ⋅ I [ τ q = t ] ] = q ⋅ E [ M j ⋅ I [ τ q ≤ n ] ] = q ⋅ E [ M j ⋅ I [ ρ j ≥ q ] ] . \begin{aligned}
r_q &= \sum_{t=1}^{n} \mathbb{E}\left[X_t \cdot\mathbb{I}[\tau_q=t]\right] \\
&\ge q \cdot\sum_{t=1}^{n} \mathbb{E}\left[Z_t^{(j)} \cdot\mathbb{I}[\tau_q=t]\right] \\
&= q \cdot\sum_{t=1}^{n} \mathbb{E}\left[\mathbb{E}[M_j \mid\mathcal{F}_t] \cdot\mathbb{I}[\tau_q=t]\right] \\
&= q \cdot\sum_{t=1}^{n} \mathbb{E}\left[M_j \cdot\mathbb{I}[\tau_q=t]\right] \\
&= q \cdot\mathbb{E}\left[M_j \cdot\mathbb{I}[\tau_q \le n]\right] = q \cdot\mathbb{E}\left[M_j \cdot\mathbb{I}[\rho_j \ge q]\right].
\end{aligned} r q = t = 1 ∑ n E [ X t ⋅ I [ τ q = t ] ] ≥ q ⋅ t = 1 ∑ n E [ Z t ( j ) ⋅ I [ τ q = t ] ] = q ⋅ t = 1 ∑ n E [ E [ M j ∣ F t ] ⋅ I [ τ q = t ] ] = q ⋅ t = 1 ∑ n E [ M j ⋅ I [ τ q = t ] ] = q ⋅ E [ M j ⋅ I [ τ q ≤ n ] ] = q ⋅ E [ M j ⋅ I [ ρ j ≥ q ] ] .
Consequently, choosing Q Q Q from [ α j , 1 ] [\alpha_j,1] [ α j , 1 ] with density f ( q ) ∝ 1 / q f(q) \propto1/q f ( q ) ∝ 1/ q would cancel out the q q q factors, yielding a reward proportional to the second term in (Dual-Identity).
Because ρ j ≤ 1 \rho_j \le1 ρ j ≤ 1 ,6 by iteratively using Primal-Dual Improvement, we obtain a sequence of dual certificate M 0 ≥ M 1 ≥ M 2 , ⋯ M_0 \ge M_1 \ge M_2, \cdots M 0 ≥ M 1 ≥ M 2 , ⋯ . We claim that this sequence converges to the optimal dual martingale
M ∗ = arg min terminal random variable M { E [ M ] : E [ M ∣ F t ] ≥ X t almost surely for every t ∈ [ n ] } . (8) M_* = \underset{\text{terminal random}\\\text{variable }M}{\arg\min}\ \left\{\mathbb{E}[M] : \mathbb{E}[M \mid\mathcal{F}_t] \ge X_t \text{ almost surely for every } t \in[n]\right\}. \tag*{(8)} M ∗ = terminal random variable M arg min { E [ M ] : E [ M ∣ F t ] ≥ X t almost surely for every t ∈ [ n ] } . (8)
As we will formally prove r ( A j ) ≥ α j ⋅ E [ M j ] ≥ α j ⋅ O P T r(\mathcal{A}_j) \ge\alpha_j \cdot\mathbb{E}[M_j] \ge\alpha_j \cdot\mathrm{OPT} r ( A j ) ≥ α j ⋅ E [ M j ] ≥ α j ⋅ OPT for every j j j , and because α j → 1 \alpha_j \to1 α j → 1 as j → ∞ j \to\infty j → ∞ , we infer that E [ M ∗ ] = lim j → ∞ E [ M j ] = O P T \mathbb{E}[M_*] = \lim_{j\to\infty}\mathbb{E}[M_j] = \mathrm{OPT} E [ M ∗ ] = lim j → ∞ E [ M j ] = OPT . In other words, the optimal dual martingale has the same expected value as the optimal online algorithm’s reward, which is the strong duality claimed in Section 2.2. This form of strong duality has been similarly established in the context of “information relaxation” methods for stochastic dynamic programming [6 ] .
Beyond the close connection of our primal guarantee and (Dual-Identity), a main motivation for our particular form of dual update is to be able to approximate the dual martingales efficiently. Indeed, finding the optimal dual certificate M ∗ M_* M ∗ in (8) is as hard as finding the optimum policy. Thus, we start with a feasible solution of the optimization problem in (8) —which is M 0 M_0 M 0 —and progressively refine it to get closer to M ∗ M_* M ∗ .
The update dual has a simple pathwise interpretation. Fix a time t t t . Since ρ j ≥ X t / Z t ( j ) \rho_j \ge X_t/Z_t^{(j)} ρ j ≥ X t / Z t ( j ) on every sample path, and X t / Z t ( j ) X_t/Z_t^{(j)} X t / Z t ( j ) is F t \mathcal{F}_t F t -measurable, we have
Z t ( j + 1 ) = E [ M j max { ρ j , α j } ∣ F t ] ≥ X t Z t ( j ) ⋅ E [ M j ∣ F t ] = X t . Z_t^{(j+1)} = \mathbb{E}\left[M_j \max\{\rho_j,\alpha_j\}\mid\mathcal{F}_t\right] \ge\frac{X_t}{Z_t^{(j)}}\cdot\mathbb{E}\left[M_j\mid\mathcal{F}_t\right] = X_t. Z t ( j + 1 ) = E [ M j max { ρ j , α j } ∣ F t ] ≥ Z t ( j ) X t ⋅ E [ M j ∣ F t ] = X t .
In other words, the dual feasibility constraints E [ M ∣ F t ] ≥ X t \mathbb{E}[M\mid\mathcal{F}_t]\ge X_t E [ M ∣ F t ] ≥ X t —which couple all sample paths sharing the same history—are guaranteed if, for each sample path ω \omega ω of the n n n -step trajectory, M ( ω ) M(\omega) M ( ω ) is scaled by a factor of at least max t X t ( ω ) / Z t ( j ) ( ω ) \max_t X_t(\omega)/Z_t^{(j)}(\omega) max t X t ( ω ) / Z t ( j ) ( ω ) , a condition that can be checked on each path in isolation. The factor ρ j ( ω ) \rho_j(\omega) ρ j ( ω ) is the smallest one satisfying this condition, and since ρ j ≤ 1 \rho_j\le1 ρ j ≤ 1 , the scaling can only shrink M j M_j M j . Because the condition is checked separately on each path, we may shrink M j ( ω ) M_j(\omega) M j ( ω ) on any subset of paths, or on all of them at once, without violating dual feasibility (see also Figure 1 for this intuition on the scenario tree).
!The pathwise dual update on the scenario tree. Panel (a), “Read one sample path,” shows Z 1 ( j ) ( h 1 ) = E [ M j ∣ h 1 ] Z_1^{(j)}(h_1)=\mathbb{E}[M_j\mid h_1] Z 1 ( j ) ( h 1 ) = E [ M j ∣ h 1 ] , Z 2 ( j ) ( h 2 ) = E [ M j ∣ h 2 ] Z_2^{(j)}(h_2)=\mathbb{E}[M_j\mid h_2] Z 2 ( j ) ( h 2 ) = E [ M j ∣ h 2 ] , M j ( ω ) M_j(\omega) M j ( ω ) , and ρ j ( ω ) = max t ∈ [ n ] X t ( ω ) Z t ( j ) ( ω ) \rho_j(\omega)=\max_{t\in[n]}\frac{X_t(\omega)}{Z_t^{(j)}(\omega)} ρ j ( ω ) = max t ∈ [ n ] Z t ( j ) ( ω ) X t ( ω ) . Panel (b), “Update that sample path,” shows Z 1 ( j + 1 ) ( h 1 ) = E [ M j + 1 ∣ h 1 ] Z_1^{(j+1)}(h_1)=\mathbb{E}[M_{j+1}\mid h_1] Z 1 ( j + 1 ) ( h 1 ) = E [ M j + 1 ∣ h 1 ] , Z 2 ( j + 1 ) ( h 2 ) = E [ M j + 1 ∣ h 2 ] Z_2^{(j+1)}(h_2)=\mathbb{E}[M_{j+1}\mid h_2] Z 2 ( j + 1 ) ( h 2 ) = E [ M j + 1 ∣ h 2 ] , M j + 1 ( ω ) M_{j+1}(\omega) M j + 1 ( ω ) , and M j + 1 ( ω ) = M j ( ω ) max { α j , ρ j ( ω ) } M_{j+1}(\omega)=M_j(\omega)\max\{\alpha_j,\rho_j(\omega)\} M j + 1 ( ω ) = M j ( ω ) max { α j , ρ j ( ω )} bbox=0.18,0.06,0.82,0.33
Figure 1. The pathwise dual update on the scenario tree
This pathwise structure is also what makes the update computable. Unrolling the recursion gives M j = M 0 ∏ ℓ < j max { ρ ℓ , α ℓ } M_j=M_0\prod_{\ell<j}\max\{\rho_\ell,\alpha_\ell\} M j = M 0 ∏ ℓ < j max { ρ ℓ , α ℓ } , so M j ( ω ) M_j(\omega) M j ( ω ) depends only on the path ω \omega ω itself and on the earlier martingales Z ( ℓ ) Z^{(\ell)} Z ( ℓ ) , ℓ < j \ell<j ℓ < j , evaluated at the n n n prefixes of ω . H e n c e , \omega. Hence, ω . H e n ce , Z_t^{(j)}(h_t)=\mathbb{E}[M_j\mid h_t]$ can be estimated by Monte Carlo: simulate continuations of h t h_t h t , and evaluate M j M_j M j on each simulated path, which in turn calls for estimates of Z ( j − 1 ) Z^{(j-1)} Z ( j − 1 ) along that path. For a fixed j j j , this recursion requires only n O ( j ) n^{O(j)} n O ( j ) simulated paths, rather than the exponentially many trajectories of the full scenario tree. By contrast, the optimal dual M ∗ M_* M ∗ in (8) , like the Snell envelope, is determined by backward induction over the entire tree and admits no such local description. Finally, we note that the floor at α j \alpha_j α j for defining ρ j \rho_j ρ j prevents the dual certificate from shrinking too aggressively, which is needed for efficient estimation via Monte Carlo simulation. Indeed, the normalized multiplier W j = ∏ ℓ < j max { ρ ℓ , α ℓ } W_j=\prod_{\ell<j}\max\{\rho_\ell,\alpha_\ell\} W j = ∏ ℓ < j max { ρ ℓ , α ℓ } lies between ∏ ℓ < j α ℓ \prod_{\ell<j}\alpha_\ell ∏ ℓ < j α ℓ and $1$ on every sample path. Under the importance-sampling measure introduced in the next subsection, we estimate the expectation of this bounded variable; the lower bound on its mean controls the number of samples needed for its relative accuracy.
We note that related dual shrinkage updates have been proposed in the applied probability literature on optimal stopping [8 ] and information relaxations [7 , 6 ] that have different forms (such as additive updates) or not been implemented in polynomial time.
Each node shows a certain history h t h_t h t , with the leaves being complete sample paths. The figure shows updating the dual value M j ( ω ) M_j(\omega) M j ( ω ) for the highlighted path ω \omega ω , while leaving the value of M j M_j M j the same for other sample paths; note that the algorithm defines the update rule for all sample paths simultaneously, in contrast with the figure. The update scales M j ( ω ) M_j(\omega) M j ( ω ) by max { α j , ρ j ( ω ) } \max\{\alpha_j,\rho_j(\omega)\} max { α j , ρ j ( ω )} , where ρ j ( ω ) = max t ∈ [ n ] X t ( ω ) / Z t ( j ) ( ω ) \rho_j(\omega)=\max_{t\in[n]}X_t(\omega)/Z_t^{(j)}(\omega) ρ j ( ω ) = max t ∈ [ n ] X t ( ω ) / Z t ( j ) ( ω ) and the circled node in panel (a) attains this maximum ratio. The shaded subtrees contain the continuations of histories h 1 h_1 h 1 and h 2 h_2 h 2 : their leaf sets are nested, illustrating the laminar structure of histories (any two such sets are nested or disjoint). The labels beside h 1 h_1 h 1 and h 2 h_2 h 2 give the corresponding conditional expectations: each is an average of the leaf values in its shaded subtree, weighted by their probabilities conditional on that history. In panel (b), only the highlighted leaf is updated; consequently, only internal values along its path to the root can change. These values are recomputed as conditional expectations of the updated certificate. The pathwise ratio bound ensures dual feasibility at these ancestors, while all other node values remain unchanged.
Remark 2. In light of the alternative description of A J \mathcal{A}_J A J provided after Algorithm 2, one may attempt to only use the final dual martingale M J M_J M J because it is the tightest martingale, i.e., M J ≤ ⋯ , M 0 M_J\le\cdots,M_0 M J ≤ ⋯ , M 0 almost surely. Interestingly, it seems non-trivial to obtain a similar performance only using M J M_J M J . One challenge is how to use M J M_J M J to make decisions; Algorithm 1 used the dual martingales via the threshold policy A t h r \mathcal{A}_{\mathrm{thr}} A thr . We now show that using M J M_J M J with A t h r \mathcal{A}_{\mathrm{thr}} A thr , our analysis leads to a worse approximation ratio than α J \alpha_J α J , which is proved for A J \mathcal{A}_J A J . Suppose that A t h r \mathcal{A}_{\mathrm{thr}} A thr draws Q ∈ [ a , 1 ] Q\in[a,1] Q ∈ [ a , 1 ] with density f Q ( s ) ∝ 1 / s f_Q(s)\propto1/s f Q ( s ) ∝ 1/ s and accepts X t X_t X t if and only if X t / E [ M J ∣ F t ] ≥ Q X_t/\mathbb{E}[M_J\mid\mathcal{F}_t]\ge Q X t / E [ M J ∣ F t ] ≥ Q , where a a a is a parameter of choice. Let this algorithm be called A ′ \mathcal{A}' A ′ .
Ignore the approximation error in computing the martingales and suppose that we can implement Primal-Dual Improvement exactly. Algorithm 2 gives A J \mathcal{A}_J A J with an approximation ratio of α J \alpha_J α J . Conversely, similar to the proof of Proposition 1, we can show
r ( A ′ ) O N ≥ E [ ( X τ ∗ − a Z τ ∗ ) + ] ln ( 1 / a ) ⋅ O N ≥ O N − a E [ M J ] ln ( 1 / a ) ⋅ O N . \frac{r(\mathcal{A}')}{\mathrm{ON}}\ge\frac{\mathbb{E}[(X_{\tau^*}-aZ_{\tau^*})_+]}{\ln(1/a)\cdot\mathrm{ON}}\ge\frac{\mathrm{ON}-a\mathbb{E}[M_J]}{\ln(1/a)\cdot\mathrm{ON}}. ON r ( A ′ ) ≥ ln ( 1/ a ) ⋅ ON E [( X τ ∗ − a Z τ ∗ ) + ] ≥ ln ( 1/ a ) ⋅ ON ON − a E [ M J ] .
Let β J = O N / E [ M J ] \beta_J=\mathrm{ON}/\mathbb{E}[M_J] β J = ON / E [ M J ] be the gap between the dual certificate E [ M J ] \mathbb{E}[M_J] E [ M J ] and O N \mathrm{ON} ON , which makes the right-hand side above equal to 1 − a / β J ln ( 1 / a ) \frac{1-a/\beta_J}{\ln(1/a)} l n ( 1/ a ) 1 − a / β J . For the sake of this remark, we even allow A ′ \mathcal{A}' A ′ to choose a a a using the unknown ratio β J \beta_J β J . Optimizing it for a a a gives a ∗ = − β J W − 1 ( − β J / e ) a^*=-\frac{\beta_J}{W_{-1}(-\beta_J/e)} a ∗ = − W − 1 ( − β J / e ) β J , where W W W is the Lambert function. This choice of a = a ∗ a=a^* a = a ∗ yields
r ( A ′ ) ≥ γ ( β J ) ⋅ O N = − 1 W − 1 ( − β J / e ) ⋅ O N . r(\mathcal{A}') \ge\gamma(\beta_J)\cdot\mathrm{ON}=-\frac{1}{W_{-1}(-\beta_J/e)}\cdot\mathrm{ON}. r ( A ′ ) ≥ γ ( β J ) ⋅ ON = − W − 1 ( − β J / e ) 1 ⋅ ON .
However, we unfortunately only know that β J ≥ α J \beta_J\ge\alpha_J β J ≥ α J and not its exact value.7 Consequently, replacing β J \beta_J β J with α J \alpha_J α J and letting α J = 1 − ε \alpha_J=1-\varepsilon α J = 1 − ε for a small ε ≪ 1 \varepsilon\ll1 ε ≪ 1 , we obtain
r ( A ′ ) O N ≥ ( 1 − 2 ε ) + O ( ε ) , (9) \frac{r(\mathcal{A}')}{\mathrm{ON}}\ge(1-\sqrt{2\varepsilon})+O(\varepsilon), \tag*{(9)} ON r ( A ′ ) ≥ ( 1 − 2 ε ) + O ( ε ) , (9)
which is smaller than the 1 − ε 1-\varepsilon 1 − ε approximation ratio of A J \mathcal{A}_J A J . Thus, with the same number of iterations J J J , our analysis would prove a better approximation ratio for Algorithm 2 than only using the final dual certificate. Moreover, whereas Algorithm 2 needs to set J = O ( log ∗ n + 1 / ε ) J=O(\log^* n+1/\varepsilon) J = O ( log ∗ n + 1/ ε ) to obtain a ( 1 − ε ) (1-\varepsilon) ( 1 − ε ) approximation ratio, this analysis requires J = O ( log ∗ n + 1 / ε 2 ) J=O(\log^* n+1/\varepsilon^2) J = O ( log ∗ n + 1/ ε 2 ) for the A ′ \mathcal{A}' A ′ to achieve the same performance. Thus, under this analysis, certifying a ( 1 − ε ) (1-\varepsilon) ( 1 − ε ) -approximation using only the final dual martingale requires an additional factor of 1 / ε 1/\varepsilon 1/ ε in the number of iterations.
This comparison illustrates a potential advantage of our iterative primal–dual construction. Rather than relying exclusively on the tightest available dual martingale, the algorithm maintains primal policies associated with earlier, looser dual certificates. Our analysis exploits the complementary contributions of these policies to obtain a faster convergence guarantee. Whether a policy using only the final dual martingale can achieve the same guarantee remains an interesting open question.
Efficient Implementation of alg:iteration
We now discuss how to efficiently implement A J \mathcal{A}_J A J , the output of Algorithm 2. Recall that to define A J \mathcal{A}_J A J , Algorithm 2 repeatedly uses Primal-Dual Improvement and then invokes Algorithm 1 using dual martingales Z t ( j ) = E [ M j ∣ F t ] Z_t^{(j)}=\mathbb{E}[M_j\mid\mathcal{F}_t] Z t ( j ) = E [ M j ∣ F t ] . Given that we cannot exactly compute martingales Z t ( j ) Z_t^{(j)} Z t ( j ) (for superconstant values of j j j ), we need to approximate it. Thus, in order to run A J \mathcal{A}_J A J in polynomial time, the invocation of Primal-Dual Improvement in Line 5 must use Algorithm 1 with a ( 1 − ε ) (1-\varepsilon) ( 1 − ε ) -approximation L t ( j ) L_t^{(j)} L t ( j ) of Z t ( j ) Z_t^{(j)} Z t ( j ) . Except for this approximation, the rest of Algorithms 1 and 2 can be readily implemented in polynomial time. Therefore, we prove the following lemma (proof in Appendix B.§ 3 ) that establishes our approximation can be done in a computationally efficient manner.
Lemma 4. Suppose 0 < α 0 < 1 0 < \alpha_0 < 1 0 < α 0 < 1 and consider accuracy parameters 0 < ε , δ < 1 0 < \varepsilon, \delta< 1 0 < ε , δ < 1 . For each j ≥ 0 j \ge0 j ≥ 0 , time t ∈ [ n ] t \in[n] t ∈ [ n ] , and history h t h_t h t , we can compute L t ( j ) ( h t ) L_t^{(j)}(h_t) L t ( j ) ( h t ) such that
L t ( j ) ( h t ) Z t ( j ) ( h t ) ∈ [ 1 − ε , 1 ] \frac{L_t^{(j)}(h_t)}{Z_t^{(j)}(h_t)} \in[1-\varepsilon,1] Z t ( j ) ( h t ) L t ( j ) ( h t ) ∈ [ 1 − ε , 1 ] with probability at least 1 − δ 1-\delta 1 − δ in time poly ( 2 j 2 ( K m n α 0 ε δ ) j + 1 ) \operatorname{poly}\left(2^{j^2}\left(\frac{Kmn}{\alpha_0\varepsilon\delta}\right)^{j+1}\right) poly ( 2 j 2 ( α 0 ε δ K mn ) j + 1 ) .
More precisely, the runtime is
O ( ζ 2 K m n j + 1 ( α 0 ε ) − ( 2 j + 2 ) ( j + ln n α 0 δ ε ) j + 1 ) O\left(\zeta^2 Kmn^{j+1}(\alpha_0\varepsilon)^{-(2j+2)}\left(j+\ln\frac{n}{\alpha_0\delta\varepsilon}\right)^{j+1}\right) O ( ζ 2 K m n j + 1 ( α 0 ε ) − ( 2 j + 2 ) ( j + ln α 0 δ ε n ) j + 1 ) where ζ = 2 19 \zeta=2^{19} ζ = 2 19 .
To compute Z t ( j ) ( h t ) Z_t^{(j)}(h_t) Z t ( j ) ( h t ) for a fixed history h t h_t h t , one needs to consider all continuations from h t h_t h t until time n n n , compute M j M_j M j for each of them, and then average them by their probabilities. Evaluating M j ( ω ) M_j(\omega) M j ( ω ) for a single sample path ω \omega ω is itself challenging because it requires the computation of Z t ( j ) ( h t ) Z_t^{(j)}(h_t) Z t ( j ) ( h t ) for n n n prefixes h t h_t h t of ω \omega ω ; each of them require this process recursively.
The estimation process underlying Lemma 4 leverages the pathwise structure of our dual updates to approximate Z t ( j ) ( h t ) Z_t^{(j)}(h_t) Z t ( j ) ( h t ) by sampling continuations of h t h_t h t , and evaluating M j ( ω ) M_j(\omega) M j ( ω ) for each ω \omega ω of such continuations. As said in the previous paragraph, this requires further (recursive) computations of dual martingales which are again done via Monte carlo simulations. Then, ( M ℓ ) ℓ ≤ j (M_\ell)_{\ell\le j} ( M ℓ ) ℓ ≤ j and ( ρ ℓ ) ℓ ≤ j (\rho_\ell)_{\ell\le j} ( ρ ℓ ) ℓ ≤ j values are estimated using these samples.
One challenge for Monte carlo simulations is that an unlikely sample path ω \omega ω can have a large value of M j ( ω ) M_j(\omega) M j ( ω ) , which would be missed if ω \omega ω is not sampled. To resolve this issue, use an importance-sampling change of measure to draw our Monte carlo samples.
Define the biased probability measure
Pr ∗ [ ω ∣ F t ] = Pr [ ω ∣ F t ] ⋅ M 0 ( ω ) Z t ( 0 ) , (10) \Pr_*\left[\omega\mid\mathcal{F}_t\right]=\Pr\left[\omega\mid\mathcal{F}_t\right]\cdot\frac{M_0(\omega)}{Z_t^{(0)}}, \tag*{(10)} ∗ Pr [ ω ∣ F t ] = Pr [ ω ∣ F t ] ⋅ Z t ( 0 ) M 0 ( ω ) , (10)
where ω \omega ω is a sample path compatible with the history until time t t t denoted by h t h_t h t .8 See Appendix B.§ 2 for a quick description of how to exactly sample from Pr ∗ [ ⋅ ] \Pr_*[\cdot] Pr ∗ [ ⋅ ] in polynomial time. Let E ∗ [ ⋅ ] \mathbb{E}_*[\cdot] E ∗ [ ⋅ ] be the expectation operator with respect to Pr ∗ [ ⋅ ] \Pr_*[\cdot] Pr ∗ [ ⋅ ] . The biased distribution has the following useful property (proof in Appendix B.§ 1 ):
Claim 1. Let W j = ∏ ℓ = 0 j − 1 max { α ℓ , ρ ℓ } W_j=\prod_{\ell=0}^{j-1}\max\{\alpha_\ell,\rho_\ell\} W j = ∏ ℓ = 0 j − 1 max { α ℓ , ρ ℓ } . For every j ≥ 0 j\ge0 j ≥ 0 , t ∈ [ n ] t\in[n] t ∈ [ n ] , and a history h t h_t h t , we have Z t ( j ) ( h t ) = E [ M 0 W j ∣ h t ] = Z t ( 0 ) ( h t ) ⋅ E ∗ [ W j ∣ h t ] Z_t^{(j)}(h_t)=\mathbb{E}[M_0W_j\mid h_t]=Z_t^{(0)}(h_t)\cdot\mathbb{E}_*[W_j\mid h_t] Z t ( j ) ( h t ) = E [ M 0 W j ∣ h t ] = Z t ( 0 ) ( h t ) ⋅ E ∗ [ W j ∣ h t ] .
Claim 1 is useful because Z t ( 0 ) ( h t ) = E [ M 0 ∣ h t ] Z_t^{(0)}(h_t)=\mathbb{E}[M_0\mid h_t] Z t ( 0 ) ( h t ) = E [ M 0 ∣ h t ] can be analytically computed exactly in polynomial time. Consequently, to estimate Z t ( j ) Z_t^{(j)} Z t ( j ) , we draw sufficiently many samples ω ( 1 ) , ω ( 2 ) , … \omega^{(1)},\omega^{(2)},\ldots ω ( 1 ) , ω ( 2 ) , … for continuations X t + 1 , … , X n X_{t+1},\ldots,X_n X t + 1 , … , X n from Pr ∗ [ ⋅ ∣ F t ] \Pr_*[\cdot\mid\mathcal{F}_t] Pr ∗ [ ⋅ ∣ F t ] , each sharing the same history h t h_t h t . For each sample path ω ( i ) \omega^{(i)} ω ( i ) , we approximate W j ( ω ( i ) ) W_j(\omega^{(i)}) W j ( ω ( i ) ) . By Chernoff bound, with sufficiently many samples, the average value from these samples is close to the true expected value E ∗ [ W j ∣ h t ] \mathbb{E}_* [W_j \mid h_t] E ∗ [ W j ∣ h t ] with high probability; Claim 1 then provides the estimation of Z t ( j ) ( h t ) Z_t^{(j)}(h_t) Z t ( j ) ( h t ) . The formal description of approximating W j ( ω ) W_j(\omega) W j ( ω ) is in Algorithm 3, with its analysis and the proof of Lemma 4 deferred to Appendix B.3.
ALGORITHM 3: Recursive estimator W j ( ω , ε , δ ) W_j(\omega,\varepsilon,\delta) W j ( ω , ε , δ )
Input: Recursion level j j j ; sample path ω \omega ω ; accuracy parameters 0 < ε , δ < 1 0 < \varepsilon,\delta< 1 0 < ε , δ < 1
Output: A randomized output W ^ j ( ω ) \widehat{W}_j(\omega) W j ( ω ) such that W ^ j ( ω ) / W j ( ω ) ∈ [ ( 1 − ε ) , ( 1 − ε ) − 1 ] \widehat{W}_j(\omega)/W_j(\omega) \in[(1-\varepsilon),(1-\varepsilon)^{-1}] W j ( ω ) / W j ( ω ) ∈ [( 1 − ε ) , ( 1 − ε ) − 1 ] w.p. 1 − δ 1-\delta 1 − δ
if j = 0 j=0 j = 0 then
Return 1 1 1
ε ′ ← 1 − ( 1 − ε ) 1 / 3 \varepsilon' \leftarrow1-(1-\varepsilon)^{1/3} ε ′ ← 1 − ( 1 − ε ) 1/3 and G j − 1 ← ∏ ℓ = 0 j − 1 α ℓ G_{j-1} \leftarrow\prod_{\ell=0}^{j-1}\alpha_\ell G j − 1 ← ∏ ℓ = 0 j − 1 α ℓ // with ( α ℓ ) ℓ (\alpha_\ell)_\ell ( α ℓ ) ℓ as defined in Algorithm 2
I j ← ⌈ 3 ε ′ 2 G j − 1 ln 4 n δ ⌉ I_j \leftarrow\left\lceil\frac{3}{\varepsilon'^2G_{j-1}}\ln\frac{4n}{\delta}\right\rceil I j ← ⌈ ε ′2 G j − 1 3 ln δ 4 n ⌉ and δ ′ ← δ 2 ( n I j + 1 ) \delta' \leftarrow\frac{\delta}{2(nI_j+1)} δ ′ ← 2 ( n I j + 1 ) δ
for all time step t = 1 , … , n t=1,\ldots,n t = 1 , … , n do
Let h t h_t h t be the history of first t t t steps in ω \omega ω .
for all i = 1 , … , I j i=1,\ldots,I_j i = 1 , … , I j do
Independently sample a fresh continuation h ~ ( t , i ) = ( X ~ t + 1 ( t , i ) , … , X ~ n ( t , i ) ) \widetilde{h}^{(t,i)}=(\widetilde{X}^{(t,i)}_{t+1},\ldots,\widetilde{X}^{(t,i)}_n) h ( t , i ) = ( X t + 1 ( t , i ) , … , X n ( t , i ) ) from Pr ∗ [ ⋅ ∣ h t ] \Pr_*[\cdot\mid h_t] Pr ∗ [ ⋅ ∣ h t ]
Let ω ~ ( t , i ) \widetilde{\omega}^{(t,i)} ω ( t , i ) be the sample path formed by concatenating h t h_t h t and h ~ ( t , i ) \widetilde{h}^{(t,i)} h ( t , i )
Recursively set W ^ j − 1 ( t , i ) ← W j − 1 ( ω ~ ( t , i ) , ε ′ , δ ′ ) \widehat{W}^{(t,i)}_{j-1}\leftarrow W_{j-1}(\widetilde{\omega}^{(t,i)},\varepsilon',\delta') W j − 1 ( t , i ) ← W j − 1 ( ω ( t , i ) , ε ′ , δ ′ )
Z ^ t ( j − 1 ) ← Z t ( 0 ) ( h t ) ⋅ 1 I j ∑ i = 1 I j W ^ j − 1 ( t , i ) \widehat{Z}^{(j-1)}_t\leftarrow Z^{(0)}_t(h_t)\cdot\frac{1}{I_j}\sum_{i=1}^{I_j}\widehat{W}^{(t,i)}_{j-1} Z t ( j − 1 ) ← Z t ( 0 ) ( h t ) ⋅ I j 1 ∑ i = 1 I j W j − 1 ( t , i )
ρ ^ j − 1 ← max t ∈ [ n ] X t ( ω ) / Z ^ t ( j − 1 ) \widehat{\rho}_{j-1}\leftarrow\max_{t\in[n]}X_t(\omega)/\widehat{Z}^{(j-1)}_t ρ j − 1 ← max t ∈ [ n ] X t ( ω ) / Z t ( j − 1 )
W ^ j − 1 ( ω ) ← W j − 1 ( ω , ε ′ , δ ′ ) \widehat{W}_{j-1}(\omega)\leftarrow W_{j-1}(\omega,\varepsilon',\delta') W j − 1 ( ω ) ← W j − 1 ( ω , ε ′ , δ ′ )
Return W ^ j ( ω ) ← W ^ j − 1 ( ω ) ⋅ max { α j − 1 , ρ ^ j − 1 } \widehat{W}_j(\omega)\leftarrow\widehat{W}_{j-1}(\omega)\cdot\max\{\alpha_{j-1},\widehat{\rho}_{j-1}\} W j ( ω ) ← W j − 1 ( ω ) ⋅ max { α j − 1 , ρ j − 1 }
Completing the Proof of Theorem 3: Analysis of Algorithm 2
In this subsection, we analyze Algorithm 2 and prove that it satisfies the properties needed for Theorem 3.
The main technical analysis is done via the following lemma—which is a stronger version of Lemma 3 that accounts for martingale approximations. Recall that given an α \alpha α -competitive algorithm A \mathcal{A} A , the sequence of approximation ratios ( α j ) j ≥ 0 (\alpha_j)_{j\geq0} ( α j ) j ≥ 0 is defined recursively by α j = ( 1 + ln ( 1 / α j − 1 ) ) − 1 \alpha_j=(1+\ln(1/\alpha_{j-1}))^{-1} α j = ( 1 + ln ( 1/ α j − 1 ) ) − 1 with α 0 = α \alpha_0=\alpha α 0 = α . We then have the following lemma (proved in Section 3.4.2):
Lemma 5. Suppose 0 < β < 1 0<\beta<1 0 < β < 1 and we are given an α \alpha α -competitive algorithm A \mathcal{A} A with 0 < α ≤ 1 0<\alpha\leq1 0 < α ≤ 1 . If Algorithm 2 starts with the baseline algorithm A \mathcal{A} A and α 0 = α \alpha_0=\alpha α 0 = α , and uses estimation accuracy β \beta β when calling Algorithm 1, then every constructed level j ≥ 0 j\geq0 j ≥ 0 satisfies
r ( A j ) ≥ α j ( 1 − β ) 2 E [ M j ] ≥ α j ( 1 − β ) 2 ON . r(\mathcal{A}_j)\geq\alpha_j(1-\beta)^2\mathbb{E}[M_j]\geq\alpha_j(1-\beta)^2\operatorname{ON}. r ( A j ) ≥ α j ( 1 − β ) 2 E [ M j ] ≥ α j ( 1 − β ) 2 ON .
Before proving Theorem 3, we determine how many iterations are required for α j \alpha_j α j to approach 1 1 1 . The following lemma gives the needed bound (proof in Appendix B.6).
Lemma 6. Suppose 0 < ε ≤ 1 0 < \varepsilon\le1 0 < ε ≤ 1 , 0 < α 0 ≤ 1 0 < \alpha_0 \le1 0 < α 0 ≤ 1 , and α j + 1 = 1 / ( 1 + ln ( 1 / α j ) ) \alpha_{j+1} = 1/(1+\ln(1/\alpha_j)) α j + 1 = 1/ ( 1 + ln ( 1/ α j )) for every j ≥ 0 j \ge0 j ≥ 0 . There exists an integer J = O ( log ∗ 1 α 0 + 1 ε ) J = O(\log^* \frac{1}{\alpha_0}+\frac{1}{\varepsilon}) J = O ( log ∗ α 0 1 + ε 1 ) such that α J ≥ 1 − ε / 2 \alpha_J \ge1-\varepsilon/2 α J ≥ 1 − ε /2 .
Proof of thm:main.
We may assume n ≥ 2 n \ge2 n ≥ 2 (the case n = 1 n=1 n = 1 is trivial). Set the internal estimation accuracy in Algorithm 2 (when calling Algorithm 1) to β = ε / 4 \beta= \varepsilon/4 β = ε /4 . By Lemma 6, there exists an integer J = O ( log ∗ 1 α 0 + 1 ε ) J = O(\log^* \frac{1}{\alpha_0}+\frac{1}{\varepsilon}) J = O ( log ∗ α 0 1 + ε 1 ) with J ≥ 2 J \ge2 J ≥ 2 such that α J ≥ 1 − ε / 2 \alpha_J \ge1-\varepsilon/2 α J ≥ 1 − ε /2 . Consequently, by Lemma 5, the algorithm A J \mathcal{A}_J A J satisfies
r ( A J ) ≥ α J ( 1 − β ) 2 O N ≥ ( 1 − ε 2 ) ( 1 − ε 4 ) 2 O N ≥ ( 1 − ε ) O N . \begin{aligned}
r(\mathcal{A}_J) \ge\alpha_J(1-\beta)^2\mathrm{ON} \\
&\ge\left(1-\frac{\varepsilon}{2}\right)\left(1-\frac{\varepsilon}{4}\right)^2\mathrm{ON} \\
&\ge(1-\varepsilon)\mathrm{ON}.
\end{aligned} r ( A J ) ≥ α J ( 1 − β ) 2 ON ≥ ( 1 − 2 ε ) ( 1 − 4 ε ) 2 ON ≥ ( 1 − ε ) ON .
as desired.
It remains to account for the running time. At each time, Algorithm 1 invokes Lemma 4 with accuracy ε / 4 \varepsilon/4 ε /4 and failure probability δ = ε / ( 4 n ) \delta= \varepsilon/(4n) δ = ε / ( 4 n ) . During a run of A J \mathcal{A}_J A J , the algorithm either runs A 0 \mathcal{A}_0 A 0 or enters A t h r \mathcal{A}_{\mathrm{thr}} A thr at some level j ∈ { 0 , … , J − 1 } j \in\{0,\ldots,J-1\} j ∈ { 0 , … , J − 1 } . Thus, the algorithm makes at most n n n calls to compute L t ( h t ) L_t(h_t) L t ( h t ) for t ∈ [ n ] t \in[n] t ∈ [ n ] , all at a single level. This dominates all the other operations in that level in terms of runtime. The runtime bound in Lemma 4 for level j j j is increasing in j j j , so the largest cost occurs at j = J − 1 j=J-1 j = J − 1 . Thus, the total running time is
O ( ζ J 2 K m n J + 1 ( α 0 ε ) − 2 J ( J + ln n α 0 ε ) J ) . O\left(\zeta^{J^2} Kmn^{J+1}(\alpha_0\varepsilon)^{-2J}\left(J+\ln\frac{n}{\alpha_0\varepsilon}\right)^J\right). O ( ζ J 2 K m n J + 1 ( α 0 ε ) − 2 J ( J + ln α 0 ε n ) J ) .
Because α 0 ≥ 1 / n \alpha_0 \ge1/n α 0 ≥ 1/ n (by accepting at a time chosen uniformly at random) and J = O ( log ∗ 1 α 0 + 1 ε ) J = O(\log^* \frac{1}{\alpha_0}+\frac{1}{\varepsilon}) J = O ( log ∗ α 0 1 + ε 1 ) , the overall runtime of our algorithm is poly ( K m n 1 / ε + log ∗ n ⋅ ( 1 / ε ) 1 / ε 2 ) \operatorname{poly}(Kmn^{1/\varepsilon+\log^* n}\cdot(1/\varepsilon)^{1/\varepsilon^2}) poly ( K m n 1/ ε + l o g ∗ n ⋅ ( 1/ ε ) 1/ ε 2 ) , which establishes the runtime of our approximation scheme. For the NON-IID model, we have α 0 ≥ max { 1 2 K , n } \alpha_0 \ge\max\{\frac{1}{2K},n\} α 0 ≥ max { 2 K 1 , n } because we can also choose the algorithm that commits to the world that has the largest contribution to OFF and adopt a 1 / 2 1/2 1/2 -competitive algorithm for that world, which would be 1 2 K \frac{1}{2K} 2 K 1 -competitive. Finally, in the special case of IID, we have α 0 ≥ 1 / e \alpha_0 \ge1/e α 0 ≥ 1/ e (by using the secretary algorithm), which makes our algorithm a genuine PTAS. The proof is now complete.
We prove the result by induction on j j j . The base j = 0 j=0 j = 0 is given by the lemma’s hypothesis. For the inductive step, fix j ≥ 1 j \ge1 j ≥ 1 , and note that α j < 1 \alpha_j < 1 α j < 1 . Let L t L_t L t be the approximation of Z t ( j − 1 ) Z_t^{(j-1)} Z t ( j − 1 ) , as in Line 8 of Algorithm 1. For every q ∈ [ 0 , 1 ] q \in[0,1] q ∈ [ 0 , 1 ] , define
τ q = inf { t : X t ≥ q ⋅ Z t ( j − 1 ) } and τ ^ q = inf { t : X t ≥ q ⋅ L t } . \tau_q = \inf\{t:X_t \ge q\cdot Z_t^{(j-1)}\} \qquad\text{and}\qquad\widehat{\tau}_q = \inf\{t:X_t \ge q\cdot L_t\}. τ q = inf { t : X t ≥ q ⋅ Z t ( j − 1 ) } and τ q = inf { t : X t ≥ q ⋅ L t } .
with the convention that inf ∅ = ∞ \inf\varnothing= \infty inf ∅ = ∞ , and with all quantities indexed by an infinite stopping time set to zero. Furthermore, define A ^ q = E [ X τ ^ q ⋅ I [ τ ^ q ≤ n ] ] \widehat{A}_q = \mathbb{E}[X_{\widehat{\tau}_q}\cdot\mathbb{I}[\widehat{\tau}_q \le n]] A q = E [ X τ q ⋅ I [ τ q ≤ n ]] . The proof proceeds in six steps as follows.
Step 1. We first show (Dual-Identity), which is equivalent to
E [ M j ] = α j − 1 ⋅ E [ M j − 1 ] + ∫ α j − 1 1 E [ M j − 1 I [ τ q ≤ n ] ] d q . \mathbb{E}[M_j] = \alpha_{j-1}\cdot\mathbb{E}[M_{j-1}] + \int_{\alpha_{j-1}}^1 \mathbb{E}[M_{j-1}\mathbb{I}[\tau_q \le n]]\,dq. E [ M j ] = α j − 1 ⋅ E [ M j − 1 ] + ∫ α j − 1 1 E [ M j − 1 I [ τ q ≤ n ]] d q .
Recall the definition M j = M j − 1 ⋅ max { ρ j − 1 , α j − 1 } M_j=M_{j-1}\cdot\max\{\rho_{j-1},\alpha_{j-1}\} M j = M j − 1 ⋅ max { ρ j − 1 , α j − 1 } . Because ( Z t ( j − 1 ) ) t (Z_t^{(j-1)})_t ( Z t ( j − 1 ) ) t is a dual martingale (from Lemma 2), we have 0 ≤ ρ j − 1 ≤ 1 0\leq\rho_{j-1}\leq1 0 ≤ ρ j − 1 ≤ 1 . This gives
max { ρ j − 1 , α j − 1 } = α j − 1 + ∫ α j − 1 1 I [ ρ j − 1 ≥ q ] d q almost surely . \max\{\rho_{j-1},\alpha_{j-1}\}=\alpha_{j-1}+\int_{\alpha_{j-1}}^1\mathbb{I}[\rho_{j-1}\geq q]\,dq\quad\text{almost surely}. max { ρ j − 1 , α j − 1 } = α j − 1 + ∫ α j − 1 1 I [ ρ j − 1 ≥ q ] d q almost surely .
By the definition of ρ j − 1 = max t ∈ [ n ] X t Z t ( j − 1 ) \rho_{j-1}=\max_{t\in[n]}\frac{X_t}{Z_t^{(j-1)}} ρ j − 1 = max t ∈ [ n ] Z t ( j − 1 ) X t and τ q = inf { t : X t ≥ q ⋅ Z t ( j − 1 ) } \tau_q=\inf\{t:X_t\geq q\cdot Z_t^{(j-1)}\} τ q = inf { t : X t ≥ q ⋅ Z t ( j − 1 ) } , we have
M j − 1 I [ τ q ≤ n ] = M j − 1 I [ ρ j − 1 ≥ q ] almost surely for all q . M_{j-1}\mathbb{I}[\tau_q\leq n]=M_{j-1}\mathbb{I}[\rho_{j-1}\geq q]\quad\text{almost surely for all }q. M j − 1 I [ τ q ≤ n ] = M j − 1 I [ ρ j − 1 ≥ q ] almost surely for all q .
This implies
M j = α j − 1 M j − 1 + ∫ α j − 1 1 M j − 1 I [ τ q ≤ n ] d q almost surely . M_j=\alpha_{j-1}M_{j-1}+\int_{\alpha_{j-1}}^1M_{j-1}\mathbb{I}[\tau_q\leq n]\,dq\quad\text{almost surely}. M j = α j − 1 M j − 1 + ∫ α j − 1 1 M j − 1 I [ τ q ≤ n ] d q almost surely .
Taking expectations establishes Step 1.
Step 2. We next obtain the following lower bound for the reward of A j A_j A j :
r ( A j ) ≥ γ ( α j − 1 ( 1 − β ) 2 ⋅ E [ M j − 1 ] + ∫ α j − 1 1 A ^ q q d q ) . r(A_j)\geq\gamma\left(\alpha_{j-1}(1-\beta)^2\cdot\mathbb{E}[M_{j-1}]+\int_{\alpha_{j-1}}^1\frac{\widehat{A}_q}{q}\,dq\right). r ( A j ) ≥ γ ( α j − 1 ( 1 − β ) 2 ⋅ E [ M j − 1 ] + ∫ α j − 1 1 q A q d q ) .
When Algorithm 1 runs A t h r A_{\mathrm{thr}} A thr with Q = q Q=q Q = q , its reward is exactly A ^ q \widehat{A}_q A q . Thus, by construction, with γ = 1 / ( 1 + ln ( 1 / α j − 1 ) ) \gamma=1/(1+\ln(1/\alpha_{j-1})) γ = 1/ ( 1 + ln ( 1/ α j − 1 )) , we have
r ( A j ) = γ r ( A j − 1 ) + 1 − γ ln ( 1 / α j − 1 ) ∫ α j − 1 1 A ^ q q d q = γ r ( A j − 1 ) + γ ∫ α j − 1 1 A ^ q q d q ≥ γ ( α j − 1 ( 1 − β ) 2 ⋅ E [ M j − 1 ] + ∫ α j − 1 1 A ^ q q d q ) . \begin{aligned}
r(A_j)&=\gamma r(A_{j-1})+\frac{1-\gamma}{\ln(1/\alpha_{j-1})}\int_{\alpha_{j-1}}^1\frac{\widehat{A}_q}{q}\,dq\\
&=\gamma r(A_{j-1})+\gamma\int_{\alpha_{j-1}}^1\frac{\widehat{A}_q}{q}\,dq\\
&\geq\gamma\left(\alpha_{j-1}(1-\beta)^2\cdot\mathbb{E}[M_{j-1}]+\int_{\alpha_{j-1}}^1\frac{\widehat{A}_q}{q}\,dq\right).
\end{aligned} r ( A j ) = γ r ( A j − 1 ) + ln ( 1/ α j − 1 ) 1 − γ ∫ α j − 1 1 q A q d q = γ r ( A j − 1 ) + γ ∫ α j − 1 1 q A q d q ≥ γ ( α j − 1 ( 1 − β ) 2 ⋅ E [ M j − 1 ] + ∫ α j − 1 1 q A q d q ) .
where the final inequality follows from the induction hypothesis.
Step 3. To analyze the estimation failures, we make the estimator’s randomness explicit. Let U = ( U 1 , ⋯ , U n ) U=(U_1,\cdots,U_n) U = ( U 1 , ⋯ , U n ) be auxiliary random seeds to compute L 1 , ⋯ , L n L_1,\cdots,L_n L 1 , ⋯ , L n ; thus, U U U is independent from the underlying sample path and natural filtration. Also, let U t = σ ( U 1 , ⋯ , U t ) \mathcal{U}_t=\sigma(U_1,\cdots,U_t) U t = σ ( U 1 , ⋯ , U t ) be the corresponding filtration. Notice that F t \mathcal{F}_t F t and U t \mathcal{U}_t U t are independent, i.e., F t ⊥ ⊥ U t \mathcal{F}_t\perp\!\!\perp\mathcal{U}_t F t ⊥ ⊥ U t .
Define events E t = { L t ∈ [ ( 1 − β ) Z t ( j − 1 ) , Z t ( j − 1 ) ] } E_t=\{L_t\in[(1-\beta)Z_t^{(j-1)},Z_t^{(j-1)}]\} E t = { L t ∈ [( 1 − β ) Z t ( j − 1 ) , Z t ( j − 1 ) ]} and E t = ⋂ s = 1 t E s \mathcal{E}_t=\bigcap_{s=1}^tE_s E t = ⋂ s = 1 t E s . At each realized history, we invoke Lemma 4 with accuracy ε = β \varepsilon=\beta ε = β and failure probability δ = β / n \delta=\beta/n δ = β / n , as stated in Algorithm 1. Because U U U is independent of the full realized path and the estimator at time t t t depends on that path only through its history h t h_t h t , the fixed-history guarantee gives Pr [ E t c ∣ F n ] ≤ β / n \Pr[E_t^c\mid\mathcal{F}_n]\leq\beta/n Pr [ E t c ∣ F n ] ≤ β / n . A union bound therefore gives Pr [ E t c ∣ F n ] ≤ β \Pr[\mathcal{E}_t^c\mid\mathcal{F}_n]\leq\beta Pr [ E t c ∣ F n ] ≤ β for every t ∈ [ n ] t\in[n] t ∈ [ n ] . On { τ ^ q = t } ∩ E t \{\widehat{\tau}_q=t\}\cap\mathcal{E}_t { τ q = t } ∩ E t , we have
X t ≥ q L t ≥ q ( 1 − β ) Z t ( j − 1 ) . X_t\geq qL_t\geq q(1-\beta)Z_t^{(j-1)}. X t ≥ q L t ≥ q ( 1 − β ) Z t ( j − 1 ) .
This gives
A ^ q ≥ q ( 1 − β ) ⋅ E [ Z τ ^ q ( j − 1 ) ⋅ I [ τ ^ q ≤ n ] ⋅ I [ E τ ^ q ] ] . (11) \widehat{A}_q \ge q(1-\beta)\cdot\mathbb{E}\left[ Z_{\widehat{\tau}_q}^{(j-1)}\cdot\mathbb{I}[\widehat{\tau}_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\widehat{\tau}_q}]\right]. \tag*{(11)} A q ≥ q ( 1 − β ) ⋅ E [ Z τ q ( j − 1 ) ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] . (11)
Step 4. Next, we prove
E [ Z τ ^ q ( j − 1 ) ⋅ I [ τ ^ q ≤ n ] ⋅ I [ E τ ^ q ] ] = E [ M j − 1 ⋅ I [ τ ^ q ≤ n ] ⋅ I [ E τ ^ q ] ] . (12) \mathbb{E}\left[ Z_{\widehat{\tau}_q}^{(j-1)}\cdot\mathbb{I}[\widehat{\tau}_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\widehat{\tau}_q}]\right]
=
\mathbb{E}\left[ M_{j-1}\cdot\mathbb{I}[\widehat{\tau}_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\widehat{\tau}_q}]\right]. \tag*{(12)} E [ Z τ q ( j − 1 ) ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] = E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] . (12)
Using the tower property on the enlarged filtration G t = F t ∨ U t \mathcal{G}_t=\mathcal{F}_t\vee\mathcal{U}_t G t = F t ∨ U t , for every t ∈ [ n ] t\in[n] t ∈ [ n ] we have
E [ M j − 1 ⋅ I [ τ ^ q = t ] ⋅ I [ E t ] ] = E [ E [ M j − 1 ⋅ I [ τ ^ q = t ] ⋅ I [ E t ] ∣ G t ] ] = ( i ) E [ E [ M j − 1 ∣ G t ] ⋅ I [ τ ^ q = t ] ⋅ I [ E t ] ] = ( i i ) E [ E [ M j − 1 ∣ F t ] ⋅ I [ τ ^ q = t ] ⋅ I [ E t ] ] = E [ Z t ( j − 1 ) ⋅ I [ τ ^ q = t ] ⋅ I [ E t ] ] . \begin{aligned}
\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\widehat{\tau}_q=t]\cdot\mathbb{I}[\mathcal{E}_t]\right]
&=\mathbb{E}\left[\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\widehat{\tau}_q=t]\cdot\mathbb{I}[\mathcal{E}_t]\mid\mathcal{G}_t\right]\right]\\
&\overset{(i)}{=}\mathbb{E}\left[\mathbb{E}[M_{j-1}\mid\mathcal{G}_t]\cdot\mathbb{I}[\widehat{\tau}_q=t]\cdot\mathbb{I}[\mathcal{E}_t]\right]\\
&\overset{(ii)}{=}\mathbb{E}\left[\mathbb{E}[M_{j-1}\mid\mathcal{F}_t]\cdot\mathbb{I}[\widehat{\tau}_q=t]\cdot\mathbb{I}[\mathcal{E}_t]\right]\\
&=\mathbb{E}\left[Z_t^{(j-1)}\cdot\mathbb{I}[\widehat{\tau}_q=t]\cdot\mathbb{I}[\mathcal{E}_t]\right].
\end{aligned} E [ M j − 1 ⋅ I [ τ q = t ] ⋅ I [ E t ] ] = E [ E [ M j − 1 ⋅ I [ τ q = t ] ⋅ I [ E t ] ∣ G t ] ] = ( i ) E [ E [ M j − 1 ∣ G t ] ⋅ I [ τ q = t ] ⋅ I [ E t ] ] = ( ii ) E [ E [ M j − 1 ∣ F t ] ⋅ I [ τ q = t ] ⋅ I [ E t ] ] = E [ Z t ( j − 1 ) ⋅ I [ τ q = t ] ⋅ I [ E t ] ] .
where ( i ) (i) ( i ) uses the fact that { τ ^ q = t } \{\widehat{\tau}_q=t\} { τ q = t } and I [ E t ] \mathbb{I}[\mathcal{E}_t] I [ E t ] are G t \mathcal{G}_t G t -measurable, and ( i i ) (ii) ( ii ) follows from F n \mathcal{F}_n F n -measurability of M j − 1 M_{j-1} M j − 1 and that F n ⊥ ⊥ U n \mathcal{F}_n\perp\!\!\!\perp\mathcal{U}_n F n ⊥ ⊥ U n . The final equality simply follows from the definition. Now, summing over t ∈ [ n ] t\in[n] t ∈ [ n ] establishes (12) .
Step 5. We now show
E [ M j − 1 ⋅ I [ τ ^ q ≤ n ] ⋅ I [ E τ ^ q ] ] ≥ E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] . (13) \mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\widehat{\tau}_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\widehat{\tau}_q}]\right]
\ge
\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\tau_q}]\right]. \tag*{(13)} E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] ≥ E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] . (13)
Suppose { τ q ≤ n } ∩ E τ q \{\tau_q\le n\}\cap\mathcal{E}_{\tau_q} { τ q ≤ n } ∩ E τ q occurs. Then L s ≤ Z s ( j − 1 ) L_s\le Z_s^{(j-1)} L s ≤ Z s ( j − 1 ) for every s ≤ τ q s\le\tau_q s ≤ τ q , and at time τ q \tau_q τ q we have X τ q ≥ q Z τ q ( j − 1 ) ≥ q L τ q X_{\tau_q}\ge qZ_{\tau_q}^{(j-1)}\ge qL_{\tau_q} X τ q ≥ q Z τ q ( j − 1 ) ≥ q L τ q . Hence, the actual algorithm stops at some τ ^ q ≤ τ q ≤ n \widehat{\tau}_q\le\tau_q\le n τ q ≤ τ q ≤ n . Since the events E t \mathcal{E}_t E t are nested, E τ ^ q \mathcal{E}_{\widehat{\tau}_q} E τ q holds too. These observations establish the following event inclusion:
{ τ q ≤ n } ∩ E τ q ⊆ { τ ^ q ≤ n } ∩ E τ ^ q . \{\tau_q\le n\}\cap\mathcal{E}_{\tau_q}\subseteq\{\widehat{\tau}_q\le n\}\cap\mathcal{E}_{\widehat{\tau}_q}. { τ q ≤ n } ∩ E τ q ⊆ { τ q ≤ n } ∩ E τ q .
Because M j − 1 ≥ 0 M_{j-1}\ge0 M j − 1 ≥ 0 , we can multiply both sides of this expression by M j − 1 M_{j-1} M j − 1 pathwise to get
M j − 1 ⋅ I [ τ ^ q ≤ n ] ⋅ I [ E τ ^ q ] ≥ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] almost surely . M_{j-1}\cdot\mathbb{I}[\widehat{\tau}_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\widehat{\tau}_q}]
\ge
M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\tau_q}]
\quad\text{almost surely}. M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ≥ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] almost surely .
Taking an expectation proves (13) .
Step 6. At the final step, we demonstrate that
E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] ≥ ( 1 − β ) ⋅ E [ M j − 1 ⋅ I [ τ q ≤ n ] ] . (14) \mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\tau_q}]\right]
\ge
(1-\beta)\cdot\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\right]. \tag*{(14)} E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] ≥ ( 1 − β ) ⋅ E [ M j − 1 ⋅ I [ τ q ≤ n ] ] . (14)
To see this, note that
E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q c ] ] = E [ E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q c ] ∣ F n ] ] = E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ E [ I [ E τ q c ] ∣ F n ] ] ≤ E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ β ] = β ⋅ E [ M j − 1 ⋅ I [ τ q ≤ n ] ] , \begin{aligned}
\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\tau_q}^{c}]\right]
=
\mathbb{E}\left[\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\tau_q}^{c}]\mid\mathcal{F}_n\right]\right] \\
&= \mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{E}\left[\mathbb{I}\left[\mathcal{E}^{c}_{\tau_q}\right]\mid\mathcal{F}_n\right]\right] \\
&\le\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\beta\right] \\
&= \beta\cdot\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\right],
\end{aligned} E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q c ] ] = E [ E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q c ] ∣ F n ] ] = E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ E [ I [ E τ q c ] ∣ F n ] ] ≤ E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ β ] = β ⋅ E [ M j − 1 ⋅ I [ τ q ≤ n ] ] ,
where the inequality follows from the bound Pr [ E τ q c ∣ F n ] ≤ β \Pr[\mathcal{E}^{c}_{\tau_q}\mid\mathcal{F}_n]\le\beta Pr [ E τ q c ∣ F n ] ≤ β in Step 3, since τ q \tau_q τ q is F n \mathcal{F}_n F n -measurable.
Noting
E [ M j − 1 ⋅ I [ τ q ≤ n ] ] = E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] + E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q c ] ] \mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\right]=\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{I}[\mathcal{E}_{\tau_q}]\right]+\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\cdot\mathbb{I}[\mathcal{E}^{c}_{\tau_q}]\right] E [ M j − 1 ⋅ I [ τ q ≤ n ] ] = E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q ] ] + E [ M j − 1 ⋅ I [ τ q ≤ n ] ⋅ I [ E τ q c ] ]
completes the proof of (14) .
Completing the proof. Now, we use Steps 1-6 to establish the lemma. Combining Steps 3-6 immediately gives
A ^ q ≥ q ( 1 − β ) 2 ⋅ E [ M j − 1 ⋅ I [ τ q ≤ n ] ] . \widehat{A}_q\ge q(1-\beta)^2\cdot\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\right]. A q ≥ q ( 1 − β ) 2 ⋅ E [ M j − 1 ⋅ I [ τ q ≤ n ] ] .
Using Step 2, we obtain
r ( A j ) ≥ γ ( α j − 1 ( 1 − β ) 2 ⋅ E [ M j − 1 ] + ( 1 − β ) 2 ⋅ ∫ α j − 1 1 E [ M j − 1 ⋅ I [ τ q ≤ n ] ] d q ) . r(A_j)\ge\gamma\left(\alpha_{j-1}(1-\beta)^2\cdot\mathbb{E}[M_{j-1}]+(1-\beta)^2\cdot\int_{\alpha_{j-1}}^1\mathbb{E}\left[M_{j-1}\cdot\mathbb{I}[\tau_q\le n]\right]\,dq\right). r ( A j ) ≥ γ ( α j − 1 ( 1 − β ) 2 ⋅ E [ M j − 1 ] + ( 1 − β ) 2 ⋅ ∫ α j − 1 1 E [ M j − 1 ⋅ I [ τ q ≤ n ] ] d q ) .
Comparing this lower bound with the equality for E [ M j ] \mathbb{E}[M_j] E [ M j ] in Step 1 immediately gives r ( A j ) ≥ γ ( 1 − β ) 2 E [ M j ] = α j ( 1 − β ) 2 E [ M j ] r(A_j)\ge\gamma(1-\beta)^2\mathbb{E}[M_j]=\alpha_j(1-\beta)^2\mathbb{E}[M_j] r ( A j ) ≥ γ ( 1 − β ) 2 E [ M j ] = α j ( 1 − β ) 2 E [ M j ] , since γ = α j \gamma=\alpha_j γ = α j . Thus, the induction step is established and the proof is complete.
Competitive Algorithms
In this section, we consider the problem of competing with the prophet benchmark. We uncover that this benchmark is significantly harder. In particular, in the IID model, we find that there exists a polynomial-time algorithm with a ( 1 / e + 1 / poly ( k ) ) (1/e+1/\operatorname{poly}(k)) ( 1/ e + 1/ poly ( k )) competitive ratio, but no online algorithm can guarantee a better competitive ratio (even without a runtime constraint).
The main result of this section is as follows:
Theorem 4. There exists a polynomial-time algorithm A A A for the IID Bayesian optimal stopping problem that is ( 1 / e + c / K 2 ) (1/e+c/K^2) ( 1/ e + c / K 2 ) -competitive for some universal constant c > 0 c>0 c > 0 . Conversely, no algorithm A A A can guarantee a competitive ratio better than 1 / e + c ′ / K 1/e+c'/\sqrt{K} 1/ e + c ′ / K for some other universal constant c ′ > 0 c'>0 c ′ > 0 .
The algorithm in Theorem 4 is an adaptation of Bai et al. [3 ] where they consider an IID prophet inequality problem where a (potentially wrong) candidate D ^ \widehat{D} D for the distribution is given. For a consistency parameter α > 0 \alpha>0 α > 0 and a robustness parameter β > 0 \beta>0 β > 0 , the authors devise an algorithm that is α \alpha α -competitive if D ^ \widehat{D} D is the true distribution, and is β \beta β -competitive otherwise. Indeed, this is done only for (a subset of) feasible pairs ( α , β ) (\alpha,\beta) ( α , β ) . By carefully adapting their results to our setup, we obtain our algorithm.
Conversely, the hard instance is more challenging to construct, as it should imply hardness for any online algorithm, including the exponential-time Bayesian DP. While a uniform 1 / e 1/e 1/ e upper bound for the limit K → ∞ K \to\infty K → ∞ has been previously established by [12 Theorem 5.1] through a minimax argument, we instead provide a concrete construction which provides upper bounds on the competitive ratio in terms of K K K .
Extending Theorem 4 to the NON-IID case, we observe that it is not possible to obtain a competitive ratio substantially better than the immediate guarantee of 1 / ( 2 K ) 1/(2K) 1/ ( 2 K ) . The proof of the following proposition is deferred to Appendix C.3.
Proposition 2. There exists a polynomial-time algorithm A \mathcal{A} A for the NON-IID Bayesian optimal stopping problem that is 1 / ( 2 K ) 1/(2K) 1/ ( 2 K ) -competitive. Conversely, no algorithm A \mathcal{A} A can guarantee a competitive ratio better than 1 / K 1/K 1/ K .
Finally, it is easy to see that 1 / n 1/n 1/ n is the optimal competitive ratio in the CORREL case. We state it here for completeness (proof in Appendix C.4):
Proposition 3. There exists a polynomial-time algorithm A \mathcal{A} A for the CORREL Bayesian optimal stopping problem that is 1 / n 1/n 1/ n -competitive and no algorithm can guarantee a better competitive ratio.
The rest of this section is organized as follows. The hard instance is presented in § 4.1 and Section 4.2 discusses the algorithm. Putting together their analyses in Lemmas 7 and 8 proves Theorem 4.
Hard Instance of thm:iid-comp
In this subsection, we present and analyze an instance in which no online algorithm can obtain a competitive ratio better than 1 / e + O ( 1 / K ) 1/e + O(1/\sqrt{K}) 1/ e + O ( 1/ K ) . For almost all distributions in the support of the prior, we choose the per-distribution maximum to be sufficiently likely, overwhelmingly large, and unlikely to appear twice. Approximating the offline optimum therefore essentially requires selecting the sequence maximum, as in the secretary problem. Moreover, we use a nested family of truncated distributions. This structure greatly simplifies the analysis because the posterior depends only on the current time and running maximum. Thus, the nesting renders the additional information learned online minimal, creating an information-theoretic barrier.
We remark here that, by a minimax argument between unknown IID and the Bayesian optimal stopping, [12 ), Theorem 5.1] had previously established that 1 / e 1/e 1/ e is the best possible constant competitive ratio that one can guarantee. However, we construct a concrete hard instance which also yields an upper bound on the best possible competitive ratio in terms of K K K ; letting K → ∞ K \to\infty K → ∞ indeed corresponds to the 1 / e 1/e 1/ e bound.
Construction. Fix n ≥ 2 n \ge2 n ≥ 2 . For each world h ∈ [ K ] h \in[K] h ∈ [ K ] , let D ( h ) D^{(h)} D ( h ) be supported on { 1 , n 3 , … , n 3 h } \{1,n^3,\ldots,n^{3h}\} { 1 , n 3 , … , n 3 h } , with
Pr [ X t = 1 ∣ H = h ] = ( 1 − 1 n 2 ) h , Pr [ X t = n 3 r ∣ H = h ] = 1 n 2 ( 1 − 1 n 2 ) h − r ( r ∈ [ h ] ) . \Pr[X_t=1\mid H=h]=\left(1-\frac{1}{n^2}\right)^h,\qquad
\Pr[X_t=n^{3r}\mid H=h]=\frac{1}{n^2}\left(1-\frac{1}{n^2}\right)^{h-r}\quad(r\in[h]). Pr [ X t = 1 ∣ H = h ] = ( 1 − n 2 1 ) h , Pr [ X t = n 3 r ∣ H = h ] = n 2 1 ( 1 − n 2 1 ) h − r ( r ∈ [ h ]) .
Conditional on H = h H=h H = h , the observations are drawn IID from D ( h ) D^{(h)} D ( h ) . We choose the prior
π h = n − 3 ( h − 1 ) c K , c K = ∑ ℓ = 0 K − 1 n − 3 ℓ . \pi_h=\frac{n^{-3(h-1)}}{c_K},\qquad c_K=\sum_{\ell=0}^{K-1}n^{-3\ell}. π h = c K n − 3 ( h − 1 ) , c K = ℓ = 0 ∑ K − 1 n − 3 ℓ .
Table 1 visualizes this hard instance.
Table 1. The hard instance corresponding to Lemma 7. The entries under the value columns give the probability of sampling those values under the corresponding worlds.
The largest value in each world appears with probability 1 / n 2 1/n^2 1/ n 2 at each time and is a factor n 3 n^3 n 3 larger than every other value in that world. Thus, we have E [ O F F ∣ H = h ] ≈ n 3 h ⋅ p n \mathbb{E}[\mathrm{OFF}\mid H=h]\approx n^{3h}\cdot p_n E [ OFF ∣ H = h ] ≈ n 3 h ⋅ p n , where p n = 1 − ( 1 − 1 / n 2 ) n ≈ 1 / n p_n=1-(1-1/n^2)^n\approx1/n p n = 1 − ( 1 − 1/ n 2 ) n ≈ 1/ n . In other words, a large 1 − o ( 1 ) 1-o(1) 1 − o ( 1 ) fraction of the reward of OFF comes from the largest value in the support of D ( h ) D^{(h)} D ( h ) . The prior balances these contributions across worlds, so that the expected contribution of every world to OFF is almost identical.
Analysis. We prove a stronger upper bound for competitive ratio that yields the result of the theorem as a corollary:
Lemma 7. There exist absolute constants c 0 > 0 c_0>0 c 0 > 0 and n 0 ≥ 2 n_0\ge2 n 0 ≥ 2 such that, for every K ≥ 1 K\ge1 K ≥ 1 and n ≥ n 0 n\ge n_0 n ≥ n 0 , every online algorithm A \mathcal{A} A on the hard instance of Table 1 satisfies
C R ( A ) ≤ 1 e + c 0 ( 1 n + n K ) . \mathrm{CR}(\mathcal{A})\le\frac{1}{e}+c_0\left(\frac{1}{n}+\frac{n}{K}\right). CR ( A ) ≤ e 1 + c 0 ( n 1 + K n ) .
Taking n = ⌊ K ⌋ n=\lfloor\sqrt{K}\rfloor n = ⌊ K ⌋ in this lemma then yields the hardness result in Theorem 4.
Proof of Lemma 7.
We prove this lemma by constructing a dual certificate D D D and comparing it with OFF, i.e., we show that
E [ D ] E [ M ] ≤ 1 e + O ( 1 n + n K ) , where M = max t ∈ [ n ] X t . (15) \frac{\mathbb{E}[D]}{\mathbb{E}[M]}\le\frac{1}{e}+O\left(\frac{1}{n}+\frac{n}{K}\right),\qquad\text{where }M=\max_{t\in[n]}X_t. \tag*{(15)} E [ M ] E [ D ] ≤ e 1 + O ( n 1 + K n ) , where M = t ∈ [ n ] max X t . (15)
Since D D D is a dual certificate, by Doob’s optional sampling theorem (Theorem 2), its expectation upper bounds the reward of any online algorithm, i.e., r ( A ) ≤ E [ D ] r(A) \le\mathbb{E}[D] r ( A ) ≤ E [ D ] ; the lemma follows immediately.
To construct D D D , we pick a suffix X s , X s + 1 , … , X n X_s, X_{s+1}, \ldots, X_n X s , X s + 1 , … , X n and let D = X s + ⋯ + X n D = X_s + \cdots+ X_n D = X s + ⋯ + X n . We show that if the suffix is chosen carefully, D D D becomes a dual certificate. We choose this suffix by first drawing T ∈ [ n / e , n ] T \in[n/e,n] T ∈ [ n / e , n ] with density f T ( s ) = 1 / s f_T(s) = 1/s f T ( s ) = 1/ s , and then letting the suffix be X ⌈ T ⌉ , … , X n X_{\lceil T\rceil}, \ldots, X_n X ⌈ T ⌉ , … , X n . Finally, the dual certificate is
D = E [ D ~ ∣ F n ] for D ~ = ∑ i = ⌈ T ⌉ n X i + n 2 v K ⋅ I [ X n = v K ] , (16) D = \mathbb{E}\left[\widetilde{D} \mid\mathcal{F}_n\right] \qquad\text{for} \qquad\widetilde{D} = \sum_{i=\lceil T\rceil}^{n} X_i + n^2v_K \cdot\mathbb{I}[X_n = v_K], \tag*{(16)} D = E [ D ∣ F n ] for D = i = ⌈ T ⌉ ∑ n X i + n 2 v K ⋅ I [ X n = v K ] , (16)
where the second term in D ~ \widetilde{D} D is a correction term to control for finite values of K K K .
We first analyze E [ D ] / E [ M ] \mathbb{E}[D]/\mathbb{E}[M] E [ D ] / E [ M ] , and then show that D D D is a dual certificate. A simple calculation shows that E [ T ] = ( 1 − 1 / e ) n \mathbb{E}[T] = (1 - 1/e)n E [ T ] = ( 1 − 1/ e ) n . Since the suffix contains n − ⌈ T ⌉ + 1 n - \lceil T\rceil+ 1 n − ⌈ T ⌉ + 1 observations, we have
E [ ∑ s = ⌈ T ⌉ n X s ] = E [ X 1 ] ⋅ E [ n − ⌈ T ⌉ + 1 ] = ( n e + O ( 1 ) ) E [ X 1 ] , \mathbb{E}\left[\sum_{s=\lceil T\rceil}^{n} X_s\right] = \mathbb{E}[X_1] \cdot\mathbb{E}[n - \lceil T\rceil+ 1] = \left(\frac{n}{e} + O(1)\right)\mathbb{E}[X_1], E s = ⌈ T ⌉ ∑ n X s = E [ X 1 ] ⋅ E [ n − ⌈ T ⌉ + 1 ] = ( e n + O ( 1 ) ) E [ X 1 ] ,
where we used the fact that the observations are conditionally IID given H H H . To compute E [ X 1 ] \mathbb{E}[X_1] E [ X 1 ] , note that in each world h h h , the largest value v h = n 3 h v_h = n^{3h} v h = n 3 h arrives at any time t t t with probability 1 / n 2 1/n^2 1/ n 2 , and every other value is at most n 3 h − 3 n^{3h-3} n 3 h − 3 . Thus, E [ X 1 ∣ H = h ] = n 3 h − 2 + O ( n 3 h − 3 ) \mathbb{E}[X_1 \mid H = h] = n^{3h-2} + O(n^{3h-3}) E [ X 1 ∣ H = h ] = n 3 h − 2 + O ( n 3 h − 3 ) , and averaging over the prior gives
E [ X 1 ] = ∑ h = 1 K 1 c K n 3 h − 3 ( n 3 h − 2 + O ( n 3 h − 3 ) ) = n K + O ( K ) c K . (17) \mathbb{E}[X_1] = \sum_{h=1}^{K} \frac{1}{c_K n^{3h-3}}\left(n^{3h-2} + O(n^{3h-3})\right) = \frac{nK + O(K)}{c_K}. \tag*{(17)} E [ X 1 ] = h = 1 ∑ K c K n 3 h − 3 1 ( n 3 h − 2 + O ( n 3 h − 3 ) ) = c K n K + O ( K ) . (17)
Similarly, the largest value appears among the n n n observations with probability 1 − ( 1 − 1 / n 2 ) n = 1 / n + O ( 1 / n 2 ) 1 - (1 - 1/n^2)^n = 1/n + O(1/n^2) 1 − ( 1 − 1/ n 2 ) n = 1/ n + O ( 1/ n 2 ) . Therefore,
O F F = ∑ h = 1 K 1 c K n 3 h − 3 ( n 3 h ( 1 − ( 1 − 1 n 2 ) n ) + O ( n 3 h − 3 ) ) = n 2 K + O ( n K ) c K . (18) \begin{aligned}
\mathrm{OFF} &= \sum_{h=1}^{K} \frac{1}{c_K n^{3h-3}}\left(n^{3h}\left(1 - \left(1 - \frac{1}{n^2}\right)^n\right) + O(n^{3h-3})\right) \\
&= \frac{n^2K + O(nK)}{c_K}. \tag*{(18)}
\end{aligned} OFF = h = 1 ∑ K c K n 3 h − 3 1 ( n 3 h ( 1 − ( 1 − n 2 1 ) n ) + O ( n 3 h − 3 ) ) = c K n 2 K + O ( n K ) . (18)
Finally, X n = v K X_n = v_K X n = v K is possible only in world K K K , where it occurs with probability 1 / n 2 1/n^2 1/ n 2 . Hence, the correction term has expectation
E [ n 2 v K I [ X n = v K ] ] = v K Pr [ H = K ] = n 3 c K . \mathbb{E}\left[n^2v_K\mathbb{I}[X_n = v_K]\right] = v_K\Pr[H = K] = \frac{n^3}{c_K}. E [ n 2 v K I [ X n = v K ] ] = v K Pr [ H = K ] = c K n 3 .
Combining these, we obtain
E [ D ] E [ M ] = n 2 K / e + n 3 + O ( n K ) n 2 K + O ( n K ) = 1 e + O ( 1 n + n K ) , \frac{\mathbb{E}[D]}{\mathbb{E}[M]} = \frac{n^2K/e + n^3 + O(nK)}{n^2K + O(nK)} = \frac{1}{e} + O\left(\frac{1}{n} + \frac{n}{K}\right), E [ M ] E [ D ] = n 2 K + O ( n K ) n 2 K / e + n 3 + O ( n K ) = e 1 + O ( n 1 + K n ) ,
where the expectation in the numerator is with respect to all the randomness of the instance as well as the choice of T T T . This is now the desired bound in the lemma.
It remains to show that D D D is a dual certificate, i.e., E [ D ∣ F t ] ≥ X t \mathbb{E}[D \mid\mathcal{F}_t] \ge X_t E [ D ∣ F t ] ≥ X t for every t t t almost surely. Fix t ≥ 1 t \ge1 t ≥ 1 . If T < t T < t T < t , the suffix contains X t X_t X t and the dual property clearly holds. We thus decompose the dual martingale as follows:
E [ D ∣ F t ] = ∑ s = 1 n E [ X s ⋅ I [ T ≤ s ] ∣ F t ] + E [ n 2 v K ⋅ I [ X n = v K ] ∣ F t ] ≥ E [ X t ∣ F t ] ⋅ Pr [ T ≤ t ] + ∑ s = t + 1 n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] + E [ n 2 v K ⋅ I [ X n = v K ] ∣ F t ] ≥ X t ⋅ Pr [ T ≤ t ] + ∑ s = t + 1 n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] + E [ n 2 v K ⋅ I [ X n = v K ] ∣ F t ] , (19) \begin{aligned}
\mathbb{E}[D \mid\mathcal{F}_t] = \sum_{s=1}^{n} \mathbb{E}\left[X_s \cdot\mathbb{I}[T \le s] \mid\mathcal{F}_t\right] + \mathbb{E}\left[n^2v_K \cdot\mathbb{I}[X_n = v_K] \mid\mathcal{F}_t\right] \\
&\ge\mathbb{E}[X_t \mid\mathcal{F}_t] \cdot\Pr[T \le t] + \sum_{s=t+1}^{n} \mathbb{E}[X_s \mid\mathcal{F}_t] \cdot\Pr[T \le s] + \mathbb{E}\left[n^2v_K \cdot\mathbb{I}[X_n = v_K] \mid\mathcal{F}_t\right] \\
&\ge X_t \cdot\Pr[T \le t] + \sum_{s=t+1}^{n} \mathbb{E}[X_s \mid\mathcal{F}_t] \cdot\Pr[T \le s] + \mathbb{E}\left[n^2v_K \cdot\mathbb{I}[X_n = v_K] \mid\mathcal{F}_t\right] \, , \tag*{(19)}
\end{aligned} E [ D ∣ F t ] = s = 1 ∑ n E [ X s ⋅ I [ T ≤ s ] ∣ F t ] + E [ n 2 v K ⋅ I [ X n = v K ] ∣ F t ] ≥ E [ X t ∣ F t ] ⋅ Pr [ T ≤ t ] + s = t + 1 ∑ n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] + E [ n 2 v K ⋅ I [ X n = v K ] ∣ F t ] ≥ X t ⋅ Pr [ T ≤ t ] + s = t + 1 ∑ n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] + E [ n 2 v K ⋅ I [ X n = v K ] ∣ F t ] , (19)
where the first inequality uses the independence of T T T and observations. In light of (19) , we next focus on lower-bounding the second and third terms above. We argue
∑ s = t + 1 n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] = ∑ s = t + 1 n E [ E [ X s ∣ H , F t ] ∣ F t ] ⋅ Pr [ T ≤ s ] = E [ μ H ∣ F t ] ⋅ ∑ s = t + 1 n Pr [ T ≤ s ] , \begin{aligned}
\sum_{s=t+1}^{n} \mathbb{E}[X_s \mid\mathcal{F}_t] \cdot\Pr[T \le s] = \sum_{s=t+1}^{n} \mathbb{E}\left[\mathbb{E}[X_s \mid H,\mathcal{F}_t] \mid\mathcal{F}_t\right] \cdot\Pr[T \le s] \\
&= \mathbb{E}[\mu_H \mid\mathcal{F}_t] \cdot\sum_{s=t+1}^{n} \Pr[T \le s] \, ,
\end{aligned} s = t + 1 ∑ n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] = s = t + 1 ∑ n E [ E [ X s ∣ H , F t ] ∣ F t ] ⋅ Pr [ T ≤ s ] = E [ μ H ∣ F t ] ⋅ s = t + 1 ∑ n Pr [ T ≤ s ] ,
where the second equality uses the fact that the observations are conditionally IID given H H H . In other words, E [ X s ∣ F t ] \mathbb{E}[X_s \mid\mathcal{F}_t] E [ X s ∣ F t ] is identical for all s > t s > t s > t and is equal to E [ μ H ∣ F t ] \mathbb{E}[\mu_H \mid\mathcal{F}_t] E [ μ H ∣ F t ] , where μ h \mu_h μ h is the expectation of D ( h ) D^{(h)} D ( h ) . We henceforth use the notation μ t = E [ μ H ∣ F t ] \mu_t = \mathbb{E}[\mu_H \mid\mathcal{F}_t] μ t = E [ μ H ∣ F t ] .
Now, to show that D D D is a dual certificate, we analyze μ t \mu_t μ t and W t = ∑ s = t + 1 n Pr [ T ≤ s ] W_t = \sum_{s=t+1}^{n} \Pr[T \le s] W t = ∑ s = t + 1 n Pr [ T ≤ s ] . Let M t = max s ≤ t X s M_t = \max_{s \le t} X_s M t = max s ≤ t X s . To analyze μ t \mu_t μ t , suppose that M t = v j = n 3 j M_t = v_j = n^{3j} M t = v j = n 3 j for some j ∈ [ K ] j \in[K] j ∈ [ K ] and define d = K − j d = K-j d = K − j , where we note that if M t = 1 M_t = 1 M t = 1 , we have E [ D ∣ F t ] ≥ X t = 1 \mathbb{E}[D \mid\mathcal{F}_t] \ge X_t = 1 E [ D ∣ F t ] ≥ X t = 1 trivially. To simplify the notation, let
p = 1 n 2 , q = 1 − p , z = q t , a = z n 3 . p = \frac{1}{n^2}, \qquad q = 1-p, \qquad z = q^t, \qquad a = \frac{z}{n^3}. p = n 2 1 , q = 1 − p , z = q t , a = n 3 z .
On the one hand, a simple calculation for the posterior shows that the posterior at time t t t only depends on M t M_t M t and, for 0 ≤ r ≤ d 0 \le r \le d 0 ≤ r ≤ d , that
Pr [ H = j + r ∣ F t , M t = v j ] = Pr [ H = j + r ∣ M t = v j ] = a r S d , where S d = ∑ r = 0 d a r = 1 − a d + 1 1 − a . \Pr[H = j+r \mid\mathcal{F}_t,M_t = v_j] = \Pr[H = j+r \mid M_t = v_j] = \frac{a^r}{S_d}, \qquad\text{where } S_d = \sum_{r=0}^{d} a^r = \frac{1-a^{d+1}}{1-a}. Pr [ H = j + r ∣ F t , M t = v j ] = Pr [ H = j + r ∣ M t = v j ] = S d a r , where S d = r = 0 ∑ d a r = 1 − a 1 − a d + 1 .
See Appendix § 8 .§ 1.1 for a quick proof.
On the other hand, the contribution of world H = j + r H = j+r H = j + r to μ t \mu_t μ t comes mostly from the largest value in its support, which is v j + r = n 3 ( j + r ) v_{j+r} = n^{3(j+r)} v j + r = n 3 ( j + r ) and conditional on H = j + r H = j+r H = j + r , it occurs at time t + 1 t+1 t + 1 with probability p p p . We thus have for every j ∈ [ K ] j \in[K] j ∈ [ K ] :
μ t ≥ ∑ r = 0 d Pr [ H = j + r ∣ M t = v j ] ⋅ p v j + r = ∑ r = 0 d a r S d ⋅ p n 3 r v j = p v j S d ∑ r = 0 d z r . (20) \mu_t \ge\sum_{r=0}^{d} \Pr[H = j+r \mid M_t = v_j] \cdot p v_{j+r} = \sum_{r=0}^{d} \frac{a^r}{S_d} \cdot p n^{3r}v_j = \frac{p v_j}{S_d}\sum_{r=0}^{d} z^r \, . \tag*{(20)} μ t ≥ r = 0 ∑ d Pr [ H = j + r ∣ M t = v j ] ⋅ p v j + r = r = 0 ∑ d S d a r ⋅ p n 3 r v j = S d p v j r = 0 ∑ d z r . (20)
We define
m t ∗ = 1 − z p ( 1 − a ) = 1 − q t p ( 1 − q t / n 3 ) . m_t^* = \frac{1-z}{p(1-a)} = \frac{1-q^t}{p(1-q^t/n^3)} \, . m t ∗ = p ( 1 − a ) 1 − z = p ( 1 − q t / n 3 ) 1 − q t .
Claim 2. For all sufficiently large n n n and 2 ≤ t ≤ n 2 \le t \le n 2 ≤ t ≤ n , we have m t ∗ ≤ t m_t^* \le t m t ∗ ≤ t .
Proof of this claim is in Appendix § 8 .§ 1.2 .
Let c ( x ) = Pr [ T ≤ x ] c(x)=\Pr[T \le x] c ( x ) = Pr [ T ≤ x ] and so W t = ∑ s = t + 1 n c ( s ) W_t=\sum_{s=t+1}^{n}c(s) W t = ∑ s = t + 1 n c ( s ) . The density of T T T gives c ( x ) = max { 0 , 1 − ln ( n / x ) } c(x)=\max\{0,1-\ln(n/x)\} c ( x ) = max { 0 , 1 − ln ( n / x )} for 0 < x ≤ n 0 < x \le n 0 < x ≤ n . Since c ( x ) c(x) c ( x ) is increasing, for every t ∈ [ n ] t \in[n] t ∈ [ n ] we have
W t = ∑ s = t + 1 n c ( s ) ≥ ∫ t n c ( s ) d s = max { t , n / e } ( 1 − c ( t ) ) . W_t=\sum_{s=t+1}^{n}c(s)\ge\int_t^n c(s)\,ds=\max\{t,n/e\}(1-c(t)). W t = s = t + 1 ∑ n c ( s ) ≥ ∫ t n c ( s ) d s = max { t , n / e } ( 1 − c ( t )) .
For 2 ≤ t < n 2 \le t < n 2 ≤ t < n , Claim 2 gives m t ∗ ≤ t m_t^* \le t m t ∗ ≤ t . At t = 1 t=1 t = 1 , we instead have m 1 ∗ = 1 / ( 1 − q / n 3 ) ≤ n / e m_1^*=1/(1-q/n^3)\le n/e m 1 ∗ = 1/ ( 1 − q / n 3 ) ≤ n / e for n ≥ 3 n \ge3 n ≥ 3 .
Thus, for every t ∈ [ n ] t \in[n] t ∈ [ n ] , we obtain
W t ≥ m t ∗ ( 1 − c ( t ) ) . (21) W_t\ge m_t^*(1-c(t)). \tag*{(21)} W t ≥ m t ∗ ( 1 − c ( t )) . (21)
Now, multiplying (20) by m t ∗ = ( 1 − z ) / ( p ( 1 − a ) ) m_t^*=(1-z)/(p(1-a)) m t ∗ = ( 1 − z ) / ( p ( 1 − a )) gives
m t ∗ μ t ≥ v j ( 1 − a ) S d ( 1 − z ) ∑ r = 0 d z r = v j 1 − z d + 1 1 − a d + 1 ≥ v j ( 1 − z d + 1 ) . m_t^*\mu_t\ge\frac{v_j}{(1-a)S_d}(1-z)\sum_{r=0}^{d}z^r=v_j\frac{1-z^{d+1}}{1-a^{d+1}}\ge v_j(1-z^{d+1}). m t ∗ μ t ≥ ( 1 − a ) S d v j ( 1 − z ) r = 0 ∑ d z r = v j 1 − a d + 1 1 − z d + 1 ≥ v j ( 1 − z d + 1 ) .
By (21) , we have
∑ s = t + 1 n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] = W t μ t ≥ m t ∗ μ t ( 1 − c ( t ) ) ≥ v j ( 1 − z d + 1 ) ( 1 − c ( t ) ) , (22) \sum_{s=t+1}^{n}\mathbb{E}[X_s\mid\mathcal{F}_t]\cdot\Pr[T\le s]=W_t\mu_t\ge m_t^*\mu_t(1-c(t))\ge v_j(1-z^{d+1})(1-c(t)), \tag*{(22)} s = t + 1 ∑ n E [ X s ∣ F t ] ⋅ Pr [ T ≤ s ] = W t μ t ≥ m t ∗ μ t ( 1 − c ( t )) ≥ v j ( 1 − z d + 1 ) ( 1 − c ( t )) , (22)
which is the second term in (19) . We now lower bound the third term in (19) . Using the posterior formula, we have for t < n t<n t < n and on the event { M t = v j } \{M_t=v_j\} { M t = v j } :
E [ n 2 v K I [ X n = v K ] ∣ F t ] = v K ⋅ Pr [ H = K ∣ F t ] = v K a d S d = v j z d S d ≥ v j z d ( 1 − a ) ≥ v j z d + 1 , (23) \begin{aligned}
\mathbb{E}[n^2v_K\mathbb{I}[X_n=v_K]\mid\mathcal{F}_t]=v_K\cdot\Pr[H=K\mid\mathcal{F}_t] \\
&=v_K\frac{a^d}{S_d}=\frac{v_jz^d}{S_d}\ge v_jz^d(1-a)\ge v_jz^{d+1}, \tag*{(23)}
\end{aligned} E [ n 2 v K I [ X n = v K ] ∣ F t ] = v K ⋅ Pr [ H = K ∣ F t ] = v K S d a d = S d v j z d ≥ v j z d ( 1 − a ) ≥ v j z d + 1 , (23)
where the first inequality follows from S d = ∑ r = 0 d a r ≤ 1 / ( 1 − a ) S_d=\sum_{r=0}^{d}a^r\le1/(1-a) S d = ∑ r = 0 d a r ≤ 1/ ( 1 − a ) and the second inequality follows from 1 − z ≥ p ≥ a 1-z\ge p\ge a 1 − z ≥ p ≥ a .
Plugging in (22) and (23) in (19) gives, for t < n t<n t < n and on the event { M t = v j } \{M_t=v_j\} { M t = v j } , that
E [ D ∣ F t ] ≥ c ( t ) X t + v j ( 1 − z d + 1 ) ( 1 − c ( t ) ) + v j z d + 1 ≥ c ( t ) X t + v j ( 1 − z d + 1 ) ( 1 − c ( t ) ) + v j z d + 1 ( 1 − c ( t ) ) = c ( t ) X t + v j ( 1 − c ( t ) ) ≥ c ( t ) X t + X t ( 1 − c ( t ) ) = X t . \begin{aligned}
\mathbb{E}[D\mid\mathcal{F}_t]&\ge c(t)X_t+v_j(1-z^{d+1})(1-c(t))+v_jz^{d+1}\\
&\ge c(t)X_t+v_j(1-z^{d+1})(1-c(t))+v_jz^{d+1}(1-c(t))\\
&=c(t)X_t+v_j(1-c(t))\\
&\ge c(t)X_t+X_t(1-c(t))\\
&=X_t.
\end{aligned} E [ D ∣ F t ] ≥ c ( t ) X t + v j ( 1 − z d + 1 ) ( 1 − c ( t )) + v j z d + 1 ≥ c ( t ) X t + v j ( 1 − z d + 1 ) ( 1 − c ( t )) + v j z d + 1 ( 1 − c ( t )) = c ( t ) X t + v j ( 1 − c ( t )) ≥ c ( t ) X t + X t ( 1 − c ( t )) = X t .
For t = n t=n t = n , D D D includes X n X_n X n as a summand and the dominance holds trivially. Hence, D D D is indeed a dual certificate. Thus, we have E [ D ] ≥ O N \mathbb{E}[D]\ge\mathrm{ON} E [ D ] ≥ ON . Recalling (15) completes the proof.
Algorithm of thm:iid-comp
Our algorithm proceeds as follows. First, we identify the world h ⋆ h^\star h ⋆ that has the highest contribution to the expected reward of OFF \operatorname{OFF} OFF , which implies π h ⋆ E [ OFF ∣ H = h ⋆ ] ≥ OFF / K \pi_{h^\star}\mathbb{E}[\operatorname{OFF}\mid H=h^\star]\geq\operatorname{OFF}/K π h ⋆ E [ OFF ∣ H = h ⋆ ] ≥ OFF / K . Next, we select α K = 1 / e + 1 / K \alpha_K=1/e+1/K α K = 1/ e + 1/ K and β K = 1 / e − 2 / ( e K 2 ) \beta_K=1/e-2/(eK^2) β K = 1/ e − 2/ ( e K 2 ) . Finally, we use the algorithm of Bai et al. [3 ] with parameters α K , β K \alpha_K,\beta_K α K , β K and the candidate distribution D h ⋆ \mathcal{D}_{h^\star} D h ⋆ . We recall that Bai et al. [3 ] consider an IID optimal stopping problem where n n n observations are generated from a distribution D 0 \mathcal{D}_0 D 0 . Given a candidate distribution D \mathcal{D} D and feasible ( α , β ) (\alpha,\beta) ( α , β ) , the authors develop an algorithm that is α \alpha α -competitive if D 0 = D \mathcal{D}_0=\mathcal{D} D 0 = D , and β \beta β -competitive otherwise.
If ( α K , β K ) (\alpha_K,\beta_K) ( α K , β K ) is feasible, a simple calculation shows that our algorithm has an expected reward of at least
α K ⋅ E [ OFF ⋅ I [ H = h ] ] + β K ⋅ E [ OFF ⋅ I [ H ≠ h ] ] = ( α K − β K ) ⋅ E [ OFF ⋅ I [ H = h ] ] + β K ⋅ OFF ≥ ( α K − β K K + β K ) ⋅ OFF ≥ ( 1 e + 1 − 2 / e K 2 ) ⋅ OFF . (24) \begin{aligned}
\alpha_K\cdot\mathbb{E}[\operatorname{OFF}\cdot\mathbb{I}[H=h]]+\beta_K\cdot\mathbb{E}[\operatorname{OFF}\cdot\mathbb{I}[H\ne h]]
&=(\alpha_K-\beta_K)\cdot\mathbb{E}[\operatorname{OFF}\cdot\mathbb{I}[H=h]]+\beta_K\cdot\operatorname{OFF}\\
&\geq\left(\frac{\alpha_K-\beta_K}{K}+\beta_K\right)\cdot\operatorname{OFF}\\
&\geq\left(\frac{1}{e}+\frac{1-2/e}{K^2}\right)\cdot\operatorname{OFF}. \tag*{(24)}
\end{aligned} α K ⋅ E [ OFF ⋅ I [ H = h ]] + β K ⋅ E [ OFF ⋅ I [ H = h ]] = ( α K − β K ) ⋅ E [ OFF ⋅ I [ H = h ]] + β K ⋅ OFF ≥ ( K α K − β K + β K ) ⋅ OFF ≥ ( e 1 + K 2 1 − 2/ e ) ⋅ OFF . (24)
Thus, it suffices to show ( α K , β K ) (\alpha_K,\beta_K) ( α K , β K ) is feasible. To this end, we leverage Theorem 1 of Bai et al. [3 ] , that provides sufficient conditions for feasibility of α \alpha α and β \beta β , to prove the following lemma:
Lemma 8. For every integer K ≥ 1 K\geq1 K ≥ 1 , the pair ( α K , β K ) (\alpha_K,\beta_K) ( α K , β K ) with
α K = 1 e + 1 K ^ , β K = 1 e − 2 e K ^ 2 , K ^ = max { K , 39 } \alpha_K=\frac{1}{e}+\frac{1}{\widehat{K}},\qquad\beta_K=\frac{1}{e}-\frac{2}{e\widehat{K}^2},\qquad\widehat{K}=\max\{K,39\} α K = e 1 + K 1 , β K = e 1 − e K 2 2 , K = max { K , 39 } is feasible for Bai et al. [3 ] . That is, for every horizon n n n and candidate distribution D ^ \widehat{\mathcal{D}} D , there exists an online stopping algorithm that is α K \alpha_K α K -competitive when the observations are drawn IID from D ^ \widehat{\mathcal{D}} D , and β K \beta_K β K -competitive when they are drawn IID from any other distribution D \mathcal{D} D .
This lemma is proved in Appendix § 8 .§ 2 . Note that by this result, ( α K , β K ) (\alpha_K,\beta_K) ( α K , β K ) is feasible for every K ≥ 39 K\geq39 K ≥ 39 . Therefore, (24) implies that our algorithm is ( 1 / e + ( 1 − 2 / e ) / K 2 ) (1/e+(1-2/e)/K^2) ( 1/ e + ( 1 − 2/ e ) / K 2 ) -competitive, as desired. For K < 39 K<39 K < 39 , we use the algorithm for K = 39 K=39 K = 39 , i.e, we set α = 1 / e + 1 / 39 \alpha=1/e+1/39 α = 1/ e + 1/39 and β K = 1 / e − 2 / ( e ⋅ 39 2 ) \beta_K=1/e-2/(e\cdot39^2) β K = 1/ e − 2/ ( e ⋅ 3 9 2 ) . Then, the bound in (24) becomes
( 1 e + 1 39 K − 2 ( K − 1 ) 39 e K 2 ) ⋅ OFF ≥ ( 1 e + 1 39 K 2 ) OFF for every K ≥ 1 , \left(\frac{1}{e}+\frac{1}{39K}-\frac{2(K-1)}{39eK^2}\right)\cdot\operatorname{OFF}\geq\left(\frac{1}{e}+\frac{1}{39K^2}\right)\operatorname{OFF}\qquad\text{for every }K\geq1, ( e 1 + 39 K 1 − 39 e K 2 2 ( K − 1 ) ) ⋅ OFF ≥ ( e 1 + 39 K 2 1 ) OFF for every K ≥ 1 ,
which completes the proof of the lower bound in Theorem 4 with c ′ = min { 1 / 39 , 1 − 2 / e } = 1 / 39 c'=\min\{1/39,1-2/e\}=1/39 c ′ = min { 1/39 , 1 − 2/ e } = 1/39 .
Conclusion and Open Questions
In this work, we propose Bayesian models as a middle ground between pessimistic, adversarial models and optimistic, fully known stochastic models. We study this question in the context of Bayesian optimal stopping. In these models, the decision-maker learns about the hidden world while making decisions, and the Bayes-optimal policy accounts for both the value of learning and the value of waiting. Our results show a stark separation between philosopher and prophet inequalities. On the one hand, the Bayes-optimal policy admits efficient approximation schemes, despite being defined by an exponentially large dynamic program. On the other hand, no online algorithm can substantially surpass the worst-case competitive ratios against the prophet when the prior is broad enough, i.e., when K K K is large.
The central idea of our approximation scheme is to start with a baseline algorithm and improve it iteratively. Each improvement step randomizes between the current algorithm and thresholds set relative to a dual martingale, which upper bounds the value function of the Bayesian DP. The same step also shrinks the dual martingale, so that the improved algorithm is competitive against a tighter one and the step can be repeated. Because the shrinkage acts on each sample path separately, the dual martingales can be approximated efficiently by Monte Carlo sampling. Together, these ingredients give an approximation scheme for Bayesian optimal stopping, which is a PTAS in the IID model and in the NON-IID model with K = O ( 1 ) K=O(1) K = O ( 1 ) .
For prophet inequalities, we construct an explicit IID instance on which no online algorithm is better than ( 1 / e + O ( 1 / K ) ) (1/e+O(1/\sqrt{K})) ( 1/ e + O ( 1/ K )) -competitive. Rather than analyzing the Bayesian DP on this instance, we bound the reward of every online algorithm by an explicit dual martingale. Thus, dual martingales serve both for designing algorithms and for proving hardness results.
Several directions and open questions emerge from this paper.
Information model. In this work, we assume access to a probability oracle and a value oracle. This assumption is stronger than access to a sample oracle that returns fresh samples from the conditional distribution given the history. However, our results in Appendix § 6 .§ 3 show that such sample oracles cannot yield approximation ratios better than a constant, even in the IID model with K = 1 K=1 K = 1 . It would therefore be interesting to explore information models in between, especially for the CORREL model. Relatedly, identifying meaningful classes of problems within the CORREL model but outside the NON-IID model that admit compact representations and approximation schemes is another fruitful direction.
Better computational efficiency. In this work, we obtain approximation schemes for the CORREL and NON-IID models and a PTAS for the IID model. Are better runtimes possible, e.g., can the optimal algorithm be computed in polynomial time? Or is the CORREL model, or even the NON-IID model, APX-hard? The NON-IID model is of particular interest: although the problem
is well-structured, we are not aware of any genuinely polynomial-time approximation scheme for it, and our limited human- and AI-based efforts to find one have been unsuccessful even to obtain a constant-factor approximation.
Combinatorial problems. We view this work as a stepping stone toward designing Bayesian models and algorithms for more general online decision-making problems. Can similar algorithms be developed for problems with a combinatorial feasible set, such as online matching? Our machinery readily extends to multi-unit selection when the budget is O ( 1 ) O(1) O ( 1 ) , but beyond that, we are not aware of straightforward extensions. What about other online problems with a different structure?
AI usage disclosure. The majority of ideas were from the authors, with ChatGPT models 5.3-6 used for brainstorming and honing human ideas. Notable parts with input from AI were the randomization over Q Q Q in A t h r \mathcal{A}_{\mathrm{thr}} A thr in Algorithm 1 when given the algorithm with a deterministic Q = q Q=q Q = q , and the construction of the dual martingale for the hardness proof of competitive ratio in Lemma 7, which were then simplified and modified by the authors; the authors previously had a technical argument for the proof of Lemma 7 that was based on an analysis of the Bayesian dynamic program. The paper was fully written by the authors, with those ChatGPT models and Claude Opus 5.5 used for minor editorial purposes to improve the exposition. The authors verified the correctness and originality of all content, including references.
Omitted Proofs from § 1
Performance of History-oblivious Algorithms
The next proposition shows that no history-oblivious algorithm can guarantee a constant-factor competitive ratio. An algorithm is history-oblivious if its decision at time t t t is independent of X 1 , … , X t − 1 X_1,\ldots,X_{t-1} X 1 , … , X t − 1 . The proposition relies on the construction and definitions in § 4.1 .
Proposition 4. For every ε > 0 \varepsilon> 0 ε > 0 , there exists an instance of the Bayesian optimal stopping problem in which every history-oblivious online algorithm A \mathcal{A} A satisfies r ( A ) ≤ ε O N r(\mathcal{A}) \le\varepsilon ON r ( A ) ≤ εO N , where O N ON O N is the Bayes-optimal algorithm defined in (1) .
Proof. We use the same hard instance from § 4.1 , shown in Table 1 . Recall Equation (18) in the proof of Lemma 7 that gives
OFF = n 2 K c K ( 1 + O ( 1 n ) ) , (25) \operatorname{OFF} = \frac{n^2 K}{c_K}\left(1+O\left(\frac{1}{n}\right)\right), \tag*{(25)} OFF = c K n 2 K ( 1 + O ( n 1 ) ) , (25)
where OFF = E [ max t ∈ [ n ] X t ] \operatorname{OFF}=\mathbb{E}\left[\max_{t\in[n]}X_t\right] OFF = E [ max t ∈ [ n ] X t ] denotes the expected reward of the offline benchmark. We choose K = n 2 K=n^2 K = n 2 so that every supported value greater than 1 1 1 has probability at least 1 / ( e n 2 ) 1/(en^2) 1/ ( e n 2 ) , i.e.
Pr [ X t = v j ∣ H = h ] = 1 n 2 ( 1 − 1 n 2 ) h − j ≥ 1 n 2 ( 1 − 1 n 2 ) K − 1 ≥ 1 e n 2 (26) \Pr[X_t=v_j\mid H=h]=\frac{1}{n^2}\left(1-\frac{1}{n^2}\right)^{h-j}\ge\frac{1}{n^2}\left(1-\frac{1}{n^2}\right)^{K-1}\ge\frac{1}{en^2} \tag*{(26)} Pr [ X t = v j ∣ H = h ] = n 2 1 ( 1 − n 2 1 ) h − j ≥ n 2 1 ( 1 − n 2 1 ) K − 1 ≥ e n 2 1 (26)
for every j ≤ h ≤ K j\le h\le K j ≤ h ≤ K , where the last inequality follows from ( 1 − 1 / n 2 ) K − 1 = ( 1 + 1 / ( K − 1 ) ) − ( K − 1 ) ≥ e − 1 (1-1/n^2)^{K-1}=(1+1/(K-1))^{-(K-1)}\ge e^{-1} ( 1 − 1/ n 2 ) K − 1 = ( 1 + 1/ ( K − 1 ) ) − ( K − 1 ) ≥ e − 1 .
Now, take an arbitrary algorithm A \mathcal{A} A whose decision at time t t t depends only on the Bayesian instance (prior π \pi π and world distributions D ( h ) D^{(h)} D ( h ) ), observation X t X_t X t , time t t t , and its internal randomness (represented by seed U U U ). Let τ A \tau_{\mathcal{A}} τ A be its stopping time. At each time t t t , let the algorithm’s acceptance set be
A t = { j ∈ [ K ] : A accepts v j at time t } . A_t=\{j\in[K]:\mathcal{A}\text{ accepts }v_j\text{ at time }t\}. A t = { j ∈ [ K ] : A accepts v j at time t } .
Fix any realization u u u of U U U . Define the expected reward and probability of selecting per-distribution maxima as
r u = E [ X τ A ] and P h = Pr [ X τ A = v h ∣ H = h ] , r_u=\mathbb{E}[X_{\tau_{\mathcal{A}}}]
\quad\text{and}\quad
P_h=\Pr[X_{\tau_{\mathcal{A}}}=v_h\mid H=h], r u = E [ X τ A ] and P h = Pr [ X τ A = v h ∣ H = h ] ,
respectively. Every reward below v h v_h v h is at most v h / n 3 v_h/n^3 v h / n 3 . Thus, using π h v h = n 3 / c K \pi_hv_h=n^3/c_K π h v h = n 3 / c K and (25) , we obtain
r u OFF ≤ ( 1 + O ( 1 n ) ) ( n K ∑ h = 1 K P h + 1 n 2 ) , (27) \frac{r_u}{\operatorname{OFF}}\le\left(1+O\left(\frac{1}{n}\right)\right)\left(\frac{n}{K}\sum_{h=1}^{K}P_h+\frac{1}{n^2}\right), \tag*{(27)} OFF r u ≤ ( 1 + O ( n 1 ) ) ( K n h = 1 ∑ K P h + n 2 1 ) , (27)
To bound ∑ h P h \sum_h P_h ∑ h P h , we compare each accepted value with the smaller values the algorithm would also accept at the same time t t t . For an integer 1 ≤ L ≤ K 1 \le L \le K 1 ≤ L ≤ K , to be chosen below, let A t − A_t^{-} A t − contain the min { ∣ A t ∣ , L } \min\{|A_t|,L\} min { ∣ A t ∣ , L } smallest indices in A t A_t A t , and let A t + = A t ∖ A t − A_t^{+}=A_t\setminus A_t^{-} A t + = A t ∖ A t − . First, consider all pairs ( t , h ) (t,h) ( t , h ) such that h ∈ A t − h\in A_t^{-} h ∈ A t − . The probability of selecting v h v_h v h at time t t t in world h h h is at most 1 / n 2 1/n^2 1/ n 2 , since this is the probability that v h v_h v h appears at that time. Then, taking the union bound over all times t ∈ [ n ] t\in[n] t ∈ [ n ] with h ∈ A t − h\in A_t^{-} h ∈ A t − , these selections contributes at most
∑ t : h ∈ A t − Pr [ τ A = t , X t = v h ∣ H = h ] ≤ L n . (28) \sum_{t:h\in A_t^{-}}\Pr[\tau_A=t,X_t=v_h\mid H=h]\le\frac{L}{n}. \tag*{(28)} t : h ∈ A t − ∑ Pr [ τ A = t , X t = v h ∣ H = h ] ≤ n L . (28)
to ∑ h P h \sum_h P_h ∑ h P h . Next, whenever h ∈ A t + h\in A_t^{+} h ∈ A t + , we have
Pr [ τ A = t , X t = v h ∣ H = h ] = 1 n 2 Pr [ τ A ≥ t ∣ H = h ] ≤ e L Pr [ τ A = t ∣ H = h ] , (29) \Pr[\tau_A=t,X_t=v_h\mid H=h]=\frac{1}{n^2}\Pr[\tau_A\ge t\mid H=h]\le\frac{e}{L}\Pr[\tau_A=t\mid H=h], \tag*{(29)} Pr [ τ A = t , X t = v h ∣ H = h ] = n 2 1 Pr [ τ A ≥ t ∣ H = h ] ≤ L e Pr [ τ A = t ∣ H = h ] , (29)
where the equality follows because v h v_h v h occurs with probability 1 / n 2 1/n^2 1/ n 2 independently of everything else. For the inequality step, conditional on reaching t t t , the algorithm would also accept the L L L smaller values indexed by A t − A_t^{-} A t − , whose total probability is at least L / ( e n 2 ) L/(en^2) L / ( e n 2 ) by (26) . This gives
Pr [ τ A = t ∣ H = h ] ≥ L e n 2 Pr [ τ A ≥ t ∣ H = h ] , \Pr[\tau_A=t\mid H=h]\ge\frac{L}{en^2}\Pr[\tau_A\ge t\mid H=h], Pr [ τ A = t ∣ H = h ] ≥ e n 2 L Pr [ τ A ≥ t ∣ H = h ] ,
and rearranging yields (29) . Then, summing this inequality over all times t ∈ [ n ] t\in[n] t ∈ [ n ] with h ∈ A t + h\in A_t^{+} h ∈ A t + gives
∑ t : h ∈ A t + Pr [ τ A = t , X t = v h ∣ H = h ] ≤ e L ∑ t : h ∈ A t + Pr [ τ A = t ∣ H = h ] ≤ e L , (30) \sum_{t:h\in A_t^{+}}\Pr[\tau_A=t,X_t=v_h\mid H=h]\le\frac{e}{L}\sum_{t:h\in A_t^{+}}\Pr[\tau_A=t\mid H=h]\le\frac{e}{L}, \tag*{(30)} t : h ∈ A t + ∑ Pr [ τ A = t , X t = v h ∣ H = h ] ≤ L e t : h ∈ A t + ∑ Pr [ τ A = t ∣ H = h ] ≤ L e , (30)
where the last inequality follows because the stopping events at distinct times are mutually exclusive. Combining (28) and (30) , we obtain ∑ h = 1 K P h ≤ L n + K e L \sum_{h=1}^{K}P_h\le\frac{L}{n}+\frac{Ke}{L} ∑ h = 1 K P h ≤ n L + L K e . Substituting into (27) , we infer
r u O F F ≤ ( 1 + O ( 1 n ) ) ( L K + e n L + 1 n 2 ) . (31) \frac{r_u}{\mathrm{OFF}}\le\left(1+O\left(\frac{1}{n}\right)\right)\left(\frac{L}{K}+\frac{en}{L}+\frac{1}{n^2}\right). \tag*{(31)} OFF r u ≤ ( 1 + O ( n 1 ) ) ( K L + L e n + n 2 1 ) . (31)
Choose L = ⌈ n 3 / 2 ⌉ ≤ K L=\lceil n^{3/2}\rceil\le K L = ⌈ n 3/2 ⌉ ≤ K . Since K = n 2 K=n^2 K = n 2 , both L / K L/K L / K and e n / L en/L e n / L are O ( n − 1 / 2 ) O(n^{-1/2}) O ( n − 1/2 ) . Thus, (31) gives
r u O F F = O ( n − 1 / 2 ) , \frac{r_u}{\mathrm{OFF}}=O(n^{-1/2}), OFF r u = O ( n − 1/2 ) ,
for every initial seed U = u U=u U = u .
Finally, the observations are exchangeable. The classical secretary algorithm of Dynkin [17 ] therefore guarantees an expected reward of at least O F F / e \mathrm{OFF}/e OFF / e . Hence, O N ≥ O F F / e \mathrm{ON}\ge\mathrm{OFF}/e ON ≥ OFF / e , and we conclude
r ( A ) O N ≤ e r ( A ) O F F = O ( n − 1 / 2 ) = O ( K − 1 / 4 ) . \frac{r(\mathcal{A})}{\mathrm{ON}}\le e\frac{r(\mathcal{A})}{\mathrm{OFF}}=O(n^{-1/2})=O(K^{-1/4}). ON r ( A ) ≤ e OFF r ( A ) = O ( n − 1/2 ) = O ( K − 1/4 ) .
Constructing Value Oracle from PMFs in IID and NON-IID Models
We explain how the value oracle for the conditional expected reward of the prophet given the information at time t t t , i.e., Z t ( 0 ) = E [ max t ′ ∈ [ n ] X t ′ ∣ F t ] Z_t^{(0)} = \mathbb{E}[\max_{t' \in[n]} X_{t'} \mid\mathcal{F}_t] Z t ( 0 ) = E [ max t ′ ∈ [ n ] X t ′ ∣ F t ] , can be computed exactly only from the PMFs when the observations are conditionally independent given H H H . Indeed, we have
Z t ( 0 ) = E [ M 0 ∣ F t ] = E [ E [ M 0 ∣ H , F t ] ∣ F t ] . Z_t^{(0)} = \mathbb{E}[M_0 \mid\mathcal{F}_t] = \mathbb{E}[\mathbb{E}[M_0 \mid H,\mathcal{F}_t] \mid\mathcal{F}_t]. Z t ( 0 ) = E [ M 0 ∣ F t ] = E [ E [ M 0 ∣ H , F t ] ∣ F t ] .
Thus, we first compute E [ M 0 ∣ H = k , F t ] \mathbb{E}[M_0 \mid H = k,\mathcal{F}_t] E [ M 0 ∣ H = k , F t ] for every k ∈ [ K ] k \in[K] k ∈ [ K ] , and then, we average these values by the posterior distribution, which satisfies Pr [ H = k ∣ F t ] ∝ π k ∏ s = 1 t Pr [ X s = x s ∣ H = k ] \Pr[H = k \mid\mathcal{F}_t] \propto\pi_k \prod_{s=1}^{t} \Pr[X_s = x_s \mid H = k] Pr [ H = k ∣ F t ] ∝ π k ∏ s = 1 t Pr [ X s = x s ∣ H = k ] for the observed history h t = ( x 1 , … , x t ) h_t = (x_1,\ldots,x_t) h t = ( x 1 , … , x t ) . Suppose that v q ∗ v_{q^*} v q ∗ is the maximum value observed so far in history h t h_t h t . Given that we have access to the distributions, and that the future samples are independent conditionally on H H H , we can write
E [ M 0 ∣ H = k , F t ] = v q ∗ + ∑ q = q ∗ + 1 m ( v q − v q − 1 ) Pr [ M 0 ≥ v q ∣ H = k , F t ] = v q ∗ + ∑ q = q ∗ + 1 m ( v q − v q − 1 ) Pr [ max { X t + 1 , … , X n } ≥ v q ∣ H = k ] = v q ∗ + ∑ q = q ∗ + 1 m ( v q − v q − 1 ) ( 1 − ∏ s = t + 1 n Pr [ X s < v q ∣ H = k ] ) . \begin{aligned}
\mathbb{E}[M_0 \mid H = k,\mathcal{F}_t] &= v_{q^*} + \sum_{q=q^*+1}^{m} (v_q-v_{q-1})\Pr[M_0 \geq v_q \mid H = k,\mathcal{F}_t] \\
&= v_{q^*} + \sum_{q=q^*+1}^{m} (v_q-v_{q-1})\Pr[\max\{X_{t+1},\ldots,X_n\} \geq v_q \mid H = k] \\
&= v_{q^*} + \sum_{q=q^*+1}^{m} (v_q-v_{q-1})\left(1-\prod_{s=t+1}^{n}\Pr[X_s < v_q \mid H = k]\right).
\end{aligned} E [ M 0 ∣ H = k , F t ] = v q ∗ + q = q ∗ + 1 ∑ m ( v q − v q − 1 ) Pr [ M 0 ≥ v q ∣ H = k , F t ] = v q ∗ + q = q ∗ + 1 ∑ m ( v q − v q − 1 ) Pr [ max { X t + 1 , … , X n } ≥ v q ∣ H = k ] = v q ∗ + q = q ∗ + 1 ∑ m ( v q − v q − 1 ) ( 1 − s = t + 1 ∏ n Pr [ X s < v q ∣ H = k ] ) .
The right-hand side depends on the history only through q ∗ q^* q ∗ . Its values, over all k ∈ [ K ] k \in[K] k ∈ [ K ] , t ∈ [ n ] t \in[n] t ∈ [ n ] , and q ∗ ∈ [ m ] q^* \in[m] q ∗ ∈ [ m ] , can be tabulated once using O ( K m n ) O(Kmn) O ( K mn ) reads from the PMF and O ( K m n ) O(Kmn) O ( K mn ) arithmetic operations: the products ∏ s = t + 1 n Pr [ X s < v q ∣ H = k ] \prod_{s=t+1}^{n}\Pr[X_s < v_q \mid H = k] ∏ s = t + 1 n Pr [ X s < v q ∣ H = k ] follow from a backward recursion over t t t , and the sums over q q q from a backward recursion over q ∗ q^* q ∗ . Given this table, and since the posterior weights can be updated in O ( K ) O(K) O ( K ) time per observation, we can compute Z t ( 0 ) Z_t^{(0)} Z t ( 0 ) in O ( K ) O(K) O ( K ) time.
Hardness of Approximation with Sampling Oracles
We now consider an information model different from the one used throughout the paper: given any feasible history h t = ( x 1 , … , x t ) h_t = (x_1,\ldots,x_t) h t = ( x 1 , … , x t ) , we assume access to a sample oracle that returns an independent sample from L ( X t + 1 ∣ X 1 : t = h t ) \mathcal{L}(X_{t+1} \mid X_{1:t} = h_t) L ( X t + 1 ∣ X 1 : t = h t ) . This is the information model used by Chen and Goldberg [8 ] .
Proposition 5. For every ε > 0 \varepsilon> 0 ε > 0 and every polynomial-time algorithm A \mathcal{A} A with a sample-access oracle, there exists an instance of the Bayesian IID optimal stopping problem in which we have
r ( A ) O N ≤ 6 7 + ε , \frac{r(\mathcal{A})}{\mathrm{ON}} \leq\frac{6}{7}+\varepsilon, ON r ( A ) ≤ 7 6 + ε , where O N \mathrm{ON} ON is the Bayes-optimal algorithm that has full information of the distributions without any constraints on its runtime.
Proof. Fix an algorithm A \mathcal{A} A . We construct two simple instances of IID prophet inequality problem, i.e., K = 1 K=1 K = 1 . We show that an algorithm that has only sample access cannot obtain substantially different rewards between these two instances. From this, we infer that A \mathcal{A} A cannot obtain reward more than 6 7 O N \frac{6}{7}\mathrm{ON} 7 6 ON in at least one of these instances which proves the proposition.
In both instances, we set n = 2 n=2 n = 2 and K = 1 K=1 K = 1 . Consider an integer λ ≥ 2 \lambda\ge2 λ ≥ 2 , and let
L λ = 2 2 λ , d 0 = 2 − 3 λ , d 1 = 2 − λ . L_\lambda= 2^{2\lambda}, \qquad d_0 = 2^{-3\lambda}, \qquad d_1 = 2^{-\lambda}. L λ = 2 2 λ , d 0 = 2 − 3 λ , d 1 = 2 − λ .
In instance I i , λ \mathcal{I}_{i,\lambda} I i , λ , the observations X 1 , X 2 X_1,X_2 X 1 , X 2 are independent draws from D i D_i D i , where
D i = { 0 , with probability 1 2 − d i , 1 , with probability 1 2 , L λ , with probability d i . D_i =
\begin{cases}
0, & \text{with probability } \frac{1}{2}-d_i,\\
1, & \text{with probability } \frac{1}{2},\\
L_\lambda, & \text{with probability } d_i.
\end{cases} D i = ⎩ ⎨ ⎧ 0 , 1 , L λ , with probability 2 1 − d i , with probability 2 1 , with probability d i .
Notice that the index i i i labels the instance, not a hidden world; both instances have K = 1 K=1 K = 1 and the same support { 0 , 1 , L λ } \{0,1,L_\lambda\} { 0 , 1 , L λ } . The algorithm is not given the probabilities; rather, it can request a fresh sample from the conditional law given any history.
The IID structure implies that every conditional sampling query returns a fresh draw from D i D_i D i , regardless of the supplied history. In particular, querying simulated histories does not provide any additional information beyond independent samples. Define
μ i = E i [ X 2 ] = 1 2 + d i L λ , i.e., μ 0 = 1 2 + 2 − λ < 1 , μ 1 = 1 2 + 2 λ > 1. \mu_i = \mathbb{E}_i[X_2] = \frac{1}{2}+d_iL_\lambda, \qquad\text{i.e.,} \qquad\mu_0 = \frac{1}{2}+2^{-\lambda}<1, \qquad\mu_1 = \frac{1}{2}+2^\lambda>1. μ i = E i [ X 2 ] = 2 1 + d i L λ , i.e., μ 0 = 2 1 + 2 − λ < 1 , μ 1 = 2 1 + 2 λ > 1.
In words, μ i \mu_i μ i is the expected value of the second observation in instance I i , λ \mathcal{I}_{i,\lambda} I i , λ . When X 1 = 1 X_1=1 X 1 = 1 , the optimal policy accepts it in instance 0 whereas it rejects X 1 X_1 X 1 and continues in instance 1. In either instance, ON accepts L λ L_\lambda L λ , rejects 0, and accepts the second observation if it has not stopped earlier.
We claim that the polynomial-time algorithm A \mathcal{A} A cannot distinguish these instances, implying almost identical rewards across the two. We may assume that A \mathcal{A} A also accepts L λ L_\lambda L λ and rejects 0 at time 1, and always accepts the second observation if it reaches it. Let
a i = Pr i [ τ A = 1 ∣ X 1 = 1 ] a_i = \Pr_i[\tau_{\mathcal{A}}=1\mid X_1=1] a i = i Pr [ τ A = 1 ∣ X 1 = 1 ]
be the probability of accepting the first observation X 1 = 1 X_1=1 X 1 = 1 when the instance is I i , λ \mathcal{I}_{i,\lambda} I i , λ .
Let O i \mathcal{O}_i O i be the set of samples collected by A \mathcal{A} A when ran on instance I i , λ \mathcal{I}_{i,\lambda} I i , λ . Because A \mathcal{A} A is a polytime algorithm, we have ∣ O i ∣ = poly ( λ ) |\mathcal{O}_i|=\operatorname{poly}(\lambda) ∣ O i ∣ = poly ( λ ) . The total variation distance between D 0 D_0 D 0 and D 1 D_1 D 1 is d 1 − d 0 ≤ 2 − λ d_1-d_0\le2^{-\lambda} d 1 − d 0 ≤ 2 − λ . With ∣ O i ∣ |\mathcal{O}_i| ∣ O i ∣ many calls to the sample oracle, we have TV ( O 1 , O 2 ) ≤ poly ( λ ) ⋅ 2 − λ \operatorname{TV}(\mathcal{O}_1,\mathcal{O}_2)\le\operatorname{poly}(\lambda)\cdot2^{-\lambda} TV ( O 1 , O 2 ) ≤ poly ( λ ) ⋅ 2 − λ . Given that a i ∈ [ 0 , 1 ] a_i\in[0,1] a i ∈ [ 0 , 1 ] is a function of O i \mathcal{O}_i O i , we infer that
∣ a 0 − a 1 ∣ ≤ poly ( λ ) 2 − λ . (32) |a_0-a_1|\le\operatorname{poly}(\lambda)2^{-\lambda}. \tag*{(32)} ∣ a 0 − a 1 ∣ ≤ poly ( λ ) 2 − λ . (32)
We now compare the reward of A \mathcal{A} A in the two instances. Let r i ( A ) = E i [ X τ A ] r_i(\mathcal{A})=\mathbb{E}_i[X_{\tau_{\mathcal{A}}}] r i ( A ) = E i [ X τ A ] . Conditional on reaching the second time, the actual observation X 2 X_2 X 2 still has mean μ i \mu_i μ i . Evaluating r i ( A ) r_i(\mathcal{A}) r i ( A ) by conditioning on X 1 X_1 X 1 gives
r i ( A ) = d i L λ + ( 1 2 − d i ) μ i + 1 2 ( a i + ( 1 − a i ) μ i ) = d i L λ + ( 1 − d i ) μ i + a i 2 ( 1 − μ i ) . (33) \begin{aligned}
r_i(\mathcal{A})&=d_iL_\lambda+\left(\frac{1}{2}-d_i\right)\mu_i+\frac{1}{2}\left(a_i+(1-a_i)\mu_i\right)\\
&=d_iL_\lambda+(1-d_i)\mu_i+\frac{a_i}{2}(1-\mu_i). \tag*{(33)}
\end{aligned} r i ( A ) = d i L λ + ( 2 1 − d i ) μ i + 2 1 ( a i + ( 1 − a i ) μ i ) = d i L λ + ( 1 − d i ) μ i + 2 a i ( 1 − μ i ) . (33)
Conversely, ON knows the distributions and can compute μ 0 < 1 < μ 1 \mu_0<1<\mu_1 μ 0 < 1 < μ 1 . Then, ON sets a 0 = 1 a_0=1 a 0 = 1 and a 1 = 0 a_1=0 a 1 = 0 . Plugging in this optimal choice in the reward formulae yields
ON ( I 0 , λ ) = 3 4 + O ( 2 − λ ) , r 0 ( A ) = 1 2 + a 0 4 + O ( 2 − λ ) , \operatorname{ON}(\mathcal{I}_{0,\lambda})=\frac{3}{4}+O(2^{-\lambda}),\qquad r_0(\mathcal{A})=\frac{1}{2}+\frac{a_0}{4}+O(2^{-\lambda}), ON ( I 0 , λ ) = 4 3 + O ( 2 − λ ) , r 0 ( A ) = 2 1 + 4 a 0 + O ( 2 − λ ) ,
ON ( I 1 , λ ) = 2 λ + 1 + O ( 1 ) , r 1 ( A ) = 2 λ ( 2 − a 1 2 ) + O ( 1 ) . \operatorname{ON}(\mathcal{I}_{1,\lambda})=2^{\lambda+1}+O(1),\qquad r_1(\mathcal{A})=2^\lambda\left(2-\frac{a_1}{2}\right)+O(1). ON ( I 1 , λ ) = 2 λ + 1 + O ( 1 ) , r 1 ( A ) = 2 λ ( 2 − 2 a 1 ) + O ( 1 ) .
We can therefore argue
r 0 ( A ) ON ( I 0 , λ ) = 2 3 + a 0 3 + O ( 2 − λ ) , r 1 ( A ) ON ( I 1 , λ ) = 1 − a 1 4 + O ( 2 − λ ) . \frac{r_0(\mathcal{A})}{\operatorname{ON}(\mathcal{I}_{0,\lambda})}=\frac{2}{3}+\frac{a_0}{3}+O(2^{-\lambda}),\qquad\frac{r_1(\mathcal{A})}{\operatorname{ON}(\mathcal{I}_{1,\lambda})}=1-\frac{a_1}{4}+O(2^{-\lambda}). ON ( I 0 , λ ) r 0 ( A ) = 3 2 + 3 a 0 + O ( 2 − λ ) , ON ( I 1 , λ ) r 1 ( A ) = 1 − 4 a 1 + O ( 2 − λ ) .
Using (32) to replace a 1 a_1 a 1 by a 0 a_0 a 0 gives
min i ∈ { 0 , 1 } r i ( A ) ON ( I i , λ ) ≤ min { 2 3 + a 0 3 , 1 − a 0 4 } + poly ( λ ) ⋅ 2 − λ . \min_{i\in\{0,1\}}\frac{r_i(\mathcal{A})}{\operatorname{ON}(\mathcal{I}_{i,\lambda})}\leq\min\left\{\frac{2}{3}+\frac{a_0}{3},1-\frac{a_0}{4}\right\}+\operatorname{poly}(\lambda)\cdot2^{-\lambda}. i ∈ { 0 , 1 } min ON ( I i , λ ) r i ( A ) ≤ min { 3 2 + 3 a 0 , 1 − 4 a 0 } + poly ( λ ) ⋅ 2 − λ .
The term involving a 0 a_0 a 0 is maximized at a 0 = 4 / 7 a_0=4/7 a 0 = 4/7 with a value of 6 / 7 6/7 6/7 . Thus, we have
min i ∈ { 0 , 1 } r i ( A ) ON ( I i , λ ) ≤ 6 7 + o ( 1 ) as λ → ∞ . \min_{i\in\{0,1\}}\frac{r_i(\mathcal{A})}{\operatorname{ON}(\mathcal{I}_{i,\lambda})}\leq\frac{6}{7}+o(1)\quad\text{as }\lambda\to\infty. i ∈ { 0 , 1 } min ON ( I i , λ ) r i ( A ) ≤ 7 6 + o ( 1 ) as λ → ∞.
The proof is now complete. ▪
Notice that the above proof shows hardness for a classic prophet inequality problem with K = 1 K=1 K = 1 . Thus, such sample access creates a barrier for approximating the online optimum even in the classical setting of prophet inequality. Another implication of K = 1 K=1 K = 1 is that this proposition shows the same hardness for a different sample oracle that, given a world h h h , it returns a fresh sample from D ( h ) D^{(h)} D ( h ) . In general, this sample oracle is not comparable to one that only returns fresh samples conditional on the history, without per world knowledge. Nonetheless, the example above shows that both information access models create a barrier for developing (near) polynomial-time approximation schemes.
Omitted Proofs from sec:approximation
Proof of clm:z-alter-def
For a sample path ω ∈ Ω \omega\in\Omega ω ∈ Ω , recall that ω t \omega_t ω t is its t t t -step prefix. By the definition of the biased probability measure Pr ∗ [ ⋅ ∣ F t ] \Pr_*[\cdot\mid\mathcal{F}_t] Pr ∗ [ ⋅ ∣ F t ] in (10) , we have
E ∗ [ W j ∣ h t ] = ∑ ω ∈ Ω : ω t = h t W j ( ω ) Pr ∗ [ ω ∣ h t ] = ∑ ω ∈ Ω : ω t = h t W j ( ω ) Pr [ ω ∣ h t ] M 0 ( ω ) Z t ( 0 ) ( h t ) = E [ M 0 W j ∣ h t ] Z t ( 0 ) ( h t ) = Z t ( j ) ( h t ) Z t ( 0 ) ( h t ) . \begin{aligned}
\mathbb{E}_*[W_j\mid h_t]=\sum_{\omega\in\Omega:\omega_t=h_t}W_j(\omega)\Pr_*[\omega\mid h_t] \\
&= \sum_{\omega\in\Omega:\,\omega_t=h_t} W_j(\omega)\Pr[\omega\mid h_t]\frac{M_0(\omega)}{Z_t^{(0)}(h_t)}
= \frac{\mathbb{E}[M_0W_j \mid h_t]}{Z_t^{(0)}(h_t)}
= \frac{Z_t^{(j)}(h_t)}{Z_t^{(0)}(h_t)}.
\end{aligned} E ∗ [ W j ∣ h t ] = ω ∈ Ω : ω t = h t ∑ W j ( ω ) ∗ Pr [ ω ∣ h t ] = ω ∈ Ω : ω t = h t ∑ W j ( ω ) Pr [ ω ∣ h t ] Z t ( 0 ) ( h t ) M 0 ( ω ) = Z t ( 0 ) ( h t ) E [ M 0 W j ∣ h t ] = Z t ( 0 ) ( h t ) Z t ( j ) ( h t ) .
The last equality uses M j = M 0 W j M_j=M_0W_j M j = M 0 W j . Multiplying by Z t ( 0 ) ( h t ) Z_t^{(0)}(h_t) Z t ( 0 ) ( h t ) proves the claim.
Sampling from the Biased Distribution
In this subsection, we describe how to exactly and efficiently sample a future trajectory from the biased probability measure Pr ∗ [ ω ∣ F t ] = Pr [ ω ∣ F t ] ⋅ M 0 ( ω ) Z t ( 0 ) \Pr_*[\omega\mid\mathcal{F}_t]=\Pr[\omega\mid\mathcal{F}_t]\cdot\frac{M_0(\omega)}{Z_t^{(0)}} Pr ∗ [ ω ∣ F t ] = Pr [ ω ∣ F t ] ⋅ Z t ( 0 ) M 0 ( ω ) at time t t t , having observed a history h t h_t h t with Z t ( 0 ) ( h t ) > 0 Z_t^{(0)}(h_t)>0 Z t ( 0 ) ( h t ) > 0 .
Let h s h_s h s be the history until time s s s , and recall that F s = σ ( X 1 , … , X s ) \mathcal{F}_s=\sigma(X_1,\ldots,X_s) F s = σ ( X 1 , … , X s ) is the natural filtration generated by the history. Also, recall that ω s \omega_s ω s is the s s s -prefix of ω \omega ω , i.e., the first s s s samples under ω \omega ω , and let X s ( ω ) X_s(\omega) X s ( ω ) be exactly the s s s -th observation under ω \omega ω . We thus have
Pr ∗ [ ω ∣ F t ] = Pr [ ω ∣ h t = ω t ] ⋅ M 0 ( ω ) Z t ( 0 ) = ∏ s = t + 1 n Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s = ω s ] E [ M 0 ∣ h s − 1 = ω s − 1 ] , \begin{aligned}
\Pr_*[\omega\mid\mathcal{F}_t]=\Pr[\omega\mid h_t=\omega_t]\cdot\frac{M_0(\omega)}{Z_t^{(0)}} \\
&= \prod_{s=t+1}^{n}\Pr[\omega_s \mid h_{s-1}=\omega_{s-1}]\cdot\frac{\mathbb{E}[M_0 \mid h_s=\omega_s]}{\mathbb{E}[M_0 \mid h_{s-1}=\omega_{s-1}]},
\end{aligned} ∗ Pr [ ω ∣ F t ] = Pr [ ω ∣ h t = ω t ] ⋅ Z t ( 0 ) M 0 ( ω ) = s = t + 1 ∏ n Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s − 1 = ω s − 1 ] E [ M 0 ∣ h s = ω s ] ,
where the last equality uses chain rule ∏ s = t + 1 n Pr [ ω s ∣ h s − 1 = ω s − 1 ] = Pr [ ω ∣ h t = ω t ] \prod_{s=t+1}^{n}\Pr[\omega_s \mid h_{s-1}=\omega_{s-1}]=\Pr[\omega\mid h_t=\omega_t] ∏ s = t + 1 n Pr [ ω s ∣ h s − 1 = ω s − 1 ] = Pr [ ω ∣ h t = ω t ] . Consequently, to sample ω \omega ω from Pr ∗ [ ⋅ ∣ F t ] \Pr_*[\cdot\mid\mathcal{F}_t] Pr ∗ [ ⋅ ∣ F t ] , it suffices to iteratively, for s = t + 1 s=t+1 s = t + 1 until s = n s=n s = n , sample the s s s -th observation X s ( ω ) X_s(\omega) X s ( ω ) with probability
μ s ( ω s ) = Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s = ω s ] E [ M 0 ∣ h s − 1 = ω s − 1 ] , \mu_s(\omega_s)=\Pr[\omega_s \mid h_{s-1}=\omega_{s-1}]\cdot\frac{\mathbb{E}[M_0 \mid h_s=\omega_s]}{\mathbb{E}[M_0 \mid h_{s-1}=\omega_{s-1}]}, μ s ( ω s ) = Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s − 1 = ω s − 1 ] E [ M 0 ∣ h s = ω s ] ,
where we now use the fact that E [ M 0 ∣ h s = ω s ] \mathbb{E}[M_0 \mid h_s=\omega_s] E [ M 0 ∣ h s = ω s ] can be computed exactly. A value with E [ M 0 ∣ h s = ω s ] = 0 \mathbb{E}[M_0 \mid h_s=\omega_s]=0 E [ M 0 ∣ h s = ω s ] = 0 has weight zero, so every sampled prefix has positive conditional expectation and all ratios are well defined. Notice that μ s \mu_s μ s is a valid probability measure because
∑ X s ( ω ) ∈ { v 1 , … , v m } Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s = ω s ] E [ M 0 ∣ h s − 1 = ω s − 1 ] = 1 E [ M 0 ∣ h s − 1 = ω s − 1 ] ⋅ ∑ X s ( ω ) ∈ { v 1 , … , v m } Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s = ω s ] = 1 E [ M 0 ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s − 1 = ω s − 1 ] = 1. \begin{aligned}
\sum_{X_s(\omega)\in\{v_1,\ldots,v_m\}}\Pr[\omega_s \mid h_{s-1}=\omega_{s-1}]\cdot\frac{\mathbb{E}[M_0 \mid h_s=\omega_s]}{\mathbb{E}[M_0 \mid h_{s-1}=\omega_{s-1}]} \\
&= \frac{1}{\mathbb{E}[M_0 \mid h_{s-1}=\omega_{s-1}]}\cdot\sum_{X_s(\omega)\in\{v_1,\ldots,v_m\}}\Pr[\omega_s \mid h_{s-1}=\omega_{s-1}]\cdot\mathbb{E}[M_0 \mid h_s=\omega_s] \\
&= \frac{1}{\mathbb{E}[M_0 \mid h_{s-1}=\omega_{s-1}]}\cdot\mathbb{E}[M_0 \mid h_{s-1}=\omega_{s-1}]=1.
\end{aligned} X s ( ω ) ∈ { v 1 , … , v m } ∑ Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s − 1 = ω s − 1 ] E [ M 0 ∣ h s = ω s ] = E [ M 0 ∣ h s − 1 = ω s − 1 ] 1 ⋅ X s ( ω ) ∈ { v 1 , … , v m } ∑ Pr [ ω s ∣ h s − 1 = ω s − 1 ] ⋅ E [ M 0 ∣ h s = ω s ] = E [ M 0 ∣ h s − 1 = ω s − 1 ] 1 ⋅ E [ M 0 ∣ h s − 1 = ω s − 1 ] = 1.
At each step, this requires evaluating E [ M 0 ∣ h s = ω s ] \mathbb{E}[M_0 \mid h_s=\omega_s] E [ M 0 ∣ h s = ω s ] for each of the m m m candidate values of the s s s -th observation, at cost O ( K ) O(K) O ( K ) each. As a result, the overall sampling procedure has C ⋆ = O ( n K m ) C_\star=O(nKm) C ⋆ = O ( n K m ) time complexity.
Proof of lem:accuracy-analysis
We first state a result that says Algorithm 3 approximates W j ( ω ) W_j(\omega) W j ( ω ) accurately and efficiently (proof in Appendix B.4):
Claim 3. Suppose 0 < α 0 ≤ 1 0 < \alpha_0 \le1 0 < α 0 ≤ 1 and define α ℓ + 1 = 1 / ( 1 + ln ( 1 / α ℓ ) ) \alpha_{\ell+1}=1/(1+\ln(1/\alpha_\ell)) α ℓ + 1 = 1/ ( 1 + ln ( 1/ α ℓ )) for every ℓ ≥ 0 \ell\ge0 ℓ ≥ 0 . For every integer j ≥ 0 j \ge0 j ≥ 0 , sample path ω ∈ Ω \omega\in\Omega ω ∈ Ω , and accuracy parameters 0 < η , κ < 1 0 < \eta,\kappa< 1 0 < η , κ < 1 , the recursive estimator W j ( ω , η , κ ) W_j(\omega,\eta,\kappa) W j ( ω , η , κ ) in Algorithm 3 returns W ^ j ( ω ) \widehat{W}_j(\omega) W j ( ω ) such that
W ^ j ( ω ) W j ( ω ) ∈ [ ( 1 − η ) , ( 1 − η ) − 1 ] \frac{\widehat{W}_j(\omega)}{W_j(\omega)} \in[(1-\eta),(1-\eta)^{-1}] W j ( ω ) W j ( ω ) ∈ [( 1 − η ) , ( 1 − η ) − 1 ] with probability at least 1 − κ 1-\kappa 1 − κ in time poly ( 2 j 2 ( K m n α 0 η κ ) j + 1 ) \operatorname{poly}\left(2^{j^2}\left(\frac{Kmn}{\alpha_0\eta\kappa}\right)^{j+1}\right) poly ( 2 j 2 ( α 0 η κ K mn ) j + 1 ) .
More precisely, the runtime is
O ( 756 j 2 K m n j + 1 ( α 0 η ) − 2 j ( j + ln n α 0 κ η ) j ) . O\left(756^{j^2}Kmn^{j+1}(\alpha_0\eta)^{-2j}\left(j+\ln\frac{n}{\alpha_0\kappa\eta}\right)^j\right). O ( 75 6 j 2 K m n j + 1 ( α 0 η ) − 2 j ( j + ln α 0 κ η n ) j ) .
Given this claim, we can estimate Z t ( j ) ( h t ) Z_t^{(j)}(h_t) Z t ( j ) ( h t ) via Monte Carlo simulation, as the next claim shows (proof in Appendix B.5):
Claim 4. Consider some j ≥ 1 j \ge1 j ≥ 1 , time t ∈ [ n ] t \in[n] t ∈ [ n ] , a fixed history h t h_t h t , and let G j − 1 = ∏ ℓ = 0 j − 1 α ℓ G_{j-1}=\prod_{\ell=0}^{j-1}\alpha_\ell G j − 1 = ∏ ℓ = 0 j − 1 α ℓ . Suppose we are given r r r independent samples ( ω ( i ) ) i ∈ [ r ] (\omega^{(i)})_{i\in[r]} ( ω ( i ) ) i ∈ [ r ] for continuations X t + 1 , … , X n X_{t+1},\ldots,X_n X t + 1 , … , X n from the biased distribution Pr ∗ [ ⋅ ∣ h t ] \Pr_*[\cdot\mid h_t] Pr ∗ [ ⋅ ∣ h t ] . Moreover, suppose that for each i i i , we have an estimate W ^ j ( ω ( i ) ) \widehat{W}_j(\omega^{(i)}) W j ( ω ( i ) ) of W j ( ω ( i ) ) W_j(\omega^{(i)}) W j ( ω ( i ) ) such that, conditionally on every realized ω ( i ) \omega^{(i)} ω ( i ) and for some 0 < η , κ < 1 0 < \eta,\kappa< 1 0 < η , κ < 1 , it holds
W ^ j ( ω ( i ) ) W j ( ω ( i ) ) ∈ [ ( 1 − η ) , ( 1 − η ) − 1 ] \frac{\widehat{W}_j(\omega^{(i)})}{W_j(\omega^{(i)})}\in[(1-\eta),(1-\eta)^{-1}] W j ( ω ( i ) ) W j ( ω ( i ) ) ∈ [( 1 − η ) , ( 1 − η ) − 1 ] with probability at least 1 − κ 1-\kappa 1 − κ .
Then, Z ^ t ( j ) ( h t ) = Z t ( 0 ) ( h t ) ⋅ 1 r ∑ i = 1 r W ^ j ( ω ( i ) ) \widehat{Z}_t^{(j)}(h_t)=Z_t^{(0)}(h_t)\cdot\frac{1}{r}\sum_{i=1}^{r}\widehat{W}_j(\omega^{(i)}) Z t ( j ) ( h t ) = Z t ( 0 ) ( h t ) ⋅ r 1 ∑ i = 1 r W j ( ω ( i ) ) satisfies
Z ^ t ( j ) ( h t ) Z t ( j ) ( h t ) ∈ [ ( 1 − η ) 2 , ( 1 − η ) − 2 ] \frac{\widehat{Z}_t^{(j)}(h_t)}{Z_t^{(j)}(h_t)}\in[(1-\eta)^2,(1-\eta)^{-2}] Z t ( j ) ( h t ) Z t ( j ) ( h t ) ∈ [( 1 − η ) 2 , ( 1 − η ) − 2 ] with probability at least 1 − κ r − 2 exp ( − η 2 r G j − 1 3 ) 1-\kappa r-2\exp\left(-\frac{\eta^2rG_{j-1}}{3}\right) 1 − κ r − 2 exp ( − 3 η 2 r G j − 1 ) .
We now combine the recursive estimator of W j W_j W j with the Monte Carlo estimate of Z t ( j ) Z_t^{(j)} Z t ( j ) from the above claims.
For j = 0 j=0 j = 0 , we compute L t ( 0 ) ( h t ) = Z t ( 0 ) ( h t ) L_t^{(0)}(h_t)=Z_t^{(0)}(h_t) L t ( 0 ) ( h t ) = Z t ( 0 ) ( h t ) exactly by a call to the value oracle. We henceforth suppose j ≥ 1 j\ge1 j ≥ 1 and Z t ( 0 ) ( h t ) > 0 Z_t^{(0)}(h_t)>0 Z t ( 0 ) ( h t ) > 0 . Let G j − 1 = ∏ ℓ = 0 j − 1 α ℓ G_{j-1}=\prod_{\ell=0}^{j-1}\alpha_\ell G j − 1 = ∏ ℓ = 0 j − 1 α ℓ , and choose
η = ϵ 4 , r = ⌈ 3 η 2 G j − 1 ln 4 δ ⌉ , κ = δ 2 r . \eta=\frac{\epsilon}{4},\qquad r=\left\lceil\frac{3}{\eta^2G_{j-1}}\ln\frac{4}{\delta}\right\rceil,\qquad\kappa=\frac{\delta}{2r}. η = 4 ϵ , r = ⌈ η 2 G j − 1 3 ln δ 4 ⌉ , κ = 2 r δ .
Draw r r r independent continuations ω ( 1 ) , … , ω ( r ) \omega^{(1)},\ldots,\omega^{(r)} ω ( 1 ) , … , ω ( r ) from Pr ∗ [ ⋅ ∣ h t ] \Pr_*[\cdot\mid h_t] Pr ∗ [ ⋅ ∣ h t ] . For each completed sample path, use fresh randomness to compute W ^ j ( ω ( i ) ) = W j ( ω ( i ) , η , κ ) \widehat{W}_j(\omega^{(i)})=W_j(\omega^{(i)},\eta,\kappa) W j ( ω ( i ) ) = W j ( ω ( i ) , η , κ ) , and return
L t ( j ) ( h t ) = ( 1 − η ) 2 Z ^ t ( j ) ( h t ) , Z ^ t ( j ) ( h t ) = Z t ( 0 ) ( h t ) ⋅ 1 r ∑ i = 1 r W ^ j ( ω ( i ) ) . L_t^{(j)}(h_t)=(1-\eta)^2\widehat{Z}_t^{(j)}(h_t),\qquad\widehat{Z}_t^{(j)}(h_t)=Z_t^{(0)}(h_t)\cdot\frac{1}{r}\sum_{i=1}^{r}\widehat{W}_j(\omega^{(i)}). L t ( j ) ( h t ) = ( 1 − η ) 2 Z t ( j ) ( h t ) , Z t ( j ) ( h t ) = Z t ( 0 ) ( h t ) ⋅ r 1 i = 1 ∑ r W j ( ω ( i ) ) .
By Claim 3, conditionally on each sampled trajectory ω ( i ) \omega^{(i)} ω ( i ) , we have W ^ j ( ω ( i ) ) / W j ( ω ( i ) ) ∈ [ 1 − η , ( 1 − η ) − 1 ] \widehat{W}_j(\omega^{(i)})/W_j(\omega^{(i)}) \in[1-\eta,(1-\eta)^{-1}] W j ( ω ( i ) ) / W j ( ω ( i ) ) ∈ [ 1 − η , ( 1 − η ) − 1 ] with probability at least 1 − κ 1-\kappa 1 − κ . Thus, the hypothesis of Claim 4 holds, which implies that Z ^ t ( j ) ( h t ) / Z t ( j ) ( h t ) ∈ [ ( 1 − η ) 2 , ( 1 − η ) − 2 ] \widehat{Z}^{(j)}_t(h_t)/Z^{(j)}_t(h_t) \in[(1-\eta)^2,(1-\eta)^{-2}] Z t ( j ) ( h t ) / Z t ( j ) ( h t ) ∈ [( 1 − η ) 2 , ( 1 − η ) − 2 ] with probability at least 1 − κ r − 2 exp ( − η 2 r G j − 1 / 3 ) 1-\kappa r-2\exp(-\eta^2 rG_{j-1}/3) 1 − κ r − 2 exp ( − η 2 r G j − 1 /3 ) . We now show that this failure probability is at most δ \delta δ :
κ r + 2 exp ( − η 2 r G j − 1 3 ) ≤ ( i ) δ 2 + 2 exp ( − ln 4 δ ) = δ , \kappa r+2\exp\left(-\frac{\eta^2rG_{j-1}}{3}\right)\mathrel{\overset{(i)}{\leq}}\frac{\delta}{2}+2\exp\left(-\ln\frac{4}{\delta}\right)=\delta, κ r + 2 exp ( − 3 η 2 r G j − 1 ) ≤ ( i ) 2 δ + 2 exp ( − ln δ 4 ) = δ ,
where (i) uses κ r = δ / 2 \kappa r=\delta/2 κ r = δ /2 by the choice κ = δ / ( 2 r ) \kappa=\delta/(2r) κ = δ / ( 2 r ) , and η 2 r G j − 1 / 3 ≥ ln ( 4 / δ ) \eta^2rG_{j-1}/3\geq\ln(4/\delta) η 2 r G j − 1 /3 ≥ ln ( 4/ δ ) by the choice r ≥ 3 η 2 G j − 1 ln 4 δ r\geq\frac{3}{\eta^2G_{j-1}}\ln\frac{4}{\delta} r ≥ η 2 G j − 1 3 ln δ 4 . Consequently, with probability at least 1 − δ 1-\delta 1 − δ , the estimate Z ^ t ( j ) ( h t ) \widehat{Z}^{(j)}_t(h_t) Z t ( j ) ( h t ) lies between ( 1 − η ) 2 Z t ( j ) ( h t ) (1-\eta)^2Z^{(j)}_t(h_t) ( 1 − η ) 2 Z t ( j ) ( h t ) and ( 1 − η ) − 2 Z t ( j ) ( h t ) (1-\eta)^{-2}Z^{(j)}_t(h_t) ( 1 − η ) − 2 Z t ( j ) ( h t ) . Multiplying by ( 1 − η ) 2 (1-\eta)^2 ( 1 − η ) 2 gives
( 1 − ε ) Z t ( j ) ( h t ) ≤ ( 1 − η ) 4 Z t ( j ) ( h t ) ≤ L t ( j ) ( h t ) ≤ Z t ( j ) ( h t ) , (1-\varepsilon)Z^{(j)}_t(h_t)\leq(1-\eta)^4Z^{(j)}_t(h_t)\leq L^{(j)}_t(h_t)\leq Z^{(j)}_t(h_t), ( 1 − ε ) Z t ( j ) ( h t ) ≤ ( 1 − η ) 4 Z t ( j ) ( h t ) ≤ L t ( j ) ( h t ) ≤ Z t ( j ) ( h t ) ,
where the first inequality uses ( 1 − η ) 4 ≥ 1 − 4 η = 1 − ε (1-\eta)^4\geq1-4\eta=1-\varepsilon ( 1 − η ) 4 ≥ 1 − 4 η = 1 − ε . This proves the accuracy guarantee.
As for the runtime analysis, our estimation procedure consists of (i) drawing r r r continuations from the biased distribution Pr ∗ [ ⋅ ∣ h t ] \Pr_\ast[\cdot\mid h_t] Pr ∗ [ ⋅ ∣ h t ] , each at cost c s m p l = O ( n K m ) c_{\mathrm{smpl}}=O(nKm) c smpl = O ( n K m ) (see Appendix B.§ 2 ); and (ii) making r r r calls to the recursive estimator W j ( ⋅ , η , κ ) W_j(\cdot,\eta,\kappa) W j ( ⋅ , η , κ ) . Denoting the runtime of one such call by T j ( η , κ ) T_j(\eta,\kappa) T j ( η , κ ) , the overall runtime is
O ( K m n ) + r ⋅ ( c s m p l + T j ( η , κ ) ) . (34) O(Kmn)+r\cdot(c_{\mathrm{smpl}}+T_j(\eta,\kappa)). \tag*{(34)} O ( K mn ) + r ⋅ ( c smpl + T j ( η , κ )) . (34)
It remains to bound r r r and T j ( η , κ ) T_j(\eta,\kappa) T j ( η , κ ) . Let Λ = j + ln ( n / ( α 0 δ ε ) ) \Lambda=j+\ln(n/(\alpha_0\delta\varepsilon)) Λ = j + ln ( n / ( α 0 δ ε )) . Because n ≥ 1 n\geq1 n ≥ 1 and 0 < α 0 , ε , δ < 1 0<\alpha_0,\varepsilon,\delta<1 0 < α 0 , ε , δ < 1 , we have
Λ ≥ j ≥ 1 , ln 1 δ ≤ Λ − j , and ln 1 α 0 ε ≤ Λ − j . (35) \Lambda\geq j\geq1,\qquad\ln\frac{1}{\delta}\leq\Lambda-j,\qquad\text{and}\qquad\ln\frac{1}{\alpha_0\varepsilon}\leq\Lambda-j. \tag*{(35)} Λ ≥ j ≥ 1 , ln δ 1 ≤ Λ − j , and ln α 0 ε 1 ≤ Λ − j . (35)
We first bound r r r . Recall that η = ε / 4 \eta=\varepsilon/4 η = ε /4 . We have
r ≤ 3 η 2 G j − 1 ln 4 δ + 1 ≤ ( i ) 12 ⋅ 4 j ( α 0 ε ) 2 ln 4 δ + 1 ≤ ( i i ) 13 ⋅ 4 j ( α 0 ε ) 2 ln 4 δ ≤ ( i i i ) 26 ⋅ 4 j ( α 0 ε ) 2 Λ , (36) r\leq\frac{3}{\eta^2G_{j-1}}\ln\frac{4}{\delta}+1\mathrel{\overset{(i)}{\leq}}\frac{12\cdot4^j}{(\alpha_0\varepsilon)^2}\ln\frac{4}{\delta}+1\mathrel{\overset{(ii)}{\leq}}\frac{13\cdot4^j}{(\alpha_0\varepsilon)^2}\ln\frac{4}{\delta}\mathrel{\overset{(iii)}{\leq}}\frac{26\cdot4^j}{(\alpha_0\varepsilon)^2}\Lambda, \tag*{(36)} r ≤ η 2 G j − 1 3 ln δ 4 + 1 ≤ ( i ) ( α 0 ε ) 2 12 ⋅ 4 j ln δ 4 + 1 ≤ ( ii ) ( α 0 ε ) 2 13 ⋅ 4 j ln δ 4 ≤ ( iii ) ( α 0 ε ) 2 26 ⋅ 4 j Λ , (36)
where (i) uses G j − 1 − 1 ≤ 4 j − 1 α 0 − 2 G_{j-1}^{-1}\leq4^{j-1}\alpha_0^{-2} G j − 1 − 1 ≤ 4 j − 1 α 0 − 2 (from Claim 5 in Appendix B.§ 4.1 ), (ii) uses α 0 ε < 1 \alpha_0\varepsilon<1 α 0 ε < 1 and ln ( 4 / δ ) > 1 \ln(4/\delta)>1 ln ( 4/ δ ) > 1 , and (iii) uses ln ( 4 / δ ) ≤ ln 4 + Λ − j ≤ 2 Λ \ln(4/\delta)\leq\ln4+\Lambda-j\leq2\Lambda ln ( 4/ δ ) ≤ ln 4 + Λ − j ≤ 2Λ , which follows from (35) and j ≥ 1 j\geq1 j ≥ 1 .
Next, we bound T j ( η , κ ) T_j(\eta,\kappa) T j ( η , κ ) . By Claim 3, we have
T j ( η , κ ) = O ( 756 j 2 ⋅ K m n j + 1 ⋅ ( α 0 η ) − 2 j ⋅ ( j + ln n α 0 κ η ) j ) . T_j(\eta,\kappa)=O\left(756j^2\cdot Km\,n^{j+1}\cdot(\alpha_0\eta)^{-2j}\cdot\left(j+\ln\frac{n}{\alpha_0\kappa\eta}\right)^j\right). T j ( η , κ ) = O ( 756 j 2 ⋅ K m n j + 1 ⋅ ( α 0 η ) − 2 j ⋅ ( j + ln α 0 κ η n ) j ) .
For the third factor, η = ε / 4 \eta=\varepsilon/4 η = ε /4 gives ( α 0 η ) − 2 j = 16 j ( α 0 ε ) − 2 j (\alpha_0\eta)^{-2j}=16^j(\alpha_0\varepsilon)^{-2j} ( α 0 η ) − 2 j = 1 6 j ( α 0 ε ) − 2 j . For the last factor, κ = δ / ( 2 r ) \kappa=\delta/(2r) κ = δ / ( 2 r ) gives
j + ln n α 0 κ η = Λ + ln ( 8 r ) ≤ ( i ) Λ + ln 208 + j ln 4 + 2 ln 1 α 0 ε + ln Λ j+\ln\frac{n}{\alpha_0\kappa\eta}=\Lambda+\ln(8r)\mathrel{\overset{(i)}{\leq}}\Lambda+\ln208+j\ln4+2\ln\frac{1}{\alpha_0\varepsilon}+\ln\Lambda j + ln α 0 κ η n = Λ + ln ( 8 r ) ≤ ( i ) Λ + ln 208 + j ln 4 + 2 ln α 0 ε 1 + ln Λ
≤ ( i i ) Λ + 6 + 2 j + 2 ( Λ − j ) + ( Λ − 1 ) ≤ ( i i i ) 9 Λ , \mathrel{\overset{(ii)}{\leq}}\Lambda+6+2j+2(\Lambda-j)+(\Lambda-1)\mathrel{\overset{(iii)}{\leq}}9\Lambda, ≤ ( ii ) Λ + 6 + 2 j + 2 ( Λ − j ) + ( Λ − 1 ) ≤ ( iii ) 9Λ ,
where (i) uses the bound on r r r in (36) , (ii) uses ln 208 ≤ 6 \ln208 \le6 ln 208 ≤ 6 , ln 4 ≤ 2 \ln4 \le2 ln 4 ≤ 2 , (35) , and ln Λ ≤ Λ − 1 \ln\Lambda\le\Lambda- 1 ln Λ ≤ Λ − 1 , and (iii) uses Λ ≥ 1 \Lambda\ge1 Λ ≥ 1 . Since 16 ⋅ 9 = 144 16 \cdot9 = 144 16 ⋅ 9 = 144 , we obtain
T j ( η , κ ) = O ( 144 j ⋅ 756 j 2 K m n j + 1 ( α 0 ε ) − 2 j Λ j ) . T_j(\eta,\kappa)=O\left(144^j\cdot756^{j^2}Km\,n^{j+1}(\alpha_0\varepsilon)^{-2j}\Lambda^j\right). T j ( η , κ ) = O ( 14 4 j ⋅ 75 6 j 2 K m n j + 1 ( α 0 ε ) − 2 j Λ j ) .
We now combine the bounds. Since c s m p l = O ( n K m ) c_{\mathrm{smpl}}=O(nKm) c smpl = O ( n K m ) is dominated by the above bound on T j ( η , κ ) T_j(\eta,\kappa) T j ( η , κ ) , plugging the bounds on r r r and T j ( η , κ ) T_j(\eta,\kappa) T j ( η , κ ) into (34) and using 4 ⋅ 144 = 576 4\cdot144=576 4 ⋅ 144 = 576 gives the overall runtime
O ( 576 j ⋅ 756 j 2 K m n j + 1 ( α 0 ε ) − ( 2 j + 2 ) Λ j + 1 ) . O\left(576^j\cdot756^{j^2}Km\,n^{j+1}(\alpha_0\varepsilon)^{-(2j+2)}\Lambda^{j+1}\right). O ( 57 6 j ⋅ 75 6 j 2 K m n j + 1 ( α 0 ε ) − ( 2 j + 2 ) Λ j + 1 ) .
where the O ( K m n ) O(Kmn) O ( K mn ) term is dominated because all other factors are at least 1. Since j ≥ 1 j\ge1 j ≥ 1 , we have
576 j ⋅ 756 j 2 ≤ ( 576 ⋅ 756 ) j 2 = 435,456 j 2 ≤ ( 2 19 ) j 2 = ζ j 2 , 576^j\cdot756^{j^2}\le(576\cdot756)^{j^2}=435{,}456^{j^2}\le(2^{19})^{j^2}=\zeta^{j^2}, 57 6 j ⋅ 75 6 j 2 ≤ ( 576 ⋅ 756 ) j 2 = 435 , 45 6 j 2 ≤ ( 2 19 ) j 2 = ζ j 2 ,
which proves the precise runtime bound in Lemma 4 with ζ = 2 19 \zeta=2^{19} ζ = 2 19 .
Finally, we show that this runtime is polynomial in the sense stated in the lemma’s statement. Let N = K m n / ( α 0 ε δ ) ≥ 1 N=Kmn/(\alpha_0\varepsilon\delta)\ge1 N = K mn / ( α 0 ε δ ) ≥ 1 . We have K m n j + 1 ≤ N j + 1 Kmn^{j+1}\le N^{j+1} K m n j + 1 ≤ N j + 1 and ( α 0 ε ) − ( 2 j + 2 ) ≤ N 2 j + 2 (\alpha_0\varepsilon)^{-(2j+2)}\le N^{2j+2} ( α 0 ε ) − ( 2 j + 2 ) ≤ N 2 j + 2 . Moreover, using j ≤ 2 j j\le2^j j ≤ 2 j and ln y ≤ y \ln y\le y ln y ≤ y for y > 0 y>0 y > 0 , we get Λ ≤ 2 j + N ≤ 2 j + 1 N \Lambda\le2^j+N\le2^{j+1}N Λ ≤ 2 j + N ≤ 2 j + 1 N , and hence Λ j + 1 ≤ 2 ( j + 1 ) 2 N j + 1 \Lambda^{j+1}\le2^{(j+1)^2}N^{j+1} Λ j + 1 ≤ 2 ( j + 1 ) 2 N j + 1 . Combining these bounds with ( j + 1 ) 2 ≤ 4 j 2 (j+1)^2\le4j^2 ( j + 1 ) 2 ≤ 4 j 2 for j ≥ 1 j\ge1 j ≥ 1 , the runtime is at most
O ( 2 19 j 2 ⋅ 2 ( j + 1 ) 2 ⋅ N 4 ( j + 1 ) ) ≤ O ( 2 23 j 2 N 4 ( j + 1 ) ) ≤ O ( ( 2 j 2 N j + 1 ) 23 ) . O\left(2^{19j^2}\cdot2^{(j+1)^2}\cdot N^{4(j+1)}\right)\le O\left(2^{23j^2}N^{4(j+1)}\right)\le O\left(\left(2^{j^2}N^{j+1}\right)^{23}\right). O ( 2 19 j 2 ⋅ 2 ( j + 1 ) 2 ⋅ N 4 ( j + 1 ) ) ≤ O ( 2 23 j 2 N 4 ( j + 1 ) ) ≤ O ( ( 2 j 2 N j + 1 ) 23 ) .
which is polynomial in 2 j 2 N j + 1 2^{j^2}N^{j+1} 2 j 2 N j + 1 , as claimed. This completes the proof. ∎
Proof of Claim 3
We split the proof in two parts for accuracy and runtime analysis.
Accuracy analysis. We prove the correctness of Algorithm 3 by induction on j j j . The base case j = 0 j=0 j = 0 is immediate because W 0 = 1 W_0=1 W 0 = 1 . For the inductive step, fix j ≥ 1 j\ge1 j ≥ 1 and assume that the lemma holds at level j − 1 j-1 j − 1 . Recall the parameter choices in Algorithm 3 with input parameters ( η , κ ) (\eta,\kappa) ( η , κ ) :
η ′ = 1 − ( 1 − η ) 1 / 3 , I j = ⌈ 3 η ′ 2 G j − 1 ln 4 n κ ⌉ , κ ′ = κ 2 ( n I j + 1 ) . \eta'=1-(1-\eta)^{1/3},\qquad I_j=\left\lceil\frac{3}{\eta'^2G_{j-1}}\ln\frac{4n}{\kappa}\right\rceil,\qquad\kappa'=\frac{\kappa}{2(nI_j+1)}. η ′ = 1 − ( 1 − η ) 1/3 , I j = ⌈ η ′2 G j − 1 3 ln κ 4 n ⌉ , κ ′ = 2 ( n I j + 1 ) κ .
Since 0 < η ′ , κ ′ < 1 0<\eta',\kappa'<1 0 < η ′ , κ ′ < 1 , the induction hypothesis applies to every recursive call W j − 1 ( ⋅ , η ′ , κ ′ ) W_{j-1}(\cdot,\eta',\kappa') W j − 1 ( ⋅ , η ′ , κ ′ ) .
We first analyze the estimates Z ^ t ( j − 1 ) \widehat{Z}_t^{(j-1)} Z t ( j − 1 ) in Line 13. Fix a time t ∈ [ n ] t\in[n] t ∈ [ n ] , and let h t h_t h t be the t t t -step prefix of ω \omega ω . We show that the ratio bound
Z ^ t ( j − 1 ) Z t ( j − 1 ) ( h t ) ∈ [ ( 1 − η ′ ) 2 , ( 1 − η ′ ) − 2 ] (37) \frac{\widehat{Z}_t^{(j-1)}}{Z_t^{(j-1)}(h_t)}\in\left[(1-\eta')^2,(1-\eta')^{-2}\right] \tag*{(37)} Z t ( j − 1 ) ( h t ) Z t ( j − 1 ) ∈ [ ( 1 − η ′ ) 2 , ( 1 − η ′ ) − 2 ] (37)
fails with probability at most κ ′ I j + κ / ( 2 n ) \kappa'I_j+\kappa/(2n) κ ′ I j + κ / ( 2 n ) . If j = 1 j=1 j = 1 , every recursive call returns W ^ 0 = W 0 = 1 \widehat{W}_0=W_0=1 W 0 = W 0 = 1 , so Z ^ t ( 0 ) = Z t ( 0 ) ( h t ) \widehat{Z}_t^{(0)}=Z_t^{(0)}(h_t) Z t ( 0 ) = Z t ( 0 ) ( h t ) and the ratio bound always holds. Suppose instead that j ≥ 2 j\ge2 j ≥ 2 . The continuations of completed sample paths ( ω ~ ( t , i ) ) i ∈ [ I j ] (\widetilde{\omega}^{(t,i)})_{i\in[I_j]} ( ω ( t , i ) ) i ∈ [ I j ] from time t t t are independent samples from Pr ∗ [ ⋅ ∣ h t ] \Pr_\ast[\cdot\mid h_t] Pr ∗ [ ⋅ ∣ h t ] . Moreover, each recursive call in Line 12 uses fresh randomness. Thus, conditionally on every realized ω ~ ( t , i ) \widetilde{\omega}^{(t,i)} ω ( t , i ) , the induction hypothesis gives
W ^ j − 1 ( t , i ) W j − 1 ( ω ~ ( t , i ) ) ∈ [ ( 1 − η ′ ) , ( 1 − η ′ ) − 1 ] \frac{\widehat{W}_{j-1}^{(t,i)}}{W_{j-1}(\widetilde{\omega}^{(t,i)})}\in[(1-\eta'),(1-\eta')^{-1}] W j − 1 ( ω ( t , i ) ) W j − 1 ( t , i ) ∈ [( 1 − η ′ ) , ( 1 − η ′ ) − 1 ]
with probability at least 1 − κ ′ 1-\kappa' 1 − κ ′ .
We can therefore apply Claim 4 at level j − 1 j-1 j − 1 with r = I j r=I_j r = I j and accuracy parameters ( η ′ , κ ′ ) (\eta',\kappa') ( η ′ , κ ′ ) . This shows that the ratio bound (37) fails with probability at most
κ ′ I j + 2 exp ( − η ′ 2 I j G j − 2 3 ) ≤ κ ′ I j + 2 exp ( − η ′ 2 I j G j − 1 3 ) ≤ κ ′ I j + 2 exp ( − ln 4 n κ ) = κ ′ I j + κ 2 n . \begin{aligned}
\kappa'I_j+2\exp\left(-\frac{\eta'^2 I_jG_{j-2}}{3}\right)\leq\kappa'I_j+2\exp\left(-\frac{\eta'^2 I_jG_{j-1}}{3}\right) \\
&\leq\kappa'I_j+2\exp\left(-\ln\frac{4n}{\kappa}\right)=\kappa'I_j+\frac{\kappa}{2n}.
\end{aligned} κ ′ I j + 2 exp ( − 3 η ′2 I j G j − 2 ) ≤ κ ′ I j + 2 exp ( − 3 η ′2 I j G j − 1 ) ≤ κ ′ I j + 2 exp ( − ln κ 4 n ) = κ ′ I j + 2 n κ .
where the first inequality uses G j − 1 = α j − 1 G j − 2 ≤ G j − 2 G_{j-1}=\alpha_{j-1}G_{j-2}\leq G_{j-2} G j − 1 = α j − 1 G j − 2 ≤ G j − 2 and the second uses the choice of I j I_j I j .
By the induction hypothesis, with probability at least 1 − κ ′ 1-\kappa' 1 − κ ′ , the additional recursive call on ω \omega ω in Line 15 satisfies
W ^ j − 1 ( ω ) W j − 1 ( ω ) ∈ [ ( 1 − η ′ ) , ( 1 − η ′ ) − 1 ] . \frac{\widehat{W}_{j-1}(\omega)}{W_{j-1}(\omega)}\in[(1-\eta'),(1-\eta')^{-1}]. W j − 1 ( ω ) W j − 1 ( ω ) ∈ [( 1 − η ′ ) , ( 1 − η ′ ) − 1 ] .
A union bound over t ∈ [ n ] t\in[n] t ∈ [ n ] shows that this estimate and all the preceding Z Z Z -ratio estimates in (37) hold simultaneously with probability at least
1 − n ( κ ′ I j + κ 2 n ) − κ ′ = 1 − κ ′ ( n I j + 1 ) − κ 2 = 1 − κ . \begin{aligned}
1-n\left(\kappa'I_j+\frac{\kappa}{2n}\right)-\kappa'=1-\kappa'(nI_j+1)-\frac{\kappa}{2} \\
&=1-\kappa.
\end{aligned} 1 − n ( κ ′ I j + 2 n κ ) − κ ′ = 1 − κ ′ ( n I j + 1 ) − 2 κ = 1 − κ .
On the event that all estimates hold simultaneously, we have
ρ ^ j − 1 = max t ∈ [ n ] X t ( ω ) Z ^ t ( j − 1 ) ∈ [ ( 1 − η ′ ) 2 ρ j − 1 ( ω ) , ( 1 − η ′ ) − 2 ρ j − 1 ( ω ) ] . \widehat{\rho}_{j-1}=\max_{t\in[n]}\frac{X_t(\omega)}{\widehat{Z}_t^{(j-1)}}\in[(1-\eta')^2\rho_{j-1}(\omega),(1-\eta')^{-2}\rho_{j-1}(\omega)]. ρ j − 1 = t ∈ [ n ] max Z t ( j − 1 ) X t ( ω ) ∈ [( 1 − η ′ ) 2 ρ j − 1 ( ω ) , ( 1 − η ′ ) − 2 ρ j − 1 ( ω )] .
Recall the exact and estimated recursions
W j ( ω ) = W j − 1 ( ω ) max { α j − 1 , ρ j − 1 ( ω ) } , W_j(\omega)=W_{j-1}(\omega)\max\{\alpha_{j-1},\rho_{j-1}(\omega)\}, W j ( ω ) = W j − 1 ( ω ) max { α j − 1 , ρ j − 1 ( ω )} ,
W ^ j ( ω ) = W ^ j − 1 ( ω ) max { α j − 1 , ρ ^ j − 1 } . \widehat{W}_j(\omega)=\widehat{W}_{j-1}(\omega)\max\{\alpha_{j-1},\widehat{\rho}_{j-1}\}. W j ( ω ) = W j − 1 ( ω ) max { α j − 1 , ρ j − 1 } .
Since ( 1 − η ′ ) 2 ≤ 1 ≤ ( 1 − η ′ ) − 2 (1-\eta')^2\leq1\leq(1-\eta')^{-2} ( 1 − η ′ ) 2 ≤ 1 ≤ ( 1 − η ′ ) − 2 , the multiplicative bounds for ρ ^ j − 1 \widehat{\rho}_{j-1} ρ j − 1 carry over to max { α j − 1 , ρ ^ j − 1 } \max\{\alpha_{j-1},\widehat{\rho}_{j-1}\} max { α j − 1 , ρ j − 1 } . Combining them with the bounds for W ^ j − 1 ( ω ) \widehat{W}_{j-1}(\omega) W j − 1 ( ω ) in these recursions therefore gives
W ^ j ( ω ) ∈ [ ( 1 − η ′ ) 3 W j ( ω ) , ( 1 − η ′ ) − 3 W j ( ω ) ] . \widehat{W}_j(\omega)\in[(1-\eta')^3W_j(\omega),(1-\eta')^{-3}W_j(\omega)]. W j ( ω ) ∈ [( 1 − η ′ ) 3 W j ( ω ) , ( 1 − η ′ ) − 3 W j ( ω )] .
Since ( 1 − η ′ ) 3 = 1 − η (1-\eta')^3=1-\eta ( 1 − η ′ ) 3 = 1 − η , the proof of the correctness is complete.
Runtime analysis. Define η j = η \eta_j=\eta η j = η and κ j = κ \kappa_j=\kappa κ j = κ . For every ℓ ∈ [ j ] \ell\in[j] ℓ ∈ [ j ] , a level-ℓ \ell ℓ call uses
η ℓ − 1 = 1 − ( 1 − η ℓ ) 1 / 3 , I ℓ = ⌈ 3 η ℓ − 1 2 G ℓ − 1 ln 4 n κ ℓ ⌉ , B ℓ = n I ℓ + 1 , κ ℓ − 1 = κ ℓ 2 B ℓ . \eta_{\ell-1}=1-(1-\eta_\ell)^{1/3},\qquad I_\ell=\left\lceil\frac{3}{\eta_{\ell-1}^{2}G_{\ell-1}}\ln\frac{4n}{\kappa_\ell}\right\rceil,\qquad B_\ell=nI_\ell+1,\qquad\kappa_{\ell-1}=\frac{\kappa_\ell}{2B_\ell}. η ℓ − 1 = 1 − ( 1 − η ℓ ) 1/3 , I ℓ = ⌈ η ℓ − 1 2 G ℓ − 1 3 ln κ ℓ 4 n ⌉ , B ℓ = n I ℓ + 1 , κ ℓ − 1 = 2 B ℓ κ ℓ .
Here B ℓ B_\ell B ℓ bounds the number of recursive level-( ℓ − 1 ) (\ell-1) ( ℓ − 1 ) calls. Let T ℓ T_\ell T ℓ denote the running time of a level-ℓ \ell ℓ call. Then the n I ℓ nI_\ell n I ℓ biased-trajectory samples and the remaining arithmetic give, for a universal constant c > 0 c>0 c > 0 ,
T ℓ ≤ B ℓ T ℓ − 1 + c ⋅ c s m p l ⋅ n I ℓ , T 0 = O ( 1 ) . T_\ell\le B_\ell T_{\ell-1}+c\cdot c_{\mathrm{smpl}}\cdot nI_\ell,\qquad T_0=O(1). T ℓ ≤ B ℓ T ℓ − 1 + c ⋅ c smpl ⋅ n I ℓ , T 0 = O ( 1 ) .
where c s m p l = O ( n K m ) c_{\mathrm{smpl}}=O(nKm) c smpl = O ( n K m ) is the cost of one exact biased-trajectory sample from Appendix B.§ 2 . Unrolling the recurrence and using n I ℓ ≤ B ℓ nI_\ell\le B_\ell n I ℓ ≤ B ℓ gives
T j ≤ T 0 ∏ ℓ = 1 j B ℓ + c ⋅ c s m p l ⋅ ∑ q = 1 j n I q ∏ ℓ = q + 1 j B ℓ = T 0 ∏ ℓ = 1 j B ℓ + c ⋅ c s m p l ⋅ ∑ q = 1 j ( B q − 1 ) ∏ ℓ = q + 1 j B ℓ = T 0 ∏ ℓ = 1 j B ℓ + c ⋅ c s m p l ⋅ ( ∏ ℓ = 1 j B ℓ − 1 ) = O ( c s m p l ∏ ℓ = 1 j B ℓ ) . (38) \begin{aligned}
T_j&\le T_0\prod_{\ell=1}^{j}B_\ell+c\cdot c_{\mathrm{smpl}}\cdot\sum_{q=1}^{j}nI_q\prod_{\ell=q+1}^{j}B_\ell\\
&=T_0\prod_{\ell=1}^{j}B_\ell+c\cdot c_{\mathrm{smpl}}\cdot\sum_{q=1}^{j}(B_q-1)\prod_{\ell=q+1}^{j}B_\ell\\
&=T_0\prod_{\ell=1}^{j}B_\ell+c\cdot c_{\mathrm{smpl}}\cdot\left(\prod_{\ell=1}^{j}B_\ell-1\right)=O\left(c_{\mathrm{smpl}}\prod_{\ell=1}^{j}B_\ell\right). \tag*{(38)}
\end{aligned} T j ≤ T 0 ℓ = 1 ∏ j B ℓ + c ⋅ c smpl ⋅ q = 1 ∑ j n I q ℓ = q + 1 ∏ j B ℓ = T 0 ℓ = 1 ∏ j B ℓ + c ⋅ c smpl ⋅ q = 1 ∑ j ( B q − 1 ) ℓ = q + 1 ∏ j B ℓ = T 0 ℓ = 1 ∏ j B ℓ + c ⋅ c smpl ⋅ ( ℓ = 1 ∏ j B ℓ − 1 ) = O ( c smpl ℓ = 1 ∏ j B ℓ ) . (38)
To bound this product in (38) , it remains to control the three quantities appearing in B ℓ B_\ell B ℓ , which are G ℓ − 1 G_{\ell-1} G ℓ − 1 , the propagated accuracy η ℓ − 1 \eta_{\ell-1} η ℓ − 1 , and the propagated failure probability κ ℓ \kappa_\ell κ ℓ . The next three claims do so, with their proofs delegated to the end of this subsection.
Claim 5. Suppose 0 < α 0 ≤ 1 0<\alpha_0\le1 0 < α 0 ≤ 1 and α q + 1 = 1 / ( 1 + ln ( 1 / α q ) ) \alpha_{q+1}=1/(1+\ln(1/\alpha_q)) α q + 1 = 1/ ( 1 + ln ( 1/ α q )) for every q ≥ 0 q\ge0 q ≥ 0 . The following bounds hold for every ℓ ≥ 1 \ell\ge1 ℓ ≥ 1 and j ≥ 1 j\ge1 j ≥ 1 , respectively:
1 G ℓ − 1 ≤ 4 ℓ − 1 α 0 2 and ∏ ℓ = 1 j 1 G ℓ − 1 ≤ 4 j ( j − 1 ) / 2 α 0 2 j . \frac{1}{G_{\ell-1}}\le\frac{4^{\ell-1}}{\alpha_0^2}
\qquad\text{and}\qquad
\prod_{\ell=1}^{j}\frac{1}{G_{\ell-1}}\le\frac{4^{j(j-1)/2}}{\alpha_0^{2j}}. G ℓ − 1 1 ≤ α 0 2 4 ℓ − 1 and ℓ = 1 ∏ j G ℓ − 1 1 ≤ α 0 2 j 4 j ( j − 1 ) /2 .
Claim 6. For every ℓ ∈ [ j ] \ell\in[j] ℓ ∈ [ j ] , we have η ℓ − 1 ≥ η / 3 j − ℓ + 1 \eta_{\ell-1}\ge\eta/3^{j-\ell+1} η ℓ − 1 ≥ η / 3 j − ℓ + 1 , and consequently ∏ ℓ = 1 j η ℓ − 1 − 2 ≤ 9 j ( j + 1 ) / 2 η − 2 j \prod_{\ell=1}^{j}\eta_{\ell-1}^{-2}\le9^{j(j+1)/2}\eta^{-2j} ∏ ℓ = 1 j η ℓ − 1 − 2 ≤ 9 j ( j + 1 ) /2 η − 2 j .
Claim 7. For 0 ≤ ℓ ≤ j 0\le\ell\le j 0 ≤ ℓ ≤ j , let p ℓ = ln ( 4 n / κ ℓ ) p_\ell=\ln(4n/\kappa_\ell) p ℓ = ln ( 4 n / κ ℓ ) and L = ln ( 96 ⋅ 9 j n 2 / ( α 0 2 κ η 2 ) ) L=\ln(96\cdot9^j n^2/(\alpha_0^2\kappa\eta^2)) L = ln ( 96 ⋅ 9 j n 2 / ( α 0 2 κ η 2 )) . These quantities satisfy
p ℓ ≤ 2 j − ℓ L and ∏ ℓ = 1 j p ℓ ≤ 2 j ( j − 1 ) / 2 L j . p_\ell\le2^{j-\ell}L
\qquad\text{and}\qquad
\prod_{\ell=1}^{j}p_\ell\le2^{j(j-1)/2}L^j. p ℓ ≤ 2 j − ℓ L and ℓ = 1 ∏ j p ℓ ≤ 2 j ( j − 1 ) /2 L j .
Combining the three claims with B ℓ = n I ℓ + 1 ≤ 12 n p ℓ / ( η ℓ − 1 G ℓ − 1 ) B_\ell=nI_\ell+1\le12np_\ell/(\eta_{\ell-1}G_{\ell-1}) B ℓ = n I ℓ + 1 ≤ 12 n p ℓ / ( η ℓ − 1 G ℓ − 1 ) gives
∏ ℓ = 1 j B ℓ ≤ 12 j 8 j ( j − 1 ) / 2 9 j ( j + 1 ) / 2 n j ( α 0 η ) − 2 j L j ≤ ζ 0 j n j ( α 0 η ) − 2 j L j , \prod_{\ell=1}^{j}B_\ell\le12^j8^{j(j-1)/2}9^{j(j+1)/2}n^j(\alpha_0\eta)^{-2j}L^j\le\zeta_0^j n^j(\alpha_0\eta)^{-2j}L^j, ℓ = 1 ∏ j B ℓ ≤ 1 2 j 8 j ( j − 1 ) /2 9 j ( j + 1 ) /2 n j ( α 0 η ) − 2 j L j ≤ ζ 0 j n j ( α 0 η ) − 2 j L j ,
where we take ζ 0 = 108 \zeta_0=108 ζ 0 = 108 , since 12 j 8 j ( j − 1 ) / 2 9 j ( j + 1 ) / 2 = 108 j 72 j ( j − 1 ) / 2 ≤ 108 j 2 12^j8^{j(j-1)/2}9^{j(j+1)/2}=108^j72^{j(j-1)/2}\le108^{j^2} 1 2 j 8 j ( j − 1 ) /2 9 j ( j + 1 ) /2 = 10 8 j 7 2 j ( j − 1 ) /2 ≤ 10 8 j 2 for j ≥ 1 j\ge1 j ≥ 1 . Let R = ln ( n / ( α 0 κ η ) ) R=\ln(n/(\alpha_0\kappa\eta)) R = ln ( n / ( α 0 κ η )) . Using j ≥ 1 j\ge1 j ≥ 1 and R ≥ 0 R\ge0 R ≥ 0 , we obtain
L ≤ ln 96 + j ln 9 + 2 R ≤ 7 ( j + R ) . L\le\ln96+j\ln9+2R\le7(j+R). L ≤ ln 96 + j ln 9 + 2 R ≤ 7 ( j + R ) .
Since 7 j 0 2 ≤ ( 7 ζ 0 ) j 2 = 756 j 2 7^{j^2_0} \leq(7\zeta_0)^{j^2} = 756^{j^2} 7 j 0 2 ≤ ( 7 ζ 0 ) j 2 = 75 6 j 2 , we obtain
T j = O ( c s m p l ⋅ 756 j 2 n j ( α 0 η ) − 2 j ( j + ln n α 0 κ η ) j ) . T_j = O\left(c_{\mathrm{smpl}}\cdot756^{j^2} n^j(\alpha_0\eta)^{-2j}\left(j+\ln\frac{n}{\alpha_0\kappa\eta}\right)^j\right). T j = O ( c smpl ⋅ 75 6 j 2 n j ( α 0 η ) − 2 j ( j + ln α 0 κ η n ) j ) .
Substituting c s m p l = O ( n K m ) c_{\mathrm{smpl}}=O(nKm) c smpl = O ( n K m ) gives the precise runtime bound in Claim Claim 3.
We now show that this runtime is polynomial in the sense of Claim Claim 3. Let N = K m n / ( α 0 η κ ) ≥ 1 N=Kmn/(\alpha_0\eta\kappa)\geq1 N = K mn / ( α 0 η κ ) ≥ 1 .
We have K m n j + 1 ≤ N j + 1 Km\,n^{j+1}\leq N^{j+1} K m n j + 1 ≤ N j + 1 and ( α 0 η ) − 2 j ≤ N 2 j (\alpha_0\eta)^{-2j}\leq N^{2j} ( α 0 η ) − 2 j ≤ N 2 j . Moreover, using j ≤ 2 j j\leq2^j j ≤ 2 j and ln y ≤ y \ln y\leq y ln y ≤ y for y > 0 y>0 y > 0 , we get j + ln ( n / ( α 0 κ η ) ) ≤ 2 j + N ≤ 2 j + 1 N j+\ln(n/(\alpha_0\kappa\eta))\leq2^j+N\leq2^{j+1}N j + ln ( n / ( α 0 κ η )) ≤ 2 j + N ≤ 2 j + 1 N , and hence
( j + ln n α 0 κ η ) j ≤ 2 j ( j + 1 ) N j . \left(j+\ln\frac{n}{\alpha_0\kappa\eta}\right)^j\leq2^{j(j+1)}N^j. ( j + ln α 0 κ η n ) j ≤ 2 j ( j + 1 ) N j .
Combining these bounds with 756 ≤ 2 10 756\leq2^{10} 756 ≤ 2 10 and j ( j + 1 ) ≤ 2 j 2 j(j+1)\leq2j^2 j ( j + 1 ) ≤ 2 j 2 for j ≥ 1 j\geq1 j ≥ 1 , the runtime is at most
O ( 756 j 2 ⋅ 2 j ( j + 1 ) ⋅ N 4 j + 1 ) ≤ O ( 2 12 j 2 N 4 ( j + 1 ) ) ≤ O ( ( 2 j 2 N j + 1 ) 12 ) , O\left(756^{j^2}\cdot2^{j(j+1)}\cdot N^{4j+1}\right)
\leq O\left(2^{12j^2}N^{4(j+1)}\right)
\leq O\left(\left(2^{j^2}N^{j+1}\right)^{12}\right), O ( 75 6 j 2 ⋅ 2 j ( j + 1 ) ⋅ N 4 j + 1 ) ≤ O ( 2 12 j 2 N 4 ( j + 1 ) ) ≤ O ( ( 2 j 2 N j + 1 ) 12 ) ,
which is polynomial in 2 j 2 N j + 1 2^{j^2}N^{j+1} 2 j 2 N j + 1 , as claimed. Finally, the case j = 0 j=0 j = 0 takes constant time.
Thus, both accuracy and runtime have been analyzed, showing the desired bounds. The proof of Claim Claim 3 is now complete.
Proof of clm:g-ub.
Set a q = 1 / α q a_q=1/\alpha_q a q = 1/ α q . Then a 0 ≥ 1 a_0\geq1 a 0 ≥ 1 and a q + 1 = 1 + ln a q a_{q+1}=1+\ln a_q a q + 1 = 1 + ln a q . Since 1 + ln x ≤ 2 x 1+\ln x\leq2\sqrt{x} 1 + ln x ≤ 2 x for x ≥ 1 x\geq1 x ≥ 1 , induction gives a q ≤ 4 a 0 1 / 2 q a_q\leq4a_0^{1/2^q} a q ≤ 4 a 0 1/ 2 q for q ≥ 1 q\geq1 q ≥ 1 . Substitution and rearrangement of the factors now give both bounds:
1 G ℓ − 1 = a 0 ∏ q = 1 ℓ − 1 a q ≤ a 0 4 ℓ − 1 a 0 ∑ q = 1 ℓ − 1 2 − q ≤ 4 ℓ − 1 a 0 2 , \frac{1}{G_{\ell-1}}=a_0\prod_{q=1}^{\ell-1}a_q\leq a_0\,4^{\ell-1}a_0^{\sum_{q=1}^{\ell-1}2^{-q}}\leq4^{\ell-1}a_0^2, G ℓ − 1 1 = a 0 q = 1 ∏ ℓ − 1 a q ≤ a 0 4 ℓ − 1 a 0 ∑ q = 1 ℓ − 1 2 − q ≤ 4 ℓ − 1 a 0 2 ,
∏ ℓ = 1 j 1 G ℓ − 1 = a 0 j ∏ q = 1 j − 1 a q j − q ≤ a 0 j 4 ∑ q = 1 j − 1 ( j − q ) a 0 ∑ q = 1 j − 1 ( j − q ) / 2 q ≤ 4 j ( j − 1 ) / 2 a 0 2 j . \prod_{\ell=1}^{j}\frac{1}{G_{\ell-1}}=a_0^j\prod_{q=1}^{j-1}a_q^{j-q}\leq a_0^j4^{\sum_{q=1}^{j-1}(j-q)}a_0^{\sum_{q=1}^{j-1}(j-q)/2^q}\leq4^{j(j-1)/2}a_0^{2j}. ℓ = 1 ∏ j G ℓ − 1 1 = a 0 j q = 1 ∏ j − 1 a q j − q ≤ a 0 j 4 ∑ q = 1 j − 1 ( j − q ) a 0 ∑ q = 1 j − 1 ( j − q ) / 2 q ≤ 4 j ( j − 1 ) /2 a 0 2 j .
Proof of clm:eps-ub.
Unrolling the recurrence gives η ℓ − 1 = 1 − ( 1 − η ) 1 / 3 j − ℓ + 1 \eta_{\ell-1}=1-(1-\eta)^{1/3^{j-\ell+1}} η ℓ − 1 = 1 − ( 1 − η ) 1/ 3 j − ℓ + 1 . For 0 < r ≤ 1 0<r\leq1 0 < r ≤ 1 , concavity of x ↦ x r x\mapsto x^r x ↦ x r gives ( 1 − η ) r ≤ 1 − r η (1-\eta)^r\leq1-r\eta ( 1 − η ) r ≤ 1 − r η . Taking r = 3 − ( j − ℓ + 1 ) r=3^{-(j-\ell+1)} r = 3 − ( j − ℓ + 1 ) proves the first bound. Multiplying these bounds over ℓ ∈ [ j ] \ell\in[j] ℓ ∈ [ j ] gives
∏ ℓ = 1 j 1 η ℓ − 1 2 ≤ 9 j ( j + 1 ) / 2 η 2 j , \prod_{\ell=1}^{j}\frac{1}{\eta_{\ell-1}^2}\leq\frac{9^{j(j+1)/2}}{\eta^{2j}}, ℓ = 1 ∏ j η ℓ − 1 2 1 ≤ η 2 j 9 j ( j + 1 ) /2 ,
as desired.
Proof of clm:delta-ub.
Note that we have p ℓ = ln ( 4 n / κ ℓ ) ≥ ln 4 > 1 p_\ell=\ln(4n/\kappa_\ell)\geq\ln4>1 p ℓ = ln ( 4 n / κ ℓ ) ≥ ln 4 > 1 which also gives I ℓ ≥ 1 I_\ell\geq1 I ℓ ≥ 1 . Together with Claims 5 and 6, this gives
I ℓ = ⌈ 3 η ℓ − 1 2 G ℓ − 1 ln 4 n κ ℓ ⌉ ≤ 6 p ℓ η ℓ − 1 2 G ℓ − 1 , I_\ell=\left\lceil\frac{3}{\eta_{\ell-1}^2G_{\ell-1}}\ln\frac{4n}{\kappa_\ell}\right\rceil\leq\frac{6p_\ell}{\eta_{\ell-1}^2G_{\ell-1}}, I ℓ = ⌈ η ℓ − 1 2 G ℓ − 1 3 ln κ ℓ 4 n ⌉ ≤ η ℓ − 1 2 G ℓ − 1 6 p ℓ ,
and thus,
B ℓ ≤ 2 n I ℓ ≤ 12 n p ℓ η ℓ − 1 2 G ℓ − 1 ≤ 12 n p ℓ ⋅ 4 ℓ − 1 α 0 2 9 j − ℓ + 1 η 2 ≤ 12 ⋅ 9 j n α 0 2 η 2 p ℓ . B_\ell\le2nI_\ell\le\frac{12np_\ell}{\eta_{\ell-1}^{2}G_{\ell-1}} \le12np_\ell\cdot\frac{4^{\ell-1}}{\alpha_0^2}\frac{9^{j-\ell+1}}{\eta^2} \le\frac{12\cdot9^j n}{\alpha_0^2\eta^2}p_\ell. B ℓ ≤ 2 n I ℓ ≤ η ℓ − 1 2 G ℓ − 1 12 n p ℓ ≤ 12 n p ℓ ⋅ α 0 2 4 ℓ − 1 η 2 9 j − ℓ + 1 ≤ α 0 2 η 2 12 ⋅ 9 j n p ℓ .
Using κ ℓ − 1 = κ ℓ / ( 2 B ℓ ) \kappa_{\ell-1}=\kappa_\ell/(2B_\ell) κ ℓ − 1 = κ ℓ / ( 2 B ℓ ) and p ℓ ≥ 1 p_\ell\ge1 p ℓ ≥ 1 , we obtain
p ℓ − 1 = p ℓ + ln ( 2 B ℓ ) ≤ 2 p ℓ + ln ( 24 ⋅ 9 j n α 0 2 η 2 ) . p_{\ell-1}=p_\ell+\ln(2B_\ell)\le2p_\ell+\ln\left(\frac{24\cdot9^j n}{\alpha_0^2\eta^2}\right). p ℓ − 1 = p ℓ + ln ( 2 B ℓ ) ≤ 2 p ℓ + ln ( α 0 2 η 2 24 ⋅ 9 j n ) .
Starting from p j = ln ( 4 n / κ ) p_j=\ln(4n/\kappa) p j = ln ( 4 n / κ ) and iterating this recurrence yields
p ℓ ≤ 2 j − ℓ L and ∏ ℓ = 1 j p ℓ ≤ 2 j ( j − 1 ) / 2 L j , p_\ell\le2^{j-\ell}L \quad\text{and}\quad\prod_{\ell=1}^{j}p_\ell\le2^{j(j-1)/2}L^j, p ℓ ≤ 2 j − ℓ L and ℓ = 1 ∏ j p ℓ ≤ 2 j ( j − 1 ) /2 L j ,
as desired. The proof of the claim is now complete. ■
Proof of Claim 4
Define the empirical averages of the exact and the estimated values by
w ˉ t ( j ) = 1 r ∑ i = 1 r W j ( ω ( i ) ) , w ^ t ( j ) = 1 r ∑ i = 1 r W ^ j ( ω ( i ) ) . \bar{w}_t^{(j)}=\frac{1}{r}\sum_{i=1}^{r}W_j(\omega^{(i)}),\qquad\widehat{w}_t^{(j)}=\frac{1}{r}\sum_{i=1}^{r}\widehat{W}_j(\omega^{(i)}). w ˉ t ( j ) = r 1 i = 1 ∑ r W j ( ω ( i ) ) , w t ( j ) = r 1 i = 1 ∑ r W j ( ω ( i ) ) .
Recall that W j = ∏ ℓ = 0 j − 1 max { ρ ℓ , α ℓ } ≤ 1 W_j=\prod_{\ell=0}^{j-1}\max\{\rho_\ell,\alpha_\ell\}\le1 W j = ∏ ℓ = 0 j − 1 max { ρ ℓ , α ℓ } ≤ 1 . Together with 0 < α ℓ ≤ 1 0<\alpha_\ell\le1 0 < α ℓ ≤ 1 , this implies G j − 1 ≤ W j ≤ 1 G_{j-1}\le W_j\le1 G j − 1 ≤ W j ≤ 1 almost surely. By independence of the sampled trajectories, the variables W j ( ω ( i ) ) W_j(\omega^{(i)}) W j ( ω ( i ) ) are therefore independent and take values in [ 0 , 1 ] [0,1] [ 0 , 1 ] , and their average has mean E [ w ˉ t ( j ) ] = E ∗ [ W j ∣ h t ] ≥ G j − 1 \mathbb{E}[\bar{w}_t^{(j)}]=\mathbb{E}_* [W_j\mid h_t]\ge G_{j-1} E [ w ˉ t ( j ) ] = E ∗ [ W j ∣ h t ] ≥ G j − 1 . Hence, a Chernoff Bound (see Appendix § 9 .§ 1 ), applied to these r r r variables with parameter η \eta η , gives
Pr [ ∣ w ˉ t ( j ) − E [ w ˉ t ( j ) ] ∣ > η E [ w ˉ t ( j ) ] ] ≤ 2 exp ( − η 2 r E [ w ˉ t ( j ) ] 3 ) ≤ 2 exp ( − η 2 r G j − 1 3 ) . \Pr\left[\left|\bar{w}_t^{(j)}-\mathbb{E}\left[\bar{w}_t^{(j)}\right]\right|>\eta\mathbb{E}\left[\bar{w}_t^{(j)}\right]\right]\le2\exp\left(-\frac{\eta^2r\mathbb{E}\left[\bar{w}_t^{(j)}\right]}{3}\right)\le2\exp\left(-\frac{\eta^2rG_{j-1}}{3}\right). Pr [ w ˉ t ( j ) − E [ w ˉ t ( j ) ] > η E [ w ˉ t ( j ) ] ] ≤ 2 exp − 3 η 2 r E [ w ˉ t ( j ) ] ≤ 2 exp ( − 3 η 2 r G j − 1 ) .
Moreover, a union bound over i ∈ [ r ] i\in[r] i ∈ [ r ] shows that, with probability at least 1 − κ r 1-\kappa r 1 − κ r ,
W ^ j ( ω ( i ) ) ∈ [ ( 1 − η ) W j ( ω ( i ) ) , ( 1 − η ) − 1 W j ( ω ( i ) ) ] for every i ∈ [ r ] . \widehat{W}_j(\omega^{(i)})\in[(1-\eta)W_j(\omega^{(i)}),(1-\eta)^{-1}W_j(\omega^{(i)})]\quad\text{for every }i\in[r]. W j ( ω ( i ) ) ∈ [( 1 − η ) W j ( ω ( i ) ) , ( 1 − η ) − 1 W j ( ω ( i ) )] for every i ∈ [ r ] .
On this event, averaging over i i i gives w ^ t ( j ) ∈ [ ( 1 − η ) w ˉ t ( j ) , ( 1 − η ) − 1 w ˉ t ( j ) ] \widehat{w}_t^{(j)}\in[(1-\eta)\bar{w}_t^{(j)},(1-\eta)^{-1}\bar{w}_t^{(j)}] w t ( j ) ∈ [( 1 − η ) w ˉ t ( j ) , ( 1 − η ) − 1 w ˉ t ( j ) ] . Combining this event with the concentration event ∣ w ˉ t ( j ) − E [ w ˉ t ( j ) ] ∣ ≤ η E [ w ˉ t ( j ) ] |\bar{w}_t^{(j)}-\mathbb{E}[\bar{w}_t^{(j)}]|\le\eta\mathbb{E}[\bar{w}_t^{(j)}] ∣ w ˉ t ( j ) − E [ w ˉ t ( j ) ] ∣ ≤ η E [ w ˉ t ( j ) ] and using 1 + η ≤ ( 1 − η ) − 1 1+\eta\le(1-\eta)^{-1} 1 + η ≤ ( 1 − η ) − 1 , we conclude that, with probability at least 1 − κ r − 2 exp ( − η 2 r G j − 1 / 3 ) 1-\kappa r-2\exp(-\eta^2rG_{j-1}/3) 1 − κ r − 2 exp ( − η 2 r G j − 1 /3 ) ,
w ^ t ( j ) ∈ [ ( 1 − η ) 2 E [ w ˉ t ( j ) ] , ( 1 − η ) − 2 E [ w ˉ t ( j ) ] ] . \widehat{w}_t^{(j)}\in\left[(1-\eta)^2\mathbb{E}\left[\bar{w}_t^{(j)}\right],(1-\eta)^{-2}\mathbb{E}\left[\bar{w}_t^{(j)}\right]\right]. w t ( j ) ∈ [ ( 1 − η ) 2 E [ w ˉ t ( j ) ] , ( 1 − η ) − 2 E [ w ˉ t ( j ) ] ] .
Finally, Claim 1 gives Z t ( j ) ( h t ) = Z t ( 0 ) ( h t ) E ∗ [ W j ∣ h t ] = Z t ( 0 ) ( h t ) E ∗ [ w ˉ t ( j ) ] Z_t^{(j)}(h_t)=Z_t^{(0)}(h_t)\mathbb{E}_*[W_j\mid h_t]=Z_t^{(0)}(h_t)\mathbb{E}_*[\bar{w}_t^{(j)}] Z t ( j ) ( h t ) = Z t ( 0 ) ( h t ) E ∗ [ W j ∣ h t ] = Z t ( 0 ) ( h t ) E ∗ [ w ˉ t ( j ) ] , while Z ^ t ( j ) ( h t ) = Z t ( 0 ) ( h t ) w ^ t ( j ) \widehat{Z}_t^{(j)}(h_t)=Z_t^{(0)}(h_t)\widehat{w}_t^{(j)} Z t ( j ) ( h t ) = Z t ( 0 ) ( h t ) w t ( j ) by definition. Therefore, we have Z ^ t ( j ) ( h t ) / Z t ( j ) ( h t ) ∈ [ ( 1 − η ) 2 , ( 1 − η ) − 2 ] \widehat{Z}_t^{(j)}(h_t)/Z_t^{(j)}(h_t)\in[(1-\eta)^2,(1-\eta)^{-2}] Z t ( j ) ( h t ) / Z t ( j ) ( h t ) ∈ [( 1 − η ) 2 , ( 1 − η ) − 2 ] with probability at least 1 − κ r − 2 exp ( − η 2 r G j − 1 / 3 ) 1-\kappa r-2\exp(-\eta^2rG_{j-1}/3) 1 − κ r − 2 exp ( − η 2 r G j − 1 /3 ) which completes the proof.
Proof of lem:alpha-convergence
Fix 0 < ε ≤ 1 0 < \varepsilon\le1 0 < ε ≤ 1 and set a j = 1 / α j a_j = 1/\alpha_j a j = 1/ α j . Since 0 < α 0 ≤ 1 0 < \alpha_0 \le1 0 < α 0 ≤ 1 , we have a 0 ≥ 1 a_0 \ge1 a 0 ≥ 1 and a j + 1 = 1 + ln a j a_{j+1} = 1 + \ln a_j a j + 1 = 1 + ln a j . Let f ( x ) = 1 + ln x f(x) = 1 + \ln x f ( x ) = 1 + ln x and define k = min { ℓ ≥ 0 : log 2 ∘ ℓ ( a 0 ) ≤ 16 } k = \min\{\ell\ge0 : \log_2^{\circ\ell}(a_0) \le16\} k = min { ℓ ≥ 0 : log 2 ∘ ℓ ( a 0 ) ≤ 16 } .
The proof has two phases. Iterated logarithms first bring a j a_j a j below a constant; we then show that a j − 1 a_j - 1 a j − 1 decreases at rate O ( 1 / j ) O(1/j) O ( 1/ j ) and k = O ( log ∗ a 0 ) k = O(\log^* a_0) k = O ( log ∗ a 0 ) . We claim that
f ∘ ℓ ( a 0 ) ≤ log 2 ∘ ℓ ( a 0 ) ( 0 ≤ ℓ ≤ k ) . f^{\circ\ell}(a_0) \le\log_2^{\circ\ell}(a_0) \qquad(0 \le\ell\le k). f ∘ ℓ ( a 0 ) ≤ log 2 ∘ ℓ ( a 0 ) ( 0 ≤ ℓ ≤ k ) .
For ℓ = 0 \ell= 0 ℓ = 0 , this is equality. If it holds for some ℓ < k \ell< k ℓ < k , then log 2 ∘ ℓ ( a 0 ) > 16 \log_2^{\circ\ell}(a_0) > 16 log 2 ∘ ℓ ( a 0 ) > 16 . Because f f f is increasing and f ( x ) ≤ log 2 x f(x) \le\log_2 x f ( x ) ≤ log 2 x for every x ≥ 16 x \ge16 x ≥ 16 , it follows that
f ∘ ( ℓ + 1 ) ( a 0 ) ≤ f ( log 2 ∘ ℓ ( a 0 ) ) ≤ log 2 ∘ ( ℓ + 1 ) ( a 0 ) . f^{\circ(\ell+1)}(a_0) \le f\left(\log_2^{\circ\ell}(a_0)\right) \le\log_2^{\circ(\ell+1)}(a_0). f ∘ ( ℓ + 1 ) ( a 0 ) ≤ f ( log 2 ∘ ℓ ( a 0 ) ) ≤ log 2 ∘ ( ℓ + 1 ) ( a 0 ) .
Thus, we have a k = f ∘ k ( a 0 ) ≤ 16 a_k = f^{\circ k}(a_0) \le16 a k = f ∘ k ( a 0 ) ≤ 16 .
Define b s = a k + s − 1 b_s = a_{k+s} - 1 b s = a k + s − 1 . Then 0 ≤ b 0 ≤ 15 0 \le b_0 \le15 0 ≤ b 0 ≤ 15 and b s + 1 = ln ( 1 + b s ) b_{s+1} = \ln(1+b_s) b s + 1 = ln ( 1 + b s ) . If b 0 = 0 b_0 = 0 b 0 = 0 , then b s = 0 b_s = 0 b s = 0 for every s s s ; choosing J = k J = k J = k gives α J = 1 \alpha_J = 1 α J = 1 , so the desired conclusion follows. Assume b 0 > 0 b_0 > 0 b 0 > 0 . Then 0 < b s ≤ b 0 ≤ 15 0 < b_s \le b_0 \le15 0 < b s ≤ b 0 ≤ 15 for every s s s . For every b > 0 b > 0 b > 0 , the integral representation of the logarithm gives
ln ( 1 + b ) = b − ∫ 0 b x 1 + x d x ≤ b − ∫ 0 b x 1 + b d x = b − b 2 2 ( 1 + b ) = b ( 2 + b ) 2 ( 1 + b ) . \begin{aligned}
\ln(1+b) &= b - \int_0^b \frac{x}{1+x}\,dx \\
&\le b - \int_0^b \frac{x}{1+b}\,dx \\
&= b - \frac{b^2}{2(1+b)} = \frac{b(2+b)}{2(1+b)}.
\end{aligned} ln ( 1 + b ) = b − ∫ 0 b 1 + x x d x ≤ b − ∫ 0 b 1 + b x d x = b − 2 ( 1 + b ) b 2 = 2 ( 1 + b ) b ( 2 + b ) .
Applying this estimate with b = b s b = b_s b = b s yields
1 b s + 1 = 2 ( 1 + b s ) b s ( 2 + b s ) = 1 b s + 1 2 + b s ≥ 1 b s + 1 17 . \frac{1}{b_{s+1}} = \frac{2(1+b_s)}{b_s(2+b_s)} = \frac{1}{b_s} + \frac{1}{2+b_s} \ge\frac{1}{b_s} + \frac{1}{17}. b s + 1 1 = b s ( 2 + b s ) 2 ( 1 + b s ) = b s 1 + 2 + b s 1 ≥ b s 1 + 17 1 .
Iterating gives 1 / b s ≥ s / 17 1/b_s \ge s/17 1/ b s ≥ s /17 and, hence, b s ≤ 17 / s b_s \le17/s b s ≤ 17/ s for s ≥ 1 s \ge1 s ≥ 1 . Let S = ⌈ 34 / ε ⌉ S = \lceil34/\varepsilon\rceil S = ⌈ 34/ ε ⌉ and J = k + S J = k + S J = k + S . For this choice of J J J , we have
α J = 1 1 + b S ≥ 1 − b S ≥ 1 − ε 2 . \alpha_J = \frac{1}{1+b_S} \ge1-b_S \ge1-\frac{\varepsilon}{2}. α J = 1 + b S 1 ≥ 1 − b S ≥ 1 − 2 ε .
Moreover, we have J = O ( log ∗ a 0 + 1 / ε ) = O ( log ∗ ( 1 / α 0 ) + 1 / ε ) J = O(\log^* a_0 + 1/\varepsilon) = O(\log^*(1/\alpha_0) + 1/\varepsilon) J = O ( log ∗ a 0 + 1/ ε ) = O ( log ∗ ( 1/ α 0 ) + 1/ ε ) .
Omitted Proofs from sec:competitive-algs
Proofs of the claims used in lem:main-hardness
Posterior calculation.
Suppose that M t = n 3 j M_t = n^{3j} M t = n 3 j which implies that the observed history has zero likelihood under D ( h ) D^{(h)} D ( h ) for h < j h < j h < j . Now, fix j ≤ h < K j \le h < K j ≤ h < K . For every observed sample X s X_s X s , its probability under D ( h + 1 ) D^{(h+1)} D ( h + 1 ) is 1 − 1 / n 2 1 - 1/n^2 1 − 1/ n 2 times its probability under D ( h ) D^{(h)} D ( h ) by definition of D ( h ) D^{(h)} D ( h ) . The likelihood ratio of the observed history is therefore
Pr [ X 1 , … , X t ∣ H = h + 1 ] Pr [ X 1 , … , X t ∣ H = h ] = ( 1 − 1 n 2 ) t . \frac{\Pr[X_1,\ldots,X_t \mid H=h+1]}{\Pr[X_1,\ldots,X_t \mid H=h]} = \left(1-\frac{1}{n^2}\right)^t. Pr [ X 1 , … , X t ∣ H = h ] Pr [ X 1 , … , X t ∣ H = h + 1 ] = ( 1 − n 2 1 ) t .
Moreover, the prior weights satisfy π h + 1 π h = 1 n 3 \frac{\pi_{h+1}}{\pi_h}=\frac{1}{n^3} π h π h + 1 = n 3 1 . Therefore, Bayes’ rule gives
Pr [ H = h + 1 ∣ F t ] Pr [ H = h ∣ F t ] = ( 1 − 1 / n 2 ) t n 3 . \frac{\Pr[H=h+1\mid\mathcal{F}_t]}{\Pr[H=h\mid\mathcal{F}_t]}=\frac{(1-1/n^2)^t}{n^3}. Pr [ H = h ∣ F t ] Pr [ H = h + 1 ∣ F t ] = n 3 ( 1 − 1/ n 2 ) t .
Thus, the posterior weights on h = j , … , K h=j,\ldots,K h = j , … , K form a truncated geometric sequence satisfying
Pr [ H = h ∣ F t ] ∝ ( ( 1 − 1 / n 2 ) t n 3 ) h − j . \Pr[H=h\mid\mathcal{F}_t]\propto\left(\frac{(1-1/n^2)^t}{n^3}\right)^{h-j}. Pr [ H = h ∣ F t ] ∝ ( n 3 ( 1 − 1/ n 2 ) t ) h − j .
for j ≤ h ≤ K j\le h\le K j ≤ h ≤ K . Normalizing this sequence gives the stated formula. ■
Proof of Claim 2
Recall that p = 1 / n 2 p=1/n^2 p = 1/ n 2 and q = 1 − p q=1-p q = 1 − p . Since t ≥ 2 t\ge2 t ≥ 2 and 0 < q < 1 0<q<1 0 < q < 1 , we have
1 − q t t p = 1 t ∑ r = 0 t − 1 q r ≤ 1 + ( t − 1 ) q t = 1 − t − 1 t p ≤ 1 − p 2 ≤ 1 − q t n 3 , \begin{aligned}
\frac{1-q^t}{tp}=\frac{1}{t}\sum_{r=0}^{t-1}q^r\le\frac{1+(t-1)q}{t} \\
&=1-\frac{t-1}{t}p\le1-\frac{p}{2}\le1-\frac{q^t}{n^3},
\end{aligned} tp 1 − q t = t 1 r = 0 ∑ t − 1 q r ≤ t 1 + ( t − 1 ) q = 1 − t t − 1 p ≤ 1 − 2 p ≤ 1 − n 3 q t ,
where the last inequality uses n ≥ 2 n\ge2 n ≥ 2 and q t ≤ 1 q^t\le1 q t ≤ 1 . Dividing by 1 − q t / n 3 > 0 1-q^t/n^3>0 1 − q t / n 3 > 0 gives
m t ∗ = 1 − q t p ( 1 − q t / n 3 ) ≤ t , m_t^*=\frac{1-q^t}{p(1-q^t/n^3)}\le t, m t ∗ = p ( 1 − q t / n 3 ) 1 − q t ≤ t ,
as desired. ■
Proof of Lemma 8
We begin by recalling the results of Bai et al. [3 ] :
Theorem 5 (c.f. Bai et al. [3 ] , Theorem 1). For any β ∈ [ 0 , 1 / e ] \beta\in[0,1/e] β ∈ [ 0 , 1/ e ] , suppose λ 1 , λ 2 \lambda_1,\lambda_2 λ 1 , λ 2 are two roots of − x ln x = β -x\ln x=\beta − x ln x = β with λ 1 ≤ λ 2 \lambda_1\le\lambda_2 λ 1 ≤ λ 2 . If there exists a left-continuous non-increasing function θ : [ λ 1 , λ 2 ] → [ 0 , 1 ] \theta:[\lambda_1,\lambda_2]\to[0,1] θ : [ λ 1 , λ 2 ] → [ 0 , 1 ] satisfying θ ( λ 1 ) = 1 \theta(\lambda_1)=1 θ ( λ 1 ) = 1 and
∫ z 1 ∫ 0 t 1 t θ ( max { s , z } ) t d s d t ≥ α θ ( z ) , ∀ z ∈ [ λ 1 , λ 2 ] , (39) \int_z^1\int_0^t\frac{1}{t}\theta(\max\{s,z\})^t\,\mathrm{d}s\,\mathrm{d}t\ge\alpha\theta(z),\qquad\forall z\in[\lambda_1,\lambda_2], \tag*{(39)} ∫ z 1 ∫ 0 t t 1 θ ( max { s , z } ) t d s d t ≥ α θ ( z ) , ∀ z ∈ [ λ 1 , λ 2 ] , (39) then, for every horizon n ∈ N n\in\mathbb{N} n ∈ N , there exists a policy that is α \alpha α -consistent and β \beta β -robust.
Now, for every β ∈ ( 0 , 1 / e ) \beta\in(0,1/e) β ∈ ( 0 , 1/ e ) , q ∈ ( 0 , 1 ) q\in(0,1) q ∈ ( 0 , 1 ) , define the function θ ˉ β , q ( t ) = q \bar{\theta}_{\beta,q}(t)=q θ ˉ β , q ( t ) = q for all t ∈ [ λ 1 , λ 2 ] t\in[\lambda_1,\lambda_2] t ∈ [ λ 1 , λ 2 ] . Moreover, let θ ˉ β , q ( t ) = 1 \bar{\theta}_{\beta,q}(t)=1 θ ˉ β , q ( t ) = 1 for t ∈ [ 0 , λ 1 ] t\in[0,\lambda_1] t ∈ [ 0 , λ 1 ] and θ ˉ β , q ( t ) = 0 \bar{\theta}_{\beta,q}(t)=0 θ ˉ β , q ( t ) = 0 for t ∈ ( λ 2 , 1 ] t\in(\lambda_2,1] t ∈ ( λ 2 , 1 ] . In what follows, we will prove the following lemma:
Lemma 9. Setting α = 1 / e + 1 / K \alpha=1/e+1/K α = 1/ e + 1/ K , β = 1 / e − 2 / ( e K 2 ) \beta=1/e-2/(eK^2) β = 1/ e − 2/ ( e K 2 ) , q = exp ( − 4 e / K ) q=\exp(-4e/K) q = exp ( − 4 e / K ) , and θ = θ ˉ β , q \theta=\bar{\theta}_{\beta,q} θ = θ ˉ β , q , inequality (39) is satisfied for every K ≥ 39 K\ge39 K ≥ 39 .
It is immediate that this lemma implies Lemma 8.
Proof of Lemma 9. We drop the subscript K K K from variables to ease the notation, i.e., we have α = 1 / e + 1 / K \alpha=1/e+1/K α = 1/ e + 1/ K , β = 1 / e − 2 / ( e K 2 ) \beta=1/e-2/(eK^2) β = 1/ e − 2/ ( e K 2 ) , q = exp ( − 4 e / K ) q=\exp(-4e/K) q = exp ( − 4 e / K ) . Let λ 1 ≤ λ 2 \lambda_1\le\lambda_2 λ 1 ≤ λ 2 denote the two roots of − x ln x = β -x\ln x=\beta − x ln x = β , and L ( z ) L(z) L ( z ) be the left-hand side of (39). For z = λ 1 z=\lambda_1 z = λ 1 , the inner integral in (39) equals
∫ 0 t θ ( max { s , λ 1 } ) t d s = { λ 1 + ( t − λ 1 ) q t , λ 1 ≤ t ≤ λ 2 , λ 1 + ( λ 2 − λ 1 ) q t , λ 2 < t ≤ 1. \int_0^t \theta(\max\{s,\lambda_1\})^t\,ds =
\begin{cases}
\lambda_1+(t-\lambda_1)q^t, & \lambda_1\le t\le\lambda_2,\\
\lambda_1+(\lambda_2-\lambda_1)q^t, & \lambda_2<t\le1.
\end{cases} ∫ 0 t θ ( max { s , λ 1 } ) t d s = { λ 1 + ( t − λ 1 ) q t , λ 1 + ( λ 2 − λ 1 ) q t , λ 1 ≤ t ≤ λ 2 , λ 2 < t ≤ 1.
Since − λ 1 ln λ 1 = β -\lambda_1\ln\lambda_1=\beta − λ 1 ln λ 1 = β , it follows that
L ( λ 1 ) = β + ∫ λ 1 λ 2 ( 1 − λ 1 t ) q t d t + ( λ 2 − λ 1 ) ∫ λ 2 1 q t t d t = : A 1 . (40) L(\lambda_1)=\beta+\int_{\lambda_1}^{\lambda_2}\left(1-\frac{\lambda_1}{t}\right)q^t\,dt+(\lambda_2-\lambda_1)\int_{\lambda_2}^1\frac{q^t}{t}\,dt=:A_1. \tag*{(40)} L ( λ 1 ) = β + ∫ λ 1 λ 2 ( 1 − t λ 1 ) q t d t + ( λ 2 − λ 1 ) ∫ λ 2 1 t q t d t =: A 1 . (40)
For λ 1 < z ≤ λ 2 \lambda_1<z\le\lambda_2 λ 1 < z ≤ λ 2 , the inner integral equals t q t tq^t t q t when z ≤ t ≤ λ 2 z\le t\le\lambda_2 z ≤ t ≤ λ 2 and λ 2 q t \lambda_2q^t λ 2 q t when λ 2 < t ≤ 1 \lambda_2<t\le1 λ 2 < t ≤ 1 and, hence,
L ( z ) q = ∫ z λ 2 q t − 1 d t + λ 2 q ∫ λ 2 1 q t t d t ≥ λ 2 q ∫ λ 2 1 q t t d t = : A 2 . (41) \begin{aligned}
\frac{L(z)}{q}=\int_z^{\lambda_2}q^{t-1}\,dt+\frac{\lambda_2}{q}\int_{\lambda_2}^1\frac{q^t}{t}\,dt \\
&\ge\frac{\lambda_2}{q}\int_{\lambda_2}^1\frac{q^t}{t}\,dt=:A_2. \tag*{(41)}
\end{aligned} q L ( z ) = ∫ z λ 2 q t − 1 d t + q λ 2 ∫ λ 2 1 t q t d t ≥ q λ 2 ∫ λ 2 1 t q t d t =: A 2 . (41)
Since θ ( λ 1 ) = 1 \theta(\lambda_1)=1 θ ( λ 1 ) = 1 and θ ( z ) = q \theta(z)=q θ ( z ) = q for λ 1 < z ≤ λ 2 \lambda_1<z\le\lambda_2 λ 1 < z ≤ λ 2 , it suffices to prove A 1 , A 2 ≥ α A_1,A_2\ge\alpha A 1 , A 2 ≥ α .
Define r − = 1 − e λ 1 r_-=1-e\lambda_1 r − = 1 − e λ 1 and r + = e λ 2 − 1 r_+=e\lambda_2-1 r + = e λ 2 − 1 so that λ 1 = 1 − r − e \lambda_1=\frac{1-r_-}{e} λ 1 = e 1 − r − and λ 2 = 1 + r + e \lambda_2=\frac{1+r_+}{e} λ 2 = e 1 + r + . We have r − , r + > 0 r_-,r_+>0 r − , r + > 0 because λ 1 < 1 / e \lambda_1<1/e λ 1 < 1/ e . Since λ 2 = ( 1 + r + ) / e \lambda_2=(1+r_+)/e λ 2 = ( 1 + r + ) / e and − λ 2 ln λ 2 = β = 1 / e − 2 / ( e K 2 ) -\lambda_2\ln\lambda_2=\beta=1/e-2/(eK^2) − λ 2 ln λ 2 = β = 1/ e − 2/ ( e K 2 ) , we have
( 1 + r + ) ln ( 1 + r + ) − r + = e λ 2 ln ( e λ 2 ) − e λ 2 + 1 = − e β + e λ 2 − e λ 2 + 1 = 1 − e β = 2 K 2 . (1+r_+)\ln(1+r_+)-r_+=e\lambda_2\ln(e\lambda_2)-e\lambda_2+1=-e\beta+e\lambda_2-e\lambda_2+1=1-e\beta=\frac{2}{K^2}. ( 1 + r + ) ln ( 1 + r + ) − r + = e λ 2 ln ( e λ 2 ) − e λ 2 + 1 = − e β + e λ 2 − e λ 2 + 1 = 1 − e β = K 2 2 .
Therefore, we have
∫ 0 r + ln ( 1 + s ) d s = ( 1 + r + ) ln ( 1 + r + ) − r + = 2 K 2 . (42) \int_0^{r_+}\ln(1+s)\,ds=(1+r_+)\ln(1+r_+)-r_+=\frac{2}{K^2}. \tag*{(42)} ∫ 0 r + ln ( 1 + s ) d s = ( 1 + r + ) ln ( 1 + r + ) − r + = K 2 2 . (42)
Because log ( 1 + s ) ≤ s \log(1+s)\le s log ( 1 + s ) ≤ s , (42) gives
2 K 2 = ∫ 0 r + ln ( 1 + s ) d s ≤ ∫ 0 r + s d s = r + 2 2 , \frac{2}{K^2}=\int_0^{r_+}\ln(1+s)\,ds\le\int_0^{r_+}s\,ds=\frac{r_+^2}{2}, K 2 2 = ∫ 0 r + ln ( 1 + s ) d s ≤ ∫ 0 r + s d s = 2 r + 2 ,
implying r + ≥ 2 / K r_+\ge2/K r + ≥ 2/ K . Moreover, since ln ( 1 + s ) ≥ s / ( 1 + s ) \ln(1+s)\ge s/(1+s) ln ( 1 + s ) ≥ s / ( 1 + s ) , we can argue
2 K 2 = ∫ 0 r + ln ( 1 + s ) d s ≥ ∫ 0 r + s 1 + s d s ≥ r + ⋅ r + 2 ( 1 + r + ) , \frac{2}{K^2}=\int_0^{r_+}\ln(1+s)\,ds\ge\int_0^{r_+}\frac{s}{1+s}\,ds\ge r_+\cdot\frac{r_+}{2(1+r_+)}, K 2 2 = ∫ 0 r + ln ( 1 + s ) d s ≥ ∫ 0 r + 1 + s s d s ≥ r + ⋅ 2 ( 1 + r + ) r + ,
and, thus, r + ≤ 2 ( 1 + K 2 + 1 ) / K 2 ≤ 4 / K r_+\le2(1+\sqrt{K^2+1})/K^2\le4/K r + ≤ 2 ( 1 + K 2 + 1 ) / K 2 ≤ 4/ K .
Similarly, since λ 1 = ( 1 − r − ) / e \lambda_1=(1-r_-)/e λ 1 = ( 1 − r − ) / e and − λ 1 ln λ 1 = β = 1 / e − 2 / ( e K 2 ) -\lambda_1\ln\lambda_1=\beta=1/e-2/(eK^2) − λ 1 ln λ 1 = β = 1/ e − 2/ ( e K 2 ) , we have
r − + ( 1 − r − ) ln ( 1 − r − ) = 2 K 2 , r_-+(1-r_-)\ln(1-r_-)=\frac{2}{K^2}, r − + ( 1 − r − ) ln ( 1 − r − ) = K 2 2 ,
which implies
∫ 0 r − − ln ( 1 − s ) d s = r − + ( 1 − r − ) ln ( 1 − r − ) = 2 K 2 . \int_0^{r_-}-\ln(1-s)\,ds=r_-+(1-r_-)\ln(1-r_-)=\frac{2}{K^2}. ∫ 0 r − − ln ( 1 − s ) d s = r − + ( 1 − r − ) ln ( 1 − r − ) = K 2 2 .
For every s ∈ [ 0 , r − ] s\in[0,r_-] s ∈ [ 0 , r − ] , we have
− ln ( 1 − s ) = ∫ 0 s d u 1 − u ≤ ∫ 0 s d u 1 − r − = s 1 − r − . -\ln(1-s)=\int_0^s\frac{du}{1-u}\le\int_0^s\frac{du}{1-r_-}=\frac{s}{1-r_-}. − ln ( 1 − s ) = ∫ 0 s 1 − u d u ≤ ∫ 0 s 1 − r − d u = 1 − r − s .
Therefore, we conclude
2 K 2 = ∫ 0 r − − ln ( 1 − s ) d s ≤ ∫ 0 r − s 1 − r − d s = r − 2 2 ( 1 − r − ) . \frac{2}{K^2}=\int_{0}^{r_-}-\ln(1-s)\,\mathrm{d}s\le\int_{0}^{r_-}\frac{s}{1-r_-}\,\mathrm{d}s=\frac{r_-^2}{2(1-r_-)}. K 2 2 = ∫ 0 r − − ln ( 1 − s ) d s ≤ ∫ 0 r − 1 − r − s d s = 2 ( 1 − r − ) r − 2 .
Rearranging gives
K 2 r − 2 + 4 r − − 4 ≥ 0. K^2r_-^2+4r_--4\ge0. K 2 r − 2 + 4 r − − 4 ≥ 0.
The roots of the corresponding quadratic equation are 2 ( − 1 ± K 2 + 1 ) K 2 \frac{2(-1\pm\sqrt{K^2+1})}{K^2} K 2 2 ( − 1 ± K 2 + 1 ) . Since r − > 0 r_->0 r − > 0 , it follows that
r − ≥ 2 ( K 2 + 1 − 1 ) K 2 = 2 K 2 + 1 + 1 ≥ 2 K + 2 , r_-\ge\frac{2(\sqrt{K^2+1}-1)}{K^2}=\frac{2}{\sqrt{K^2+1}+1}\ge\frac{2}{K+2}, r − ≥ K 2 2 ( K 2 + 1 − 1 ) = K 2 + 1 + 1 2 ≥ K + 2 2 ,
where the last inequality uses K 2 + 1 ≤ K + 1 \sqrt{K^2+1}\le K+1 K 2 + 1 ≤ K + 1 . Combining this with 2 / K ≤ r + ≤ 4 / K 2/K\le r_+\le4/K 2/ K ≤ r + ≤ 4/ K , we obtain
λ 2 − λ 1 = r + + r − e ≥ 1 e ( 2 K + 2 K + 2 ) ≥ 4 e K − 4 e K 2 . (43) \lambda_2-\lambda_1=\frac{r_++r_-}{e}\ge\frac{1}{e}\left(\frac{2}{K}+\frac{2}{K+2}\right)\ge\frac{4}{eK}-\frac{4}{eK^2}. \tag*{(43)} λ 2 − λ 1 = e r + + r − ≥ e 1 ( K 2 + K + 2 2 ) ≥ eK 4 − e K 2 4 . (43)
Here, the second inequality follows from 1 K + 2 ≥ 1 K − 2 K 2 = K − 2 K 2 \frac{1}{K+2}\ge\frac{1}{K}-\frac{2}{K^2}=\frac{K-2}{K^2} K + 2 1 ≥ K 1 − K 2 2 = K 2 K − 2 . Moreover, we have
λ 2 − 1 / e = r + / e ≤ 4 e K . (44) \lambda_2-1/e=r_+/e\le\frac{4}{eK}. \tag*{(44)} λ 2 − 1/ e = r + / e ≤ eK 4 . (44)
We are now ready to show that A 1 A_1 A 1 and A 2 A_2 A 2 are at least α \alpha α , starting with the former. Recall
A 1 = β + ∫ λ 1 λ 2 ( 1 − λ 1 t ) q t d t + ( λ 2 − λ 1 ) ∫ λ 2 1 q t t d t . A_1=\beta+\int_{\lambda_1}^{\lambda_2}\left(1-\frac{\lambda_1}{t}\right)q^t\,\mathrm{d}t+(\lambda_2-\lambda_1)\int_{\lambda_2}^{1}\frac{q^t}{t}\,\mathrm{d}t. A 1 = β + ∫ λ 1 λ 2 ( 1 − t λ 1 ) q t d t + ( λ 2 − λ 1 ) ∫ λ 2 1 t q t d t .
Since q t ≥ q q^t\ge q q t ≥ q for t ∈ [ 0 , 1 ] t\in[0,1] t ∈ [ 0 , 1 ] and the weights in the definition of A 1 − β A_1-\beta A 1 − β are nonnegative, we have
A 1 − β ≥ q ( ∫ λ 1 λ 2 ( 1 − λ 1 t ) d t + ( λ 2 − λ 1 ) ∫ λ 2 1 d t t ) = q ( λ 2 − λ 1 + λ 1 ln λ 1 − λ 2 ln λ 2 ) = ( i ) q ( λ 2 − λ 1 ) ≥ e − 4 e / K 4 e K ( 1 − 1 K ) ≥ ( i i ) 4 e K ( 1 − 4 e K ) ( 1 − 1 K ) ≥ 4 e K ( 1 − 1 + 4 e K ) . \begin{aligned}
A_1-\beta&\ge q\left(\int_{\lambda_1}^{\lambda_2}\left(1-\frac{\lambda_1}{t}\right)\,\mathrm{d}t+(\lambda_2-\lambda_1)\int_{\lambda_2}^{1}\frac{\mathrm{d}t}{t}\right)\\
&=q(\lambda_2-\lambda_1+\lambda_1\ln\lambda_1-\lambda_2\ln\lambda_2)\\
&\overset{(i)}{=}q(\lambda_2-\lambda_1)\\
&\ge e^{-4e/K}\frac{4}{eK}\left(1-\frac{1}{K}\right)\\
&\overset{(ii)}{\ge}\frac{4}{eK}\left(1-\frac{4e}{K}\right)\left(1-\frac{1}{K}\right)\\
&\ge\frac{4}{eK}\left(1-\frac{1+4e}{K}\right).
\end{aligned} A 1 − β ≥ q ( ∫ λ 1 λ 2 ( 1 − t λ 1 ) d t + ( λ 2 − λ 1 ) ∫ λ 2 1 t d t ) = q ( λ 2 − λ 1 + λ 1 ln λ 1 − λ 2 ln λ 2 ) = ( i ) q ( λ 2 − λ 1 ) ≥ e − 4 e / K eK 4 ( 1 − K 1 ) ≥ ( ii ) eK 4 ( 1 − K 4 e ) ( 1 − K 1 ) ≥ eK 4 ( 1 − K 1 + 4 e ) .
where ( i ) (i) ( i ) uses that λ 1 , λ 2 \lambda_1,\lambda_2 λ 1 , λ 2 are roots of − x ln x = β -x\ln x=\beta − x ln x = β , and ( i i ) (ii) ( ii ) follows from e − x ≥ 1 − x e^{-x}\ge1-x e − x ≥ 1 − x . Because
α − β = 1 K + 2 e K 2 , \alpha-\beta=\frac{1}{K}+\frac{2}{eK^2}, α − β = K 1 + e K 2 2 ,
we obtain
A 1 − α = ( A 1 − β ) − ( α − β ) ≥ 4 e K ( 1 − 1 + 4 e K ) − 1 K − 2 e K 2 = ( 4 − e ) K − ( 16 e + 6 ) e K 2 . A_1-\alpha=(A_1-\beta)-(\alpha-\beta)\ge\frac{4}{eK}\left(1-\frac{1+4e}{K}\right)-\frac{1}{K}-\frac{2}{eK^2}=\frac{(4-e)K-(16e+6)}{eK^2}. A 1 − α = ( A 1 − β ) − ( α − β ) ≥ eK 4 ( 1 − K 1 + 4 e ) − K 1 − e K 2 2 = e K 2 ( 4 − e ) K − ( 16 e + 6 ) .
For every K ≥ 39 K\ge39 K ≥ 39 , the numerator is positive, implying that A 1 ≥ α A_1\ge\alpha A 1 ≥ α , as desired.
Proof of prop:noniid-cr
We now move on to proving A 2 ≥ α A_2 \ge\alpha A 2 ≥ α . Because β = − λ 2 ln λ 2 = λ 2 ∫ λ 2 1 d t t \beta=-\lambda_2\ln\lambda_2=\lambda_2\int_{\lambda_2}^{1}\frac{dt}{t} β = − λ 2 ln λ 2 = λ 2 ∫ λ 2 1 t d t , recalling the value of q = exp ( − 4 e / K ) q=\exp(-4e/K) q = exp ( − 4 e / K ) and definition of A 2 A_2 A 2 in (41) , we obtain
A 2 − β = λ 2 ∫ λ 2 1 q t − 1 t d t − λ 2 ∫ λ 2 1 d t t = λ 2 ∫ λ 2 1 exp ( 4 e K ( 1 − t ) ) − 1 t d t ≥ ( i i i ) λ 2 ∫ λ 2 1 4 e K ( 1 − t ) t d t . A_2-\beta=\lambda_2\int_{\lambda_2}^{1}\frac{q^{t-1}}{t}\,dt-\lambda_2\int_{\lambda_2}^{1}\frac{dt}{t}=\lambda_2\int_{\lambda_2}^{1}\frac{\exp\left(\frac{4e}{K}(1-t)\right)-1}{t}\,dt\mathrel{\overset{(iii)}{\ge}}\lambda_2\int_{\lambda_2}^{1}\frac{\frac{4e}{K}(1-t)}{t}\,dt. A 2 − β = λ 2 ∫ λ 2 1 t q t − 1 d t − λ 2 ∫ λ 2 1 t d t = λ 2 ∫ λ 2 1 t exp ( K 4 e ( 1 − t ) ) − 1 d t ≥ ( iii ) λ 2 ∫ λ 2 1 t K 4 e ( 1 − t ) d t .
where step ( i i i ) (iii) ( iii ) uses e x − 1 ≥ x e^x-1\ge x e x − 1 ≥ x . We, thus, have A 2 − β ≥ 4 e K J ( λ 2 ) A_2-\beta\ge\frac{4e}{K}J(\lambda_2) A 2 − β ≥ K 4 e J ( λ 2 ) , where we define
J ( x ) = x ∫ x 1 1 − t t d t = − x ln x − x + x 2 . J(x)=x\int_x^1\frac{1-t}{t}\,dt=-x\ln x-x+x^2. J ( x ) = x ∫ x 1 t 1 − t d t = − x ln x − x + x 2 .
We have J ( 1 / e ) = 1 / e 2 J(1/e)=1/e^2 J ( 1/ e ) = 1/ e 2 . Furthermore, on [ 1 / e , 1 / 2 ] [1/e,1/2] [ 1/ e , 1/2 ] ,
J ′ ( x ) + 1 = − ln x − 1 + 2 x ≥ ln 2 > 0 , J'(x)+1=-\ln x-1+2x\ge\ln2>0, J ′ ( x ) + 1 = − ln x − 1 + 2 x ≥ ln 2 > 0 ,
because the derivative of the left-hand side is 2 − 1 / x ≤ 0 2-1/x\le0 2 − 1/ x ≤ 0 , so its minimum on [ 1 / e , 1 / 2 ] [1/e,1/2] [ 1/ e , 1/2 ] is attained at x = 1 / 2 x=1/2 x = 1/2 with a value of ln 2 \ln2 ln 2 .
We now recall (44) that shows λ 2 ≤ 1 e + 4 e K < 1 2 \lambda_2\le\frac{1}{e}+\frac{4}{eK}<\frac{1}{2} λ 2 ≤ e 1 + eK 4 < 2 1 for every K ≥ 39 K\ge39 K ≥ 39 . Because λ 2 ≥ 1 / e \lambda_2\ge1/e λ 2 ≥ 1/ e , we have
J ( λ 2 ) = J ( 1 / e ) + ∫ 1 / e λ 2 J ′ ( x ) d x ≥ 1 e 2 − ( 1 − ln 2 ) ( λ 2 − 1 e ) ≥ 1 e 2 − 4 ( 1 − ln 2 ) e K . J(\lambda_2)=J(1/e)+\int_{1/e}^{\lambda_2}J'(x)\,dx\ge\frac{1}{e^2}-(1-\ln2)\left(\lambda_2-\frac{1}{e}\right)\ge\frac{1}{e^2}-\frac{4(1-\ln2)}{eK}. J ( λ 2 ) = J ( 1/ e ) + ∫ 1/ e λ 2 J ′ ( x ) d x ≥ e 2 1 − ( 1 − ln 2 ) ( λ 2 − e 1 ) ≥ e 2 1 − eK 4 ( 1 − ln 2 ) .
Consequently, we have
A 2 − β ≥ 4 e K J ( λ 2 ) ≥ 4 e K − 16 ( 1 − ln 2 ) K 2 . A_2-\beta\ge\frac{4e}{K}J(\lambda_2)\ge\frac{4}{eK}-\frac{16(1-\ln2)}{K^2}. A 2 − β ≥ K 4 e J ( λ 2 ) ≥ eK 4 − K 2 16 ( 1 − ln 2 ) .
Recalling α − β = 1 K + 2 e K 2 \alpha-\beta=\frac{1}{K}+\frac{2}{eK^2} α − β = K 1 + e K 2 2 , we obtain
A 2 − α = ( A 2 − β ) − ( α − β ) ≥ 4 / e − 1 K − 16 ( 1 − ln 2 ) + 2 / e K 2 . A_2-\alpha=(A_2-\beta)-(\alpha-\beta)\ge\frac{4/e-1}{K}-\frac{16(1-\ln2)+2/e}{K^2}. A 2 − α = ( A 2 − β ) − ( α − β ) ≥ K 4/ e − 1 − K 2 16 ( 1 − ln 2 ) + 2/ e .
In particular, the right-hand side is positive for every K ≥ 39 K\ge39 K ≥ 39 .
Thus, we have proved A 1 , A 2 ≥ α A_1,A_2\ge\alpha A 1 , A 2 ≥ α . Since L ( λ 1 ) = A 1 L(\lambda_1)=A_1 L ( λ 1 ) = A 1 and θ ( λ 1 ) = 1 \theta(\lambda_1)=1 θ ( λ 1 ) = 1 , (39) holds at z = λ 1 z=\lambda_1 z = λ 1 . For λ 1 < z ≤ λ 2 \lambda_1<z\le\lambda_2 λ 1 < z ≤ λ 2 , (41) gives
L ( z ) ≥ q A 2 ≥ q α = α θ ( z ) . L(z)\ge qA_2\ge q\alpha=\alpha\theta(z). L ( z ) ≥ q A 2 ≥ q α = α θ ( z ) .
Hence (39) holds for every z ∈ [ λ 1 , λ 2 ] z\in[\lambda_1,\lambda_2] z ∈ [ λ 1 , λ 2 ] and the proof is complete. ■
Proof of Proposition 2
The lower bound follows from the algorithm used for Corollary 1: find h ∗ = arg max h ∈ [ K ] π h E [ O F F ∣ H = h ] h^*=\operatorname*{arg\,max}_{h\in[K]}\pi_h\mathbb{E}[\mathrm{OFF}\mid H=h] h ∗ = arg max h ∈ [ K ] π h E [ OFF ∣ H = h ] and use the classic prophet inequality of Samuel-Cahn [35 ] for distribution D h ∗ D_{h^*} D h ∗ . When H = h ∗ H=h^* H = h ∗ , our algorithm is 1 / 2 1/2 1/2 -competitive which yields the overall 1 / ( 2 K ) 1/(2K) 1/ ( 2 K ) -competitiveness.
Conversely, the upper bound is from a concrete construction. Fix ρ ∈ ( 0 , 1 ) \rho\in(0,1) ρ ∈ ( 0 , 1 ) and write
C ρ = ∑ ℓ = 0 K − 1 ρ ℓ , and π j = ρ j − 1 C ρ for every j ∈ [ K ] . C_\rho=\sum_{\ell=0}^{K-1}\rho^\ell,\qquad\text{and}\qquad\pi_j=\frac{\rho^{j-1}}{C_\rho}\quad\text{for every }j\in[K]. C ρ = ℓ = 0 ∑ K − 1 ρ ℓ , and π j = C ρ ρ j − 1 for every j ∈ [ K ] .
Let n = K n=K n = K . Conditional on { H = j } \{H=j\} { H = j } , let the observations be deterministic:
X t = { ρ − ( t − 1 ) , t ≤ j , 0 , t > j . (45) X_t =
\begin{cases}
\rho^{-(t-1)}, & t \le j,\\
0, & t > j.
\end{cases} \tag*{(45)} X t = { ρ − ( t − 1 ) , 0 , t ≤ j , t > j . (45)
In world j j j , the largest observation is ρ − ( j − 1 ) \rho^{-(j-1)} ρ − ( j − 1 ) , and thus,
O F F = ∑ j = 1 K ρ j − 1 C ρ ρ − ( j − 1 ) = K C ρ . (46) \mathrm{OFF}=\sum_{j=1}^{K}\frac{\rho^{j-1}}{C_\rho}\rho^{-(j-1)}=\frac{K}{C_\rho}. \tag*{(46)} OFF = j = 1 ∑ K C ρ ρ j − 1 ρ − ( j − 1 ) = C ρ K . (46)
Now take an arbitrary online algorithm A \mathcal{A} A that is potentially randomized, and let τ A \tau_{\mathcal{A}} τ A be the corresponding stopping time. Represent all its internal randomness by a seed U U U , independent of H H H , and fix a realization U = u U=u U = u . The resulting rule is deterministic and non-anticipative. Run K K K parallel instances of the algorithm with seed u u u , one for each value of H ∈ [ K ] H\in[K] H ∈ [ K ] . Let T u ∈ [ K ] ∪ { ∞ } T_u\in[K]\cup\{\infty\} T u ∈ [ K ] ∪ { ∞ } be its stopping time when run in world K K K . Indeed, this stopping time corresponds to either a time in 1 , … , K 1,\ldots,K 1 , … , K , or the algorithm never stops (if T u = ∞ T_u=\infty T u = ∞ ).
Suppose first that T u ≤ K T_u\le K T u ≤ K . The algorithm would stop at time t t t for all the runs corresponding to worlds T u , T u + 1 , … , K T_u,T_u+1,\ldots,K T u , T u + 1 , … , K , earning reward ρ − ( T u − 1 ) \rho^{-(T_u-1)} ρ − ( T u − 1 ) . This is because the algorithm observes the exact sequence of values for all those worlds. By contrast, for worlds 1 , … , T u − 1 1,\ldots,T_u-1 1 , … , T u − 1 , the algorithm rejects all positive observations, since its history through time j j j agrees with that in world K K K . All subsequent observations are zero, so its reward is zero. Hence, for a fixed seed u u u , the reward of the algorithm is ρ − ( T u − 1 ) { H ≥ T u } \rho^{-(T_u-1)}\{H\ge T_u\} ρ − ( T u − 1 ) { H ≥ T u } . Taking expectation only over H H H gives
E [ X τ A ∣ U = u ] = ρ − ( T u − 1 ) ⋅ Pr [ H ≥ T u ] = ρ − ( T u − 1 ) ⋅ ∑ j = T u K ρ j − 1 C ρ = ∑ ℓ = 0 K − T u ρ ℓ C ρ ≤ 1. (47) \mathbb{E}[X_{\tau_{\mathcal{A}}}\mid U=u]=\rho^{-(T_u-1)}\cdot\Pr[H\ge T_u]=\rho^{-(T_u-1)}\cdot\frac{\sum_{j=T_u}^{K}\rho^{j-1}}{C_\rho}=\frac{\sum_{\ell=0}^{K-T_u}\rho^\ell}{C_\rho}\le1. \tag*{(47)} E [ X τ A ∣ U = u ] = ρ − ( T u − 1 ) ⋅ Pr [ H ≥ T u ] = ρ − ( T u − 1 ) ⋅ C ρ ∑ j = T u K ρ j − 1 = C ρ ∑ ℓ = 0 K − T u ρ ℓ ≤ 1. (47)
If T u = ∞ T_u=\infty T u = ∞ , the algorithm A \mathcal{A} A passes every positive reward in every world and can receive only zero, so the same bound holds. Since the bound (47) holds for every fixed U = u U=u U = u , averaging over U U U yields
E [ X τ A ] ≤ 1. (48) \mathbb{E}[X_{\tau_{\mathcal{A}}}]\le1. \tag*{(48)} E [ X τ A ] ≤ 1. (48)
Combining (46) and (48) , we infer
r ( A ) O F F = E [ X τ A ] O F F ≤ C ρ K = 1 + ρ + ⋯ + ρ K − 1 K . \frac{r(\mathcal{A})}{\mathrm{OFF}}=\frac{\mathbb{E}[X_{\tau_{\mathcal{A}}}]}{\mathrm{OFF}}\le\frac{C_\rho}{K}=\frac{1+\rho+\cdots+\rho^{K-1}}{K}. OFF r ( A ) = OFF E [ X τ A ] ≤ K C ρ = K 1 + ρ + ⋯ + ρ K − 1 .
The right-hand side converges to 1 / K 1/K 1/ K as ρ → 0 \rho\to0 ρ → 0 . Therefore, for any η > 0 \eta>0 η > 0 , taking ρ \rho ρ sufficiently small makes the competitive ratio of any online algorithm to be it at most 1 / K + η 1/K+\eta 1/ K + η . Letting η → 0 \eta\to0 η → 0 establishes the result.
Proof of prop:gen-cr
The algorithm simply chooses one time t t t uniformly at random from { 1 , … , n } \{1,\ldots,n\} { 1 , … , n } and accepts it. With probability 1 / n 1/n 1/ n , it accepts the item with the maximum value and thus its competitive ratio is at least 1 / n 1/n 1/ n .
We now construct a hard instance in which no algorithm can obtain a better competitive ratio, even when K = 1 K=1 K = 1 . Fix some B > 1 B>1 B > 1 and let K = 1 K=1 K = 1 . Initially, X 1 = 1 X_1=1 X 1 = 1 with probability 1 1 1 . For every t < n t<n t < n , generate X t + 1 X_{t+1} X t + 1 conditionally on X t X_t X t according to
X t + 1 = { B X t , with probability 1 / B , 0 , with probability 1 − 1 / B , X_{t+1} =
\begin{cases}
BX_t, & \text{with probability } 1/B,\\
0, & \text{with probability } 1-1/B,
\end{cases} X t + 1 = { B X t , 0 , with probability 1/ B , with probability 1 − 1/ B ,
where we note that when X t = 0 X_t=0 X t = 0 for some t t t , we have X t ′ = 0 X_{t'}=0 X t ′ = 0 for all t ′ > t t'>t t ′ > t .
Notice that E [ X t + 1 ∣ F t ] = 1 B ( B X t ) = X t \mathbb{E}[X_{t+1}\mid\mathcal{F}_t]=\frac{1}{B}(BX_t)=X_t E [ X t + 1 ∣ F t ] = B 1 ( B X t ) = X t , i.e., the process is a martingale. Thus, by Doob’s optional sampling (Theorem 2), we have E [ X τ ∗ ] = O N = 1 \mathbb{E}[X_{\tau^*}]=\mathrm{ON}=1 E [ X τ ∗ ] = ON = 1 . Conversely, the prophet obtains a reward
O F F = ∑ t = 1 n − 1 B t − 1 B − ( t − 1 ) ( 1 − 1 B ) + B n − 1 B − ( n − 1 ) = ( n − 1 ) ( 1 − 1 B ) + 1 = n − n − 1 B . \begin{aligned}
\mathrm{OFF}=\sum_{t=1}^{n-1}B^{t-1}B^{-(t-1)}\left(1-\frac{1}{B}\right)+B^{n-1}B^{-(n-1)} \\
&=(n-1)\left(1-\frac{1}{B}\right)+1 \\
&=n-\frac{n-1}{B}.
\end{aligned} OFF = t = 1 ∑ n − 1 B t − 1 B − ( t − 1 ) ( 1 − B 1 ) + B n − 1 B − ( n − 1 ) = ( n − 1 ) ( 1 − B 1 ) + 1 = n − B n − 1 .
Now, taking B → ∞ B\to\infty B → ∞ establishes O N / O F F ≤ 1 / n \mathrm{ON}/\mathrm{OFF}\le1/n ON / OFF ≤ 1/ n , which is the desired result. ▪
Auxiliary lemmas
Chernoff Bound
We use the following concentration inequality of Chernoff [9 ] :
Lemma 10 (Multiplicative Chernoff bound). Suppose Y 1 , … , Y n Y_1,\ldots,Y_n Y 1 , … , Y n are independent random variables taking values in [ 0 , 1 ] [0,1] [ 0 , 1 ] and let Y ‾ = 1 n ∑ i = 1 n Y i \overline{Y}=\frac{1}{n}\sum_{i=1}^{n}Y_i Y = n 1 ∑ i = 1 n Y i . Then for every θ ∈ [ 0 , 1 ] \theta\in[0,1] θ ∈ [ 0 , 1 ] , the following bound holds
Pr [ ∣ Y ‾ − E [ Y ‾ ] ∣ > θ E [ Y ‾ ] ] ≤ 2 exp ( − θ 2 n E [ Y ‾ ] / 3 ) . \Pr\left[\left|\overline{Y}-\mathbb{E}[\overline{Y}]\right|>\theta\mathbb{E}[\overline{Y}]\right]\le2\exp\left(-\theta^2 n\mathbb{E}[\overline{Y}]/3\right). Pr [ Y − E [ Y ] > θ E [ Y ] ] ≤ 2 exp ( − θ 2 n E [ Y ] /3 ) .
Figures