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.

159 lines
6.6 KiB

9 months ago
  1. \begin{cofactors}
  2. $f$ \= $= (((p \land q) \lor (r \land s)) \lor (\lnot p \land \lnot r))$\\
  3. \>$f_{s}$ \= $= (((p \land q) \lor r) \lor (\lnot p \land \lnot r))$\\
  4. \>\>$f_{sr}$ \= $= \true$\\
  5. \>\>$f_{s\lnot r}$ \= $= ((p \land q) \lor \lnot p)$\\
  6. \>\>\>$f_{s\lnot rq}$ \= $= \true$\\
  7. \>\>\>$f_{s\lnot r\lnot q}$ \= $= \lnot p$\\
  8. \>\>\>\>$f_{s\lnot r\lnot qp}$ \= $= \false$\\
  9. \>\>\>\>$f_{s\lnot r\lnot q\lnot p}$ \= $= \true$\\
  10. \>$f_{\lnot s}$ \= $= ((p \land q) \lor (\lnot p \land \lnot r))$\\
  11. \>\>$f_{\lnot sr}$ \= $= (p \land q)$\\
  12. \>\>\>$f_{\lnot srq}$ \= $= \lnot f_{s\lnot r\lnot q}$\\
  13. \>\>\>$f_{\lnot sr\lnot q}$ \= $= \false$\\
  14. \>\>$f_{\lnot s\lnot r}$ \= $= f_{s\lnot r}$\\
  15. \end{cofactors}
  16. The final ROBDD:
  17. \begin{center}
  18. \scalebox{0.75}{
  19. \begin{tikzpicture}[>=latex,line join=bevel,]
  20. \pgfsetlinewidth{1bp}
  21. %%
  22. \pgfsetcolor{black}
  23. % Edge: f_E -> s0
  24. \draw [] (123.5bp,268.99bp) .. controls (123.5bp,258.92bp) and (123.5bp,243.47bp) .. (123.5bp,233.3bp);
  25. % Edge: f_s -> r1
  26. \draw [] (174.5bp,210.99bp) .. controls (174.5bp,200.92bp) and (174.5bp,185.47bp) .. (174.5bp,175.3bp);
  27. % Edge: f_s!r -> q2
  28. \draw [] (123.5bp,152.99bp) .. controls (123.5bp,142.92bp) and (123.5bp,127.47bp) .. (123.5bp,117.3bp);
  29. % Edge: f_s!r!q -> p3
  30. \draw [] (72.5bp,94.988bp) .. controls (72.5bp,84.921bp) and (72.5bp,69.474bp) .. (72.5bp,59.304bp);
  31. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  32. \pgfsetstrokecolor{strokecol}
  33. \draw (72.5bp,79.304bp) node {\Large$\bullet$};
  34. % Edge: f_!s -> r4
  35. \draw [] (72.5bp,210.99bp) .. controls (72.5bp,200.92bp) and (72.5bp,185.47bp) .. (72.5bp,175.3bp);
  36. % Edge: f_!sr -> q5
  37. \draw [] (21.5bp,152.99bp) .. controls (21.5bp,142.92bp) and (21.5bp,127.47bp) .. (21.5bp,117.3bp);
  38. % Edge: s0 -> r4
  39. \draw [] (116.41bp,213.21bp) .. controls (106.66bp,202.51bp) and (89.243bp,183.38bp) .. (79.531bp,172.72bp);
  40. \draw (92.998bp,187.51bp) node {\Large$\circ$};
  41. % Edge: s0 -> r1
  42. \draw [] (130.59bp,213.21bp) .. controls (140.34bp,202.51bp) and (157.76bp,183.38bp) .. (167.47bp,172.72bp);
  43. % Edge: r4 -> q5
  44. \draw [] (65.409bp,155.21bp) .. controls (55.665bp,144.51bp) and (38.243bp,125.38bp) .. (28.531bp,114.72bp);
  45. % Edge: r4 -> q2
  46. \draw [] (79.591bp,155.21bp) .. controls (89.335bp,144.51bp) and (106.76bp,125.38bp) .. (116.47bp,114.72bp);
  47. \draw (103.0bp,129.51bp) node {\Large$\circ$};
  48. % Edge: q5 -> p3
  49. \draw [] (28.591bp,97.213bp) .. controls (38.335bp,86.514bp) and (55.757bp,67.385bp) .. (65.469bp,56.72bp);
  50. % Edge: q5 -> 4
  51. \draw [] (21.5bp,94.988bp) .. controls (21.5bp,79.384bp) and (21.5bp,50.854bp) .. (21.5bp,49.086bp);
  52. \draw (21.5bp,69.086bp) node {\Large$\bullet$};
  53. % Edge: r1 -> q2
  54. \draw [] (167.41bp,155.21bp) .. controls (157.66bp,144.51bp) and (140.24bp,125.38bp) .. (130.53bp,114.72bp);
  55. \draw (144.0bp,129.51bp) node {\Large$\circ$};
  56. % Edge: r1 -> 0
  57. \draw [] (174.5bp,152.99bp) .. controls (174.5bp,137.38bp) and (174.5bp,108.85bp) .. (174.5bp,107.09bp);
  58. % Edge: q2 -> p3
  59. \draw [] (116.41bp,97.213bp) .. controls (106.66bp,86.514bp) and (89.243bp,67.385bp) .. (79.531bp,56.72bp);
  60. \draw (92.998bp,71.507bp) node {\Large$\bullet$};
  61. % Edge: q2 -> 1
  62. \draw [] (123.5bp,94.988bp) .. controls (123.5bp,79.384bp) and (123.5bp,50.854bp) .. (123.5bp,49.086bp);
  63. % Edge: p3 -> 2
  64. \draw [] (70.281bp,36.791bp) .. controls (67.427bp,23.663bp) and (62.8bp,2.3815bp) .. (62.514bp,1.0642bp);
  65. % Edge: p3 -> 3
  66. \draw [] (74.497bp,36.791bp) .. controls (77.066bp,23.663bp) and (81.23bp,2.3815bp) .. (81.487bp,1.0642bp);
  67. \draw (77.647bp,20.692bp) node {\Large$\bullet$};
  68. % Node: f_E
  69. \begin{scope}
  70. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  71. \pgfsetstrokecolor{strokecol}
  72. \draw (145.0bp,291.0bp) -- (102.0bp,291.0bp) -- (102.0bp,269.0bp) -- (145.0bp,269.0bp) -- cycle;
  73. \draw (123.5bp,280.0bp) node {$f$};
  74. \end{scope}
  75. % Node: s0
  76. \begin{scope}
  77. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  78. \pgfsetstrokecolor{strokecol}
  79. \draw (123.5bp,222.0bp) ellipse (11.0bp and 11.0bp);
  80. \draw (123.5bp,222.0bp) node {$s$};
  81. \end{scope}
  82. % Node: f_s
  83. \begin{scope}
  84. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  85. \pgfsetstrokecolor{strokecol}
  86. \draw (196.0bp,233.0bp) -- (153.0bp,233.0bp) -- (153.0bp,211.0bp) -- (196.0bp,211.0bp) -- cycle;
  87. \draw (174.5bp,222.0bp) node {$f_{s}$};
  88. \end{scope}
  89. % Node: r1
  90. \begin{scope}
  91. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  92. \pgfsetstrokecolor{strokecol}
  93. \draw (174.5bp,164.0bp) ellipse (11.0bp and 11.0bp);
  94. \draw (174.5bp,164.0bp) node {$r$};
  95. \end{scope}
  96. % Node: f_s!r
  97. \begin{scope}
  98. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  99. \pgfsetstrokecolor{strokecol}
  100. \draw (145.0bp,175.0bp) -- (102.0bp,175.0bp) -- (102.0bp,153.0bp) -- (145.0bp,153.0bp) -- cycle;
  101. \draw (123.5bp,164.0bp) node {$f_{s\lnot r}$};
  102. \end{scope}
  103. % Node: q2
  104. \begin{scope}
  105. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  106. \pgfsetstrokecolor{strokecol}
  107. \draw (123.5bp,106.0bp) ellipse (11.0bp and 11.0bp);
  108. \draw (123.5bp,106.0bp) node {$q$};
  109. \end{scope}
  110. % Node: f_s!r!q
  111. \begin{scope}
  112. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  113. \pgfsetstrokecolor{strokecol}
  114. \draw (94.0bp,117.0bp) -- (51.0bp,117.0bp) -- (51.0bp,95.0bp) -- (94.0bp,95.0bp) -- cycle;
  115. \draw (72.5bp,106.0bp) node {$f_{s\lnot r\lnot q}$};
  116. \end{scope}
  117. % Node: p3
  118. \begin{scope}
  119. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  120. \pgfsetstrokecolor{strokecol}
  121. \draw (72.5bp,48.0bp) ellipse (11.0bp and 11.0bp);
  122. \draw (72.5bp,48.0bp) node {$p$};
  123. \end{scope}
  124. % Node: f_!s
  125. \begin{scope}
  126. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  127. \pgfsetstrokecolor{strokecol}
  128. \draw (94.0bp,233.0bp) -- (51.0bp,233.0bp) -- (51.0bp,211.0bp) -- (94.0bp,211.0bp) -- cycle;
  129. \draw (72.5bp,222.0bp) node {$f_{\lnot s}$};
  130. \end{scope}
  131. % Node: r4
  132. \begin{scope}
  133. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  134. \pgfsetstrokecolor{strokecol}
  135. \draw (72.5bp,164.0bp) ellipse (11.0bp and 11.0bp);
  136. \draw (72.5bp,164.0bp) node {$r$};
  137. \end{scope}
  138. % Node: f_!sr
  139. \begin{scope}
  140. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  141. \pgfsetstrokecolor{strokecol}
  142. \draw (43.0bp,175.0bp) -- (0.0bp,175.0bp) -- (0.0bp,153.0bp) -- (43.0bp,153.0bp) -- cycle;
  143. \draw (21.5bp,164.0bp) node {$f_{\lnot sr}$};
  144. \end{scope}
  145. % Node: q5
  146. \begin{scope}
  147. \definecolor{strokecol}{rgb}{0.0,0.0,0.0};
  148. \pgfsetstrokecolor{strokecol}
  149. \draw (21.5bp,106.0bp) ellipse (11.0bp and 11.0bp);
  150. \draw (21.5bp,106.0bp) node {$q$};
  151. \end{scope}
  152. %
  153. \end{tikzpicture}
  154. }
  155. \end{center}