Learn R Programming

lmomco (version 1.7.3)

pdfkmu: Probability Density Function of the Kappa-Mu Distribution

Description

This function computes the probability density of the Kappa-Mu ($\kappa:\mu$) distribution given parameters ($\kappa$ and $\mu$) of the distribution computed by parkmu. The probability density function of the distribution is $$f(x) = \frac{2\mu(1+\kappa)^{(\mu + 1)/2}}{\kappa^{(\mu-1)/2}\mathrm{exp}(\mu\kappa)}x^\mu\mathrm{exp}(-\mu(1+\kappa)x^2)\mathrm{I}_{\mu - 1}(2\mu\sqrt{\kappa(1+\kappa)}x)$$ where $f(x)$ is the nonexceedance probability for quantile $x$ and the modified Bessel function of the first kind is $I_k(x)$.

Define $m$ as $$m = \frac{\mu(1+\kappa)^2}{1+2\kappa}$$ and for a given $m$, the parameter $\mu$ must lie in the range $$0 \le \mu \le m$$

Usage

pdfkmu(x, para, paracheck=TRUE)

Arguments

x
A real value.
para
The parameters from parkmu or similar.
paracheck
A logical controlling whether the parameters and checked for validity.

Value

  • Probability density ($f$) for $x$.

References

Yacoub, M.D., 2007, The kappa-mu distribution and the eta-mu distribution: IEEE Antennas and Propagation Magazine, v. 49, no. 1, pp. 68--81

See Also

cdfkmu, quakmu, parkmu

Examples

Run this code
x <- seq(0,4, by=.1)
para <- vec2par(c(.5, 1.4), type="kmu")
F <- cdfkmu(x, para)
X <- quakmu(F, para)
plot(F, X, type="l", lwd=8)
lines(F, x, col=2)

# Note that in this example very delicate steps are taken to show
# how one interacts with the Dirac Delta function (x=0) when the m
# is known but mu == 0. For x=0, the fraction of total probability
# is recorded, but when one is doing numerical summation to evaluate
# whether the total probability under the PDF is unity some algebraic
# manipulations are needed as shown for the conditional when kappa
# is infinity.

delx <- 0.001
x <- seq(0,3, by=delx)

plot(c(0,3), c(0,1), xlab="RHO", ylab="pdfkmu(RHO)", type="n")
m <- 1.25
mus <- c(0.25, 0.50, 0.75, 1, 1.25, 0)
for(mu in mus) {
   kappa <- m/mu - 1 + sqrt((m/mu)*((m/mu)-1))
   para <- vec2par(c(kappa, mu), type="kmu")
   if(! is.finite(kappa)) {
      para <- vec2par(c(Inf,m), type="kmu")
      density <- pdfkmu(x, para)
      lines(x, density, col=2, lwd=3)
      dirac <- 1/delx - sum(density[x != 0])
      cumulant <- (sum(density) + density[1]*(1/delx - 1))*delx
      density[x == 0] <- rep(dirac, length(density[x == 0]))
      message("total probability is ", cumulant, "\n")
   }
   lines(x, pdfkmu(x, para))
}
mtext("Yacoub (2007, figure 3)")

Run the code above in your browser using DataLab