F-distribution
Name
UxHwDoubleFDist, UxHwFloatFDist — Create an F-distribution.
Synopsis
#include <uxhw.h>
double UxHwDoubleFDist(double d1, double d2);
float UxHwFloatFDist(float d1, float d2);
Description
The UxHwDoubleFDist() function, on architectures that associate distributional information with floating-point values, creates an F distribution with parameters d1 and d2 and associates it with its return value. The particle return value is the mean value of an F-distribution with parameters d1 and d2. The probability density function of the F-distribution is
where is the Beta function and is the Gamma function.
Parameters
d1— The parameter () of the F-distribution.d2— The parameter () of the F-distribution.
Return Values
The UxHwDoubleFDist() function returns the mean of samples of a F-distribution with parameters d1 and d2.
If d1<=0or d2<=2, the function returns NaN.
✏️ Examples
#include <stdio.h>
#include <uxhw.h>
int
main(void)
{
double value = UxHwDoubleFDist(1.0,3.0);
printf("value = %lf\n", value);
return 0;
}