Data Structures Range Queries Space Efficiency Pooya Davoodi

  • Slides: 22
Download presentation
Data Structures: Range Queries - Space Efficiency Pooya Davoodi Aarhus University Ph. D Defense

Data Structures: Range Queries - Space Efficiency Pooya Davoodi Aarhus University Ph. D Defense July 4, 2011

Thesis Overview 25 12 14 4 § a c 6 76 18 98 8

Thesis Overview 25 12 14 4 § a c 6 76 18 98 8 31 79 45 20 7 5 12 43 23 6 4 10 17 84 11 65 62 10 38 7 9 8 58 13 5 40 25 46 4 2 3 10 b d e f 2

Range Minimum Queries § Database systems – Lowest average-salary: Year Age 1990 1995 2000

Range Minimum Queries § Database systems – Lowest average-salary: Year Age 1990 1995 2000 2005 2010 60 80, 000 85, 000 115, 000 120, 000 118, 000 50 81, 000 73, 000 90, 000 100, 000 94, 000 40 65, 000 75, 000 86, 000 92, 000 95, 000 30 72, 000 91, 000 89, 000 103, 000 102, 000 20 35, 000 42, 000 50, 000 41, 000 Minimum: 65, 000 at [3, 1] 3

Definition § 4

Definition § 4

Naïve Solution § 5

Naïve Solution § 5

Data Structures § Top-Left Bottom-Right Minimum 1 2 12 5 8 10 Tabulation (1,

Data Structures § Top-Left Bottom-Right Minimum 1 2 12 5 8 10 Tabulation (1, 1): 12 (1, 1) (1, 2): 8 (1, 1) (2, 1): 5 (1, 1) (2, 2) (2, 1): 5 (2, 1) (2, 2): 5 (1, 2): 8 (1, 2) (2, 2) (1, 2): 8 (2, 2): 10 6

Space-Efficient Data Structures Reference Tabulation Tarjan et al. (STOC’ 84) Chazelle & Rosenberg (So.

Space-Efficient Data Structures Reference Tabulation Tarjan et al. (STOC’ 84) Chazelle & Rosenberg (So. CG’ 89) Lewenstein et al. (CPM’ 07) Demaine et al. (ICALP’ 09) Sadakane (ISAAC’ 07) Our Result (ESA’ 10) Space (bits) Query Time - - 7

1 D vs. 2 D 2 § Lowest Common Ancestor 7 5 20 8

1 D vs. 2 D 2 § Lowest Common Ancestor 7 5 20 8 6 10 7 20 2 10 16 8 5 16 6 8

Indexing Data Structures § Popular in Succinct Data Structures Read-only Size of Input Index

Indexing Data Structures § Popular in Succinct Data Structures Read-only Size of Input Index Size of Index Query Time (Our Results, ESA’ 10) 9

 27 30 2 90 28 15 18 6 13 20 93 54 17

27 30 2 90 28 15 18 6 13 20 93 54 17 11 16 12 7 2 74 39 62 8 5 46 23 61 38 68 10 9 87 98 21 7 5 20 Cartesian Trees 8 6 16 10 7 20 2 10 8 5 16 6 Cartesian Tree: Tabulation Atallah and Yuan (SODA’ 10) 10

 § C 1 1 0 1 1 1 0 1 1 1 1

§ C 1 1 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 0 1 1 1 1 0 1 1 1 0 1 1 1 1 0 1 11

Outline § Range Minimum Queries 25 12 14 4 (ESA 2010, Invited to Algorithmica)

Outline § Range Minimum Queries 25 12 14 4 (ESA 2010, Invited to Algorithmica) § Path Minima Queries (WADS 2011) 6 76 18 98 8 31 79 45 20 7 5 12 43 23 6 4 10 17 84 11 65 62 10 38 4 42 7 9 8 58 6 3 13 5 40 25 10 § Range Diameter Queries (Submitted to ISAAC 2011) 12

Path Minima/Maxima Queries § The most expensive connection between two given nodes? – between

Path Minima/Maxima Queries § The most expensive connection between two given nodes? – between b and k = (c, e) i – between e and k = (j, k) 4 b 5 a 7 30 4 c 4 4 f d 6 e 2 g 3 h j 10 k Tree-Topology Networks § Update(c, e) = 4 Trees with Dynamic Weights 13

Naïve Structures § 5 a b 7 c 4 30 e i 6 4

Naïve Structures § 5 a b 7 c 4 30 e i 6 4 2 3 h g f 4 d j 10 k 30 4 14

Dynamic Weights Reference Query Time Update Time Tabulation Brute Force Search Comparison Based Sleator

Dynamic Weights Reference Query Time Update Time Tabulation Brute Force Search Comparison Based Sleator and Tarjan (STOC’ 81) Our Result (WADS’ 11) Optimal: Alstrup et al. (FOCS’ 98) Optimal: Brodal et al. (SWAT’ 96) Our Result (WADS’ 11) Optimal by conjecture: Optimal: Alstrup et al. (FOCS’ 98) Patrascu and Thorup (STOC’ 06) RAM § Reduction from Range Minimum Queries in 1 D arrays 15

Dynamic Leaves Query Time Reference Update Time Comment Alstrup and Holm (ICALP’ 00) and

Dynamic Leaves Query Time Reference Update Time Comment Alstrup and Holm (ICALP’ 00) and Kaplan and Shafrir (ESA’ 08) RAM Our Results (WADS’ 11) Comparison based Optimal: Pettie (FOCS’ 02) 5 a b 7 c 4 d 30 4 e i 6 4 2 3 h g f j 10 4 k 16

Updates with link and cut(c, e) link (d, i, 12) Reference 5 a b

Updates with link and cut(c, e) link (d, i, 12) Reference 5 a b 7 30 c 4 e 6 4 2 3 h g f 12 d Query Time 4 i Update Time j 10 k Comment Sleator and Tarjan (STOC’ 81) Comparison Based Our Results (WADS’ 11) Cell Probe Proof: by reduction from connectivity problems in graphs 17

Outline § Range Minimum Queries 25 12 14 4 (ESA 2010, Invited to Algorithmica)

Outline § Range Minimum Queries 25 12 14 4 (ESA 2010, Invited to Algorithmica) § Path Minima Queries (WADS 2011) 6 76 18 98 8 31 79 45 20 7 5 12 43 23 6 4 10 17 84 11 65 62 10 38 4 42 7 9 8 58 6 3 13 5 40 25 10 § Range Diameter Queries (Submitted to ISAAC 2011) 18

Range Diameter Queries § Farthest pair of points A Difficult Problem 19

Range Diameter Queries § Farthest pair of points A Difficult Problem 19

Known Results Reference Query Time Space Tabulation Smid et al. (CCCG’ 08) Our Results

Known Results Reference Query Time Space Tabulation Smid et al. (CCCG’ 08) Our Results (Submitted to ISAAC’ 11) Reduction from Set Intersection Problem Cohen and Porat (2010) Conjecture: Set Intersection problem is difficult (Patrascu and Roditty, FOCS’ 10) 20

Set Intersection Queries Reduction Diameter = 3 Diameter < 5 Arithmetic on real numbers

Set Intersection Queries Reduction Diameter = 3 Diameter < 5 Arithmetic on real numbers with unbounded precisions Reference Query Time Space Points in Convex Position Our Results (Submitted to ISAAC’ 11) 21

Publications § 25 12 14 4 12 43 23 6 a 8 31 79

Publications § 25 12 14 4 12 43 23 6 a 8 31 79 45 10 17 84 11 20 7 5 6 76 18 98 4 65 62 10 38 7 9 8 58 4 42 13 5 40 25 6 3 10 b c de f 22