0% found this document useful (0 votes)
2 views22 pages

Vertical Decomposition

The document discusses techniques for sampling and moments, focusing on vertical decomposition and randomized incremental construction (RIC) to solve the problem of determining the face containing a point in an arrangement of line segments. It highlights the challenges of space complexity in slab decomposition and presents vertical trapezoids as a solution to manage complexity. The document also covers the expected running time of the RIC algorithm and the role of randomization in improving efficiency.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views22 pages

Vertical Decomposition

The document discusses techniques for sampling and moments, focusing on vertical decomposition and randomized incremental construction (RIC) to solve the problem of determining the face containing a point in an arrangement of line segments. It highlights the challenges of space complexity in slab decomposition and presents vertical trapezoids as a solution to manage complexity. The document also covers the expected running time of the RIC algorithm and the role of randomization in improving efficiency.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 22

SAMPLING & MOMENTS

TECHNIQUES

- KARTHEEK 190101023
- SAAKETH 190101080
OVERVIEW

 Vertical Decomposition
 Randomized Incremental Algorithm
 Backward Analysis
 Why randomization?
 General Settings
PROBLEM STATEMENT

 Let S = {s1, s2,….., sn} be a collection of n line segments in the plane, and let p be a point not lying on any
of the segments. We wish to compute the face that contains p in the arrangement A of S.
 How to solve this problem?
 We already know that this problem can be solved using the Slab Decomposition Technique.
 But What’s the problem with slab decomposition?
REVIEW:
 In this example, the space complexity is
O(n^2) which is too much.
 Can we do better in space complexity?
 To reduce the space complexity, we use
vertical decomposition.
VERTICAL
DECOMPOSITION

 Let S = {s1, s2, ..., sn} be a set of line segments, then a vertex of
set S is either an endpoint of a segment of S, or an
intersection point of two of its segments.
 Let us take a subset R of set S , and the vertical decomposition
be A’(R) corresponding to the arrangement A(R) of segments
in R.
 From each such vertex in R we shoot up (similarly down) a
vertical ray till it hits a segment of R, or it continues all the way
to infinity.
VERTICAL
DECOMPOSITION
2

 A vertical trapezoid is defined by at most 4 segments: two seg-


ments defining its ceiling and floor, and two segments defining
the two inter-section points that induce the two vertical walls 3
on its boundary
 A vertical trapezoid might be degenerate, and thus defined by
less segments.
 Vertical decomposition breaks the faces of the arrangement
into entities (vertical trapezoids) of constant complexity.
RANDOMIZED INCREMENTAL
CONSTRUCTION (RIC)
 Assume set S contains k intersection points and we will
compute a random permutation of S:<s1, s2 ... sn>
 If we know the vertical decomposition for a prefix of S, then
we try to find vertical decomposition after adding the next
segment si. We compute Bi = A'(Si) from Bi-1 = A'(Si-1).
 The process of finding A' after inserting a line segment
involves splitting and merging of trapezoids.
 We have to compute the trapezoids which intersect si, this is
done by using Conflict Graph.
 Every trapezoid σ ∈ Bi-1 maintains a conflict list cl(σ),
containing the segments of S that intersect its interior
RANDOMIZED INCREMENTAL
CONSTRUCTION
 When a new segment arrive, we know what are the trapezoids to
split (trapezoids in cl(si)).
 Splitting of a trapezoid may lead to a maximum of 4 new trapezoids.
 For every new trapezoid, we need to compute the conflict list.
 This can be done in linear time by iterating through the conflict list of
the parent trapezoid.
 Merging of trapezoids is done by providing pointers between
adjacent vertical trapezoids and maintaining the conflict-list sorted
(or by using hashing).
RANDOMIZED INCREMENTAL
CONSTRUCTION
 Claim:
 The (amortized) running time of constructing Bi from Bi−1 is proportional to the size of the conflict lists of the
vertical trapezoids in Bi \ Bi−1 (and the number of such new trapezoids).
 Proof:
 Observe, that every conflict get charged twice – when it is being created, and when it is being deleted.
 So the (amortized) running time in the ith iteration is proportional to the total length of the newly created
conflict lists.
 Thus, to bound the running time of the algorithm, it is enough to bound the expected size of the created
conflict-lists in ith iteration.
RANDOMIZED INCREMENTAL
CONSTRUCTION
 Lemma:

 Let S be a set of n segments with k intersection points. Let Si be the first i segments in a random permutation
of S. The expected size of Bi = A'(Si), denoted by τ(i), (i.e., number of trapezoids in Bi) is O(i + k(i/n)2)
 Proof:
 Number of trapezoids in Bi is proportional to number of vertices in A(Si).
 Number of vertices = End points of segments + Intersection Points.
 Total endpoints = 2 * total no of segments = 2i.
 The probability that an intersection point p exists in Bi is α.
α = (n-2)C(i-2) / nci = i*(i-1) / n*(n-1).
 Expected number of intersection points in Bi = k*α.
 So total number of trapezoids ∝ no of vertices = 2i + kα = 2i + k*i*(i-1) / n*(n-1) ≈ O(i + k* (i / n)2).
BACKWARD ANALYSIS
 Assume that the overall size of the conflict-lists of the trapezoids of Bi is Wi , and total size of the conflict lists
created only in the ith iteration is Ci.
 Bi does not depends on internal order of Si = {s1, s2, …, si}.
 Probability that si is the last segment added is 1/i.
 Now let σ ∈ Bi is a trapezoid formed in ith iteration then si must one of the segments (atmost 4) defining it.
 So Prob[σ ∈ Bi / Bi-1] <= 4 / i.
 By definition, Wi = ∑σ∈Bi |cl(σ)|
 Expected overall size of conflict list created in ith iteration is given by,
BACKWARD ANALYSIS

 No of trapezoids in Bi is already given by claim above, is o(i + k*(i/n)2).


 For time being, let's take that avg size of conflict list of a trapezoid of Bi is O(n/i).

 In particular, the expected amount of work in the ith iteration is proportional to E[Ci]. Thus, the overall
expected running time of the algorithm is
BACKWARD ANALYSIS

 Let's see Intuitively how the average size of conflict list is O(n/i).
 Now let's think of the similar type of problem in 1D.
 Consider a set P of n points on the line, and a random sample R of i points from P. Let I be the partition
of the real line into open intervals by the endpoints of R that do not contain points of R in their interior.
 Probability that a point x belongs to R is (i/n).
 Expected number of points in an interval is n/i.
 Here, the expected number of points in the interval is of the same order as expected size of conflict list
for a trapezoid. So expected size of conflict list is O(n/i).
WHY RANDOMIZATION?
GENERAL SETTINGS

 Let S be a set of objects. For a subset R ⊆ S, we define a collection


of ‘regions’ called F(R) .
 Let T denote the set of all possible regions defined by subsets of S,
T = T(S) = ⋃R⊆SF(R) .
 Let a region σ ∈ T then we define two subsets D(σ), K(σ) ⊆ S.
 The defining set D(σ) of σ is a subset of S defining the region σ.
 We assume that for every σ ∈ T, |D(σ)| <= d, here d is referred as
combinatorial dimension.
 The killing set K(σ) of σ is the set of objects of S such that including
any object into R prevents σ from appearing in F(R).
GENERAL SETTINGS

 The weight of σ is size of killing set of σ w(σ) = |K(σ)|.


 For any σ ∈ F(R), it holds D(σ) ⊆ R and R∩K(σ)=∅.
 If D(σ) ⊆ R and K(σ)∩R = ∅, then σ ∈ F(R).
 For any r ∈ ℕ and a number t > 0, consider R ,a random sample of size r from S, and let’s denote F t(R) the set
of regions in F(R) which are t times heavier than the expected.
 #(r) is the expected number of regions in a structure created by r random objects.
 Similarly, #t(r) denotes the expected number of regions with weight t times more than the expected size n/r.
 Tt(r) denote the all the t-heavy regions which might be created by a random sample of size r.
GENERAL
SETTINGS

 LEMMA:
 Let r ≤ n and t be parameters, such that 1 ≤ t ≤ r/d.
Furthermore, let R be a sample of size r, R' be a sample
of size r' = ⌊r/t⌋, both from S. Let σ ∈ T be a trapezoid
with weight ω = ω(σ) ≥ t(n/r).
Then, Pr[σ ∈ F (R)] = O(td2-tPr[σ ∈ F(R')]).
CONTINUATION
GENERAL SETTINGS

 Lemma:
 Given a set S of n objects. Let r ≤ n and
t be parameters, such that 1 ≤ t ≤ r/d,
where d = max σ ∈ T(S)|D(σ)|.
we have,
#t(r) = O( td2−t #(⌊r/t⌋) ) = O( td2−t #(r) ).
GENERAL SETTINGS

 Theorem:
 Let R ⊆ S be a random subset of size r.
 Let #(r) = E[|F(R)|] and c ≥ 1 be an arbitrary constant.
Then,
E(∑σ∈F(R)(ω(σ))c) = O(#(r) * (n/r)c).
ANALYSING RIC ALGO
THANK YOU

You might also like