Пример #1
0
        public void ValidateDensity(double scale, double x)
        {
            var    n        = new Rayleigh(scale);
            double expected = (x / (scale * scale)) * Math.Exp(-x * x / (2.0 * scale * scale));

            Assert.AreEqual(expected, n.Density(x));
            Assert.AreEqual(expected, Rayleigh.PDF(scale, x));
        }