summaryrefslogtreecommitdiff
path: root/Aircraft_Structures_for_Engineering_Students/Chapter06.ipynb
diff options
context:
space:
mode:
authorhardythe12015-04-07 15:58:05 +0530
committerhardythe12015-04-07 15:58:05 +0530
commit92cca121f959c6616e3da431c1e2d23c4fa5e886 (patch)
tree205e68d0ce598ac5caca7de839a2934d746cce86 /Aircraft_Structures_for_Engineering_Students/Chapter06.ipynb
parentb14c13fcc6bb6d01c468805d612acb353ec168ac (diff)
downloadPython-Textbook-Companions-92cca121f959c6616e3da431c1e2d23c4fa5e886.tar.gz
Python-Textbook-Companions-92cca121f959c6616e3da431c1e2d23c4fa5e886.tar.bz2
Python-Textbook-Companions-92cca121f959c6616e3da431c1e2d23c4fa5e886.zip
added books
Diffstat (limited to 'Aircraft_Structures_for_Engineering_Students/Chapter06.ipynb')
-rwxr-xr-xAircraft_Structures_for_Engineering_Students/Chapter06.ipynb112
1 files changed, 112 insertions, 0 deletions
diff --git a/Aircraft_Structures_for_Engineering_Students/Chapter06.ipynb b/Aircraft_Structures_for_Engineering_Students/Chapter06.ipynb
new file mode 100755
index 00000000..5195a30b
--- /dev/null
+++ b/Aircraft_Structures_for_Engineering_Students/Chapter06.ipynb
@@ -0,0 +1,112 @@
+{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:902d8cc266f9fb597a0d00273b10ab788d226cbd969bb1e960b465c84a750eef"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 06: Matrix methods"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.4 Pg.No.205"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "from __future__ import division\n",
+ "import math\n",
+ "import numpy as np\n",
+ "from sympy import solve, symbols, pprint\n",
+ "from sympy import diff\n",
+ "x,y=symbols('x,y')\n",
+ "\n",
+ "E=200000 #youngs modulus (N/mm^2)\n",
+ "nu=0.3 #poissons ratio\n",
+ "u1=0.001\n",
+ "u2=0.003\n",
+ "u3=-0.003 #displacements of corners (m)\n",
+ "u4=0\n",
+ "v1=-0.004\n",
+ "v2=-0.002\n",
+ "v3=0.001\n",
+ "v4=0.001\n",
+ "\n",
+ "\n",
+ "a=np.array([[1,-2,-1,2],[1,2,-1,-2],[1,2,1,2],[1,-2,1,-2]])\n",
+ "b=np.array([u1,u2,u3,u4])\n",
+ "alpha=np.linalg.solve(a,b)\n",
+ "alpha1=alpha[0]\n",
+ "alpha2=alpha[1]\n",
+ "alpha3=alpha[2]\n",
+ "alpha4=alpha[3]\n",
+ "\n",
+ "a=np.array([[1,-2,-1,2],[1,2,-1,-2],[1,2,1,2],[1,-2,1,-2]])\n",
+ "b=np.array([v1,v2,v3,v4])\n",
+ "alpha=np.linalg.solve(a,b)\n",
+ "alpha5=alpha[0]\n",
+ "alpha6=alpha[1]\n",
+ "alpha7=alpha[2]\n",
+ "alpha8=alpha[3]\n",
+ "\n",
+ "u=alpha1+alpha2*x+alpha3*y+alpha4*x*y\n",
+ "v=alpha5+alpha6*x+alpha7*y+alpha8*x*y\n",
+ "\n",
+ "ex=diff(u,x)\n",
+ "ey=diff(v,y)\n",
+ "Yxy=diff(u,y)+diff(v,x)\n",
+ "\n",
+ "ex=-0.000125\n",
+ "ey=.002\n",
+ "Yxy=-0.0015\n",
+ "\n",
+ "sigma_x=E/(1-nu**2)*(ex+nu*ey)\n",
+ "sigma_y=E/(1-nu**2)*(ey+nu*ex)\n",
+ "print \"longitudinal stress in x direction = %3.1f N/mm^2\"%(sigma_x)\n",
+ "print \"longitudinal stress in y direction = %3.1f N/mm^2\"%(sigma_y)\n",
+ "\n",
+ "T_xy=E/2/(1+nu)*Yxy\n",
+ "print \"shear stress at the center of plate = %3.1f N/mm^2\"%(T_xy)"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "longitudinal stress in x direction = 104.4 N/mm^2\n",
+ "longitudinal stress in y direction = 431.3 N/mm^2\n",
+ "shear stress at the center of plate = -115.4 N/mm^2\n"
+ ]
+ }
+ ],
+ "prompt_number": 44
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [],
+ "language": "python",
+ "metadata": {},
+ "outputs": []
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+} \ No newline at end of file