際際滷

際際滷Share a Scribd company logo
3-Coloring is NP-Hard
Feliciano colella
December 4, 2014
Algorithm Design Homework 02
Outline of the presentation
1. Denition of 3-Satisability.
2. Denition of 3-Coloring.
3. Proof that 3-Sat P 3-Color.
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 2 / 8
Algorithm Design Homework 02
The problems
3-Satisability
Input CNF formula 陸 where each clause contains exactly 3 dierent
literals.
Output Satisfying truth assignment for the formula 陸.
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 3 / 8
Algorithm Design Homework 02
The problems
3-Satisability
Input CNF formula 陸 where each clause contains exactly 3 dierent
literals.
Output Satisfying truth assignment for the formula 陸.
k-Coloring
Input A graph G = (V , E) with |V | = n vertices and |E| = m
edges.
Output A k-Coloring c : V  {1, . . . , k}, s.t.
(x, y)  E, C(x) = C(y).
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 3 / 8
Algorithm Design Homework 02
The reduction
3-Coloring is in NP
Certicate A 3-Coloring c : V  {1, 2, 3}
Certier Check if (u, v)  E, c(u) = c(v)
Hardness
Show that the formula 陸 is satisable IFF exist a 3-Coloring for the
graph G.
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 4 / 8
Algorithm Design Homework 02
The gadgets
Literals Gadget Clause gadget
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 5 / 8
Algorithm Design Homework 02
The gadgets
Literals Gadget Clause gadget
x1 測x1
x2 測x2
xn 測xn
R
T
F
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 5 / 8
Algorithm Design Homework 02
The gadgets
Literals Gadget Clause gadget
x1 測x1
x2 測x2
xn 測xn
R
T
F
ci1 ci2 ci3
R
T
F
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 5 / 8
Algorithm Design Homework 02
The construction
x1 測x1
x2 測x2
xn 測xn
R
T
F
c13
c12
c11
c23
c22
c21
c 3
c 2
c 1
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 6 / 8
Algorithm Design Homework 02
The theorem
Theorem
A CNF Formula 陸 is satisable  exists a 3-Coloring for the graph G陸.
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 7 / 8
Algorithm Design Homework 02
The theorem
Theorem
A CNF Formula 陸 is satisable  exists a 3-Coloring for the graph G陸.
陸 is satisable = G陸 is 3-Colorable
Take a truth assignment  for 陸 and color the literals gadgets;
Each clause have at least 1 literal set to True;
All the clause gadget can be colored with respect to the constraint;
We have a 3-Coloring.
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 7 / 8
Algorithm Design Homework 02
The theorem
Theorem
A CNF Formula 陸 is satisable  exists a 3-Coloring for the graph G陸.
G陸 is 3-Colorable = 陸 is satisable
Take a 3-Coloring for G陸;
If a literal is colored with True, set it to True in the formula 陸;
For any clause, it cannot be that all the literals are True or False.
Otherwise we would have a clause gadget colored to False, but this is
impossible since they are connected to Base and False and we have
started from a 3-Coloring for G陸;
We have hence correct a truth assignment for 陸
Feliciano colella 3-Coloring is NP-Hard December 4, 2014 7 / 8
Thank you for the attention.

More Related Content

What's hot (20)

犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...
犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...
犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...
Saharat Laksanasut
留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮
留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮 留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮
留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮
d tampouris
1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢
1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢
1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢
Tongsamut vorasan
犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖
犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖
犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖
Chalit Arm'k
侶虜竜溜竜 凌 虜亮凌
侶虜竜溜竜 凌 虜亮凌侶虜竜溜竜 凌 虜亮凌
侶虜竜溜竜 凌 虜亮凌
流亮侶留 里龍旅僚凌.
' 離裡離 裡立: 里里里
 ' 離裡離 裡立: 里里里 ' 離裡離 裡立: 里里里
' 離裡離 裡立: 里里里
溜虜凌 竜凌凌虜略凌
留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)
留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)
留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)
僚旅粒僚侶 旅留凌凌了凌
Nutri巽達o - Biologia 2尊 anoNutri巽達o - Biologia 2尊 ano
Nutri巽達o - Biologia 2尊 ano
Matheus Felipe Schmitt
ergastiria dexiotiton drasi.pptx
ergastiria dexiotiton drasi.pptxergastiria dexiotiton drasi.pptx
ergastiria dexiotiton drasi.pptx
1stgymtrip
1.5硫 裡律裡 立裡 里 (離裡)
1.5硫 裡律裡 立裡  里  (離裡)1.5硫 裡律裡 立裡  里  (離裡)
1.5硫 裡律裡 立裡 里 (離裡)
了竜僚侶 留凌
硫 了虜竜溜凌 旅了留亮
硫 了虜竜溜凌 旅了留亮硫 了虜竜溜凌 旅了留亮
硫 了虜竜溜凌 旅了留亮
Roy Akanthopoulou
僚隆凌亮
僚隆凌亮僚隆凌亮
僚隆凌亮
lykkarea
竜溜留 竜旅凌粒溜留
  竜溜留 竜旅凌粒溜留  竜溜留 竜旅凌粒溜留
竜溜留 竜旅凌粒溜留
Soultana Gargana
隆竜.36 - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留
隆竜.36  - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留隆竜.36  - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留
隆竜.36 - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留
desphan
' 離裡離 - 10.1.1 離離里裡
 ' 離裡離 - 10.1.1 離離里裡 ' 離裡離 - 10.1.1 離離里裡
' 離裡離 - 10.1.1 離離里裡
溜虜凌 竜凌凌虜略凌
犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖
犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖
犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖
toomtam
' 離裡離 - 10.1.1 里離痢 里裡 離裡
 ' 離裡離 - 10.1.1 里離痢 里裡 離裡 ' 離裡離 - 10.1.1 里離痢 里裡 離裡
' 離裡離 - 10.1.1 里離痢 里裡 離裡
溜虜凌 竜凌凌虜略凌
Rela巽探es ecol坦gicas 2Rela巽探es ecol坦gicas 2
Rela巽探es ecol坦gicas 2
XPaulinhaSilva
劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)
劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)
劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)
Tsormpatzoglou Nestor
' 離裡離 8.4.3 痢律 立離 痢里離裡
 ' 離裡離 8.4.3 痢律 立離 痢里離裡 ' 離裡離 8.4.3 痢律 立離 痢里離裡
' 離裡離 8.4.3 痢律 立離 痢里離裡
溜虜凌 竜凌凌虜略凌
犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...
犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...
犢犖犖犖犖犖迦犖о鹸犖犖∇顕犖犖迦肩犖犖犢 犢犖犖犖劇犖犖犖犖犖犢犖橿犢犖犢犖÷犖犖園犢犖犖÷険犖犖 (Saharat Laksanasut 犖犖犖犖園 犖ム険犖犖...
Saharat Laksanasut
留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮
留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮 留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮
留慮侶旅虜劉 凌旅僚侶竜 - 留僚凌僚旅亮
d tampouris
1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢
1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢
1 04+犖犖迦献犖朽犖о権犖犖犖犢+犖о犖朽硯犖巌犖迦+犖犖迦犖犖朽+2+犖犖迦犖∇顕犖+犢犖ム鍵+犖犖巌犖犢
Tongsamut vorasan
犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖
犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖
犖犖犢犖о権犖犖朽 1 犖ム険犖犖犖犖萎犖ム鍵犖犖迦牽犖犖園犖犖萎犖犖朽権犖犖犖迦犖犖園犖犖
Chalit Arm'k
留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)
留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)
留旅虜劉 留劉 凌 裡僚略粒亮留凌 (竜了. 54-55)
僚旅粒僚侶 旅留凌凌了凌
Nutri巽達o - Biologia 2尊 anoNutri巽達o - Biologia 2尊 ano
Nutri巽達o - Biologia 2尊 ano
Matheus Felipe Schmitt
ergastiria dexiotiton drasi.pptx
ergastiria dexiotiton drasi.pptxergastiria dexiotiton drasi.pptx
ergastiria dexiotiton drasi.pptx
1stgymtrip
1.5硫 裡律裡 立裡 里 (離裡)
1.5硫 裡律裡 立裡  里  (離裡)1.5硫 裡律裡 立裡  里  (離裡)
1.5硫 裡律裡 立裡 里 (離裡)
了竜僚侶 留凌
硫 了虜竜溜凌 旅了留亮
硫 了虜竜溜凌 旅了留亮硫 了虜竜溜凌 旅了留亮
硫 了虜竜溜凌 旅了留亮
Roy Akanthopoulou
僚隆凌亮
僚隆凌亮僚隆凌亮
僚隆凌亮
lykkarea
竜溜留 竜旅凌粒溜留
  竜溜留 竜旅凌粒溜留  竜溜留 竜旅凌粒溜留
竜溜留 竜旅凌粒溜留
Soultana Gargana
隆竜.36 - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留
隆竜.36  - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留隆竜.36  - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留
隆竜.36 - 旅 亮留旅凌虜留慮凌了旅虜凌溜 侶僚 竜凌流 亮留
desphan
犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖
犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖
犖犖迦牽犖犖犖巌見犖迦牽犢犖о献犖
toomtam
Rela巽探es ecol坦gicas 2Rela巽探es ecol坦gicas 2
Rela巽探es ecol坦gicas 2
XPaulinhaSilva
劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)
劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)
劉慮旅亮留 略留 (竜粒留溜留 虜竜旅亮劉僚僚)
Tsormpatzoglou Nestor

Recently uploaded (20)

Drugs and Their Effects | Cambridge IGCSE Biology
Drugs and Their Effects | Cambridge IGCSE BiologyDrugs and Their Effects | Cambridge IGCSE Biology
Drugs and Their Effects | Cambridge IGCSE Biology
Blessing Ndazie
The Arctic through the lens of data visualization
The Arctic through the lens of data visualizationThe Arctic through the lens of data visualization
The Arctic through the lens of data visualization
Zachary Labe
Variation and Natural Selection | IGCSE Biology
Variation and Natural Selection | IGCSE BiologyVariation and Natural Selection | IGCSE Biology
Variation and Natural Selection | IGCSE Biology
Blessing Ndazie
(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...
(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...
(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...
Scintica Instrumentation
Sujay Rao Mandavilli public profile March 2025 - (2)
Sujay Rao Mandavilli public profile March 2025 - (2)Sujay Rao Mandavilli public profile March 2025 - (2)
Sujay Rao Mandavilli public profile March 2025 - (2)
Sujay Rao Mandavilli
(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...
(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...
(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...
David Podorefsky, PhD
Simple Phenomena of Magnetism | IGCSE Physics
Simple Phenomena of Magnetism | IGCSE PhysicsSimple Phenomena of Magnetism | IGCSE Physics
Simple Phenomena of Magnetism | IGCSE Physics
Blessing Ndazie
biochemical mechanism of gall stone .pptx
biochemical mechanism of gall stone .pptxbiochemical mechanism of gall stone .pptx
biochemical mechanism of gall stone .pptx
Amri559698
Neumann, Franz. - Behemoth [ocr] [1942].pdf
Neumann, Franz. - Behemoth [ocr] [1942].pdfNeumann, Franz. - Behemoth [ocr] [1942].pdf
Neumann, Franz. - Behemoth [ocr] [1942].pdf
Francisco Sandoval Mart鱈nez
Cell Structure & Function | Cambridge IGCSE Biology
Cell Structure & Function | Cambridge IGCSE BiologyCell Structure & Function | Cambridge IGCSE Biology
Cell Structure & Function | Cambridge IGCSE Biology
Blessing Ndazie
WORKING AND APPLICATION OF LC-MS/MS 2025
WORKING AND APPLICATION OF LC-MS/MS  2025WORKING AND APPLICATION OF LC-MS/MS  2025
WORKING AND APPLICATION OF LC-MS/MS 2025
PSG College of Technology
Lower Secondary Science Stage 9 Scheme of Work
Lower Secondary Science Stage 9 Scheme of WorkLower Secondary Science Stage 9 Scheme of Work
Lower Secondary Science Stage 9 Scheme of Work
MayoreeChannaryPisey
Telescope equatorial mount polar alignment quick reference guide
Telescope equatorial mount polar alignment quick reference guideTelescope equatorial mount polar alignment quick reference guide
Telescope equatorial mount polar alignment quick reference guide
bartf25
The Sense Organs: Structure and Function of the Eye and Skin | IGCSE Biology
The Sense Organs: Structure and Function of the Eye and Skin | IGCSE BiologyThe Sense Organs: Structure and Function of the Eye and Skin | IGCSE Biology
The Sense Organs: Structure and Function of the Eye and Skin | IGCSE Biology
Blessing Ndazie
Investigational New drug application process
Investigational New drug application processInvestigational New drug application process
Investigational New drug application process
onepalyer4
(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...
(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...
(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...
David Podorefsky, PhD
animal cell plant cell power point presentation
animal cell plant cell power point presentationanimal cell plant cell power point presentation
animal cell plant cell power point presentation
JosephinePaguio2
Leafcurl viral disease presentation.pptx
Leafcurl viral disease presentation.pptxLeafcurl viral disease presentation.pptx
Leafcurl viral disease presentation.pptx
Mir Ali M
Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...
Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...
Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...
S辿rgio Sacani
(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...
(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...
(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...
David Podorefsky, PhD
Drugs and Their Effects | Cambridge IGCSE Biology
Drugs and Their Effects | Cambridge IGCSE BiologyDrugs and Their Effects | Cambridge IGCSE Biology
Drugs and Their Effects | Cambridge IGCSE Biology
Blessing Ndazie
The Arctic through the lens of data visualization
The Arctic through the lens of data visualizationThe Arctic through the lens of data visualization
The Arctic through the lens of data visualization
Zachary Labe
Variation and Natural Selection | IGCSE Biology
Variation and Natural Selection | IGCSE BiologyVariation and Natural Selection | IGCSE Biology
Variation and Natural Selection | IGCSE Biology
Blessing Ndazie
(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...
(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...
(February 25th, 2025) Real-Time Insights into Cardiothoracic Research with In...
Scintica Instrumentation
Sujay Rao Mandavilli public profile March 2025 - (2)
Sujay Rao Mandavilli public profile March 2025 - (2)Sujay Rao Mandavilli public profile March 2025 - (2)
Sujay Rao Mandavilli public profile March 2025 - (2)
Sujay Rao Mandavilli
(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...
(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...
(Journal Club) - RNA m6A regulates transcription via DNA demethylation and ch...
David Podorefsky, PhD
Simple Phenomena of Magnetism | IGCSE Physics
Simple Phenomena of Magnetism | IGCSE PhysicsSimple Phenomena of Magnetism | IGCSE Physics
Simple Phenomena of Magnetism | IGCSE Physics
Blessing Ndazie
biochemical mechanism of gall stone .pptx
biochemical mechanism of gall stone .pptxbiochemical mechanism of gall stone .pptx
biochemical mechanism of gall stone .pptx
Amri559698
Cell Structure & Function | Cambridge IGCSE Biology
Cell Structure & Function | Cambridge IGCSE BiologyCell Structure & Function | Cambridge IGCSE Biology
Cell Structure & Function | Cambridge IGCSE Biology
Blessing Ndazie
Lower Secondary Science Stage 9 Scheme of Work
Lower Secondary Science Stage 9 Scheme of WorkLower Secondary Science Stage 9 Scheme of Work
Lower Secondary Science Stage 9 Scheme of Work
MayoreeChannaryPisey
Telescope equatorial mount polar alignment quick reference guide
Telescope equatorial mount polar alignment quick reference guideTelescope equatorial mount polar alignment quick reference guide
Telescope equatorial mount polar alignment quick reference guide
bartf25
The Sense Organs: Structure and Function of the Eye and Skin | IGCSE Biology
The Sense Organs: Structure and Function of the Eye and Skin | IGCSE BiologyThe Sense Organs: Structure and Function of the Eye and Skin | IGCSE Biology
The Sense Organs: Structure and Function of the Eye and Skin | IGCSE Biology
Blessing Ndazie
Investigational New drug application process
Investigational New drug application processInvestigational New drug application process
Investigational New drug application process
onepalyer4
(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...
(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...
(Journal Club) - Understanding tumor ecosystems by single-cell sequencing: pr...
David Podorefsky, PhD
animal cell plant cell power point presentation
animal cell plant cell power point presentationanimal cell plant cell power point presentation
animal cell plant cell power point presentation
JosephinePaguio2
Leafcurl viral disease presentation.pptx
Leafcurl viral disease presentation.pptxLeafcurl viral disease presentation.pptx
Leafcurl viral disease presentation.pptx
Mir Ali M
Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...
Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...
Beyond Point Masses. IV. Trans-Neptunian Object Altjira Is Likely a Hierarchi...
S辿rgio Sacani
(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...
(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...
(Journal Club) Focused ultrasound excites neurons via mechanosensitive calciu...
David Podorefsky, PhD

3-Coloring is NP-Hard

  • 1. 3-Coloring is NP-Hard Feliciano colella December 4, 2014
  • 2. Algorithm Design Homework 02 Outline of the presentation 1. Denition of 3-Satisability. 2. Denition of 3-Coloring. 3. Proof that 3-Sat P 3-Color. Feliciano colella 3-Coloring is NP-Hard December 4, 2014 2 / 8
  • 3. Algorithm Design Homework 02 The problems 3-Satisability Input CNF formula 陸 where each clause contains exactly 3 dierent literals. Output Satisfying truth assignment for the formula 陸. Feliciano colella 3-Coloring is NP-Hard December 4, 2014 3 / 8
  • 4. Algorithm Design Homework 02 The problems 3-Satisability Input CNF formula 陸 where each clause contains exactly 3 dierent literals. Output Satisfying truth assignment for the formula 陸. k-Coloring Input A graph G = (V , E) with |V | = n vertices and |E| = m edges. Output A k-Coloring c : V {1, . . . , k}, s.t. (x, y) E, C(x) = C(y). Feliciano colella 3-Coloring is NP-Hard December 4, 2014 3 / 8
  • 5. Algorithm Design Homework 02 The reduction 3-Coloring is in NP Certicate A 3-Coloring c : V {1, 2, 3} Certier Check if (u, v) E, c(u) = c(v) Hardness Show that the formula 陸 is satisable IFF exist a 3-Coloring for the graph G. Feliciano colella 3-Coloring is NP-Hard December 4, 2014 4 / 8
  • 6. Algorithm Design Homework 02 The gadgets Literals Gadget Clause gadget Feliciano colella 3-Coloring is NP-Hard December 4, 2014 5 / 8
  • 7. Algorithm Design Homework 02 The gadgets Literals Gadget Clause gadget x1 測x1 x2 測x2 xn 測xn R T F Feliciano colella 3-Coloring is NP-Hard December 4, 2014 5 / 8
  • 8. Algorithm Design Homework 02 The gadgets Literals Gadget Clause gadget x1 測x1 x2 測x2 xn 測xn R T F ci1 ci2 ci3 R T F Feliciano colella 3-Coloring is NP-Hard December 4, 2014 5 / 8
  • 9. Algorithm Design Homework 02 The construction x1 測x1 x2 測x2 xn 測xn R T F c13 c12 c11 c23 c22 c21 c 3 c 2 c 1 Feliciano colella 3-Coloring is NP-Hard December 4, 2014 6 / 8
  • 10. Algorithm Design Homework 02 The theorem Theorem A CNF Formula 陸 is satisable exists a 3-Coloring for the graph G陸. Feliciano colella 3-Coloring is NP-Hard December 4, 2014 7 / 8
  • 11. Algorithm Design Homework 02 The theorem Theorem A CNF Formula 陸 is satisable exists a 3-Coloring for the graph G陸. 陸 is satisable = G陸 is 3-Colorable Take a truth assignment for 陸 and color the literals gadgets; Each clause have at least 1 literal set to True; All the clause gadget can be colored with respect to the constraint; We have a 3-Coloring. Feliciano colella 3-Coloring is NP-Hard December 4, 2014 7 / 8
  • 12. Algorithm Design Homework 02 The theorem Theorem A CNF Formula 陸 is satisable exists a 3-Coloring for the graph G陸. G陸 is 3-Colorable = 陸 is satisable Take a 3-Coloring for G陸; If a literal is colored with True, set it to True in the formula 陸; For any clause, it cannot be that all the literals are True or False. Otherwise we would have a clause gadget colored to False, but this is impossible since they are connected to Base and False and we have started from a 3-Coloring for G陸; We have hence correct a truth assignment for 陸 Feliciano colella 3-Coloring is NP-Hard December 4, 2014 7 / 8
  • 13. Thank you for the attention.