Accord.Tests.Statistics.LogLinkFunctionTest.LogLinkFunctionConstructorTest2 C# (CSharp) 메소드

LogLinkFunctionConstructorTest2() 개인적인 메소드

private LogLinkFunctionConstructorTest2 ( ) : void
리턴 void
        public void LogLinkFunctionConstructorTest2()
        {
            LogLinkFunction target = new LogLinkFunction();

            Assert.AreEqual(1, target.B);
            Assert.AreEqual(0, target.A);

            for (int i = 0; i < 11; i++)
            {
                double x = i / 10.0;
                double y = Math.Log(x);

                Assert.AreEqual(y, target.Function(x), 1e-10);
                Assert.AreEqual(x, target.Inverse(y), 1e-10);
            }
        }