powS {kStatistics} | R Documentation |
Power sums
Description
The function returns the value of the power sum symmetric polynomial, with fixed degrees and in one or more sets of variables, when the variables are substituted with the input lists of numerical values.
Usage
powS(vn = NULL, lvd = NULL)
Arguments
vn |
vector of integers (the powers of the indeterminates) |
lvd |
list of numerical values in place of the variables |
Details
Given the lists of numerical values (x[1],x[2],...), (y[1],y[2],...), (z[1],z[2],...), ...
in the input parameter lvd
and the integers (n,m,j,...)
in the input parameter vn
,
the powS
function returns the value of
(x[1]^n)*(y[1]^m)*(z[1]^j)*...+(x[2]^n)*(y[2]^m)*(z[2]^j)*+...
.
Value
integer |
the value of the polynomial |
Note
Called by the nKS
, nKM
, nPS
and nPM
functions
in the kStatistics
package.
Author(s)
Elvira Di Nardo elvira.dinardo@unito.it,
Giuseppe Guarino giuseppe.guarino@rete.basilicata.it
References
E. Di Nardo, G. Guarino, D. Senato (2008) Symbolic computation of moments of sampling distributions. Comp. Stat. Data Analysis. 52(11), 4909-4922. (download from https://arxiv.org/abs/0806.0129)
Examples
# Return 1^3 + 2^3 + 3^3 = 36
powS(c(3), list(c(1),c(2),c(3)))
# Return (1^3 * 4^2) + (2^3 * 5^2) + (3^3 * 6^2) = 1188
powS(c(3,2),list(c(1,4),c(2,5),c(3,6)))