def test_2D_tri(self):
     assert_allclose(polygon_2nd_moment_of_area(self.shp['2D tri']),
                     np.array([0.38888889, 0.66666667, 0.]))
 def test_octahedral_tri(self):
     assert_allclose(polygon_2nd_moment_of_area(self.shp['octahedral tri']),
                     np.array([0.05555556, 0.05555556, 0.05555556]))
 def test_right_tri(self):
     assert_allclose(polygon_2nd_moment_of_area(self.shp['right tri']),
                     np.array([0.05555556, 0.05555556, 0.]))
 def test_unit_square(self):
     assert_allclose(polygon_2nd_moment_of_area(self.shp['unit square']),
                     [0.08333333, 0.08333333, 0.])
Example #5
0
 def test_2D_tri(self):
     assert_allclose(polygon_2nd_moment_of_area(self.shp['2D tri']),
                     np.array([ 0.38888889,  0.66666667,  0.        ]))
Example #6
0
 def test_octahedral_tri(self):
     assert_allclose(polygon_2nd_moment_of_area(self.shp['octahedral tri']),
                     np.array([ 0.05555556,  0.05555556,  0.05555556]))