@@ -198,7 +198,7 @@ Performs any post-processing, which is normally adding constraints that
198
198
require some global knowledge of the formula, ex. for encoding arrays
199
199
into uninterpreted functions.
200
200
201
- Some key classes:
201
+ ** Some key classes:**
202
202
203
203
\ref propt is instance of whichever solver is currently being used. This
204
204
inherits from ` decision_proceduret ` whose interface has a fuller explanation
@@ -228,7 +228,44 @@ To be documented.
228
228
229
229
\subsection sat-solving-api-section SAT solving API
230
230
231
- To be documented.
231
+ The basic SAT solver interface is in [ cnf] (\ref cnft). This inherits
232
+ from the [ propositional logic decision procedure wrapper] (\ref propt).
233
+
234
+ The interface supports the following operations by default:
235
+ 1 . Boolean operations on literals (like ` and ` , ` or ` , ` xor ` ), etc.
236
+ These take as input two [ literal] (\ref literalt) and return as
237
+ output another [ literal] (\ref literalt).
238
+ 2 . Generating new [ literals] (\ref literalt) and adding them
239
+ as variables to the formula and returning the number of variables
240
+ or clauses the solver is operating with (with ` no_variables ` ).
241
+ 3 . Simulate gate operations on literals, applying Tseitin's
242
+ transformation on them. Tseitin's transformation converts a
243
+ propositional formula ` F ` into an equisatisfiable CNF formula
244
+ that is linear in the size of ` F ` .
245
+
246
+ This interface is then extended by the various solver interfaces
247
+ which implemenet the interface by hooking into the solver
248
+ related functions that implement the operations that they
249
+ abstract. Solvers for which specific drivers exist include Minisat,
250
+ Minisat2, Chaff, Picosat, Glucose, Cadical, Booleforce and Lingeling.
251
+
252
+ As an example of that, the Minisat 2 interface (in ` satcheck_minisat2.h ` )
253
+ implements a method ` prop_solve() ` that hooks into Minisat 2's
254
+ interface by initialising the variable list Minisat 2 will use,
255
+ and then invoking the actual solver on the formula and checking
256
+ whether the solver could manage find a satisfying assignment or
257
+ not.
258
+
259
+ For more details on how the particular drivers work, please refer
260
+ to them in their interface and implementation files, which follow
261
+ the naming pattern ` satcheck_x ` , where ` x ` is the name of the
262
+ solver.
263
+
264
+ We also support any solver that can hook into ` ipasir ` . This is a
265
+ generic incremental SAT solver API. This is handled by the
266
+ ` satcheck_ipasir.h ` interface abstracts over ` ipasir ` with our own
267
+ generic interface. For a description of the ` ipasir ` interface
268
+ please take a look at the following file: [ ipasir.h] ( https://github.com/biotomas/ipasir/blob/master/ipasir.h )
232
269
233
270
\section sat-smt-encoding SAT/SMT Encoding
234
271
0 commit comments