Check all symmetries of elasticity tensor.
(self, tensor, dim)
| 9 | |
| 10 | class MaterialTest(TestCase): |
| 11 | def assert_symmetry(self, tensor, dim): |
| 12 | """ Check all symmetries of elasticity tensor. |
| 13 | """ |
| 14 | C = tensor |
| 15 | for i in range(dim): |
| 16 | for j in range(dim): |
| 17 | for k in range(dim): |
| 18 | for l in range(dim): |
| 19 | self.assertAlmostEqual(C[i,j,k,l], C[j,i,k,l]) |
| 20 | self.assertAlmostEqual(C[i,j,k,l], C[i,j,l,k]) |
| 21 | self.assertAlmostEqual(C[i,j,k,l], C[k,l,i,j]) |
| 22 | |
| 23 | def test_isotropic_material(self): |
| 24 | young = 1000.0 |
no outgoing calls
no test coverage detected