copilot-theorem-3.2.1: k-induction for Copilot.
Safe HaskellTrustworthy
LanguageHaskell2010

Copilot.Theorem.Prover.SMT

Description

Connections to various SMT solvers and theorem provers.

Synopsis

Backends

data Backend a Source #

Backend to an SMT solver or theorem prover.

class Show a => SmtFormat a Source #

Format of SMT-Lib commands.

Minimal complete definition

push, pop, checkSat, setLogic, declFun, assert

Instances

Instances details
SmtFormat SmtLib Source #

Interface for SMT-Lib conforming backends.

Instance details

Defined in Copilot.Theorem.Prover.SMTLib

Methods

push :: SmtLib

pop :: SmtLib

checkSat :: SmtLib

setLogic :: String -> SmtLib

declFun :: String -> Type -> [Type] -> SmtLib

assert :: Expr -> SmtLib

SmtFormat Tptp Source # 
Instance details

Defined in Copilot.Theorem.Prover.TPTP

Methods

push :: Tptp

pop :: Tptp

checkSat :: Tptp

setLogic :: String -> Tptp

declFun :: String -> Type -> [Type] -> Tptp

assert :: Expr -> Tptp

data SmtLib Source #

Type used to represent SMT-lib commands.

Use the interface in SmtFormat to create such commands.

Instances

Instances details
Show SmtLib Source # 
Instance details

Defined in Copilot.Theorem.Prover.SMTLib

Methods

showsPrec :: Int -> SmtLib -> ShowS

show :: SmtLib -> String

showList :: [SmtLib] -> ShowS

SmtFormat SmtLib Source #

Interface for SMT-Lib conforming backends.

Instance details

Defined in Copilot.Theorem.Prover.SMTLib

Methods

push :: SmtLib

pop :: SmtLib

checkSat :: SmtLib

setLogic :: String -> SmtLib

declFun :: String -> Type -> [Type] -> SmtLib

assert :: Expr -> SmtLib

data Tptp Source #

Type used to represent TPTP expressions.

Although this type implements the SmtFormat interface, only assert is actually used.

Instances

Instances details
Show Tptp Source # 
Instance details

Defined in Copilot.Theorem.Prover.TPTP

Methods

showsPrec :: Int -> Tptp -> ShowS

show :: Tptp -> String

showList :: [Tptp] -> ShowS

SmtFormat Tptp Source # 
Instance details

Defined in Copilot.Theorem.Prover.TPTP

Methods

push :: Tptp

pop :: Tptp

checkSat :: Tptp

setLogic :: String -> Tptp

declFun :: String -> Type -> [Type] -> Tptp

assert :: Expr -> Tptp

yices :: Backend SmtLib Source #

Backend to the Yices 2 SMT solver.

It enables non-linear arithmetic (QF_NRA), which means MCSat will be used.

The command yices-smt2 must be in the user's PATH.

dReal :: Backend SmtLib Source #

Backend to the dReal SMT solver.

It enables non-linear arithmetic (QF_NRA).

The libraries for dReal must be installed and perl must be in the user's PATH.

altErgo :: Backend SmtLib Source #

Backend to the Alt-Ergo SMT solver.

It enables support for uninterpreted functions and mixed nonlinear arithmetic (QF_NIRA).

The command alt-ergo.opt must be in the user's PATH.

metit :: String -> Backend Tptp Source #

Backend to the MetiTaski theorem prover.

The command metit must be in the user's PATH.

The argument string is the path to the tptp subdirectory of the metitarski install location.

z3 :: Backend SmtLib Source #

Backend to the Z3 theorem prover.

The command z3 must be in the user's PATH.

cvc4 :: Backend SmtLib Source #

Backend to the cvc4 SMT solver.

It enables support for uninterpreted functions and mixed nonlinear arithmetic (QF_NIRA).

The command cvc4 must be in the user's PATH.

mathsat :: Backend SmtLib Source #

Backend to the Mathsat SMT solver.

It enables non-linear arithmetic (QF_NRA).

The command mathsat must be in the user's PATH.

Tactics

data Options Source #

Options to configure the provers.

Constructors

Options 

Fields

  • startK :: Word32

    Initial k for the k-induction algorithm.

  • maxK :: Word32

    The maximum number of steps of the k-induction algorithm the prover runs before giving up.

  • debug :: Bool

    If debug is set to True, the SMTLib/TPTP queries produced by the prover are displayed in the standard output.

Instances

Instances details
Default Options Source #

Default Options with a 0 k and a max of 10 steps, and that produce no debugging info.

Instance details

Defined in Copilot.Theorem.Prover.SMT

Methods

def :: Options #

induction :: SmtFormat a => Options -> Backend a -> Proof Universal Source #

Tactic to find a proof by standard 1-induction.

The values for startK and maxK in the options are ignored.

kInduction :: SmtFormat a => Options -> Backend a -> Proof Universal Source #

Tactic to find a proof by k-induction.

onlySat :: SmtFormat a => Options -> Backend a -> Proof Existential Source #

Tactic to find only a proof of satisfiability.

onlyValidity :: SmtFormat a => Options -> Backend a -> Proof Universal Source #

Tactic to find only a proof of validity.

Auxiliary

class Default a where #

A class for types with a default value.

Minimal complete definition

Nothing

Methods

def :: a #

The default value for this type.

Instances

Instances details
Default Double 
Instance details

Defined in Data.Default.Class

Methods

def :: Double #

Default Float 
Instance details

Defined in Data.Default.Class

Methods

def :: Float #

Default Int 
Instance details

Defined in Data.Default.Class

Methods

def :: Int #

Default Int8 
Instance details

Defined in Data.Default.Class

Methods

def :: Int8 #

Default Int16 
Instance details

Defined in Data.Default.Class

Methods

def :: Int16 #

Default Int32 
Instance details

Defined in Data.Default.Class

Methods

def :: Int32 #

Default Int64 
Instance details

Defined in Data.Default.Class

Methods

def :: Int64 #

Default Integer 
Instance details

Defined in Data.Default.Class

Methods

def :: Integer #

Default Ordering 
Instance details

Defined in Data.Default.Class

Methods

def :: Ordering #

Default Word 
Instance details

Defined in Data.Default.Class

Methods

def :: Word #

Default Word8 
Instance details

Defined in Data.Default.Class

Methods

def :: Word8 #

Default Word16 
Instance details

Defined in Data.Default.Class

Methods

def :: Word16 #

Default Word32 
Instance details

Defined in Data.Default.Class

Methods

def :: Word32 #

Default Word64 
Instance details

Defined in Data.Default.Class

Methods

def :: Word64 #

Default () 
Instance details

Defined in Data.Default.Class

Methods

def :: () #

Default All 
Instance details

Defined in Data.Default.Class

Methods

def :: All #

Default Any 
Instance details

Defined in Data.Default.Class

Methods

def :: Any #

Default CUShort 
Instance details

Defined in Data.Default.Class

Methods

def :: CUShort #

Default CUSeconds 
Instance details

Defined in Data.Default.Class

Methods

def :: CUSeconds #

Default CULong 
Instance details

Defined in Data.Default.Class

Methods

def :: CULong #

Default CULLong 
Instance details

Defined in Data.Default.Class

Methods

def :: CULLong #

Default CUIntPtr 
Instance details

Defined in Data.Default.Class

Methods

def :: CUIntPtr #

Default CUIntMax 
Instance details

Defined in Data.Default.Class

Methods

def :: CUIntMax #

Default CUInt 
Instance details

Defined in Data.Default.Class

Methods

def :: CUInt #

Default CTime 
Instance details

Defined in Data.Default.Class

Methods

def :: CTime #

Default CSize 
Instance details

Defined in Data.Default.Class

Methods

def :: CSize #

Default CSigAtomic 
Instance details

Defined in Data.Default.Class

Methods

def :: CSigAtomic #

Default CShort 
Instance details

Defined in Data.Default.Class

Methods

def :: CShort #

Default CSUSeconds 
Instance details

Defined in Data.Default.Class

Methods

def :: CSUSeconds #

Default CPtrdiff 
Instance details

Defined in Data.Default.Class

Methods

def :: CPtrdiff #

Default CLong 
Instance details

Defined in Data.Default.Class

Methods

def :: CLong #

Default CLLong 
Instance details

Defined in Data.Default.Class

Methods

def :: CLLong #

Default CIntPtr 
Instance details

Defined in Data.Default.Class

Methods

def :: CIntPtr #

Default CIntMax 
Instance details

Defined in Data.Default.Class

Methods

def :: CIntMax #

Default CFloat 
Instance details

Defined in Data.Default.Class

Methods

def :: CFloat #

Default CDouble 
Instance details

Defined in Data.Default.Class

Methods

def :: CDouble #

Default CClock 
Instance details

Defined in Data.Default.Class

Methods

def :: CClock #

Default CInt 
Instance details

Defined in Data.Default.Class

Methods

def :: CInt #

Default Options Source #

Default Options with a 0 k and a max of 10 steps, and that produce no debugging info.

Instance details

Defined in Copilot.Theorem.Prover.SMT

Methods

def :: Options #

Default Options Source #

Default options with unlimited unrolling for base and step.

Instance details

Defined in Copilot.Theorem.Kind2.Prover

Methods

def :: Options #

Default [a] 
Instance details

Defined in Data.Default.Class

Methods

def :: [a] #

Default (Maybe a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Maybe a #

Integral a => Default (Ratio a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Ratio a #

Default a => Default (IO a) 
Instance details

Defined in Data.Default.Class

Methods

def :: IO a #

(Default a, RealFloat a) => Default (Complex a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Complex a #

Default (Endo a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Endo a #

Num a => Default (Sum a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Sum a #

Num a => Default (Product a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Product a #

Default (Last a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Last a #

Default (First a) 
Instance details

Defined in Data.Default.Class

Methods

def :: First a #

Default a => Default (Dual a) 
Instance details

Defined in Data.Default.Class

Methods

def :: Dual a #

Default r => Default (e -> r) 
Instance details

Defined in Data.Default.Class

Methods

def :: e -> r #

(Default a, Default b) => Default (a, b) 
Instance details

Defined in Data.Default.Class

Methods

def :: (a, b) #

(Default a, Default b, Default c) => Default (a, b, c) 
Instance details

Defined in Data.Default.Class

Methods

def :: (a, b, c) #

(Default a, Default b, Default c, Default d) => Default (a, b, c, d) 
Instance details

Defined in Data.Default.Class

Methods

def :: (a, b, c, d) #

(Default a, Default b, Default c, Default d, Default e) => Default (a, b, c, d, e) 
Instance details

Defined in Data.Default.Class

Methods

def :: (a, b, c, d, e) #

(Default a, Default b, Default c, Default d, Default e, Default f) => Default (a, b, c, d, e, f) 
Instance details

Defined in Data.Default.Class

Methods

def :: (a, b, c, d, e, f) #

(Default a, Default b, Default c, Default d, Default e, Default f, Default g) => Default (a, b, c, d, e, f, g) 
Instance details

Defined in Data.Default.Class

Methods

def :: (a, b, c, d, e, f, g) #