コード例 #1
0
ファイル: test_nthderiv.py プロジェクト: shoyer/algopy
 def test_sqrt_n1(self):
     x = 0.123
     a = nthderiv.sqrt(x, n=1)
     b = 1 / (2 * np.sqrt(x))
     assert_allclose(a, b)
コード例 #2
0
ファイル: test_nthderiv.py プロジェクト: argriffing/algopy
 def test_sqrt_n1(self):
     x = 0.123
     a = nthderiv.sqrt(x, n=1)
     b = 1 / (2 * np.sqrt(x))
     assert_allclose(a, b)
コード例 #3
0
ファイル: test_nthderiv.py プロジェクト: shoyer/algopy
 def test_sqrt_n0(self):
     x = 0.123
     a = nthderiv.sqrt(x, n=0)
     b = np.sqrt(x)
     assert_allclose(a, b)
コード例 #4
0
ファイル: test_nthderiv.py プロジェクト: argriffing/algopy
 def test_sqrt_n0(self):
     x = 0.123
     a = nthderiv.sqrt(x, n=0)
     b = np.sqrt(x)
     assert_allclose(a, b)