Computability and Complexity
-
Upload
duncan-brewer -
Category
Documents
-
view
24 -
download
2
description
Transcript of Computability and Complexity
![Page 1: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/1.jpg)
Computability and Complexity 26-1
Computability and ComplexityAndrei Bulatov
Probabilistic Algorithms
![Page 2: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/2.jpg)
Computability and Complexity 26-2
Non-Deterministic vs. Probabilistic
All algorithms we nave seen so far are either deterministic or impractical (non-deterministic)
To make non-deterministic algorithms more practical we introduce probabilistic algorithms
A probabilistic algorithm (Turing Machine) is a non-deterministic algorithm that makes non-deterministic choices randomly, e.g. by flipping a coin
This is still not practical, because sometimes the algorithm should be extremely lucky to solve problems
![Page 3: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/3.jpg)
Computability and Complexity 26-3
Interactive Proofs
Prover Verifier
Has unlimited computational power
Can perform polynomial timecomputations
They can exchange massages
Wants to convince Verifier in something
Accepts or rejects afterperforming some computation
![Page 4: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/4.jpg)
Computability and Complexity 26-4
Proofs for Problems in NP
SAT
Prover and Verifier get an instance of SAT
Prover solves the instance using his unlimited computational power and send a satisfying assignment to Verifier
Verifier checks (in polynomial time) if what obtained is a satisfying assignment, and accepts if it is or rejects otherwise
![Page 5: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/5.jpg)
Computability and Complexity 26-5
Problems from coNP
Instance: Graphs G and H.
Question: Are G and H isomorphic?
Graph Non-Isomorphism
This problem belongs to coNP, but is not believed to be coNP-complete
Apparently, there no way to prove interactively that two graphs are not isomorphic
![Page 6: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/6.jpg)
Computability and Complexity 26-6
Randomized Verifier
Now suppose that Verifier has a fair coin
Given graphs G and H
• Verifier chooses one of G and H by flipping a coin
• Verifier then renames somehow the vertices of the chosen graph and send it to Prover
• Prover decides which graph it received
• Prover send the answer to Verifier
• Repeat the procedure
![Page 7: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/7.jpg)
Computability and Complexity 26-7
Analysis
If the graphs are not isomorphic then Prover always gives the right answer
If the graphs are isomorphic then Prover gives a correct answer with probability 1/2
Therefore if Prover is wrong we conclude that the graphs are isomorphic
If after n repetitions of the protocol, Prover gives only right answers,
then Verifier can conclude with probability that graphs are not isomorphic
n21
![Page 8: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/8.jpg)
Computability and Complexity 26-8
Probabilistic Turing Machines
Definition A Probabilistic Turing Machine is a nondeterministic polynomial time Turing Machine PT such that
• from each configuration of PT, there are at most two possible next configurations
• PT chooses which of the two possible next configurations to take by flipping a fair coin
Thus, with each computational path, we can associate the probability of taking this path. This probability is equal to where k is the number of coin flips made along this path
k21
Denote this probability by Pr[p]
![Page 9: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/9.jpg)
Computability and Complexity 26-9
Define the probability that PT accepts w to be
path accepting an is
accepts p
pwPT ]Pr[]Pr[
Clearly ]Pr[1]Pr[ wPTwPT accepts rejects
![Page 10: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/10.jpg)
Computability and Complexity 26-10
Class BPP
Definition A Probabilistic Turing Machine PT recognizes language L with error probability if
• w L implies Pr[PT accepts w] 1 –
• w L implies Pr[PT rejects w] 1 –
Definition BPP is the class of languages that are recognizable by probabilistic Turing Machines with error probability of 1/3
We say that PT operates with error probability if the above inequalities hold for where n is the length of w
)(2 nf
)(2 nf
![Page 11: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/11.jpg)
Computability and Complexity 26-11
Amplification
The error probability 1/3 may seem random
Actually, we can choose any value 0 1
Amplification Lemma Let 0 1. Then for any polynomial p(n) and a probabilistic TM that operates with error probability , there is a probabilistic TM that operates with an error probability
Amplification Lemma Let 0 1. Then for any polynomial p(n) and a probabilistic TM that operates with error probability , there is a probabilistic TM that operates with an error probability
1PT
2PT)(2 np
The main idea is to run many times and then output the majority of votes
1PT
![Page 12: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/12.jpg)
Computability and Complexity 26-12
Math Prerequisites
Let be a series of independent experiments (for example, coin flips) such that the probability of success in each of them is p
nXXX ,,, 21
Theorem (Chernoff Bound)
If for some , then the probability that the
number of successes in a series of n experiments is less than
is at most
Theorem (Chernoff Bound)
If for some , then the probability that the
number of successes in a series of n experiments is less than
is at most
21
p
2n 6
2n
e
![Page 13: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/13.jpg)
Computability and Complexity 26-13
Proof of Amplification Lemma
Machine works as follows2PT
On input w
• for i = 1 to t(|w|) do
- simulate on w1PT
• if most runs of accept, then accept; otherwise reject1PT
![Page 14: Computability and Complexity](https://reader035.fdocuments.in/reader035/viewer/2022072016/5681329f550346895d993fea/html5/thumbnails/14.jpg)
Computability and Complexity 26-14
Analysis
The number t(|w|) must be such that
|)(|6|)(|
2
2
wpwt
e
2ln|)(|6
|)(|2
wpwt
2ln|)(|6|)(|2 wpwt
|)(|2ln6
|)(| 2 wpwt