示例#1
0
        public void TestAcosh()
        {
            double d = 0;

            d = MathX.Acosh(0);
            Assert.IsTrue(Double.IsNaN(d), "Acosh 0 is NaN");

            d = MathX.Acosh(1);
            AssertEquals("Acosh 1 ", 0, d);

            d = MathX.Acosh(-1);
            Assert.IsTrue(Double.IsNaN(d), "Acosh -1 is NaN");

            d = MathX.Acosh(100);
            AssertEquals("Acosh 100 ", 5.298292366d, d);

            d = MathX.Acosh(101.001);
            AssertEquals("Acosh 101.001 ", 5.308253091d, d);

            d = MathX.Acosh(200000);
            AssertEquals("Acosh 200000 ", 12.89921983d, d);
        }
示例#2
0
 public override double Evaluate(double d)
 {
     return(MathX.Acosh(d));
 }