FindEquationalProof[thm,axms]
尝试使用公理 axms 找到符号定理 thm 的等式证明.
FindEquationalProof[thm,"theory"]
尝试使用指定的命名的公理理论找到 thm 的证明.
FindEquationalProof
FindEquationalProof[thm,axms]
尝试使用公理 axms 找到符号定理 thm 的等式证明.
FindEquationalProof[thm,"theory"]
尝试使用指定的命名的公理理论找到 thm 的证明.
更多信息和选项
- 如果 FindEquationalProof[thm,axms] 成功地从公理 axms 推导出定理 thm,则返回 ProofObject 表达式. 如果成功地证明了该定理不能从公理中得出,它将返回一个 Failure 对象. 否则,除非时间限制,它可能不会终止.
- 公理和定理可以以等式形式或一阶逻辑中的公式形式给出. 将一阶逻辑中的公式转换为等式.
- 陈述 thm 和 axms 可以是以下形式的项的逻辑组合:
-
expr1expr2 相等性断言 p[expr1,…] 任意符号谓词 ForAll[vars,stmt] 认定对于 vars 的所有值 stmt 为真的断言 Exists[vars,stmt] 认定 stmt 为真时 vars 的值存在的断言 - expri 可以是任意符号表达式,具有表示正式运算符、函数等的标头.
- 陈述 stmt 可以包含谓词的任意逻辑组合.
- FindEquationalProof[expr1&&expr2&&…,axm1&&axm2&&…] 将会把每个 expr1,expr2,… 看作独立的假设,把每个 axm1,axm2,… 看作独立的公理.
- FindEquationalProof[{expr1,expr2,…},{axm1,axm2,…}] 等价于 FindEquationalProof[expr1&&expr2&&…,axm1&&axm2&&…].
- FindEquationalProof[thm,"theory"] 等价于 FindEquationalProof[thm,AxiomaticTheory["theory"]].
- FindEquationalProof["name","theory"] 试图从 AxiomaticTheory["theory","NotableTheorems"] 中求出已命名定理的证明.
- FindEquationalProof 有下列选项:
-
TimeConstraint Infinity 允许使用多长时间 - 如果 FindEquationalProof 超过了指定的时间限制,将会返回 Failure 对象.
- FindEquationalProof[thm,axms] 用 Knuth–Bendix 补全算法来证明定理 thm 遵循公理 axms.
范例
打开所有单元 关闭所有单元基本范例 (3)
proof = FindEquationalProof[a == c, {a == b, b == c}]proof["ProofGraph"]用 Dataset 对象显示完整的证明步骤:
proof["ProofDataset"]用一阶逻辑证明涉及通用附量 (universal quantification) 的定理:
proof = FindEquationalProof[ForAll[x, f[g[x]] == g[f[x]]], ForAll[x, f[x] == g[x]]]proof["ProofNotebook"]FindEquationalProof[mortal[socrates], {ForAll[x, Implies[man[x], mortal[x]]], man[socrates]}]范围 (3)
FindEquationalProof[a == d, {a == b, b == c, c == d}]FindEquationalProof[a == d, a == b && b == c && c == d]FindEquationalProof[a == c, a == b]FindEquationalProof[Exists[x, Mortal[x]], {ForAll[x, Implies[Man[x], Mortal[x]]], Exists[x, Man[x]]}]选项 (1)
TimeConstraint (1)
用 TimeConstraintt 将计算时间限制在 t 秒内:
theorem = ForAll[{a, b, c}, f[a, f[a, f[b, c]]] == f[b, f[b, f[a, c]]]]axiom = ForAll[{a, b, c}, f[f[a, a], f[a, a]] == a && f[a, f[b, f[b, b]]] == f[a, a] && f[f[a, f[b, c]], f[a, f[b, c]]] == f[f[f[b, b], a], f[f[c, c], a]]]FindEquationalProof[theorem, axiom, TimeConstraint -> 1]默认情况下,FindEquationalProof 会无限期地寻找证明:
FindEquationalProof[theorem, axiom]//AbsoluteTiming应用 (19)
基本逻辑 (6)
booleanLogic = {ForAll[{a, b}, and[a, b] == and[b, a]], ForAll[{a, b}, or[a, b] == or[b, a]], ForAll[{a, b}, and[a, or[b, not[b]]] == a], ForAll[{a, b}, or[a, and[b, not[b]]] == a], ForAll[{a, b, c}, and[a, or[b, c]] == or[and[a, b], and[a, c]]], ForAll[{a, b, c}, or[a, and[b, c]] == and[or[a, b], or[a, c]]]}proof = FindEquationalProof[ForAll[{a, b}, or[not[or[not[a], b]], not[or[not[a], not[b]]]] == a], booleanLogic]proof["ProofGraph"]proof2 = FindEquationalProof[ForAll[{a, b}, not[or[not[or[a, b]], not[or[a, not[b]]]]] == a], booleanLogic]proof2["ProofFunction"][]shefferLogic = {ForAll[a, nand[nand[a, a], nand[a, a]] == a], ForAll[{a, b}, nand[a, nand[b, nand[b, b]]] == nand[a, a]], ForAll[{a, b, c}, nand[nand[a, nand[b, c]], nand[a, nand[b, c]]] == nand[nand[nand[b, b], a], nand[nand[c, c], a]]]}proof = FindEquationalProof[ForAll[{a, b}, nand[a, nand[a, b]] == nand[a, nand[b, b]]], shefferLogic]proof["ProofDataset"]proof2 = FindEquationalProof[ForAll[{a, b}, nand[nand[a, a], nand[a, b]] == a], shefferLogic]proof2["ProofFunction"][]proof3 = FindEquationalProof[ForAll[{a, b, c}, nand[nand[nand[a, b], c], nand[a, nand[nand[a, c], a]]] == c], shefferLogic]proof3["ProofGraph"]proof4 = FindEquationalProof[ForAll[{a, b, c}, nand[a, nand[a, nand[b, c]]] == nand[b, nand[b, nand[a, c]]]], shefferLogic]proof4["ProofGraph"]定义布尔逻辑、Huntington 逻辑和 Robbins 逻辑的公理:
booleanLogic = {ForAll[{a, b}, and[a, b] == and[b, a]], ForAll[{a, b}, or[a, b] == or[b, a]], ForAll[{a, b}, and[a, or[b, not[b]]] == a], ForAll[{a, b}, or[a, and[b, not[b]]] == a], ForAll[{a, b, c}, and[a, or[b, c]] == or[and[a, b], and[a, c]]], ForAll[{a, b, c}, or[a, and[b, c]] == and[or[a, b], or[a, c]]]}huntingtonLogic = {ForAll[{a, b}, or[a, b] == or[b, a]], ForAll[{a, b, c}, or[a, or[b, c]] == or[or[a, b], c]], ForAll[{a, b}, or[not[or[not[a], b]], not[or[not[a], not[b]]]] == a]}robbinsLogic = {ForAll[{a, b}, or[a, b] == or[b, a]], ForAll[{a, b, c}, or[a, or[b, c]] == or[or[a, b], c]], ForAll[{a, b}, not[or[not[or[a, b]], not[or[a, not[b]]]]] == a]}FindEquationalProof[huntingtonLogic, booleanLogic]FindEquationalProof[robbinsLogic, booleanLogic]FindEquationalProof[robbinsLogic, huntingtonLogic]wolframLogic = ForAll[{a, b, c}, ((a·b)·c)·(a·((a·c)·a)) == c]FindEquationalProof[a·b == b·a, wolframLogic]%["ProofGraph"]通过辅助定义引入 And、Or、Not 运算符,用 Wolfram 公理来证明布尔公理:
ancillary = AxiomaticTheory["WolframAxioms", "AncillaryDefinitions"]FindEquationalProof[AxiomaticTheory["BooleanAxioms"], Join[AxiomaticTheory["WolframAxioms"], Values[ancillary]]]通过辅助定义引入 Or、Not 运算符,用 Wolfram 公理证明 Or-Not 布尔公理:
theorem = AxiomaticTheory["OrNotBooleanAxioms"]ancillary = AxiomaticTheory["WolframAxioms", "AncillaryDefinitions"]FindEquationalProof[theorem, Join[AxiomaticTheory["WolframAxioms"], Values[ancillary]]]抽象代数 (8)
groupTheory = {ForAll[{a, b, c}, g[a, g[b, c]] == g[g[a, b], c]], ForAll[a, g[a, e] == a], ForAll[a, g[a, inv[a]] == e]}proof = FindEquationalProof[ForAll[x, g[e, x] == x], groupTheory]proof["ProofNotebook"]proof2 = FindEquationalProof[ForAll[{a, b, c, d}, g[a, inv[g[b, g[g[g[c, inv[c]], inv[g[d, b]]], a]]]] == d], groupTheory]proof2["ProofGraph"]abelianGroupTheory = {ForAll[{a, b, c}, g[a, g[b, c]] == g[g[a, b], c]], ForAll[a, g[a, e] == a], ForAll[a, g[a, inv[a]] == e], ForAll[{a, b}, g[a, b] == g[b, a]]}proof = FindEquationalProof[ForAll[{a, b, c}, g[g[g[a, b], c], inv[g[a, c]]] == b], abelianGroupTheory]proof["ProofDataset"]proof2 = FindEquationalProof[ForAll[{a, b, c, d}, g[a, inv[g[b, g[g[g[c, inv[c]], inv[g[d, b]]], a]]]] == d], abelianGroupTheory]proof2["ProofGraph"]semigroupTheory = ForAll[{a, b, c}, g[a, g[b, c]] == g[g[a, b], c]]monoidTheory = {ForAll[{a, b, c}, g[a, g[b, c]] == g[g[a, b], c]], ForAll[a, g[a, e] == a], ForAll[a, g[e, a] == a]}groupTheory = {ForAll[{a, b, c}, g[a, g[b, c]] == g[g[a, b], c]], ForAll[a, g[a, e] == a], ForAll[a, g[a, inv[a]] == e]}FindEquationalProof[semigroupTheory, groupTheory]FindEquationalProof[monoidTheory, groupTheory]abelianGroupTheory = {ForAll[{a, b, c}, g[a, g[b, c]] == g[g[a, b], c]], ForAll[a, g[a, e] == a], ForAll[a, g[a, inv[a]] == e], ForAll[{a, b}, g[a, b] == g[b, a]]}ringTheory = {ForAll[{a, b, c}, g[a, g[b, c]] == g[g[a, b], c]], ForAll[a, g[a, e] == a], ForAll[a, g[a, inv[a]] == e], ForAll[{a, b}, g[a, b] == g[b, a]], ForAll[{a, b, c}, f[a, f[b, c]] == f[f[a, b], c]], ForAll[{a, b, c}, f[a, g[b, c]] == g[f[a, b], f[a, c]]], ForAll[{a, b}, f[a, b] == f[b, a]]}FindEquationalProof[abelianGroupTheory, ringTheory]["ProofGraph"]groups = AxiomaticTheory[{"GroupAxioms", "Multiplication" -> p, "Identity" -> e}]quaternionGroup = {groups, p[p[a, b], a] == b, p[p[b, a], b] == a};FindEquationalProof[p[a, a] == p[b, b], quaternionGroup]FindEquationalProof[p[p[p[a, a], a], a] == e, quaternionGroup]FindEquationalProof[p[p[p[b, b], b], b] == e, quaternionGroup]AxiomaticTheory["FieldAxioms", "AxiomsAssociation"]["MultiplicationInverse"]FindEquationalProof[ForAll[, Implies[Not[Tilde[, OverTilde[0]]], Tilde[CircleTimes[SuperMinus[], ], OverTilde[1]]]], "FieldAxioms"]FindEquationalProof[AxiomaticTheory["RightNearRingAxioms"], Join[AxiomaticTheory["LeftNearRingAxioms"], {ForAll[{, }, CircleTimes[, ] == CircleTimes[, ]]}]]构建幂等半环公理,其中用 LeftTriangle 表示自然定义的偏序:
axioms = Join[AxiomaticTheory["SemiringAxioms"] /. Equal -> Tilde, {Subscript[∀, ]∼, Subscript[∀, {, }](∼∼), Subscript[∀, {, , }](∼ && ∼∼), ForAll[, Tilde[CirclePlus[, ], ]], ForAll[{, }, Implies[LeftTriangle[, ], Tilde[CirclePlus[, ], ]]], ForAll[{, }, Implies[Tilde[CirclePlus[, ], ], LeftTriangle[, ]]]}]theorem = ForAll[{, }, Implies[And[LeftTriangle[, ], LeftTriangle[, ]], Tilde[, ]]]FindEquationalProof[theorem, axioms]算术 (1)
为 Presburger 算术的修改(等式)版本指定一些公理:
presburgerArithmetic = {ForAll[x, plus[x, 0] == x], ForAll[x, plus[x, neg[x]] == 0], ForAll[{x, y, z}, plus[plus[x, y], z] == plus[x, plus[y, z]]]}proof = FindEquationalProof[ForAll[x, neg[neg[x]] == x], presburgerArithmetic]proof["ProofGraph"]proof2 = FindEquationalProof[ForAll[{x, y}, plus[x, plus[y, 0]] == plus[x, plus[0, y]]], presburgerArithmetic]proof2["ProofDataset"]实分析 (1)
calculus = {ForAll[f, integral[derivative[f]] == f], ForAll[f, derivative[integral[f]] == f], ForAll[{f, g}, derivative[product[f, g]] == sum[product[f, derivative[g]], product[g, derivative[f]]]], ForAll[{f, g}, derivative[sum[f, g]] == sum[derivative[f], derivative[g]]]}proof = FindEquationalProof[ForAll[{f, g}, sum[integral[product[f, derivative[g]]], integral[product[g, derivative[f]]]] == product[f, g]], calculus]proof["ProofNotebook"]循环理论与通用代数 (1)
loopTheory = {ForAll[x, mult[x, 1] == x], ForAll[x, mult[1, x] == x], ForAll[{x, y}, mult[x, conj[x, y]] == y], ForAll[{x, y, z}, R[x, y, z] == z], ForAll[{x, y, z, u}, T[x, R[y, z, u]] == R[y, z, T[x, y]]], ForAll[{x, y}, T[x, y] == conj[x, mult[y, x]]]}proof = FindEquationalProof[ForAll[{x, y, z, u, v}, mult[comm[x, assc[y, z, u]], v] == mult[v, comm[x, assc[y, z, u]]]], loopTheory]proof["ProofDataset"]逻辑难题 (2)
跟随刘易斯·卡洛尔 (Lewis Carroll),推断婴儿无法管理鳄鱼:
FindEquationalProof[Not[Exists[x, And[baby[x], manageCrocodile[x]]]], {ForAll[x, Implies[baby[x], Not[logical[x]]]], ForAll[x, Implies[manageCrocodile[x], Not[despised[x]]]], ForAll[x, Implies[Not[logical[x]], despised[x]]]}]查看 knight(总是说真话)和 knave(总是说谎)难题的解:
FindEquationalProof[And[knight[zoey], knave[mel]], {ForAll[p, ForAll[s, Implies[And[knight[p], says[p, s]], s]]], ForAll[p, ForAll[s, Implies[And[knave[p], says[p, s]], Not[s]]]], ForAll[p, Or[knight[p], knave[p]]], says[zoey, knave[mel]], says[mel, And[Not[knave[zoey]], Not[knave[mel]]]]}]属性和关系 (2)
如果 FindEquationalProof 返回一个特定定理的证明对象 (proof object),针对该定理,FullSimplify 将会返回 True:
FindEquationalProof[f[f[u, f[v, w]], u] == f[u, f[f[v, w], u]], ForAll[{a, b, c}, f[a, f[b, c]] == f[f[a, b], c]]]FullSimplify[f[f[u, f[v, w]], u] == f[u, f[f[v, w], u]], ForAll[{a, b, c}, f[a, f[b, c]] == f[f[a, b], c]]]FindEquationalProof 把公理列表和公理的组合看作是等价的:
FindEquationalProof[a == c, {a == b, b == c}]FindEquationalProof[a == c, a == b && b == c]FindEquationalProof[{a == c, a == d}, {a == b, b == c, c == d}]FindEquationalProof[a == c && a == d, a == b && b == c && c == d]可能存在的问题 (1)
默认情况下,FindEquationalProof 不能证明涉及算术运算符的定理:
FindEquationalProof[ForAll[x, f[4 * x] == 4 * f[x]], {ForAll[x, f[2 * x] == 2 * f[x]]}]FindEquationalProof[ForAll[a, f[mult[4, x]] == mult[4, f[x]]], {ForAll[x, f[mult[2, x]] == mult[2, f[x]]], ForAll[{x, y, z}, mult[x, mult[y, z]] == mult[mult[x, y], z]], mult[2, 2] == 4}]文本
Wolfram Research (2018),FindEquationalProof,Wolfram 语言函数,https://reference.wolfram.com/language/ref/FindEquationalProof.html (更新于 2020 年).
CMS
Wolfram 语言. 2018. "FindEquationalProof." Wolfram 语言与系统参考资料中心. Wolfram Research. 最新版本 2020. https://reference.wolfram.com/language/ref/FindEquationalProof.html.
APA
Wolfram 语言. (2018). FindEquationalProof. Wolfram 语言与系统参考资料中心. 追溯自 https://reference.wolfram.com/language/ref/FindEquationalProof.html 年
BibTeX
@misc{reference.wolfram_2026_findequationalproof, author="Wolfram Research", title="{FindEquationalProof}", year="2020", howpublished="\url{https://reference.wolfram.com/language/ref/FindEquationalProof.html}", note=[Accessed: 25-November-2026]}
BibLaTeX
@online{reference.wolfram_2026_findequationalproof, organization={Wolfram Research}, title={FindEquationalProof}, year={2020}, url={https://reference.wolfram.com/language/ref/FindEquationalProof.html}, note=[Accessed: 25-November-2026]}