In [1]:
import pyPLY
In [2]:
AS4_3501_6 = pyPLY.CompositeMaterial()
AS4_3501_6.define("AS4_3501_6", "imperial", E11=20010000.0, E22=1301000.0, G12=1001000.0, niu12=0.3, thk=0.005)
In [3]:
layer1 = pyPLY.Lamina()
layer2 = pyPLY.Lamina()
layer3 = pyPLY.Lamina()
layer4 = pyPLY.Lamina()
In [4]:
layer1.define("Layer_1", 1, 0)
layer2.define("Layer_2", 1, 45)
layer3.define("Layer_3", 1, 45)
layer4.define("Layer_4", 1, 0)
In [5]:
layer1.update()
layer2.update()
layer3.update()
layer4.update()
In [6]:
laminate1 = pyPLY.Laminate()
laminate1.add_Lamina(layer1)
laminate1.add_Lamina(layer2)
laminate1.add_Lamina(layer3)
laminate1.add_Lamina(layer4)
In [7]:
laminate1.update()
In [8]:
load1 = pyPLY.Loading()
load1.define_Load(500,0,0,0,0,0)
load1.apply_To(laminate1)
In [9]:
print "A = ", laminate1.A
print "B = ", laminate1.B
print "D = ", laminate1.D
In [10]:
from numpy import set_printoptions
set_printoptions(suppress=True)
print "load1.epsilon_K = ", load1.epsilon_K
In [11]:
print " layerNo", "epsx", " epsy", " gammaxy"
for i in range (0, 4):
strain = load1.list_ply_strains_xy[i*3 + 0]
print "bottom ", i+1, '{0:+.4}'.format(strain[0,0]), '{0:+.4}'.format(strain[1,0]), '{0:+.4}'.format(strain[2,0])
strain = load1.list_ply_strains_xy[i*3 + 1]
print "centroid", i+1, '{0:+.4}'.format(strain[0,0]), '{0:+.4}'.format(strain[1,0]), '{0:+.4}'.format(strain[2,0])
strain = load1.list_ply_strains_xy[i*3 + 2]
print "top ", i+1, '{0:+.4}'.format(strain[0,0]), '{0:+.4}'.format(strain[1,0]), '{0:+.4}'.format(strain[2,0])
In [12]:
print " layerNo", "sigmax", " sigmay", " sigmaxy"
for i in range (0, 4):
stress = load1.list_ply_stresses_xy[i*3 + 0]
print "bottom ", i+1, '{0:+.4}'.format(stress[0,0]), '{0:+.4}'.format(stress[1,0]), '{0:+.4}'.format(stress[2,0])
stress = load1.list_ply_stresses_xy[i*3 + 1]
print "centroid", i+1, '{0:+.4}'.format(stress[0,0]), '{0:+.4}'.format(stress[1,0]), '{0:+.4}'.format(stress[2,0])
stress = load1.list_ply_stresses_xy[i*3 + 2]
print "top ", i+1, '{0:+.4}'.format(stress[0,0]), '{0:+.4}'.format(stress[1,0]), '{0:+.4}'.format(stress[2,0])
In [13]:
print " layerNo", "eps11", " eps22", " gamma12"
for i in range (0, 4):
strain = load1.list_ply_strains_12[i*3 + 0]
print "bottom ", i+1, '{0:+.4}'.format(strain[0,0]), '{0:+.4}'.format(strain[1,0]), '{0:+.4}'.format(strain[2,0])
strain = load1.list_ply_strains_12[i*3 + 1]
print "centroid", i+1, '{0:+.4}'.format(strain[0,0]), '{0:+.4}'.format(strain[1,0]), '{0:+.4}'.format(strain[2,0])
strain = load1.list_ply_strains_12[i*3 + 2]
print "top ", i+1, '{0:+.4}'.format(strain[0,0]), '{0:+.4}'.format(strain[1,0]), '{0:+.4}'.format(strain[2,0])
In [14]:
print " layerNo", "sigma11", " sigma22", " tau12"
for i in range (0, 4):
stress = load1.list_ply_stresses_12[i*3 + 0]
print "bottom ", i+1, '{0:+.4}'.format(stress[0,0]), '{0:+.4e}'.format(stress[1,0]), '{0:+.4}'.format(stress[2,0])
stress = load1.list_ply_stresses_12[i*3 + 1]
print "centroid", i+1, '{0:+.4}'.format(stress[0,0]), '{0:+.4e}'.format(stress[1,0]), '{0:+.4}'.format(stress[2,0])
stress = load1.list_ply_stresses_12[i*3 + 2]
print "top ", i+1, '{0:+.4}'.format(stress[0,0]), '{0:+.4e}'.format(stress[1,0]), '{0:+.4}'.format(stress[2,0])