Two Glass Balls and a Tower - PowerPoint PPT Presentation

1 / 15
About This Presentation
Title:

Two Glass Balls and a Tower

Description:

Oren Kapah. KABLOOIE!!! Given: A glass ball. An n storied building. Find: The floor k such that the ball breaks when dropped from it, but does not ... – PowerPoint PPT presentation

Number of Views:37
Avg rating:3.0/5.0
Slides: 16
Provided by: criHa
Category:
Tags: balls | glass | oren | tower | two

less

Transcript and Presenter's Notes

Title: Two Glass Balls and a Tower


1
Two Glass Balls and a Tower
Amihood Amir
Bar Ilan University And Georgia Tech
Gadis office
Costas Iliopoulos
Oren Kapah
2
Given A glass ball. An n storied
building. Find The floor k such that the
ball breaks when dropped from it, but does not
break if dropped from floor k-1.
KABLOOIE!!!
3
STRATEGY 1 Only one ball given to
experiment with.
O(n) experiments necessary. Sequential search.
4
STRATEGY 2 As many balls as necessary are
given to experiment with.
O(log n) experiments necessary. Binary search.
5
STRATEGY 3 Only two balls given to
experiment with.
O( ) experiments necessary. Bounded
divide-and-conquer
Experiments 1st ball
Experiments 2nd ball
6
Meaning of two Balls
  • Bounded Divide-and-Conquer.

In reality Different paradigms. 1. Works on
large groups. 2. Works within a group.
7
In Pattern Matching
  • Works on large groups
  • Convolutions

O(n log m) using FFT
8
Problem O(n log m) only in algebraically closed
fields, e.g. C.
Solution Reduce problem to (Boolean/integer/real)
multiplication.
This reduction costs!
Example Hamming distance.
Counting mismatches is equivalent to Counting
matches
9
Example
Count all hits of 1 in pattern and 1 in text.
10
(No Transcript)
11
(No Transcript)
12
So for alphabet with a symbols (a fixed) the time
is O(n a log m) O(n log m) Problem Infinite
alphabets.
13
Without loss of generality S m 1 Since
every element of T not in P is replaced by some
symbol x not in P.
14
Divide and Conquer Idea (Wrong)
Split S to S1 U S2 of size m/2 each. Construct
T1, P1 and T2, P2. Where for S T,
P and e 1, 2
15
The Algorithm
Write a Comment
User Comments (0)
About PowerShow.com