Visible Surface Algorithms, Convex Set Algorithms




CS216

Chris Pollett

Apr 20, 2010

Outline

Introduction

Area Subdivision

Z-Buffer Algorithms

Scan Line Algorithms

Quiz

Which of the following statements is true?

  1. The algorithms we learned for convexity testing were O(log n) in the number of vertices.
  2. Newell-Newell-Sancha depth sorting sorts objects with respect to a viewpoint.
  3. The BSP traversal part of the BSP depth sorting algorithm we gave does not depend of the viewpoint.

More Geometric Modeling Tools

Separability

Theorem. Let `vec p_1, vec p_2, \ldots, \vec p_s` and `vec q_1, vec q_2, \ldots, \vec q_t` be points in `mathbb{R}^n`. Let `X` and `Y` be the convex hulls respectively of the first and set set of points. Assume the hull of `S = \{ vec p_1, vec p_2, \ldots, \vec p_s, vec q_1, vec q_2, \ldots, \vec q_t \}`has dimension `n`. Then the following two statements are equivalent:

  1. The convex hull of `X` and `Y` are linearly separable.
  2. There are linearly independent vectors `vec r_1, vec r_2, \ldots, vec r_n` in S so that if `vec n` is any nonzero normal to the hyperplane `\{ \vec x| \vec x = \vec r_1 + a_2\vec r_2 +\cdots + a_n\vec r_n\}` they generate, then the intervals `vec n(X)` and `vec n(Y)` intersect in at most one point.

Proof of the Theorem

Convex Hulls

Theorem. Let `vec p_1, vec p_2, \ldots, \vec p_s` and `vec q` be points in `mathbb{R}^n`. Assume that the convex hull of `X` of `vec p_1, vec p_2, \ldots, \vec p_s` has dimension `n`. Then `vec q` is disjoint from `X` iff there is a subset `vec r_1, vec r_2, \ldots, vec r_n` of linearly independent points of `vec p_1, vec p_2, \ldots, \vec p_s` so that the hyperplane with these points separates `X` and `vec q`.

Definition. A point `vec v` is said to be a vertex or an extreme point of a convex set `C` if `vec v` does not belong to the interior of any segment whose endpoints lie in `C`.

Corollary Let `vec p_1, vec p_2, \ldots, \vec p_s` and `vec q` be points in `mathbb{R}^n`. Assume that the convex hull of `X` of `vec p_1, vec p_2, \ldots, \vec p_s` has dimension `n`. Let `Y` be the convex hull of `vec p_1, vec p_2, \ldots, \vec p_(s-1)`. Then `\vec p_s` is a vertex of `X` iff either:

  1. `Y` is (n-1)-dimensional, or
  2. there is a set of n linearly independent points in `vec p_1, vec p_2, \ldots, \vec p_s` whose hyperplane strictly separates `Y` and `vec p_s`.

Let `m=s+t`. The proofs of the theorems above give `O(m^(n+1))` algorithms for whether the intersection of convex hulls of `s` and `t` points intersect. i.e., choose a subset of size `n` and try to verify the condition of the theorem for that subset. One also gets an order `O(s^(n+1))` algorithm for deciding if a point is a vertex of a convex hull.