find a valuation satisfying an expression - Maple Help

Home : Support : Online Help : Programming : Logic : Boolean : Logic Package : Logic/Satisfy

Logic[Satisfy] - find a valuation satisfying an expression

 Calling Sequence Satisfy(expr, alpha)

Parameters

 expr - Boolean expression alpha - (optional) list or set of names

Description

 • The Satisfy command returns a set of equations representing an assignment to the variables of the given Boolean expression expr that satisfy  the expression expr. If expr is not satisfiable , then NULL is returned.
 • If the optional second parameter is present, the valuation includes all variable names in alpha.

Examples

 > $\mathrm{with}\left(\mathrm{Logic}\right):$
 > $\mathrm{Satisfy}\left(a&orb\right)$
 $\left\{{a}{=}{\mathrm{true}}{,}{b}{=}{\mathrm{false}}\right\}$ (1)
 > $\mathrm{Satisfy}\left(a&orb,\left\{a,b,c\right\}\right)$
 $\left\{{a}{=}{\mathrm{true}}{,}{b}{=}{\mathrm{false}}{,}{c}{=}{\mathrm{false}}\right\}$ (2)
 > $\mathrm{Satisfy}\left(a&and\mathrm{¬}\left(a\right)\right)$
 > $\mathrm{Satisfy}\left(a&impliesb&xor\mathrm{¬}\left(c\right)\right)$
 $\left\{{a}{=}{\mathrm{false}}{,}{b}{=}{\mathrm{false}}{,}{c}{=}{\mathrm{false}}\right\}$ (3)