A Space Optimal Streaming Algorithm for Sketching Small Moments - - PowerPoint PPT Presentation

a space optimal streaming algorithm for sketching small
SMART_READER_LITE
LIVE PREVIEW

A Space Optimal Streaming Algorithm for Sketching Small Moments - - PowerPoint PPT Presentation

Introduction F p Algorithm Lower Bounds Conclusion A Space Optimal Streaming Algorithm for Sketching Small Moments Daniel M. Kane Jelani Nelson David P. Woodruff Harvard MIT IBM Almaden December 18, 2009 Introduction F p Algorithm Lower


slide-1
SLIDE 1

Introduction Fp Algorithm Lower Bounds Conclusion

A Space Optimal Streaming Algorithm for Sketching Small Moments

Daniel M. Kane Jelani Nelson David P. Woodruff

Harvard MIT IBM Almaden

December 18, 2009

slide-2
SLIDE 2

Introduction Fp Algorithm Lower Bounds Conclusion

Streaming moments: problem formulation

Model

  • x = (x1, x2, . . . , xn) starts off as
  • m updates (i1, v1), (i2, v2), . . . , (im, vm)
  • Update (i, v) causes change xi ← xi + v
  • v ∈ {−M, . . . , M}
slide-3
SLIDE 3

Introduction Fp Algorithm Lower Bounds Conclusion

Streaming moments: problem formulation

Model

  • x = (x1, x2, . . . , xn) starts off as
  • m updates (i1, v1), (i2, v2), . . . , (im, vm)
  • Update (i, v) causes change xi ← xi + v
  • v ∈ {−M, . . . , M}

Goal: Output Fp

def

=

n

  • i=1

|xi|p = xp

p

slide-4
SLIDE 4

Introduction Fp Algorithm Lower Bounds Conclusion

Streaming moments: objectives

Objectives

  • Minimize space usage
  • Minimize update time

Trivial solutions

  • Keep x in memory:

O(n log(mM)) space / O(1) time

  • Keep stream in memory: O(m log(nM)) space / O(1) time

Goal: Get polylogarithmic dependence on n, m

slide-5
SLIDE 5

Introduction Fp Algorithm Lower Bounds Conclusion

Streaming moments: bad news

Alon, Matias, Szegedy ’99: No sublinear space algorithms without

  • Approximation (allow output to be (1 ± ε)Fp)
  • Randomization (allow 1% failure probability)

New goal: Output (1 ± ε)Fp with probability 99%

slide-6
SLIDE 6

Introduction Fp Algorithm Lower Bounds Conclusion

Streaming moments: bad news

Alon, Matias, Szegedy ’99: No sublinear space algorithms without

  • Approximation (allow output to be (1 ± ε)Fp)
  • Randomization (allow 1% failure probability)

New goal: Output (1 ± ε)Fp with probability 99% More bad news: Polynomial space required for p > 2 ([BJKS ’02] and [CKS ’03])

slide-7
SLIDE 7

Introduction Fp Algorithm Lower Bounds Conclusion

Streaming moments: bad news

Alon, Matias, Szegedy ’99: No sublinear space algorithms without

  • Approximation (allow output to be (1 ± ε)Fp)
  • Randomization (allow 1% failure probability)

New goal: Output (1 ± ε)Fp with probability 99% More bad news: Polynomial space required for p > 2 ([BJKS ’02] and [CKS ’03]) Newer goal: Output (1 ± ε)Fp with probability 99% for 0 ≤ p ≤ 2

slide-8
SLIDE 8

Introduction Fp Algorithm Lower Bounds Conclusion

Contributions (0 < p ≤ 2)

(Notation: N = min{n, m})

Ref Upper bound Lower bound Update time AMS’99 O(ε−2 log(mM)) (p=2) Ω(log N) O(1) (*) FKSV’99 (**) O(ε−2 log(mM)) (p=1) ———— O “ log(NM)

ε2

” Indyk’06, Li’08 O(ε−2 log(mM) log N) ———— O(ε−2) GC’07 O(ε−(2+p) log2(N) log(mM)) ———— polylog(mM) Woodruff’04 ———— Ω(ε−2) ———— This work O(ε−2 log(mM)) Ω(ε−2 log(mM)) ˜ O(ε−2)

(*) achieved by CCF’02, TZ’04, (**) L1-difference only

slide-9
SLIDE 9

Introduction Fp Algorithm Lower Bounds Conclusion

Fp (0 < p < 2) p-stable distributions

Definition (Zolotarev ’86)

For 0 < p ≤ 2, there exists a probability distribution Dp called the p-stable distribution such that if Q1, . . . , Qn ∼ Dp are independent, then n

i=1 Qixi ∼ xpDp.

(In short: Dp carries information about Lp norms)

slide-10
SLIDE 10

Introduction Fp Algorithm Lower Bounds Conclusion

Fp (0 < p < 2) p-stable distributions

Definition (Zolotarev ’86)

For 0 < p ≤ 2, there exists a probability distribution Dp called the p-stable distribution such that if Q1, . . . , Qn ∼ Dp are independent, then n

i=1 Qixi ∼ xpDp.

(In short: Dp carries information about Lp norms)

  • p = 2: Gaussian
  • p = 1: Cauchy
  • p = 1/2: L´

evy

slide-11
SLIDE 11

Introduction Fp Algorithm Lower Bounds Conclusion

Algorithms based on p-stable sketch matrices

A =    A1,1 · · · A1,n . . . ... . . . Ar,1 · · · Ar,n    , the Ai,j are i.i.d. from Dp, Maintain Ax = y

slide-12
SLIDE 12

Introduction Fp Algorithm Lower Bounds Conclusion

Algorithms based on p-stable sketch matrices

A =    A1,1 · · · A1,n . . . ... . . . Ar,1 · · · Ar,n    , the Ai,j are i.i.d. from Dp, Maintain Ax = y

  • Idea introduced by Indyk ’06
  • Indyk ’06: Estimate Fp as median{|yj|p}r

j=1

  • Li ’08: Estimate Fp as

Qr

j=1 |yj|p/r

[ 2

π Γ( p r )Γ(1− 1 r ) sin( π 2 · p r )] r

  • Both cases: r = Θ(1/ε2)
slide-13
SLIDE 13

Introduction Fp Algorithm Lower Bounds Conclusion

Too much randomness

  • In Indyk’06 and Li’08, Ω(n/ε2) bits needed to store matrix A
slide-14
SLIDE 14

Introduction Fp Algorithm Lower Bounds Conclusion

Too much randomness

  • In Indyk’06 and Li’08, Ω(n/ε2) bits needed to store matrix A
  • Indyk derandomized using Nisan’s pseudorandom generator

(but blowed up space)

slide-15
SLIDE 15

Introduction Fp Algorithm Lower Bounds Conclusion

Too much randomness

  • In Indyk’06 and Li’08, Ω(n/ε2) bits needed to store matrix A
  • Indyk derandomized using Nisan’s pseudorandom generator

(but blowed up space) Is there a more efficient derandomization?

slide-16
SLIDE 16

Introduction Fp Algorithm Lower Bounds Conclusion

Our Contributions

Yes, via k-wise independence!

  • For fixed i, make the Ai,j k-wise independent
  • Make the seeds used to generate rows of A pairwise

independent

slide-17
SLIDE 17

Introduction Fp Algorithm Lower Bounds Conclusion

Our Contributions

Yes, via k-wise independence!

  • For fixed i, make the Ai,j k-wise independent
  • Make the seeds used to generate rows of A pairwise

independent

  • k = ˜

Θ(1/εp) fools Indyk’s estimator

  • A different estimator works with

k = Θ(log(1/ε)/ log log(1/ε)).

slide-18
SLIDE 18

Introduction Fp Algorithm Lower Bounds Conclusion

Our Contributions

A different estimator (works with k = O(log(1/ε)/ log log(1/ε)))

  • 1. Maintain Ax = y and A′x = y′.
  • 2. A has k = Θ(log(1/ε)/ log log(1/ε)), r = Θ(1/ε2).
  • 3. A′ has k′, r′ = Θ(1).
  • 4. y′

med ← median{|y′ j |}r′ j=1.

  • 5. Output −y′p

med · ln

  • 1

r

r

j=1 cos

  • yj

y′

med

  • .
slide-19
SLIDE 19

Introduction Fp Algorithm Lower Bounds Conclusion

Analyzing median Fp algorithm (full independence)

An argument for the median: Define I[a,b](x) =

  • 1,

if x ∈ [a, b], 0,

  • therwise
  • Q =

i Qixi.

slide-20
SLIDE 20

Introduction Fp Algorithm Lower Bounds Conclusion

Analyzing median Fp algorithm (full independence)

An argument for the median: Define I[a,b](x) =

  • 1,

if x ∈ [a, b], 0,

  • therwise
  • Q =

i Qixi.

  • “median(|Q|/xp) = 1” means E[I[−1,1](Q/xp)] = 1/2.
slide-21
SLIDE 21

Introduction Fp Algorithm Lower Bounds Conclusion

Analyzing median Fp algorithm (full independence)

An argument for the median: Define I[a,b](x) =

  • 1,

if x ∈ [a, b], 0,

  • therwise
  • Q =

i Qixi.

  • “median(|Q|/xp) = 1” means E[I[−1,1](Q/xp)] = 1/2.
  • E[I[−1+ε,1−ε](Q/xp)] = 1/2 − Θ(ε)
  • E[I[−1−ε,1+ε](Q/xp)] = 1/2 + Θ(ε)
  • Take r = Θ(1/ε2) trials Q1, . . . , Qr. Number of counters

inside interval is concentrated by Chebyshev. ⇒ median of the |Qj| is (1 ± Θ(ε))xp with probability 2/3

slide-22
SLIDE 22

Introduction Fp Algorithm Lower Bounds Conclusion

Analyzing median Fp algorithm (k-wise independence)

One possible path

  • Replace I[a,b] with a well-approximating low-degree

polynomial.

  • k-wise independence fools polynomials.
slide-23
SLIDE 23

Introduction Fp Algorithm Lower Bounds Conclusion

Analyzing median Fp algorithm (k-wise independence)

One possible path

  • Replace I[a,b] with a well-approximating low-degree

polynomial.

  • k-wise independence fools polynomials.

What we actually do (for good reason)

  • Replace I[a,b] with a well-approximating smooth function ˜

I[a,b].

  • Show ˜

I[a,b] is fooled by k-wise independence via Taylor’s theorem.

slide-24
SLIDE 24

Introduction Fp Algorithm Lower Bounds Conclusion

Defining ˜ I[a,b] FT-mollification

Define b(x) =    e−

x2 1−x2

for |x| < 1

  • therwise

and ˜ I c

[a,b](x) = 1

2π(c · ˆ b(ct) ∗ I[a,b](t))(x)

slide-25
SLIDE 25

Introduction Fp Algorithm Lower Bounds Conclusion

Defining ˜ I[a,b] FT-mollification

Define b(x) =    e−

x2 1−x2

for |x| < 1

  • therwise

and ˜ I c

[a,b](x) = 1

2π(c · ˆ b(ct) ∗ I[a,b](t))(x) Then, for c > 1,

  • i. (˜

I c

[a,b])(ℓ)∞ = O(cℓ) for ℓ ≥ 0.

  • ii. For c = ˜

O(1/ε), |˜ I c

[a,b] − I[a,b]| < ε except potentially at a ± ε

and b ± ε.

slide-26
SLIDE 26

Introduction Fp Algorithm Lower Bounds Conclusion

Defining ˜ I[a,b] FT-mollification

Define b(x) =    e−

x2 1−x2

for |x| < 1

  • therwise

and ˜ I c

[a,b](x) = 1

2π(c · ˆ b(ct) ∗ I[a,b](t))(x) Then, for c > 1,

  • i. (˜

I c

[a,b])(ℓ)∞ = O(cℓ) for ℓ ≥ 0.

  • ii. For c = ˜

O(1/ε), |˜ I c

[a,b] − I[a,b]| < ε except potentially at a ± ε

and b ± ε. For c large, ˜ I c

[a,b] looks like I[a,b].

slide-27
SLIDE 27

Introduction Fp Algorithm Lower Bounds Conclusion

˜ I c

[−1,1] plots

x K 2 K 1 1 2 0.2 0.4 0.6 0.8 1.0

c = 5

x K 2 K 1 1 2 0.2 0.4 0.6 0.8 1.0

c = 9

x K 2 K 1 1 2 0.2 0.4 0.6 0.8 1.0

c = 13

x K 2 K 1 1 2 0.2 0.4 0.6 0.8 1.0

c = 17

slide-28
SLIDE 28

Introduction Fp Algorithm Lower Bounds Conclusion

Proof Outline

  • Let Ri be k-wise independent from Dp, and Qi be i.i.d.
  • Let R =

i Rixi and Q = i Qixi.

  • Suppose xp = 1.
slide-29
SLIDE 29

Introduction Fp Algorithm Lower Bounds Conclusion

Proof Outline

  • Let Ri be k-wise independent from Dp, and Qi be i.i.d.
  • Let R =

i Rixi and Q = i Qixi.

  • Suppose xp = 1.

Want: E[I[a,b](Q)] ≈ε E[I[a,b](R)]

slide-30
SLIDE 30

Introduction Fp Algorithm Lower Bounds Conclusion

Proof Outline

  • Let Ri be k-wise independent from Dp, and Qi be i.i.d.
  • Let R =

i Rixi and Q = i Qixi.

  • Suppose xp = 1.

Want: E[I[a,b](Q)] ≈ε E[I[a,b](R)] Proof: E[I[a,b](Q)] ≈ε E[˜ I c

[a,b](Q)] ≈ε E[˜

I c

[a,b](R)] ≈ε E[I[a,b](R)]

(1)→(2) ˜ I c well-approximates I except for two length-O(ε) strips. Use anticoncentration. (2)→(3) Main technical lemma. (3)→(4) Same as (1)→(2), but must prove anticoncentration.

slide-31
SLIDE 31

Introduction Fp Algorithm Lower Bounds Conclusion

Main technical lemma

Lemma

  • f (ℓ)(x)∞ = O(αℓ) for all ℓ ≥ 0
  • k = max{log(1/ε), αp}
  • Ri are Θ(k)-wise indep., Qi are fully indep., from Dp
  • R =

i Rixi, Q = i Qixi

  • xp = O(1)

⇒ |E[f (R)] − E[f (Q)]| < ε

slide-32
SLIDE 32

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy

  • Approximate f by a polynomial (Taylor-expand), and bound

expected difference using Taylor’s theorem, by analyzing moments E[X k

i ] and high-order derivatives of f

slide-33
SLIDE 33

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy

  • Approximate f by a polynomial (Taylor-expand), and bound

expected difference using Taylor’s theorem, by analyzing moments E[X k

i ] and high-order derivatives of f

  • Problem: Dp has infinite moments for p < 2
slide-34
SLIDE 34

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy (modified)

Linearity of expectation: E[f (R)] = E

  • A∈A

1A · f (R)

  • =
  • A∈A

E[1A · f (R)] where events in A partition probability space

slide-35
SLIDE 35

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy (modified)

Linearity of expectation: E[f (R)] = E

  • A∈A

1A · f (R)

  • =
  • A∈A

E[1A · f (R)] where events in A partition probability space What events should we consider?

slide-36
SLIDE 36

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy (modified)

Linearity of expectation: E[f (R)] = E

  • A∈A

1A · f (R)

  • =
  • A∈A

E[1A · f (R)] where events in A partition probability space What events should we consider? Truncation

slide-37
SLIDE 37

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy (modified)

Linearity of expectation: E[f (R)] = E

  • A∈A

1A · f (R)

  • =
  • A∈A

E[1A · f (R)] where events in A partition probability space What events should we consider? Truncation Define random variables: R′

i =

  • Ri,

|Rixi| ≤ λ 0,

  • therwise
slide-38
SLIDE 38

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy (modified)

R′

i =

  • Ri

|Rixi| ≤ λ

  • therwise

For S ⊆ [n], event 1S indicates that S is exactly the set of truncated R′

i

slide-39
SLIDE 39

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy (modified)

R′

i =

  • Ri

|Rixi| ≤ λ

  • therwise

For S ⊆ [n], event 1S indicates that S is exactly the set of truncated R′

i

E[f (R)] =

  • S⊆[n]

E [1S · f (R)] =

  • S⊆[n]

E

  • 1S · f
  • i∈S

Rixi +

  • i /

∈S

R′

i xi

slide-40
SLIDE 40

Introduction Fp Algorithm Lower Bounds Conclusion

Proof strategy (modified)

R′

i =

  • Ri

|Rixi| ≤ λ

  • therwise

For S ⊆ [n], event 1S indicates that S is exactly the set of truncated R′

i

E[f (R)] =

  • S⊆[n]

E [1S · f (R)] =

  • S⊆[n]

E

  • 1S · f
  • i∈S

Rixi +

  • i /

∈S

R′

i xi

  • Problem: How to reason about 1S using k-wise indep.?
slide-41
SLIDE 41

Introduction Fp Algorithm Lower Bounds Conclusion

Dealing with 1S

For S ⊆ [n], 1′

S indicates that S is a subset of the truncated R′ i

slide-42
SLIDE 42

Introduction Fp Algorithm Lower Bounds Conclusion

Dealing with 1S

For S ⊆ [n], 1′

S indicates that S is a subset of the truncated R′ i

Use inclusion-exclusion!

slide-43
SLIDE 43

Introduction Fp Algorithm Lower Bounds Conclusion

Dealing with 1S

For S ⊆ [n], 1′

S indicates that S is a subset of the truncated R′ i

Use inclusion-exclusion! 1S = 1′

S ·

  • i /

∈S

  • 1 − 1′

{i}

  • =
  • T⊆[n]\S

(−1)|T|1′

S∪T

slide-44
SLIDE 44

Introduction Fp Algorithm Lower Bounds Conclusion

Dealing with 1S

For S ⊆ [n], 1′

S indicates that S is a subset of the truncated R′ i

Use inclusion-exclusion! 1S = 1′

S ·

  • i /

∈S

  • 1 − 1′

{i}

  • =
  • T⊆[n]\S

(−1)|T|1′

S∪T

Now E[f (R)] =

  • S⊆[n]
  • T⊆[n]\S

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

slide-45
SLIDE 45

Introduction Fp Algorithm Lower Bounds Conclusion

Dealing with 1S

For S ⊆ [n], 1′

S indicates that S is a subset of the truncated R′ i

Use inclusion-exclusion! 1S = 1′

S ·

  • i /

∈S

  • 1 − 1′

{i}

  • =
  • T⊆[n]\S

(−1)|T|1′

S∪T

Now E[f (R)] =

  • S⊆[n]
  • T⊆[n]\S

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

  • Still a problem: How to deal with large S, T?
slide-46
SLIDE 46

Introduction Fp Algorithm Lower Bounds Conclusion

Approximate Inclusion-Exclusion

Introduced to streaming by Bar-Yossef et al. ’02 (analyzed balls and bins with limited independence)

slide-47
SLIDE 47

Introduction Fp Algorithm Lower Bounds Conclusion

Approximate Inclusion-Exclusion

Introduced to streaming by Bar-Yossef et al. ’02 (analyzed balls and bins with limited independence) E[f (R)] =

  • S⊆[n]
  • T⊆[n]\S

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

slide-48
SLIDE 48

Introduction Fp Algorithm Lower Bounds Conclusion

Approximate Inclusion-Exclusion

Introduced to streaming by Bar-Yossef et al. ’02 (analyzed balls and bins with limited independence) E[f (R)] =

  • S⊆[n]
  • T⊆[n]\S

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

  • ?

  • S⊆[n]

|S|≤Ck

  • T⊆[n]\S

|T|≤Ck

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

slide-49
SLIDE 49

Introduction Fp Algorithm Lower Bounds Conclusion

Approximate Inclusion-Exclusion

Introduced to streaming by Bar-Yossef et al. ’02 (analyzed balls and bins with limited independence) E[f (R)] =

  • S⊆[n]
  • T⊆[n]\S

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

  • S⊆[n]

|S|≤Ck

  • T⊆[n]\S

|T|≤Ck

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

slide-50
SLIDE 50

Introduction Fp Algorithm Lower Bounds Conclusion

Approximate Inclusion-Exclusion

Introduced to streaming by Bar-Yossef et al. ’02 (analyzed balls and bins with limited independence) E[f (R)] =

  • S⊆[n]
  • T⊆[n]\S

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

  • S⊆[n]

|S|≤Ck

  • T⊆[n]\S

|T|≤Ck

(−1)|T|E

  • 1′

S∪T · f

  • i∈S

Rixi +

  • i /

∈S

R′

i xi

  • E[f (R)]

≈ε E[F( R)] ≈ε X

S,T⊆[n] |S|,|T|≤Ck S∩T=∅

(−1)|T|E

Ri i∈S∪T

2 41′

S∪T · E

2 4pk,Ri @ X

i / ∈S∪T

R′

i xi

1 A 3 5 3 5 = X

S,T⊆[n] |S|,|T|≤Ck S∩T=∅

(−1)|T|E

Qi i∈S∪T

2 41′

S∪T · E

2 4pk,Qi @ X

i / ∈S∪T

Q′

i xi

1 A 3 5 3 5 ≈ε E[F( Q)] ≈ε E[f (Q)]

slide-51
SLIDE 51

Introduction Fp Algorithm Lower Bounds Conclusion

Proof Outline

  • Let Ri be k-wise independent from Dp, and Qi be i.i.d.
  • Let R =

i Rixi and Q = i Qixi.

  • Suppose xp = 1.

Want: E[I[a,b](Q)] ≈ε E[I[a,b](R)] Proof: E[I[a,b](Q)] ≈ε E[˜ I c

[a,b](Q)] ≈ε E[˜

I c

[a,b](R)] ≈ε E[I[a,b](R)]

(1)→(2) ˜ I c well-approximates I except for two length-O(ε) strips. Use anticoncentration. (2)→(3) Main technical lemma. (3)→(4) Same as (1)→(2), but must prove anticoncentration.

slide-52
SLIDE 52

Introduction Fp Algorithm Lower Bounds Conclusion

Anticoncentration of R

x K 3 K 2 K 1 1 2 3 0.1 0.2 0.3 0.4 0.5 0.6

slide-53
SLIDE 53

Introduction Fp Algorithm Lower Bounds Conclusion

Anticoncentration of R

x K 3 K 2 K 1 1 2 3 0.1 0.2 0.3 0.4 0.5 0.6

  • f (ℓ)∞ = O(1/ε)ℓ

⇒ fooled with k = O(1/εp)

  • Easy to show E[f (Q)] = O(ε)
  • ⇒ E[f (R)] = O(ε) by main technical

lemma

  • ⇒ anticoncentration in interval [−ε, ε]

Shift f to show anticoncentration in any width-O(ε) interval.

slide-54
SLIDE 54

Introduction Fp Algorithm Lower Bounds Conclusion

Anticoncentration of R

x K 3 K 2 K 1 1 2 3 0.1 0.2 0.3 0.4 0.5 0.6

f (x) = − x/ε

−∞

sin4(y) y3 dy

  • f (ℓ)∞ = O(1/ε)ℓ

⇒ fooled with k = O(1/εp)

  • Easy to show E[f (Q)] = O(ε)
  • ⇒ E[f (R)] = O(ε) by main technical

lemma

  • ⇒ anticoncentration in interval [−ε, ε]

Shift f to show anticoncentration in any width-O(ε) interval.

slide-55
SLIDE 55

Introduction Fp Algorithm Lower Bounds Conclusion

Intuition for the new estimator

Our new estimator’s final step: “Let y′

median = median{|y′ j |}r′ j=1.

Output −y′p

median · ln

  • 1

r

r

j=1 cos

  • yj

y′

median

  • .”
slide-56
SLIDE 56

Introduction Fp Algorithm Lower Bounds Conclusion

Intuition for the new estimator

Our new estimator’s final step: “Let y′

median = median{|y′ j |}r′ j=1.

Output −y′p

median · ln

  • 1

r

r

j=1 cos

  • yj

y′

median

  • .”
  • We know y′

median = Θ(xp).

  • Apply main technical lemma with f (x) = cos(x) to refine

y′

median to a (1 ± ε)-approximation.

slide-57
SLIDE 57

Introduction Fp Algorithm Lower Bounds Conclusion

Correcting to (1 ± ε)-approximation

Z ∼ Dp E[cos(BZ)] = E eiBZ + e−iBZ 2

  • Can look at Fourier transform of pdf of Dp to show

E[cos(BZ)] = e−|B|p

slide-58
SLIDE 58

Introduction Fp Algorithm Lower Bounds Conclusion

Correcting to (1 ± ε)-approximation

Z ∼ Dp E[cos(BZ)] = E eiBZ + e−iBZ 2

  • Can look at Fourier transform of pdf of Dp to show

E[cos(BZ)] = e−|B|p

  • Apply technical lemma to f
  • yj

y′

median

  • with f (x) = cos(x)
  • Use Chebyshev’s inequality
slide-59
SLIDE 59

Introduction Fp Algorithm Lower Bounds Conclusion

Lower bounds

Streaming lower bounds via communication complexity Alice Bob x ∈ X y ∈ Y

  • Alice, Bob know f : X × Y → {0, 1}
  • Bob needs to compute f (x, y)
  • Communication lower bounds ⇒ streaming space lower

bounds (Alon, Matias, Szegedy ’99)

slide-60
SLIDE 60

Introduction Fp Algorithm Lower Bounds Conclusion

Previous Fp lower bound

Woodruff ’04 and Jayram, Kumar, Sivakumar ’08

Indexing

  • X = {0, 1}t, Y = {1, . . . , t}
  • f (x, y) = xy
slide-61
SLIDE 61

Introduction Fp Algorithm Lower Bounds Conclusion

Previous Fp lower bound

Woodruff ’04 and Jayram, Kumar, Sivakumar ’08

Indexing

  • X = {0, 1}t, Y = {1, . . . , t}
  • f (x, y) = xy

Gap-Hamming

  • X = {0, 1}t′, Y = {0, 1}t′
  • f (x, y) =
  • 1

∆(x, y) ≥ t′

2 +

√ t′ ∆(x, y) ≤ t′

2 −

√ t′

slide-62
SLIDE 62

Introduction Fp Algorithm Lower Bounds Conclusion

Previous Fp lower bound

Woodruff ’04 and Jayram, Kumar, Sivakumar ’08

Indexing

  • X = {0, 1}t, Y = {1, . . . , t}
  • f (x, y) = xy

Gap-Hamming

  • X = {0, 1}t′, Y = {0, 1}t′
  • f (x, y) =
  • 1

∆(x, y) ≥ t′

2 +

√ t′ ∆(x, y) ≤ t′

2 −

√ t′ Indexing

JKS′08

− − − − → Gap-Hamming Woodruff′04 − − − − − − → Fp Led to Ω(min{N, ε−2}) lower bound for Fp

slide-63
SLIDE 63

Introduction Fp Algorithm Lower Bounds Conclusion

The new Fp lower bound

Augmented-Indexing

  • X = {0, 1}t, Y = {1, . . . , t}
  • Bob also gets xi for i > y
  • f (x, y) = xy

Requires Ω(t) communication (MNSW ’98)

slide-64
SLIDE 64

Introduction Fp Algorithm Lower Bounds Conclusion

An F1 lower bound

Theorem

(1 ± ε)-approximation of F1 requires Ω(min{N, ε−2 log M}) space

Proof.

1/ε2 coordinates t = min{ε2N, log M} blocks

Alice:

slide-65
SLIDE 65

Introduction Fp Algorithm Lower Bounds Conclusion

An F1 lower bound

Theorem

(1 ± ε)-approximation of F1 requires Ω(min{N, ε−2 log M}) space

Proof.

1/ε2 coordinates t = min{ε2N, log M} blocks

Alice: Bob:

y

slide-66
SLIDE 66

Introduction Fp Algorithm Lower Bounds Conclusion

An F1 lower bound

Step 1:

1/ε2 coordinates t = min{ε2N, log M} blocks

Alice: Bob:

y

Step 2:

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Bob: Alice:

... y

slide-67
SLIDE 67

Introduction Fp Algorithm Lower Bounds Conclusion

An F1 lower bound

Step 1:

1/ε2 coordinates t = min{ε2N, log M} blocks

Alice: Bob:

y

Step 2:

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Bob: Alice:

... y

Step 3: For ith Gap-Ham vector zi, if zi,j = 1 Alice puts ((i, j), 2i) in stream

slide-68
SLIDE 68

Introduction Fp Algorithm Lower Bounds Conclusion

An F1 lower bound

Step 1:

1/ε2 coordinates t = min{ε2N, log M} blocks

Alice: Bob:

y

Step 2:

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Bob: Alice:

... y

Step 3: For ith Gap-Ham vector zi, if zi,j = 1 Alice puts ((i, j), 2i) in stream Step 4: Alice sends algorithm state + weight of each block

slide-69
SLIDE 69

Introduction Fp Algorithm Lower Bounds Conclusion

An F1 lower bound

Step 1:

1/ε2 coordinates t = min{ε2N, log M} blocks

Alice: Bob:

y

Step 2:

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Gap-Ham JKS ’08

Θ(1/ε2)

Gap-Ham JKS ’08 Indexing

Θ(1/ε2)

Bob: Alice:

... y

Step 3: For ith Gap-Ham vector zi, if zi,j = 1 Alice puts ((i, j), 2i) in stream Step 4: Alice sends algorithm state + weight of each block Step 5: Bob deletes contribution of blocks larger than his own

slide-70
SLIDE 70

Introduction Fp Algorithm Lower Bounds Conclusion

Open problems

  • Fp in optimal space with O(1) update time?
  • Find other applications for FT-mollification.
slide-71
SLIDE 71

Introduction Fp Algorithm Lower Bounds Conclusion

Open problems (some progress)

  • Fp in optimal space with O(1) update time?

[N., Woodruff] p = 1 with ε−2 logO(1)(nmM) space, logO(1)(nmM) update time

  • Find other applications for FT-mollification.

[Kane, N., Woodruff] FT-mollification actually gives an alternative proof that bounded independence fools regular halfspaces ([DGJ+09]). [Diakonikolas, Kane, N.] Showed bounded independence fools degree-2 threshold functions, via FT-mollification.

slide-72
SLIDE 72

Introduction Fp Algorithm Lower Bounds Conclusion

Other news announcements

[Kane, N., Woodruff]: Optimal distinct elements algorithm.

  • O(ε−2 + log(n)) bits of space
  • O(1) worst-case update and reporting times
slide-73
SLIDE 73

Introduction Fp Algorithm Lower Bounds Conclusion

Fooling regular halfspaces

  • Ha,θ = {x : a, x ≥ θ} (a halfspace).
  • Theorem [DGJ+09]: Pr[x ∈ Ha,θ] ≈ε Pr[y ∈ Ha,θ] for

k = ˜ O(1/ε2). xi are i.i.d., yi are k-wise independent.

  • The [DGJ+09] proof outline:
  • 1. Reduce to case when |ai| ≤ ε for all i
  • 2. Show the theorem in the case when every |ai| ≤ ε (the

“regular” case)

slide-74
SLIDE 74

Introduction Fp Algorithm Lower Bounds Conclusion

Fooling regular halfspaces

  • Ha,θ = {x : a, x ≥ θ} (a halfspace).
  • Theorem [DGJ+09]: Pr[x ∈ Ha,θ] ≈ε Pr[y ∈ Ha,θ] for

k = ˜ O(1/ε2). xi are i.i.d., yi are k-wise independent.

  • The [DGJ+09] proof outline:
  • 1. Reduce to case when |ai| ≤ ε for all i
  • 2. Show the theorem in the case when every |ai| ≤ ε (the

“regular” case)

  • Proof of 2 via FT-mollification:

E[I[θ,∞)(a, x)] ≈ε E[˜ I c

[θ,∞)(a, x)] ≈ε E[˜

I c

[θ,∞)(a, y)] ≈ε

E[I[θ,∞)(a, y)].

slide-75
SLIDE 75

Introduction Fp Algorithm Lower Bounds Conclusion

Fooling degree-2 threshold functions

Statement: E[sign(p(x))] ≈ε E[sign(p(y))] for k = poly(1/ε), p a degree-2 polynomial.

slide-76
SLIDE 76

Introduction Fp Algorithm Lower Bounds Conclusion

Fooling degree-2 threshold functions

Statement: E[sign(p(x))] ≈ε E[sign(p(y))] for k = poly(1/ε), p a degree-2 polynomial.

  • Some savings in the known applications: (1) Ω(1/εp)-wise

independence fools Indyk’s estimator, (2) Ω(1/ε2)-wise independence ε-fools regular halfspaces (no more logs).

  • A new statement: Bounded independence fools

Goemans-Williamson hyperplane rounding.

slide-77
SLIDE 77

Introduction Fp Algorithm Lower Bounds Conclusion

Fooling degree-2 threshold functions

Statement: E[sign(p(x))] ≈ε E[sign(p(y))] for k = poly(1/ε), p a degree-2 polynomial.

  • Some savings in the known applications: (1) Ω(1/εp)-wise

independence fools Indyk’s estimator, (2) Ω(1/ε2)-wise independence ε-fools regular halfspaces (no more logs).

  • A new statement: Bounded independence fools

Goemans-Williamson hyperplane rounding.

  • Idea of proof:
  • 1. p = p1 − p2 + p3 + p4 + C, p1, p2 pos. semidef. with no small

non-zero eigenvalues, p3 indefinite with only small eigenvalues, p4 a linear form, C a constant.

  • 2. Let ∆ be the trace of the symmetric matrix associated with p3.
  • 3. Define R ⊆ R4 by R = {z : z2

1 − z2 2 + z3 + z4 + ∆ + C > 0}.

  • 4. E[IR(M(x))] ≈ε E[˜

I c

R(M(x))] ≈ε E[˜

I c

R(M(y))] ≈ε E[IR(M(y))]

for M(z) = (

  • p1(z),
  • p2(z), p3(z) − ∆, p4(z)).