Probabilities::LogarithmicPDF Function

double LogarithmicPDF(int x, double p);

Logarithmic (log-series) probability mass function (PMF).

#NameTypeDescription
1xintFunction domain, positive integer (x>=1).
2pdoubleDistribution parameter, real value on the open interval (0,1).

Returns: the logarithmic-series probability mass function (PMF) at x using parameter p. Returns NAN when p is outside (0,1).

Remarks:

Computes the logarithmic-series PMF:

PMF(x| p)=(-1)/(ln(1-p)) p^x/x, x=1,2,3,...

Domain: x >= 1, p in (0,1). For p <= 0 or p >= 1 the result is NaN.

See Also: Probabilities::LogarithmicCDF, Probabilities::LogarithmicCDFInv
Declared in Dew::Math::Units::Probabilities · Dew.Math/Units.Probabilities.h · Cross-compiler