Page 1

arXiv:1112.1136v1 [cs.DS] 6 Dec 2011

Secretary Problems with Convex Costs

Siddharth BarmanSeeun Umboh

David Malec

Shuchi Chawla

University of Wisconsin–Madison

{sid, seeun, shuchi, dmalec}@cs.wisc.edu

Abstract

We consider online resource allocation problems where given a set of requests our goal is to select

a subset that maximizes a value minus cost type of objective function. Requests are presented online

in random order, and each request possesses an adversarial value and an adversarial size. The online

algorithm must make an irrevocable accept/reject decision as soon as it sees each request. The “profit”

of a set of accepted requests is its total value minus a convex cost function of its total size. This problem

falls within the framework of secretary problems. Unlike previous work in that area, one of the main

challenges we face is that the objective function can be positive or negative and we must guard against

accepting requests that look good early on but cause the solution to have an arbitrarily large cost as more

requests are accepted. This requires designing new techniques.

We study this problem under various feasibility constraints and present online algorithms with com-

petitive ratios only a constant factor worse than those known in the absence of costs for the same feasi-

bility constraints. We also consider a multi-dimensional version of the problem that generalizes multi-

dimensional knapsack within a secretary framework. In the absence of any feasibility constraints, we

presentanO(ℓ) competitivealgorithmwhereℓis thenumberofdimensions; thismatcheswithinconstant

factors the best known ratio for multi-dimensional knapsack secretary.

1 Introduction

We study online resource allocation problems under a natural profit objective: a single server accepts or

rejects requests for service so as to maximize the total value of the accepted requests minus the cost imposed

by them on the system. This model captures, for example, the optimization problem faced by a cloud

computing service accepting jobs, a wireless access point accepting connections from mobile nodes, or an

advertiser in a sponsored search auction deciding which keywords to bid on. In many of these settings, the

server must make accept or reject decisions in an online fashion as soon as requests are received without

knowledge of the quality future requests. We design online algorithms with the goal of achieving a small

competitive ratio—ratio of the algorithm’s performance to that of the best possible (offline optimal) solution.

A classical example of online decision making is the secretary problem. Here a company is interested in

hiring a candidate for a single position; candidates arrive for interview in random order, and the company

must accept or reject each candidate following the interview. The goal is to select the best candidate as

often as possible. What makes the problem challenging is that each interview merely reveals the rank of the

candidate relative to the ones seen previously, but not the ones following. Nevertheless, Dynkin [11] showed

that it is possible to succeed with constant probability using the following algorithm: unconditionally reject

the first 1/e fraction of the candidates; then hire the next candidate that is better than all of the ones seen

1

Page 2

previously. Dynkin showed that as the number of candidates goes to infinity, this algorithm hires the best

candidate with probability approaching 1/e and in fact this is the best possible.

More general resource allocation settings may allow picking multiple candidates subject to a certain

feasibility constraint. We call such a problem a generalized secretary problem (GSP) and use (Φ,F) to

denote an instance of the problem. Here F denotes a feasibility constraint that the set of accepted requests

must satisfy (e.g. the size of the set cannot exceed a given bound), and Φ denotes an objective function

that we wish to maximize. As in the classical setting, we assume that requests arrive in random order; the

feasibility constraint F is known in advance but the quality of each request, in particular its contribution

to Φ, is only revealed when the request arrives. Recent work has explored variants of the GSP where Φ

is the sum over the accepted requests of the “value” of each request. For such a sum-of-values objective,

constant factor competitive ratios are known for various kinds of feasibility constraints including cardinality

constraints [17, 19], knapsack constraints [4], and certain matroid constraints [5].

In many settings, the linear sum-of-values objective does not adequately capture the tradeoffs that the

server faces in accepting or rejecting a request, and feasibility constraints provide only a rough approxima-

tion. Consider, for example, a wireless access point accepting connections. Each accepted request improves

resource utilization and brings value to the access point. However as the number of accepted requests grows

the access point performs greater multiplexing of the spectrum, and must use more and more transmitting

power in order to maintain a reasonable connection bandwidth for each request. The power consumption

and its associated cost are non-linear functions of the total load on the access point. This directly translates

into a value minus cost type of objective function where the cost is an increasing function of the load or total

size of all the requests accepted.

Our goal then is to accept a set A out of a universe U of requests such that the “profit” π(A) = v(A) −

C(s(A)) is maximized; here v(A) is the total value of all requests in A, s(A) is the total size, and C is a

known increasing convex cost function1.

Note that when the cost function takes on only the values 0 and ∞ it captures a knapsack constraint,

and therefore the problem (π,2U) (i.e. where the feasibility constraint is trivial) is a generalization of the

knapsack secretary problem [4]. We further consider objectives that generalize the ℓ-dimensional knapsack

secretary problem. Here, we are given ℓ different (known) convex cost functions Cifor 1 ≤ i ≤ ℓ, and

each request is endowed with ℓ sizes, one for each dimension. The profit of a set is given by π(A) =

v(A) −?ℓ

costs, we obtain online algorithms with competitive ratios within a constant factor of those achievable for a

sum-of-values objective with the same feasibility constraints. For ℓ-dimensional costs, in the absence of any

constraints, we obtain an O(ℓ) competitive ratio. We remark that this is essentially the best approximation

achievable even in the offline setting: Dean et al. [9] show an Ω(ℓ1−ǫ)hardness for the simpler ℓ-dimensional

knapsack problem under a standard complexity-theoretic assumption. For the multi-dimensional problem

with general feasibility constraints, our competitive ratios are worse by a factor of O(ℓ5) over the corre-

sponding versions without costs. Improving this factor is a possible avenue for future research.

We remark that the profit function π is a submodular function. Recently several works [13, 6, 16] have

looked at secretary problems with submodular objective functions and developed constant competitive algo-

rithms. However, all of these works make the crucial assumption that the objective is always nonnegative;

it therefore does not capture π as a special case. In particular, if Φ is a monotone increasing submodular

function (that is, if adding more elements to the solution cannot decrease its objective value), then to obtain

i=1Ci(si(A)) where si(A) is the total size of the set in dimension i.

Weconsider theprofitmaximization problem under various feasibility constraints. Forsingle-dimensional

1Convexity is crucial in obtaining any non-trivial competitive ratio—if the cost function were concave, the only solutions with

a nonnegative objective function value may be to accept everything or nothing.

2

Page 3

a good competitive ratio it suffices to show that the online solution captures a good fraction of the optimal

solution. In the case of [6] and [16], the objective function is not necessarily monotone. Nevertheless,

nonnegativity implies that the universe of elements can be divided into two parts, over each of which the

objective essentially behaves like a monotone submodular function in the sense that adding extra elements

to a good subset of the optimal solution does not decrease its objective function value. In our setting, in

contrast, adding elements with too large a size to the solution can cause the cost of the solution to become

too large and therefore imply a negative profit, even if the rest of the elements are good in terms of their

value-size tradeoff. As a consequence we can only guarantee good profit when no “bad” elements are added

to the solution, and must ensure that this holds with constant probability. This necessitates designing new

techniques.

Our techniques.

classify elements as “good” or“bad” based onathreshold on their value tosize ratio (a.k.a. density) such that

any large enough subset of the good elements provides a good approximation to profit; the optimal threshold

is defined according to the offline optimal fractional solution. Our algorithm learns an estimate of this

threshold from the first few elements (that we call the sample) and accepts all the elements in the remaining

stream that cross the threshold. Learning the threshold from the sample is challenging. First, following the

intuition about avoiding all bad elements, our estimate must be conservative, i.e. exceed the true threshold,

with constant probability. Second, the optimal threshold for the sample can differ significantly from the

optimal threshold for the entire stream and is therefore not a good candidate for our estimate. Our key

observation is that the optimal profit over the sample is a much better behaved random variable and is, in

particular, sufficiently concentrated; we use this observation to carefully pick an estimate for the density

threshold.

With general feasibility constraints, it is no longer sufficient to merely classify elements as good and

bad: an arbitrary feasible subset of the good elements is not necessarily a good approximation. Instead, we

decompose the profit function into two parts, each of which can be optimized by maximizing a certain sum-

of-values function (see Section 4). This suggests a reduction from our problem to two different instances

of the GSP with sum-of-values objectives. The catch is that the new objectives are not necessarily non-

negative and so previous approaches for the GSP don’t work directly. We show that if the decomposition of

the profit function is done with respect to a good density threshold and an extra filtering step is applied to

weed out bad elements, then the two new objectives on the remaining elements are always non-negative and

admit good solutions. At this point we can employ previous work on GSP with a sum-of-values objective

to obtain a good approximation to one or the other component of profit. We note that while the exposition

in Section 4 focuses on a matroid feasibility constraint, the results of that section extend to any downwards-

closed feasibility constraint that admits good offline and online algorithms with a sum-of-values objective2.

In the multi-dimensional setting (discussed in Section 5), elements have different sizes along different

dimensions. Therefore, a single density does not capture the value-size tradeoff that an element offers.

Instead we can decompose the value of an element into ℓ different values, one for each dimension, and

define densities in each dimension accordingly. This decomposes the profit across dimensions as well.

Then, at a loss of a factor of ℓ, we can approximate the profit objective along the “best” dimension. The

problem with this approach is that a solution that is good (or even best) in one dimension may in fact be

terrible with respect to the overall profit, if its profit along other dimensions is negative. Surprisingly we

show that it is possible to partition values across dimensions in such a way that there is a single ordering over

In the absence of feasibility constraints (see Section 3), we note that it is possible to

2We obtain an O(α4β) competitive algorithm where α is the best offline approximation and β is the best online competitive

ratio for the sum-of-values objective.

3

Page 4

elements in terms of their value-size tradeoff that is respected in each dimension; this allows us to prove that

a solution that is good in one dimension is also good in other dimensions. We present an O(ℓ) competitive

algorithm for the unconstrained setting based on this approach in Section 5, and defer a discussion of the

constrained setting to Section 6.

Related work.

survey. Recently a number of papers have explored variants of the GSP with a sum-of-values objective.

Hajiaghayi et al. [17] considered the variant where up to k secretaries can be selected (a.k.a. the k-secretary

problem) in a game-theoretic setting and gave a strategyproof constant-competitive mechanism. Klein-

berg [19] later showed an improved 1 − O(1/√k) competitive algorithm for the classical setting. Babaioff

et al. [4] generalized this to a setting where different candidates have different sizes and the total size of the

selected set must be bounded by a given amount, and gave a constant factor approximation. In [5] Babaioff

et al. considered another generalization of the k-secretary problem to matroid feasibility constraints. A

matroid is a set system over U that is downwards closed (that is, subsets of feasible sets are feasible), and

satisfies a certain exchange property (see [21] for a comprehensive treatment). They presented an O(logr)

competitive algorithm, where r is the rank of the matroid, or the size of a maximal feasible set. This was

subsequently improved to a O(√logr)-competitive algorithm by Chakraborty and Lachish [7]. Several pa-

pers have improved upon the competitive ratio for special classes of matroids [1, 10, 20]. Bateni et al. [6]

and Gupta et al. [16] were the first to (independently) consider non-linear objectives in this context. They

gave online algorithms for non-monotone nonnegative submodular objective functions with competitive ra-

tios within constant factors of the ratios known for the sum-of-values objective under the same feasibility

constraint. Other versions of the problem that have been studied recently include: settings where elements

are drawn from known or unknown distributions but arrive in an adversarial order [8, 18, 22], versions where

values are permuted randomly across elements of a non-symmetric set system [24], and settings where the

algorithm is allowed to reverse some of its decisions at a cost [2, 3].

The classical secretary problem has been studied extensively; see [14, 15] and [23] for a

2 Notation and Preliminaries

We consider instances of the generalized secretary problem represented by the pair (π,F), and an implicit

number n of requests or elements that arrive in an online fashion. U denotes the universe of elements.

F ⊂ 2Uis a known downwards-closed feasibility constraint. Our goal is to accept a subset of elements

A ⊂ U with A ∈ F such that the objective function π(A) is maximized. For a given set T ⊂ U, we use

O∗(T) = argmaxA∈F∩2T π(A) to denote the optimal solution over T; O∗is used as shorthand for O∗(U).

We now describe the function π.

In the single-dimensional cost setting, each element e ∈ U is endowed with a value v(e) and a size

s(e). Values and sizes are integral and are a priori unknown. The size and value functions extend to sets

of elements as s(A) =?

following quantities will be useful in our analysis:

e∈As(e) and v(A) =?

e∈Av(e). Then the “profit” of a subset is given by

π(A) = v(A) − C(s(A)) where C is a non-decreasing convex function on size: C : Z+→ Z+. The

• The density of an element, ρ(e) := v(e)/s(e). We assume without loss of generality that densities of

elements are unique and denote the unique element with density γ by eγ.

• The marginal cost function, c(s) := C(s) − C(s − 1). Note that this is an increasing function.

4

Page 5

• The inverse marginal cost function, ¯ s(ρ) which is defined to be the maximum size for which an

element of density ρ will have a non-negative profit increment, that is, the maximum s for which

ρ ≥ c(s).

• The density prefix for a given density γ and a set T, PT

density prefix,¯PT

γ := {e ∈ T : ρ(e) ≥ γ}, and the partial

γand¯PU

γ:= PT

γ\ {eγ}. We use Pγand¯Pγas shorthand for PU

γrespectively.

We will sometimes find it useful to discuss fractional relaxations of the offline problem of maximizing

π subject to F. To this end, we extend the definition of subsets of U to allow for fractional membership.

We use αe to denote an α-fraction of element e; this has value v(αe) = αv(e) and size s(αe) = αs(e). We

say that a fractional subset A is feasible if its support supp(A) is feasible. Note that when the feasibility

constraint can be expressed as a set of linear constraints, this relaxation is more restrictive than the natural

linear relaxation.

Note that since costs are a convex non-decreasing function of size, it may at times be more profitable

to accept a fraction of an element rather than the whole. That is, argmaxαπ(αe) may be strictly less than

1. For such elements, ρ(e) < c(s(e)). We use F to denote the set of all such elements: F = {e ∈ U :

argmaxαπ(αe) < 1}, and I = U \ F to denote the remaining elements. Our solutions will generally

approximate the optimal profit from F by running Dynkin’s algorithm for the classical secretary problem;

most of our analysis will focus on I. Let F∗(T) denote the optimal (feasible) fractional subset of T ∩ I for

a given set T. Then π(F∗(T)) ≥ π(O∗(T ∩ I)). We use F∗as shorthand for F∗(U), and let s∗be the size

of this solution.

In the multi-dimensional setting each element has an ℓ-dimensional size s(e) = (s1(e),...,sℓ(e)). The

cost function is composed of ℓ different non-decreasing convex functions, Ci: Z+→ Z+. The cost of a set

of elements is defined to be C(A) =?

iCi(si(A)) and the profit of A, as before, is its value minus its cost:

π(A) = v(A) − C(A).

2.1Balanced Sampling

Our algorithms learn the distribution of element values and sizes by observing the first few elements. Be-

cause of the random order of arrival, these elements form a random subset of the universe U. The following

concentration result is useful in formalizing the representativeness of the sample.

Lemma 2.1. Given constant c ≥ 3 and a set of elements I with associated non-negative weights, wifor

i ∈ I, say we construct a random subset J by including each element of I uniformly at random with

probability 1/2. If for all k ∈ I, wk≤1

least 0.76:

c

?

?

i∈Iwithen the following inequality holds with probability at

j∈J

wj≥ β(c)

?

i∈I

wi,

where β(c) is a non-decreasing function of c (and furthermore is independent of I).

We begin the proof of Lemma 2.1 with a restatement of Lemma 1 from [12] since it plays a crucial role

in our argument. Note that we choose a different parameterization than they do, since in our setting the

balance between approximation ratio and probability of success is different.

Lemma 2.2. Let Xi, for i ≥ 1, be indicator random variables for a sequence of independent, fair coin flips.

Then, for Si=?i

5

k=1Xk, we have Pr[∀i, Si≥ ⌊i/3⌋] ≥ 0.76.

Page 6

We now proceed to prove Lemma 2.1. While we do not give a closed form for the approximation factor

β(c) in the statement of the lemma, we define it implicitly as

β(c) = max

0<y<1

?

y

2 + y

??

1 −

2

c(1 − y)

?

,

and give explicit values in Table 1 for particular values of c that we invoke the lemma with.

Proof of Lemma 2.1. Our general approach will be to separate our set of weights I into a “good” set G and

a “bad” set B. At a high level, Lemma 2.2 guarantees us that at worst, we will accept a weight every third

time we flip a coin. So the good case is when weights do not decrease too quickly; this intuition guides our

definitions of G and B.

Let y ∈ (0,1) be a lower bound on “acceptable” rates of decrease; we tune the exact value later.

Throughout, we use w(S), w(S), and w(S) to denote the total, minimum, and maximum weights of a

set S. We form G and B as follows.

Initialize B = ∅ and i = 1. Consider I in order of decreasing weight. While I ?= ∅, we repeat the

following. Let P be the largest prefix such that w(P) ≥ y · w(P). If |P| ≤ 2, move P from I to B, i.e.

set B := B ∪ P and I := I \ P. Otherwise, |P| ≥ 3 and we define Gito be the 3 largest elements of P;

remove them from I (i.e. set I := I \ Gi); and increment i by 1. Once we are done, we define G = ∪iGi.

First, we show that the total weight in B cannot be too large. Note that we add at most 2 elements at

a time to B; and when we do add elements, we know that all remaining elements in I (and hence all later

additions to B) are smaller by more than a factor of y. Thus, we can see that

w(B) ≤

?

i≥0

2yi· w(B) ≤2w(B)

1 − y

≤

2w(I)

c(1 − y),

by our assumption that no individual weight is more than w(I)/c.

Next, we show that with probability at least 0.76, we can lower bound the fraction of weight we keep

from G. Consider applying Lemma 2.2, flipping coins first for the weights in G in order by decreasing

weight. Note that by the time we finish flipping coins for Gi, we must have added at least i weights to J;

hence the ithweight we add to J must have value at least w(Gi). On the other hand, we know that

w(Gi) ≤ 2w(Gi) + w(Gi) ≤

?2

y+ 1

?

w(Gi),

and so summing over i we can see that elements we accept have total weight w(J) ≥ (

Combining our bounds for the weights of G and B, we can see that with probability 0.76 the elements

we accept have weight

y

2+y)w(G).

w(J) ≥

?

y

2 + y

?

w(G) =

?

y

2 + y

?

(w(I) − w(B)) ≥

?

y

2 + y

??

1 −

2

c(1 − y)

?

w(I);

optimizing the above with respect to y for a fixed c gives the claimed result. Note that for each fixed

y ∈ (0,1) our approximation factor is increasing in c, and so the optimal value β(c) must be increasing in c

as well.

6

Page 7

c given

111

15/2

8

y chosen

0.84

0.46

.47

β(c) achieved

≈ 0.262

≈ 0.094

≈ 0.100

Figure 1: Some specific values of approximation ratio achieved by Lemma 2.1.

3Unconstrained Profit Maximization

We begin by developing an algorithm for the unconstrained version of the generalized secretary problem

with F = 2U, which already exhibits some of the challenges of the general setting. Note that this setting

captures as a special case the knapsack secretary problem of [4] where the goal is to maximize the total value

of a subset of size at most a given bound. In fact in the offline setting, the generalized secretary problem

is very similar to the knapsack problem. If all elements have the same (unit) size, then the optimal offline

algorithm orders elements in decreasing order of value and picks the largest prefix in which each element

contributes a positive marginal profit. When element sizes are different, a similar approach works: we order

elements by density this time, and note that either a prefix of this ordering or a single element is a good

approximation (much like the greedy 2-approximation for knapsack).

Algorithm 1 Offline algorithm for single-dimensional (π,2U)

1: Initialize set I ← {a ∈ U | ρ(a) ≥ c(s(a))}

2: Initialize selected set A ← ∅

3: Sort I in decreasing order of density.

4: for i ∈ I do

5:

if marginal profit for the ith element, πA(i) ≥ 0 then

6:

A ← A ∪ {i}

7:

else

8:

Exit loop.

9:

end if

10: end for

11: Set m := argmax{a∈U}π(a) {the most profitable element}

12: if π(m) > π(A) then

13:

Output set {m}

14: else

15:

Output set A

16: end if

Precisely, we show that |O∗∩ F| ≤ 1, and we can therefore focus on approximating π over the set I.

Furthermore, let A(U) denote the greedy subset obtained by Algorithm 1, which considers elements in I

in decreasing order of density and picks the largest prefix where every element has nonnegative marginal

profit. The following lemma implies that one of A(U) or the single best element is a 3-approximation to

O∗.

Lemma 3.1. We have that π(O∗) ≤ π(F∗) + maxe∈Uπ(e) ≤ π(A(U)) + 2maxe∈Uπ(e). Therefore the

greedy offline algorithm (Algorithm 1) achieves a 3-approximation for (π,2U).

7

Page 8

Proof. We first show that O∗has at most one element from F. For contradiction, assume that O∗contains

at least two elements f1,f2∈ F. Since densities are unique, without loss of generality, we assume ρ(f1) >

ρ(f2).

Recall that F is precisely the set of elements for which it is optimal to accept a strictly fractional amount.

Let α1,α2< 1 be the optimal fractions for f1and f2, i.e. argmaxαπ(αf1) = α1and argmaxαπ(αf2) =

α2. Then adding a fractional amount of any element with density at most ρ(f1) to {α1f1} results in strictly

decreased profit. But this implies π(O∗) < π(O∗\ {f2}), contradicting the optimality of O∗.

Let f be the unique element in O∗∩ F. By subadditivity, we get that π(O∗\ {f}) + π(f) ≥ π(O∗).

Since O∗\ {f} ⊆ I, we have π(F∗) ≥ π(O∗\ {f}). In the rest of the proof we focus on approximating

π(F∗).

Note that F∗is a fractional density prefix of I. So let F∗= Pρ– ∪ {αe}, for some e and α < 1. The

subadditivity of π implies π(F∗) ≤ π(Pρ–) + π({αe}). Note that Algorithm 1 selects A = Pρ–, and that

π({αe}) ≤ π(e) since e ∈ I.

Hence, combining the above inequalities we get π(A) + π(e) + π(f) ≥ π(O∗). This in turn proves the

required claim.

The offline greedy algorithm suggests an online solution as well. In the case where a single element

gives a good approximation, we can use the classical secretary algorithm to get a good competitive ratio.

In the other case, in order to get good competitive ratio, we merely need to estimate the smallest density,

say ρ–, in the prefix of elements that the offline greedy algorithm picks, and then accept every element that

exceeds this threshold.

We pick an estimate for ρ–by observing the first few elements of the stream U. Note that it is important

for our estimate of ρ–to be no smaller than ρ–. In particular, if there are many elements with density just

below ρ–, and our algorithm uses a density threshold less than ρ–, then the algorithm may be fooled into

mostly picking elements with density below ρ–(since elements arrive in random order), while the optimal

solution picks elements with densities far exceeding ρ–. We now describe how to pick an overestimate of

ρ–which is not too conservative, that is, such that there is still sufficient profit in elements whose densities

exceed the estimate.

In the remainder of this section, we assume that every element has profit at most

appropriate constant k1, to be defined later. (If this does not hold, the classical secretary algorithm obtains

an expected profit of at least

1

k1+1π(O∗) for an

1

e(k1+1)π(O∗)). Then Lemma 3.1 implies π(F∗) ≥

k1π(F∗), and π(A(U)) ≥

We divide the stream U into two parts X and Y , where X is a random subset of U. Our algorithm

unconditionally rejects elements in X and extracts a density threshold τ from this set. Over the remaining

stream Y , it accepts an element if and only if its density is at least τ and if it brings in strictly positive

marginal profit. Under the assumption of small element profits we can apply Lemma 2.1 to show that

π(X∩A(U)) is concentrated and is alarge enough fraction of π(O∗). This implies that withhigh probability

π(X ∩ A(U)) (which is a prefix of A(X)) is a significant fraction of π(A(X)). Therefore we attempt to

identify X ∩ A(U) by looking at profits of prefixes of X.

We will need the following lemma about A().

Lemma 3.2. For any set S, consider subsets A1,A2⊆ A(S). If A1⊇ A2, then π(A1) ≥ π(A2). In other

words, π is monotone-increasing when restricted to A(S) for all S ⊂ U.

Proof. We observe that the fractional greedy algorithm sorts its input S by decreasing order of density, and

A(S) consists of the top |A(S)| elements under that ordering. Since F∗(S) contains each element in A(S)

?

1 −

1

(k1+1)

?

π(O∗),

maxe∈Uπ(e) ≤

1

?

1 −

1

k1

?

π(F∗).

8

Page 9

Algorithm 2 Online algorithm for single-dimensional (π,2U)

1: With probability 1/2 run the classic secretary algorithm to pick the single most profitable element else

execute the following steps.

2: Draw k from Binomial(n,1/2).

3: Select the first k elements to be in the sample X. Unconditionally reject these elements.

4: Letτ be largest density such that π(PX

τ) ≥ β

later.

5: Initialize selected set O ← ∅.

6: for i ∈ Y = U \ X do

7:

if π(O ∪ {i}) − π(O) ≥ 0 and ρ(i) ≥ τ and i / ∈ F then

8:

O ← O ∪ {i}

9:

else

10:

Exit loop.

11:

end if

12: end for

?

1 −1

k1

?

π(F∗(X)) forconstants β and k1tobe specified

in its entirety, we can see that F∗(B) = B for any subset B of A(S). So for A2⊆ A1⊆ A(S), we have that

F∗(A2) = A2⊆ A1= F∗(A1); by the optimality of F∗, this implies that π(A2) ≤ π(A1) as claimed.

We define two good events. E1asserts that X ∩ A(U) has high enough profit. Our final output is the

set PY

density prefix, say Pρ–, and so X ∩ A(U) = PX

E1: π(PX

ρ– ) > β π(Pρ–)

τ. E2asserts that the profit of PY

τis a large enough fraction of the profit of Pτ. Recall that A(U) is a

ρ– . We define the event E1as follows.

where β is a constant to be specified later. Conditioned on E1, we have π(PX

β (1 − 1/k1)π(F∗(X)). Note that threshold τ, as selected by Algorithm 2, is the largest density such that

π(PX

ρ– ) > β (1 − 1/k1)π(F∗) ≥

τ) ≥ β (1 − 1/k1)π(F∗(X)). Therefore, E1implies τ ≥ ρ–, and we have the following lemma.

Lemma 3.3. Conditioned on E1, O = Pτ∩ Y ⊆ A(U).

On the other hand, PX

τ ⊆ Pτ⊂ A(U) along with Lemma 3.2 implies

π(Pτ) ≥ π(PX

where the second inequality is by the definition of τ, the third by optimality and the last is obtained by

applying E1and A(U) ≥ (1 − 1/k1)F∗.

We define ρ+to be the largest density such that π(Pρ+) ≥ β2?

implies Pρ+ ⊆ Pτand the following lemma.

Lemma 3.4. Event E1implies O ⊇ Y ∩ Pρ+.

Based on the above lemma, we define event E2for an appropriate constant β′as follows

τ) ≥ β (1 − 1/k1)π(F∗(X)) ≥ β (1 − 1/k1)π(PX

ρ– ) ≥ β2(1 − 1/k1)2π(F∗)

1 −

1

k1

?2π(F∗). Then ρ+≥ τ, which

E2: π(PY

ρ+) ≥ β′π(Pρ+).

Conditioned on events E1and E2, and using Lemma 3.2 again, we get

π(O) ≥ π(PY

ρ+) ≥ β′β2(1 − 1/k1)2π(F∗).

To wrap up the analysis, we show that E1and E2are high probability events.

9

Page 10

Lemma 3.5. If no element of U has profit more than

and β′= 0.094.

1

113π(O∗), then Pr[E1∧ E2] ≥ 0.52, where β = 0.262

Proof. We show that Pr[E1],Pr[E2] ≥ 0.76; the desired inequality Pr[E1 ∧ E2] ≥ 0.52 then follows by

the union bound.

In the following, we assume the elements are sorted in decreasing order of density. Denote the profit

increment of the ithelement by ˜ π(i) = π(P(i)) − π(P(i−1)); this extends naturally to sets A ⊆ A(U) by

setting ˜ π(A) =?

We apply Lemma 2.1 with Pρ– as the fixed set I and PX

in Lemma 2.1 correspond to profit increments of the elements. Note that Pρ– = A(U); so we know both

that elements in Pρ– have non-negative profit increments, and π(Pρ–) ≥ π(O∗) − 2maxe∈Uπ(e). Hence

if no element has profit exceeding a 1/113-fraction of π(O∗), we get that any element ei∈ Pρ– has profit

increment ˜ π(i) ≤ π(ei) ≤ 1/(113 − 2)π(Pρ–) = 1/111˜ π(Pρ–). Hence we can apply Lemma 2.1 to get

˜ π(PX

0.76.

By our definition of ρ+, the profit of Pρ+ is at least β2(1−1/k1)2(1−1/(k1+1))π(O∗); substituting in

the specified values of β and k1give us that no element in Pρ+ has profit increment more than 2/15 ˜ π(Pρ+).

Thus, applying Lemma 2.1 implies Pr[E2] ≥ 0.76 with β′= 0.094.

Putting everything together we get the following theorem.

i∈A˜ π(i). By the subadditivity of π, we have π(A) ≥ ˜ π(A) for all A ⊆ A(U), with

equality at A(U).

ρ– = U∩Pρ– as the the random set J. The weights

ρ– ) ≥ 0.262˜ π(Pρ–) with probability at least 0.76, and so the event E1holds with probability at least

Theorem 3.6. Algorithm 2 achieves a competitive ratio of 616 for (π,2U) using k1= 112 and β = 0.262.

Proof. If there exists an element with profit at least

gives a competitive ratio of

E[π(O) | E1∧E2]Pr[E1∧E2] ≥ 0.52β′β2(1−1/k1)2π(F∗) ≥ 0.52β′β2(1−1/k1)2(1 − 1/(k1+ 1))π(O∗) ≥

1

307π(O∗). Since we flip a fair coin to decide whether to output the result of running the classical secretary

algorithm, or output the set O, weachieve a2max{308,307} = 616-approximation to π(O∗) in expectation

(over the coin flip).

1

113π(O∗(U)), the classical secretary algorithm (Step 1)

308. Otherwise, using Lemma 3.5, with β′= 0.094, we have E[π(O)] ≥

1

113e≥

1

4Matroid-Constrained Profit Maximization

Wenow extend the algorithm of Section 3 to the setting (π,F) where F is a matroid constraint. In particular,

F is the set of all independent sets of a matroid over U. We skip a precise definition of matroids and will

only use the following facts: F is a downward closed feasibility constraint and there exist an exact offline

and an O(√logr) online algorithm for (Φ,F), where Φ is a sum-of-values objective and r is the rank of the

matroid.

Inthe unconstrained setting, weshowed that there always exists either adensity prefix orasingle element

with near-optimal profit. So in the online setting it sufficed to determine the density threshold for a good

prefix. In constrained settings this is no longer true, and we need to develop new techniques. Our approach

is to develop a general reduction from the π objective to two different sum-of-values type objectives over

the same feasibility constraint. This allows us to employ previous work on the (Φ,F) setting; we lose only

a constant factor in the competitive ratio. We will first describe the reduction in the offline setting and then

extend it to the online algorithm using techniques from Section 3.

10

Page 11

Decomposition of π.

hγ(A) :=?

function as π(A) = hγ(A)+gγ(A). In particular π(O∗) = hγ(O∗)+gγ(O∗). Our goal will be to optimize

the two parts separately and then return the better of them.

Note that the function hγis a sum of values function where the value of an element is defined to be

(ρ(e) − γ)s(e). Its maximizer is a subset of Pγ, the set of elements with nonnegative shifted density

ρ(e) − γ. In order to ensure that the maximizer, say A, of hγalso obtains good profit, we must ensure that

gγ(A) is nonnegative, and therefore π(A) ≥ hγ(A). This is guaranteed for a set A as long as s(A) ≤ ¯ s(γ).

Likewise, the function gγincreases as a function of size s as long as s is at most ¯ s(γ), and decreases

thereafter. Therefore, in order to maximize gγ, we merely need to find the largest (in terms of size) feasible

subset of size no more than ¯ s(γ). As before, if we can ensure that for such a subset hγis nonnegative (e.g.

if the set is a subset of Pγ), then the profit of the set is no smaller than its gγvalue. This motivates the

following definition of “bounded” subsets:

For a given density γ, we define the shifted density function hγ() over sets as

e∈A(ρ(e) − γ)s(e) and the fixed density function gγ() over sizes as gγ(s) := γs − C(s).

For a set A we use gγ(A) to denote gγ(s(A)). It is immediate that for any density γ we can split the profit

Definition 4.1. Given a density γ a subset A ⊆ U is said to be γ-bounded if A ⊆ Pγand s(A) ≤ ¯ s(γ).

We begin by formally proving that the function gγincreases as a function of size s as long as s is at most

¯ s(γ).

Lemma 4.1. If density γ and sizes s and t satisfy s ≤ t ≤ ¯ s(γ), then gγ(s) ≤ gγ(t).

Proof. Since C(·) is convex, we have that its marginal, c(), is monotonically non-decreasing. Thus we get

the following chain of inequalities,

C(t) − C(s) =

t

?

z=s+1

c(z) ≤ (t − s) × c(t) ≤ (t − s)γ.

The last inequality follows from the assumption that t is no more than¯ s(γ) and hence c(t) ≤ γ. Bydefinition

of gγ() we get the desired claim.

Proposition 4.2. For any γ-bounded set A, π(A) ≥ hγ(A) and π(A) ≥ gγ(A).

Proof. Since π(A) = hγ(A) + gγ(A), it is sufficient to prove that hγ(A) and gγ(A) are both non-negative.

The former is clearly non-negative since all elements of A have density at least γ. Lemma 4.1 implies that

the latter is non-negative by taking t = s(A) and s = 0.

For a density γ and set T we define HT

γand GT

γas follows. (We write Hγfor HU

γand Gγfor GU

γ.)

HT

γ= argmax

H∈F,H⊂PT

γ

hγ(H)GT

γ= argmax

G∈F,G⊂¯PT

γ

s(G)

Following our observations above, both Hγand Gγcan be determined efficiently (in the offline setting)

using standard matroid maximization. However, we must ensure that the two sets are γ-bounded. Further,

in order to compare the performance of Gγagainst O∗, we must ensure that its size is at least a constant

fraction of the size of O∗. We now show that there exists a density γ for which Hγand Gγsatisfy these

properties.

Once again, we focus on the case where no single element has high enough profit by itself. Recall that

F∗denotes F∗(I), s∗denotes the size of this set and¯Pγdenotes Pγ\{eγ}. Before we proceed we need the

following fact about the fractional optimal subset F∗.

11

Page 12

Lemma 4.3. If F∗has an element of density γ then s∗is at most¯ s(γ).

Proof. The proof is by contradiction. Say s∗is more than ¯ s(γ). Recall that eγdenotes the element with

density γ. We show that in such conditions reducing the fractional contribution of eγ, say by ǫ, increases

profit giving us a better fractional solution. This is turn contradicts the optimality of F∗.

Write s = s(eγ) and note that

π(F∗) = v(F∗) − C(s∗)

= [(v(F∗) − γ × ǫs) − C(s∗− ǫs)] − [C(s∗) − C(s∗− ǫs) − γ × ǫs].

If ǫ is such that s∗− ǫ > ¯ s(γ), then we have C(s∗) − C(s∗− ǫs) > γ × ǫs; thus we get that the term

[C(s∗) − C(s∗− ǫs) − γ × ǫs] is positive which proves the claim.

Definition 4.2. Let ρ–be the largest density such that Pρ– has a feasible set of size at least s∗.

We now state a useful property of ρ–.

Lemma 4.4. Any feasible set in¯Pρ– is ρ–-bounded and has size less than s∗. Moreover for any density

γ > ρ–all feasible subsets of Pγare γ-bounded.

Proof. By definition, the size of any feasible set contained in Pρ– \ {eρ–} is no more than s∗.

We will show that s∗≤ ¯ s(ρ–). Then the first part of the lemma follows immediately. For the second

part we have γ > ρ–and hence ¯ s(ρ–) ≤ ¯ s(γ). Overall a size bound of s∗also implies that feasible sets in

Pγsatisfy the size requirement for being γ-bounded. Hence we get that all feasible sets in Pρ– \ {eρ–} are

ρ–-bounded and all feasible sets in Pγare γ-bounded.

The size of F∗is at most the size of its support. Thus the support of F∗is a feasible set of size at least

s∗. By definition, ρ–is the largest density such that Pρ– contains a feasible set of size s∗. Hence we get that

F∗contains an element of density less than or equal to ρ–. Applying Lemma 4.3 we get s∗≤ ¯ s(ρ–) and the

lemma follows.

The following is our main claim of this section.

Lemma 4.5. For any density γ > ρ–, π(O∗(¯Pγ)) ≤ π(Hγ) + π(Gγ). Furthermore, π(O∗) ≤ π(Hρ–) +

π(Gρ–) + 2maxe∈Uπ(e).

Proof. Let P, H, and G denote Pρ–, Hρ–, and Gρ– respectively. As in the unconstrained setting, there can be

at most one element in the intersection of O∗and F (see proof of Lemma 3.1). Note that π() is subadditive,

hence π(O∗∩ I) + maxe∈Uπ(e) ≥ π(O∗). In the analysis below we do not consider elements present in F

and show that π(H) + π(G) + maxe∈Uπ(e) ≥ π(O∗∩ I). This in turn establishes the second part of the

Lemma.

For ease of notation we denote eρ– as e′. Without loss of generality, we can assume that H does not

contain e′since ρ(e′) − ρ–= 0. Therefore set H is contained in P \ {e′}. By Lemma 4.4 we get that H is

ρ–-bounded.

Note that by definition Gdoes not contain e′, hence itssize isat mosts∗. Also, G∪{e′} isno smaller than

the maximum-size feasible subset contained in P. So, by definition of ρ–, we also have s(G) + s(e′) ≥ s∗.

Thus there exists α < 1 such that the fractional set F = G ∪ {αe′} has size exactly equal to s∗.

Next we split the profit of F∗into two parts, and bound the first by hρ–(H) and the second by gρ–(F):

π(F∗) = hρ–(F∗) + gρ–(s∗) ≤ hρ–(H) + gρ–(F).

12

Page 13

Note that we can drop elements which have a negative contribution to the sum to get

hρ–(F∗) ≤ hρ–(F∗∩ Pρ–)

≤ hρ– (supp(F∗) ∩ Pρ–)

≤ hρ–(H)

≤ π(H).

The second inequality follows since we can only increase the value of a subset by “rounding up” fractional

elements. The third inequality follows from the optimality of H, and the fourth from the fact that it is

ρ–-bounded.

To bound the second part we note that s(F) = s∗, hence gρ–(F) = ρ–s∗− C(s∗). Elements in F have

density no less than ρ–and its size is bounded above by ¯ s(ρ–), hence it is a ρ–-bounded set implying that

π(F) ≥ gρ–(F). Note that F = G ∪ {αe′}, and by sub-additivity of π() we have π(G) + π(αe′) ≥ π(F).

Moreover e′∈ I implies π(αe′) ≤ π(e′) and hence we get

π(F∗) ≤ π(H) + gγ(F) ≤ π(H) + π(G) + π(e′),

which proves the second half of the lemma.

Thefirsthalf ofthelemmafollows along similar lines. Wehave thestandard decomposition, π(O∗(¯Pγ)) =

hγ(O∗(¯Pγ))+gγ(O∗(¯Pγ)). Bydefinition, Hγistheconstrained maximizer ofhγ, hence wegethγ(O∗(¯Pγ)) ≤

hγ(Hγ). We note that all feasible sets in Pγare γ-bounded, for density γ > ρ–(Lemma 4.4). Hence, by

Lemma 4.1, gγstrictly increases with size when restricted to feasible sets in¯Pγ. Gγis the largest such set,

hence we get gγ(Gγ) ≥ gγ(O∗(¯Pγ)). Hγand Gγare γ-bounded and hence by Proposition 4.2 we have

π(Hγ) ≥ hγ(Hγ) and π(Gγ) ≥ gγ(Gγ). This establishes the lemma.

This lemma immediately gives us an offline approximation algorithm for (π,F): for every element

density γ, we find the sets Hγand Gγ; we then output the best (in terms of profit) of these sets or the best

individual element. We obtain the following theorem:

Theorem 4.6. Algorithm 3 4-approximates (π,F) in the offline setting.

Algorithm 3 Offline algorithm for single-dimensional (π,F)

1: Set Amax← argmaxH∈{Hγ}γπ(H)

2: Set Bmax← argmaxG∈{Gγ}γπ(G)

3: Set emax← argmaxe∈Uπ(e)

4: Assign A(U) ← argmaxS∈{Amax,Bmax,emax}π(S)

The online setting.

an estimate τ for the density ρ–. Then with equal probability it applies the online algorithm for (hτ,F) on

the remaining set Y ∩Pτor the online algorithm for (s,F) (in order to maximize gτ) on Y ∩Pτ. Lemma 4.5

indicates that it should suffice for τ to be larger than ρ–while ensuring that π(O∗(Pτ)) is large enough. Asin

Section 3 we define the density ρ+as the upper limit on τ, and claim that τ satisfies the required properties

with high probability.

Our online algorithm, as in the unconstrained case, uses a sample X from U to obtain

13

Page 14

Algorithm 4 Online algorithm for single-dimensional (π,F)

1: Draw k from Binomial(n,1/2).

2: Select the first k elements to be in the sample X. Unconditionally reject these elements.

3: Toss a fair coin.

4: if Heads then

5:

Set output O as the first element, over the remaining stream, with profit higher than maxe∈Xπ(e).

6: else

7:

Determine A(X) using the offline Algorithm 3.

8:

Let β be a specified constant and let τ be the highest density such that π(A(PX

9:

Toss a fair coin.

10:

if Heads then

11:

Let O1be the result of executing an online algorithm for (hτ,F) on the subset PY

stream with the objective function

τ)) ≥

β

16π(A(X)).

τof the remaining

hτ(A) =

?

e∈A

(ρ(e) − τ)s(e)

12:

13:

14:

15:

16:

17:

18:

19:

20:

Set O ← ∅.

for e ∈ O1do

if π(O ∪ {e}) − π(O) ≥ 0 then

Set O ← O ∪ {e}.

end if

end for

Output O.

else

Let O2be the result of executing an online algorithm for F on the subset PY

stream with objective function s().

Set O ← ∅.

for e ∈ O2do

if π(O ∪ {e}) − π(O) ≥ 0 then

Set O ← O ∪ {e}.

end if

end for

Output O.

end if

29: end if

τ of the remaining

21:

22:

23:

24:

25:

26:

27:

28:

14

Page 15

Note that we use an algorithm for (Φ,F) where Φ is a sum-of-values objective in Algorithm 4 as a

black box. Forexample if the underlying feasibility constraint is a partition matroid weexecute the partition-

matroid secretary algorithm in steps 11 and 20 as subroutines. Since these subroutines are online algorithms,

we can execute steps 11 and 20 in parallel with the respective ‘for’ loops in steps 13 and 22. This ensures

that all accepted elements have positive profit increment.

Definition4.3. Forafixedparameter β ≤ 1, letρ+bethehighest density withπ(O∗(Pρ+)) ≥ (β/16)2π(O∗).

Lemma 4.7. For fixed parameters k1≥ 1, k2≤ 1, β ≤ 1 and β′≤ 1 suppose that there is no element with

profit more than

that π(A(PX

Proof. We first define two events analogous to the events E1and E2in Section 3.

1

k1π(O∗). Then with probability at least k2, we have that if τ is the highest density such

τ)) ≥

β

16π(A(X)), then τ satisfies ρ+≥ τ ≥ ρ–and π(O∗(PY

τ)) ≥ β′(β/16)2π(O∗).

E1: π(O∗(PX

E2: π(O∗(PY

ρ– )) ≥ βπ(O∗(Pρ–))

ρ+)) ≥ β′π(O∗(Pρ+))

We claim that the event E1immediately implies ρ+≥ τ ≥ ρ–. Furthermore, when ρ+≥ τ ≥ ρ–, we

get the containment PY

combined with event E2and the definition of ρ+, proves the second condition. We furthermore claim that

E1and E2simultaneously hold with probability at least k2, which would give the desired result.

Thus, we are done if we demonstrate that event E1implies ρ+≥ τ ≥ ρ–, and that the probability of E1

and E2occurring simultaneously is at least k2; we now proceed to prove each of these claims in turn.

ρ+ ⊂ PY

τ ⊂ PY

ρ–, which implies π(O∗(PY

τ)) ≥ π(O∗(PY

ρ+)). This inequality, when

Claim 1. Event E1implies that ρ+≥ τ and so PY

Proof. First, by containment and optimality, we observe that

ρ+⊂ PY

τ.

π(O∗(Pτ)) ≥ π(O∗(PX

β

16π(A(X)). Furthermore,

π(A(X)) ≥1

τ)) ≥ π(A(PX

τ)).

By definition of τ, we have π(A(PX

τ)) ≥

4π(O∗(X)) ≥1

4π(O∗(PX

ρ– )).

Lemma 4.5 gives us π(O∗(Pρ–)) ≥1

4π(O∗). This together with event E1implies

π(O∗(PX

ρ– )) ≥ βπ(O∗(Pρ–)) ≥β

4π(O∗).

Thus, we have that π(O∗(Pτ)) ≥

previous profit inequality holds. Hence we conclude that ρ+≥ τ.

Claim 2. Event E1implies that τ ≥ ρ–.

Proof. Asstated before, Lemma4.5gives usπ(O∗(Pρ–)) ≥1

Now, E1implies that

?

β

16

?2π(O∗). We have defined ρ+to be the largest density for which the

4π(O∗). Wehave thatπ(A(PX

ρ– )) ≥1

4π(O∗(PX

ρ– )).

π(O∗(PX

ρ– )) ≥ βπ(O∗(Pρ–)) ≥β

4π(O∗).

15

Page 16

Combining these we get that

π(A(PX

ρ– )) ≥β

16π(O∗) ≥β

16π(A(X)).

Since τ is the largest density for which the above inequality holds we have τ ≥ ρ–.

Claim 3. For a fixed constant k1, if no element of S has profit more than

1

k1π(O∗) then Pr[E1∧E2] ≥ 0.52.

Proof. The proof of this claim is similar to that of Lemma 3.5. We show that Pr[E1] ≥ 0.76 and Pr[E2] ≥

0.76; the result then follows by applying the union bound. We begin by observing that π(O∗(PX

π(O∗(Pρ–) ∩ X), and so it suffices to bound the probability that π(O∗(Pρ–) ∩ X) ≥ βπ(O∗(Pρ–)) and

likewise the probability that π(O∗(Pρ+) ∩ Y ) ≥ β′π(O∗(Pρ+)).

We fix an ordering over elements of O∗(Pρ–), such that the profit increments are non-increasing. That

is, if Liis the set containing elements 1 through i and hence the profit increment of the ith element is

˜ π(i) := π(Li) − π(Li−1), then we have ˜ π(1) ≥ ˜ π(2) ≥ .... Note that such an ordering can be determined

by greedily picking elements from O∗(Pρ–) such that the profit increment at each step is maximized.

We set k1≥ 24, now the fact that no element in S has profit more than

itself has profit more than 1/8 π(O∗(Pρ–)), since π(O∗(Pρ–)) ≥ 1/3π(O∗). Profit increments of elements

are upper bounded by their profits, therefore we can apply Lemma 2.1 with O∗(Pρ–) as the fixed set and

profit increments as the weights. By optimality of O∗(Pρ–) we have that these profit increments are non-

negative hence the required conditions of Lemma 2.1 hold and we have π(O∗(Pρ–) ∩ X) ≥ βπ(O∗(Pρ–))

with probability at least 0.76. Since π(O∗(PX

ρ– )) ≥

1

24π(O∗) implies no element by

ρ– )) ≥ π(O∗(Pρ–)∩X) we get Pr[E1] ≥ 0.76 with β = 1/10.

?

By definition of ρ+the profit of O∗(Pρ+) is at least

can again apply Lemma 2.1 to show that Pr[E2] ≥ 0.76. Hence we can set k2= 0.52 and this completes

the proof of the claim.

β

9

?2π(O∗). With k1≥ 8

?

9

β

?2

and β′= 1/10 we

With the demonstration that the above three claims hold, our proof is complete.

Toconclude the analysis, we show that if the online algorithms for (hτ,F) and (s,F) have acompetitive

ratio of α, then we obtain an O(α) approximation to π(O∗(PY

τ)). We therefore get the following theorem.

Theorem 4.8. If there exists an α-competitive algorithm for the matroid secretary problem (Φ,F) where Φ

is a sum-of-values objective, then Algorithm 4 achieves a competitive ratio of O(α) for the problem (π,F).

Before we proceed to prove Theorem 4.8, we show that in steps 9 to 27 the algorithm obtains a good

approximation to O∗(PY

τ).

Lemma 4.9. Suppose that there is an α-competitive algorithm for (Φ,F) where Φ is any sum-of-values ob-

jective. For a fixed set Y and threshold τ, satisfying τ ≥ ρ–, we have Eσ[π(O1)+π(O2)] ≥ α π(O∗(PY

where the expectation is over all permutations σ of Y .

τ)),

Proof. The threshold τ is either equal to or strictly greater than ρ–. In the former case eρ– must have been

in the sample set X and hence O1,O2⊆¯Pρ–. By Lemma 4.4 we show that O1and O2are ρ–-bounded and

hence τ-bounded. On the other hand if τ > ρ–we can again apply Lemma 4.4 and get that O1and O2are

τ-bounded.

Hence byProposition 4.2weget theinequalities Eσ[π(O1)] ≥ Eσ[hτ(O1)]and Eσ[π(O2)] ≥ Eσ[gτ(O2)].

16

Page 17

By applying the α-competitive matroid secretary algorithm with objective hτ(Step 11 of Algorithm 4 )

we get

Eσ[hτ(O1)] ≥ α × hτ(HY

≥ α × hτ(O∗(PY

τ)

τ)),

where the second inequality follows from the optimality of HY

Next we bound Eσ[gτ(O2)]. Let K be the largest feasible subset contained in PY

underlying algorithm is α-competitive implies Eσ[s(O2)] ≥ α × s(K).

Note that, as observed above, PY

So, for O2we have

τ.

τ. The fact that the

τ ⊂¯Pρ–. Since K ⊂ PY

τ, by definition of ρ–we get that s(K) ≤ s∗.

Eσ[gτ(O2)] ≥ Eσ[τs(O2) − C(s(O2)]

≥ Eσ

?s(O2)

≥ α(τs(K) − C(s(K)))

= α gτ(K)

≥ α gτ(O∗(PY

τ)) ≤ s(K) ≤ s∗≤ ¯ s(τ) we get the last inequality by applying Lemma 4.1.

The conclusion of the lemma now follows from the decomposition π(O∗(PY

gτ(O∗(PY

?

τ

?s(O2)

s(K)

?

?

s(K) −

?s(O2)

s(K)

?

C(s(K))

?

= Eσ

s(K)

(τs(K) − C(s(K)))

τ)).

Since s(O∗(PY

τ)) = hτ(O∗(PY

τ)) +

τ)).

Proof of Theorem 4.8. With probability1

If an element has profit more than

We have Pr[E1∧ E2] ≥ k2, for a fixed constant k2. Also, the events E1and E2depend only on

what elements are in X and Y , and not on their ordering in the stream. So conditioned on E1and E2, the

remaining stream is still a uniformly random permutation of Y . Therefore, if no element has profit more

than

output O1and O2with probability1

2we apply the standard secretary algorithm which is e-competitive.

k1π(O∗), in expectation we get a profit of

1

1

2k1etimes the optimal.

1

k1π(O∗) we can apply the second inequality of Lemma 4.7 and Lemma 4.9 along with the fact that we

4each, to show that

E[π(O)] ≥1

4E[π(O1) + π(O2) | E1∧ E2] × Pr[E1∧ E2]

≥αk2

4

≥αk2β′

4 16

E[π(O∗(PY

τ)) | E1∧ E2]

?β

?2

π(O∗).

Overall, we have that

E[π(O)] ≥ min

?

αk2β′

4

?β

16

?2

,

1

2k1e

?

· π(O∗).

Since all the involved parameters are fixed constants we get the desired result.

17

Page 18

5Multi-dimensional Profit Maximization

In this section, we consider the GSP with a multi-dimensional profit objective. Recall that in this setting

each element e has ℓ different sizes s1(e),...,sℓ(e), and the cost of a subset is defined by ℓ different convex

functions C1,...,Cℓ. The profit function is defined as π(A) = v(A) −?

argmaxαπ(αe) < 1}. We first claim that, as before, an optimal solution cannot contain too many ele-

ments of F.

iCi(si(A)).

As in the single-dimensional setting, we partition U into two sets I and F with F = {e ∈ U :

Lemma 5.1. We have that |O∗∩ F| ≤ ℓ.

Proof. Suppose, towards a contradiction, that |O∗∩ F| ≥ ℓ + 1. For i ∈ {1,...,ℓ}, let mibe any element

in O∗with si(mi) = maxe∈O∗ si(e). Since |O∗∩ F| ≥ ℓ + 1, there exists o ∈ (O∗∩ F) \ {m1,...,mℓ}

such that si(o) ≤ si(O∗\ {o}) for all i. This implies that when we compare the marginal cost of adding

another copy of o to {o} against the marginal cost of adding o to O∗\ {o}, we have by convexity

?

Therefore, we have π(O∗) − π(O∗\ {o}) ≤ π(o + o) − π(o) < 0 since o ∈ F, and this contradicts the

optimality of O∗.

i

Ci(si(o + o)) − Ci(si(o)) ≤

?

i

Ci(si(O∗)) − Ci(si(O∗\ {o})).

We therefore focus on approximating π over I and devote this section to the unconstrained problem (π,2U).

The main challenge of this setting is that we cannot summarize the value-size tradeoff that an element

provides by a single density because the element can be quite large in one dimension and very small in

another. Our high level approach is to distribute the value of each element across the ℓ dimensions, thereby

defining densities and decomposing profit across dimensions appropriately. We do this in such a way that

a maximizer of the ith dimensional profit for some dimension i gives us a good overall solution (albeit at a

cost of a factor of ℓ).

Formally, let ρ : U → Rℓdenote an ℓ-dimensional vector function ρ(e) = (ρ1(e),...,ρℓ(e)) that

satisfies?

Given this observation, it is natural to try to obtain an approximation to π by solving for F∗

rounding the best one. This does not immediately work: even if πi(F∗

ative because of the profit of the set being negative in other dimensions. We will now describe an approach

for defining and finding density vectors such that the best set F∗

O∗(I). We first define a quantity Πi(γi) which bounds the ith dimensional profit that can be obtained by any

set with elements of ith density at most γi: Πi(γi) = maxt(γit−Ci(t)). We can bound πi(F∗

Lemma 5.2. For a given density γj, let A = {a ∈ F∗

Proof. Subadditivity implies πj(F∗

we have πj(F∗

iρi(e)si(e) = v(e) for all e. We set vi(e) = ρi(e)si(e) and πi(A) = vi(A) − Ci(si(A)) and

note that π(A) =?

iπi(A). Let F∗

idenote the maximizer of πiover I. Then, π(F∗) ≤?

iπi(F∗

ifor all i and

i) could be neg-

i).

i) is very large, π(F∗

iindeed gives an O(ℓ) approximation to

i) using Πi(·).

j: ρj(a) ≥ γj}. Then πj(F∗

j\A). Since the elements e in F∗

j) ≤ πj(A) + Πj(γj).

j\Ahave ρj(e) ≤ γj,

j) ≤ πj(A)+πj(F∗

j\ A) ≤ maxtγjt − Cj(t) = Πj(γj).

In order to obtain a uniform bound on the profits πj(F∗

a vector ρ(e) proper if it satisfies the following properties:

j), we restrict density vectors as follows. We call

(P1)

?

iρi(e)si(e) = v(e)

(P2) Πi(ρi(e)) = Πj(ρj(e)) for all i,j ∈ [1,ℓ]; we denote this quantity by Π(e).

18

Page 19

The following lemma is proved in Section 5.1.

Lemma 5.3. For every element e, a unique proper density vector exists and can be found in polynomial

time.

Finally, we note that proper density vectors induce a single ordering over elements. In particular, since

the Πis are monotone, ρi(e) ≥ ρi(e′) if and only if Π(e) ≥ Π(e′). We order the elements e1,...,enin

decreasing order of Π. Note that each F∗

prefix. Let A = {e1,...,ek1} denote the integral part of F∗

element if it exists).

First, we need the following fact about F∗

monotone when restricted to subsets of F∗

iis a (fractional) prefix of this sequence. Let F∗

1and e′= ek1+1(i.e., F∗

1be the shortest

1’s unique fractional

1. It implies that the multidimensional profit function π is

1.

Lemma 5.4. Consider subsets A1,A2⊂ F∗

πi(A) for all i if A ⊂ F∗

Proof. For any i, we have F∗

Lemma 3.2 to πi(·) implies that πi(A1) ≥ πi(A2) ≥ 0. By summing, we have π(A1) ≥ π(A2), and also

that π(A1) ≥ πi(A1). Setting A1as A gives us the second claim.

We get the following lemma by noting that π1(F∗

1. If A1⊃ A2, then π(A1) ≥ π(A2). Furthermore, π(A) ≥

1.

1⊂ F∗

i. Since F∗

iis the fractional prefix that optimizes πi(·), applying

1) ≥ Π1(e′).

Lemma 5.5. For proper ρ(e)s and A and e′as defined above, for every i, πi(F∗

2π(F∗

i) ≤ πi(A) + π1(F∗

1) ≤

1). Furthermore, π(F∗) ≤ ℓ(π(A) + π(e′)).

Proof. We begin by proving that π1(F∗

ci(si(F∗

its profit. Together with Claim 4.3, we have ¯ si(e′) ≤ si(F∗

fact that ρ′

1) ≥ Π1(e′). Let ρ′

i= mina∈F∗

iρi(a). We observe that ρi(e′) ≤

i))since otherwise, wecould have included anadditional fractional amount of e′to F∗

iand increased

i) ≤ ¯ si(ρ′

i). Thus, applying Claim 4.1 and the

i≥ ρi(e′), we have

Πi(e′) = ρi(e′)¯ si(e′) − Ci(¯ si(e′)) ≤ ρ′

i¯ si(e′) − Ci(¯ si(e′)) ≤ ρ′

isi(F∗

i) − Ci(si(F∗

i)).

Since F∗

This proves that π1(F∗

Since ρ is proper, we have Πi(e′) = Π1(e′). Recall that e′is not in A, the integral subset of F∗

have Πi(e′) = Π1(e′) ≤ π1(F∗

πi(F∗

iis ρ′

i-bounded in the ith dimension, we have πi(F∗

1) ≥ Π1(e′).

i) ≥ ρ′

isi(F∗

i)−Ci(si(F∗

i)) by Proposition 4.2.

1, so we

1). Together with Lemma 5.2, this gives us

i) ≤ πi(A) + π1(F∗

1).

(1)

Now, Lemma 5.4 gives us π(F∗

as claimed.

Summing Equation (1) over i and applying subadditivity to π1(F∗

1) ≥ πi(F∗

1) ≥ πi(A) and π(F∗

1) ≥ π1(F∗

1), so we have πi(F∗

1) ≤ 2π(F∗

1)

1), we have

?

i

πi(F∗

i) ≤

?

?

i?=1

[πi(A) + π1(F∗

1)] + π1(F∗

1)

≤

i?=1

πi(A) + ℓ(π1(A) + π1(αe′))

= π(A) + (ℓ − 1)π1(A) + ℓπ1(αe′).

19

Page 20

Applying Lemma 5.4 we have π(A) ≥ π1(A) and π(αe′) ≥ π1(αe′), and so

π(A) + (ℓ − 1)π1(A) + ℓπ1(αe′) ≤ ℓ(π(A) + π(αe′)).

Theconclusion nowfollows from thefact weare considering only elements from Iand π(F∗) =?

Lemmas 5.1 and 5.5 together give π(O∗) ≤ ℓ(π(A) + 2maxeπ(e)), and therefore imply an offline

3ℓ-approximation for (π,2U) in the multi-dimensional setting.

iπi(F∗) ≤

?

iπi(F∗

i).

Theonlinesetting.

space. We can therefore hope to apply our online algorithm from Section 3 to this setting. However, there

is a caveat: the algorithm from Section 3 uses the offline algorithm as a subroutine on the sample X to

estimate the threshold τ; na¨ ıvely replacing the subroutine by the O(ℓ) approximation described above leads

to an O(ℓ2) competitive online algorithm3. In order to improve the competitive ratio to O(ℓ) we need to

pick the threshold τ more carefully.

Notethat proper densities essentially define a1-dimensional manifold inℓ-dimensional

Algorithm 5 Online algorithm for multi-dimensional (π,2U)

1: With probability 1/2 run the classic secretary algorithm to pick the single most profitable element else

execute the following steps.

2: Draw k from Binomial(n,1/2).

3: Select the first k elements to be in the sample X. Unconditionally reject these elements.

4: Let τ be largest density such that eτ ∈ X satisfies π(¯PX

constant β.

5: Initialize selected set O ← ∅.

6: for i ∈ Y = U \ X do

7:

if π(O ∪ {i}) − π(O) ≥ 0 and ρ(i) ≥ τ and i / ∈ F then

8:

O ← O ∪ {i}

9:

else

10:

Exit loop.

11:

end if

12: end for

τ) + π(eτ) ≥

β

2πi(F∗

i(X)) for all i, for a

We define τ to be the largest density with eτ ∈ X such that for an appropriate constant β, π(¯PX

π(eτ) ≥

P∗(T) = ∩iF∗

smallest density in F∗

τ) +

β

2πi(F∗

i(X)) for all i. For a set T, let F∗

i(T) denote the shortest of these prefixes. Recall that P∗(U) = F∗

1. That is, F∗

i(T) denote the maximizer of πiover T ∩ I and let

1. Let ρ–denote the

1= P∗(Pρ–). Our analysis relies on the following two events:

E1: π(P∗(PX

ρ– )) ≥ βπ(P∗(Pρ–)),E′

1: π(O∗(X)) ≥ β′′π(O∗).

E1implies the following sequence of inequalities; here the second inequality follows from Lemma 5.5.

π(P∗(PX

ρ– )) ≥ βπ(F∗

1) ≥β

2πi(F∗

i) ≥β

2πi(F∗

i(X)).

(2)

This implies τ ≥ ρ–. Formally, we have the following claim.

3Note the (1 − 1/k1)2factor in the final competitive ratio in Theorem 3.6; this factor is due to the use of the offline subroutine

in determining τ.

20

Page 21

Lemma 5.6. Conditioned on E1, we have τ ≥ ρ–.

Proof. Since¯PX

non-empty, so let ρ′be the minimum density of PX

P∗(PX

for some α′∈ [0,1]. Using subadditivity and the fact that eρ′ ∈ I gives us

π(¯PX

ρ– ⊂¯Pρ– = A, Lemma 5.4 implies that¯PX

ρ– ⊂ P∗(PX

ρ– ). Event E1guarantees that PX

ρ′ = PX

ρ– ) = P∗(PX

ρ– is

ρ– ⊂

ρ– . We have PX

ρ– , which implies¯PX

ρ′ ⊂¯PX

ρ′ ∪{α′eρ′}

ρ– ) and PX

ρ– = PX

ρ′ =¯PX

ρ′ ∪{eρ′} by definition. So, we can write P∗(PX

ρ′) =¯PX

ρ′ ) + π(eρ′) ≥ π(¯PX

ρ′ ∪ {α′eρ′}) = π(P∗(PX

ρ– )).

(3)

Now, threshold τ asselected byAlgorithm 5isthelargest density such that π(¯PX

for all i. Since step 4 of the algorithm would have considered π(¯PX

τ ≥ ρ′. By definition, ρ′≥ ρ–, so we conclude that E1implies τ ≥ ρ–.

Furthermore, by definition, eτ ∈ X and so eτ / ∈ PY

implies¯Pτ⊂¯Pρ– = A, Lemma 5.6 gives us the following lemma.

Lemma 5.7. Conditioned on E1, we have O = PY

τ)+π(eτ) ≥β

2π(F∗

i(X))

ρ′) + π(eρ′), Equations (3) and (2) imply

τ, which implies that PY

τ

⊂¯Pτ. Since τ ≥ ρ–

τ⊂¯Pτ⊂ A.

1gives usSumming over all dimensions and applying event E′

ℓ(π(¯PX

τ) + π(eτ)) ≥β

2

?

i

πi(F∗

i(X)) ≥β

2

?

i

πi(O∗(X)) =β

2π(O∗(X)) ≥ββ′′

2

π(O∗).

So if we define ρ+to be the highest density such that π(¯Pρ+) + π(eρ+) ≥ββ′′

Then, as before we can define the event E2in terms of ρ+to conclude that π(PY

we define E2for some fixed constant β′as follows.

2ℓπ(O∗), then we get ρ+≥ τ.

τ) is large enough. Formally,

E2: π(PY

ρ+) ≥ β′π(Pρ+).

Since PY

conditioning on events E1, E′

ρ+ ⊂ PY

τ

⊂¯Pτ ⊂ A, applying Claim 5.4, we have π(O) = π(PY

1and E2, we get

τ) ≥ π(PY

ρ+). Therefore,

π(O) ≥ π(PY

ρ+) ≥ββ′′β′

2ℓ

π(O∗).

To wrap up the analysis, we argue that the probability of these events is bounded from below by a

constant. Using Lemma 2.1 as in the proof of Lemma 3.5 , if no element has profit at least

then events E1, E′

Pr[E1∧ E′

Lemma 5.8. Suppose that maxeπ(e) ≤ (1/k3ℓ)π(O∗). Then, Pr[E1∧ E′

Via a similar argument as for Theorem 3.6, we get

1

ℓk3π(O∗),

1and E2each occur with probability at least 0.76. Using a union bound, we have that

1∧ E2] ≥ 0.28. This proves the following lemma.

1∧ E2] ≥ 0.28.

Theorem 5.9. Algorithm 5 is O(ℓ) competitive for (π,2U) where π is a multi-dimensional profit function.

21

Page 22

5.1Computing Proper Densities

In this subsection, we show that proper ρ’s exist and can be efficiently computed. To do this, we make the

following assumptions about the marginal cost functions:

(A1) The marginal cost functions cj(·) are unbounded.

(A2) They satisfy cj(sj(U)) > maxe∈Uv(e) for all i.

Note that these assumptions do not affect Ci(t) for sizes t ≤ si(U), and so have no effect on either the

profit function or the optimal solution as well. We first prove that there exists a proper ρ(e) for each element

e. Observe that properties (P1) and (P2) together uniquely define ρ(e). Therefore, we only need to find x∗

satisfying the equation

?

then our proper density ρ(e) is given by ρj(e) = Π−1

continuous function with Πj(0) = 0 and limγ→∞Πj(γ) = ∞, so its inverse Π−1

a strictly-increasing continuous function with Π−1

x∗exists.

Next, we show that for any element e, we can efficiently compute ρ(e). In the following, we fix an

element e, and use sjand v to denote sj(e) and v(e), respectively. We define Ij(t) = Πj(cj(t)). Let x∗be

the solution to Equation 4 for the fixed element e and note that x∗= Π(e).

In the following two lemma statements and proofs, we focus on a single dimension j and remove sub-

scripts for ease of notation. First, we prove that we can easily compute I(t).

j

Π−1

j(x∗)sj(e) = v(e);

(4)

j(x∗). By Assumption (A1), Πjis a strictly-increasing

j

is well-defined and is also

j(x) = ∞. Thus, the solution

j(0) = 0 and limx→∞Π−1

Lemma 5.10. We have I(t) = c(t)t − C(t).

Proof. Let t′= ¯ s(c(t)). Since t′is the maximum size r ≥ t such that c(t) ≥ c(r), by monotonicity, we

have that c(·) is constant in [t,t′]. This implies C(t′) − C(t) = c(t)(t′− t) and so,

c(t)t′− C(t′) = c(t)t − C(t).

The lemma now follows from the fact that I(t) = Π(c(t)) is the LHS of the above equation.

Next, we prove a lemma that helps us determine Π−1(x) given x.

Lemma 5.11. Given x and positive integer t such that I(t) ≤ x < I(t + 1), we have

Π−1(x) =x + C(t)

t

.

Proof. By definition of I(·), we have Π(c(t)) ≤ x < Π(c(t + 1)), and since Π(·) is strictly increasing, we

get

c(t) ≤ Π−1(x) < c(t + 1).

By definition of¯ s(·), this gives us t ≤ ¯ s(Π−1(x)) < t + 1, and therefore ¯ s(Π−1(x)) = t, since c(·) changes

only on the integer points.

Thus, we have

x = Π(Π−1(x)) = Π−1(x)t − C(t)

and solving this for Π−1(x) gives us the desired equality.

22

Page 23

Lemma 5.11 leads to the FIND-DENSITY algorithm which, given a profit x, uses a binary search to

compute Π−1

and then solving linear equations.

j(x). Together with Lemma 5.12, this enables us to determine x∗by first using binary search,

Algorithm 6 Given x and sizes sj, find Π−1(x) and t1,...,tℓsatisfying Ij(tj) ≤ x < Ij(tj+ 1).

FIND-DENSITY(x,s)

1: for j = 1 to ℓ do

2:

Binary search to find integral tj∈ [0,sj(U)) satisfying Ij(tj) ≤ x < Ij(tj+ 1).

3:

Set ρj← (x + Cj(tj))/tj.

4: end for

5: return (ρ,t), where ρ is the vector (ρ1,...,ρℓ) and t is the vector (t1,...,tℓ).

Lemma 5.12. Suppose we have a positive integer x such that

?

j

Π−1

j(x)sj≤ v <

?

j

Π−1

j(x + 1)sj,

(5)

and positive integers t1,...,tℓsuch that Ij(tj) ≤ x < Ij(tj+ 1) for all j. Then the solution x∗to

Equation (4) is precisely:

v −?

?

Proof. Equation (5) and the monotonicity of the Π−1

Ij(tj) ≤ x∗< x + 1 ≤ Ij(tj+ 1) for all j. Applying Lemma 5.11 to dimension j gives us Π−1

(x∗− Cj(tj))/tj. Then, applying Equation (4), we get

x∗=

jCj(tj)(sj/tj)

j(sj/tj)

.

j’s imply that x ≤ x∗< x + 1 and so, we have

j(x∗) =

v =

?

j

Π−1

j(x∗)sj=

?

j

?x∗+ Cj(tj)

tj

?

sj.

Solving this for x∗gives the claimed equality.

Weneed the following lemmato show that the binary search upper bounds in both algorithms are correct.

Lemma 5.13. For proper density ρ, we have x∗< Ij(sj(U)) for all dimensions j.

Proof. If an element has zero size in dimension j, then we can ignore Cj(·). So without loss of generality,

we assume that sj> 0 for all j. Property (P1) gives us v =?

iρisi≥ ρjsjand so ρj≤ v/sj≤ v. From

assumption (A2), we have that cj(sj(U)) > v ≥ ρj. This implies that

Πj(ρj) < Π(cj(sj(U))) = Ij(sj(U))

Since ρ is proper, we have Πj(ρj) = x∗and this proves the lemma.

Theorem 5.14. Algorithms FIND-DENSITY and FIND-PROPER-DENSITY run in polynomial time and are

correct.

23

Page 24

Algorithm 7 Given sizes sjand value v, find ρ satisfying (P1) and (P2).

FIND-PROPER-DENSITY(v,s)

1: Binary search to find integral x ∈ [0,minjIj(sj(U))) satisfying

?

j

δ−

jsj≤ v <

?

j

δ+

jsj,

where (δ−,t) = FIND-DENSITY(x,s) and (δ+,t′) = FIND-DENSITY(x + 1,s).

2: Set

x∗←

v −?

jCj(tj)(sj/tj)

?

j(sj/tj)

.

3: for j = 1 to ℓ do

4:

Set ρj← (x∗+ Cj(tj))/tj.

5: end for

6: return ρ

Proof. Lemmas 5.11 and 5.12 show that given correctness of the binary search upper bounds, the output

is correct. Lemma 5.13 implies that the binary search upper bound of FIND-PROPER-DENSITY is correct.

We observe that FIND-DENSITY is only invoked for integral profits x < Ij(sj(U)). Therefore, we have

Ij(t′) ≤ x < Ij(t′+1) for t′< sj(U) and this proves that the binary search upper bound of FIND-DENSITY

is correct.

Since the numbers involved in the arithmetic and the binary search are polynomial in terms of sj(U),

Cj(sj(U)), we conclude that the algorithms take time polynomial in the input size.

The online setting.

know sj(U). However, we can get around this by observing that if we have sizes t1,...,tℓsatisfying

Ij(tj) > Πj(ρj) = x∗for all j, then Ij(tj) > x∗and hence minjIj(tj) suffices as an upper bound for the

binary search in FIND-PROPER-DENSITY. Since we invoke FIND-DENSITY for x < Ij(tj), we have that

t1,...,tℓsuffice as upper bounds for the binary searches in FIND-DENSITY as well.

By (A2), we have cj(sj(U)) > v ≥ ρjfor any proper ρ, so if we guess tjsuch that cj(tj) > v, then

we have Ij(tj) > Πj(ρj). Therefore, we set tj= 2m, with m = 1 initially, increment m one at a time and

check if cj(tj) < v. Assumption (A2) and monotonicity of cj(·) implies that tj≤ 2sj(U) and so it takes us

m ≤ log(2sj(U)) iterations to get cj(tj) > v. Repeating this for each dimension gives us sufficient upper

bounds for the binary searches in both algorithms.

When the algorithm does not get to see the entire input at once, then it does not

6Multi-dimensional costs with general feasibility constraint

In this section we consider the multi-dimensional costs setting with a general feasibility constraint, (π,F).

As before we use an O(1)-approximate offline and an α-competitive online algorithm for (Φ,F) as a sub-

routine, where Φ is a sum-of-values objective. While we will be able to obtain an O(αℓ) approximation in

the offline setting, this only translates into an O(αℓ5) competitive online algorithm.

As in Section 5, we associate with each element e an ℓ-dimensional proper density vector ρ(e). Then

24

Page 25

we decompose the profit functions πiinto sum-of-values objectives defined as follows.

gi

γ(A) = γisi(A) − Ci(si(A)),

hi

γ(A) =

?

igi

e∈A

(ρi(e) − γi)si(e).

Let hγ(A) =?

We extend the definition of “boundedness” to the multi-dimensional setting as follows (see also Defini-

tion 4.1).

ihi

γ(A) and gγ(A) =?

γ(A). We have πi(A) = hi

γ(A) + gi

γ(A) for all i and π(A) =

hγ(A) + gγ(A). As before, Gγ,i= argmaxA⊂¯Pγsi(A).

Definition 6.1. Given a density vector γ, a subset A ⊂ Pγis said to be γ-bounded if, for all i, A is γi-

bounded with respect to Ci, that is, ρi(A) ≥ γiand si(A) ≤ ¯ si(γi). If A is γ-bounded and γ is the minimum

density of A, then we say A is bounded.

The following lemma is analogous to Proposition 4.2.

Lemma 6.1. If A is bounded, then π(A) ≥ πi(A) for all i. Moreover, if A is γ-bounded then for all i, we

have

π(A) ≥ gγ(A) ≥ gi

π(A) ≥ hγ(A) ≥ hi

Proof. We start by assuming that A is γ-bounded. For each dimension i, we get πi(A) ≥ gi

by Proposition 4.2. Thus, we have π(A) ≥ gγ(A) ≥ gi

that π(A) ≥ hγ(A) ≥ hi

hi

γ(A),

γ(A).

γ(A) ≥ 0

γ(A) by summing over i. A similar proof shows

γ(A). Next, we assume that A is bounded. Let µ be its minimum density. Then

µ(A) ≥ 0. This gives us πi(A) = hi

As in the single-dimensional setting, our approach is to find an appropriate density γ to bound hγ(O∗)

and gγ(O∗) in terms of the maximizers of hi

single-dimensional constrained setting given in Section 4, as a subroutine. We consider two possible sce-

narios: either all feasible sets are bounded or there exists an unbounded set. We use the following lemma to

tackle the first scenario.

µ(A) ≥ 0 and gi

µ(A) + gi

µ(A) ≥ 0 and so π(A) ≥ πi(A) for all i.

γand gi

γ. We use Algorithm 3, the offline algorithm for the

Lemma 6.2. Suppose all feasible sets are bounded. Let Di= argmaxD∈{Hγi,Gγi,e}γiπi(D) be the result

of running Algorithm 3 on the single-dimensional instance (πi,F), where F is the underlying feasibility

constraint. Then, we have?

Proof. Fix a dimension i. Since all feasible sets are bounded, we have π(Di) ≥ πi(Di) by Lemma 6.1.

Furthermore, Theorem 3 implies that πi(Di) ≥1

?

Now we handle the case when there exists an unbounded feasible set.

iπ(Di) ≥1

4π(O∗).

4πi(O∗). Summing over all dimensions, we have

1

4πi(O∗) =1

i

π(Di) ≥

?

i

πi(Di) ≥

?

i

4π(O∗).

Lemma 6.3. Suppose there exists an unbounded feasible set. Let ρ–be the highest proper density such that

Pρ– contains an unbounded feasible set. Let D′

elements of density at most ρ–) with objective πiand feasibility constraint F. If eρ– ∈ I, then we have

4

?

ibe the result of running Algorithm 3 on¯Pρ– (i.e. ignoring

i

π(D′

i) + ℓ(max

i

π(Gρ–,i) + π(eρ–)) ≥ π(O∗).

25

Page 26

Proof. For brevity we use e′to denote eρ–. Let O∗

we have π(O∗) ≤ π(O∗

Thus, we can apply Lemma 6.2 and get 4?

we have π(O∗

2) ≤?

1= O∗∩ (¯Pρ–) and O∗

2= O∗\ O∗

1. By subadditivity,

1) + π(O∗

2). We observe that all feasible sets in¯Pρ– are bounded by definition of ρ–.

iπ(D′

2). We have hρ–(O∗

2). We know that for all i,

i) ≥ π(O∗

2) ≤ 0 since O∗

1).

Next, we approximate π(O∗

2has elements of density at most ρ–. So,

igi

ρ–(O∗

Π(e′) = max

t

(ρ–

it − Ci(t))

2) − Ci(si(O∗

ρ–(O∗

≥ ρ–

= gi

isi(O∗

2))

2),

so we have ℓΠ(e′) ≥ π(O∗

Let L be the unbounded feasible set in Pρ–; note that its minimum density is ρ–. Since L is unbounded,

there exists j such that sj(L) > ¯ sj(e′). We know that Gρ–,jmaximizes sj(·) among feasible sets contained

in Pρ– \ {eρ–}. Therefore, we have sj(Gρ–,j) + sj(e′) ≥ sj(L) > ¯ sj(e′).

Now consider two cases. Suppose that for all i, si(Gρ–,i) ≤ ¯ si(e′). Then, si(Gρ–,j) ≤ ¯ si(e′). For brevity,

we denote Gρ–,jby G′. For all i, let αibe such that si(G′)+αisi(e′) = ¯ si(e′) and let α = miniαi. Without

loss of generality, we assume that α1is the minimum. By definition, we have s1(G′+ αe′) = ¯ s1(e′) and

si(G′+ αe′) ≤ ¯ si(e′) for i ?= 1. This implies that G′+ αe′is a ρ–-bounded fractional set and so

π(G′+ αe′) ≥ g1

= ρ–

= ρ1(e′)¯ s1(e′) − C1(¯ s1(e′))

= Π(e′).

2) and it suffices to bound Π(e′).

ρ–(G′+ αe′)

1s1(G′+ αe′) − C1(s1(G′+ αe′))

Since e′∈ I, we have ℓ(π(G′) + π(e′)) ≥ ℓΠ(e′) ≥ π(O∗

In the second case, there exists a dimension i such that¯ si(e′) < si(Gρ–,i). Without loss of generality, we

assume that it is the first dimension. In this case, we define G′to be Gρ–,1. Let µ be the minimum density

in G′. Note that µ1> ρ–

¯ s1(µ1). Applying Lemma 4.1 over µ1gives

2).

11 < by definition of the Gρ–,i’s. Since G′is bounded, we have ¯ s1(e′) < s1(G′) ≤

g1

µ(G′) = µ1s1(G′) − C1(s1(G′)) > µ1¯ s1(e′) − C1(¯ s1(e′)).

Since G′is µ-bounded, by Lemma 6.2 we have

π(G′) ≥ g1

µ(G′)

> µ1¯ s1(e′) − C1(¯ s1(e′))

> ρ–

= Π(e′).

1¯ s1(e′) − C1(¯ s1(e′))

This gives us ℓπ(G′) = π(O∗

2). Overall, we get ℓ(maxiπ(Gρ–,i) + π(e′)) ≥ π(O∗

We are now ready to give an offline algorithm. Let Dγ,ibe the result of running Algorithm 3 on Pγwith

objective πiand feasibility constraint F.

Finally, we use the above lemmas to lower bound the performance of Algorithm 8.

2).

Theorem 6.4. Algorithm 8 gives a 7ℓ-approximation to (π,F) where π is an ℓ-dimensional profit function

and F is a matroid feasibility constraint.

26

Page 27

Algorithm 8 Offline algorithm for multi-dimensional (π,F)

1: Let Gmax= argmaxG∈{Gγ,i}γ,iπ(G).

2: Let Dmax= argmaxD∈{Dγ,i}γ,iπ(D).

3: Let emax= argmaxe∈Uπ(e).

4: return the most profitable of Gmax, Dmax, and emax.

Proof. First, we consider only elements from I. If all feasible sets are bounded, then we get π(Dmax) ≥

1

4ℓπ(O∗) by Lemma 6.2. On the other hand, if there exists an unbounded feasible set, then we have

ℓ(4π(Dmax) + π(emax) + π(Gmax)) ≥ 4

?

i

π(D′

i) + ℓ(π(e′) + max

i

π(Gρ–,i))

≥ π(O∗∩ I)

by Lemma 6.3. For elements from F, Lemma 5.1 shows that π(emax) ≥ π(O∗∩ F)/ℓ. This proves that the

algorithm achieves a 7ℓ-approximation.

6.1 The online setting

Algorithm 9 Online algorithm for multi-dimensional (π,F)

1: Let c be a uniformly random draw from {1,2,3}.

2: Let i∗be a uniformly random draw from {1,...,ℓ}.

3: if c = 1 then

4:

return O0: the result of running Dynkin’s online algorithm.

5: else if c = 2 then

6:

return O1: the result of running Algorithm 4 on (πi∗,F).

7: else if c = 3 then

8:

Draw k from Binomial(n,1/2).

9:

Let the sample X be the first k elements and Y be the remaining elements.

10:

Determine A(X) using the offline Algorithm 8.

11:

Let β be a specified constant and let τ be the highest density such that π(A(PX

12:

return O2: the result of running Algorithm 4 on PY

13: end if

τ)) ≥

β

49ℓ2π(A(X)).

τwith objective πi∗ and feasibility constraint F.

In this subsection, we develop the online algorithm for constrained multidimensional profit maximiza-

tion. First we remark that density prefixes are well-defined in this setting, so we can use Algorithm 4, the

online algorithm for single-dimensional constrained profit maximization, in steps 6 and 12. In order to

mimic the offline algorithm, we guess (with equal probability) among one of the following scenarios and

apply the appropriate subroutine for profit maximization: if there is a single high profit element we apply

Dynkin’s algorithm, if all feasible sets are bounded we apply Algorithm 4 along a randomly selected dimen-

sion, else if there exists an unbounded feasible set we first estimate a density threshold by sampling and then

apply Algorithm 4 over a random dimension but restricted to elements with density above the threshold.

Most of this subsection is devoted the analysis of Algorithm 9 when there exists an unbounded feasible

set. We prove the overall competitive ratio of the algorithm in Theorem 6.7.

We define ρ+as follows.

27

Page 28

Definition 6.2. For a fixed parameter β ≤ 1, let ρ+be the highest density such that π(O∗(Pρ+)) ≥

?

The following lemma is essentially an analogue of Lemma 4.7.

β

49ℓ2

?2π(O∗).

Lemma 6.5. Suppose there exists an unbounded feasible set. For fixed parameters k1 ≥ 1, k4 ≤ 1,

β ≤ 1 and β′≤ 1 assume that there does not exists an element with profit more than

probability at least k4, we have that τ, as defined in Algorithm 9, satisfies

1

k1π(O∗). Then with

1. ρ+≥ τ ≥ ρ–and

2. π(O∗(PY

τ)) ≥ β′?

β

49ℓ2

?2π(O∗)

Proof Sketch: We define events E1and E2as in the single-dimensional setting:

E1: π(O∗(PX

E2: π(O∗(PY

ρ– )) ≥ βπ(O∗(Pρ–))

ρ+)) ≥ β′π(O∗(Pρ+)).

We observe that the proof of Lemma 4.7 primarily depends on the properties of density prefixes, in partic-

ular that π(O∗(PX

decrease when considering larger prefixes. Then Theorem 6.4 gives us π(O∗(Pρ–)) ≥

Thus, a proof similar to that of Lemma 4.7 validates Lemma 6.5.

The following lemma establishes the competitive ratio of Algorithm 9 in the presence of an unbounded

feasible set.

ρ– )) is a sufficiently large fraction of π(O∗(Pρ–)), and that Algorithm 3’s profit does not

1

7ℓπ(O∗).

Lemma 6.6. Suppose that there exists an unbounded feasible set, and let α be the competitive ratio that

Algorithm 4 achieves for a single-dimensional problem (πi,F). Then, for a fixed set Y and threshold τ,

satisfying τ ≥ ρ–, we have Eσ[π(O2)] ≥

of Y .

1

αℓπ(O∗(PY

τ)), where the expectation is over all permutations σ

Proof. First, we prove that O2is bounded. By the definition of ρ–, since O2⊆ PY

PY

ρ–and it suffices to consider the former case. If τ = ρ–, then eρ– must have been in the sample set X so it

is not in PY

Hence, by Lemma 6.1, for all i we have π(O2) ≥ πi(O2). Applying Theorem 4.8 where the ground set

is PY

τ it suffices to show that

τ⊆¯Pρ–, as all feasible sets in¯Pρ– are bounded. The threshold τ is either equal to or strictly greater than

τand so PY

τ⊆¯Pρ–.

τgives us Eσ[πi(O2) | i∗= i] ≥1

απi(O∗(PY

τ)). Therefore, we have

Eσ[π(O2)] =1

ℓ

?

?

1

αℓ

i

Eσ[π(O2) | i∗= i]

≥1

ℓ

i

Eσ[πi(O2) | i∗= i]

≥

?

i

πi(O∗(PY

τ))

=

1

αℓπ(O∗(PY

τ)).

We now prove the main result of this section.

28

Page 29

Theorem 6.7. Let α denote the competitive ratio of Algorithm 4 for the single-dimensional problem (πi,F).

Then Algorithm 9 achieves a competitive ratio of O(αℓ5) for the multi-dimensional problem (π,F).

Proof. If all feasible sets are bounded, we can apply Lemma 6.1. Then,

E[π(O1)] ≥1

ℓ

?

1

αℓ

i

E[πi(O1) | i∗= i]

≥

?

i

πi(O∗)

=

1

αℓπ(O∗).

Suppose there exists an element with profit more than

algorithm with probability1

profit of

Finally, if no element has profit more than

the second inequality of Lemma 6.5, Lemma 6.6, and the fact that we output O2with probability1

1

k1π(O∗). Since we apply the standard secretary

3, and the standard secretary algorithm is e-competitive, in expectation we get a

3k1etimes the optimal.

1

k1π(O∗) and there exists an unbounded feasible set, using

1

3, we get

E[π(O2)] ≥1

3E[π(O2) | E1∧ E2]Pr[E1∧ E2]

k4

3αℓ· E[π(O∗(PY

≥k4β′

3αℓ49ℓ2

≥

τ)) | E1∧ E2]

?

β

?2

π(O∗).

Overall, we have that

E[π(O)] ≥ min

?

k4β′

3αℓ

?

β

49ℓ2

?2

,

1

3k1e,

1

3αℓ

?

· π(O∗).

Since all the involved parameters are fixed constants we get the desired result.

References

[1] M. Babaioff, M. Dinitz, A. Gupta, N. Immorlica, and K. Talwar. Secretary problems: weights and

discounts. In Proceedings of the twentieth Annual ACM-SIAM Symposium on Discrete Algorithms,

pages 1245–1254. Society for Industrial and Applied Mathematics, 2009.

[2] M. Babaioff, J. Hartline, and R. Kleinberg. Selling banner ads: Online algorithms with buyback. In

Fourth Workshop on Ad Auctions, 2008.

[3] M. Babaioff, J. D. Hartline, and R. D. Kleinberg. Selling ad campaigns: Online algorithms with

cancellations. In Proceedings of the tenth ACM conference on Electronic commerce, pages 61–70.

ACM, 2009.

[4] M. Babaioff, N. Immorlica, D. Kempe, and R. Kleinberg. A knapsack secretary problem with appli-

cations. In Approximation, Randomization, and Combinatorial Optimization. Algorithms and Tech-

niques, pages 16–28. Springer Berlin / Heidelberg, 2007.

29

Page 30

[5] M. Babaioff, N. Immorlica, and R. Kleinberg. Matroids, secretary problems, and online mechanisms.

In Proceedings of the eighteenth annual ACM-SIAM symposium on Discrete algorithms, pages 434–

443. Society for Industrial and Applied Mathematics, 2007.

[6] M. H. Bateni, M. T. Hajiaghayi, and M. Zadimoghaddam. Submodular secretary problem and ex-

tensions. In Approximation, Randomization, and Combinatorial Optimization. Algorithms and Tech-

niques, pages 39–52. Springer Berlin / Heidelberg, 2010.

[7] S. Chakraborty and O. Lachish. Improved competitive ratio for the matroid secretary problem. To

appear in SODA ’12.

[8] S. Chawla, J. D. Hartline, D. L. Malec, and B. Sivan. Multi-parameter mechanism design and sequen-

tial posted pricing. In Proceedings of the 42nd ACM symposium on Theory of computing, STOC ’10,

pages 311–320. ACM, 2010.

[9] B. C. Dean, M. X. Goemans, and J. Vondr´ ak. Adaptivity and approximation for stochastic packing

problems. In Proceedings of the sixteenth annual ACM-SIAM symposium on Discrete algorithms,

SODA ’05, pages 395–404. Society for Industrial and Applied Mathematics, 2005.

[10] N. B. Dimitrov and C. G. Plaxton. Competitive weighted matching in transversal matroids. In Proceed-

ings of the 35th international colloquium on Automata, Languages and Programming, Part I, pages

397–308. Springer-Verlag, 2008.

[11] E. B. Dynkin. The optimum choice of the instant for stopping a Markov process. Soviet Math. Dokl,

4(627-629), 1963.

[12] U. Feige, A. Flaxman, J. D. Hartline, and R. Kleinberg. On the Competitive Ratio of the Random

Sampling Auction. In Proceedings of the first annual workshop on Internet and network economics.

Springer, 2005.

[13] Moran Feldman, Joseph Seffi Naor, and Roy Schwartz. Improved competitive ratios for submodular

secretary problems. In Proceedings of the 14th international workshop and 15th international confer-

ence on Approximation, randomization, and combinatorial optimization: algorithms and techniques,

APPROX’11/RANDOM’11, pages 218–229, Berlin, Heidelberg, 2011. Springer-Verlag.

[14] T. Ferguson. Who solved the secretary problem. Statist. Sci., 4(3):282–289, 1989.

[15] P. R. Freeman. The secretary problem and its extensions: a review. International Statistical Review,

51(2):189–206, 1983.

[16] Anupam Gupta, Aaron Roth, Grant Schoenebeck, and Kunal Talwar. Constrained non-monotone sub-

modular maximization: Offline and secretary algorithms. In Internet and Network Economics, pages

246–257. Springer Berlin / Heidelberg, 2010.

[17] Mohammad Taghi Hajiaghayi, Robert Kleinberg, and David C. Parkes. Adaptive limited-supply online

auctions. In Proceedings of the 5th ACM conference on Electronic commerce, EC ’04, pages 71–80,

New York, NY, USA, 2004. ACM.

[18] D. P. Kennedy. Prophet-type inequalities for multi-choice optimal stopping. Stochastic Processes and

their Applications, 24(1):77–88, 1987.

30

Page 31

[19] R. Kleinberg. A multiple-choice secretary algorithm with applications to online auctions. In Proceed-

ings of the sixteenth annual ACM-SIAM symposium on Discrete algorithms, pages 630–631. Society

for Industrial and Applied Mathematics, 2005.

[20] N. Korula and M. P´ al. Algorithms for secretary problems on graphs and hypergraphs. In Proceedings

of the 36th International Colloquium on Automata, Languages and Programming: Part II, ICALP ’09,

pages 508–520. Springer-Verlag, 2009.

[21] J. Oxley. Matroid Theory. Oxford University Press, 1992.

[22] E. Samuel-Cahn. Comparison of threshold stop rules and maximum for independent nonnegative

random variables. The Annals of Probability, 12(4):1213–1216, 1984.

[23] S. Samuels. Secretary problems. In Handbook of Sequential Analysis, pages 381–405. Marcel Dekker,

1991.

[24] J. A. Soto. Matroid Secretary Problem in the Random Assignment Model. In Proceedings of the

twenty-second Annual ACM-SIAM Symposium on Discrete Algorithms, pages 1275–1284. Society for

Industrial and Applied Mathematics, 2011.

31