Beispiel #1
0
 def test_width_45_angle(self):
     w = 6 * DIAMETER
     bearing = [100, 100]
     bypass = [0, 0, 0]
     p, theta = self.analysis.bearing_angle(bearing)
     bypass_correction = rotate_plane_stress(np.array([p / (2 * w), 0, 0]),
                                             angle=-theta)
     brg = LoadedHole(p, DIAMETER, QUASI_THICK, QUASI_INV, theta=theta)
     byp = UnloadedHole(bypass_correction, DIAMETER, QUASI_THICK, QUASI_INV)
     x, y = self.analysis.xy_points(rc=0., num=100)
     byp_stress = byp.stress(x, y)
     brg_stress = brg.stress(x, y)
     total_stress = byp_stress + brg_stress
     analysis_stress = self.analysis.stresses(bearing,
                                              bypass,
                                              rc=0.,
                                              num=100,
                                              w=w)
     assert_array_almost_equal(total_stress, analysis_stress)
Beispiel #2
0
 def test_width_0_angle(self):
     w = 6 * DIAMETER
     bearing = [100, 0]
     bypass = [0, 0, 0]
     bypass_correction = [100 / (2 * w), 0, 0]
     brg = LoadedHole(bearing[0],
                      DIAMETER,
                      QUASI_THICK,
                      QUASI_INV,
                      theta=0.)
     byp = UnloadedHole(bypass_correction, DIAMETER, QUASI_THICK, QUASI_INV)
     x, y = self.analysis.xy_points(rc=0., num=100)
     byp_stress = byp.stress(x, y)
     brg_stress = brg.stress(x, y)
     total_stress = byp_stress + brg_stress
     analysis_stress = self.analysis.stresses(bearing,
                                              bypass,
                                              rc=0.,
                                              num=100,
                                              w=w)
     assert_array_almost_equal(total_stress, analysis_stress)
Beispiel #3
0
 def loaded_test_case(a_inv, h, d, step, x_pnts, y_pnts, p, alpha=0.):
     p_func = LoadedHole(p, d, h, a_inv, theta=np.deg2rad(alpha))
     p_stress = p_func.stress(x_pnts, y_pnts)
     f_stress, f_u, f_v = bjsfm.loaded(4 * p / h, d, a_inv, alpha, step,
                                       len(x_pnts) // 2)
     return f_stress, p_stress