LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
moment_factcumulant_from_factorial.m
1function kappa = moment_factcumulant_from_factorial(f)
2% kappa = moment_factcumulant_from_factorial(f)
3%
4% Converts the factorial moments f_n = E[N(N-1)...(N-n+1)] of a discrete random
5% variable N into its factorial cumulants, the coefficients of the logarithm of
6% the probability generating function expanded about z = 1,
7%
8% log E[z^N] = sum_{n>=1} kappa_n (z-1)^n / n!
9%
10% The factorial cumulants stand to the factorial moments exactly as the
11% cumulants stand to the power moments, so the same recursion applies,
12%
13% f_n = sum_{k=1}^{n} nchoosek(n-1,k-1) * kappa_k * f_(n-k)
14%
15% For a Poisson variable of rate lambda all factorial cumulants beyond the
16% first vanish, which makes them the natural measure of departure from Poisson
17% behaviour in the counting process of a MAP.
18%
19% Input:
20% f: vector of length n+1 holding f_0,...,f_n, i.e. f(i) is the moment of
21% order i-1 and f(1) = 1
22%
23% Output:
24% kappa: vector of length n+1 holding the factorial cumulants of order
25% 0,...,n, with the same orientation as f and element 1 equal to 0
26%
27% Example:
28% kappa = moment_factcumulant_from_factorial([1, 2, 4, 8]);
29%
30% Reference:
31% V. P. Leonov and A. N. Shiryaev. On a method of calculation of
32% semi-invariants. Theory of Probability and its Applications,
33% 4(3):319-329, 1959.
34
35kappa = moment_cumulant_from_raw(f);
36end