Distribute[f[x1,x2,…]]
将 f 分配到 xi 的和式 Plus.
Distribute[expr,g]
分配到 g 中.
Distribute[expr,g,f]
当 expr 的头部是 f 时执行分配.
Distribute
Distribute[f[x1,x2,…]]
将 f 分配到 xi 的和式 Plus.
Distribute[expr,g]
分配到 g 中.
Distribute[expr,g,f]
当 expr 的头部是 f 时执行分配.
更多信息
- Distribute 有效地实现了 f 和 g 的分配律.
- Distribute 建立一个分布的完整结果;相反地,Expand 只简单在每一阶段重复建立结果.
- Distribute[expr,g,f,gp,fp] 在分配的结果中分别使用 gp 和 fp 来代替 g 和 f. »
范例
打开所有单元 关闭所有单元基本范例 (3)
Distribute[(a + b).(x + y + z)]f 分配到 Plus 中:
Distribute[f[a + b, c + d + e]]Distribute[f[g[a, b], g[c, d, e]], g]范围 (4)
在缺省情况下,对 Plus 分配:
Distribute[(a + b + c)(u + v), Plus]Distribute[(a + b + c)(u + v)]Distribute[(a + b + c)(u + v), Plus, Times]Distribute[(a + b + c) ^ (u + v), Plus, Times]Distribute[And[Or[a, b, c], Or[u, v]], Or, And]Distribute[Or[And[a, b, c], And[u, v]], And, Or]Distribute[And[Xor[a, b, c], Xor[u, v]], Xor, And]Distribute[(a⊕b⊕c)⊗(u⊕v), CirclePlus, CircleTimes]推广和延伸 (1)
应用 (5)
Distribute[(m1 + m2).(m3 + m4)]Distribute[(v1 + v2)⨯(v3 + v4)]Distribute[(a + b)⊕(x + y + z)⊕(s + t)]Distribute[{{a, b}, {x, y, z}, {s, t}}, List]Distribute[{{}, {#}}& /@ {a, b, c}, List, List, List, Join]Distribute[Factor[x ^ 6 - 1], Plus, Times, List, Times]Plus@@%属性和关系 (3)
对于纯积,Distribute 给出 Expand 相同的结果:
Factor[x ^ 10 - 1]Distribute[%]对应分布的 PowerExpand 分配到 Times:
PowerExpand[(x y z) ^ n]Distribute[(x y z) ^ n, Times]Outer 形成所有元素的相同组合,但以嵌套结构:
Outer[List, {a, b, c}, {x, y}]Distribute[{{a, b, c}, {x, y}}, List]可能存在的问题 (2)
使用 Distribute 没有给出预期结果:
Distribute[(a + b) * (a + b)](a + b) * (a + b)Distribute[%]避免在 Distribute 使用它之前计算参数:
Distribute[Unevaluated[(a + b) * (a + b)]]Distribute 并不一定能得到数学意义上正确的结果:
Distribute[u ^ (a + b)]将应用限制在 Times 的出现上可避免转换:
Distribute[u ^ (a + b), Plus, Times]技术笔记
-
▪
- 结构的操作
历史
1988年引入 (1.0)
文本
Wolfram Research (1988),Distribute,Wolfram 语言函数,https://reference.wolfram.com/language/ref/Distribute.html.
CMS
Wolfram 语言. 1988. "Distribute." Wolfram 语言与系统参考资料中心. Wolfram Research. https://reference.wolfram.com/language/ref/Distribute.html.
APA
Wolfram 语言. (1988). Distribute. Wolfram 语言与系统参考资料中心. 追溯自 https://reference.wolfram.com/language/ref/Distribute.html 年
BibTeX
@misc{reference.wolfram_2026_distribute, author="Wolfram Research", title="{Distribute}", year="1988", howpublished="\url{https://reference.wolfram.com/language/ref/Distribute.html}", note=[Accessed: 04-September-2026]}
BibLaTeX
@online{reference.wolfram_2026_distribute, organization={Wolfram Research}, title={Distribute}, year={1988}, url={https://reference.wolfram.com/language/ref/Distribute.html}, note=[Accessed: 04-September-2026]}