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

Method test_elasticity_tensor

python/pymesh/tests/test_assembler.py:62–70  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

60 self.assert_PSD(K)
61
62 def test_elasticity_tensor(self):
63 assembler = self.single_triangle_2D_setup()
64 E = assembler.assemble("elasticity_tensor")
65 self.assert_symmetry(E)
66 self.assert_PD(E)
67
68 # The default material should yield identity elasticity tensor.
69 I = scipy.sparse.eye(assembler.mesh.dim * (assembler.mesh.dim + 1) / 2)
70 self.assertAlmostEqual(0.0, scipy.sparse.linalg.norm(E-I))
71
72

Callers

nothing calls this directly

Calls 5

assert_symmetryMethod · 0.95
assert_PDMethod · 0.95
normMethod · 0.80
assembleMethod · 0.45

Tested by

no test coverage detected