Lines Matching defs:INF
7 INF = float('inf')
12 (INF, 0.0), # 1st quadrant
13 (INF, 2.3),
14 (INF, INF),
15 (2.3, INF),
16 (0.0, INF),
17 (-0.0, INF), # 2nd quadrant
18 (-2.3, INF),
19 (-INF, INF),
20 (-INF, 2.3),
21 (-INF, 0.0),
22 (-INF, -0.0), # 3rd quadrant
23 (-INF, -2.3),
24 (-INF, -INF),
25 (-2.3, -INF),
26 (-0.0, -INF),
27 (0.0, -INF), # 4th quadrant
28 (2.3, -INF),
29 (INF, -INF),
30 (INF, -2.3),
31 (INF, -0.0)
34 (NAN, -INF),
39 (NAN, INF),
40 (-INF, NAN),
45 (INF, NAN)
382 self.assertAlmostEqual(phase(complex(-INF, -0.0)), -pi)
383 self.assertAlmostEqual(phase(complex(-INF, -2.3)), -pi)
384 self.assertAlmostEqual(phase(complex(-INF, -INF)), -0.75*pi)
385 self.assertAlmostEqual(phase(complex(-2.3, -INF)), -pi/2)
386 self.assertAlmostEqual(phase(complex(-0.0, -INF)), -pi/2)
387 self.assertAlmostEqual(phase(complex(0.0, -INF)), -pi/2)
388 self.assertAlmostEqual(phase(complex(2.3, -INF)), -pi/2)
389 self.assertAlmostEqual(phase(complex(INF, -INF)), -pi/4)
390 self.assertEqual(phase(complex(INF, -2.3)), -0.0)
391 self.assertEqual(phase(complex(INF, -0.0)), -0.0)
392 self.assertEqual(phase(complex(INF, 0.0)), 0.0)
393 self.assertEqual(phase(complex(INF, 2.3)), 0.0)
394 self.assertAlmostEqual(phase(complex(INF, INF)), pi/4)
395 self.assertAlmostEqual(phase(complex(2.3, INF)), pi/2)
396 self.assertAlmostEqual(phase(complex(0.0, INF)), pi/2)
397 self.assertAlmostEqual(phase(complex(-0.0, INF)), pi/2)
398 self.assertAlmostEqual(phase(complex(-2.3, INF)), pi/2)
399 self.assertAlmostEqual(phase(complex(-INF, INF)), 0.75*pi)
400 self.assertAlmostEqual(phase(complex(-INF, 2.3)), pi)
401 self.assertAlmostEqual(phase(complex(-INF, 0.0)), pi)
414 self.assertEqual(abs(z), INF)
417 self.assertEqual(abs(complex(NAN, -INF)), INF)
422 self.assertEqual(abs(complex(NAN, INF)), INF)
423 self.assertEqual(abs(complex(-INF, NAN)), INF)
428 self.assertEqual(abs(complex(INF, NAN)), INF)
450 self.assertFalse(cmath.isnan(INF))
455 self.assertTrue(cmath.isnan(complex(NAN, INF)))
456 self.assertTrue(cmath.isnan(complex(INF, NAN)))
462 self.assertTrue(cmath.isinf(INF))
463 self.assertTrue(cmath.isinf(complex(INF, 0)))
464 self.assertTrue(cmath.isinf(complex(0, INF)))
465 self.assertTrue(cmath.isinf(complex(INF, INF)))
466 self.assertTrue(cmath.isinf(complex(NAN, INF)))
467 self.assertTrue(cmath.isinf(complex(INF, NAN)))