コード例 #1
0
 def test_logistic_inflections(self):
     logistic_inflections = inflections(
         'logistic', coefficients[:3],
         logistic_derivatives_object['second']['evaluation'], precision)
     self.assertEqual(logistic_inflections, [5])
コード例 #2
0
 def test_sinusoidal_inflections(self):
     sinusoidal_inflections = inflections(
         'sinusoidal', coefficients[:3],
         sinusoidal_derivatives_object['second']['evaluation'], precision)
     self.assertEqual(sinusoidal_inflections,
                      [5, 6.0472, 7.0944, 8.1416, 9.1888, '5 + 1.0472k'])
コード例 #3
0
 def test_exponential_inflections(self):
     exponential_inflections = inflections(
         'exponential', coefficients[:2],
         exponential_derivatives_object['second']['evaluation'], precision)
     self.assertEqual(exponential_inflections, [None])
コード例 #4
0
 def test_hyperbolic_inflections(self):
     hyperbolic_inflections = inflections(
         'hyperbolic', coefficients[:2],
         hyperbolic_derivatives_object['second']['evaluation'], precision)
     self.assertEqual(hyperbolic_inflections, [None])
コード例 #5
0
 def test_cubic_inflections(self):
     cubic_inflections = inflections(
         'cubic', coefficients,
         cubic_derivatives_object['second']['evaluation'], precision)
     self.assertEqual(cubic_inflections, [-0.5])
コード例 #6
0
 def test_quadratic_inflections(self):
     quadratic_inflections = inflections(
         'quadratic', coefficients[:3],
         quadratic_derivatives_object['second']['evaluation'], precision)
     self.assertEqual(quadratic_inflections, [None])
コード例 #7
0
 def test_linear_inflections(self):
     linear_inflections = inflections(
         'linear', coefficients[:2],
         linear_derivatives_object['second']['evaluation'], precision)
     self.assertEqual(linear_inflections, [None])