MCPcopy Create free account
hub / github.com/geekcomputers/Python / test__eq__vector

Method test__eq__vector

linear-algebra-python/src/tests.py:159–163  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

157 self.assertAlmostEqual(x.norm().component(1), math.sqrt((2.0 / 7)), 0.001)
158
159 def test__eq__vector(self):
160 x = Vector([1, 2, 3])
161 y = Vector([1, 0, 1])
162 self.assertTrue(x == x)
163 self.assertFalse(x == y)
164
165 def test__eq__matrix(self):
166 A = Matrix([[1, 2, 3], [2, 4, 5], [6, 7, 8]], 3, 3)

Callers

nothing calls this directly

Calls 1

VectorClass · 0.85

Tested by

no test coverage detected