smt

Efficient way to “keep turning the crank” on a stateful computation

依然范特西╮ 提交于 2020-08-08 06:12:26
问题 I have a stateful process that is modelled as an i -> RWS r w s a . I want to feed it an input cmds :: [i] ; currently I do that wholesale: let play = runGame theGame . go where go [] = finished go ((v, n):cmds) = do end1 <- stepWorld end2 <- ite (SBV.isJust end1) (return end1) $ stepPlayer (v, n) ite (SBV.isJust end2) (return end2) $ go cmds I can try searching for an input of a predetermined size like this: result <- satWith z3{ verbose = True } $ do cmds <- mapM sCmd [1..inputLength]

Incremental Learning using MAXSMT

别来无恙 提交于 2020-07-23 11:01:06
问题 Can we use the previous solution of a MaxSMT solver (optimize) in an incremental way in z3? Also, Is there any way to print out the soft assertions on the optimizer? 回答1: The answer is YES if you are asking whether it is technically possible to run either z3 or OptiMathSAT incrementally with a MaxSMT problem. (Use the API). All soft-clauses with the same id --at the moment in which one performs a check-sat -- are considered part of the same MaxSMT goal. In essence, the OMT solver evaluates

Incremental Learning using MAXSMT

别说谁变了你拦得住时间么 提交于 2020-07-23 10:58:23
问题 Can we use the previous solution of a MaxSMT solver (optimize) in an incremental way in z3? Also, Is there any way to print out the soft assertions on the optimizer? 回答1: The answer is YES if you are asking whether it is technically possible to run either z3 or OptiMathSAT incrementally with a MaxSMT problem. (Use the API). All soft-clauses with the same id --at the moment in which one performs a check-sat -- are considered part of the same MaxSMT goal. In essence, the OMT solver evaluates

Incremental Learning using MAXSMT

一笑奈何 提交于 2020-07-23 10:58:09
问题 Can we use the previous solution of a MaxSMT solver (optimize) in an incremental way in z3? Also, Is there any way to print out the soft assertions on the optimizer? 回答1: The answer is YES if you are asking whether it is technically possible to run either z3 or OptiMathSAT incrementally with a MaxSMT problem. (Use the API). All soft-clauses with the same id --at the moment in which one performs a check-sat -- are considered part of the same MaxSMT goal. In essence, the OMT solver evaluates

How do I debug missing variables from SMT-Lib output?

放肆的年华 提交于 2020-07-23 06:24:27
问题 Based on this very helpful answer I rewrote my solver-for-a-stateful-program to use the Query monad and an ever-increasing list of SMT variables standing for the inputs. I expected one of two outcomes from this: either the first part (generating the SMTLib output) is sped up a lot and becomes usable, or it still remains so slow that it might as well not work. However, instead I get an error message from the SMT solver (Z3 in my case) complaining about a missing SMT variable in the SMTLib