MCPcopy Create free account
hub / github.com/PyMesh/PyMesh / assert_PD

Method assert_PD

python/pymesh/tests/test_assembler.py:25–27  ·  view source on GitHub ↗
(self, A)

Source from the content-addressed store, hash-verified

23 self.assertAlmostEqual(0.0, scipy.sparse.linalg.norm(A - A.T))
24
25 def assert_PD(self, A):
26 eig_values, eig_vectors = scipy.sparse.linalg.eigsh(A, 1, which="SM")
27 self.assertLess(0.0, eig_values[0])
28
29 def assert_PSD(self, A):
30 eig_values, eig_vectors = scipy.sparse.linalg.eigsh(A, 1, which="SA")

Callers 3

test_mass_matrixMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected