Chi-Square Distribution: New Derivations and Environmental Application

We describe two new derivations of the chi-square distribution. The first derivation uses the induction method, which requires only a single integral to calculate. The second derivation uses the Laplace transform and requires minimum assumptions. The new derivations are compared with the established derivations, such as by convolution, moment generating function, and Bayesian inference. The chi-square testing has seen many applications to physics and other fields. We describe a unique version of the chi-square test where both the variance and location are tested, which is then applied to environmental data. The chi-square test is used to make a judgment whether a laboratory method is capable of detection of gross alpha and beta radioactivity in drinking water for regulatory monitoring to protect health of population. A case of a failure of the chi-square test and its amelioration are described. The chi-square test is compared to and supplemented by the t-test.


Introduction
The chi-square distribution (CSD) has been one of the most frequently used distributions in science. It is a special case of the gamma distribution (see Section 2). The latter has been an important distribution in fundamental physics, for example as kinetic energy distribution of particles in an ideal gas (Maxwell-Boltzmann) [1] or the kinetic energy distribution of particles emitted from excited nuclei in nuclear reactions [2]. A historical context for the development of the CSD is de- [5], who used multiple integrals over normal variables and substitutions. Abbe [6] used a method of integration in the complex plane to solve multiple integrals.
The most general derivation is attributed to Helmert, who proposed a classic transformation to derive CSD, including calculation of the Jacobian determinant of transformation [7]. This transformation can be worked out into polar variables, which is described in statistical textbooks [4] [8].
The established fundamental derivations of the CSD described above lend themselves to complicated handling of multiple integrals. On the contrary, the simplified derivations use the fact that CSD is a special case of the gamma distribution. Owing to the integrable and recursive properties of the gamma distribution, as well as its moment generating function (Mgf), simplified derivations of CSD are described in the textbooks [9] [10]. Another simplified derivation uses Bayesian inference [11]. In Section 2, we refer to these methods for comparisons.
In this work, we present two new methods of derivation of the CSD. They are both within the simplified category. One of them is mathematical induction. The original derivation was done by Helmert [12] using a 2-step forward mathematical induction. We have elaborated on that and observed that the CSD has certain recursive property, which enables its derivation using a single-step induction plus the well-known theorem for beta and gamma functions. Another derivation method we describe is by the Laplace transform. This method has some similarity to the Mgf and characteristic function methods, owing to the presence of exponentiation. It uses a complex-variable integration and it is free from many assumptions of the other methods. The two new derivations of the CSD by mathematical induction and Laplace transform are described in Section 2.
Chi-square testing (CST) is closely related to and based upon the CSD. It has its origins in the discovery of the goodness-of-fit test by Pearson [13]. In the goodness-of-fit, one calculates the test statistics as , where n is the number of observations, i x is the observed variable, i µ is the expected value, i σ is the standard deviation, and n ν ≤ . The variables in Equation (2) can be expressed in physical units. In the limit of large number of observations, the variable and parameters of Equation (2) are approximated by those of the normal variates, and the 2 ν χ distributes as CSD. In this work, we generalize this CST test to a combined test for variance and location as well as verify it with the t-test [17]. The test statistics studied are described in Section 3.
Within the context of this work, we present a unique application of the CST to the detection of radioactive contaminants in drinking water required by the Safe Drinking Water Act (SDWA) in the US. The bulk of natural alpha and beta/gamma (photon) radioactivity in drinking water originates from the possible presence of 238 U and 232 Th natural radioactive-series progeny, 226,228 Ra and their progeny, as well as 40 K radionuclides [18]. The SDWA regulations [19] establish a Maximum Contaminant Level (MCL) of 15 pCi/L (555 mBq/L) for gross alpha (GA) radioactivity, excluding U and Rn. For gross beta (GB) radioactivity, the MCL is limited by the total body or any organ radiation dose of 4 mrem/y (40 μSv/y). For both GA and GB, the Maximum Contaminant Level Goal (MCLG) is zero. Furthermore, SDWA requires Detection Limits (DL) of 3 pCi/L (111 mBq/L) and 4 pCi/L (148 mBq/L) for GA and GB radioactivity, respectively. These DLs must be met by all public health laboratories accredited for monitoring of GA and GB radioactivity in drinking water in the US. In Section 4, we detail a CST procedure to verify if the required above-mentioned DLs are met [20].
We investigate the reasons and consequences of failed CST and ameliorate such cases.

Chi-Square Distribution
The probability density function (Pdf) of the CSD is given by which has the Pdf given by Equation (3) for 1 ν = . In deriving Equation (5), we also used ( ) = , whereas factor of 2 originated from the fact that the 1 x variable ranging from minus infinity to plus infinity has been substituted with the 2 1 χ variable ranging from zero to plus infinity.
Let us assume that the 1 n + term with the normal 1 n x + variable was added to Equation (2), and that this addition raised the number of degrees of freedom to 1 ν + . Then, Using the calculus for probability density functions [21], Let us define a new variable z, such as ( ) By realizing that , and performing all substitutions, the right side of Equation (7) can be rewritten as However, the integral on the right side of Equation (9) is the beta function, , which is related to the gamma functions by [22], By inserting Equation (10) into Equation (9), simplifying, and comparing with the left side of Equation (7), one obtains which is the Pdf given by Equation (3)  The sum of independent random variables 2 i ϕ is called a convolution and the joint distribution function for 2 ν χ can be obtained by calculating an n-dimensional convolution integral. Exploring the properties of this convolution leads to simplifications, which have been used in the literature. By convoluting two gamma distributions 2 (5) and using the theorem that the convolution of two gammas is also a gamma, one obtains ( ) 2 2 gamma | 2 2, 2 χ [9]. By continuing this process of convoluting with 2 1 χ , it is easy to infer that the full convolution is equal to , where n ν = , which the CSD given by Equation (3). This provides a simplified derivation of CSD using convolution.
Another simplified derivation of CSD uses the theorem that the Mgf of convolution is a product of individual Mgfs [10]. Thus, by calculating Mfg of 2 1 χ from Equation (5) and taking it to the nth power, one obtains the Mgf for 2 ν χ , where n ν = . One can also calculate the Mgf of the gamma distribution and infer from a comparison that the CSD in Equation (3) is a special case of the gamma distribution [10].
In this work we provide yet another simplified derivation of the CSD using Laplace transform [23]. The Laplace transform of Equation (5) Subsequently, we use a theorem that the Laplace transform of a nth convolution is a product of the individual transforms, i.e.
To calculate the contour integral in Equation (14), we start with the Cauchy integration formula for an analytic function ( ) f s of a complex variable s having a simple pole at 0 s [24]: The 1 k − times differentiation of Equation (15), where the differentiation can be of an integer or a fractional order [25], results in: By comparing Equation (14) to Equation ( Another simplified derivation of the CSD uses the Bayesian inference and it is not related to the convolutions described above [11]. It uses a normal likelihood function for multiple samples. It also uses the transformational prior distributions: 1 σ ∝ for scale parameter σ and a constant for translation parameter µ [26]. Marginalizing the joint distribution ( ) , µ σ over µ results in the CSD, whereas marginalizing over σ results in the t-distribution [27].
In Section 5, we summarize the advantages and disadvantages of the simplified derivation methods of CSD described in this section.

Test Statistics
Several models for the CST statistics can be derived from the general Equation (2). For the t-test we perform a standard one-sample test, where we calculate t variable as ( . The t-test is the location test. The results of all these test models using radioactivity data are presented in Section 4.

Chi-Square-and t-Test for Radioactivity Detection in Drinking Water
The most convenient method of measuring GA and GB radioactivity in drinking water is by gas proportional counting [28]. In this method, a given quantity of water is evaporated with nitric acid onto a stainless-steel planchet and dried, leaving a residue containing any radioactivity. The planchet is then counted on a gas proportional detector. Alpha and beta particles are counted simultaneously, and they are differentiated by much larger ionization caused by the former.
As stated in Section 1, this method must be able to determine GA and GB at the DL, to be verified by the CST [20] using a minimum of seven samples. EPA  Table 1). However, the observed 2 χ of 43.1 and 93.7 exceed the calculated RT 2 χ of 21.7 (columns 4 and 5 in Table 1 Table 1) ensuring the passage of the three CSTs. This is supported by the passage of the t-test also (columns 6, 7, and 8).     The reasons for the elevated GB in MB of community drinking water were investigated. Ten L of water were evaporated to 50 mL and measured using precise gamma-ray spectrometry [29]. It was determined that the concentration of the beta/gamma emitter, 40 K was 0.6926 ± 0.0790 pCi/L. It was also possible to identify several beta/gamma progenies of the 238 U series: 234 Th, 214 Pb, 214 Bi, and 210 Pb, as well as those from the 232 Th series: 228 Ac, 212 Pb, and 208 Tl. The combined activity of the beta/gamma progeny was 0.1513 ± 0.0672 pCi/L. Therefore, the sum of 40 K and beta/gamma progeny was 0.8440 ± 0.1037 pCi/L. The latter is consistent with the GB activity of 0.8121 ± 0.2801 pCi/L from the MB measurement to within the measured uncertainties. Also associated with the decay of 238 U and 232 Th is their alpha activity plus alpha progeny of similar activity to that of the beta/gamma progeny. This alpha activity could not have been detected by gamma spectrometry and was below the detection by GA in the MB measurement. However, the fact that GA of 3.0951 pCi/L is slightly higher than the expected 2.9888 pCi/L is an indication of that. Unlike in the case of beta activity, the small alpha progeny activity did not affect the CST or t-test. It should be noted that this level of naturally present radioactivity in the community water is much below the MCL, and thus poses small risk to the population.

Summary and Conclusions
We have described five simplified methods of deriving the chi-square distribution. Three of them: by convolution, moment generating function, and Bayesian In this work, we have proposed two new methods for derivation of the chi-square distribution: by induction and by Laplace transform. The method of induction uses operational calculus with only a single integral leading to beta function. The proposed derivation applies modern formalism and seems to be simpler than the original derivation by Helmert as early as in 1876. A disadvantage of the induction method is that it requires a prior knowledge of the chi-square distribution to perform induction on it. There is a significant advantage, however. All other methods require either no constraints in the data; i.e. the number of degrees of freedom must be equal to the number of observations, or one constraint in case of Bayesian inference. The induction method leaves any constraints intact by adding one induction step to the existing number of degrees of freedom. The proposed derivation method by Laplace transform is more advanced because it uses integration in the complex plane. The significant advantage of the Laplace transform, and the Bayes inference methods is that they do not require prior knowledge about the gamma distribution.
We have also described a unique application of the chi-square test to environmental science. In chi-square testing, it is important to delineate systematic effects from the random uncertainties. In this work, a systematic natural contamination of laboratory method blank caused the chi-square test for combined variance/location to fail; however, it did not affect the chi-square test for variance alone. After subtracting the systematic method blank, the chi-square variance/location test was shown to have passed. This was confirmed by the location t-test. It is also imperative to perform analysis of uncertainty. In this work, using either individual or sample standard deviations did not affect the variance/location chi-square test. While the chi-square test provides verification if a laboratory test method is adequate to monitor gross alpha and gross beta radioactivity in drinking water, the test statistics combining variance and location is more useful than the one based on the variance alone because it can identify systematic bias.