Ejemplo n.º 1
0
 def test_pi_on_six(self):
     self.assertAlmostEqual(dc.phase(math.sqrt(3) / 2.0, 1.0 / 2.0),
                            math.pi / 6.0)
Ejemplo n.º 2
0
 def test_zero_one(self):
     self.assertEqual(dc.phase(0.0, 1.0), math.pi / 2.0)
Ejemplo n.º 3
0
 def test_pi_on_four(self):
     self.assertEqual(dc.phase(math.sqrt(2) / 2.0,
                               math.sqrt(2) / 2.0), math.pi / 4.0)
Ejemplo n.º 4
0
 def test_zero_zero(self):
     self.assertEqual(dc.phase(0.0, 0.0), 0.0)
Ejemplo n.º 5
0
 def test_one_zero(self):
     self.assertEqual(dc.phase(1.0, 0.0), 0.0)
Ejemplo n.º 6
0
 def test_pi_on_six(self):
     self.assertAlmostEqual(dc.phase(math.sqrt(3) / 2.0, 1.0 / 2.0), math.pi / 6.0)
Ejemplo n.º 7
0
 def test_pi_on_four(self):
     self.assertEqual(dc.phase(math.sqrt(2) / 2.0, math.sqrt(2) / 2.0), math.pi / 4.0)
Ejemplo n.º 8
0
 def test_zero_one(self):
     self.assertEqual(dc.phase(0.0, 1.0), math.pi / 2.0)
Ejemplo n.º 9
0
 def test_one_zero(self):
     self.assertEqual(dc.phase(1.0, 0.0), 0.0)
Ejemplo n.º 10
0
 def test_zero_zero(self):
     self.assertEqual(dc.phase(0.0, 0.0), 0.0)