PROBC contains routines for handling various discrete and continuous probability density functions (PDF's). For a discrete variable K, PDF(N) is the probability that K takes on the value N; for a continuous variable Y, PDF(X) is the probability density at Y = X.
The corresponding cumulative density functions (CDF's) are also handled. For a discrete variable K, CDF(N) is the probability that K takes on a value which is less than or equal to N; for a continuous variable Y, CDF(X) is the probability that Y takes on a value less than or equal to X.
For each distribution, the mean or "average value" or "expected value" is also available. For a discrete variable K, MEAN is simply the sum of the products N * PDF(N) for all N; for a continuous variable, MEAN is the integral of X * PDF(X) over the range of Y. For the distributions covered here, the means are known beforehand, and no summation or integration is required.
For each distribution, the variance is available. For a discrete variable K, the variance is the sum of the products ( N - MEAN )**2 * PDF(N) for all N; for a continuous variable, the variance is the integral of ( X - MEAN )**2 * PDF(X) over the range of Y. The square root of the variance is known as the standard deviation. For the distributions covered here, the variances are known beforehand, and no summation or integration is required.
PROBC is a C version of a subset of the FORTRAN PROB collection.
Files you may copy include:
The list of routines includes:
Return to the C software page.