2017017(期末)
来源:互联网 发布:sql 查询分析器 编辑:程序博客网 时间:2024/06/04 23:07
8.23. In the NODE-DISJOINT PATHS problem, the input is an undirected graph in which
some vertices have been specially marked: a certain number of “sources”
s1, s2, . . . sk and an equal number of “destinations” t1, t2, . . . tk. The goal is to find
k node-disjoint paths (that is, paths which have no nodes in common) where the
ith path goes from si to ti . Show that this problem is NP-complete.
Here is a sequence of progressively stronger hints.
(i) Reduce from 3SAT.
(ii) For a 3SAT formula with m clauses and n variables, use k = m+ n
sources and destinations. Introduce one source/destination pair (sx, tx) for
each variable x, and one source/destination pair (sc , tc) for each
clause c.
(iii) For each 3SAT clause, introduce 6 new intermediate vertices, one for each
literal occurring in that clause and one for its complement.
(iv) Notice that if the path from sc to tc goes through some intermediate vertex
representing, say, an occurrence of variable x, then no other path can go
through that vertex. What vertex would you like the other path to be forced
to go through instead?
some vertices have been specially marked: a certain number of “sources”
s1, s2, . . . sk and an equal number of “destinations” t1, t2, . . . tk. The goal is to find
k node-disjoint paths (that is, paths which have no nodes in common) where the
ith path goes from si to ti . Show that this problem is NP-complete.
Here is a sequence of progressively stronger hints.
(i) Reduce from 3SAT.
(ii) For a 3SAT formula with m clauses and n variables, use k = m+ n
sources and destinations. Introduce one source/destination pair (sx, tx) for
each variable x, and one source/destination pair (sc , tc) for each
clause c.
(iii) For each 3SAT clause, introduce 6 new intermediate vertices, one for each
literal occurring in that clause and one for its complement.
(iv) Notice that if the path from sc to tc goes through some intermediate vertex
representing, say, an occurrence of variable x, then no other path can go
through that vertex. What vertex would you like the other path to be forced
to go through instead?
题意为:
在提示的基础上再做以下处理:对任意子句
连结起来形成三条路径,因为任意 li 为真都使得c 为真。另外,对于每个变量v ,将 Sv 与所有 v 串联起来,再连向tv ,从而形成一条路径,再将Sv 与所有v 串联起来,连向tv ,又形成一条路径。在这两条路径中,必然要选择其中一条,这保证了所有变量的一致性,即如果有任意子句选择了v ,则其余子句就不能再选择v 。下面举一个简单的例子,假设要验证 CNF:(x ∨ y ∨ z)(x ∨ y ∨ z )是否可以被满足,令 u = ( x ∨ y ∨ z),v = (x ∨ y ∨ z ),可得 NODE-DISJOINT PATH 问题如下图:
连结起来形成三条路径,因为任意 li 为真都使得c 为真。另外,对于每个变量v ,将 Sv 与所有 v 串联起来,再连向tv ,从而形成一条路径,再将Sv 与所有v 串联起来,连向tv ,又形成一条路径。在这两条路径中,必然要选择其中一条,这保证了所有变量的一致性,即如果有任意子句选择了v ,则其余子句就不能再选择v 。下面举一个简单的例子,假设要验证 CNF:(x ∨ y ∨ z)(x ∨ y ∨ z )是否可以被满足,令 u = ( x ∨ y ∨ z),v = (x ∨ y ∨ z ),可得 NODE-DISJOINT PATH 问题如下图:
阅读全文
0 0
- 2017017(期末)
- oracle期末(一)
- oracle期末(二) .
- oracle期末(三)
- 计算机网络(期末复习)
- 期末
- 期末
- 期末
- 期末
- 期末。。。期末
- 数据结构期末复习题(一)
- java期末复习(1)
- java期末复习(2)
- java期末复习(3)
- Android期末复习(1)
- Android期末复习(2)
- 人工智能(AI)期末复习
- 数据库期末复习-(1)
- 2017暑假集训 div1 并查集(2)
- 冒泡排序(C语言版本)
- 文件上传路径问题
- jquery 使用index()方法 出现的问题
- 使用javassist生成新类
- 2017017(期末)
- C++设计模式——Bridge模式
- 《面向对象程序设计-C++》学习笔记2
- ES的集群名字被谁改了?
- volley学习笔记四
- BZOJ 3262 陌上花开 树状数组套splay
- 2 Add Two Numbers
- 17.7.11 校内赛 【图论】【最大流】【SPFA】
- MySQL优化之expalin语句详解