summaryrefslogtreecommitdiff
path: root/MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb
diff options
context:
space:
mode:
authorTrupti Kini2016-11-24 23:30:37 +0600
committerTrupti Kini2016-11-24 23:30:37 +0600
commit3727ade10dd304eb7a596cac7adb00302953e402 (patch)
tree664e414e47c97a577af8ede629a1026f4c5c97b9 /MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb
parente2984baaac8ec023123503a40110435e68d62756 (diff)
downloadPython-Textbook-Companions-3727ade10dd304eb7a596cac7adb00302953e402.tar.gz
Python-Textbook-Companions-3727ade10dd304eb7a596cac7adb00302953e402.tar.bz2
Python-Textbook-Companions-3727ade10dd304eb7a596cac7adb00302953e402.zip
Added(A)/Deleted(D) following books
A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter11.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter12.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter13.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter14.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter15.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter16.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter18.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter19.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter2.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter20.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter21.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter22.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter23.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter5.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter6.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter8.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/Chapter9.ipynb A Electrical_&_Electronic_Systems_by_Neil_Storey/screenshots/pic1.png A Electrical_&_Electronic_Systems_by_Neil_Storey/screenshots/pic2.png A Electrical_&_Electronic_Systems_by_Neil_Storey/screenshots/pic3.png A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter10_67BmtXx.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter10_LGPoR7F.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter10_PDCS2qh.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter10_lNjLAte.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter10_n5s4jXl.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter10_npy5vv0.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter10_pjpRgex.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_IE4byFL.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_RAQoou9.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_VcicGy5.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_hoqMFBX.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_iBTGbp8.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_k1rTVhh.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_nGrFEGY.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter11_pfzLlc6.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter1_1FJHa67.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter1_2wryDDQ.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter1_BuZVTIP.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter1_UCsno1y.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter1_Yd7uN6t.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter1_bGP3Wsd.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter1_pFJzyF5.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter2_242icmu.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter2_Rcy1wii.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter2_TvxYpxT.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter2_VU0Vuul.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter2_Xiz19Ms.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter2_rAG8C10.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter2_xUN650b.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter3_0WKL8dM.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter3_BsRbQCe.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter3_IF7BAbT.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter3_Qh2uphO.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter3_WS64jkH.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter3_aM1BqRM.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter3_tEQK8Lr.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_0E18xYL.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_4P7HQZZ.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_8GR2j3i.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_KE5ki12.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_LmrwpIC.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_wUtoaip.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter5_0Ke5Vhq.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter5_23aeJMe.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter5_4a14Khd.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter5_eftppGy.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter5_jOQv5Ua.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter5_m75AW4e.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter5_mZ9916M.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter6_2OboaPO.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter6_Cf1Ae70.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter6_IZI7GIy.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter6_TRm6El0.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter6_WfVJQIc.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter6_Z5dEk19.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter6_z9FlTqT.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter8_6BR5OK6.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter8_FV7Jgrb.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter8_Q79Sp1O.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter8_Qhj9HPA.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter8_fBoE3j3.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter8_mFOxHz2.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter8_zNY63b3.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter9_039FJN6.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter9_0AhnrOb.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter9_8K1gGKx.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter9_E4M5MRA.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter9_Ivqhz8T.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter9_ZSvbidk.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter9_u7ekl0N.ipynb A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/screenshots/ch1_mHmqCLQ.png A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/screenshots/ch_9_UicjBqW.png A MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/screenshots/ch_xk3ylh6.png A basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter2_eh02mMg.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter4_QnODdtI.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/Chapter5_IwMblyq.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/chapter11_nHcyQSN.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/chapter1_ivpTi0v.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/chapter3.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/chapter6_7Vcvq3x.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/chapter7_Iro5ijO.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/chapter8_dRxKPQv.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/chapter9_QP9exWK.ipynb A basic_electrical_engineering_by_nagsarkar_and_sukhija/screenshots/chap1_gG9EuuG.png A basic_electrical_engineering_by_nagsarkar_and_sukhija/screenshots/chapter2_RW9JXUw.png A basic_electrical_engineering_by_nagsarkar_and_sukhija/screenshots/chapter6_kNIRtlM.png
Diffstat (limited to 'MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb')
-rw-r--r--MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb1403
1 files changed, 1403 insertions, 0 deletions
diff --git a/MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb b/MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb
new file mode 100644
index 00000000..d78e1aa8
--- /dev/null
+++ b/MECHANICS_OF_SOLIDS_by_S.S._Bhavikatti/Chapter4_ZuWrQKN.ipynb
@@ -0,0 +1,1403 @@
+{
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Chapter4-DISTRIBUTED FORCES, CENTRE OF GRAVITY AND MOMENT OF INERTIA"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.1 page number 102\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 1,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 407.44 mm\n",
+ "yc= 101.65 mm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import cos,sin,pi\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "L1=600.0 #length of wire AB,mm\n",
+ "L2=200.0 #length of wire BC,mm\n",
+ "L3=300.0 #length of wire CD,mm\n",
+ "theta=45*pi/180\n",
+ "#The wire is divided into three segments AB, BC and CD. Taking A as origin the coordinates of the centroids of AB, BC and CD are (X1,Y1),(X2,Y2),(X3,Y3)\n",
+ "\n",
+ "X1=300.0\n",
+ "X2=600.0\n",
+ "X3=600.0-150*cos(theta)\n",
+ "Y1=0\n",
+ "Y2=100\n",
+ "Y3=200+150*sin(theta)\n",
+ "L=L1+L2+L3 #Total length,mm\n",
+ "\n",
+ "xc=(L1*X1+L2*X2+L3*X3)/L\n",
+ "\n",
+ "print \"xc=\",round(xc,2),\"mm\"\n",
+ "\n",
+ "\n",
+ "yc=(L1*Y1+L2*Y2+L3*Y3)/L\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"mm\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.2 page number 103"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 451.2 mm\n",
+ "yc= 54.07 mm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import cos,sin,pi\n",
+ "\n",
+ "#The composite figure is divided into three simple figures and taking A as origin coordinates of their centroids \n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "L1=400.0 #length of wire AB,mm\n",
+ "L2=150.0*pi #length of wire BC,mm\n",
+ "L3=250.0 #length of wire CD,mm\n",
+ "theta=30*pi/180\n",
+ "\n",
+ "#The wire is divided into three segments AB, BC and CD. Taking A as origin the coordinates of the centroids of AB, BC and CD are (X1,Y1),(X2,Y2),(X3,Y3)\n",
+ "X1=200.0\n",
+ "X2=475.0\n",
+ "X3=400+300.0+250*cos(theta)/2\n",
+ "\n",
+ "Y1=0\n",
+ "Y2=2*150/pi\n",
+ "Y3=125*sin(theta)\n",
+ "L=L1+L2+L3 #Total length,mm\n",
+ "\n",
+ "xc=(L1*X1+L2*X2+L3*X3)/L\n",
+ "\n",
+ "print \"xc=\",round(xc,2),\"mm\"\n",
+ "\n",
+ "\n",
+ "yc=(L1*Y1+L2*Y2+L3*Y3)/L\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"mm\"\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.3 page number 105"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 3,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 90.19 mm\n",
+ "yc= 198.5 mm\n",
+ "zc= 56.17 mm\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import cos,sin,pi\n",
+ "# The length and the centroid of portions AB, BC and CD \n",
+ "# portion AB is in x-z plane, BC in y-z plane and CD in x-y plane. AB and BC are semi circular in shape\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "L1=100.0*pi #length of wire AB,mm\n",
+ "L2=140.0*pi #length of wire BC,mm\n",
+ "L3=300.0 #length of wire CD,mm\n",
+ "theta=45*pi/180\n",
+ "\n",
+ "#The wire is divided into three segments AB, BC and CD. Taking A as origin the coordinates of the centroids of AB, BC and CD are (X1,Y1),(X2,Y2),(X3,Y3)\n",
+ "X1=100.0\n",
+ "X2=0\n",
+ "X3=300*sin(theta)\n",
+ "\n",
+ "Y1=0\n",
+ "Y2=140\n",
+ "Y3=280+300*cos(theta)\n",
+ "Z1=2*100/pi\n",
+ "Z2=2*140/pi\n",
+ "Z3=0\n",
+ "\n",
+ "L=L1+L2+L3 #Total length,mm\n",
+ "\n",
+ "xc=(L1*X1+L2*X2+L3*X3)/L\n",
+ "\n",
+ "print \"xc=\",round(xc,2),\"mm\"\n",
+ "\n",
+ "\n",
+ "yc=(L1*Y1+L2*Y2+L3*Y3)/L\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"mm\"\n",
+ "\n",
+ "zc=(L1*Z1+L2*Z2+L3*Z3)/L\n",
+ "\n",
+ "print \"zc=\",round(zc,2),\"mm\"\n",
+ "\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.4 page number 111"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 4,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 0.0\n",
+ "yc= 40.0 mm\n",
+ "Hence, centroid of T-section is on the symmetric axis at a distance 40 mm from the top\n"
+ ]
+ }
+ ],
+ "source": [
+ "#variable declaration\n",
+ "\n",
+ "A1=100.0*20.0 #Area of 1 ,mm^2\n",
+ "A2=20.0*100.0 #Area of 2,mm^2\n",
+ "\n",
+ "X1=0\n",
+ "X2=0\n",
+ "\n",
+ "Y1=10\n",
+ "Y2=70\n",
+ "\n",
+ "A=A1+A2\n",
+ "\n",
+ "xc=(A1*X1+A2*X2)/A\n",
+ "\n",
+ "print \"xc=\",round(xc,2)\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2)/A\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"mm\"\n",
+ "print \"Hence, centroid of T-section is on the symmetric axis at a distance 40 mm from the top\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.5 page number 111"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 5,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 36.62\n",
+ "yc= 61.62 mm\n",
+ "Thus, the centroid is at x = 36.62 mm and y = 61.62 mm \n"
+ ]
+ }
+ ],
+ "source": [
+ "#variable declaration\n",
+ "\n",
+ "A1=150.0*12.0 #Area of 1 ,mm^2\n",
+ "A2=(200.0-12.0)*12.0 #Area of 2,mm^2\n",
+ "\n",
+ "X1=75\n",
+ "X2=6\n",
+ "\n",
+ "Y1=6\n",
+ "Y2=12+(200-12)/2\n",
+ "\n",
+ "A=A1+A2\n",
+ "\n",
+ "xc=(A1*X1+A2*X2)/A\n",
+ "\n",
+ "print \"xc=\",round(xc,2)\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2)/A\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"mm\"\n",
+ "\n",
+ "print \"Thus, the centroid is at x = 36.62 mm and y = 61.62 mm \"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.6 page number 112"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 6,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "yc= 59.71 mm\n",
+ "Thus, the centroid is on the symmetric axis at a distance 59.71 mm from the bottom\n"
+ ]
+ }
+ ],
+ "source": [
+ "#variable declaration\n",
+ "\n",
+ "A1=100.0*20 #Area of 1 ,mm^2\n",
+ "A2=100.0*20.0 #Area of 2,mm^2\n",
+ "A3=150.0*30.0 #Area of 3,mm^2\n",
+ "\n",
+ "#Selecting the coordinate system, due to symmetry centroid must lie on y axis,\n",
+ "\n",
+ "X1=0\n",
+ "X2=0\n",
+ "\n",
+ "Y1=30+100+20/2\n",
+ "Y2=30+100/2\n",
+ "Y3=30/2\n",
+ "\n",
+ "A=A1+A2+A3\n",
+ "\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2+A3*Y3)/A\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"mm\"\n",
+ "\n",
+ "print \"Thus, the centroid is on the symmetric axis at a distance 59.71 mm from the bottom\"\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.7 page number 113"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 7,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 3.523 m\n",
+ "yc= 2.777 m\n"
+ ]
+ }
+ ],
+ "source": [
+ "# Note that it is convenient to take axis in such a way that the centroids of all simple figures are having positive coordinates. If coordinate of any simple figure comes out to be negative, one should be careful in assigning the sign of moment of area \n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "A1=2.0*6.0*1.0/2.0 #Area of 1,m^2\n",
+ "A2=2.0*7.5 #Area of 2,m^2\n",
+ "A3=3.0*5.0*1.0/2 #Area of 3,m^2\n",
+ "A4=1.0*4.0 #Area of 4,m^2\n",
+ "\n",
+ "#The composite figure can be conveniently divided into two triangles and two rectangle\n",
+ "\n",
+ "X1=2.0*2.0/3.0\n",
+ "X2=2.0+1.0\n",
+ "X3=2.0+2.0+(1.0*3.0/3.0)\n",
+ "X4=4.0+4.0/2.0\n",
+ "\n",
+ "Y1=6.0/3.0\n",
+ "Y2=7.5/2.0\n",
+ "Y3=1.0+5.0/3.0\n",
+ "Y4=1/2.0\n",
+ "\n",
+ "A=A1+A2+A3+A4\n",
+ "\n",
+ "xc=(A1*X1+A2*X2+A3*X3+A4*X4)/A\n",
+ "\n",
+ "print \"xc=\",round(xc,3),\"m\"\n",
+ "\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2+A3*Y3+A4*Y4)/A\n",
+ "\n",
+ "print \"yc=\",round(yc,3),\"m\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.8 page number 114\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 8,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 2.995 m\n",
+ "yc= 1.89 m\n"
+ ]
+ }
+ ],
+ "source": [
+ "\n",
+ "# The composite section is divided into three simple figures, a triangle, a rectangle and a semicircle\n",
+ "\n",
+ "from math import pi\n",
+ "#variable declaration\n",
+ "\n",
+ "A1=1.0*3.0*4.0/2.0 #Area of 1,m^2\n",
+ "A2=6.0*4.0 #Area of 2,m^2\n",
+ "A3=1.0*pi*pow(2,2)/2 #Area of 3,m^2\n",
+ "\n",
+ "#The coordinates of centroids of these three simple figures are:\n",
+ "\n",
+ "X1=6.0+3.0/3.0\n",
+ "X2=3.0\n",
+ "X3=-(4*2)/(3.0*pi)\n",
+ "\n",
+ "Y1=4.0/3.0\n",
+ "Y2=2.0\n",
+ "Y3=2.0\n",
+ "\n",
+ "A=A1+A2+A3\n",
+ "\n",
+ "xc=(A1*X1+A2*X2+A3*X3)/A\n",
+ "\n",
+ "print \"xc=\",round(xc,4),\"m\"\n",
+ "\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2+A3*Y3)/A\n",
+ "\n",
+ "print \"yc=\",round(yc,3),\"m\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.9 page number 115"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 9,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 145.42 m\n",
+ "yc= 90.39 m\n"
+ ]
+ }
+ ],
+ "source": [
+ "#The composite area is equal to a rectangle of size 160 × 280 mm plus a triangle of size 280 mm base width and 40 mm height and minus areas of six holes. In this case also the can be used for locating centroid by treating area of holes as negative. The area of simple figures and their centroids are\n",
+ "\n",
+ "from math import pi\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "Ar=160.0*280.0 #Area of rectangle,mm^2\n",
+ "At=280.0*40.0/2.0 #Area of triangle,mm^2\n",
+ "d=21.5 #diameter of hole,mm \n",
+ "Ah=-pi*pow(d,2)/4 #Area of hole,mm^2\n",
+ "\n",
+ "A=Ar+At+Ah*6\n",
+ "\n",
+ "\n",
+ "Xr=140.0\n",
+ "Xt=560/3.0\n",
+ "Xh1=70.0\n",
+ "Xh2=140.0\n",
+ "Xh3=210.0\n",
+ "Xh4=70.0\n",
+ "Xh5=140.0\n",
+ "Xh6=210.0\n",
+ "\n",
+ "Yr=80.0\n",
+ "Yt=160.0+40.0/3.0\n",
+ "Yh1=50.0\n",
+ "Yh2=50.0\n",
+ "Yh3=50.0\n",
+ "Yh4=120.0\n",
+ "Yh5=130.0\n",
+ "Yh6=140.0\n",
+ "\n",
+ "xc=(Ar*Xr+At*Xt+Ah*(Xh1+Xh2+Xh3+Xh4+Xh5+Xh6))/A\n",
+ "\n",
+ "print \"xc=\",round(xc,2),\"m\"\n",
+ "\n",
+ "\n",
+ "yc=(Ar*Yr+At*Yt+Ah*(Yh1+Yh2+Yh3+Yh4+Yh5+Yh6))/A\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"m\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.10 page number 116"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 10,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 90.48 mm\n",
+ "yc= 67.86 mm\n"
+ ]
+ }
+ ],
+ "source": [
+ "# If xc and yc are the coordinates of the centre of the circle, centroid also must have the coordinates xc and yc as per the condition laid down in the problem. The shaded area may be considered as a rectangle of size 200 mm × 150 mm minus a triangle of sides 100 mm × 75 mm and a circle of diameter 100 mm.\n",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "Ap=200.0*150.0 #Area of plate,mm^2\n",
+ "At=100.0*75.0/2.0 #Area of triangle,mm^2\n",
+ "Ah=pi*pow(100,2)/4.0 #Area of hole ,mm^2\n",
+ "\n",
+ "A=Ap-At-Ah\n",
+ "\n",
+ "\n",
+ "X1=100.0\n",
+ "X2=200.0-100.0/3.0\n",
+ "#X3=Xc\n",
+ "\n",
+ "Y1=75.0\n",
+ "Y2=150.0-25.0\n",
+ "#Y3=Yc\n",
+ "\n",
+ "A=Ap-At-Ah\n",
+ "\n",
+ "xc=(Ap*X1-At*X2)/(Ah+A)\n",
+ "\n",
+ "print \"xc=\",round(xc,2),\"mm\"\n",
+ "\n",
+ "yc=(Ap*Y1-At*Y2)/(Ah+A)\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"mm\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.11 page number 118"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 11,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "xc= 326.4 m\n",
+ "yc= 219.12 m\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import pi\n",
+ "\n",
+ "#variable declaration\n",
+ "X=40.0\n",
+ "A1=14.0*12.0*pow(X,2) #Area of rectangle,mm^2\n",
+ "A2=6.0*4.0*pow(X,2)/2.0 #Area of triangle,mm^2\n",
+ "A3=-4*4*pow(X,2) #Area of removed subtracted,mm^2\n",
+ "A4=-pi*pow(4*X,2)/2.0 #Area of semicircle to be subtracted,mm^2\n",
+ "A5=-pi*pow(4*X,2)/4.0 #Area of quarter of circle to be subtracted,mm^2\n",
+ "\n",
+ "X1=7.0*X\n",
+ "X2=14*X+2*X\n",
+ "X3=2*X\n",
+ "X4=6.0*X\n",
+ "X5=14.0*X-(16*X/(3*pi))\n",
+ "\n",
+ "Y1=6.0*X\n",
+ "Y2=4.0*X/3.0\n",
+ "Y3=8.0*X+2.0*X\n",
+ "Y4=(16.0*X)/(3*pi)\n",
+ "Y5=12*X-4*(4*X/(3*pi))\n",
+ "\n",
+ "A=A1+A2+A3+A4+A5\n",
+ "\n",
+ "xc=(A1*X1+A2*X2+A3*X3+A4*X4+A5*X5)/A\n",
+ "\n",
+ "print \"xc=\",round(xc,2),\"m\"\n",
+ "\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2+A3*Y3+A4*Y4+A5*Y5)/A\n",
+ "\n",
+ "print \"yc=\",round(yc,2),\"m\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.12 page number 130"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 12,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Ixx= 6372441.9 mm^4\n",
+ "Iyy= 2824166.0 mm^4\n",
+ "kxx= 46.88 mm\n",
+ "kyy= 31.21 mm\n"
+ ]
+ }
+ ],
+ "source": [
+ "#The given composite section can be divided into two rectangles \n",
+ "\n",
+ "from math import pi,sqrt\n",
+ "#variable declaration\n",
+ "\n",
+ "\n",
+ "A1=150.0*10.0 #Area of 1,mm^2\n",
+ "A2=140.0*10.0 #Area of 2,mm^2\n",
+ "A=A1+A2 #Total area,mm^2 \n",
+ "#Due to symmetry, centroid lies on the symmetric axis y-y. The distance of the centroid from the top most fibre is given by:\n",
+ "\n",
+ "Y1=5.0\n",
+ "Y2=10.0+70.0\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2)/A\n",
+ "\n",
+ "#Referring to the centroidal axis x-x and y-y, the centroid of A1 is g1 (0.0, yc-5) and that of A2 is g2 (0.0, 80-yc)\n",
+ "\n",
+ "#Moment of inertia of the section about x-x axis Ixx = moment of inertia of A1 about x-x axis + moment of inertia of A2 about x-x axis.\n",
+ "\n",
+ "\n",
+ "Ixx=(150*pow(10,3)/12)+(A1*pow((yc-5),2))+(10*pow(140,3)/12)+(A2*pow((80-yc),2))\n",
+ "\n",
+ "print \"Ixx=\",round(Ixx,1),\"mm^4\"\n",
+ "\n",
+ "Iyy=(10*pow(150,3)/12)+(140*pow(10,3)/12)\n",
+ "\n",
+ "print \"Iyy=\",round(Iyy,1),\"mm^4\"\n",
+ "\n",
+ "#Hence, the moment of inertia of the section about an axis passing through the centroid and parallel to the top most fibre is Ixxmm^4 and moment of inertia of the section about the axis of symmetry is Iyy mm^4. \n",
+ "#The radius of gyration is given by\n",
+ "\n",
+ "kxx=sqrt(Ixx/A)\n",
+ "print\"kxx=\",round(kxx,2),\"mm\"\n",
+ "\n",
+ "kyy=sqrt(Iyy/A)\n",
+ "print\"kyy=\",round(kyy,2),\"mm\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.13 page number 131"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 13,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Ixx= 3411298.7 mm^4\n",
+ "Iyy= 1208657.7 mm^4\n",
+ "Izz= 4619956.4 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "#The given composite section can be divided into two rectangles \n",
+ "\n",
+ " \n",
+ "#variable declaration\n",
+ "\n",
+ "\n",
+ "A1=125.0*10.0 #Area of 1,mm^2\n",
+ "A2=75.0*10.0 #Area of 2,mm^2\n",
+ "A=A1+A2 #Total area,mm^2 \n",
+ "\n",
+ "#First, the centroid of the given section is to be located. Two reference axis (1)–(1) and (2)–(2) \n",
+ "\n",
+ "#The distance of centroid from the axis (1)–(1)\n",
+ "\n",
+ "X1=5.0\n",
+ "X2=10.0+75.0/2\n",
+ "\n",
+ "xc=(A1*X1+A2*X2)/A\n",
+ "\n",
+ "#Similarly, the distance of the centroid from the axis (2)–(2)\n",
+ "\n",
+ "Y1=125.0/2\n",
+ "Y2=5.0\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2)/A\n",
+ "\n",
+ "#With respect to the centroidal axis x-x and y-y, the centroid of A1 is g1 (xc-5, (85/2)-xc) and that of A2 is g2 ((135/2)-yc, yc-5). \n",
+ "Ixx=(10*pow(125,3)/12)+(A1*pow(21.56,2))+(75.0*pow(10.0,3.0)/12)+(A2*pow((39.94),2))\n",
+ "\n",
+ "print \"Ixx=\",round(Ixx,1),\"mm^4\"\n",
+ "\n",
+ "Iyy=(125*pow(10,3)/12)+(A1*pow(15.94,2))+(10*pow(75,3)/12)+(A2*pow(26.56,2)) \n",
+ "\n",
+ "print \"Iyy=\",round(Iyy,1),\"mm^4\"\n",
+ "\n",
+ "#Izz=Polar moment of inertia\n",
+ "\n",
+ "Izz=Ixx+Iyy\n",
+ "\n",
+ "print \"Izz=\",round(Izz,1),\"mm^4\"\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# eample 4.14 page number 132"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 14,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Ixx= 59269202.1 mm^4\n",
+ "Iyy= 12005814.8 mm^4\n",
+ "Izz= 71275016.9 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "#The given composite section can be divided into two rectangles \n",
+ "\n",
+ " \n",
+ "#variable declaration\n",
+ "\n",
+ "\n",
+ "A1=200.0*9.0 #Area of 1,mm^2\n",
+ "A2=(250.0-9*2)*6.7 #Area of 2,mm^2\n",
+ "A3=200.0*9.0 #Area of 3,mm^2 \n",
+ "A=A1+A2+A3 #Total area,mm^2 \n",
+ "\n",
+ "#The section is symmetrical about both x-x and y-y axis. \n",
+ "X1=0\n",
+ "X2=0\n",
+ "X3=0\n",
+ "\n",
+ "xc=(A1*X1+A2*X2+A3*X3)/A\n",
+ "\n",
+ "\n",
+ "Y1=245.5\n",
+ "Y2=125.0\n",
+ "Y3=4.5\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2+A3*Y3)/A\n",
+ "\n",
+ "#Therefore, its centroid will coincide with the centroid of rectangle A2. With respect to the centroidal axis x-x and y-y, the centroid of rectangle A1 is g1 (0.0, 120.5), that of A2 is g2 (0.0, 0.0) and that of A3 is g3 (0.0, 120.5).\n",
+ "\n",
+ "Ixx=(200.0*pow(9,3)/12)+(A1*pow(yc-4.5,2))+(6.7*pow(232,3.0)/12)+0+(200*pow(9,3)/12)+(A3*pow((yc-4.5),2))\n",
+ "\n",
+ "print \"Ixx=\",round(Ixx,1),\"mm^4\"\n",
+ "\n",
+ "Iyy=(9*pow(200,3)/12)+(232*pow(6.7,3)/12)+(9*pow(200,3)/12) \n",
+ "\n",
+ "print \"Iyy=\",round(Iyy,1),\"mm^4\"\n",
+ "\n",
+ "#Izz=Polar moment of inertia\n",
+ "\n",
+ "Izz=Ixx+Iyy\n",
+ "\n",
+ "#misprint in book\n",
+ "\n",
+ "print \"Izz=\",round(Izz,1),\"mm^4\"\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example4.15 page number 133"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 15,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Ixx= 135903229.0 mm^4\n",
+ "Iyy= 5276363.1 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import sqrt\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "\n",
+ "A1=100.0*13.5 #Area of 1,mm^2\n",
+ "A2=(400.0-27.0)*8.1 #Area of 2,mm^2\n",
+ "A3=100.0*13.5 #Area of 3,mm^2 \n",
+ "\n",
+ "A=A1+A2+A3 #Total area,mm^2 \n",
+ "\n",
+ "#The given section is symmetric about horizontal axis passing through the centroid g2 of the rectangle A2.\n",
+ "\n",
+ "X1=50.0\n",
+ "X2=8.1/2.0\n",
+ "X3=50.0\n",
+ "\n",
+ "xc=(A1*X1+A2*X2+A3*X3)/A\n",
+ "\n",
+ "Y1=386.5+13.5/2.0\n",
+ "Y2=200.0\n",
+ "Y3=13.5/2\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2+A3*Y3)/A\n",
+ "\n",
+ "#With reference to the centroidal axis x-x and y-y\n",
+ "\n",
+ "Ixx=(100.0*pow(13.5,3)/12.0)+(A1*pow((200-(13.5/2)),2))+(8.1*pow(373,3.0)/12.0)+0+(100*pow(13.5,3)/12.0)+(A3*pow((200-(13.5/2)),2))\n",
+ "print \"Ixx=\",round(Ixx,1),\"mm^4\"\n",
+ "\n",
+ "Iyy=(13.5*pow(100.0,3)/12.0)+(A1*pow((50-xc),2))+(373.0*pow(8.1,3.0)/12.0)+A2*pow(21.68,2)+(13.5*pow(100,3)/12.0)+(A3*pow((50-xc),2))\n",
+ "\n",
+ "print \"Iyy=\",round(Iyy,1),\"mm^4\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.16 page number 134\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 16,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Polar moment of Inertia= 32109472.0 mm^4\n",
+ "kxx= 90.3 mm\n",
+ "kyy= 23.09 mm\n"
+ ]
+ }
+ ],
+ "source": [
+ "# The section is divided into three rectangles A1, A2 and A3\n",
+ "\n",
+ " \n",
+ "#variable declaration\n",
+ "\n",
+ "\n",
+ "A1=80.0*12.0 #Area of 1,mm^2\n",
+ "A2=(150.0-22.0)*12.0 #Area of 2,mm^2\n",
+ "A3=120.0*10.0 #Area of 3,mm^2 \n",
+ "\n",
+ "A=A1+A2+A3 #Total area,mm^2 \n",
+ "\n",
+ "#Due to symmetry, centroid lies on axis y-y. The bottom fibre (1)–(1) is chosen as reference axis to locate the centroid\n",
+ "\n",
+ "Y1=150-6\n",
+ "Y2=(128/2) +10\n",
+ "Y3=5\n",
+ "\n",
+ "yc=(A1*X1+A2*X2+A3*X3)/A\n",
+ "\n",
+ "X1=60.0\n",
+ "X2=60.0\n",
+ "X3=60.0\n",
+ "\n",
+ "xc=(A1*Y1+A2*Y2+A3*Y3)/A\n",
+ "\n",
+ "#With reference to the centroidal axis x-x and y-y, the centroid of the rectangles A1 is g1 (0.0, 150-6-yc), that of A2 is g2 (0.0, 75-yc) and that of A3 is g3 (0.0, yc-5 ).\n",
+ "\n",
+ "Iyy=(12*(pow(80,3))/12)+(128*(pow(12,3))/12)+(10*(pow(120,3))/12)\n",
+ "\n",
+ "Ixx=(80.0*pow(12.0,3)/12.0)+(A1*pow((150-6-yc),2))+(12*pow(128,3.0)/12.0)+(A2*pow((75-yc),2))+(120*pow(10,3)/12.0)+(A3*pow((150-10-6-yc),2))\n",
+ "\n",
+ "\n",
+ "\n",
+ "PolarmomentofInertia=Ixx+Iyy\n",
+ "\n",
+ "print \"Polar moment of Inertia=\",round(PolarmomentofInertia),\"mm^4\"\n",
+ "\n",
+ "kxx=sqrt(Ixx/A)\n",
+ "print \"kxx=\",round(kxx,2),\"mm\"\n",
+ "\n",
+ "\n",
+ "kyy=sqrt(Iyy/A)\n",
+ "print \"kyy=\",round(kyy,2),\"mm\"\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example4.17 page number 135"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 17,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Ixx= 31543827.2 mm^4\n",
+ "Iyy= 19745121.6 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import sqrt\n",
+ "\n",
+ "#The given composite section may be divided into simple rectangles and triangle\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "\n",
+ "A1=100.0*30.0 #Area of 1,mm^2\n",
+ "A2=100.0*25.0 #Area of 2,mm^2\n",
+ "A3=200.0*20.0 #Area of 3,mm^2 \n",
+ "A4=87.5*20.0/2.0 #Area of 4,mm^2\n",
+ "A5=87.5*20.0/2.0 #Area of 5,mm^2\n",
+ "\n",
+ "A=A1+A2+A3+A4+A5 #Total area,mm^2 \n",
+ "\n",
+ "#Due to symmetry, centroid lies on the axis y-y. A reference axis (1)–(1) is choosen as shown in the figure. The distance of the centroidal axis from (1)–(1)\n",
+ "\n",
+ "X1=100.0\n",
+ "X2=100.0\n",
+ "X3=100.0\n",
+ "X4=2.0*87.5/3.0\n",
+ "X5=200-X4\n",
+ "xc=(A1*X1+A2*X2+A3*X3+A4*X4+A5*X5)/A\n",
+ "\n",
+ "Y1=135.0\n",
+ "Y2=70.0\n",
+ "Y3=10.0\n",
+ "Y4=(20.0/3.0)+20.0\n",
+ "Y5=Y4\n",
+ "\n",
+ "yc=(A1*Y1+A2*Y2+A3*Y3+A4*Y4+A5*Y5)/A\n",
+ "\n",
+ "#With reference to the centroidal axis x-x and y-y, the centroid of the rectangle A1 is g1 (0.0,135.0-yc), that of A2 is g2(0.0,70.00-yc), that of A3 is g3 (0.0, yc-10.0), the centroid of triangle A4 is g4 (41.66,yc-20.0-(20.0/3.0) ) and that of A5 is g5 (41.66,yc-20.0-(20.0/3.0)).\n",
+ "\n",
+ "\n",
+ "Ixx=(100.0*pow(30,3)/12.0)+(A1*pow((135.0-yc),2))+(25.0*pow(100,3.0)/12.0)+(A2*pow((70.0-yc),2))+(200*pow(20,3)/12.0)+(A3*pow((yc-10.0),2))+((87.5*pow(20,3)/36.0)+(A4*pow((yc-20.0-(20.0/3.0)),2)))*2\n",
+ "\n",
+ "print \"Ixx=\",round(Ixx,1),\"mm^4\"\n",
+ "\n",
+ "Iyy=(30.0*pow(100,3)/12.0)+(100.0*pow(25,3.0)/12.0)+(20*pow(200,3)/12.0)+((20.0*pow(87.5,3)/36.0)+(A4*pow((41.66),2)))*2\n",
+ "\n",
+ "print \"Iyy=\",round(Iyy,1),\"mm^4\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example4.18 page number137"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 18,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "IAB= 806093331.0 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "#In this problem, it is required to find out the moment of inertia of the section about an axis AB. So there is no need to find out the position of the centroid. \n",
+ "#The given section is split up into simple rectangles\n",
+ "#Moment of inertia about AB = Sum of moments of inertia of the rectangle about AB\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "A1=400*20.0\n",
+ "A2=100*10\n",
+ "A3=10*380.0\n",
+ "A4=100*10.0\n",
+ "\n",
+ "IAB=(400.0*pow(20,3)/12)+(A1*pow(10,2))+((100*pow(10,3)/12)+(A2*pow(25,2)))*2+((10*pow(380,3)/12)+(A3*pow(220,2)))*2+((100*pow(10,3)/12)+(A4*pow(415,2)))*2\n",
+ "\n",
+ "print \"IAB=\",round(IAB),\"mm^4\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example4.19 page number 137"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 19,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Ixx= 50399393.9 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "# The built-up section is divided into six simple rectangles\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "\n",
+ "A1=250.0*10.0 #Area of 1,mm^2\n",
+ "A2=40.0*10.0 #Area of 2,mm^2\n",
+ "\n",
+ "A=A1*2+A2*4 #Total area,mm^2 \n",
+ "\n",
+ "\n",
+ "Y1=5.0\n",
+ "Y2=30.0\n",
+ "Y3=15.0\n",
+ "Y4=255.0\n",
+ "Y5=135.0\n",
+ "\n",
+ "yc=(A1*Y1+2*A2*Y2+A2*Y3+A2*Y4+A1*Y5)/A\n",
+ "\n",
+ "#Now, Moment of inertia about the centroidalaxis=Sum of the moment of inertia of the individual rectangles\n",
+ "\n",
+ "Ixx=(250.0*pow(10,3)/12.0)+(A1*pow((yc-5),2))+((10.0*pow(40,3.0)/12.0)+(A2*pow((yc-30.0),2)))*2+(40*pow(10,3)/12.0)+(A2*pow((yc-15.0),2))+(10.0*pow(250.0,3.0)/12.0)+(A1*pow((yc-135.0),2))+(40.0*pow(10.0,3)/12)+(A2*pow((yc-255),2))\n",
+ "\n",
+ "print \"Ixx=\",round(Ixx,1),\"mm^4\"\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example4.20 page number 138"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 20,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "145.394736842\n",
+ "Ixx= 752680131.6 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Each angle is divided into two rectangles \n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "A1=600.0*15.0 #Area of 1,mm^2\n",
+ "A2=140.0*10.0 #Area of 2,mm^2\n",
+ "A3=150.0*10.0\n",
+ "A4=400.0*20.0\n",
+ "A=A1+A2*2+A3*2+A4 #Total area,mm^2 \n",
+ "\n",
+ "#The distance of the centroidal axis from the bottom fibres of section \n",
+ "\n",
+ "Y1=320.0\n",
+ "Y2=100.0\n",
+ "Y3=25.0\n",
+ "Y4=10.0\n",
+ "\n",
+ "yc=(A1*Y1+2*A2*Y2+A3*Y3*2+A4*Y4)/A\n",
+ "print yc\n",
+ "#Now, Moment of inertia about the centroidalaxis=Sum of the moment of inertia of the individual rectangles\n",
+ "\n",
+ "Ixx=(15.0*pow(600,3)/12.0)+(A1*pow((yc-320),2))+((10.0*pow(140,3.0)/12.0)+(A2*pow((yc-100.0),2)))*2+((150*pow(10,3)/12.0)+(A3*pow((yc-15.0),2)))*2+(400.0*pow(20.0,3.0)/12.0)+(A4*pow((yc-10.0),2))\n",
+ "\n",
+ "\n",
+ "print \"Ixx=\",round(Ixx,1),\"mm^4\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example4.21 page number 139"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 21,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Ixx= 36000000.0 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "\n",
+ "from math import asin,sin,cos,pi\n",
+ "\n",
+ "#The rectangle is divided into four triangles\n",
+ "#The lines AE and FC are parallel to x-axis\n",
+ " \n",
+ "#variable declaration\n",
+ "\n",
+ "theta=asin(4.0/5.0)\n",
+ "\n",
+ "AB=100.0\n",
+ "BK=AB*sin((90*pi/180)-theta)\n",
+ "ND=BK\n",
+ "FD=60.0/sin(theta)\n",
+ "AF=150.0-FD\n",
+ "FL=ME=75.0*sin(theta)\n",
+ "AE=AB/cos((90*pi/180)-theta)\n",
+ "FC=AE\n",
+ "A=125.0*60.0/2.0\n",
+ "\n",
+ "#Moment of inertia of the section about axis x-x=Sum of the momentsof inertia of individual triangular areasabout axis\n",
+ "\n",
+ "Ixx=(125*pow(60,3)/36)+(A*pow((ND*4.0/3.0),2))+(125*pow(60,3)/36)+(A*pow((ND*2.0/3.0),2))+(125*pow(60,3)/36)+(A*pow((ND*1.0/3.0),2))+(125*pow(60,3)/36)+(A*pow((ND*1.0/3.0),2))\n",
+ "\n",
+ "print \"Ixx=\",round(Ixx),\"mm^4\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.22, page number 140"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 22,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "IAB= 4292979.0 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import pi\n",
+ "\n",
+ "#The section is divided into a triangle PQR, a semicircle PSQ having base on axis AB and a circle having its centre on axis AB\n",
+ "\n",
+ "#variable declaration\n",
+ "#Now,Moment of inertia of the section about axis AB\n",
+ "IAB=(80*pow(80,3)/12)+(pi*pow(80,4)/128)-(pi*pow(40,4)/64)\n",
+ "\n",
+ "print \"IAB=\",round(IAB),\"mm^4\"\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example4.23 page number141"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 23,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "106.435694487 28.4724404943\n",
+ "Ixx= 686943.0 mm^4\n",
+ "Iyy= 17146488.0 mm^4\n"
+ ]
+ }
+ ],
+ "source": [
+ "from math import pi\n",
+ "\n",
+ "#The section is divided into three simple figures viz., a triangle ABC, a rectangle ACDE and a semicircle. \n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "r=20.0 #radius of semicircle\n",
+ "A1=80.0*20.0/2 #Area of triangle ABC \n",
+ "A3=40.0*80.0 #Area of rectangle ACDE \n",
+ "A4=pi*pow(r,2)/2 #Area of semicircle\n",
+ "At1=30.0*20.0/2.0\n",
+ "At2=50.0*20.0/2.0\n",
+ "A=A1+A3-A4 #Total area\n",
+ "\n",
+ "X1=2.0*30.0/3.0\n",
+ "X2=50.0*30.0/3.0\n",
+ "X3=40.0\n",
+ "X4=40.0\n",
+ "\n",
+ "xc=(At1*X1+At2*X2+A3*X3-A4*X4)/A\n",
+ "#mistake in book\n",
+ "\n",
+ "Y1=(20.0/3.0)+40.0\n",
+ "Y3=20.0\n",
+ "Y4=(4.0*20.0)/(3.0*pi)\n",
+ "\n",
+ "yc=(A1*Y1+A3*Y3-A4*Y4)/A\n",
+ "print xc,yc\n",
+ "#\n",
+ "#Moment of inertia of the section about axis x-x=Sum of the momentsof inertia of individual triangular areasabout axis\n",
+ "\n",
+ "Ixx=(80.0*pow(20.0,3)/36) +A1*pow((60.0-(2*20.0/3.0)-yc),2)+(80*pow(40,3)/12)+(A3*pow((yc-20.0),2))-((0.0068598*pow(20,4))+(A4*pow((yc-Y4),2)))\n",
+ "\n",
+ "print\"Ixx=\",round(Ixx),\"mm^4\"\n",
+ "\n",
+ "\n",
+ "Iyy=(20.0*pow(30.0,3)/36) +At1*pow((xc-(2*30.0/3.0)),2)+(20*pow(50,3)/36)+(At2*pow((xc-(30.0+(50/3))),2))+((40*pow(80,3)/12)+(A3*pow((xc-40),2)))-((pi*pow(40,4))/(2*64))-(A4*pow((40-xc),2))\n",
+ "\n",
+ "print\"Iyy=\",round(Iyy),\"mm^4\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# example 4.27 page number 150"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 24,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "25000.0 5625.0 235.619449019 7889.38055098\n",
+ "xc= 0.411 m\n",
+ "yc= 0.329 m\n",
+ "zc= 0.221 m\n"
+ ]
+ }
+ ],
+ "source": [
+ "#A concrete block of size 0.60 m × 0.75 m × 0.5 m is cast with a hole of diameter 0.2 m and depth 0.3 m\n",
+ "#The hole is completely filled with steel balls weighing 2500 N. Locate the centre of gravity of the body.\n",
+ "\n",
+ "from math import pi\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "W=25000.0 # weight of concrete=25000, N/m^3\n",
+ "W1=0.6*0.75*0.5*W #Weight of solid concrete block\n",
+ "W2=pi*pow(0.2,2)*0.3*W/4 #Weight of concrete (W2) removed for making hole:\n",
+ "W3=2500\n",
+ "\n",
+ "#Taking origin as shown in the figure, the centre of gravity of solid block is (0.375, 0.3, 0.25) and that of hollow portion is (0.5, 0.4, 0.15)\n",
+ "\n",
+ "X1=0.375\n",
+ "X2=0.5\n",
+ "X3=0.5\n",
+ "\n",
+ "Y1=0.3\n",
+ "Y2=0.4\n",
+ "Y3=0.4\n",
+ "\n",
+ "Z1=0.25\n",
+ "Z2=0.15\n",
+ "Z3=0.15\n",
+ "\n",
+ "Wt=W3+W1-W2\n",
+ "print W,W1,W2,Wt\n",
+ "xc=(W1*X1-W2*X2+W3*X3)/Wt\n",
+ "\n",
+ "yc=(W1*Y1-W2*Y2+W3*Y3)/Wt\n",
+ "\n",
+ "zc=(W1*Z1-W2*Z2+W3*Z3)/Wt\n",
+ "\n",
+ "print\"xc=\",round(xc,3),\"m\"\n",
+ "print\"yc=\",round(yc,3),\"m\"\n",
+ "print\"zc=\",round(zc,3),\"m\"\n"
+ ]
+ }
+ ],
+ "metadata": {
+ "kernelspec": {
+ "display_name": "Python [Root]",
+ "language": "python",
+ "name": "Python [Root]"
+ },
+ "language_info": {
+ "codemirror_mode": {
+ "name": "ipython",
+ "version": 2
+ },
+ "file_extension": ".py",
+ "mimetype": "text/x-python",
+ "name": "python",
+ "nbconvert_exporter": "python",
+ "pygments_lexer": "ipython2",
+ "version": "2.7.12"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}