Notes for Intel® oneAPI Math Kernel Library Vector Statistics

ID 772987
Date 12/04/2020
Public
Document Table of Contents

ChiSquare (VSL_RNG_METHOD_CHISQUARE_CHI2GAMMA)

Random number generator of the chi-square distribution with degrees of freedom v. You can generate any successful random number x of the chi-square distribution as follows:

  1. If v = 1 and v = 3, a chi-square distributed number is generated as a sum of squares of v independent normal random numbers with parameter mean value a = 0 and standard deviation σ = 1.
  2. If v is even and 2 ≤ v ≤ 16, a chi-square distributed random number is generated according to the formula:

    , where ui is a vector of successive random numbers uniformly distributed over the interval (0, 1).
  3. If v ≥ 17 or v is odd and 5 ≤ v ≤ 15, the ChiSquare distribution is reduced to Gamma distribution with parameters shape α = v/2, offset a = 0, and scalefactor β = 2. Random numbers of the Gamma distribution are generated using method VSL_RNG_METHOD_GAMMA_GNORM.

See Intel® oneAPI Math Kernel Library Vector Statistics Random Number Generator Performance Data for test results summary and performance graphs.