summaryrefslogtreecommitdiff
path: root/Elementary_Fluid_Mechanics_by_J_K_Vennard/1-Fundamentals.ipynb
diff options
context:
space:
mode:
authorPrashant S2020-04-14 10:25:32 +0530
committerGitHub2020-04-14 10:25:32 +0530
commit06b09e7d29d252fb2f5a056eeb8bd1264ff6a333 (patch)
tree2b1df110e24ff0174830d7f825f43ff1c134d1af /Elementary_Fluid_Mechanics_by_J_K_Vennard/1-Fundamentals.ipynb
parentabb52650288b08a680335531742a7126ad0fb846 (diff)
parent476705d693c7122d34f9b049fa79b935405c9b49 (diff)
downloadall-scilab-tbc-books-ipynb-06b09e7d29d252fb2f5a056eeb8bd1264ff6a333.tar.gz
all-scilab-tbc-books-ipynb-06b09e7d29d252fb2f5a056eeb8bd1264ff6a333.tar.bz2
all-scilab-tbc-books-ipynb-06b09e7d29d252fb2f5a056eeb8bd1264ff6a333.zip
Merge pull request #1 from prashantsinalkar/masterHEADmaster
Initial commit
Diffstat (limited to 'Elementary_Fluid_Mechanics_by_J_K_Vennard/1-Fundamentals.ipynb')
-rw-r--r--Elementary_Fluid_Mechanics_by_J_K_Vennard/1-Fundamentals.ipynb193
1 files changed, 193 insertions, 0 deletions
diff --git a/Elementary_Fluid_Mechanics_by_J_K_Vennard/1-Fundamentals.ipynb b/Elementary_Fluid_Mechanics_by_J_K_Vennard/1-Fundamentals.ipynb
new file mode 100644
index 0000000..683a9e2
--- /dev/null
+++ b/Elementary_Fluid_Mechanics_by_J_K_Vennard/1-Fundamentals.ipynb
@@ -0,0 +1,193 @@
+{
+"cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Chapter 1: Fundamentals"
+ ]
+ },
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.1: Chapter_1_Example_1.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"//page no.8\n",
+"T = 80;//temperature of chlorine gas in degree F\n",
+"p = 100;//pressure in psia\n",
+"W = 2*35.45;//molecular weight of chlorine \n",
+"R = 1545/W;//specific gas constant in ft-lb/lb-degreeR\n",
+"gam = p*(144/R)*(1/(460+T));//specific weight of chlorine in lb/cuft\n",
+"Spec_vol = 1/gam;//specific volume in cuft/lb\n",
+"rho = gam/32.2;//density of chlorine in slug/cuft\n",
+"printf('Spec. weight = %.3f lb/cuft\n Spec. volume = %.3f cuft/lb\n density = %.4f slug/cuft',gam,Spec_vol,rho);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2: Chapter_1_Example_2.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"//page no. 12\n",
+"\n",
+"funcprot(0);\n",
+"gamma = 1.4;\n",
+"T1 = 60;//temperature of air in degree F\n",
+"p1 = 14.7;//pressure in psia\n",
+"k = 0.5;//(final volume/initial volume) = k\n",
+"R = 53.3;//Engineering gas constant\n",
+"gam1 = p1*(144/R)*(1/(460+T1));//lb/cuft\n",
+"gam2 = gam1/k;//lb/cuft\n",
+"p2 = (p1/(gam1^(gamma)))*(gam2^(gamma));// in psia\n",
+"T2 = p2*(144/R)*(1/gam2);//in degree F\n",
+"a1 = sqrt(gamma*32.2*R*(460+T1));// in fps\n",
+"a2 = sqrt(gamma*32.2*R*(T2));// in fps\n",
+"printf('Final pressure = %.1f psia\n Final temperature = %d degreeR \n Sonic velocity before compression = %d fps\n Sonic velocity after compression = %d fps',p2,T2,a1,a2);\n",
+"\n",
+"//there are small errors in the answers given in textbook"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.3: Chapter_1_Example_3.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"//page no. 17\n",
+"\n",
+"r1 = 0.25;// radius of cylinder in feet\n",
+"l = 2;//length of cylnider in feet\n",
+"r2 = 0.30;// radius of co-axial cylinder in feet\n",
+"mu = 0.018;//lb-sec/ft^2\n",
+"torque = 0.25;// in ft-lb\n",
+"dv_dy1 = torque/(4*%pi*mu*r1^2);//velocity gradient at radius = 0.25 in fps/ft\n",
+"dv_dy2 = torque/(4*%pi*mu*r2^2);//velocity gradient at radius = 0.30 in fps/ft\n",
+"V1 = integrate('-torque/(4*%pi*mu*r^2)','r',r2,r1);// velocity in fps\n",
+"rpm1 = V1*60/(2*%pi*r1);\n",
+"V2 = torque*(r2-r1)/(4*%pi*mu*r1^2);//in fps\n",
+"rpm2 = V2*60/(2*%pi*r1);\n",
+"hp = 2*%pi*r1*(rpm1/(550*60));\n",
+"printf('Velocity gradient at the inner cylinder wall is %.1f fps/ft and \n at the outer cylinder wall is %.1f fps/ft',dv_dy1,dv_dy2);\n",
+"printf('\n rpm = %.1f and approximate rpm = %.1f \n hp = %.5f ',rpm1,rpm2,hp);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4: Chapter_1_Example_4.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"\n",
+"//page no.20\n",
+"\n",
+"T = 70;//degreeF\n",
+"del_p = 0.1;// in psi\n",
+"sigma = 0.00498;// lb/ft\n",
+"R = (sigma*2)/(del_p*144);//in ft\n",
+"d = 12*2*R;// in inches\n",
+"printf('Diameter of the droplet of water, d = %.4f in',d);"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.5: Chapter_1_Example_5.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"clear;\n",
+"clc;\n",
+"\n",
+"//page no. 20\n",
+"\n",
+"l = 12;// length of the cylinder\n",
+"T = 150;//temperature of water in degreeF\n",
+"p1 = 14.52;//atmospheric pressure in psia\n",
+"p2 = 3.72;//the pressure on the inside of the piston in psia\n",
+"F = 0.25*(p1-p2)*%pi*l^2;//Force on the piston in lb\n",
+"printf('Minimum force on the piston to be applied is, F = %d lb.',F);\n",
+"\n",
+"//there is an error in the answer given in textbook"
+ ]
+ }
+],
+"metadata": {
+ "kernelspec": {
+ "display_name": "Scilab",
+ "language": "scilab",
+ "name": "scilab"
+ },
+ "language_info": {
+ "file_extension": ".sce",
+ "help_links": [
+ {
+ "text": "MetaKernel Magics",
+ "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md"
+ }
+ ],
+ "mimetype": "text/x-octave",
+ "name": "scilab",
+ "version": "0.7.1"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}