Computational Complexity Lecture 6 NL-Completeness and NL=co-NL 1 - - PowerPoint PPT Presentation

computational complexity
SMART_READER_LITE
LIVE PREVIEW

Computational Complexity Lecture 6 NL-Completeness and NL=co-NL 1 - - PowerPoint PPT Presentation

Computational Complexity Lecture 6 NL-Completeness and NL=co-NL 1 Story, so far NEXP EXP PSPACE NPSPACE NP P NL L 2 Story, so far Time/Space Hierarchies NEXP EXP PSPACE NPSPACE NP P NL L 2 Story, so far Time/Space


slide-1
SLIDE 1

Computational Complexity

Lecture 6 NL-Completeness and NL=co-NL

1

slide-2
SLIDE 2

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE 2

slide-3
SLIDE 3

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE

Time/Space Hierarchies

2

slide-4
SLIDE 4

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE

Time/Space Hierarchies Relations across complexity measures

2

slide-5
SLIDE 5

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE

Time/Space Hierarchies Relations across complexity measures SAT is NP-complete, TQBF is PSPACE-complete

2

slide-6
SLIDE 6

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE

Time/Space Hierarchies Relations across complexity measures SAT is NP-complete, TQBF is PSPACE-complete Today

2

slide-7
SLIDE 7

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE

Time/Space Hierarchies Relations across complexity measures SAT is NP-complete, TQBF is PSPACE-complete Today Log-space reductions

2

slide-8
SLIDE 8

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE

Time/Space Hierarchies Relations across complexity measures SAT is NP-complete, TQBF is PSPACE-complete Today Log-space reductions An NL-complete language: PATH

2

slide-9
SLIDE 9

Story, so far

P

PSPACE

EXP NP NEXP L NL

NPSPACE

Time/Space Hierarchies Relations across complexity measures SAT is NP-complete, TQBF is PSPACE-complete Today Log-space reductions An NL-complete language: PATH NSPACE = co-NSPACE (one less kind to worry about!)

2

slide-10
SLIDE 10

NL-completeness

3

slide-11
SLIDE 11

NL-completeness

For any two (non-trivial) languages L1, L2 in P, L2 !p L1

3

slide-12
SLIDE 12

NL-completeness

For any two (non-trivial) languages L1, L2 in P, L2 !p L1 So if X ⊆ P, then all non-trivial languages in X are X-complete (w.r.t !p)

3

slide-13
SLIDE 13

NL-completeness

For any two (non-trivial) languages L1, L2 in P, L2 !p L1 So if X ⊆ P, then all non-trivial languages in X are X-complete (w.r.t !p) Need a tighter notion of reduction to capture “(almost) as hard as it gets” within X

3

slide-14
SLIDE 14

Log-Space Reduction

4

slide-15
SLIDE 15

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that

4

slide-16
SLIDE 16

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1

4

slide-17
SLIDE 17

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1 M uses only O(log|x|) work-tape

4

slide-18
SLIDE 18

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1 M uses only O(log|x|) work-tape Is allowed to have a write-only output tape, because |f(x)| may be poly(|x|)

4

slide-19
SLIDE 19

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1 M uses only O(log|x|) work-tape Is allowed to have a write-only output tape, because |f(x)| may be poly(|x|) Equivalently: f “implicitly computable” in log-space

4

slide-20
SLIDE 20

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1 M uses only O(log|x|) work-tape Is allowed to have a write-only output tape, because |f(x)| may be poly(|x|) Equivalently: f “implicitly computable” in log-space A log-space machine M’ to output the bit fi(x) on input (x,i)

4

slide-21
SLIDE 21

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1 M uses only O(log|x|) work-tape Is allowed to have a write-only output tape, because |f(x)| may be poly(|x|) Equivalently: f “implicitly computable” in log-space A log-space machine M’ to output the bit fi(x) on input (x,i) M’ from M: keep a counter and output only the ith bit

4

slide-22
SLIDE 22

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1 M uses only O(log|x|) work-tape Is allowed to have a write-only output tape, because |f(x)| may be poly(|x|) Equivalently: f “implicitly computable” in log-space A log-space machine M’ to output the bit fi(x) on input (x,i) M’ from M: keep a counter and output only the ith bit M from M’: keep a counter and repeatedly call M on each i

4

slide-23
SLIDE 23

Log-Space Reduction

Many-one reduction: L2 !L L1 if there is a TM, M which maps its input x to f(x) such that x ∈ L2 ⇒ f(x) ∈ L1 and x ! L2 ⇒ f(x) ! L1 M uses only O(log|x|) work-tape Is allowed to have a write-only output tape, because |f(x)| may be poly(|x|) Equivalently: f “implicitly computable” in log-space A log-space machine M’ to output the bit fi(x) on input (x,i) M’ from M: keep a counter and output only the ith bit M from M’: keep a counter and repeatedly call M on each i

Not suitable for use as a subroutine

4

slide-24
SLIDE 24

Log-Space Reduction

5

slide-25
SLIDE 25

Log-space reductions “compose”: L2 !L L1 !L L0 ⇒ L2 !L L0

Log-Space Reduction

5

slide-26
SLIDE 26

Log-space reductions “compose”: L2 !L L1 !L L0 ⇒ L2 !L L0 Given M2-1 and M1-0 build M2-0:

Log-Space Reduction

5

slide-27
SLIDE 27

Log-space reductions “compose”: L2 !L L1 !L L0 ⇒ L2 !L L0 Given M2-1 and M1-0 build M2-0: Start running M1-0 without input. When it wants to read ith bit of input, run M2-1 (with a counter) to get the ith bit

  • f its output

Log-Space Reduction

5

slide-28
SLIDE 28

Log-space reductions “compose”: L2 !L L1 !L L0 ⇒ L2 !L L0 Given M2-1 and M1-0 build M2-0: Start running M1-0 without input. When it wants to read ith bit of input, run M2-1 (with a counter) to get the ith bit

  • f its output

Space needed: O(log(|f(x)|) + log(|x|)) = O(log(|x|)), because |f(x)| is poly(|x|)

Log-Space Reduction

5

slide-29
SLIDE 29

Log-space reductions “compose”: L2 !L L1 !L L0 ⇒ L2 !L L0 Given M2-1 and M1-0 build M2-0: Start running M1-0 without input. When it wants to read ith bit of input, run M2-1 (with a counter) to get the ith bit

  • f its output

Space needed: O(log(|f(x)|) + log(|x|)) = O(log(|x|)), because |f(x)| is poly(|x|) Similarly, L (the class of problems decidable in log-space) is downward closed under log-space reductions

Log-Space Reduction

5

slide-30
SLIDE 30

Log-space reductions “compose”: L2 !L L1 !L L0 ⇒ L2 !L L0 Given M2-1 and M1-0 build M2-0: Start running M1-0 without input. When it wants to read ith bit of input, run M2-1 (with a counter) to get the ith bit

  • f its output

Space needed: O(log(|f(x)|) + log(|x|)) = O(log(|x|)), because |f(x)| is poly(|x|) Similarly, L (the class of problems decidable in log-space) is downward closed under log-space reductions L2 !L L1 ∈ L ⇒ L2 ∈ L

Log-Space Reduction

5

slide-31
SLIDE 31

NL-completeness

6

slide-32
SLIDE 32

NL-completeness

NL has languages of the form L1 = { x | ∃w, |w|<poly(|x|), (x;w) ∈ L1’ } where L1’ can be decided deterministically in logspace, with w in a read-once tape

6

slide-33
SLIDE 33

NL-completeness

NL has languages of the form L1 = { x | ∃w, |w|<poly(|x|), (x;w) ∈ L1’ } where L1’ can be decided deterministically in logspace, with w in a read-once tape L0 is NL-Hard if for all L1 in NL, L1 !L L0

6

slide-34
SLIDE 34

NL-completeness

NL has languages of the form L1 = { x | ∃w, |w|<poly(|x|), (x;w) ∈ L1’ } where L1’ can be decided deterministically in logspace, with w in a read-once tape L0 is NL-Hard if for all L1 in NL, L1 !L L0 L0 is NL-complete if it is NL-hard and is in NL

6

slide-35
SLIDE 35

NL-completeness

NL has languages of the form L1 = { x | ∃w, |w|<poly(|x|), (x;w) ∈ L1’ } where L1’ can be decided deterministically in logspace, with w in a read-once tape L0 is NL-Hard if for all L1 in NL, L1 !L L0 L0 is NL-complete if it is NL-hard and is in NL Can construct trivial NL-complete language

6

slide-36
SLIDE 36

NL-completeness

NL has languages of the form L1 = { x | ∃w, |w|<poly(|x|), (x;w) ∈ L1’ } where L1’ can be decided deterministically in logspace, with w in a read-once tape L0 is NL-Hard if for all L1 in NL, L1 !L L0 L0 is NL-complete if it is NL-hard and is in NL Can construct trivial NL-complete language { (M,x,1n,1s) | ∃w, |w|<n, M accepts (x;w) in space log(s) } (where M takes w in a read-once tape)

6

slide-37
SLIDE 37

NL-completeness

NL has languages of the form L1 = { x | ∃w, |w|<poly(|x|), (x;w) ∈ L1’ } where L1’ can be decided deterministically in logspace, with w in a read-once tape L0 is NL-Hard if for all L1 in NL, L1 !L L0 L0 is NL-complete if it is NL-hard and is in NL Can construct trivial NL-complete language { (M,x,1n,1s) | ∃w, |w|<n, M accepts (x;w) in space log(s) } (where M takes w in a read-once tape) Interesting NLC language: PATH

6

slide-38
SLIDE 38

Directed Path

7

slide-39
SLIDE 39

Directed Path

PATH = {(G,s,t) | G a directed graph with a path from s to t}

7

slide-40
SLIDE 40

Directed Path

PATH = {(G,s,t) | G a directed graph with a path from s to t} G using some representation, of size say, n2 (n=#vertices)

7

slide-41
SLIDE 41

Directed Path

PATH = {(G,s,t) | G a directed graph with a path from s to t} G using some representation, of size say, n2 (n=#vertices) Such that, if two vertices x,y on work-tape, can read the input tape to check for edge (x,y)

7

slide-42
SLIDE 42

Directed Path

PATH = {(G,s,t) | G a directed graph with a path from s to t} G using some representation, of size say, n2 (n=#vertices) Such that, if two vertices x,y on work-tape, can read the input tape to check for edge (x,y) PATH in NL

7

slide-43
SLIDE 43

Directed Path

PATH = {(G,s,t) | G a directed graph with a path from s to t} G using some representation, of size say, n2 (n=#vertices) Such that, if two vertices x,y on work-tape, can read the input tape to check for edge (x,y) PATH in NL Certificate w is the path (poly(n) long certificate)

7

slide-44
SLIDE 44

Directed Path

PATH = {(G,s,t) | G a directed graph with a path from s to t} G using some representation, of size say, n2 (n=#vertices) Such that, if two vertices x,y on work-tape, can read the input tape to check for edge (x,y) PATH in NL Certificate w is the path (poly(n) long certificate) Need to verify adjacent vertices are connected: need keep only two vertices on the work-tape at a time

7

slide-45
SLIDE 45

Directed Path

PATH = {(G,s,t) | G a directed graph with a path from s to t} G using some representation, of size say, n2 (n=#vertices) Such that, if two vertices x,y on work-tape, can read the input tape to check for edge (x,y) PATH in NL Certificate w is the path (poly(n) long certificate) Need to verify adjacent vertices are connected: need keep only two vertices on the work-tape at a time Note: w is scanned only once

7

slide-46
SLIDE 46

Seen PATH before?

8

slide-47
SLIDE 47

Seen PATH before?

In proving NSPACE(S(n)) ⊆ DTIME(2O(S(n))) (e.g. NL ⊆ P)

8

slide-48
SLIDE 48

Seen PATH before?

In proving NSPACE(S(n)) ⊆ DTIME(2O(S(n))) (e.g. NL ⊆ P) Every problem in NL Karp reduces to PATH

8

slide-49
SLIDE 49

Seen PATH before?

In proving NSPACE(S(n)) ⊆ DTIME(2O(S(n))) (e.g. NL ⊆ P) Every problem in NL Karp reduces to PATH PATH ∈ P

8

slide-50
SLIDE 50

Seen PATH before?

In proving NSPACE(S(n)) ⊆ DTIME(2O(S(n))) (e.g. NL ⊆ P) Every problem in NL Karp reduces to PATH PATH ∈ P In Savitch’ s theorem

8

slide-51
SLIDE 51

Seen PATH before?

In proving NSPACE(S(n)) ⊆ DTIME(2O(S(n))) (e.g. NL ⊆ P) Every problem in NL Karp reduces to PATH PATH ∈ P In Savitch’ s theorem PATH ∈ DSPACE(log2(n))

8

slide-52
SLIDE 52

PATH is NL-complete

9

slide-53
SLIDE 53

PATH is NL-complete

Log-space reducing any NL language L1 to PATH

9

slide-54
SLIDE 54

PATH is NL-complete

Log-space reducing any NL language L1 to PATH Given input x, output (G,s,t) where G is the configuration graph G(M,x), where M is the NTM accepting L1, and s,t are start, accept configurations

9

slide-55
SLIDE 55

PATH is NL-complete

Log-space reducing any NL language L1 to PATH Given input x, output (G,s,t) where G is the configuration graph G(M,x), where M is the NTM accepting L1, and s,t are start, accept configurations Outputting G: Cycle through all pairs of configurations, checking if there is an edge between them, outputting 0 or 1 in the adjacency matrix

9

slide-56
SLIDE 56

PATH is NL-complete

Log-space reducing any NL language L1 to PATH Given input x, output (G,s,t) where G is the configuration graph G(M,x), where M is the NTM accepting L1, and s,t are start, accept configurations Outputting G: Cycle through all pairs of configurations, checking if there is an edge between them, outputting 0 or 1 in the adjacency matrix Edge checking done using M’ s transition table

9

slide-57
SLIDE 57

PATH is NL-complete

Log-space reducing any NL language L1 to PATH Given input x, output (G,s,t) where G is the configuration graph G(M,x), where M is the NTM accepting L1, and s,t are start, accept configurations Outputting G: Cycle through all pairs of configurations, checking if there is an edge between them, outputting 0 or 1 in the adjacency matrix Edge checking done using M’ s transition table Need to store only two configurations at a time in the work-tape

9

slide-58
SLIDE 58

PATH is NL-complete

Log-space reducing any NL language L1 to PATH Given input x, output (G,s,t) where G is the configuration graph G(M,x), where M is the NTM accepting L1, and s,t are start, accept configurations Outputting G: Cycle through all pairs of configurations, checking if there is an edge between them, outputting 0 or 1 in the adjacency matrix Edge checking done using M’ s transition table Need to store only two configurations at a time in the work-tape Note: in fact O(S)-space reduction from L ∈ NSPACE(S) to PATH

9

slide-59
SLIDE 59

If PATH ∈ co-NL

10

slide-60
SLIDE 60

If PATH ∈ co-NL

If PATH ∈ co-NL, then co-NL ⊆ NL

10

slide-61
SLIDE 61

If PATH ∈ co-NL

If PATH ∈ co-NL, then co-NL ⊆ NL For any L ∈ co-NL, we have L !L PATHc (as Lc !L PATH), and if PATHc ∈ NL, then L ∈ NL (NL is downward closed under !L)

10

slide-62
SLIDE 62

If PATH ∈ co-NL

If PATH ∈ co-NL, then co-NL ⊆ NL For any L ∈ co-NL, we have L !L PATHc (as Lc !L PATH), and if PATHc ∈ NL, then L ∈ NL (NL is downward closed under !L) Implies co-NL = NL (why?)

10

slide-63
SLIDE 63

If PATH ∈ co-NL

If PATH ∈ co-NL, then co-NL ⊆ NL For any L ∈ co-NL, we have L !L PATHc (as Lc !L PATH), and if PATHc ∈ NL, then L ∈ NL (NL is downward closed under !L) Implies co-NL = NL (why?) If Y ⊆ X, then co-Y ⊆ co-X. Consider X = NL, Y = co-NL.

10

slide-64
SLIDE 64

If PATH ∈ co-NL

11

slide-65
SLIDE 65

If PATH ∈ co-NL

In fact, PATH ∈ co-NL implies co-NSPACE(S) = NSPACE(S)

11

slide-66
SLIDE 66

If PATH ∈ co-NL

In fact, PATH ∈ co-NL implies co-NSPACE(S) = NSPACE(S) Recall: O(S)-space reduction from any L ∈ NSPACE(S) to PATH

11

slide-67
SLIDE 67

If PATH ∈ co-NL

In fact, PATH ∈ co-NL implies co-NSPACE(S) = NSPACE(S) Recall: O(S)-space reduction from any L ∈ NSPACE(S) to PATH i.e., from any L ’ ∈ co-NSPACE(S) to PATHc

11

slide-68
SLIDE 68

If PATH ∈ co-NL

In fact, PATH ∈ co-NL implies co-NSPACE(S) = NSPACE(S) Recall: O(S)-space reduction from any L ∈ NSPACE(S) to PATH i.e., from any L ’ ∈ co-NSPACE(S) to PATHc Size of the new instance is at most N = 2O(|S|)

11

slide-69
SLIDE 69

If PATH ∈ co-NL

In fact, PATH ∈ co-NL implies co-NSPACE(S) = NSPACE(S) Recall: O(S)-space reduction from any L ∈ NSPACE(S) to PATH i.e., from any L ’ ∈ co-NSPACE(S) to PATHc Size of the new instance is at most N = 2O(|S|) PATHc ∈ NL implies an NTM that decides if the instance is in PATHc in NSPACE(log N) = NSPACE(S)

11

slide-70
SLIDE 70

If PATH ∈ co-NL

In fact, PATH ∈ co-NL implies co-NSPACE(S) = NSPACE(S) Recall: O(S)-space reduction from any L ∈ NSPACE(S) to PATH i.e., from any L ’ ∈ co-NSPACE(S) to PATHc Size of the new instance is at most N = 2O(|S|) PATHc ∈ NL implies an NTM that decides if the instance is in PATHc in NSPACE(log N) = NSPACE(S) Then L ’ ∈ co-NSPACE(S) is also in NSPACE(S), by composing space-bounded computations. So, co-NSPACE(S) ⊆ NSPACE(S)

11

slide-71
SLIDE 71

If PATH ∈ co-NL

In fact, PATH ∈ co-NL implies co-NSPACE(S) = NSPACE(S) Recall: O(S)-space reduction from any L ∈ NSPACE(S) to PATH i.e., from any L ’ ∈ co-NSPACE(S) to PATHc Size of the new instance is at most N = 2O(|S|) PATHc ∈ NL implies an NTM that decides if the instance is in PATHc in NSPACE(log N) = NSPACE(S) Then L ’ ∈ co-NSPACE(S) is also in NSPACE(S), by composing space-bounded computations. So, co-NSPACE(S) ⊆ NSPACE(S) Hence co-NSPACE(S) = NSPACE(S)

11

slide-72
SLIDE 72

If PATH ∈ co-NL

12

slide-73
SLIDE 73

If PATH ∈ co-NL

If PATH ∈ co-NL then NSPACE(S) = co-NSPACE(S)

12

slide-74
SLIDE 74

If PATH ∈ co-NL

If PATH ∈ co-NL then NSPACE(S) = co-NSPACE(S) In particular NL = co-NL

12

slide-75
SLIDE 75

If PATH ∈ co-NL

If PATH ∈ co-NL then NSPACE(S) = co-NSPACE(S) In particular NL = co-NL And indeed, PATH ∈ co-NL!

12

slide-76
SLIDE 76

If PATH ∈ co-NL

If PATH ∈ co-NL then NSPACE(S) = co-NSPACE(S) In particular NL = co-NL And indeed, PATH ∈ co-NL! There is a (polynomial sized) certificate that can be verified in log-space, that there is no path from s to t in a graph G

12

slide-77
SLIDE 77

PATHc ∈ NL

13

slide-78
SLIDE 78

PATHc ∈ NL

Certificate for (s,t) connected is just the path

13

slide-79
SLIDE 79

PATHc ∈ NL

Certificate for (s,t) connected is just the path What is a certificate that (s,t) not connected?

13

slide-80
SLIDE 80

PATHc ∈ NL

Certificate for (s,t) connected is just the path What is a certificate that (s,t) not connected? size c of the connected component of s, C; a list of all v ∈ C (with certificates) in order; and (somehow) a certificate for c = |C|

13

slide-81
SLIDE 81

PATHc ∈ NL

Certificate for (s,t) connected is just the path What is a certificate that (s,t) not connected? size c of the connected component of s, C; a list of all v ∈ C (with certificates) in order; and (somehow) a certificate for c = |C| Log-space, one-scan verification of certified C (believing |C|): scan list, checking certificates, counting, ensuring

  • rder, and that t not in the list. Verify certificate for |C|.

13

slide-82
SLIDE 82

PATHc ∈ NL

Certificate for (s,t) connected is just the path What is a certificate that (s,t) not connected? size c of the connected component of s, C; a list of all v ∈ C (with certificates) in order; and (somehow) a certificate for c = |C| Log-space, one-scan verification of certified C (believing |C|): scan list, checking certificates, counting, ensuring

  • rder, and that t not in the list. Verify certificate for |C|.

If list has |C| many v ∈ C, without repeating, list must be complete

13

slide-83
SLIDE 83

Certificate for |C|

14

slide-84
SLIDE 84

Certificate for |C|

Let Ci := set of nodes within distance i of s. Then C = CN

14

slide-85
SLIDE 85

Certificate for |C|

Let Ci := set of nodes within distance i of s. Then C = CN Tail recursion to verify |CN|:

14

slide-86
SLIDE 86

Certificate for |C|

Let Ci := set of nodes within distance i of s. Then C = CN Tail recursion to verify |CN|: Read |CN-1|, believing it verify |CN|, forget |CN|;

14

slide-87
SLIDE 87

Certificate for |C|

Let Ci := set of nodes within distance i of s. Then C = CN Tail recursion to verify |CN|: Read |CN-1|, believing it verify |CN|, forget |CN|; Read |CN-2|, believing it verify |CN-1|, forget |CN-1|; ...

14

slide-88
SLIDE 88

Certificate for |C|

Let Ci := set of nodes within distance i of s. Then C = CN Tail recursion to verify |CN|: Read |CN-1|, believing it verify |CN|, forget |CN|; Read |CN-2|, believing it verify |CN-1|, forget |CN-1|; ... Base case: |C0|=1

14

slide-89
SLIDE 89

Certificate for |C|

Let Ci := set of nodes within distance i of s. Then C = CN Tail recursion to verify |CN|: Read |CN-1|, believing it verify |CN|, forget |CN|; Read |CN-2|, believing it verify |CN-1|, forget |CN-1|; ... Base case: |C0|=1 Believing |Ci-1| verify |Ci|: for each vertex v certificate that v ∈ Ci

  • r that v ∉ Ci (these certificates should be poly(N) long)

14

slide-90
SLIDE 90

Certificate for |C|

Let Ci := set of nodes within distance i of s. Then C = CN Tail recursion to verify |CN|: Read |CN-1|, believing it verify |CN|, forget |CN|; Read |CN-2|, believing it verify |CN-1|, forget |CN-1|; ... Base case: |C0|=1 Believing |Ci-1| verify |Ci|: for each vertex v certificate that v ∈ Ci

  • r that v ∉ Ci (these certificates should be poly(N) long)

Certificate that v ∉ Ci given (i.e., believing) |Ci-1|: list of all vertices in Ci-1 in order, with certificates. As before verify Ci-1 believing |Ci-1| (scan and ensure list is correct/complete), but also check that no node in the list has v as a neighbor

14

slide-91
SLIDE 91

Certificate for t∉CN

15

slide-92
SLIDE 92

Certificate for t∉CN

t ! CN

15

slide-93
SLIDE 93

|CN|

Certificate for t∉CN

t ! CN

15

slide-94
SLIDE 94

|CN|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN|

15

slide-95
SLIDE 95

|CN|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN|

|CN| vertices

15

slide-96
SLIDE 96

|CN|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN|

vi ∈CN path(s,vi)

|CN| vertices

15

slide-97
SLIDE 97

|CN|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN|

vi ∈CN path(s,vi)

|CN| vertices

vi ≠ t

15

slide-98
SLIDE 98

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN|

vi ∈CN path(s,vi)

|CN| vertices

vi ≠ t

15

slide-99
SLIDE 99

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi)

|CN| vertices

vi ≠ t

15

slide-100
SLIDE 100

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi)

|CN| vertices all N vertices

vi ≠ t

15

slide-101
SLIDE 101

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi)

|CN| vertices all N vertices

vi ≠ t

15

slide-102
SLIDE 102

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi) vi ∉CN

|CN| vertices all N vertices

vi ≠ t

15

slide-103
SLIDE 103

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi) vi ∉CN

|CN| vertices all N vertices

vi ! CN /|CN-1| vi ≠ t

15

slide-104
SLIDE 104

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi) vi ∉CN

|CN| vertices all N vertices |CN-1| vertices

vi ! CN /|CN-1| vi ≠ t

15

slide-105
SLIDE 105

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi) vi ∉CN vj ∈CN-1 path(s,vj)

|CN| vertices all N vertices |CN-1| vertices

vi ! CN /|CN-1| vi ≠ t

15

slide-106
SLIDE 106

|CN| |CN-1|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi) vi ∉CN vj ∈CN-1 path(s,vj)

|CN| vertices all N vertices |CN-1| vertices

vi ! CN /|CN-1| vj vi vi ≠ t

15

slide-107
SLIDE 107

|CN| |CN-1| |CN-2|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi) vi ∉CN vj ∈CN-1 path(s,vj)

|CN| vertices all N vertices |CN-1| vertices

vi ! CN /|CN-1| vj vi vi ≠ t

15

slide-108
SLIDE 108

|CN| |CN-1| |CN-2|

t ! CN /|CN|

Certificate for t∉CN

t ! CN |CN| |CN| /|CN-1| |CN-1|

vi ∈CN path(s,vi) vi ∈CN path(s,vi) vi ∉CN vj ∈CN-1 path(s,vj)

|CN| vertices all N vertices |CN-1| vertices

vi ! CN /|CN-1| vj vi vi ≠ t

15