REVISION AND PRACTICE

Extension: completing the JL proof

5 min read
On this page 15 headings

Learning goal: Turn a one-vector error bound into a guarantee for all point pairs.

Goal: make a large projection error unlikely

  • Start with k independent standard normal coordinates.
  • Their squared values add up to a random total S. Its expected value is k.
  • We want the chance of S being much larger or smaller than k to be small. Assume 0<ε<10 < \varepsilon < 1.
S=∥x∥2=∑i=1kxi2E[S]=k\begin{aligned}S&=\|x\|^2=\sum_{i=1}^{k}x_i^2\\\mathbb{E}[S]&=k\end{aligned}

Step A: get an upper-tail bound

1. See why plain Markov is too weak

Applying Markov directly gives:

P ⁣(S≥k(1+ε))≤E[S]k(1+ε)=11+ε\begin{aligned}&\mathbb{P}\!\left(S\ge k(1+\varepsilon)\right)\\&\le\frac{\mathbb{E}[S]}{k(1+\varepsilon)}\\&=\frac{1}{1+\varepsilon}\end{aligned}
  • For ε=0.1\varepsilon = 0.1, this upper bound is about 0.91.
  • That allows up to a 91% failure probability, so it is too weak for a useful accuracy guarantee.
  • It also does not improve as k increases.

2. Exponentiate before applying Markov

  • Choose a positive number λ smaller than 12\frac{1}{2}.
  • The exponential function is increasing. Transforming both sides preserves the event.
S≥k(1+ε)⟺eλS≥eλk(1+ε)\begin{aligned}&S\ge k(1+\varepsilon)\quad\\&\Longleftrightarrow\quad e^{\lambda S}\ge e^{\lambda k(1+\varepsilon)}\end{aligned}

Now apply Markov to the positive exponential random variable:

P ⁣(S≥k(1+ε))≤E[eλS]eλk(1+ε)\begin{aligned}&\mathbb{P}\!\left(S\ge k(1+\varepsilon)\right)\\&\le\frac{\mathbb{E}[e^{\lambda S}]}{e^{\lambda k(1+\varepsilon)}}\end{aligned}

3. Use independence to split the expectation

  • S is a sum of independent squared coordinates.
  • The exponential of a sum is a product. Independence lets us multiply the expectations.
E[eλS]=∏i=1kE[eλxi2]\mathbb{E}[e^{\lambda S}]=\prod_{i=1}^{k}\mathbb{E}[e^{\lambda x_i^2}]

4. Use the standard Gaussian identity

For a standard normal random variable Z and λ <12< \frac{1}{2}:

E[eλZ2]=(1−2λ)−1/2\mathbb{E}[e^{\lambda Z^2}]=(1-2\lambda)^{-1/2}

There are k identical factors, so the bound becomes:

P ⁣(S≥k(1+ε))≤e−λk(1+ε)(1−2λ)−k/2\begin{aligned}&\mathbb{P}\!\left(S\ge k(1+\varepsilon)\right)\\&\le e^{-\lambda k(1+\varepsilon)}(1-2\lambda)^{-k/2}\end{aligned}

5. Choose λ to tighten the bound

Minimizing the preceding expression gives:

λ=ε2(1+ε)\lambda=\frac{\varepsilon}{2(1+\varepsilon)}

Substitute this value:

P ⁣(S≥k(1+ε))≤((1+ε)e−ε)k/2\begin{aligned}&\mathbb{P}\!\left(S\ge k(1+\varepsilon)\right)\\&\le\left((1+\varepsilon)e^{-\varepsilon}\right)^{k/2}\end{aligned}

6. Put the result into a convenient form

The logarithm inequality below gives a simpler, slightly looser bound:

ln⁡(1+ε)≤ε−ε22+ε33\ln(1+\varepsilon)\le\varepsilon-\frac{\varepsilon^2}{2}+\frac{\varepsilon^3}{3}
P ⁣(S≥k(1+ε))≤exp⁡ ⁣(−k(ε2−ε3)4)\begin{aligned}&\mathbb{P}\!\left(S\ge k(1+\varepsilon)\right)\\&\le\exp\!\left(-\frac{k(\varepsilon^2-\varepsilon^3)}{4}\right)\end{aligned}
  • For a fixed ε\varepsilon between 0 and 1, the failure bound falls exponentially as k grows.
  • This is the improvement that plain Markov could not give.

7. Control the lower tail too

Applying the exponential method to the lower tail gives:

P ⁣(S≤k(1−ε))≤exp⁡ ⁣(−kε24)\begin{aligned}&\mathbb{P}\!\left(S\le k(1-\varepsilon)\right)\\&\le\exp\!\left(-\frac{k\varepsilon^2}{4}\right)\end{aligned}

This controls a projection that is too small. The preceding upper-tail bound controls one that is too large.

Exact chi-square tail vs exponential bound as k grows
ε = 0.1. The exact chance of the bad event (blue) and our bound (orange) both fall exponentially in k. The bound is safe, though loose by a constant factor.

Worked example

  • k = 1,000, ε = 0.1: bound .
  • The exact value is 0.0146, so the bound holds.
  • At k = 2,000 the bound is 0.011 and the exact value is 0.0011.

Step B: one pair fails rarely

  • For one pair (x, y), take u = x − y.
  • The pair is distorted by more than ε (too big or too small) with probability at most .

Step C: union bound over all pairs, which is where log⁡n\log n comes from

  • There are pairs.
  • By the union bound (Lesson 5),

This is less than 1 as soon as

  • A failure probability below 1 means a good map exists, which is exactly what JL claims.
  • If you want it to work with high probability in practice, use, for example, ; then the failure chance is at most .

Worked example: dimension requirements with explicit constants

  • n = 10⁶, ε = 0.1: .
  • As noted in Lesson 6, that exceeds d = 10,000.
  • With d = 10⁶ (and ε = 0.2: k ≈ 3,450) the reduction is dramatic.

Does it really work? A simulation

  • 200 random points in d = 10,000 dimensions, giving 19,900 pairs.
  • We project with and compare every squared distance before and after.
Scatter of distances before vs after, and histogram of distortions for k=500 and k=3000
Left: with k = 3,000, all 19,900 pairs land inside the ±10 % lines (distortion range 0.905–1.090). Right: with k = 500, 1,973 pairs (about 10 %) fall outside ±10 % (range 0.77–1.26). With k = 3,000, none do.
How to interpret the simulation
  • In this run, k = 3,000 preserved all pairwise squared distances within the tolerance.
  • The existence bound requires about 4,710 dimensions for these parameters.
  • The stronger high-probability version requires about 7,060 dimensions.
  • A particular dataset can succeed with fewer dimensions than a worst-case guarantee requires.

Key points to remember

  • Exponentiate before applying Markov to obtain a useful tail bound.
  • Control both tails, then use the union bound across all pairs.
  • More target dimensions reduce the risk; stronger accuracy requires more dimensions.
YOUR STUDY PROGRESS

Finished this section? Save your progress.

Back to top ↑