Expand description
§Z3
Z3 is a theorem prover from Microsoft Research.
This crate provides low-level bindings that provide no real affordances for usage from Rust and that mirror the C API.
For bindings that are easier to use from Rust, see the higher level bindings in the Z3 crate.
§Build configuration
This crate needs to locate a Z3 library at build time. The method is controlled by Cargo features and environment variables.
§Features
| Feature | Behaviour |
|---|---|
| (default) | Link against a system-installed Z3 (brew install z3, etc.) |
bundled | Build Z3 from source using cmake and statically link it |
gh-release | Build against a pre-compiled Z3 static library from GitHub Releases |
vcpkg | Use a Z3 installed via vcpkg |
§Environment variables
§bundled feature
The bundled feature builds Z3 from source using cmake and statically
links it. Despite the name, Z3 source is not included in the crate
tarball published to crates.io. In cases where the user does not provide
the source tree, the z3-sys build.rs script must reach out to GitHub
to fetch the source tree. At build time, the build script resolves
a Z3 source tree in the following order:
Z3_SYS_BUNDLED_DIR_OVERRIDEis set — that path is used directly; no network access occurs.- Build output cache (
OUT_DIR/z3) already exists from a prior build — the cached source is reused; no network access occurs. - Local submodule (
CARGO_MANIFEST_DIR/z3) exists — only relevant when buildingz3-sysitself from its git repository, not when using it as a crate dependency. - GitHub fetch — the build script calls the GitHub Contents API to
look up which Z3 commit the
z3-sysgit submodule pointed to at the time of the current release (using thez3-sys-vX.Y.Zgit tag), then downloads and extracts that Z3 source archive intoOUT_DIR/z3.
By default, the Z3 version built is whatever commit the z3-sys release
pinned in its submodule. You can build any (compatible) Z3 version by pointing
Z3_SYS_BUNDLED_DIR_OVERRIDE at your own checkout (see below). To use a
specific version without managing source yourself, gh-release with
Z3_SYS_Z3_VERSION is a simpler alternative.
Network access: A first build from crates.io requires outbound HTTPS to
api.github.com(submodule ref lookup) andgithub.com(archive download). SetREAD_ONLY_GITHUB_TOKENto a GitHub PAT to avoid rate-limiting in CI. The downloaded source is cached inOUT_DIRand reused on subsequent builds untilcargo clean.
Using your own Z3 checkout: Set Z3_SYS_BUNDLED_DIR_OVERRIDE to the
absolute path of a Z3 source tree to skip the network fetch entirely:
Z3_SYS_BUNDLED_DIR_OVERRIDE=/absolute/path/to/z3 cargo buildTo use a project-relative path, add the following to your project’s
.cargo/config.toml. The relative = true key tells Cargo to resolve
the path relative to the config file’s location:
[env]
Z3_SYS_BUNDLED_DIR_OVERRIDE = { value = "path/to/z3", relative = true }Note: A
z3directory in your own project or workspace is not picked up automatically — you must setZ3_SYS_BUNDLED_DIR_OVERRIDEexplicitly, even if you have a Z3 git submodule in your repo.
§Other variables
| Variable | Feature | Description |
|---|---|---|
Z3_SYS_Z3_HEADER | default | Override the path to z3.h used during binding generation |
Z3_LIBRARY_PATH_OVERRIDE | default | Add an extra library search path for the linker |
Z3_SYS_Z3_VERSION | gh-release | Z3 version to download (e.g. 4.13.0) |
READ_ONLY_GITHUB_TOKEN | bundled, gh-release | GitHub PAT to avoid API rate limits in CI |
CXXSTDLIB | any | Override which C++ standard library to link (e.g. c++, stdc++) |
§Example
use z3_sys::*;
unsafe {
let cfg = Z3_mk_config().unwrap();
let ctx = Z3_mk_context(cfg).unwrap();
let a = Z3_mk_not(ctx, Z3_mk_eq(ctx, Z3_mk_false(ctx).unwrap(), Z3_mk_true(ctx).unwrap()).unwrap()).unwrap();
let b = Z3_mk_not(ctx, Z3_mk_iff(ctx, Z3_mk_false(ctx).unwrap(), Z3_mk_true(ctx).unwrap()).unwrap()).unwrap();
assert_eq!(Z3_mk_true(ctx), Z3_simplify(ctx, a));
assert_eq!(Z3_mk_true(ctx), Z3_simplify(ctx, b));
Z3_del_config(cfg);
Z3_del_context(ctx);
}Enums§
- AstKind
- The different kinds of Z3 AST (abstract syntax trees). That is, terms, formulas and types.
- AstPrint
Mode - Z3 pretty printing modes (See
Z3_set_ast_print_mode). - Decl
Kind - The different kinds of interpreted function kinds.
- Error
Code - Z3 error codes (See
Z3_get_error_code). - Goal
Prec - Precision of a given goal. Some goals can be transformed using over/under approximations.
- Param
Kind - The different kinds of parameters that can be associated with parameter sets.
(see
Z3_mk_params). - Parameter
Kind - The different kinds of parameters that can be associated with function symbols.
- Sort
Kind - The different kinds of Z3 types.
- Symbol
Kind - The different kinds of symbol.
In Z3, a symbol can be represented using integers and
strings. See
Z3_get_symbol_kind.
Constants§
Functions§
- Z3_
add_ ⚠const_ interp - Add a constant interpretation.
- Z3_
add_ ⚠func_ interp - Create a fresh
func_interpobject, add it to a model for a specified function. It has reference count 0. - Z3_
add_ ⚠rec_ def - Define the body of a recursive function.
- Z3_
algebraic_ ⚠add - Return the value
a + b. - Z3_
algebraic_ ⚠div - Return the value
a / b. - Z3_
algebraic_ ⚠eq - Return
trueifa == b, andfalseotherwise. - Z3_
algebraic_ ⚠eval - Given a multivariate polynomial
p(x_0, ..., x_{n-1}), return the sign ofp(a[0], ..., a[n-1]). - Z3_
algebraic_ ⚠ge - Return
trueifa >= b, andfalseotherwise. - Z3_
algebraic_ ⚠gt - Return
trueifa > b, andfalseotherwise. - Z3_
algebraic_ ⚠is_ neg - Return
trueifais negative, andfalseotherwise. - Z3_
algebraic_ ⚠is_ pos - Return
trueifais positive, andfalseotherwise. - Z3_
algebraic_ ⚠is_ value - Return
trueifacan be used as value in the Z3 real algebraic number package. - Z3_
algebraic_ ⚠is_ zero - Return
trueifais zero, andfalseotherwise. - Z3_
algebraic_ ⚠le - Return
trueifa <= b, andfalseotherwise. - Z3_
algebraic_ ⚠lt - Return
trueifa < b, andfalseotherwise. - Z3_
algebraic_ ⚠mul - Return the value
a * b. - Z3_
algebraic_ ⚠neq - Return
trueifa != b, andfalseotherwise. - Z3_
algebraic_ ⚠power - Return the
a^k - Z3_
algebraic_ ⚠root - Return the
a^(1/k) - Z3_
algebraic_ ⚠roots - Given a multivariate polynomial
p(x_0, ..., x_{n-1}, x_n), returns the roots of the univariate polynomialp(a[0], ..., a[n-1], x_n). - Z3_
algebraic_ ⚠sign - Return 1 if
ais positive, 0 ifais zero, and -1 ifais negative. - Z3_
algebraic_ ⚠sub - Return the value
a - b. - Z3_
app_ ⚠to_ ast - Convert a
Z3_appintoZ3_ast. This is just type casting. - Z3_
append_ ⚠log - Append user-defined string to interaction log.
- Z3_
apply_ ⚠result_ dec_ ref - Decrement the reference counter of the given
Z3_apply_resultobject. - Z3_
apply_ ⚠result_ get_ num_ subgoals - Return the number of subgoals in the
Z3_apply_resultobject returned byZ3_tactic_apply. - Z3_
apply_ ⚠result_ get_ subgoal - Return one of the subgoals in the
Z3_apply_resultobject returned byZ3_tactic_apply. - Z3_
apply_ ⚠result_ inc_ ref - Increment the reference counter of the given
Z3_apply_resultobject. - Z3_
apply_ ⚠result_ to_ string - Convert the
Z3_apply_resultobject returned byZ3_tactic_applyinto a string. - Z3_
ast_ ⚠map_ contains - Return true if the map
mcontains the AST keyk. - Z3_
ast_ ⚠map_ dec_ ref - Decrement the reference counter of the given AST map.
- Z3_
ast_ ⚠map_ erase - Erase a key from the map.
- Z3_
ast_ ⚠map_ find - Return the value associated with the key
k. - Z3_
ast_ ⚠map_ inc_ ref - Increment the reference counter of the given AST map.
- Z3_
ast_ ⚠map_ insert - Store/Replace a new key, value pair in the given map.
- Z3_
ast_ ⚠map_ keys - Return the keys stored in the given map.
- Z3_
ast_ ⚠map_ reset - Remove all keys from the given map.
- Z3_
ast_ ⚠map_ size - Return the size of the given map.
- Z3_
ast_ ⚠map_ to_ string - Convert the given map into a string.
- Z3_
ast_ ⚠to_ string - Convert the given AST node into a string.
- Z3_
ast_ ⚠vector_ dec_ ref - Decrement the reference counter of the given AST vector.
- Z3_
ast_ ⚠vector_ get - Return the AST at position
iin the AST vectorv. - Z3_
ast_ ⚠vector_ inc_ ref - Increment the reference counter of the given AST vector.
- Z3_
ast_ ⚠vector_ push - Add the AST
ain the end of the AST vectorv. The size ofvis increased by one. - Z3_
ast_ ⚠vector_ resize - Resize the AST vector
v. - Z3_
ast_ ⚠vector_ set - Update position
iof the AST vectorvwith the ASTa. - Z3_
ast_ ⚠vector_ size - Return the size of the given AST vector.
- Z3_
ast_ ⚠vector_ to_ string - Convert AST vector into a string.
- Z3_
ast_ ⚠vector_ translate - Translate the AST vector
vfrom contextsinto an AST vector in contextt. - Z3_
benchmark_ ⚠to_ smtlib_ string - Convert the given benchmark into SMT-LIB formatted string.
- Z3_
close_ ⚠log - Close interaction log.
- Z3_
datatype_ ⚠update_ field - Update record field with a value.
- Z3_
dec_ ⚠ref - Decrement the reference counter of the given AST.
The context
cshould have been created usingZ3_mk_context_rc. This function is a NOOP ifcwas created usingZ3_mk_context. - Z3_
del_ ⚠config - Delete the given configuration object.
- Z3_
del_ ⚠constructor - Reclaim memory allocated to constructor.
- Z3_
del_ ⚠constructor_ list - Reclaim memory allocated for constructor list.
- Z3_
del_ ⚠context - Delete the given logical context.
- Z3_
disable_ ⚠trace - Disable tracing messages tagged as
tagwhen Z3 is compiled in debug mode. It is a NOOP otherwise - Z3_
enable_ ⚠trace - Enable tracing messages tagged as
tagwhen Z3 is compiled in debug mode. It is a NOOP otherwise - Z3_
eval_ ⚠smtlib2_ string - Parse and evaluate and SMT-LIB2 command sequence. The state from a previous call is saved so the next evaluation builds on top of the previous call.
- Z3_
finalize_ ⚠memory - Destroy all allocated resources.
- Z3_
fixedpoint_ ⚠add_ callback - Set export callback for lemmas.
- Z3_
fixedpoint_ ⚠add_ constraint - Z3_
fixedpoint_ ⚠add_ cover - Add property about the predicate
pred. Add a property of predicatepredatlevel. It gets pushed forward when possible. - Z3_
fixedpoint_ ⚠add_ fact - Add a Database fact.
- Z3_
fixedpoint_ ⚠add_ invariant - Add an assumed invariant of predicate
pred. - Z3_
fixedpoint_ ⚠add_ rule - Add a universal Horn clause as a named rule.
The
horn_ruleshould be of the form: - Z3_
fixedpoint_ ⚠assert - Assert a constraint to the fixedpoint context.
- Z3_
fixedpoint_ ⚠dec_ ref - Decrement the reference counter of the given fixedpoint context.
- Z3_
fixedpoint_ ⚠from_ file - Parse an SMT-LIB2 file with fixedpoint rules. Add the rules to the current fixedpoint context. Return the set of queries in the file.
- Z3_
fixedpoint_ ⚠from_ string - Parse an SMT-LIB2 string with fixedpoint rules. Add the rules to the current fixedpoint context. Return the set of queries in the string.
- Z3_
fixedpoint_ ⚠get_ answer - Retrieve a formula that encodes satisfying answers to the query.
- Z3_
fixedpoint_ ⚠get_ assertions - Retrieve set of background assertions from fixedpoint context.
- Z3_
fixedpoint_ ⚠get_ cover_ delta - Retrieve the current cover of
predup tolevelunfoldings. Return just the delta that is known atlevel. To obtain the full set of properties ofpredone should query atlevel+1 ,level+2 etc, and includelevel=-1. - Z3_
fixedpoint_ ⚠get_ ground_ sat_ answer - Retrieve a bottom-up (from query) sequence of ground facts
- Z3_
fixedpoint_ ⚠get_ help - Return a string describing all fixedpoint available parameters.
- Z3_
fixedpoint_ ⚠get_ num_ levels - Query the PDR engine for the maximal levels properties are known about predicate.
- Z3_
fixedpoint_ ⚠get_ param_ descrs - Return the parameter description set for the given fixedpoint object.
- Z3_
fixedpoint_ ⚠get_ reachable - Retrieve reachable states of a predicate.
- Z3_
fixedpoint_ ⚠get_ reason_ unknown - Retrieve a string that describes the last status returned by
Z3_fixedpoint_query. - Z3_
fixedpoint_ ⚠get_ rule_ names_ along_ trace - Obtain the list of rules along the counterexample trace.
- Z3_
fixedpoint_ ⚠get_ rules - Retrieve set of rules from fixedpoint context.
- Z3_
fixedpoint_ ⚠get_ rules_ along_ trace - Obtain the list of rules along the counterexample trace.
- Z3_
fixedpoint_ ⚠get_ statistics - Retrieve statistics information from the last call to
Z3_fixedpoint_query. - Z3_
fixedpoint_ ⚠inc_ ref - Increment the reference counter of the given fixedpoint context
- Z3_
fixedpoint_ ⚠init - Initialize the context with a user-defined state.
- Z3_
fixedpoint_ ⚠query - Pose a query against the asserted rules.
- Z3_
fixedpoint_ ⚠query_ from_ lvl - Pose a query against the asserted rules at the given level.
- Z3_
fixedpoint_ ⚠query_ relations - Pose multiple queries against the asserted rules.
- Z3_
fixedpoint_ ⚠register_ relation - Register relation as Fixedpoint defined. Fixedpoint defined relations have least-fixedpoint semantics. For example, the relation is empty if it does not occur in a head or a fact.
- Z3_
fixedpoint_ ⚠set_ params - Set parameters on fixedpoint context.
- Z3_
fixedpoint_ ⚠set_ predicate_ representation - Configure the predicate representation.
- Z3_
fixedpoint_ ⚠set_ reduce_ app_ callback - Register a callback for building terms based on the relational operators.
- Z3_
fixedpoint_ ⚠set_ reduce_ assign_ callback - Register a callback to destructive updates.
- Z3_
fixedpoint_ ⚠to_ string - Print the current rules and background axioms as a string.
- Z3_
fixedpoint_ ⚠update_ rule - Update a named rule. A rule with the same name must have been previously created.
- Z3_
fpa_ ⚠get_ ebits - Retrieves the number of bits reserved for the exponent in a
FloatingPointsort. - Z3_
fpa_ ⚠get_ numeral_ exponent_ bv - Retrieves the exponent of a floating-point literal as a bit-vector expression.
- Z3_
fpa_ ⚠get_ numeral_ exponent_ int64 - Return the exponent value of a floating-point numeral as a signed 64-bit integer
- Z3_
fpa_ ⚠get_ numeral_ exponent_ string - Return the exponent value of a floating-point numeral as a string.
- Z3_
fpa_ ⚠get_ numeral_ sign - Retrieves the sign of a floating-point literal.
- Z3_
fpa_ ⚠get_ numeral_ sign_ bv - Retrieves the sign of a floating-point literal as a bit-vector expression.
- Z3_
fpa_ ⚠get_ numeral_ significand_ bv - Retrieves the significand of a floating-point literal as a bit-vector expression.
- Z3_
fpa_ ⚠get_ numeral_ significand_ string - Return the significand value of a floating-point numeral as a string.
- Z3_
fpa_ ⚠get_ numeral_ significand_ uint64 - Return the significand value of a floating-point numeral as a uint64.
- Z3_
fpa_ ⚠get_ sbits - Retrieves the number of bits reserved for the significand in a
FloatingPointsort. - Z3_
fpa_ ⚠is_ numeral_ inf - Checks whether a given floating-point numeral is a +oo or -oo.
- Z3_
fpa_ ⚠is_ numeral_ nan - Checks whether a given floating-point numeral is a NaN.
- Z3_
fpa_ ⚠is_ numeral_ negative - Checks whether a given floating-point numeral is negative.
- Z3_
fpa_ ⚠is_ numeral_ normal - Checks whether a given floating-point numeral is normal.
- Z3_
fpa_ ⚠is_ numeral_ positive - Checks whether a given floating-point numeral is positive.
- Z3_
fpa_ ⚠is_ numeral_ subnormal - Checks whether a given floating-point numeral is subnormal.
- Z3_
fpa_ ⚠is_ numeral_ zero - Checks whether a given floating-point numeral is +zero or -zero.
- Z3_
func_ ⚠decl_ to_ ast - Convert a
Z3_func_declintoZ3_ast. This is just type casting. - Z3_
func_ ⚠decl_ to_ string - Convert the given func decl AST node into a string.
- Z3_
func_ ⚠entry_ dec_ ref - Decrement the reference counter of the given
Z3_func_entryobject. - Z3_
func_ ⚠entry_ get_ arg - Return an argument of a
Z3_func_entryobject. - Z3_
func_ ⚠entry_ get_ num_ args - Return the number of arguments in a
Z3_func_entryobject. - Z3_
func_ ⚠entry_ get_ value - Return the value of this point.
- Z3_
func_ ⚠entry_ inc_ ref - Increment the reference counter of the given
Z3_func_entryobject. - Z3_
func_ ⚠interp_ add_ entry - add a function entry to a function interpretation.
- Z3_
func_ ⚠interp_ dec_ ref - Decrement the reference counter of the given
Z3_func_interpobject. - Z3_
func_ ⚠interp_ get_ arity - Return the arity (number of arguments) of the given function interpretation.
- Z3_
func_ ⚠interp_ get_ else - Return the ‘else’ value of the given function interpretation.
- Z3_
func_ ⚠interp_ get_ entry - Return a “point” of the given function interpretation. It represents
the value of
fin a particular point. - Z3_
func_ ⚠interp_ get_ num_ entries - Return the number of entries in the given function interpretation.
- Z3_
func_ ⚠interp_ inc_ ref - Increment the reference counter of the given
Z3_func_interpobject. - Z3_
func_ ⚠interp_ set_ else - Set the ‘else’ value of the given function interpretation.
- Z3_
get_ ⚠algebraic_ number_ lower - Return a lower bound for the given real algebraic number.
- Z3_
get_ ⚠algebraic_ number_ upper - Return an upper bound for the given real algebraic number.
- Z3_
get_ ⚠app_ arg - Return the i-th argument of the given application.
- Z3_
get_ ⚠app_ decl - Return the declaration of a constant or function application.
- Z3_
get_ ⚠app_ num_ args - Return the number of argument of an application. If
tis an constant, then the number of arguments is 0. - Z3_
get_ ⚠arity - Alias for
Z3_get_domain_size. - Z3_
get_ ⚠array_ sort_ domain - Return the domain of the given array sort.
- Z3_
get_ ⚠array_ sort_ range - Return the range of the given array sort.
- Z3_
get_ ⚠as_ array_ func_ decl - Return the function declaration
fassociated with a(_ as_array f)node. - Z3_
get_ ⚠ast_ hash - Return a hash code for the given AST.
- Z3_
get_ ⚠ast_ id - Return a unique identifier for
t. - Z3_
get_ ⚠ast_ kind - Return the kind of the given AST.
- Z3_
get_ ⚠bool_ value - Return
Z3_L_TRUEifais true,Z3_L_FALSEif it is false, andZ3_L_UNDEFotherwise. - Z3_
get_ ⚠bv_ sort_ size - Return the size of the given bit-vector sort.
- Z3_
get_ ⚠datatype_ sort_ constructor - Return idx’th constructor.
- Z3_
get_ ⚠datatype_ sort_ constructor_ accessor - Return
idx_a’th accessor for theidx_c’th constructor. - Z3_
get_ ⚠datatype_ sort_ num_ constructors - Return number of constructors for datatype.
- Z3_
get_ ⚠datatype_ sort_ recognizer - Return idx’th recognizer.
- Z3_
get_ ⚠decl_ ast_ parameter - Return the expression value associated with an expression parameter.
- Z3_
get_ ⚠decl_ double_ parameter - Return the double value associated with an double parameter.
- Z3_
get_ ⚠decl_ func_ decl_ parameter - Return the expression value associated with an expression parameter.
- Z3_
get_ ⚠decl_ int_ parameter - Return the integer value associated with an integer parameter.
- Z3_
get_ ⚠decl_ kind - Return declaration kind corresponding to declaration.
- Z3_
get_ ⚠decl_ name - Return the constant declaration name as a symbol.
- Z3_
get_ ⚠decl_ num_ parameters - Return the number of parameters associated with a declaration.
- Z3_
get_ ⚠decl_ parameter_ kind - Return the parameter type associated with a declaration.
- Z3_
get_ ⚠decl_ rational_ parameter - Return the rational value, as a string, associated with a rational parameter.
- Z3_
get_ ⚠decl_ sort_ parameter - Return the sort value associated with a sort parameter.
- Z3_
get_ ⚠decl_ symbol_ parameter - Return the double value associated with an double parameter.
- Z3_
get_ ⚠denominator - Return the denominator (as a numeral AST) of a numeral AST of sort Real.
- Z3_
get_ ⚠domain - Return the sort of the i-th parameter of the given function declaration.
- Z3_
get_ ⚠domain_ size - Return the number of parameters of the given declaration.
- Z3_
get_ ⚠error_ code - Return the error code for the last API call.
- Z3_
get_ ⚠error_ msg - Return a string describing the given error code.
- Z3_
get_ ⚠estimated_ alloc_ size - Return the estimated allocated memory in bytes.
- Z3_
get_ ⚠finite_ domain_ sort_ size - Store the size of the sort in
r. Returnfalseif the call failed. That is,Z3_get_sort_kind(s) == SortKind::FiniteDomain - Z3_
get_ ⚠full_ version - Return a string that fully describes the version of Z3 in use.
- Z3_
get_ ⚠func_ decl_ id - Return a unique identifier for
f. - Z3_
get_ ⚠implied_ equalities - Retrieve congruence class representatives for terms.
- Z3_
get_ ⚠index_ value - Return index of de-Bruijn bound variable.
- Z3_
get_ ⚠num_ probes - Return the number of builtin probes available in Z3.
- Z3_
get_ ⚠num_ tactics - Return the number of builtin tactics available in Z3.
- Z3_
get_ ⚠numeral_ decimal_ string - Return numeral as a string in decimal notation.
The result has at most
precisiondecimal places. - Z3_
get_ ⚠numeral_ double - Return numeral as a double.
- Z3_
get_ ⚠numeral_ int - Similar to
Z3_get_numeral_string, but only succeeds if the value can fit in a machine int. Returntrueif the call succeeded. - Z3_
get_ ⚠numeral_ int64 - Similar to
Z3_get_numeral_string, but only succeeds if the value can fit in a machineint64_tint. Returntrueif the call succeeded. - Z3_
get_ ⚠numeral_ rational_ int64 - Similar to
Z3_get_numeral_string, but only succeeds if the value can fit as a rational number as machineint64_tint. Returntrueif the call succeeded. - Z3_
get_ ⚠numeral_ small - Return numeral value, as a pair of 64 bit numbers if the representation fits.
- Z3_
get_ ⚠numeral_ string - Return numeral value, as a string of a numeric constant term
- Z3_
get_ ⚠numeral_ uint - Similar to
Z3_get_numeral_string, but only succeeds if the value can fit in a machine unsigned int. Returntrueif the call succeeded. - Z3_
get_ ⚠numeral_ uint64 - Similar to
Z3_get_numeral_stringbut only succeeds if the value can fit in a machineuint64_tint. Returntrueif the call succeeded. - Z3_
get_ ⚠numerator - Return the numerator (as a numeral AST) of a numeral AST of sort Real.
- Z3_
get_ ⚠pattern - Return i’th ast in pattern.
- Z3_
get_ ⚠pattern_ num_ terms - Return number of terms in pattern.
- Z3_
get_ ⚠probe_ name - Return the name of the
iprobe. - Z3_
get_ ⚠quantifier_ body - Return body of quantifier.
- Z3_
get_ ⚠quantifier_ bound_ name - Return symbol of the i’th bound variable.
- Z3_
get_ ⚠quantifier_ bound_ sort - Return sort of the i’th bound variable.
- Z3_
get_ ⚠quantifier_ no_ pattern_ ast - Return i’th
no_pattern. - Z3_
get_ ⚠quantifier_ num_ bound - Return number of bound variables of quantifier.
- Z3_
get_ ⚠quantifier_ num_ no_ patterns - Return number of
no_patternsused in quantifier. - Z3_
get_ ⚠quantifier_ num_ patterns - Return number of patterns used in quantifier.
- Z3_
get_ ⚠quantifier_ pattern_ ast - Return i’th pattern.
- Z3_
get_ ⚠quantifier_ weight - Obtain weight of quantifier.
- Z3_
get_ ⚠range - Return the range of the given declaration.
- Z3_
get_ ⚠relation_ arity - Return arity of relation.
- Z3_
get_ ⚠relation_ column - Return sort at i’th column of relation sort.
- Z3_
get_ ⚠sort - Return the sort of an AST node.
- Z3_
get_ ⚠sort_ id - Return a unique identifier for
s. - Z3_
get_ ⚠sort_ kind - Return the sort kind (e.g., array, tuple, int, bool, etc).
- Z3_
get_ ⚠sort_ name - Return the sort name as a symbol.
- Z3_
get_ ⚠string - Retrieve the string constant stored in
s. - Z3_
get_ ⚠symbol_ int - Return the symbol int value.
- Z3_
get_ ⚠symbol_ kind - Return
SymbolKind::Intif the symbol was constructed usingZ3_mk_int_symbol, andSymbolKind::Stringif the symbol was constructed usingZ3_mk_string_symbol. - Z3_
get_ ⚠symbol_ string - Return the symbol name.
- Z3_
get_ ⚠tactic_ name - Return the name of the idx tactic.
- Z3_
get_ ⚠tuple_ sort_ field_ decl - Return the i-th field declaration (i.e., projection function declaration) of the given tuple sort.
- Z3_
get_ ⚠tuple_ sort_ mk_ decl - Return the constructor declaration of the given tuple sort.
- Z3_
get_ ⚠tuple_ sort_ num_ fields - Return the number of fields of the given tuple sort.
- Z3_
get_ ⚠version - Return Z3 version number information.
- Z3_
global_ ⚠param_ get - Get a global (or module) parameter.
- Z3_
global_ ⚠param_ reset_ all - Restore the value of all global (and module) parameters. This command will not affect already created objects (such as tactics and solvers).
- Z3_
global_ ⚠param_ set - Set a global (or module) parameter. This setting is shared by all Z3 contexts.
- Z3_
goal_ ⚠assert - Add a new formula
ato the given goal. - Z3_
goal_ ⚠convert_ model - Convert a model of the formulas of a goal to a model of an original goal. The model may be null, in which case the returned model is valid if the goal was established satisfiable.
- Z3_
goal_ ⚠dec_ ref - Decrement the reference counter of the given goal.
- Z3_
goal_ ⚠depth - Return the depth of the given goal. It tracks how many transformations were applied to it.
- Z3_
goal_ ⚠formula - Return a formula from the given goal.
- Z3_
goal_ ⚠inc_ ref - Increment the reference counter of the given goal.
- Z3_
goal_ ⚠inconsistent - Return true if the given goal contains the formula
false. - Z3_
goal_ ⚠is_ decided_ sat - Return true if the goal is empty, and it is precise or the product of a under approximation.
- Z3_
goal_ ⚠is_ decided_ unsat - Return true if the goal contains false, and it is precise or the product of an over approximation.
- Z3_
goal_ ⚠num_ exprs - Return the number of formulas, subformulas and terms in the given goal.
- Z3_
goal_ ⚠precision - Return the “precision” of the given goal. Goals can be transformed using over and under approximations. A under approximation is applied when the objective is to find a model for a given goal. An over approximation is applied when the objective is to find a proof for a given goal.
- Z3_
goal_ ⚠reset - Erase all formulas from the given goal.
- Z3_
goal_ ⚠size - Return the number of formulas in the given goal.
- Z3_
goal_ ⚠to_ dimacs_ string - Convert a goal into a DIMACS formatted string. The goal must be in CNF. You can convert a goal to CNF by applying the tseitin-cnf tactic. Bit-vectors are not automatically converted to Booleans either, so the if caller intends to preserve satisfiability, it should apply bit-blasting tactics. Quantifiers and theory atoms will not be encoded.
- Z3_
goal_ ⚠to_ string - Convert a goal into a string.
- Z3_
goal_ ⚠translate - Copy a goal
gfrom the contextsourceto the contexttarget. - Z3_
inc_ ⚠ref - Increment the reference counter of the given AST.
The context
cshould have been created usingZ3_mk_context_rc. This function is a NOOP ifcwas created usingZ3_mk_context. - Z3_
interrupt ⚠ - Interrupt the execution of a Z3 procedure.
- Z3_
is_ ⚠algebraic_ number - Return true if the given AST is a real algebraic number.
- Z3_
is_ ⚠app - Z3_
is_ ⚠as_ array - The
(_ as-array f)AST node is a construct for assigning interpretations for arrays in Z3. - Z3_
is_ ⚠eq_ ast - Compare terms.
- Z3_
is_ ⚠eq_ func_ decl - Compare terms.
- Z3_
is_ ⚠eq_ sort - compare sorts.
- Z3_
is_ ⚠lambda - Determine if ast is a lambda expression.
- Z3_
is_ ⚠numeral_ ast - Z3_
is_ ⚠quantifier_ exists - Determine if ast is an existential quantifier.
- Z3_
is_ ⚠quantifier_ forall - Determine if quantifier is universal.
- Z3_
is_ ⚠re_ sort - Check if
sis a regular expression sort. - Z3_
is_ ⚠seq_ sort - Check if
sis a sequence sort. - Z3_
is_ ⚠string - Determine if
sis a string constant. - Z3_
is_ ⚠string_ sort - Check if
sis a string sort. - Z3_
is_ ⚠well_ sorted - Return true if the given expression
tis well sorted. - Z3_
mk_ ⚠add - Create an AST node representing
args[0] + ... + args[num_args-1]. - Z3_
mk_ ⚠and - Create an AST node representing
args[0] and ... and args[num_args-1]. - Z3_
mk_ ⚠app - Create a constant or function application.
- Z3_
mk_ ⚠array_ default - Access the array default value. Produces the default range value, for arrays that can be represented as finite maps with a default range value.
- Z3_
mk_ ⚠array_ ext - Create array extensionality index given two arrays with the same sort. The meaning is given by the axiom: (=> (= (select A (array-ext A B)) (select B (array-ext A B))) (= A B))
- Z3_
mk_ ⚠array_ sort - Create an array type.
- Z3_
mk_ ⚠array_ sort_ n - Create an array type with N arguments
- Z3_
mk_ ⚠as_ array - Create array with the same interpretation as a function. The array satisfies the property (f x) = (select (_ as-array f) x) for every argument x.
- Z3_
mk_ ⚠ast_ map - Return an empty mapping from AST to AST
- Z3_
mk_ ⚠ast_ vector - Return an empty AST vector.
- Z3_
mk_ ⚠atleast - Pseudo-Boolean relations.
- Z3_
mk_ ⚠atmost - Pseudo-Boolean relations.
- Z3_
mk_ ⚠bool_ sort - Create the Boolean type.
- Z3_
mk_ ⚠bound - Create a bound variable.
- Z3_
mk_ ⚠bv2int - Create an integer from the bit-vector argument
t1. Ifis_signedis false, then the bit-vectort1is treated as unsigned. So the result is non-negative and in the range[0..2^N-1], where N are the number of bits int1. Ifis_signedis true,t1is treated as a signed bit-vector. - Z3_
mk_ ⚠bv_ numeral - create a bit-vector numeral from a vector of Booleans.
- Z3_
mk_ ⚠bv_ sort - Create a bit-vector type of the given size.
- Z3_
mk_ ⚠bvadd - Standard two’s complement addition.
- Z3_
mk_ ⚠bvadd_ no_ overflow - Create a predicate that checks that the bit-wise addition
of
t1andt2does not overflow. - Z3_
mk_ ⚠bvadd_ no_ underflow - Create a predicate that checks that the bit-wise signed addition
of
t1andt2does not underflow. - Z3_
mk_ ⚠bvand - Bitwise and.
- Z3_
mk_ ⚠bvashr - Arithmetic shift right.
- Z3_
mk_ ⚠bvlshr - Logical shift right.
- Z3_
mk_ ⚠bvmul - Standard two’s complement multiplication.
- Z3_
mk_ ⚠bvmul_ no_ overflow - Create a predicate that checks that the bit-wise multiplication
of
t1andt2does not overflow. - Z3_
mk_ ⚠bvmul_ no_ underflow - Create a predicate that checks that the bit-wise signed multiplication
of
t1andt2does not underflow. - Z3_
mk_ ⚠bvnand - Bitwise nand.
- Z3_
mk_ ⚠bvneg - Standard two’s complement unary minus.
- Z3_
mk_ ⚠bvneg_ no_ overflow - Check that bit-wise negation does not overflow when
t1is interpreted as a signed bit-vector. - Z3_
mk_ ⚠bvnor - Bitwise nor.
- Z3_
mk_ ⚠bvnot - Bitwise negation.
- Z3_
mk_ ⚠bvor - Bitwise or.
- Z3_
mk_ ⚠bvredand - Take conjunction of bits in vector, return vector of length 1.
- Z3_
mk_ ⚠bvredor - Take disjunction of bits in vector, return vector of length 1.
- Z3_
mk_ ⚠bvsdiv - Two’s complement signed division.
- Z3_
mk_ ⚠bvsdiv_ no_ overflow - Create a predicate that checks that the bit-wise signed division
of
t1andt2does not overflow. - Z3_
mk_ ⚠bvsge - Two’s complement signed greater than or equal to.
- Z3_
mk_ ⚠bvsgt - Two’s complement signed greater than.
- Z3_
mk_ ⚠bvshl - Shift left.
- Z3_
mk_ ⚠bvsle - Two’s complement signed less than or equal to.
- Z3_
mk_ ⚠bvslt - Two’s complement signed less than.
- Z3_
mk_ ⚠bvsmod - Two’s complement signed remainder (sign follows divisor).
- Z3_
mk_ ⚠bvsrem - Two’s complement signed remainder (sign follows dividend).
- Z3_
mk_ ⚠bvsub - Standard two’s complement subtraction.
- Z3_
mk_ ⚠bvsub_ no_ overflow - Create a predicate that checks that the bit-wise signed subtraction
of
t1andt2does not overflow. - Z3_
mk_ ⚠bvsub_ no_ underflow - Create a predicate that checks that the bit-wise subtraction
of
t1andt2does not underflow. - Z3_
mk_ ⚠bvudiv - Unsigned division.
- Z3_
mk_ ⚠bvuge - Unsigned greater than or equal to.
- Z3_
mk_ ⚠bvugt - Unsigned greater than.
- Z3_
mk_ ⚠bvule - Unsigned less than or equal to.
- Z3_
mk_ ⚠bvult - Unsigned less than.
- Z3_
mk_ ⚠bvurem - Unsigned remainder.
- Z3_
mk_ ⚠bvxnor - Bitwise xnor.
- Z3_
mk_ ⚠bvxor - Bitwise exclusive-or.
- Z3_
mk_ ⚠concat - Concatenate the given bit-vectors.
- Z3_
mk_ ⚠config - Create a configuration object for the Z3 context object.
- Z3_
mk_ ⚠const - Declare and create a constant.
- Z3_
mk_ ⚠const_ array - Create the constant array.
- Z3_
mk_ ⚠constructor - Create a constructor.
- Z3_
mk_ ⚠constructor_ list - Create list of constructors.
- Z3_
mk_ ⚠context - Create a context using the given configuration.
- Z3_
mk_ ⚠context_ rc - Create a context using the given configuration.
This function is similar to
Z3_mk_context. However, in the context returned by this function, the user is responsible for managingZ3_astreference counters. Managing reference counters is a burden and error-prone, but allows the user to use the memory more efficiently. The user must invokeZ3_inc_reffor anyZ3_astreturned by Z3, andZ3_dec_refwhenever theZ3_astis not needed anymore. This idiom is similar to the one used in BDD (binary decision diagrams) packages such as CUDD. - Z3_
mk_ ⚠datatype - Create datatype, such as lists, trees, records, enumerations or unions of records. The datatype may be recursive. Return the datatype sort.
- Z3_
mk_ ⚠datatypes - Create mutually recursive datatypes.
- Z3_
mk_ ⚠distinct - Create an AST node representing
distinct(args[0], ..., args[num_args-1]). - Z3_
mk_ ⚠div - Create an AST node representing
arg1 div arg2. - Z3_
mk_ ⚠empty_ set - Create the empty set.
- Z3_
mk_ ⚠enumeration_ sort - Create a enumeration sort.
- Z3_
mk_ ⚠eq - Create an AST node representing
l = r. - Z3_
mk_ ⚠exists - Create an exists formula. Similar to
Z3_mk_forall. - Z3_
mk_ ⚠exists_ const - Similar to
Z3_mk_forall_const. - Z3_
mk_ ⚠ext_ rotate_ left - Rotate bits of
t1to the leftt2times. - Z3_
mk_ ⚠ext_ rotate_ right - Rotate bits of
t1to the rightt2times. - Z3_
mk_ ⚠extract - Extract the bits
highdown tolowfrom a bit-vector of sizemto yield a new bit-vector of sizen, wheren = high - low + 1. - Z3_
mk_ ⚠false - Create an AST node representing
false. - Z3_
mk_ ⚠finite_ domain_ sort - Create a named finite domain sort.
- Z3_
mk_ ⚠fixedpoint - Create a new fixedpoint context.
- Z3_
mk_ ⚠forall - Create a forall formula. It takes an expression
bodythat contains bound variables of the same sorts as the sorts listed in the arraysorts. The bound variables are de-Bruijn indices created usingZ3_mk_bound. The arraydecl_namescontains the names that the quantified formula uses for the bound variables. Z3 applies the convention that the last element in thedecl_namesandsortsarray refers to the variable with index 0, the second to last element ofdecl_namesandsortsrefers to the variable with index 1, etc. - Z3_
mk_ ⚠forall_ const - Create a universal quantifier using a list of constants that will form the set of bound variables.
- Z3_
mk_ ⚠fpa_ abs - Floating-point absolute value
- Z3_
mk_ ⚠fpa_ add - Floating-point addition
- Z3_
mk_ ⚠fpa_ div - Floating-point division
- Z3_
mk_ ⚠fpa_ eq - Floating-point equality.
- Z3_
mk_ ⚠fpa_ fma - Floating-point fused multiply-add.
- Z3_
mk_ ⚠fpa_ fp - Create an expression of
FloatingPointsort from three bit-vector expressions. - Z3_
mk_ ⚠fpa_ geq - Floating-point greater than or equal.
- Z3_
mk_ ⚠fpa_ gt - Floating-point greater than.
- Z3_
mk_ ⚠fpa_ inf - Create a floating-point infinity of sort
s. - Z3_
mk_ ⚠fpa_ is_ infinite - Predicate indicating whether
tis a floating-point number representing +oo or -oo. - Z3_
mk_ ⚠fpa_ is_ nan - Predicate indicating whether
tis a NaN. - Z3_
mk_ ⚠fpa_ is_ negative - Predicate indicating whether
tis a negative floating-point number. - Z3_
mk_ ⚠fpa_ is_ normal - Predicate indicating whether
tis a normal floating-point number. - Z3_
mk_ ⚠fpa_ is_ positive - Predicate indicating whether
tis a positive floating-point number. - Z3_
mk_ ⚠fpa_ is_ subnormal - Predicate indicating whether
tis a subnormal floating-point number. - Z3_
mk_ ⚠fpa_ is_ zero - Predicate indicating whether
tis a floating-point number with zero value, i.e., +zero or -zero. - Z3_
mk_ ⚠fpa_ leq - Floating-point less than or equal.
- Z3_
mk_ ⚠fpa_ lt - Floating-point less than.
- Z3_
mk_ ⚠fpa_ max - Maximum of floating-point numbers.
- Z3_
mk_ ⚠fpa_ min - Minimum of floating-point numbers.
- Z3_
mk_ ⚠fpa_ mul - Floating-point multiplication
- Z3_
mk_ ⚠fpa_ nan - Create a floating-point NaN of sort
s. - Z3_
mk_ ⚠fpa_ neg - Floating-point negation
- Z3_
mk_ ⚠fpa_ numeral_ double - Create a numeral of
FloatingPointsort from a double. - Z3_
mk_ ⚠fpa_ numeral_ float - Create a numeral of
FloatingPointsort from a float. - Z3_
mk_ ⚠fpa_ numeral_ int - Create a numeral of
FloatingPointsort from a signed integer. - Z3_
mk_ ⚠fpa_ numeral_ int64_ uint64 - Create a numeral of
FloatingPointsort from a sign bit and two 64-bit integers. - Z3_
mk_ ⚠fpa_ numeral_ int_ uint - Create a numeral of
FloatingPointsort from a sign bit and two integers. - Z3_
mk_ ⚠fpa_ rem - Floating-point remainder
- Z3_
mk_ ⚠fpa_ rna - Create a numeral of
RoundingModesort which represents theNearestTiesToAwayrounding mode. - Z3_
mk_ ⚠fpa_ rne - Create a numeral of
RoundingModesort which represents theNearestTiesToEvenrounding mode. - Z3_
mk_ ⚠fpa_ round_ nearest_ ties_ to_ away - Create a numeral of
RoundingModesort which represents theNearestTiesToAwayrounding mode. - Z3_
mk_ ⚠fpa_ round_ nearest_ ties_ to_ even - Create a numeral of
RoundingModesort which represents theNearestTiesToEvenrounding mode. - Z3_
mk_ ⚠fpa_ round_ to_ integral - Floating-point roundToIntegral. Rounds a floating-point number to the closest integer, again represented as a floating-point number.
- Z3_
mk_ ⚠fpa_ round_ toward_ negative - Create a numeral of
RoundingModesort which represents theTowardNegativerounding mode. - Z3_
mk_ ⚠fpa_ round_ toward_ positive - Create a numeral of
RoundingModesort which represents theTowardPositiverounding mode. - Z3_
mk_ ⚠fpa_ round_ toward_ zero - Create a numeral of
RoundingModesort which represents theTowardZerorounding mode. - Z3_
mk_ ⚠fpa_ rounding_ mode_ sort - Create the
RoundingModesort. - Z3_
mk_ ⚠fpa_ rtn - Create a numeral of
RoundingModesort which represents theTowardNegativerounding mode. - Z3_
mk_ ⚠fpa_ rtp - Create a numeral of
RoundingModesort which represents theTowardPositiverounding mode. - Z3_
mk_ ⚠fpa_ rtz - Create a numeral of
RoundingModesort which represents theTowardZerorounding mode. - Z3_
mk_ ⚠fpa_ sort - Create a
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ 16 - Create the half-precision (16-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ 32 - Create the single-precision (32-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ 64 - Create the double-precision (64-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ 128 - Create the quadruple-precision (128-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ double - Create the double-precision (64-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ half - Create the half-precision (16-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ quadruple - Create the quadruple-precision (128-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sort_ single - Create the single-precision (32-bit)
FloatingPointsort. - Z3_
mk_ ⚠fpa_ sqrt - Floating-point square root
- Z3_
mk_ ⚠fpa_ sub - Floating-point subtraction
- Z3_
mk_ ⚠fpa_ to_ fp_ bv - Conversion of a single IEEE 754-2008 bit-vector into a floating-point number.
- Z3_
mk_ ⚠fpa_ to_ fp_ float - Conversion of a
FloatingPointterm into another term of differentFloatingPointsort. - Z3_
mk_ ⚠fpa_ to_ fp_ int_ real - Conversion of a real-sorted significand and an integer-sorted exponent into a term of
FloatingPointsort. - Z3_
mk_ ⚠fpa_ to_ fp_ real - Conversion of a term of real sort into a term of
FloatingPointsort. - Z3_
mk_ ⚠fpa_ to_ fp_ signed - Conversion of a 2’s complement signed bit-vector term into a term of
FloatingPointsort. - Z3_
mk_ ⚠fpa_ to_ fp_ unsigned - Conversion of a 2’s complement unsigned bit-vector term into a term of
FloatingPointsort. - Z3_
mk_ ⚠fpa_ to_ ieee_ bv - Conversion of a floating-point term into a bit-vector term in IEEE 754-2008 format.
- Z3_
mk_ ⚠fpa_ to_ real - Conversion of a floating-point term into a real-numbered term.
- Z3_
mk_ ⚠fpa_ to_ sbv - Conversion of a floating-point term into a signed bit-vector.
- Z3_
mk_ ⚠fpa_ to_ ubv - Conversion of a floating-point term into an unsigned bit-vector.
- Z3_
mk_ ⚠fpa_ zero - Create a floating-point zero of sort
s. - Z3_
mk_ ⚠fresh_ const - Declare and create a fresh constant.
- Z3_
mk_ ⚠fresh_ func_ decl - Declare a fresh constant or function.
- Z3_
mk_ ⚠full_ set - Create the full set.
- Z3_
mk_ ⚠func_ decl - Declare a constant or function.
- Z3_
mk_ ⚠ge - Create greater than or equal to.
- Z3_
mk_ ⚠goal - Create a goal (aka problem). A goal is essentially a set of formulas, that can be solved and/or transformed using tactics and solvers.
- Z3_
mk_ ⚠gt - Create greater than.
- Z3_
mk_ ⚠iff - Create an AST node representing
t1 iff t2. - Z3_
mk_ ⚠implies - Create an AST node representing
t1 implies t2. - Z3_
mk_ ⚠int - Create a numeral of an int, bit-vector, or finite-domain sort.
- Z3_
mk_ ⚠int2bv - Create an
nbit bit-vector from the integer argumentt1. - Z3_
mk_ ⚠int2real - Coerce an integer to a real.
- Z3_
mk_ ⚠int64 - Create a numeral of a int, bit-vector, or finite-domain sort.
- Z3_
mk_ ⚠int_ sort - Create the integer type.
- Z3_
mk_ ⚠int_ symbol - Create a Z3 symbol using an integer.
- Z3_
mk_ ⚠int_ to_ str - Integer to string conversion.
- Z3_
mk_ ⚠is_ int - Check if a real number is an integer.
- Z3_
mk_ ⚠ite - Create an AST node representing an if-then-else:
ite(t1, t2, t3). - Z3_
mk_ ⚠lambda - Create a lambda expression.
- Z3_
mk_ ⚠lambda_ const - Create a lambda expression using a list of constants that form the set of bound variables
- Z3_
mk_ ⚠le - Create less than or equal to.
- Z3_
mk_ ⚠linear_ order - Create a
FuncDeclrepresenting a linear order - Z3_
mk_ ⚠list_ sort - Create a list sort
- Z3_
mk_ ⚠lt - Create less than.
- Z3_
mk_ ⚠map - Map f on the argument arrays.
- Z3_
mk_ ⚠mod - Create an AST node representing
arg1 mod arg2. - Z3_
mk_ ⚠model - Create a fresh model object. It has reference count 0.
- Z3_
mk_ ⚠mul - Create an AST node representing
args[0] * ... * args[num_args-1]. - Z3_
mk_ ⚠not - Create an AST node representing
not(a). - Z3_
mk_ ⚠numeral - Create a numeral of a given sort.
- Z3_
mk_ ⚠optimize - Create a new optimize context.
- Z3_
mk_ ⚠or - Create an AST node representing
args[0] or ... or args[num_args-1]. - Z3_
mk_ ⚠params - Create a Z3 (empty) parameter set. Starting at Z3 4.0, parameter sets are used to configure many components such as: simplifiers, tactics, solvers, etc.
- Z3_
mk_ ⚠partial_ order - Create a
FuncDeclrepresenting a partial order - Z3_
mk_ ⚠pattern - Create a pattern for quantifier instantiation.
- Z3_
mk_ ⚠pbeq - Pseudo-Boolean relations.
- Z3_
mk_ ⚠pbge - Pseudo-Boolean relations.
- Z3_
mk_ ⚠pble - Pseudo-Boolean relations.
- Z3_
mk_ ⚠piecewise_ linear_ order - Create a
FuncDeclrepresenting a piecewise linear order - Z3_
mk_ ⚠power - Create an AST node representing
arg1 ^ arg2. - Z3_
mk_ ⚠probe - Return a probe associated with the given name.
The complete list of probes may be obtained using the procedures
Z3_get_num_probesandZ3_get_probe_name. It may also be obtained using the command(help-tactic)in the SMT 2.0 front-end. - Z3_
mk_ ⚠quantifier - Create a quantifier - universal or existential, with pattern hints.
See the documentation for
Z3_mk_forallfor an explanation of the parameters. - Z3_
mk_ ⚠quantifier_ const - Create a universal or existential quantifier using a list of constants that will form the set of bound variables.
- Z3_
mk_ ⚠quantifier_ const_ ex - Create a universal or existential quantifier using a list of constants that will form the set of bound variables.
- Z3_
mk_ ⚠quantifier_ ex - Create a quantifier - universal or existential, with pattern hints, no patterns, and attributes
- Z3_
mk_ ⚠re_ allchar - Create a regular expression that accepts all singleton sequences of the regular expression sort.
- Z3_
mk_ ⚠re_ complement - Create the complement of the regular language
re. - Z3_
mk_ ⚠re_ concat - Create the concatenation of the regular languages.
- Z3_
mk_ ⚠re_ diff - Create the difference of regular expressions.
- Z3_
mk_ ⚠re_ empty - Create an empty regular expression of sort
re. - Z3_
mk_ ⚠re_ full - Create an universal regular expression of sort
re. - Z3_
mk_ ⚠re_ intersect - Create the intersection of the regular languages.
- Z3_
mk_ ⚠re_ loop - Create a regular expression loop. The supplied regular expression
ris repeated betweenloandhitimes. Theloshould be belowhiwith one execution: when supplying the valuehias 0, the meaning is to repeat the argumentrat leastlonumber of times, and with an unbounded upper bound. - Z3_
mk_ ⚠re_ option - Create the regular language
re?. - Z3_
mk_ ⚠re_ plus - Create the regular language
re+. - Z3_
mk_ ⚠re_ power - Create a power regular expression.
- Z3_
mk_ ⚠re_ range - Create the range regular expression over two sequences of length 1.
- Z3_
mk_ ⚠re_ sort - Create a regular expression sort out of a sequence sort.
- Z3_
mk_ ⚠re_ star - Create the regular language
re*. - Z3_
mk_ ⚠re_ union - Create the union of the regular languages.
- Z3_
mk_ ⚠real - Create a real from a fraction.
- Z3_
mk_ ⚠real2int - Coerce a real to an integer.
- Z3_
mk_ ⚠real_ sort - Create the real type.
- Z3_
mk_ ⚠rec_ func_ decl - Declare a recursive function
- Z3_
mk_ ⚠rem - Create an AST node representing
arg1 rem arg2. - Z3_
mk_ ⚠repeat - Repeat the given bit-vector up length
i. - Z3_
mk_ ⚠rotate_ left - Rotate bits of
t1to the leftitimes. - Z3_
mk_ ⚠rotate_ right - Rotate bits of
t1to the rightitimes. - Z3_
mk_ ⚠select - Array read.
The argument
ais the array andiis the index of the array that gets read. - Z3_
mk_ ⚠select_ n - n-ary Array read.
The argument
ais the array andidxsare the indices of the array that gets read. - Z3_
mk_ ⚠seq_ at - Retrieve from
sthe unit sequence positioned at positionindex. - Z3_
mk_ ⚠seq_ concat - Concatenate sequences.
- Z3_
mk_ ⚠seq_ contains - Check if
containercontainscontainee. - Z3_
mk_ ⚠seq_ empty - Create an empty sequence of the sequence sort
seq. - Z3_
mk_ ⚠seq_ extract - Extract subsequence starting at
offsetoflength. - Z3_
mk_ ⚠seq_ in_ re - Check if
seqis in the language generated by the regular expressionre. - Z3_
mk_ ⚠seq_ index - Return index of first occurrence of
substrinsstarting from offsetoffset. Ifsdoes not containsubstr, then the value is -1, ifoffsetis the length ofs, then the value is -1 as well. The function is under-specified ifoffsetis negative or larger than the length ofs. - Z3_
mk_ ⚠seq_ length - Return the length of the sequence
s. - Z3_
mk_ ⚠seq_ nth - Retrieve from
sthe element positioned at positionindex. The function is under-specified if the index is out of bounds. - Z3_
mk_ ⚠seq_ prefix - Check if
prefixis a prefix ofs. - Z3_
mk_ ⚠seq_ replace - Replace the first occurrence of
srcwithdstins. - Z3_
mk_ ⚠seq_ sort - Create a sequence sort out of the sort for the elements.
- Z3_
mk_ ⚠seq_ suffix - Check if
suffixis a suffix ofs. - Z3_
mk_ ⚠seq_ to_ re - Create a regular expression that accepts the sequence
seq. - Z3_
mk_ ⚠seq_ unit - Create a unit sequence of
a. - Z3_
mk_ ⚠set_ add - Add an element to a set.
- Z3_
mk_ ⚠set_ complement - Take the complement of a set.
- Z3_
mk_ ⚠set_ del - Remove an element to a set.
- Z3_
mk_ ⚠set_ difference - Take the set difference between two sets.
- Z3_
mk_ ⚠set_ intersect - Take the intersection of a list of sets.
- Z3_
mk_ ⚠set_ member - Check for set membership.
- Z3_
mk_ ⚠set_ sort - Create Set type.
- Z3_
mk_ ⚠set_ subset - Check for subsetness of sets.
- Z3_
mk_ ⚠set_ union - Take the union of a list of sets.
- Z3_
mk_ ⚠sign_ ext - Sign-extend of the given bit-vector to the (signed) equivalent bit-vector of
size
m+i, wheremis the size of the given bit-vector. - Z3_
mk_ ⚠simple_ solver - Create a new incremental solver.
- Z3_
mk_ ⚠solver - Create a new solver. This solver is a “combined solver” (see
combined_solvermodule) that internally uses a non-incremental (solver1) and an incremental solver (solver2). This combined solver changes its behaviour based on how it is used and how its parameters are set. - Z3_
mk_ ⚠solver_ for_ logic - Create a new solver customized for the given logic.
It behaves like
Z3_mk_solverif the logic is unknown or unsupported. - Z3_
mk_ ⚠solver_ from_ tactic - Create a new solver that is implemented using the given tactic.
The solver supports the commands
Z3_solver_pushandZ3_solver_pop, but it will always solve eachZ3_solver_checkfrom scratch. - Z3_
mk_ ⚠store - Array update.
- Z3_
mk_ ⚠store_ n - n-ary Array update.
- Z3_
mk_ ⚠str_ le - String less-than-or-equal lexicographic comparison operation.
Return a new AST node
Bool. - Z3_
mk_ ⚠str_ lt - String less-than lexicographic comparison operation.
Return a new AST node
Bool. - Z3_
mk_ ⚠str_ to_ int - Convert string to integer.
- Z3_
mk_ ⚠string - Create a string constant out of the string that is passed in
- Z3_
mk_ ⚠string_ sort - Create a sort for 8 bit strings.
- Z3_
mk_ ⚠string_ symbol - Create a Z3 symbol using a C string.
- Z3_
mk_ ⚠sub - Create an AST node representing
args[0] - ... - args[num_args - 1]. - Z3_
mk_ ⚠tactic - Return a tactic associated with the given name.
- Z3_
mk_ ⚠transitive_ closure - Create a
FuncDeclrepresenting a transitive closure - Z3_
mk_ ⚠tree_ order - Create a
FuncDeclrepresenting a tree order - Z3_
mk_ ⚠true - Create an AST node representing
true. - Z3_
mk_ ⚠tuple_ sort - Create a tuple type.
- Z3_
mk_ ⚠unary_ minus - Create an AST node representing
- arg. - Z3_
mk_ ⚠uninterpreted_ sort - Create a free (uninterpreted) type using the given name (symbol).
- Z3_
mk_ ⚠unsigned_ int - Create a numeral of a int, bit-vector, or finite-domain sort.
- Z3_
mk_ ⚠unsigned_ int64 - Create a numeral of a int, bit-vector, or finite-domain sort.
- Z3_
mk_ ⚠xor - Create an AST node representing
t1 xor t2. - Z3_
mk_ ⚠zero_ ext - Extend the given bit-vector with zeros to the (unsigned) equivalent
bit-vector of size
m+i, wheremis the size of the given bit-vector. - Z3_
model_ ⚠dec_ ref - Decrement the reference counter of the given model.
- Z3_
model_ ⚠eval - Evaluate the AST node
tin the given model. Returntrueif succeeded, and store the result inv. - Z3_
model_ ⚠extrapolate - Extrapolates a model of a formula
- Z3_
model_ ⚠get_ const_ decl - Return the i-th constant in the given model.
- Z3_
model_ ⚠get_ const_ interp - Return the interpretation (i.e., assignment) of constant
ain the modelm. - Z3_
model_ ⚠get_ func_ decl - Return the declaration of the i-th function in the given model.
- Z3_
model_ ⚠get_ func_ interp - Return the interpretation of the function
fin the modelm. - Z3_
model_ ⚠get_ num_ consts - Return the number of constants assigned by the given model.
- Z3_
model_ ⚠get_ num_ funcs - Return the number of function interpretations in the given model.
- Z3_
model_ ⚠get_ num_ sorts - Return the number of uninterpreted sorts that
massigns an interpretation to. - Z3_
model_ ⚠get_ sort - Return an uninterpreted sort that
massigns an interpretation. - Z3_
model_ ⚠get_ sort_ universe - Return the finite set of distinct values that represent the interpretation for sort
s. - Z3_
model_ ⚠has_ interp - Test if there exists an interpretation (i.e., assignment) for
ain the modelm. - Z3_
model_ ⚠inc_ ref - Increment the reference counter of the given model.
- Z3_
model_ ⚠to_ string - Convert the given model into a string.
- Z3_
model_ ⚠translate - Translate model from context
cto contextdst. - Z3_
open_ ⚠log - Log interaction to a file.
- Z3_
optimize_ ⚠assert - Assert hard constraint to the optimization context.
- Z3_
optimize_ ⚠assert_ and_ track - Assert tracked hard constraint to the optimization context.
- Z3_
optimize_ ⚠assert_ soft - Assert soft constraint to the optimization context.
- Z3_
optimize_ ⚠check - Check consistency and produce optimal values.
- Z3_
optimize_ ⚠dec_ ref - Decrement the reference counter of the given optimize context.
- Z3_
optimize_ ⚠from_ file - Parse an SMT-LIB2 file with assertions, soft constraints and optimization objectives. Add the parsed constraints and objectives to the optimization context.
- Z3_
optimize_ ⚠from_ string - Parse an SMT-LIB2 string with assertions, soft constraints and optimization objectives. Add the parsed constraints and objectives to the optimization context.
- Z3_
optimize_ ⚠get_ assertions - Return the set of asserted formulas on the optimization context.
- Z3_
optimize_ ⚠get_ help - Return a string containing a description of parameters accepted by optimize.
- Z3_
optimize_ ⚠get_ lower - Retrieve lower bound value or approximation for the i’th optimization objective.
- Z3_
optimize_ ⚠get_ lower_ as_ vector - Retrieve lower bound value or approximation for the i’th optimization objective.
The returned vector is of length 3. It always contains numerals.
The three numerals are coefficients a, b, c and encode the result of
Z3_optimize_get_lowera * infinity + b + c * epsilon. - Z3_
optimize_ ⚠get_ model - Retrieve the model for the last
Z3_optimize_check. - Z3_
optimize_ ⚠get_ objectives - Return objectives on the optimization context. If the objective function is a max-sat objective it is returned as a Pseudo-Boolean (minimization) sum of the form (+ (if f1 w1 0) (if f2 w2 0) …) If the objective function is entered as a maximization objective, then return the corresponding minimization objective. In this way the resulting objective function is always returned as a minimization objective.
- Z3_
optimize_ ⚠get_ param_ descrs - Return the parameter description set for the given optimize object.
- Z3_
optimize_ ⚠get_ reason_ unknown - Retrieve a string that describes the last status returned by
Z3_optimize_check. - Z3_
optimize_ ⚠get_ statistics - Retrieve statistics information from the last call to
Z3_optimize_check - Z3_
optimize_ ⚠get_ unsat_ core - Retrieve the unsat core for the last
Z3_optimize_check. - Z3_
optimize_ ⚠get_ upper - Retrieve upper bound value or approximation for the i’th optimization objective.
- Z3_
optimize_ ⚠get_ upper_ as_ vector - Retrieve upper bound value or approximation for the i’th optimization objective.
- Z3_
optimize_ ⚠inc_ ref - Increment the reference counter of the given optimize context
- Z3_
optimize_ ⚠maximize - Add a maximization constraint.
- Z3_
optimize_ ⚠minimize - Add a minimization constraint.
- Z3_
optimize_ ⚠pop - Backtrack one level.
- Z3_
optimize_ ⚠push - Create a backtracking point.
- Z3_
optimize_ ⚠set_ params - Set parameters on optimization context.
- Z3_
optimize_ ⚠to_ string - Print the current context as a string.
- Z3_
param_ ⚠descrs_ dec_ ref - Decrement the reference counter of the given parameter description set.
- Z3_
param_ ⚠descrs_ get_ documentation - Retrieve documentation string corresponding to parameter name
s. - Z3_
param_ ⚠descrs_ get_ kind - Return the kind associated with the given parameter name
n. - Z3_
param_ ⚠descrs_ get_ name - Return the number of parameters in the given parameter description set.
- Z3_
param_ ⚠descrs_ inc_ ref - Increment the reference counter of the given parameter description set.
- Z3_
param_ ⚠descrs_ size - Return the number of parameters in the given parameter description set.
- Z3_
param_ ⚠descrs_ to_ string - Convert a parameter description set into a string. This function is mainly used for printing the contents of a parameter description set.
- Z3_
params_ ⚠dec_ ref - Decrement the reference counter of the given parameter set.
- Z3_
params_ ⚠inc_ ref - Increment the reference counter of the given parameter set.
- Z3_
params_ ⚠set_ bool - Add a Boolean parameter
kwith valuevto the parameter setp. - Z3_
params_ ⚠set_ double - Add a double parameter
kwith valuevto the parameter setp. - Z3_
params_ ⚠set_ symbol - Add a symbol parameter
kwith valuevto the parameter setp. - Z3_
params_ ⚠set_ uint - Add a unsigned parameter
kwith valuevto the parameter setp. - Z3_
params_ ⚠to_ string - Convert a parameter set into a string. This function is mainly used for printing the contents of a parameter set.
- Z3_
params_ ⚠validate - Validate the parameter set
pagainst the parameter description setd. - Z3_
parse_ ⚠smtlib2_ file - Similar to
Z3_parse_smtlib2_string, but reads the benchmark from a file. - Z3_
parse_ ⚠smtlib2_ string - Parse the given string using the SMT-LIB2 parser.
- Z3_
pattern_ ⚠to_ ast - Convert a
Z3_patternintoZ3_ast. This is just type casting. - Z3_
pattern_ ⚠to_ string - Convert the given pattern AST node into a string.
- Z3_
polynomial_ ⚠subresultants - Return the nonzero subresultants of
pandqwith respect to the “variable”x. - Z3_
probe_ ⚠and - Return a probe that evaluates to “true” when
p1andp2evaluates to true. - Z3_
probe_ ⚠apply - Execute the probe over the goal. The probe always produce a double value. “Boolean” probes return 0.0 for false, and a value different from 0.0 for true.
- Z3_
probe_ ⚠const - Return a probe that always evaluates to val.
- Z3_
probe_ ⚠dec_ ref - Decrement the reference counter of the given probe.
- Z3_
probe_ ⚠eq - Return a probe that evaluates to “true” when the value returned by
p1is equal to the value returned byp2. - Z3_
probe_ ⚠ge - Return a probe that evaluates to “true” when the value returned by
p1is greater than or equal to the value returned byp2. - Z3_
probe_ ⚠get_ descr - Return a string containing a description of the probe with the given name.
- Z3_
probe_ ⚠gt - Return a probe that evaluates to “true” when the value returned by
p1is greater than the value returned byp2. - Z3_
probe_ ⚠inc_ ref - Increment the reference counter of the given probe.
- Z3_
probe_ ⚠le - Return a probe that evaluates to “true” when the value returned by
p1is less than or equal to the value returned byp2. - Z3_
probe_ ⚠lt - Return a probe that evaluates to “true” when the value returned by
p1is less than the value returned byp2. - Z3_
probe_ ⚠not - Return a probe that evaluates to “true” when
pdoes not evaluate to true. - Z3_
probe_ ⚠or - Return a probe that evaluates to “true” when
p1orp2evaluates to true. - Z3_
qe_ ⚠lite - Best-effort quantifier elimination
- Z3_
qe_ ⚠model_ project - Project variables given a model
- Z3_
qe_ ⚠model_ project_ skolem - Project variables given a model
- Z3_
query_ ⚠constructor - Query constructor for declared functions.
- Z3_
rcf_ ⚠add - Return the value
a + b. - Z3_
rcf_ ⚠del - Delete a RCF numeral created using the RCF API.
- Z3_
rcf_ ⚠div - Return the value
a / b. - Z3_
rcf_ ⚠eq - Return
trueifa == b. - Z3_
rcf_ ⚠ge - Return
trueifa >= b. - Z3_
rcf_ ⚠get_ numerator_ denominator - Extract the “numerator” and “denominator” of the given RCF numeral.
- Z3_
rcf_ ⚠gt - Return
trueifa > b. - Z3_
rcf_ ⚠inv - Return the value
1/a. - Z3_
rcf_ ⚠le - Return
trueifa <= b. - Z3_
rcf_ ⚠lt - Return
trueifa < b. - Z3_
rcf_ ⚠mk_ e - Return e (Euler’s constant)
- Z3_
rcf_ ⚠mk_ infinitesimal - Return a new infinitesimal that is smaller than all elements in the Z3 field.
- Z3_
rcf_ ⚠mk_ pi - Return Pi
- Z3_
rcf_ ⚠mk_ rational - Return a RCF rational using the given string.
- Z3_
rcf_ ⚠mk_ roots - Store in roots the roots of the polynomial
a[n-1]*x^{n-1} + ... + a[0]. The output vectorrootsmust have sizen. It returns the number of roots of the polynomial. - Z3_
rcf_ ⚠mk_ small_ int - Return a RCF small integer.
- Z3_
rcf_ ⚠mul - Return the value
a * b. - Z3_
rcf_ ⚠neg - Return the value
-a. - Z3_
rcf_ ⚠neq - Return
trueifa != b. - Z3_
rcf_ ⚠num_ to_ decimal_ string - Convert the RCF numeral into a string in decimal notation.
- Z3_
rcf_ ⚠num_ to_ string - Convert the RCF numeral into a string.
- Z3_
rcf_ ⚠power - Return the value
a^k. - Z3_
rcf_ ⚠sub - Return the value
a - b. - Z3_
reset_ ⚠memory - Reset all allocated resources.
- Z3_
set_ ⚠ast_ print_ mode - Select mode for the format used for pretty-printing AST nodes.
- Z3_
set_ ⚠error - Set an error.
- Z3_
set_ ⚠error_ handler - Register a Z3 error handler.
- Z3_
set_ ⚠param_ value - Set a configuration parameter.
- Z3_
simplify ⚠ - Interface to simplifier.
- Z3_
simplify_ ⚠ex - Interface to simplifier.
- Z3_
simplify_ ⚠get_ help - Return a string describing all available parameters.
- Z3_
simplify_ ⚠get_ param_ descrs - Return the parameter description set for the simplify procedure.
- Z3_
solver_ ⚠assert - Assert a constraint into the solver.
- Z3_
solver_ ⚠assert_ and_ track - Assert a constraint
ainto the solver, and track it (in the unsat) core using the Boolean constantp. - Z3_
solver_ ⚠check - Check whether the assertions in a given solver are consistent or not.
- Z3_
solver_ ⚠check_ assumptions - Check whether the assertions in the given solver and optional assumptions are consistent or not.
- Z3_
solver_ ⚠cube - Extract a next cube for a solver. The last cube is the constant
trueorfalse. The number of (non-constant) cubes is by default 1. For the sat solver cubing is controlled using parameters sat.lookahead.cube.cutoff and sat.lookahead.cube.fraction. - Z3_
solver_ ⚠dec_ ref - Decrement the reference counter of the given solver.
- Z3_
solver_ ⚠from_ file - load solver assertions from a file.
- Z3_
solver_ ⚠from_ string - load solver assertions from a string.
- Z3_
solver_ ⚠get_ assertions - Return the set of asserted formulas on the solver.
- Z3_
solver_ ⚠get_ consequences - retrieve consequences from solver that determine values of the supplied function symbols.
- Z3_
solver_ ⚠get_ help - Return a string describing all solver available parameters.
- Z3_
solver_ ⚠get_ model - Retrieve the model for the last
Z3_solver_check - Z3_
solver_ ⚠get_ non_ units - Return the set of non units in the solver state.
- Z3_
solver_ ⚠get_ num_ scopes - Return the number of backtracking points.
- Z3_
solver_ ⚠get_ param_ descrs - Return the parameter description set for the given solver object.
- Z3_
solver_ ⚠get_ proof - Retrieve the proof for the last
Z3_solver_check - Z3_
solver_ ⚠get_ reason_ unknown - Return a brief justification for an “unknown” result (i.e.,
Z3_L_UNDEF) for the commandsZ3_solver_check - Z3_
solver_ ⚠get_ statistics - Return statistics for the given solver.
- Z3_
solver_ ⚠get_ units - Return the set of units modulo model conversion.
- Z3_
solver_ ⚠get_ unsat_ core - Retrieve the unsat core for the last
Z3_solver_check_assumptionsThe unsat core is a subset of the assumptionsa. - Z3_
solver_ ⚠import_ model_ converter - Ad-hoc method for importing model conversion from solver.
- Z3_
solver_ ⚠inc_ ref - Increment the reference counter of the given solver.
- Z3_
solver_ ⚠pop - Backtrack
nbacktracking points. - Z3_
solver_ ⚠push - Create a backtracking point.
- Z3_
solver_ ⚠reset - Remove all assertions from the solver.
- Z3_
solver_ ⚠set_ params - Set the given solver using the given parameters.
- Z3_
solver_ ⚠to_ string - Convert a solver into a string.
- Z3_
solver_ ⚠translate - Copy a solver
sfrom the contextsourceto the contexttarget. - Z3_
sort_ ⚠to_ ast - Convert a
Z3_sortintoZ3_ast. This is just type casting. - Z3_
sort_ ⚠to_ string - Convert the given sort AST node into a string.
- Z3_
stats_ ⚠dec_ ref - Decrement the reference counter of the given statistics object.
- Z3_
stats_ ⚠get_ double_ value - Return the double value of the given statistical data.
- Z3_
stats_ ⚠get_ key - Return the key (a string) for a particular statistical data.
- Z3_
stats_ ⚠get_ uint_ value - Return the unsigned value of the given statistical data.
- Z3_
stats_ ⚠inc_ ref - Increment the reference counter of the given statistics object.
- Z3_
stats_ ⚠is_ double - Return
trueif the given statistical data is a double. - Z3_
stats_ ⚠is_ uint - Return
trueif the given statistical data is a unsigned integer. - Z3_
stats_ ⚠size - Return the number of statistical data in
s. - Z3_
stats_ ⚠to_ string - Convert a statistics into a string.
- Z3_
substitute ⚠ - Substitute every occurrence of
from[i]inawithto[i], forismaller thannum_exprs. - Z3_
substitute_ ⚠vars - Substitute the free variables in
awith the expressions into. - Z3_
tactic_ ⚠and_ then - Return a tactic that applies
t1to a given goal andt2to every subgoal produced byt1. - Z3_
tactic_ ⚠apply - Apply tactic
tto the goalg. - Z3_
tactic_ ⚠apply_ ex - Apply tactic
tto the goalgusing the parameter setp. - Z3_
tactic_ ⚠cond - Return a tactic that applies
t1to a given goal if the probepevaluates to true, andt2ifpevaluates to false. - Z3_
tactic_ ⚠dec_ ref - Decrement the reference counter of the given tactic.
- Z3_
tactic_ ⚠fail - Return a tactic that always fails.
- Z3_
tactic_ ⚠fail_ if - Return a tactic that fails if the probe
pevaluates to false. - Z3_
tactic_ ⚠fail_ if_ not_ decided - Return a tactic that fails if the goal is not trivially satisfiable (i.e., empty) or trivially unsatisfiable (i.e., contains false).
- Z3_
tactic_ ⚠get_ descr - Return a string containing a description of the tactic with the given name.
- Z3_
tactic_ ⚠get_ help - Return a string containing a description of parameters accepted by the given tactic.
- Z3_
tactic_ ⚠get_ param_ descrs - Return the parameter description set for the given tactic object.
- Z3_
tactic_ ⚠inc_ ref - Increment the reference counter of the given tactic.
- Z3_
tactic_ ⚠or_ else - Return a tactic that first applies
t1to a given goal, if it fails then returns the result oft2applied to the given goal. - Z3_
tactic_ ⚠par_ and_ then - Return a tactic that applies
t1to a given goal and thent2to every subgoal produced byt1. The subgoals are processed in parallel. - Z3_
tactic_ ⚠par_ or - Return a tactic that applies the given tactics in parallel.
- Z3_
tactic_ ⚠repeat - Return a tactic that keeps applying
tuntil the goal is not modified anymore or the maximum number of iterationsmaxis reached. - Z3_
tactic_ ⚠skip - Return a tactic that just return the given goal.
- Z3_
tactic_ ⚠try_ for - Return a tactic that applies
tto a given goal formsmilliseconds. Iftdoes not terminate inmsmilliseconds, then it fails. - Z3_
tactic_ ⚠using_ params - Return a tactic that applies
tusing the given set of parameters. - Z3_
tactic_ ⚠when - Return a tactic that applies
tto a given goal is the probepevaluates to true. Ifpevaluates to false, then the new tactic behaves like the skip tactic. - Z3_
to_ ⚠app - Convert an
astinto anZ3_app. This is just type casting. - Z3_
to_ ⚠func_ decl - Convert an AST into a
Z3_func_decl. This is just type casting. - Z3_
toggle_ ⚠warning_ messages - Enable/disable printing warning messages to the console.
- Z3_
translate ⚠ - Translate/Copy the AST
afrom contextsourceto contexttarget. - Z3_
update_ ⚠param_ value - Set a value of a context parameter.
- Z3_
update_ ⚠term - Update the arguments of term
ausing the argumentsargs.
Type Aliases§
- Z3_app
- Kind of AST used to represent function applications.
- Z3_
apply_ result - Collection of subgoals resulting from applying of a tactic to a goal.
- Z3_ast
- Abstract Syntax Tree node. That is, the data structure used in Z3 to represent terms, formulas, and types.
- Z3_
ast_ map - Mapping from
Z3_asttoZ3_astobjects. - Z3_
ast_ vector - Vector of
Z3_astobjects. - Z3_
config - Configuration object used to initialize logical contexts.
- Z3_
constructor - Type constructor for a (recursive) datatype.
- Z3_
constructor_ list - List of constructors for a (recursive) datatype.
- Z3_
context - Manager of all other Z3 objects, global configuration options, etc.
- Z3_
error_ handler - Z3 custom error handler (See
Z3_set_error_handler). - Z3_
fixedpoint - Context for the recursive predicate solver.
- Z3_
fixedpoint_ new_ lemma_ eh - Z3_
fixedpoint_ predecessor_ eh - Z3_
fixedpoint_ reduce_ app_ callback_ fptr - Z3_
fixedpoint_ reduce_ assign_ callback_ fptr - The following utilities allows adding user-defined domains.
- Z3_
fixedpoint_ unfold_ eh - Z3_
func_ decl - Kind of AST used to represent function symbols.
- Z3_
func_ entry - Representation of the value of a
Z3_func_interpat a particular point. - Z3_
func_ interp - Interpretation of a function in a model.
- Z3_goal
- Set of formulas that can be solved and/or transformed using tactics and solvers.
- Z3_
lbool - Lifted Boolean type:
false,undefined,true. - Z3_
literals - Z3_
model - Model for the constraints inserted into the logical context.
- Z3_
optimize - Context for solving optimization queries.
- Z3_
param_ descrs - Provides a collection of parameter names, their types, default values and documentation strings. Solvers, tactics, and other objects accept different collection of parameters.
- Z3_
params - Parameter set used to configure many components such as: simplifiers, tactics, solvers, etc.
- Z3_
pattern - Kind of AST used to represent pattern and multi-patterns used to guide quantifier instantiation.
- Z3_
probe - Function/predicate used to inspect a goal and collect information that may be used to decide which solver and/or preprocessing step will be used.
- Z3_
rcf_ num - Z3_
solver - (Incremental) solver, possibly specialized by a particular tactic or logic.
- Z3_sort
- Kind of AST used to represent types.
- Z3_
stats - Statistical data for a solver.
- Z3_
string - Z3 string type. It is just an alias for
const char *. - Z3_
string_ ptr - Z3_
symbol - Lisp-like symbol used to name types, constants, and functions. A symbol can be created using string or integers.
- Z3_
tactic - Basic building block for creating custom solvers for specific problem domains.