650 likes | 885 Views
Online product queries. Based on the technical report of Alon and Schieber. Published by Chazelle & Rozenberg and Yao. Wilhelm Ackermann. 1896-1963, phd 1925, function 1928. Ackermann ’s function. Ackermann ’s function (modified). is the inverse of the function. Inverse Ackermann function.
E N D
Online product queries Based on the technical report of Alon and Schieber Published by Chazelle & Rozenberg and Yao
Wilhelm Ackermann 1896-1963, phd 1925, function 1928
is the inverse of the function Inverse Ackermann function A “diagonal” The first “column”
We can define these row-inverses directly # times you have to apply αk–1, starting from n, until you get a result ≤ 1.
The inverse Ackermann function For every fixed n ≥ 6, the sequence strictly decreases, until it settles at 3.
Today’s problem You get a list of items from some semigroup (think of integers and the operation max) Preprocess them so that you can compute the product of any query interval using a small number of precomputed products pk(n) = # of products we have to precompute to answer a query using only k products
k=2 ....................... .......................
k=2 log(n) levels, linearly many products per level O(nlog(n)) = O(nα2(n)) products
k=3 √n
k=3 For every element x we have two products from x to the endpoints of its block O(n)
k=3 For every interval of complete blocks we compute its product O(n)
k=3 Recursively do the same inside each block p3(n) = O(nloglog(n))=o(nlog(n)) = o(nα2(n))
Product queries 1 product per query (k=1): 2 products per query (k=2): 3 products per query: 4,5 products per query: 6,7 products per query: k products per query: (Implicit constants in upper bound are independent of k.)
k≥4 t
k≥4 Compute a product from each element to the endpoints of its interval 2n
k≥4 Compute the product of each block and apply the algorithm for k-2 to these n/t elements
k≥4 Apply the algorithm recursively inside each block of size t
k≥4 Apply the algorithm recursively inside each block of size t
By induction assumption: Let Note that: We do not quite get the induction through…
Let: For k≥3
Homework By induction assumption: Let Note that: c≥4
lower bounds k=1
k=2 z
k=2 x z If for each x we have a product such that x is the leftmost item in this product and the product has elements to the right of z then:
k=2 y x z Otherwise for each y on the right we must have a set containing z in which y is the rightmost so:
k=3 √n
k=3 An element is global if it is the leftmost element or rightmost in a set that is not contained in an interval A global interval is an interval whose elements are all global
k=3 If there are √n/2 global intervals then
k=3 Otherwise there are √n/2 non-global intervals each with a non-global element
k=3 Otherwise there are √n/2 non-global intervals each with a non-global element In a cover of an interval as above one set is inside I1 and one set is inside I2 The last set must cover all the greens in the middle
k=3 So consider only the greens right before a non-global interval (except the first) We have about √n/2 such greens We have a subset corresponding to each interval of these greens
k≥4 Suppose we have a lower bound of Ω(nαm(n)) for k, we prove a lower bound of Ω(nαm+1(n)) for k+2: t= αm(n) An element is global if it is the leftmost element or the rightmost in a set that is not contained in an interval A global interval is an interval whose elements are all global
k≥4 Suppose we have a lower bound of Ω(nαm(n)) for k, we prove a lower bound of Ω(nαm+1(n)) for k+2: t= αm(n) If there are n/2t global intervals then
k≥4 Suppose we have a lower bound of Ω(nαm(n)) for k, we prove a lower bound of Ω(nαm+1(n)) for k+2: Otherwise there are n/2t=n/(2αm(n)) non-global intervals Our cover must induces a cover of the green elements preceding these intervals (but the first) with k sets
k≥4 Suppose we have a lower bound of Ω(nαm(n)) for k, we prove a lower bound of Ω(nαm+1(n)) for k+2:
Weak ε-nets for convex sets (ANSSK’08) Given: Set S of n points in Rd; parameter ε, 0 < ε < 1. S N εn = 4 Objective: Construct a point set N that “stabs” all convex hulls of at least εn points of S. Points of N do not have to be from S. Net is “weak”.
Weak ε-nets for convex sets For convenience, let r = 1/ε, so r > 1. Weak (1/r)-net: Stabs all convex hulls of n/r points of S. Weak ε-Net Theorem: [ABDK ’92] Size of the net depends only on d and r. There exist functions fd(r), independent of n, such that every set S in Rd has a weak (1/r)-net of size at most fd(r). Best upper bounds: f2(r) = O(r2) [ABDK ’92]. fd(r) = O(rd polylog r) [CEGGSW ’95]. fd(r) = Ω(r). Best lower bound: Trivial.
Weak ε-nets for convex sets We consider a special case. S in R2 in convex position. Previous upper bound for this case: We will show: α – inverse Ackermann function
… … Construction of weak (1/r)-netsfor planar sets in convex position Given:n-point set S in convex position. Want: Stab all convex hulls of n/r points. B2 B3 B1 p2 p1 Place lgreen points equally spaced between the points of S. The green points partition S into lblocksB1, …, Bl, each of size n/l.
Construction of weak (1/r)-netsfor planar sets in convex position A subset S' of size n/r must “touch” at least l/r different blocks. block Bi (size n/l) Let m = l/r. m-gon with vertices from m different blocks. interval Ik The m-gon partitions the green points into mnonempty intervalsI0,…,Im–1. If 4 green pointspa, pb, pc, pd lie on 4 different intervals, then intersection between papc and pbpd lies inside the m-gon, so it stabsCH(S’).
Construction of weak (1/r)-netsfor planar sets in convex position We have reduced to the following problem: Given a cyclic sequence of lgreen points divided into mintervalsI0, …, Im–1, in an unknown way. I0 I1 I2 I3 I4 I5 I0 p0 pa pb pc pd pl–1 Construct a family of quadruples, s.t. some quadruple pa, pb, pc, pd “falls on” 4 different intervals.
Construction of weak (1/r)-netsfor planar sets in convex position I0 I1 I2 I3 I4 I5 I0 p0 pa pb pc pl–1 Take p0 as the first point of all the quadruples. It stabs interval I0. Need to construct a family of triples that stab 3 other intervals. We have reduced to: Stabbing interval chains with triples.