Summary of previous class - PowerPoint PPT Presentation

1 / 14
About This Presentation
Title:

Summary of previous class

Description:

Summary of previous class. Completeness for coNP co-SAT and Taut ... Can we use A and B as subroutines to get a Las Vegas algorithm for PRIMES? ... – PowerPoint PPT presentation

Number of Views:38
Avg rating:3.0/5.0
Slides: 15
Provided by: facultyR
Category:
Tags: alas | class | previous | summary

less

Transcript and Presenter's Notes

Title: Summary of previous class


1
Summary of previous class
  • Completeness for coNP co-SAT and Taut
  • Proof systems for SAT and super proof systems for
    SAT
  • Resolution soundness and completeness
  • Hard formulas for resolution
  • PTM definition use of random numbers
  • Probability of one trace and runtime
  • Class of Las Vegas algorithms - ZPP

2
Monte Carlo algorithms main direction
  • Bounded runtime but one sided-error algorithm
    never output 1 when x?L but may output 0 when
    x?L.
  • Define PTM M? RTIME(T(n)) if the following
    conditions hold
  • x?L ? Pr(M accepts x)?1/2 ? for some ?gt0
  • x?L ? Pr(M accepts x)0
  • TimeM(n) O(T(n))
  • One-sided Monte Carlo class (main direction)
    RPUcgt0RTIME(nc).

3
Independent Runs of Monte Carlo algorithm
  • Let a1, , ak be answers of independent runs of a
    Monte-Carlo algorithm A on x
  • If aiyes for some 1?i?k then we know with
    certainty that x?L
  • If a1 akno then the probability x?L is at
    most (1/2)k. So we decide that x?L. This is
    correct with probability at least
  • 1-(1/2)k.

4
Example of Monte Carlo Algorithms
  • Polynomial Identity Problem Given two
    polynomials P(x) and Q(x), does the identity P(x)
    ? Q(x) hold?
  • Example of instance
  • (x1)(x-2)(x3)(x-4)(x5)(x-6) ? x6-7x325

5
Algorithm for Polynomial Identity (PI)
  • Input PI polynomials P(x),Q(x)
  • Output PI accept if P(x)?Q(x) or reject
    otherwise
  • Pick a prime n s.t. ngtgt3d and n is bigger than
    all coefficients in G(x)P(x)-Q(x)
  • Choose a value a from Zn0,1,,n
  • Evaluate G(x/a) doing all computations mod n.
  • If G(x/a)?0 then output P(x)?Q(x) (accept) else
    output P(x)Q(x) (reject)

6
Analysis -Polynomial Identity
  • Accept polynomials are over the field Zn that
    are non-identical i.e. the language is
  • L(P(x), Q(x)) P(x), Q(x)?Znx and P(x)
    ?Q(x))
  • P(x), Q(x) are both of degree d. For
    G(x)P(x)-Q(x) either G(x) ? 0 or (G(x) ? 0).
  • If (G(x) ? 0) then G(X) has at most d roots.
  • Base if d0 then G(x) has 0 roots.
  • Induction step if a is the root of G(x) then
    ?R(x) of degree d-1 s.t. G(x)(x-a)R(x).
  • If P(x) ?Q(x) then (G(x) ? 0)
    Prob(G(x/a)0)?d/n so Prob(PI accpt P(x)?Q(x))1-
    Prob(G(x/a)0)?1-1/3
  • If P(x) ?Q(x) the algorithm never errs

7
Monte Carlo algorithms reverse direction
  • Bounded runtime but one sided-error algorithm
    may output 1 when x?L but never output 0 when
    x?L.
  • Define PTM M? coRTIME(T(n)) if the following
    conditions hold
  • x?L ? Pr(M accepts x)1
  • x?L ? Pr(M rejects x)? 1/2 ? for some ?gt0
  • TimeM(n) O(T(n))
  • One-sided Monte Carlo class (main direction)
    coRPUcgt0 coRTIME(nc) and coRPL L?RP

8
Monte Carlo and Las Vegas
  • Suppose we have
  • A one-sided error Monte Carlo algorithm for
    PRIMES main direction
  • no is always correct
  • yes is correct with small probability of error.
  • B one-sided error Monte Carlo algorithm for
    PRIMES reverse direction
  • yes is always correct
  • no is correct with small probability of error.
  • Can we use A and B as subroutines to get a Las
    Vegas algorithm for PRIMES?
  • Theorem ZPPRP?coRP (prove!)

9
Two-sided error algorithms
  • Bounded runtime but two sided-error algorithm
    may output 1 when x?L but may output 0 when x?L.
  • Define PTM M? BPTIME(T(n)) if the following
    conditions hold
  • Pr(M(x)L(x))?1/2 ? for some ?gt0, where we
    denote by L(x) value accept if x?L and reject
    if x?L
  • TimeM(n) O(T(n))
  • Class of two-sided error algorithms is defined as
    BPPUcgt0BPTIME(nc).

10
Example primality testing
  • Theorem 1 Let n?i1k qi?I be the factorization
    of a number that is not a prime or a prime power.
    Then the number of solutions of an equation x2a
    mod n is either 0 or 2k.
  • In particular, given a prime (or prime power) p
    then the an equation x2a mod p has either 0 or
    2 solutions.

11
Example primality-testing (continued)
  • Input a number p and a safety parameter s
  • Output prime or composite
  • If P either even or prime power return prime
  • Choose x?Zp uniformly at random
  • If gcd(x,p) ? 1 return composite
  • Compute a x2 mod p
  • V MSQRT(a,p,s)
  • If (Vfail) or (V2 ? x2 mod p) or (V?x,-x)
    then return composite else return prime

12
Example primality-testing (continued)
  • Here we use algorithm MSQRT(a,p,s) that solves
    the equation x2a mod p in polytime with
    probability of failure 2-s.
  • If p is prime then primality-test returns prime
    with probability 1-2-s (error when MSQRT fails)
  • If p is composite primality-test returns
    composite with probability gt1/2 MSQRT could
    output 2k values (theorem) so probability that it
    returned either x or x is at most (1-2s)2/2k.
    Since k?2 we have P(prime)lt1/2-?

13
Independent Runs of two-sided error algorithm
  • A randomized two-sided error algorithm deciding
    L with probability ½?
  • For an input x run t times A on x saving outputs
    a1,,at (take t odd)
  • If among a1,,at at least ?t/2? answers are
    accept then output accept otherwise output
    reject

14
Analysis of independent runs
  • Probability that A outputs incorrect answer
    (t-i)-out-of-t times (i.e i time correct) is

Therefore, due to the way algorithm chooses
answer
Write a Comment
User Comments (0)
About PowerShow.com