diff options
author | FOSSEE Git User | 2017-08-22 19:33:31 +0530 |
---|---|---|
committer | FOSSEE Git User | 2017-08-22 19:33:31 +0530 |
commit | dce2a9bed55eda4718cb590b90783652b6847c3b (patch) | |
tree | 76e74a69fd3cff9b9412b16da5a244b281629cf3 /Engineering_Mechanics_Statics_and_Dynamics_by_Hibbeler_and_Gupta/Chapter14KineticsofaParticleWorkandEnergy.ipynb | |
parent | 16d89ed8065e3385dfda78f9516fa8934431fdd6 (diff) | |
parent | d34b2ae7e5e6051f7c87531ebc73b154b082d05b (diff) | |
download | Python-Textbook-Companions-master.tar.gz Python-Textbook-Companions-master.tar.bz2 Python-Textbook-Companions-master.zip |
Diffstat (limited to 'Engineering_Mechanics_Statics_and_Dynamics_by_Hibbeler_and_Gupta/Chapter14KineticsofaParticleWorkandEnergy.ipynb')
-rw-r--r-- | Engineering_Mechanics_Statics_and_Dynamics_by_Hibbeler_and_Gupta/Chapter14KineticsofaParticleWorkandEnergy.ipynb | 428 |
1 files changed, 428 insertions, 0 deletions
diff --git a/Engineering_Mechanics_Statics_and_Dynamics_by_Hibbeler_and_Gupta/Chapter14KineticsofaParticleWorkandEnergy.ipynb b/Engineering_Mechanics_Statics_and_Dynamics_by_Hibbeler_and_Gupta/Chapter14KineticsofaParticleWorkandEnergy.ipynb new file mode 100644 index 00000000..2fcc32fb --- /dev/null +++ b/Engineering_Mechanics_Statics_and_Dynamics_by_Hibbeler_and_Gupta/Chapter14KineticsofaParticleWorkandEnergy.ipynb @@ -0,0 +1,428 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 14 Kinetics of a Particle : Work and Energy" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.1 Page No 569" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "UT = 504.7 J\n" + ] + } + ], + "source": [ + "# Ex 14.1\n", + "import math\n", + "from __future__ import division\n", + "\n", + "# Variable Declaration\n", + "P = 400 #[Newtons]\n", + "s = 2 #[meters]\n", + "\n", + "# Calculation\n", + "# Horizontal Force P\n", + "UP = round(P*s*math.cos(math.pi*30/180),1) #[Joules]\n", + "# Spring force Fs\n", + "Us = round(-((1/2)*30*2.5**(2)-(1/2)*30*0.5**(2)),1) #[Joules]\n", + "# Weight W\n", + "UW = round(-98.1*(2*math.sin(math.pi*30/180)),1) #[Joules]\n", + "# Total Work\n", + "UT = UP+Us+UW #[Joules]\n", + "\n", + "# Result\n", + "print\"UT = \",(UT),\"J\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.2 Page No 574" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "s = 4.0 m\n" + ] + } + ], + "source": [ + "# Ex 14.2\n", + "from __future__ import division\n", + "import math\n", + "\n", + "# Variable Declaration\n", + "uk = 0.5\n", + "m = 20 #[kilo Newton]\n", + "\n", + "# Calculation\n", + "# Using +ΣFn = 0\n", + "NA = round(m*math.cos(math.pi*10/180),2) #[kilo Newtons]\n", + "FA = uk*NA #[kilo Newtons]\n", + "# Principle of Work and Energys\n", + "s = round((-(1/2)*(m/9.81)*(5**(2)))/(m*math.sin(math.pi*10/180)-9.85),1) #[meters]\n", + " \n", + "# Result\n", + "print\"s = \",(s),\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.3 Page No 575" + ] + }, + { + "cell_type": "code", + "execution_count": 17, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "v = 5.47 m/s\n", + "t = 1.79 s\n" + ] + } + ], + "source": [ + "# Ex 14.3\n", + "from __future__ import division\n", + "from scipy import integrate\n", + "\n", + "# Calculation\n", + "v = round((2.78*3+0.8*3**(3))**(1/2),2) #[meters per second]\n", + "x = lambda s : 1/((2.78*s+0.8*s**(3))**(1/2))\n", + "t = round(integrate.quad(x,0,3)[0],2) #[seconds]\n", + " \n", + "# Result\n", + "print\"v = \",(v),\"m/s\"\n", + "print\"t = \",(t),\"s\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.4 Page No 576" + ] + }, + { + "cell_type": "code", + "execution_count": 21, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "h = 0.963 m\n" + ] + } + ], + "source": [ + "# Ex 14.4\n", + "from __future__ import division\n", + "\n", + "# Calculation\n", + "# Using Principle of Work and Energy\n", + "h = round(((-(1/2)*200*(0.6**(2))+(1/2)*200*(0.7**(2)))/(19.62))+0.3,3) #[meters]\n", + "\n", + "# Result\n", + "print\"h = \",(h),\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.5 Page No 577" + ] + }, + { + "cell_type": "code", + "execution_count": 24, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thetamax = 42.7 degrees\n" + ] + } + ], + "source": [ + "# Ex 14.5\n", + "import math\n", + "\n", + "# Calculation\n", + "thetamax = round(math.degrees(math.acos((9.81+1)/(4.905+9.81))),1) #[Degrees]\n", + "\n", + "# Result\n", + "print\"thetamax = \",(thetamax),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.6 Page No 578" + ] + }, + { + "cell_type": "code", + "execution_count": 29, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "delta_sB = 0.883 m\n" + ] + } + ], + "source": [ + "# EX 14.6\n", + "from __future__ import division\n", + "\n", + "# Calculation\n", + "vA = -4*2 #[meters per second]\n", + "# Substituting delta_sA = -4*delta_sB\n", + "delta_sB = round(((1/2)*10*(vA**(2))+(1/2)*100*(2**(2)))/(-4*98.1+981),3) #[meters]\n", + "\n", + "# Result\n", + "print\"delta_sB = \",(delta_sB),\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.8 Page No 586" + ] + }, + { + "cell_type": "code", + "execution_count": 39, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "P = 162.0 kW\n" + ] + } + ], + "source": [ + "# Ex 14.8\n", + "import math\n", + "from __future__ import division\n", + "\n", + "# Variable Declaration\n", + "uk = 0.35\n", + "\n", + "# Calculation\n", + "# Using +ΣFy(upward) = 0\n", + "NC = 19.62 #[kilo Newtons]\n", + "FC = uk*NC #[kilo Newtons]\n", + "v = round(math.sqrt(((1/2)*2000*(25**(2))-6.867*(10**(3))*10)/((1/2)*2000)),2) #[meters per second]\n", + "P = round(FC*v,1) #[kilo Watts]\n", + "\n", + "# Result\n", + "print\"P = \",(P),\"kW\" # Correction in the answer" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.9 Page No 595" + ] + }, + { + "cell_type": "code", + "execution_count": 44, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "T = 148.7 kN\n" + ] + } + ], + "source": [ + "# Ex 14.9\n", + "import math\n", + "\n", + "# Calculation\n", + "# Using Principle of Conservation of Energy\n", + "vB = round(math.sqrt((8000*9.81*20*math.cos(math.pi*15/180)-8000*9.81*20*math.cos(math.pi*60/180))/((1/2)*8000)),1) #[meters per second]\n", + "# Using ΣFn = m*an\n", + "T = 8000*9.81*math.cos(math.pi*15/180)+8000*(13.5**(2))/20 #[Newtons]\n", + "\n", + "# Result\n", + "print\"T = \",round((T/1000),1),\"kN\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.10 Page No 596" + ] + }, + { + "cell_type": "code", + "execution_count": 47, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "sA = 0.331 m\n" + ] + } + ], + "source": [ + "# Ex 14.10\n", + "import numpy as np\n", + "\n", + "# Calculation\n", + "coeff = [13500, -2481, -660.75]\n", + "# Taking positive root\n", + "sA = round(np.roots(coeff)[0],3) #[meters]\n", + "\n", + "# Result\n", + "print\"sA = \",(sA),\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Ex 14.11 Page No 597" + ] + }, + { + "cell_type": "code", + "execution_count": 51, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Part(a)\n", + "vC = 4.39 m/s\n", + "\n", + "Part(b)\n", + "vC = 4.82 m/s\n" + ] + } + ], + "source": [ + "# Ex 14.11\n", + "import math\n", + "from __future__ import division\n", + "\n", + "# Calculation\n", + "# Part(a) Potential Energy\n", + "vC = round(math.sqrt((-(1/2)*3*(0.5**(2))+2*9.81*1)/((1/2)*2)),2) #[meters per second]\n", + "\n", + "# Result Part(a)\n", + "print\"Part(a)\"\n", + "print\"vC = \",(vC),\"m/s\\n\"\n", + "\n", + "# Part(b) Conservation of Energy\n", + "vC = round(math.sqrt(((1/2)*2*(2**(2))-(1/2)*3*(0.5**(2))+2*9.81*1)/((1/2)*2)),2) #[meters per second]\n", + "\n", + "# Result Part(b)\n", + "print\"Part(b)\"\n", + "print\"vC = \",(vC),\"m/s\"\n" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], + "source": [] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [default]", + "language": "python", + "name": "python2" + }, + "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": 1 +} |