1function b = moment_joint_binomial_from_tail(t)
2% b = moment_joint_binomial_from_tail(t)
4% Converts the joint survival probabilities t_(m_1,...,m_d) =
P(N_1 >= m_1,
5% ..., N_d >= m_d) of a nonnegative integer random vector into its joint
8% b_(k) = E[prod_j nchoosek(N_j,k_j)]
9% =
sum_(m>=k) prod_j nchoosek(m_j-1,k_j-1) * t_(m)
11% The transform
is the tensor product of the univariate one, which
is what
12% makes the mode-by-mode evaluation legitimate: an entry with k_j = 0 selects
13% m_j = 0, and t_(0,m_2,...)
is by construction the marginal survival array of
14% the remaining coordinates. As in the univariate case it
is upper triangular,
15% so the array must cover the joint support to be exact; truncating gives lower
19% t: array of size (n_1+1)x...x(n_d+1) holding the joint survival
20% probabilities, element 1 being 1
23% b: array of the same size holding the joint binomial moments
26% b = moment_joint_binomial_from_tail(t);
29% A. Heindl and A. van de Liefvoort. Moment conversions for discrete
30% distributions. PMCCS, 2003.
32b = moment_jointtrans(t, 'binomial_from_tail');