Example #1
0
 def test_euler4(self):
     expected = 1
     a = 1
     self.assertEquals(expected, Modular.phi(a))
     self.assertEquals(expected, Modular.phi_by_kanon(a))
     self.assertEquals(expected, Modular.phi_by_kanon2(a))
Example #2
0
 def test_euler3(self):
     expected = math.pow(2, 16)
     a = int(math.pow(2, 16) + 1)
     self.assertEquals(expected, Modular.phi(a))
     self.assertEquals(expected, Modular.phi_by_kanon(a))
     self.assertEquals(expected, Modular.phi_by_kanon2(a))