FactorialMoment[data,r]
给出 data 的阶 r 阶乘矩
.
FactorialMoment[data,{r1,…,rm}]
给出 data 的阶 {r1,…,rm} 多元阶乘矩
.
FactorialMoment[dist,…]
给出了分布 dist 的阶乘矩.
代表阶 r 形式阶乘矩.
FactorialMoment
FactorialMoment[data,r]
给出 data 的阶 r 阶乘矩
.
FactorialMoment[data,{r1,…,rm}]
给出 data 的阶 {r1,…,rm} 多元阶乘矩
.
FactorialMoment[dist,…]
给出了分布 dist 的阶乘矩.
代表阶 r 形式阶乘矩.
更多信息
- 阶乘矩使用 FactorialPower[x,r] 定义,由
给出. - 对于标量阶 r 和作为数组的 data
: -
![x in TemplateBox[{Vectors, paclet:ref/Vectors}, RefLink, BaseStyle -> {3ColumnTableMod}][n] x in TemplateBox[{Vectors, paclet:ref/Vectors}, RefLink, BaseStyle -> {3ColumnTableMod}][n]](Files/FactorialMoment.zh/1.png)

r
次阶乘幂之和 »![x in TemplateBox[{Matrices, paclet:ref/Matrices}, RefLink, BaseStyle -> {3ColumnTableMod}][{n,m}] x in TemplateBox[{Matrices, paclet:ref/Matrices}, RefLink, BaseStyle -> {3ColumnTableMod}][{n,m}]](Files/FactorialMoment.zh/3.png)

r
次阶乘幂列式之和 »![x in TemplateBox[{Arrays, paclet:ref/Arrays}, RefLink, BaseStyle -> {3ColumnTableMod}][{n_(1),...,n_(k)}] x in TemplateBox[{Arrays, paclet:ref/Arrays}, RefLink, BaseStyle -> {3ColumnTableMod}][{n_(1),...,n_(k)}]](Files/FactorialMoment.zh/5.png)

r
次阶乘幂列式之和 » - FactorialMoment[x,r] 等价于 ArrayReduce[FactorialMoment[#,r]&,x,1].
- 对于向量阶 {r1,…,rm} 和作为数组的 data
: -
![x in TemplateBox[{Matrices, paclet:ref/Matrices}, RefLink, BaseStyle -> {3ColumnTableMod}][{n,m}] x in TemplateBox[{Matrices, paclet:ref/Matrices}, RefLink, BaseStyle -> {3ColumnTableMod}][{n,m}]](Files/FactorialMoment.zh/7.png)

第 j 列中的 rj 次阶乘和 ![x in TemplateBox[{Arrays, paclet:ref/Arrays}, RefLink, BaseStyle -> {3ColumnTableMod}][{n_(1),...,n_(k)}] x in TemplateBox[{Arrays, paclet:ref/Arrays}, RefLink, BaseStyle -> {3ColumnTableMod}][{n_(1),...,n_(k)}]](Files/FactorialMoment.zh/8.png)

第 j 列中求和 rj 次阶乘幂 » - FactorialMoment[x,{r1,…,rm}] 等价于 ArrayReduce[FactorialMoment[#,{r1,…,rm}]&,x,{{1},{2}}].
- FactorialMoment 既能处理数值数据,也能处理符号数据.
- data 可以有以下其他形式和解释:
-
Association 值(忽略键值) » WeightedData 加权平均值,基于底层 EmpiricalDistribution » EventData 基于底层 SurvivalDistribution » TimeSeries, TemporalData, … 值的向量或数组(忽略时间戳) » Image,Image3D RGB 通道值或灰度强度值 » Audio 所有通道的振幅值 » - 对于分布 dist,第 r 次阶乘矩由 Expectation[x(r),xdist] 给出. »
- 对于多元分布 dist,第 {r1,…,rm}
次阶乘矩由 Expectation[x1(r1)⋯ xm(rm),{x1,…,xm}dist] 给出. » - 对于随机过程 proc,可以计算出时间 t 的切片分布的阶乘矩函数 SliceDistribution[proc,t],因为
[t]=FactorialMoment[SliceDistribution[proc,t],r]. » - FactorialMoment[r] 可用于如 MomentConvert 和 MomentEvaluate 等函数. »
范例
打开所有单元 关闭所有单元基本范例 (2)
data = RandomVariate[PoissonDistribution[4], 10 ^ 4];FactorialMoment[data, 3]FactorialMoment[{Subscript[k, 1], Subscript[k, 2], Subscript[k, 3]}, 3]FactorialMoment[BinomialDistribution[n, p], 2]FactorialMoment[MultinomialDistribution[n, {Subscript[p, 1], Subscript[p, 2], Subscript[p, 3]}], {2, 2, 2}]范围 (20)
基础用法 (5)
FactorialMoment[{1, 2, 3, 4}, 1]FactorialMoment[{π, E, 2}, 2]//TogetherFactorialMoment[{1., 2., 3., 4.}, 2]FactorialMoment[N[{1, 2, 3, 4}, 30], 2]求 WeightedData 的阶乘矩:
FactorialMoment[WeightedData[{1, 2, 3}, {Subscript[w, 1], Subscript[w, 2], Subscript[w, 3]}], 1]data = {8, 3, 5, 4, 9, 0, 4, 2, 2, 3};
weights = {0.15, 0.09, 0.12, 0.10, 0.16, 0., 0.11, 0.08, 0.08, 0.09};FactorialMoment[WeightedData[data, weights], 2]求 EventData 的阶乘矩:
e = {1.0, 2.1, 3.2, 4.5, 5.7};
ci = {0, 0, 0, 1, 0};FactorialMoment[EventData[e, ci], 2]求 TimeSeries 的阶乘矩:
FactorialMoment[TemporalData[TimeSeries, {{{2.3, 1.2, 6.7, 5.8, 7.1, 4.6}}, {{0, 5, 1}}, 1, {"Discrete", 1},
{"Discrete", 1}, 1, {}}, False, 10.], 2]FactorialMoment[TemporalData[TimeSeries, {{{2.3, 1.2, 6.7, 5.8, 7.1, 4.6}}, {{0, 5, 1}}, 1, {"Discrete", 1},
{"Discrete", 1}, 1, {}}, False, 10.]["Values"], 2]数组数据 (4)
对于矩阵而言,FactorialMoment 给出列向矩:
FactorialMoment[(| | |
| ----- | ----- |
| a1, 1 | a1, 2 |
| a2, 1 | a2, 2 |), 2]对于数组而言,FactorialMoment 给出第一层的列向矩:
FactorialMoment[Array[Subscript[a, ##]&, {2, 2, 2}], 2]//Simplify//MatrixForm数组的多元 FactorialMoment:
FactorialMoment[Array[Subscript[a, ##]&, {2, 2, 2}], {2, 2}]//Simplify//TraditionalForm%//FunctionExpand//SimplifyFactorialMoment[RandomReal[1, 10 ^ 7], 2]FactorialMoment[RandomReal[1, {10 ^ 6, 5}], 1]当输入是 Association 时,FactorialMoment 会作用于其值:
mat = RandomReal[1, {2, 2}];
assoc = AssociationThread[Range[2], mat]FactorialMoment[assoc, 3]SparseArray 数据可以像稠密数组一样使用:
FactorialMoment[SparseArray[{{1} -> 1, {100} -> 1}], 1]FactorialMoment[SparseArray[{{1, 1} -> 1, {2, 2} -> 2, {3, 3} -> 3, {1, 3} -> 4}], 2]图像和音频数据 (2)
FactorialMoment[[image], 5]RGBColor[%]FactorialMoment[[image], 4]对于音频对象,FactorialMoment 按通道工作:
a = ExampleData[{"Audio", "Bee"}]AudioMeasurements[a, "Channels"]FactorialMoment[a, 3]分布与过程矩 (5)
FactorialMoment[BinomialDistribution[n, p], 1]//TogetherFactorialMoment[NormalDistribution[μ, σ], 2]FactorialMoment[BinormalDistribution[{Subscript[μ, 1], Subscript[μ, 2]}, {Subscript[σ, 1], Subscript[σ, 2]}, ρ], 2]FactorialMoment[DirichletDistribution[{a, b, c}], 2]//SimplifyFactorialMoment[MultinomialDistribution[n, {Subscript[p, 1], Subscript[p, 2], Subscript[p, 3]}], {1, 1, 1}]FactorialMoment[BinormalDistribution[{Subscript[μ, 1], Subscript[μ, 2]}, {Subscript[σ, 1], Subscript[σ, 2]}, ρ], {2, 2}]FactorialMoment[PoissonDistribution[μ], r]FactorialMoment[BorelTannerDistribution[𝒶, n], r]% /. {r -> 2}FactorialMoment[VonMisesDistribution[Pi / 2, 2], 4]N[%]FactorialMoment[TransformedDistribution[x^2, xNormalDistribution[μ, σ]], 1]FactorialMoment[ProbabilityDistribution[(Sqrt[2] / π)(1 / (1 + (x - 2)^4)), {x, -∞, ∞}], 2]data = RandomVariate[NormalDistribution[], 10 ^ 3];FactorialMoment[HistogramDistribution[data], 4]FactorialMoment[BrownianBridgeProcess[μ, σ][t], 2]Plot[Evaluate[% /. {μ -> 3, σ -> 1}], {t, 0, 1}, PlotRange -> All]求 TemporalData 在某时刻 t=0.5 的阶乘矩:
td = RandomFunction[WienerProcess[1, 1], {0, 10, 0.05}, 100]FactorialMoment[td[0.5], 1]Show[ListLinePlot[td, PlotStyle -> Directive[Opacity[0.2], Thin]], Plot[FactorialMoment[td[t], 1], {t, 0, 10}, PlotStyle -> Thick]]形式矩 (4)
形式矩的 TraditionalForm 格式:
FactorialMoment[r]//TraditionalFormFactorialMoment[{p, q, r}]//TraditionalForm将形式矩的组合转换为含 FactorialMoment 的表达式:
MomentConvert[Moment[2], FactorialMoment]//TraditionalFormMomentConvert[CentralMoment[2]Cumulant[2], FactorialMoment]//TraditionalFormMomentEvaluate[FactorialMoment[2] + FactorialMoment[3], PoissonDistribution[λ]]data = RandomVariate[PoissonDistribution[1], 10^4];MomentEvaluate[FactorialMoment[2] + FactorialMoment[3], data]求包含 FactorialMoment 的一个表达式的样本估计量:
estimator = MomentConvert[FactorialMoment[2], "UnbiasedSampleEstimator"]data = RandomVariate[PoissonDistribution[1], 10^4];MomentEvaluate[estimator, data]应用 (4)
data = RandomVariate[SkellamDistribution[2, 5], 10 ^ 4];NSolve[Table[FactorialMoment[data, k] == FactorialMoment[SkellamDistribution[m1, m2], k], {k, 1, 2}], {m1, m2}]Show[Histogram[data, Automatic, "ProbabilityDensity"], DiscretePlot[Evaluate[PDF[SkellamDistribution[m1, m2], x] /. %], {x, -10, 10}, PlotStyle -> PointSize[Medium]]]fm[r_] = (7 / 3)^-r(3 + (-1)^r) / 4;fmgf = Sum[fm[r](t - 1) ^ r / r!, {r, 0, Infinity}]dist = ProbabilityDistribution[
SeriesCoefficient[fmgf, {t, 0, k}], {k, 0, Infinity, 1}]Table[FactorialMoment[dist, r], {r, 0, 6}]Table[fm[r], {r, 0, 6}]data = TemporalData[TimeSeries, {{{0., -0.1658757846470872, -0.2728638398721067, -0.20572896599603147,
-0.10538217461042272, -0.05347321047935807, -0.09210914812542037, -0.19681903814874602,
-0.2868001703261339, -0.39654025546507443, -0.42843667 ... 4643, -0.020432977410382067, 0.061353433083862305,
-0.05763556841195196}}, {{0, 1., 0.01}}, 1, {"Continuous", 1}, {"Continuous", 1}, 1,
{ValueDimensions -> 1, ResamplingMethod -> {"Interpolation", InterpolationOrder -> 1}}}, False,
10.1];md = MovingMap[FactorialMoment[#, 2]&, data, .1];ListLinePlot[md, PlotRange -> All]data = RandomFunction[WienerProcess[], {0, 1, .01}, 10 ^ 3];times = Range[0, 1, .1];fm = Map[{#, FactorialMoment[data[#], 2]}&, times];Show[ListPlot[data], ListLinePlot[fm, PlotStyle -> Black]]属性和关系 (5)
阶乘矩
与 FactorialPower 的期望等价:
FactorialMoment[PoissonDistribution[μ], 2]Expectation[FactorialPower[x, 2], xPoissonDistribution[μ]]第一阶乘矩与 Mean 等价:
FactorialMoment[{Subscript[x, 1], Subscript[x, 2], Subscript[x, 3], Subscript[x, 4], Subscript[x, 5]}, 1]Mean[{Subscript[x, 1], Subscript[x, 2], Subscript[x, 3], Subscript[x, 4], Subscript[x, 5]}]FactorialMoment 可以由 Moment 通过
计算:
With[{r = 5, 𝒟 = BinomialDistribution[n, p]}, Subsuperscript[∑, k = 1, r]StirlingS1[r, k]Moment[𝒟, k]]With[{r = 5, 𝒟 = BinomialDistribution[n, p]}, FactorialMoment[𝒟, r]]Simplify[%% - %]MomentConvert 产生相同的结果:
MomentConvert[FactorialMoment[5], Moment]Subsuperscript[∑, k = 1, r]StirlingS1[r, k]Moment[k] /. r -> 5Moment 可由 FactorialMoment 通过
计算:
With[{r = 5, 𝒟 = ExponentialDistribution[λ]}, Underoverscript[∑, k = 0, r]StirlingS2[r, k]FactorialMoment[𝒟, k]]With[{r = 5, 𝒟 = ExponentialDistribution[λ]}, Moment[𝒟, r]]Simplify[%% - %]MomentConvert 产生相同的结果:
MomentConvert[Moment[5], FactorialMoment]Subsuperscript[∑, k = 1, r]StirlingS2[r, k]FactorialMoment[k] /. r -> 5arr = Array[Subscript[a, Row@{##}]&, {n = 4, m = 3, 2, 3}];
rs = {2, 2, 2};
Length[rs] == mFactorialMoment[arr, rs] ==
ArrayReduce[Mean,
ArrayReduce[Times@@FactorialPower[#, rs]&, arr, 2],
1]//Simplify巧妙范例 (1)
估计 30、100 和 300 个样本的 FactorialMoment 的分布:
FactorialMoment[ExponentialDistribution[0.9], 2]SmoothHistogram[Table[FactorialMoment[RandomVariate[ExponentialDistribution[0.9], {s, 1000}], 2], {s, {30, 100, 300}}], Filling -> Axis, PlotLegends -> {30, 100, 300}, PlotRange -> {{0, 4}, Automatic}]相关指南
-
▪
- 统计矩与母函数 ▪
- 描述性统计分析 ▪
- 符号向量、矩阵和数组
文本
Wolfram Research (2010),FactorialMoment,Wolfram 语言函数,https://reference.wolfram.com/language/ref/FactorialMoment.html (更新于 2024 年).
CMS
Wolfram 语言. 2010. "FactorialMoment." Wolfram 语言与系统参考资料中心. Wolfram Research. 最新版本 2024. https://reference.wolfram.com/language/ref/FactorialMoment.html.
APA
Wolfram 语言. (2010). FactorialMoment. Wolfram 语言与系统参考资料中心. 追溯自 https://reference.wolfram.com/language/ref/FactorialMoment.html 年
BibTeX
@misc{reference.wolfram_2026_factorialmoment, author="Wolfram Research", title="{FactorialMoment}", year="2024", howpublished="\url{https://reference.wolfram.com/language/ref/FactorialMoment.html}", note=[Accessed: 14-October-2026]}
BibLaTeX
@online{reference.wolfram_2026_factorialmoment, organization={Wolfram Research}, title={FactorialMoment}, year={2024}, url={https://reference.wolfram.com/language/ref/FactorialMoment.html}, note=[Accessed: 14-October-2026]}