@@ -0,0 +1,1453 @@
+package org.broadinstitute.sting.utils;%0A%0Aimport org.junit.Assert;%0Aimport org.junit.BeforeClass;%0Aimport org.junit.Test;%0Aimport org.broadinstitute.sting.BaseTest;%0Aimport org.broadinstitute.sting.utils.MathUtils;%0A%0A%0Aimport java.io.File;%0A%0A/**%0A * Basic unit test for MathUtils%0A */%0Apublic class MathUtilsTest extends BaseTest %7B%0A    @BeforeClass%0A    public static void init() %7B %7D%0A%0A    /**%0A     * Tests that we get the right values from the binomial distribution%0A     */%0A    @Test%0A    public void testBinomialProbability() %7B%0A        logger.warn(%22Executing testBinomialProbability%22);%0A%0A        Assert.assertTrue(MathUtils.compareDoubles(MathUtils.binomialProbability(2, 3, 0.5), 0.375, 0.001) == 0);%0A        Assert.assertTrue(MathUtils.compareDoubles(MathUtils.binomialProbability(10, 100, 0.5), 1.365543e-17, 1e-18) == 0);%0A        Assert.assertTrue(MathUtils.compareDoubles(MathUtils.binomialProbability(73, 217, 0.02), 4.521904e-67, 1e-68) == 0);%0A        Assert.assertTrue(MathUtils.compareDoubles(MathUtils.binomialProbability(100, 300, 0.02), 9.27097e-91, 1e-92) == 0);%0A        Assert.assertTrue(MathUtils.compareDoubles(MathUtils.binomialProbability(150, 300, 0.98), 6.462892e-168, 1e-169) == 0);%0A        Assert.assertTrue(MathUtils.compareDoubles(MathUtils.binomialProbability(120, 300, 0.98), 3.090054e-221, 1e-222) == 0);%0A        Assert.assertTrue(MathUtils.compareDoubles(MathUtils.binomialProbability(112, 300, 0.98), 2.34763e-236, 1e-237) == 0);%0A    %7D%0A%7D

Test class for MathUtils with a test for binomialProbability().