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