a mechanical engineering toolbox
source code - https://github.com/nagordon/mechpy
documentation - https://nagordon.github.io/mechpy/
Neal Gordon
2017-02-20
This a collection of sample codes for various calcuations useful for composites mechanics
In [1]:
cd ..
In [11]:
# setup
import numpy as np
import sympy as sp
import scipy
from pprint import pprint
sp.init_printing(use_latex='mathjax')
import matplotlib.pyplot as plt
plt.rcParams['figure.figsize'] = (12, 8) # (width, height)
plt.rcParams['font.size'] = 14
plt.rcParams['legend.fontsize'] = 16
from matplotlib import patches
#get_ipython().magic('matplotlib') # seperate window
get_ipython().magic('matplotlib inline') # inline plotting
In [12]:
from mechpy.math import T3rot, T6rot
from mechpy.composites import my_laminate_with_loading, material_plots, laminate_gen, \
plot_single_max_failure_loads
In [13]:
import importlib
importlib.reload
Out[13]:
In [14]:
from mechpy.math import T2rot
T2rot(45)
Out[14]:
In [15]:
print(T6rot(45,45,45))
In [16]:
help(laminate_gen)
In [17]:
%matplotlib inline
In [18]:
material_plots()
In [19]:
my_laminate_with_loading()
In [20]:
plot_single_max_failure_loads(mymat='E-Glass Epoxy fabric M10E-3783', mylayup=[0,45,45,0] )
Out[20]:
In [ ]:
In [ ]:
In [ ]: