상속: UnivariateContinuousDistribution
        public void ConstructorTest()
        {
            var invchisq = new InverseChiSquareDistribution(degreesOfFreedom: 7);

            double mean = invchisq.Mean;     // 0.2
            double median = invchisq.Median; // 6.345811068141737
            double var = invchisq.Variance;  // 75
            double mode = invchisq.Mode;     // 0.1111111111111111

            double cdf = invchisq.DistributionFunction(x: 6.27); // 0.50860033566176044
            double pdf = invchisq.ProbabilityDensityFunction(x: 6.27); // 0.0000063457380298844403
            double lpdf = invchisq.LogProbabilityDensityFunction(x: 6.27); // -11.967727146795536

            double ccdf = invchisq.ComplementaryDistributionFunction(x: 6.27); // 0.49139966433823956
            double icdf = invchisq.InverseDistributionFunction(p: cdf); // 6.2699998329362963

            double hf = invchisq.HazardFunction(x: 6.27); // 0.000012913598625327002
            double chf = invchisq.CumulativeHazardFunction(x: 6.27); // 0.71049750196765715

            string str = invchisq.ToString(); // "Inv-χ²(x; df = 7)"

            Assert.AreEqual(0.2, mean, 1e-10);
            Assert.AreEqual(6.345811068141737, median, 1e-6);
            Assert.AreEqual(75, var);
            Assert.AreEqual(0.1111111111111111, mode);
            Assert.AreEqual(0.71049750196765715, chf);
            Assert.AreEqual(0.50860033566176044, cdf);
            Assert.AreEqual(0.0000063457380298844403, pdf);
            Assert.AreEqual(-11.967727146795536, lpdf);
            Assert.AreEqual(0.000012913598625327002, hf);
            Assert.AreEqual(0.49139966433823956, ccdf);
            Assert.AreEqual(6.2699998329362963, icdf, 1e-6);
            Assert.AreEqual("Inv-χ²(x; df = 7)", str);

            var range1 = invchisq.GetRange(0.95);
            var range2 = invchisq.GetRange(0.99);
            var range3 = invchisq.GetRange(0.01);

            Assert.AreEqual(2.1673499092513264, range1.Min);
            Assert.AreEqual(14.067140449765922, range1.Max);
            Assert.AreEqual(1.2390421125300894, range2.Min);
            Assert.AreEqual(18.475307115523769, range2.Max);
            Assert.AreEqual(1.2390421125300894, range3.Min);
            Assert.AreEqual(18.475307115523773, range3.Max);
        }
        public void GetRangeTest()
        {
            var invchisq = new InverseChiSquareDistribution(degreesOfFreedom: 1);

            var range1 = invchisq.GetRange(0.95);
            var range2 = invchisq.GetRange(0.99);
            var range3 = invchisq.GetRange(0.01);

            Assert.AreEqual(0.0039321399872199164, range1.Min);
            Assert.AreEqual(3.8414588207219076, range1.Max);

            Assert.AreEqual(0.00015695842882115102, range2.Min);
            Assert.AreEqual(6.6348966014931827, range2.Max);

            Assert.AreEqual(0.00015695842882115102, range3.Min);
            Assert.AreEqual(6.6348966014931854, range3.Max);
        }
        public void GetRangeTest2()
        {
            var invchisq = new InverseChiSquareDistribution(degreesOfFreedom: 4200);

            var range1 = invchisq.GetRange(0.95);
            var range2 = invchisq.GetRange(0.99);
            var range3 = invchisq.GetRange(0.01);

            Assert.AreEqual(4050.3922378834536, range1.Min);
            Assert.AreEqual(4351.8817614873615, range1.Max);
            Assert.AreEqual(3989.7323067750908, range2.Min);
            Assert.AreEqual(4416.1499610177834, range2.Max);
            Assert.AreEqual(3989.7323067750908, range3.Min);
            Assert.AreEqual(4416.1499610177489, range3.Max);
        }