1
SAT本地搜索的支持数据结构
WalkSAT和GSAT是解决布尔可满足性问题的众所周知的简单本地搜索算法。从实现GSAT算法-如何选择要翻转的文字的问题中复制了GSAT算法的伪代码。并在下面介绍。 procedure GSAT(A,Max_Tries,Max_Flips) A: is a CNF formula for i:=1 to Max_Tries do S <- instantiation of variables for j:=1 to Max_Iter do if A satisfiable by S then return S endif V <- the variable whose flip yield the most important raise in the number of satisfied clauses; S …