def test_laminate_applied_force_for_laminae_midplane_stress(self): """Apply a force to a laminate and determine the midplane stresses of the laminae in the laminate. 'Fiber-Reinforced Composites' by Mallick (3rd edition), Example 3.13 Test will look at the midplane stresses of the two laminae in the laminate. """ ply = Ply(E1=133.4e9, E2=8.78e9, nu12=0.26, G12=3.254e9, h=0.006) # h is in [mm] laminae_pos45 = Laminae(ply=ply, theta_rad=(45.0*np.pi/180.0)) laminae_neg45 = Laminae(ply=ply, theta_rad=(-45.0*np.pi/180.0)) laminae_list = [laminae_pos45, laminae_neg45] laminate = Laminate(laminae_list) N = np.matrix.transpose(np.matrix([100.0e3, 0.0, 0.0])); # N[0] is in [N/m] M = np.matrix.transpose(np.matrix([0.0, 0.0, 0.0])); strain_dictionary = laminate.applied_stress(N,M) Epsilon = strain_dictionary['Epsilon'] Kappa = strain_dictionary['Kappa'] laminae_midplane_strains = laminate.laminae_midplane_strain(Epsilon, Kappa) laminae_midplane_stresses = laminate.laminae_stress(Epsilon, Kappa) laminae_midplane_stress_expected = np.power(10.0,6.0)*np.matrix.transpose(np.matrix([8.33, 0.0, 2.09])) self.assertMatrixAlmostEqualPercent(laminae_midplane_stresses[0],laminae_midplane_stress_expected) laminae_midplane_stress_expected = np.power(10.0,6.0)*np.matrix.transpose(np.matrix([8.33, 0.0, -2.09])) self.assertMatrixAlmostEqualPercent(laminae_midplane_strains[1],laminae_midplane_stress_expected)