Parcourir la source

Fix DSATUR psuedocode: 'v' should be 'u'

Ryan Newton il y a 7 ans
Parent
commit
566e0d8f44
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      book.tex

+ 1 - 1
book.tex

@@ -2405,7 +2405,7 @@ Output: an assignment |$\mathrm{color}[v]$| for each node |$v \in G$|
 while |$W \neq \emptyset$| do
     pick a node |$u$| from |$W$| with the highest saturation,
         breaking ties randomly
-    find the lowest color |$c$| that is not in |$\{ \mathrm{color}[v] \;:\; v \in \mathrm{adjacent}(v)\}$|
+    find the lowest color |$c$| that is not in |$\{ \mathrm{color}[v] \;:\; v \in \mathrm{adjacent}(u)\}$|
     |$\mathrm{color}[u] \gets c$|
     |$W \gets W - \{u\}$|
 \end{lstlisting}