public void DecimalTest() { Assert.Equal(1m, NdMath.Exp(0m), 27); Assert.Equal(NdMath.E <decimal>(), NdMath.Exp(1m), 27); Assert.Equal(1.64872127070012814684865078781m, NdMath.Exp(0.5m), 27); Assert.Equal(4.48168907033806482260205546012m, NdMath.Exp(1.5m), 27); Assert.Equal(0.223130160148429828933280470764m, NdMath.Exp(-1.5m), 27); }
public void FloatTest(float x, float ans) => Assert.Equal(ans, NdMath.Exp(x), 6);