SAT-canonical-0.1.0.0

Safe HaskellSafe
LanguageHaskell2010

Heuristics

Synopsis

Documentation

type Heuristics = Set FProp -> [VarProp] -> [VarProp] Source #

The Heuristic data type indicates the order in which variables are forgotten.

vars :: FProp -> [VarProp] Source #

For example,

>>> vars (p ∧ q → p)
["p","q"]

frequency :: Heuristics Source #

( frequency ps vs ) is the list of variables vs sorted by frequency of occurrence in ps. For example:

>>> [x1,x2] = map var ["x1","x2"] :: [PolF2]
>>> frequency (S.fromList [x1,x2,x1+1]) [x1,x2]
[x2,x1]

revFreq :: Heuristics Source #

( revFreq ps vs ) is the list of variables vs ordered in reverse order of frequency in ps. For example:

>>> [x1,x2] = map var ["x1","x2"] :: [PolF2]
>>> revFreq (S.fromList [x1,x2,x1+1]) [x1,x2]
[x1,x2]