Randomized Algorithms (Spring 2010)/Fingerprinting: Difference between revisions
Jump to navigation
Jump to search
imported>WikiSysop |
imported>WikiSysop |
||
Line 27: | Line 27: | ||
*pick <math>r_1, \ldots , r_n</math> independently and uniformly at random from a set <math>S</math>; | *pick <math>r_1, \ldots , r_n</math> independently and uniformly at random from a set <math>S</math>; | ||
*if <math>P_1(r_1, \ldots , r_n) = P_2(r_1, \ldots , r_n)</math> then return “yes” else return “no”; | *if <math>P_1(r_1, \ldots , r_n) = P_2(r_1, \ldots , r_n)</math> then return “yes” else return “no”; | ||
|} | |||
{|border="1" | |||
|'''Theorem (Schwartz-Zippel)''' | |||
: Let <math>Q(x_1,\ldots,x_n)</math> be a multivariate polynomial of degree <math>d</math> defined over a field <math>\mathbb{F}</math>. Fix any finite set <math>S\subset\mathbb{F}</math>, and let <math>r_1,\ldots,r_n</math> be chosen independently and uniformly at random from <math>S</math>. Then | |||
::<math>\Pr[Q(r_1,\ldots,r_n)=0\mid Q\not\equiv 0]\le\frac{d}{|S|}.</math> | |||
|} | |} | ||
Revision as of 13:06, 2 June 2010
Fingerprinting
Evaluating at random points
Example: Checking matrix multiplication
Consider the following problem:
- Given as the input three [math]\displaystyle{ n\times n }[/math] matrices [math]\displaystyle{ A,B }[/math] and [math]\displaystyle{ C }[/math],
- check whether [math]\displaystyle{ C=AB }[/math].
Algorithm (Freivalds)
|
If [math]\displaystyle{ AB=C }[/math] then [math]\displaystyle{ A(Br) = Cr }[/math] for any [math]\displaystyle{ r \in\{0, 1\}^n }[/math], thus the algorithm always returns "yes".
Lemma
|
Example: Checking polynomial identities
Algorithm (Schwartz-Zippel)
|
Theorem (Schwartz-Zippel)
|
Evaluating over a random field
Example: Identity checking
Example: Randomized pattern matching
Universal hashing
- Example: checking distinctness