コード例 #1
0
ファイル: MathTest.cs プロジェクト: epam/DFP
        public void TestIsCanonical()
        {
            Assert.True(Scalbn(FromInt32(314), -2).IsCanonical());
            Assert.True(Scalbn(FromInt32(-314), -2).IsCanonical());

            Assert.True(Zero.IsCanonical());

            Assert.True(NaN.IsCanonical());
            Assert.True(PositiveInfinity.IsCanonical());
            Assert.True(NegativeInfinity.IsCanonical());
        }
コード例 #2
0
ファイル: MathTest.cs プロジェクト: epam/DFP
        public void TestIsSubnormal()
        {
            Assert.False(Scalbn(FromInt32(314), -2).IsSubnormal());
            Assert.False(Scalbn(FromInt32(-314), -2).IsSubnormal());

            Assert.False(Zero.IsSubnormal());

            Assert.False(NaN.IsSubnormal());
            Assert.False(PositiveInfinity.IsSubnormal());
            Assert.False(NegativeInfinity.IsSubnormal());
        }