You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

171 lines
7.8 KiB

2 months ago
  1. We start by computing $\skel$:
  2. \begin{compactItemize}
  3. \item $e_{0}\Leftrightarrow(g(a)=c)$
  4. \item $e_{1}\Leftrightarrow(f(g(a))=f(c))$
  5. \item $e_{2}\Leftrightarrow(g(a)=d)$
  6. \item $e_{3}\Leftrightarrow(c=d)$
  7. \end{compactItemize}
  8. $$ \skel = e_{0} \land \neg e_{1} \land e_{2} \land \neg e_{3} $$
  9. \hspace{-0.09cm}\scalebox{0.85}{
  10. \begin{dplltabular}{4}
  11. \dpllStep{1|2|3|4}
  12. \dpllDecL{0|0|0|0}
  13. \dpllAssi{ - |$e_{0}$|$e_{0}, \lnot e_{3}$|$e_{0}, \lnot e_{3}, \lnot e_{1}$}
  14. \dpllClause{1}{$e_{0}$}{$e_{0}$|\done|\done|\done}
  15. \dpllClause{2}{$\lnot e_{1}, e_{2}$}{$\lnot e_{1}, e_{2}$|$\lnot e_{1}, e_{2}$|$\lnot e_{1}, e_{2}$|\done}
  16. \dpllClause{3}{$\lnot e_{3}$}{$\lnot e_{3}$|$\lnot e_{3}$|\done|\done}
  17. \dpllBCP{$e_{0}$|$\lnot e_{3}$| - | - }
  18. \dpllPL{ - | - |$\lnot e_{1}$| - }
  19. \dpllDeci{ - | - | - | - }
  20. \end{dplltabular}
  21. }
  22. A satisfying assignment $e_0 \land \neg e_1 \land \neg e_3$ has been found and
  23. we have to check consistency of $(g(a) = c) \land (f(g(a)) \neq f(c)) \land (c \neq d) $:
  24. \begin{align*}
  25. &\{g(a), c\}, \{f(g(a))\}, \{f(c)\}, \{d\}\\
  26. &\{g(a), c\}, \{d\}, \{f(c), f(g(a))\}
  27. \end{align*}
  28. Congruence Closure returns UNSAT because of: $(f(g(a)) \neq f(c)) $.
  29. We therefore add $\neg e_0 \lor e_1 \lor e_3$ as a blocking clause and continue.
  30. \hspace{-0.09cm}\scalebox{0.85}{
  31. \begin{dplltabular}{5}
  32. \dpllStep{5|6|7|8|9}
  33. \dpllDecL{0|0|0|0|0}
  34. \dpllAssi{ - |$e_{0}$|$e_{0}, \lnot e_{3}$|$e_{0}, \lnot e_{3}, e_{1}$|\makecell{$e_{0}, \lnot e_{3}, e_{1}, $ \\ $e_{2}$}}
  35. \dpllClause{1}{$e_{0}$}{$e_{0}$|\done|\done|\done|\done}
  36. \dpllClause{2}{$\lnot e_{1}, e_{2}$}{$\lnot e_{1}, e_{2}$|$\lnot e_{1}, e_{2}$|$\lnot e_{1}, e_{2}$|$e_{2}$|\done}
  37. \dpllClause{3}{$\lnot e_{3}$}{$\lnot e_{3}$|$\lnot e_{3}$|\done|\done|\done}
  38. \dpllClause{4}{$\lnot e_{0}, e_{3}, e_{1}$}{$\lnot e_{0}, e_{3}, e_{1}$|$e_{3}, e_{1}$|$e_{1}$|\done|\done}
  39. \dpllBCP{$e_{0}$|$\lnot e_{3}$|$e_{1}$|$e_{2}$| - }
  40. \dpllPL{ - | - | - | - | - }
  41. \dpllDeci{ - | - | - | - | - }
  42. \end{dplltabular}
  43. }
  44. We have to check consistency for $(g(a) = c) \land (f(g(a)) = f(c)) \land (g(a) = d) \land (c \neq d) $:
  45. \begin{align*}
  46. &\{g(a), c\}, \{f(g(a)), f(c)\}, \{g(a), d\}\\
  47. &\{f(g(a)), f(c)\}, \{c, d, g(a)\}
  48. \end{align*}
  49. Congruence Closure returns UNSAT because of: $(c \neq d) $\\
  50. We therefore add $\neg e_0 \lor e_3 \lor \neg e_1 \lor \neg e_2$ as a blocking clause and continue.
  51. \hspace{-0.09cm}\scalebox{0.80}{
  52. \begin{dplltabular}{5}
  53. \dpllStep{10|11|12|13|14}
  54. \dpllDecL{0|0|0|0|0}
  55. \dpllAssi{ - |$e_{0}$|$e_{0}, \lnot e_{3}$|$e_{0}, \lnot e_{3}, e_{1}$|\makecell{$e_{0}, \lnot e_{3}, e_{1}, $ \\ $\lnot e_{2}$}}
  56. \dpllClause{1}{$e_{0}$}{$e_{0}$|\done|\done|\done|\done}
  57. \dpllClause{2}{$\lnot e_{1}, e_{2}$}{$\lnot e_{1}, e_{2}$|$\lnot e_{1}, e_{2}$|$\lnot e_{1}, e_{2}$|$e_{2}$|\conflict}
  58. \dpllClause{3}{$\lnot e_{3}$}{$\lnot e_{3}$|$\lnot e_{3}$|\done|\done|\done}
  59. \dpllClause{4}{$\lnot e_{0}, e_{3}, e_{1}$}{$\lnot e_{0}, e_{3}, e_{1}$|$e_{3}, e_{1}$|$e_{1}$|\done|\done}
  60. \dpllClause{5}{$\lnot e_{0}, e_{3}, \lnot e_{1}, \lnot e_{2}$}{\makecell{$\lnot e_{0}, e_{3}, \lnot e_{1}, $ \\ $\lnot e_{2}$}|$e_{3}, \lnot e_{1}, \lnot e_{2}$|$\lnot e_{1}, \lnot e_{2}$|$\lnot e_{2}$|\done}
  61. \dpllBCP{$e_{0}$|$\lnot e_{3}$|$e_{1}$|$\lnot e_{2}$| - }
  62. \dpllPL{ - | - | - | - | - }
  63. \dpllDeci{ - | - | - | - |UNSAT}
  64. \end{dplltabular}
  65. }
  66. Conflict in step 14\\
  67. \scalebox{0.75}{
  68. \begin{tikzpicture}[>=latex,line join=bevel,]
  69. \pgfsetlinewidth{1bp}
  70. %%
  71. \pgfsetcolor{black}
  72. % Edge: 0 -> 2
  73. \draw [->] (1.0882bp,62.277bp) .. controls (1.964bp,62.779bp) and (9.2748bp,62.662bp) .. (19.0bp,62.429bp) .. controls (30.239bp,62.537bp) and (43.981bp,61.976bp) .. (65.01bp,63.663bp);
  74. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  75. \pgfsetstrokecolor{strokecol}
  76. \draw (33.0bp,70.929bp) node {$$1$$};
  77. % Edge: 0 -> 4
  78. \draw [->] (1.0536bp,100.444bp) .. controls (2.5288bp,100.842bp) and (34.108bp,100.377bp) .. (65.302bp,102.81bp);
  79. \draw (33.0bp,107.93bp) node {$$3$$};
  80. % Edge: 2 -> 5
  81. \draw [->] (84.139bp,57.437bp) .. controls (89.42bp,51.96bp) and (97.049bp,44.903bp) .. (105.0bp,40.429bp) .. controls (117.15bp,33.594bp) and (132.19bp,29.057bp) .. (153.87bp,24.136bp);
  82. \draw (119.0bp,47.929bp) node {$$4$$};
  83. % Edge: 2 -> 6
  84. \draw [->] (87.223bp,65.255bp) .. controls (115.41bp,64.774bp) and (194.66bp,63.424bp) .. (242.75bp,62.604bp);
  85. \draw (165.0bp,70.929bp) node {$$5$$};
  86. % Edge: 3 -> 1
  87. \draw [->] (264.67bp,18.652bp) .. controls (272.24bp,21.175bp) and (283.02bp,24.768bp) .. (302.09bp,31.126bp);
  88. % Edge: 4 -> 5
  89. \draw [->] (85.379bp,99.325bp) .. controls (96.698bp,90.91bp) and (117.27bp,75.011bp) .. (133.0bp,59.429bp) .. controls (139.39bp,53.105bp) and (145.86bp,45.585bp) .. (157.76bp,30.745bp);
  90. \draw (119.0bp,89.929bp) node {$$4$$};
  91. % Edge: 4 -> 6
  92. \draw [->] (87.393bp,105.29bp) .. controls (98.691bp,105.0bp) and (117.24bp,104.11bp) .. (133.0bp,101.43bp) .. controls (174.77bp,94.331bp) and (185.41bp,91.533bp) .. (225.0bp,76.429bp) .. controls (228.25bp,75.189bp) and (231.62bp,73.694bp) .. (243.87bp,67.569bp);
  93. \draw (165.0bp,104.93bp) node {$$5$$};
  94. % Edge: 5 -> 3
  95. \draw [->] (173.78bp,15.592bp) .. controls (179.69bp,10.872bp) and (188.28bp,4.9991bp) .. (197.0bp,2.4291bp) .. controls (208.94bp,-1.0874bp) and (212.85bp,-0.25425bp) .. (225.0bp,2.4291bp) .. controls (228.24bp,3.1456bp) and (231.56bp,4.2776bp) .. (244.02bp,10.039bp);
  96. \draw (211.0bp,9.9291bp) node {$$2$$};
  97. % Edge: 5 -> 6
  98. \draw [->] (176.04bp,24.306bp) .. controls (188.14bp,26.832bp) and (208.86bp,32.005bp) .. (225.0bp,40.429bp) .. controls (229.31bp,42.678bp) and (233.61bp,45.621bp) .. (245.22bp,55.023bp);
  99. \draw (211.0bp,47.929bp) node {$$5$$};
  100. % Edge: 6 -> 1
  101. \draw [->] (264.16bp,57.93bp) .. controls (272.09bp,54.035bp) and (283.8bp,48.281bp) .. (302.68bp,39.01bp);
  102. % Node: 2
  103. \begin{scope}
  104. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  105. \pgfsetstrokecolor{strokecol}
  106. \draw (76.0bp,65.43bp) ellipse (11.0bp and 11.0bp);
  107. \draw (76.0bp,65.429bp) node {$e_{0}$};
  108. \end{scope}
  109. % Node: 4
  110. \begin{scope}
  111. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  112. \pgfsetstrokecolor{strokecol}
  113. \draw (76.0bp,105.43bp) ellipse (11.0bp and 11.0bp);
  114. \draw (76.0bp,105.43bp) node {$\lnot e_{3}$};
  115. \end{scope}
  116. % Node: 1
  117. \begin{scope}
  118. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  119. \pgfsetstrokecolor{strokecol}
  120. \draw (313.0bp,34.43bp) ellipse (11.0bp and 11.0bp);
  121. \draw (313.0bp,34.429bp) node {$\bot$};
  122. \end{scope}
  123. % Node: 5
  124. \begin{scope}
  125. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  126. \pgfsetstrokecolor{strokecol}
  127. \draw (165.0bp,22.43bp) ellipse (11.0bp and 11.0bp);
  128. \draw (165.0bp,22.429bp) node {$e_{1}$};
  129. \end{scope}
  130. % Node: 6
  131. \begin{scope}
  132. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  133. \pgfsetstrokecolor{strokecol}
  134. \draw (254.0bp,62.43bp) ellipse (11.0bp and 11.0bp);
  135. \draw (254.0bp,62.429bp) node {$\lnot e_{2}$};
  136. \end{scope}
  137. % Node: 3
  138. \begin{scope}
  139. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  140. \pgfsetstrokecolor{strokecol}
  141. \draw (254.0bp,15.43bp) ellipse (11.0bp and 11.0bp);
  142. \draw (254.0bp,15.429bp) node {$e_{2}$};
  143. \end{scope}
  144. %
  145. \end{tikzpicture}
  146. }
  147. \begin{prooftree}
  148. \AxiomC{$2. \; \lnot e_{1} \lor e_{2}$}
  149. \AxiomC{$5. \; \lnot e_{0} \lor e_{3} \lor \lnot e_{1} \lor \lnot e_{2}$}
  150. \BinaryInfC{$\lnot e_{1} \lor \lnot e_{0} \lor e_{3}$}
  151. \AxiomC{$4. \; \lnot e_{0} \lor e_{3} \lor e_{1}$}
  152. \BinaryInfC{$\lnot e_{0} \lor e_{3}$}
  153. \AxiomC{$1. \; e_{0}$}
  154. \BinaryInfC{$e_{3}$}
  155. \AxiomC{$3. \; \lnot e_{3}$}
  156. \BinaryInfC{$\bot$}
  157. \end{prooftree}
  158. Since the SAT solver cannot find a satisfying assignment we are done and conclude that $\varphi$ is UNSAT.