1 / 62

Online product queries

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.

bandele
Download Presentation

Online product queries

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Online product queries Based on the technical report of Alon and Schieber Published by Chazelle & Rozenberg and Yao

  2. Wilhelm Ackermann 1896-1963, phd 1925, function 1928

  3. Ackermann’s function

  4. Ackermann’s function (modified)

  5. is the inverse of the function Inverse Ackermann function A “diagonal” The first “column”

  6. I am changing notation slightly..

  7. Inverse Ackermann functions

  8. We can define these row-inverses directly # times you have to apply αk–1, starting from n, until you get a result ≤ 1.

  9. The inverse Ackermann function For every fixed n ≥ 6, the sequence strictly decreases, until it settles at 3.

  10. Example: n = 9876!:

  11. 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

  12. k=2 ....................... .......................

  13. k=2 log(n) levels, linearly many products per level  O(nlog(n)) = O(nα2(n)) products

  14. k=3 √n

  15. k=3 For every element x we have two products from x to the endpoints of its block  O(n)

  16. k=3 For every interval of complete blocks we compute its product  O(n)

  17. k=3 Recursively do the same inside each block p3(n) = O(nloglog(n))=o(nlog(n)) = o(nα2(n))

  18. 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.)

  19. k≥4 t

  20. k≥4 Compute a product from each element to the endpoints of its interval  2n

  21. k≥4 Compute the product of each block and apply the algorithm for k-2 to these n/t elements

  22. k≥4 Apply the algorithm recursively inside each block of size t

  23. k≥4 Apply the algorithm recursively inside each block of size t

  24. Choose t = log(n)

  25. By induction assumption: Let Note that: We do not quite get the induction through…

  26. Let: For k≥3

  27. Homework By induction assumption: Let Note that: c≥4

  28. lower bounds k=1

  29. k=2 z

  30. 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:

  31. 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:

  32. k=3 √n

  33. 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

  34. k=3 If there are √n/2 global intervals then

  35. k=3 Otherwise there are √n/2 non-global intervals each with a non-global element

  36. 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

  37. 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

  38. 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

  39. 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

  40. 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

  41. 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:

  42. 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”.

  43. 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.

  44. 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

  45. … 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.

  46. 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’).

  47. 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.

  48. 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.

More Related