1 Introduction
Prophet inequality has been a cornerstone of optimal stopping theory, since the classical result of Krengel and Sucheston [17, 18]. Consider a gambler facing a sequence of items, whose values are drawn independently from known distributions. After seeing an item, the gambler observes its realized value, and either accepts it and the game ends, or irrevocably rejects it and continues to the next item. The classical prophet inequality states that the gambler can achieve at least half of the expected maximum value. The latter is referred to as a prophet, who knows the realization of all values beforehand. Furthermore, the ratio of half is proven to be the best possible in the worst case. Later, SamuelCahn [21] showed that the competitive ratio^{1}^{1}1We choose to use the terminology competitive ratio, due to the online nature of prophet inequality. of can be achieved using a singlethreshold algorithm.
In the past fifteen years, there has been an increased interest of prophet inequality related problems in the algorithmic game theory and online algorithms literature, due to its close connection to mechanism design and posted pricing mechanisms
[14]. Among the fruitful extensions of the classical prophet inequality, a remarkable line of research focuses on surpassing the impossibility result by relaxing the worst case model. Consider the following three variants in progressive order of difficulty.I.I.D. Model.
Hill and Kertz [15] studied the case when the value distributions are identical and designed a competitive algorithm. They also constructed a family of instance showing that no algorithm can be better than competitive^{2}^{2}2The constant is the unique solution to .. The ratio is improved to by Abolhassan et al. [1]. Recently, Correa et al. [8] designed an optimal competitive algorithm, matching the hardness of Hill and Kertz.
Order Selection Model.
In this variant, the gambler is given an extra power for selecting the arrival order of each item. This assumption is natural in the application of sequential posted pricing mechanisms [6], as the mechanism designer plays the role of the gambler. Chawla et al. [6] proposed an competitive algorithm and the ratio is later improved to by Beyhaghi et al. [4]. This variant subsumes the i.i.d. model as a special case. Indeed, when the value distributions are identical, the extra power of order selection is useless. Very recently, Agrawal, Sethuraman and Zhang [2] established a negative result, showing that the task of selecting the optimal order is NPhard, even when the support of each distribution is of size . They also provide a competitive algorithm when the support of each distribution is of size at most .
Random Order Model.
This variant is also known as prophet secretary, in which items arrive in a random order. This model can be viewed as a generalization of the i.i.d. model and is no easier than the order selection model. Esfandiari et al. [12] initiated the study of this variant and designed a competitive algorithm. Later, the same ratio is achieved using different strategies, including using personalized but timeinvariant thresholds [8], and a singlethreshold algorithm with randomized tiebreaking [11]. Later, the ratio is improved to by Azar, Chiplunkar, and Kaplan [3] and to by Correa, Saona, and Ziliotto [10]. The latter work also establishes a hardness of , showing a separation between the random order model and the i.i.d. model.
1.1 Our Contributions.
In this work, we focus on the order selection model. Despite the NPhardness of selecting the optimal order, we strongly exploit the power of order selection and design a competitive algorithm, that substantially improve the stateoftheart ratio from the random order model. As a side result, our algorithm is competitive for the i.i.d. prophet inequality.
Previous Approaches.
We briefly summarize the previous techniques. Naturally, an algorithm is consisted of two parts: selecting the order and setting the thresholds. Each step is easy to optimize on its own. Specifically, when the arrival order is fixed, the optimal thresholds can be calculated through backward induction; when the thresholds are fixed for each item, we can calculate the expected value of each item conditioning on that its value exceeds the threshold, and then set the arrival order to be a descending order of the calculated values.
Chawla et al. [6] and Beyhaghi et al. [4] applied a twostep approach of first designing the thresholds, and then selecting the order. Both works studied the order selection prophet inequality from the perspective of sequential posted pricing mechanisms. It is implicitly shown by Chawla et al. [6] that the latter setting reduces to the first setting.
The line of work studying prophet secretary [12, 3, 10]
can be viewed as a twostep approach of first selecting the order, and then designing the thresholds. More accurately, the algorithm selects the uniform distribution over all permutations and then focuses on designing the thresholds. Remarkably, prior to our work, the stateoftheart
ratio for the order selection prophet inequality is established in the random order setting by Correa, Saona, and Ziliotto [10].Our Perspective: Arrival Time Design.
Recall a folklore continuous formulation of the prophet secretary problem. Let the time horizon be and assume that each item arrives at time (i.e., the uniform distribution over ). This formulation is equivalent to the random arrival order and often eases the analysis. Specifically, under this formulation, Correa, Saona and Ziliotto [10] carefully set timedependent thresholds and accept the first item whose value exceeds the threshold on its arrival time.
We provide a novel point of view by rescaling the time horizon. We first fix the timedependent thresholds. Specifically, at time , we set the threshold to be the value
so that the maximum value of all items is larger than it with probability exactly
. Then, we design an arrival time distribution for each item and let the items arrive at a random time with respect to . In principle, this formulation is without loss of generality, since we can choose the distributions to be deterministic. Under this formulation, we only need to optimize for the arrival times. Moreover, the continuous formulation allows us to adapt the analysis framework from the i.i.d. setting [8] and the random order setting [10]. Noticeably, if the distributions are identical, our algorithm can be implemented in the prophet secretary setting. See Section 2 for a more detailed discussion.Our Results.
We explicitly construct arrival time distributions and achieve a competitive ratio of , where is the unique solution^{3}^{3}3For completeness, we provide a proof of the uniqueness of in Appendix B. to .
Furthermore, our algorithm serves as an alternative optimal competitive algorithm for the i.i.d. setting, with only one parameter modified, compared to our algorithm in the order selection setting. Our unified analysis bridges the i.i.d. setting and the order selection setting, and suggests that our novel arrival time design perspective to be the right framework.
1.2 Related Work
There is a vast literature on prophet inequalities. We refer interested readers to the survey of Hill and Kertz [16] for the classical results, the suvery of Lucier [20] for the economic perspective of prophet inequalities, and the survey of Correa et al. [7] for more recent developments. Below, we review the most related works.
Hajiaghayi et al. [14], and Chawla et al. [6] observed a close relation between prophet inequalities and sequential posted pricing. They showed that designing posted pricing mechanisms can be reduced to the prophet inequality problem. Recently, Correa et al. [9] proved that the two settings are indeed equivalent.
Besides the results that we have discussed before, there are a few special cases in which better competitive ratios are known for the order selection prophet inequality problem. When the number of items is a small constant, Beyhaghi et al. [4] obtained a better competitive ratio than their general bound of . If each type of distribution occurs at least times, Abolhassani et al. [1] improved the competitive ratio to for the order selection model. Liu et al. [19] relaxed the problem by allowing the algorithm to remove a constant number of items. After so, they showed that the competitive ratio can be arbitrary close to against the relaxed prophet.
Closely related to the order selection prophet inequality is the optimal ordering problem. This problem shares the same input model as the order selection prophet inequality, while the benchmark is changed to the optimal online algorithm instead of the expected maximum value. Agrawal, Sethuraman and Zhang [2] proved that the problem is NPhard, and designed a FPTAS when the support of each distribution is of size . Fu et al. [13] gave a PTAS when each distribution has a constant support size. Chakraborty et al. [5] obtained a PTAS without any assumption on the support of the distribution. Their original results were stated in the setting of sequential posted pricing mechanisms, that can be translated to the optimal ordering problem by the reduction of Correa et al. [9]. Liu et al. [19] improved the results to an EPTAS based on a novel decomposition technique.
2 Preliminaries
Let there be items, whose values are drawn independently from known distributions . The algorithm first selects an arrival order of the items. Then, the items arrive in a sequence according to the selected order. Upon the arrival of an item, its value is realized and the algorithm either accepts the item and stops, or rejects the item and continues to the next. Our goal is to maximize the expected value of the selected item and compare against the prophet
For the ease of presentation, we assume the value distributions ’s are continuous distributions. The extension to discrete distributions can be implemented by a careful tiebreaking rule. We refer to [10] for a detailed explanation.
Our algorithm is parameterized by distributions for each , supported on . Consider the following algorithm:
Independent Arrival Time ().

Sample independently for each . We refer to as the arrival time of item .

Let the items arrive in ascending order according to their arrival times.

We accept the first item with , where is the threshold that
Remark.
Before we go to the detailed analysis of our algorithm, it is worthwhile to make a comparison with the algorithm by Correa, Saona, and Ziliotto [10] for the prophet secretary problem. In the prophet secretary problem (and other online optimization problems with random arrival), a folklore formulation is to assume that each item arrives at time (i.e., the uniform distribution over ). Correa, Saona, and Ziliotto first set timedependent thresholds at time , with an appropriate function , and then accept the first item whose value exceeds the threshold.
Alternatively, we rescale the time horizon by fixing the threshold to be at time , and then let the items arrive according to carefully chosen distributions. Indeed, if all the distributions ’s are identical, our algorithm can be implemented in the prophet secretary setting. Specifically, for any function , by setting for every item , our algorithm is equivalent to the algorithm of Correa, Saona, and Ziliotto [10]. On the other hand, our formulation admits a natural generalization to the order selection setting by allowing nonidentical ’s.
Analysis.
Our analysis is similar to the framework of [10]. We abuse ALG to denote our algorithm and to denote the (random) value of the accepted item of our algorithm. We show the competitive ratio of our algorithm through the following stronger statement.
Lemma 2.1.
For the order selection prophet inequality, there exists distributions , so that for every :
where and is the unique solution to .
Observe that for any nonnegative random variable
, we have . The above lemma immediately concludes the competitive ratio of our algorithm.Theorem 2.1.
The independent arrival time algorithm with functions chosen in Lemma 2.1 is competitive for the order selection prophet inequality. I.e., .
As a side result, for the i.i.d. prophet inequality, i.e., when the distributions are identical, our construction in Lemma 2.1 works with a different parameter . Thus, we give an alternative optimal competitive algorithm for the i.i.d. prophet inequality. Formally, we prove the following lemma and theorem.
Lemma 2.2.
For the i.i.d. prophet inequality, there exists distributions , so that for every :
where is the unique solution to .
Theorem 2.2.
The independent arrival time algorithm with functions chosen in Lemma 2.2 is competitive for the i.i.d. prophet inequality. I.e., .
3 Analysis
In this section, we prove Lemma 2.1 and 2.2. We first provide the construction of the distributions in Section 3.1, and then prove the stated inequality of Lemma 2.1 and 2.2 in Section 3.2.
Without specifying the constant and assuming that our distributions are welldefined, our constructions and analysis are unified for the noni.i.d. case and the i.i.d. case.
Finally, in Section 3.3, we find the largest possible constants for our algorithm to be welldefined for the noni.i.d. case and the i.i.d. case, respectively.
3.1 Construction of
We explicitly construct the distributions
by defining their probability density functions. We first introduce some notations. For every
and , letWith the assumption that the value distributions are continuous, we have that are nondecreasing continuous functions. Hence, they are differentiable almost everywhere and we will use to denote the derivatives. We have the following simple observation according to the definition of :
(1)  
(2) 
By taking derivatives on both sides of (1), we have
(3) 
Consider equation (1) when , we have . Hence, there exists at least one index with . Without loss of generality, let it be the index . Consequently, for all .
Now, we define the distributions as the following.
Construction of .

Let be an auxiliary function.

For every item , let be the probability density function for its arrival time and let with probability .
Remark.
We use almost the same construction for the noni.i.d. case and the i.i.d. case, except for a different choice of the constant . We shall specify the choice of later when it becomes crucial.
We need to be careful when multiple items arrive at time , since the distributions ’s might have point masses on according to our construction. We resolve this issue by doing a special treatment for item : 1) if for , we reject item without looking at its realized value; 2) if , we accept it without looking at its realized value. Recall that , there is no difference between always accepting item and setting a threshold of to item .
Intuition.
The construction might look mysterious at the first glance, with the complicated formulas. Indeed, our construction is driven by the analysis and is derived after solving a set of differential equations. We provide an informal argument in Appendix A to provide intuitions how we derive the above distributions. For readers who are familiar with the analysis framework of Correa, Saona, and Ziliotto [10], it would be helpful to check the informal argument before verifying the correctness of our proof. For other readers, we also encourage reading the informal argument after going through the full analysis. Nevertheless, our formal proof below is selfcontained.
We first prove two useful mathematical properties of the functions and .
Lemma 3.1.
The functions satisfy that

, ;

, .
Proof.
We verify the first equation by plugging in the definition of to the left hand side:
Next, we prove the second statement. We first calculate the derivative of function :
(4) 
Then, by applying the first stated equation, we have:
∎
3.2 Competitive Analysis
For our algorithm to be welldefined, we need to verify that the distributions are valid, i.e. for all . This is the crucial place where we have different constants for the noni.i.d. case and i.i.d. case respectively.
Lemma 3.2.
For the i.i.d. case, for (the unique solution to ), and for each , we have
For the noni.i.d. case, we prove the following stronger statement that automatically implies the validity of our algorithm.
Lemma 3.3.
For the noni.i.d. case, for where is the unique solution to , and for each , we have
We defer the proofs of the above lemmas to the next subsection and continue proving the stated inequality of Lemma 2.1 and 2.2, assuming the validity of our algorithm.
Fixing an arbitrary time , the event that our algorithm accepts an item with value larger than belongs to one of the following possibilities:

Our algorithm stops before time . In this case, the accepted value must be larger than , since the threshold function is decreasing.

For some , our algorithms accepts item at time and .
We introduce notations for each to denote the following events:

: item arrives at time and .

: item is accepted by our algorithm at time and .
Lemma 3.4.
For any , .
Proof.
Observe that our algorithm stops before time if and only if at least one of the events happens. Moreover, the events are independent from each other for different ’s. Consequently,
where the last equation follows from the second statement of Lemma 3.1. ∎
Next, we study the events .
Lemma 3.5.
For any and , .
Proof.
For any , fixing the arrival time of and conditioning on that its realized value is larger than , our algorithm accepts it as long as we haven’t stopped before time . Specifically, the last event happens when none of the happens. Thus,
(by Lemma 3.1)  
(by the definition of )  
For , we conclude the proof of the statement by noticing that . However, not necessarily equals . We remark that for the i.i.d. case, all distributions are symmetric and the above analysis is sufficient since for all . The rest of our proof is only for the noni.i.d. case.
Note that the above analysis ignores the point mass of on and recall that we have a special treatment of item when it arrives at time . It suffices to calculate the extra probability when item is accepted at time and .
Here, the third equality follows from the fact that ; the last inequality follows from Lemma 3.3. This concludes the proof of the lemma. ∎
3.3 Calculation of
Finally, we prove Lemma 3.2 and 3.3. Recall the definition of . We have that
Since is continuous and nondecreasing, we do the following change of variables: for ,

;

and .
Then,
Remark.
If is strictly monotonically increasing, our definition of is the standard inverse function of . The above change of variables works for arbitrary absolute continuous nondecreasing function . Indeed, for any Lebesgue measurable function and ,
where the first equation follows from the fact that the Lebesgue measure of equals .
3.3.1 I.I.D.: Proof of Lemma 3.2
We start with the case of i.i.d. distributions. Within this subsection, is the unique solution to . By symmetry, all functions are the same. Since , we have that for all
Consequently, we have
and  
(since are the same for all )  
We have the following mathematical fact, whose proof involves tedious calculations that we defer to Appendix B.
Claim 3.1.
For any , we have
Applying the above claim and recalling that , we have that
(let )  
where the last equality follows from the definition of .
3.3.2 NonI.I.D.: Proof of Lemma 3.3
Finally, we derive the constant for the noni.i.d. case. In contrast to the analysis for the i.i.d. case, we no longer have explicit expressions for functions . The challenge is to prove that for all possible , the stated inequality holds. Within this subsection, and is the unique solution of the following equation on
We first observe the following property regarding functions and .
Claim 3.2.
For each , we have
(5) 
Proof.
For notation simplicity, let . Since , we have that . Then,
Here, the third equality holds since for all ; the inequality holds since for all . ∎
Observe that functions are only defined on . We further extend the two functions by defining and for . It is straightforward to verify that the extended functions satisfy (5) for all . This condition is the only property that we are going to use for functions and . Specifically, we prove the following technical lemma.
Lemma 3.6.
Suppose functions satisfies that
Then