summaryrefslogtreecommitdiff
path: root/Industrial_Instrumentation
diff options
context:
space:
mode:
authordebashisdeb2014-06-20 15:42:42 +0530
committerdebashisdeb2014-06-20 15:42:42 +0530
commit83c1bfceb1b681b4bb7253b47491be2d8b2014a1 (patch)
treef54eab21dd3d725d64a495fcd47c00d37abed004 /Industrial_Instrumentation
parenta78126bbe4443e9526a64df9d8245c4af8843044 (diff)
downloadPython-Textbook-Companions-83c1bfceb1b681b4bb7253b47491be2d8b2014a1.tar.gz
Python-Textbook-Companions-83c1bfceb1b681b4bb7253b47491be2d8b2014a1.tar.bz2
Python-Textbook-Companions-83c1bfceb1b681b4bb7253b47491be2d8b2014a1.zip
removing problem statements
Diffstat (limited to 'Industrial_Instrumentation')
-rw-r--r--Industrial_Instrumentation/Chapter_1.ipynb567
-rw-r--r--Industrial_Instrumentation/Chapter_2.ipynb871
-rw-r--r--Industrial_Instrumentation/Chapter_3.ipynb526
-rw-r--r--Industrial_Instrumentation/Chapter_4.ipynb798
-rw-r--r--Industrial_Instrumentation/Chapter_5.ipynb1206
-rw-r--r--Industrial_Instrumentation/Chapter_6.ipynb786
-rw-r--r--Industrial_Instrumentation/Chapter_7.ipynb799
-rw-r--r--Industrial_Instrumentation/Chapter_8.ipynb686
-rw-r--r--Industrial_Instrumentation/ch2.ipynb69
-rw-r--r--Industrial_Instrumentation/ch3.ipynb128
-rw-r--r--Industrial_Instrumentation/ch4.ipynb314
-rw-r--r--Industrial_Instrumentation/ch5.ipynb234
-rw-r--r--Industrial_Instrumentation/ch6.ipynb108
-rw-r--r--Industrial_Instrumentation/ch7.ipynb24
-rw-r--r--Industrial_Instrumentation/ch8.ipynb90
-rw-r--r--Industrial_Instrumentation/ch9.ipynb110
16 files changed, 3391 insertions, 3925 deletions
diff --git a/Industrial_Instrumentation/Chapter_1.ipynb b/Industrial_Instrumentation/Chapter_1.ipynb
index ee337d56..d0854801 100644
--- a/Industrial_Instrumentation/Chapter_1.ipynb
+++ b/Industrial_Instrumentation/Chapter_1.ipynb
@@ -1,412 +1,433 @@
{
"metadata": {
- "name": "Chapter_1"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:6ba3160044fd56988f5c5098ab622aa22c3eae2ec5a701c2274f1da18b060ff5"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter 1: Temperature<h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.1, Page Number: 53<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Temperature Conversion'''",
- "",
- "#variable declaration",
- "c=-40.0 #Temp in degree Celcius",
- "",
- "#calculations",
- "k=c+273",
- "F=((9.0/5.0)*c)+32.0",
- "R=((9.0/5.0)*c)+492.0",
- "",
- "#Result",
- "print('\\nK=%d\u00b0K' %k)",
- "print('\\nF=%d\u00b0F' %F)",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "c=-40.0 #Temp in degree Celcius\n",
+ "\n",
+ "#calculations\n",
+ "k=c+273\n",
+ "F=((9.0/5.0)*c)+32.0\n",
+ "R=((9.0/5.0)*c)+492.0\n",
+ "\n",
+ "#Result\n",
+ "print('\\nK=%d\u00b0K' %k)\n",
+ "print('\\nF=%d\u00b0F' %F)\n",
"print('\\nR=%d\u00b0R' %R)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "",
- "K=233\u00b0K",
- "",
- "F=-40\u00b0F",
- "",
+ "\n",
+ "K=233\u00b0K\n",
+ "\n",
+ "F=-40\u00b0F\n",
+ "\n",
"R=420\u00b0R"
]
}
- ],
+ ],
"prompt_number": 1
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3> Example 1.2, Page Number: 53<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''percentage Accuracy and Error'''",
- "",
- "#varable Declaration",
- "span=1000.0 #given value of span in \u00b0C",
- "accuracy=1.0/100.0 #1% accuracy",
- "",
- "#calculations",
- "err=span*accuracy",
- "max_scale=1200.0",
- "Range_instr=max_scale+span",
- "meter_reading=700.0",
- "per_of_err=(err/meter_reading)*100.0",
- "",
- "#result",
- "print('(a)\\nAs error can be either positive or negative') ",
- "print('\\n the probable error at any point on the scale =\u00b1 %d\u00b0C'%err)",
- "print('\\n(b)\\nRange of the Instrument = %d\u00b0C'%Range_instr)",
+ "\n",
+ "\n",
+ "#varable Declaration\n",
+ "span=1000.0 #given value of span in \u00b0C\n",
+ "accuracy=1.0/100.0 #1% accuracy\n",
+ "\n",
+ "#calculations\n",
+ "err=span*accuracy\n",
+ "max_scale=1200.0\n",
+ "Range_instr=max_scale+span\n",
+ "meter_reading=700.0\n",
+ "per_of_err=(err/meter_reading)*100.0\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nAs error can be either positive or negative') \n",
+ "print('\\n the probable error at any point on the scale =\u00b1 %d\u00b0C'%err)\n",
+ "print('\\n(b)\\nRange of the Instrument = %d\u00b0C'%Range_instr)\n",
"print('\\n(c)\\nPercentage of Error = \u00b1 %.2f%% '%per_of_err)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "As error can be either positive or negative",
- "",
- " the probable error at any point on the scale =\u00b1 10\u00b0C",
- "",
- "(b)",
- "Range of the Instrument = 2200\u00b0C",
- "",
- "(c)",
+ "(a)\n",
+ "As error can be either positive or negative\n",
+ "\n",
+ " the probable error at any point on the scale =\u00b1 10\u00b0C\n",
+ "\n",
+ "(b)\n",
+ "Range of the Instrument = 2200\u00b0C\n",
+ "\n",
+ "(c)\n",
"Percentage of Error = \u00b1 1.43% "
]
}
- ],
+ ],
"prompt_number": 10
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.3, Page Number: 54<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Two wire RTD'''",
- "",
- "#variable declaration",
- "resi_per_leg=5.0 # lead wire resistance per leg in Ohm",
- "temp_coeff=0.385 # Temperature coefficient of Pt 100 RTD in ohms/\u00b0C",
- "",
- "#calculation",
- "R_due_to_leadwires=2*resi_per_leg",
- "err=R_due_to_leadwires/temp_coeff",
- "err =round(err,0)",
- "temp_obj=200.0",
- "temp_measured=temp_obj+err",
- "per_of_err=((temp_measured-temp_obj)/temp_obj)*100.0",
- "",
- "#Result",
- "print('(a)\\nThe contribution of 10 ohms lead wire resistance')",
- "print('to the measurement error = %d\u00b0C' %err)",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "resi_per_leg=5.0 # lead wire resistance per leg in Ohm\n",
+ "temp_coeff=0.385 # Temperature coefficient of Pt 100 RTD in ohms/\u00b0C\n",
+ "\n",
+ "#calculation\n",
+ "R_due_to_leadwires=2*resi_per_leg\n",
+ "err=R_due_to_leadwires/temp_coeff\n",
+ "err =round(err,0)\n",
+ "temp_obj=200.0\n",
+ "temp_measured=temp_obj+err\n",
+ "per_of_err=((temp_measured-temp_obj)/temp_obj)*100.0\n",
+ "\n",
+ "#Result\n",
+ "print('(a)\\nThe contribution of 10 ohms lead wire resistance')\n",
+ "print('to the measurement error = %d\u00b0C' %err)\n",
"print('\\n(b)\\nPercentage of Error = %d%%' %per_of_err)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "The contribution of 10 ohms lead wire resistance",
- "to the measurement error = 26\u00b0C",
- "",
- "(b)",
+ "(a)\n",
+ "The contribution of 10 ohms lead wire resistance\n",
+ "to the measurement error = 26\u00b0C\n",
+ "\n",
+ "(b)\n",
"Percentage of Error = 13%"
]
}
- ],
+ ],
"prompt_number": 3
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.4, Page Number: 54<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Thermocouple temperature measurement'''",
- "",
- "#variable declaration",
- "temp=2.022 #Millivolt corresponds to reference junction temp 50\u00b0C",
- "millivolt_cor=37.325 #Millivolt corresponds to reference junction temp 900\u00b0C",
- "",
- "#calculation",
- "op=millivolt_cor-temp",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "temp=2.022 #Millivolt corresponds to reference junction temp 50\u00b0C\n",
+ "millivolt_cor=37.325 #Millivolt corresponds to reference junction temp 900\u00b0C\n",
+ "\n",
+ "#calculation\n",
+ "op=millivolt_cor-temp\n",
+ "\n",
+ "#result\n",
"print('Millivolt output available = % .3f' %op)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Millivolt output available = 35.303"
]
}
- ],
+ ],
"prompt_number": 4
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.5, Page Number: 54<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Hot junction temperature of thermocouple'''",
- "",
- "#variable declaration",
- "millivolt_cor=2.585 #Millivolt corresponds to reference junction temp 50\u00b0C",
- "pot_reading=30.511 #reading on pot",
- "",
- "#calculation",
- "corrected_millivolt=pot_reading+millivolt_cor",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "millivolt_cor=2.585 #Millivolt corresponds to reference junction temp 50\u00b0C\n",
+ "pot_reading=30.511 #reading on pot\n",
+ "\n",
+ "#calculation\n",
+ "corrected_millivolt=pot_reading+millivolt_cor\n",
+ "\n",
+ "#result\n",
"print('Temperature correspond to %.3f mV from the table = 600\u00b0C' %corrected_millivolt)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Temperature correspond to 33.096 mV from the table = 600\u00b0C"
]
}
- ],
+ ],
"prompt_number": 5
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.6, Page Number: 54<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Caliberation of an instrument'''",
- "",
- "#variable Declarion",
- "ref_jun=100.0 #reference junction temp.",
- "mV_100=0.645 #voltage at 100\u00b0C",
- "mV_1000=9.585 #voltage at 1000\u00b0C",
- "mV_1200=11.947 #voltage at 1200\u00b0C",
- "",
- "#calculation",
- "op1=mV_1000-mV_100",
- "op2=mV_1200-mV_100",
- "",
- "#result",
- "print('Millivolt to be fed checking 1000 C = %.3f mV'%op1)",
+ "\n",
+ "\n",
+ "#variable Declarion\n",
+ "ref_jun=100.0 #reference junction temp.\n",
+ "mV_100=0.645 #voltage at 100\u00b0C\n",
+ "mV_1000=9.585 #voltage at 1000\u00b0C\n",
+ "mV_1200=11.947 #voltage at 1200\u00b0C\n",
+ "\n",
+ "#calculation\n",
+ "op1=mV_1000-mV_100\n",
+ "op2=mV_1200-mV_100\n",
+ "\n",
+ "#result\n",
+ "print('Millivolt to be fed checking 1000 C = %.3f mV'%op1)\n",
"print('\\nMillivolt to be fed checking 1200 C = %.3f mV'%op2)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "Millivolt to be fed checking 1000 C = 8.940 mV",
- "",
+ "Millivolt to be fed checking 1000 C = 8.940 mV\n",
+ "\n",
"Millivolt to be fed checking 1200 C = 11.302 mV"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.7, page Number: 55<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Wall temperature measurement'''",
- "",
- "#variable declaration",
- "E_rec_pyro=0.95*0.85 #Energy received by pyrometer",
- "",
- "#calculation",
- "T=1100.0/E_rec_pyro",
- " ",
- "#result",
+ "\n",
+ "#variable declaration\n",
+ "E_rec_pyro=0.95*0.85 #Energy received by pyrometer\n",
+ "\n",
+ "#calculation\n",
+ "T=1100.0/E_rec_pyro\n",
+ " \n",
+ "#result\n",
"print('Pyrometer reading T = %.2f\u00b0C'%T)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Pyrometer reading T = 1362.23\u00b0C"
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.8, Page Number: 55<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Thermocouple output'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "hot1_mV=41.29 # Millivolt corresponds to hot junction temp ",
- "cold1_mV=2.022 # Millivolt corresponds to cold junction temp ",
- "",
- "#calculation",
- "op1=hot1_mV-cold1_mV",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "hot2_mV=33.096 #Millivolt corresponds to hot junction temp ",
- "cold2_mV=2.585 #Millivolt corresponds to cold junction temp ",
- "#calculation",
- "op2=hot2_mV-cold2_mV",
- "",
- "#(c)",
- "",
- "#variable declaration",
- "hot3_mV=11.947 #Millivolt corresponds to hot junction temp ",
- "cold3_mV=0.299 #Millivolt corresponds to cold junction temp ",
- "#calculation",
- "op3=hot3_mV-cold3_mV",
- "",
- "#result",
- "print('(a)\\nOutput Millivolt = %.3f'%op1)",
- "print('\\n(b)\\nOutput Millivolt = %.3f'%op2)",
- "print('\\n(c)\\nAs the wrongly formed thermocouples at J1 and J2 will always oppose')",
- "print('the main millivolt output, the net output will be lower than normal value.')",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "hot1_mV=41.29 # Millivolt corresponds to hot junction temp \n",
+ "cold1_mV=2.022 # Millivolt corresponds to cold junction temp \n",
+ "\n",
+ "#calculation\n",
+ "op1=hot1_mV-cold1_mV\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "hot2_mV=33.096 #Millivolt corresponds to hot junction temp \n",
+ "cold2_mV=2.585 #Millivolt corresponds to cold junction temp \n",
+ "#calculation\n",
+ "op2=hot2_mV-cold2_mV\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#variable declaration\n",
+ "hot3_mV=11.947 #Millivolt corresponds to hot junction temp \n",
+ "cold3_mV=0.299 #Millivolt corresponds to cold junction temp \n",
+ "#calculation\n",
+ "op3=hot3_mV-cold3_mV\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nOutput Millivolt = %.3f'%op1)\n",
+ "print('\\n(b)\\nOutput Millivolt = %.3f'%op2)\n",
+ "print('\\n(c)\\nAs the wrongly formed thermocouples at J1 and J2 will always oppose')\n",
+ "print('the main millivolt output, the net output will be lower than normal value.')\n",
"print('Output mV<%.3f'%op3)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Output Millivolt = 39.268",
- "",
- "(b)",
- "Output Millivolt = 30.511",
- "",
- "(c)",
- "As the wrongly formed thermocouples at J1 and J2 will always oppose",
- "the main millivolt output, the net output will be lower than normal value.",
+ "(a)\n",
+ "Output Millivolt = 39.268\n",
+ "\n",
+ "(b)\n",
+ "Output Millivolt = 30.511\n",
+ "\n",
+ "(c)\n",
+ "As the wrongly formed thermocouples at J1 and J2 will always oppose\n",
+ "the main millivolt output, the net output will be lower than normal value.\n",
"Output mV<11.648"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 1.9, Page Number: 56<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''electtronic temperature transmitter'''",
- "",
- "#variable declaration",
- "Rl_ind=250.0 #load resistor for indicator",
- "Rl_rec=250.0 #load resistor for recorder",
- "load_allowable=600.0 #allowable load with load independency",
- "",
- "#calculation",
- "load_connected= Rl_ind+Rl_rec",
- "max_load_controller=load_allowable-load_connected",
- "op_cont=600.0",
- "total=Rl_ind+Rl_rec+load_allowable",
- "extra_load=total-op_cont",
- "",
- "#result",
- "print('(a)\\nThe max load to the controller = %d ohms'%max_load_controller)",
- "print('\\n(b)\\nExtra Load = %d ohms'%extra_load)",
- "print('\\nAdditional Power Supply voltage required = 10 V')",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "Rl_ind=250.0 #load resistor for indicator\n",
+ "Rl_rec=250.0 #load resistor for recorder\n",
+ "load_allowable=600.0 #allowable load with load independency\n",
+ "\n",
+ "#calculation\n",
+ "load_connected= Rl_ind+Rl_rec\n",
+ "max_load_controller=load_allowable-load_connected\n",
+ "op_cont=600.0\n",
+ "total=Rl_ind+Rl_rec+load_allowable\n",
+ "extra_load=total-op_cont\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nThe max load to the controller = %d ohms'%max_load_controller)\n",
+ "print('\\n(b)\\nExtra Load = %d ohms'%extra_load)\n",
+ "print('\\nAdditional Power Supply voltage required = 10 V')\n",
"print('\\nMinimum Power Supply Voltage = 34 ')"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "The max load to the controller = 100 ohms",
- "",
- "(b)",
- "Extra Load = 500 ohms",
- "",
- "Additional Power Supply voltage required = 10 V",
- "",
+ "(a)\n",
+ "The max load to the controller = 100 ohms\n",
+ "\n",
+ "(b)\n",
+ "Extra Load = 500 ohms\n",
+ "\n",
+ "Additional Power Supply voltage required = 10 V\n",
+ "\n",
"Minimum Power Supply Voltage = 34 "
]
}
- ],
+ ],
"prompt_number": 9
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/Chapter_2.ipynb b/Industrial_Instrumentation/Chapter_2.ipynb
index f6c4dada..41a457ab 100644
--- a/Industrial_Instrumentation/Chapter_2.ipynb
+++ b/Industrial_Instrumentation/Chapter_2.ipynb
@@ -1,603 +1,630 @@
{
"metadata": {
- "name": "Chapter_2"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:e12000c40c7eba5fb38d72e0bdbc08735899d3485eb0ecea04e85215c845b6b8"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter 2: Pressure<h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.1, Page Number: 116<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Pressure conversion'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "#1kg/cm^2=10000 mmWG",
- "x=10000.0*10.0 #equivalnt to 10kg/cm^2",
- "",
- "#result",
- "print('(a)\\n 10kg/cm^2 = %.0f mmWG' %x)",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "onemm_Hg=13.546 #pressure of 1 mm Hg",
- "",
- "#calculation",
- "y=10.0**5/onemm_Hg",
- "y=y/10.0**3",
- "",
- "#result",
- "print('\\n(b)\\n10kg/cm^2 = 10^5 mmWG = %.2f * 10^3 mmHg' %y)",
- "",
- "#(c)",
- "",
- "#variable declaration",
- "onebar=1.03 # 1 Bar presssure in kg/cm^2",
- "#calculation",
- "z=10.0/onebar",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "#1kg/cm^2=10000 mmWG\n",
+ "x=10000.0*10.0 #equivalnt to 10kg/cm^2\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\n 10kg/cm^2 = %.0f mmWG' %x)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "onemm_Hg=13.546 #pressure of 1 mm Hg\n",
+ "\n",
+ "#calculation\n",
+ "y=10.0**5/onemm_Hg\n",
+ "y=y/10.0**3\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\n10kg/cm^2 = 10^5 mmWG = %.2f * 10^3 mmHg' %y)\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#variable declaration\n",
+ "onebar=1.03 # 1 Bar presssure in kg/cm^2\n",
+ "#calculation\n",
+ "z=10.0/onebar\n",
+ "\n",
+ "#result\n",
"print('\\n(c)\\n10kg/cm^2 = %.2f bars' %z)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- " 10kg/cm^2 = 100000 mmWG",
- "",
- "(b)",
- "10kg/cm^2 = 10^5 mmWG = 7.38 * 10^3 mmHg",
- "",
- "(c)",
+ "(a)\n",
+ " 10kg/cm^2 = 100000 mmWG\n",
+ "\n",
+ "(b)\n",
+ "10kg/cm^2 = 10^5 mmWG = 7.38 * 10^3 mmHg\n",
+ "\n",
+ "(c)\n",
"10kg/cm^2 = 9.71 bars"
]
}
- ],
+ ],
"prompt_number": 1
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.2, Page Number: 116<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Gauge and absolute pressure'''",
- "",
- "#(a)",
- "",
- "#variable Declaration",
- "gamm=1000.0 # density of water",
- "d=35.0 # depth of water ",
- "dens_Hg=13.546 # density of Hg",
- "",
- "#calculation",
- "press_in_kg_cm=gamm*d*10**-4",
- "press_in_mmHg=gamm*d/dens_Hg",
- "press_in_mmHg=press_in_mmHg/10**3",
- "",
- "#result",
- "print('(a)\\nThe pressure at depth of %d meters in a water tank=%.1f kg/cm^2 = %.2f*10^3 mmHg'%(d, press_in_kg_cm, press_in_mmHg))",
- "",
- "#(b)",
- "",
- "#varible declaration",
- "press_atm=1.03 #atmospheric pressure",
- "",
- "#calculation",
- "abspress=press_in_kg_cm+press_atm",
- "abspress_mmHg=press_in_mmHg*1000.0+760.0",
- "abspress_mmHg=abspress_mmHg/1000.0",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable Declaration\n",
+ "gamm=1000.0 # density of water\n",
+ "d=35.0 # depth of water \n",
+ "dens_Hg=13.546 # density of Hg\n",
+ "\n",
+ "#calculation\n",
+ "press_in_kg_cm=gamm*d*10**-4\n",
+ "press_in_mmHg=gamm*d/dens_Hg\n",
+ "press_in_mmHg=press_in_mmHg/10**3\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nThe pressure at depth of %d meters in a water tank=%.1f kg/cm^2 = %.2f*10^3 mmHg'%(d, press_in_kg_cm, press_in_mmHg))\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#varible declaration\n",
+ "press_atm=1.03 #atmospheric pressure\n",
+ "\n",
+ "#calculation\n",
+ "abspress=press_in_kg_cm+press_atm\n",
+ "abspress_mmHg=press_in_mmHg*1000.0+760.0\n",
+ "abspress_mmHg=abspress_mmHg/1000.0\n",
+ "\n",
+ "#result\n",
"print('\\n(b)\\nAbsolute Pressure= %.2f kg/cm^2 Abs = %.2f*10^3 mmHg Abs'%(abspress, abspress_mmHg))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "The pressure at depth of 35 meters in a water tank=3.5 kg/cm^2 = 2.58*10^3 mmHg",
- "",
- "(b)",
+ "(a)\n",
+ "The pressure at depth of 35 meters in a water tank=3.5 kg/cm^2 = 2.58*10^3 mmHg\n",
+ "\n",
+ "(b)\n",
"Absolute Pressure= 4.53 kg/cm^2 Abs = 3.34*10^3 mmHg Abs"
]
}
- ],
+ ],
"prompt_number": 2
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.3, Page Number:116<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "''' Gauge and absolute pressure'''",
- "",
- "#varible declaration",
- "egp=260.0 # equivalent gauge pressure",
- "",
- "#calculation",
- "abspress=760.0-egp",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#varible declaration\n",
+ "egp=260.0 # equivalent gauge pressure\n",
+ "\n",
+ "#calculation\n",
+ "abspress=760.0-egp\n",
+ "\n",
+ "#result\n",
"print('Absolute Presssure = %d mmHg' %abspress)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Absolute Presssure = 500 mmHg"
]
}
- ],
+ ],
"prompt_number": 3
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.4,Page Number:117<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''pressure measurement using U tube manometer'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "p_diff=500.0 #pressure difference in mmHg",
- "",
- "#calculations",
- "pdiff=p_diff*13.546/10000",
- "",
- "#Result",
- "print('(a)\\np1-p2 = %.3f kg/cm^2' %pdiff)",
- "",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "p1=6770.0 # Gauge pressure in mmWG",
- "p_atm=10300.0 # atmospheric pressure ",
- "",
- "#calculation",
- "abs_p1=p1+p_atm",
- "",
- "#result",
- "print('\\n(b)If p2 is open to atmosphere:\\nAbsolute Pressure P1 = %d mmWG abs.' %abs_p1)",
- "",
- "#(c)",
- "",
- "#variable declaration",
- "P1=500.0 #mmHg absolute pressure",
- "",
- "#calculations",
- "P1_gauge=P1-760.0",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "p_diff=500.0 #pressure difference in mmHg\n",
+ "\n",
+ "#calculations\n",
+ "pdiff=p_diff*13.546/10000\n",
+ "\n",
+ "#Result\n",
+ "print('(a)\\np1-p2 = %.3f kg/cm^2' %pdiff)\n",
+ "\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "p1=6770.0 # Gauge pressure in mmWG\n",
+ "p_atm=10300.0 # atmospheric pressure \n",
+ "\n",
+ "#calculation\n",
+ "abs_p1=p1+p_atm\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)If p2 is open to atmosphere:\\nAbsolute Pressure P1 = %d mmWG abs.' %abs_p1)\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#variable declaration\n",
+ "P1=500.0 #mmHg absolute pressure\n",
+ "\n",
+ "#calculations\n",
+ "P1_gauge=P1-760.0\n",
+ "\n",
+ "#result\n",
"print('\\n(c)If p2 is evacuated and sealed:\\np1= %d mmHg gauge Pressure' %P1_gauge)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "p1-p2 = 0.677 kg/cm^2",
- "",
- "(b)If p2 is open to atmosphere:",
- "Absolute Pressure P1 = 17070 mmWG abs.",
- "",
- "(c)If p2 is evacuated and sealed:",
+ "(a)\n",
+ "p1-p2 = 0.677 kg/cm^2\n",
+ "\n",
+ "(b)If p2 is open to atmosphere:\n",
+ "Absolute Pressure P1 = 17070 mmWG abs.\n",
+ "\n",
+ "(c)If p2 is evacuated and sealed:\n",
"p1= -260 mmHg gauge Pressure"
]
}
- ],
+ ],
"prompt_number": 4
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.5, Page Number: 117<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Specific Gravity and weight density'''",
- "",
- "#variable declaration",
- "spe_grav_water=1.0 # specific gravity of water",
- "",
- "#calculation",
- "spe_grav_X=spe_grav_water*100.0/50.0",
- "wt_dens_water=1000.0",
- "wt_dens_X=wt_dens_water*2.0",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "spe_grav_water=1.0 # specific gravity of water\n",
+ "\n",
+ "#calculation\n",
+ "spe_grav_X=spe_grav_water*100.0/50.0\n",
+ "wt_dens_water=1000.0\n",
+ "wt_dens_X=wt_dens_water*2.0\n",
+ "\n",
+ "#result\n",
"print('Weight Density of X = %d kg/m^3' %wt_dens_X)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Weight Density of X = 2000 kg/m^3"
]
}
- ],
+ ],
"prompt_number": 5
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.6, Page Number: 117<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''water flow rate using mercury manometer'''",
- "",
- "#variable declaration",
- "A=1.0/20.0 # Area ratio",
- "p_diff=1500.0 # pressure difference in mmWG",
- "",
- "#result",
- "print('(a)\\nAs Delta_h=A2/A1*h << h and normally negligible for well type manometer')",
- "print('hence, p1-p2 = h = %d =111 mmHg' %p_diff)",
- "print('\\n(b)\\nh measured above the oriinal reference will be half of H, i.e. 111/2=55.5 mmHg')",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "A=1.0/20.0 # Area ratio\n",
+ "p_diff=1500.0 # pressure difference in mmWG\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nAs Delta_h=A2/A1*h << h and normally negligible for well type manometer')\n",
+ "print('hence, p1-p2 = h = %d =111 mmHg' %p_diff)\n",
+ "print('\\n(b)\\nh measured above the oriinal reference will be half of H, i.e. 111/2=55.5 mmHg')\n",
"print('(Since area of both legs are same)')"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "As Delta_h=A2/A1*h << h and normally negligible for well type manometer",
- "hence, p1-p2 = h = 1500 =111 mmHg",
- "",
- "(b)",
- "h measured above the oriinal reference will be half of H, i.e. 111/2=55.5 mmHg",
+ "(a)\n",
+ "As Delta_h=A2/A1*h << h and normally negligible for well type manometer\n",
+ "hence, p1-p2 = h = 1500 =111 mmHg\n",
+ "\n",
+ "(b)\n",
+ "h measured above the oriinal reference will be half of H, i.e. 111/2=55.5 mmHg\n",
"(Since area of both legs are same)"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.7, Page Number: 119<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''readings and errors in Bourdon gauge reading'''",
- "",
- "print('1 kg/cm^2 = 10 mWG\\n')",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "press=10+2 #pressure read by the gauge",
- "",
- "#result",
- "print('\\n(a)Bourdon Gauge is mounted 20 meters below water line:')",
- "print('\\nPressure read by the Gauge = %d kg/cm^2'%press)",
- "",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "press2=10-3 #pressure read by the gauge",
- "",
- "#result",
- "print('\\n\\n(b)Bourdon Gauge is located 30 meters above the water line:')",
+ "\n",
+ "\n",
+ "print('1 kg/cm^2 = 10 mWG\\n')\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "press=10+2 #pressure read by the gauge\n",
+ "\n",
+ "#result\n",
+ "print('\\n(a)Bourdon Gauge is mounted 20 meters below water line:')\n",
+ "print('\\nPressure read by the Gauge = %d kg/cm^2'%press)\n",
+ "\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "press2=10-3 #pressure read by the gauge\n",
+ "\n",
+ "#result\n",
+ "print('\\n\\n(b)Bourdon Gauge is located 30 meters above the water line:')\n",
"print('\\nPressure read by the Gauge = %d kg/cm^2'%press2)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "1 kg/cm^2 = 10 mWG",
- "",
- "",
- "(a)Bourdon Gauge is mounted 20 meters below water line:",
- "",
- "Pressure read by the Gauge = 12 kg/cm^2",
- "",
- "",
- "(b)Bourdon Gauge is located 30 meters above the water line:",
- "",
+ "1 kg/cm^2 = 10 mWG\n",
+ "\n",
+ "\n",
+ "(a)Bourdon Gauge is mounted 20 meters below water line:\n",
+ "\n",
+ "Pressure read by the Gauge = 12 kg/cm^2\n",
+ "\n",
+ "\n",
+ "(b)Bourdon Gauge is located 30 meters above the water line:\n",
+ "\n",
"Pressure read by the Gauge = 7 kg/cm^2"
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.8, Page Number: 120<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Specific Gravity and density of liquid'''",
- "",
- "#Variable declaration",
- "dens_water=1000.0 # water Density",
- "h1=125.0 # height1 mm",
- "h2=250.0 # height2 mm",
- "d2=h1*dens_water/h2",
- "",
- "#result",
- "",
- "#a",
- "print('(a)\\nDensity of Liquid = %d kg/m^3' %d2)",
- "print('\\nSpecific Density of the liquid = %.1f' %(h1/h2))",
- "",
- "#(b)",
- "print('\\n\\n(b)\\nIf Values of water and liquid interchanged:\\n')",
- "d3=h2*dens_water/h1",
- "print('\\nDensity of Liquid = %d kg/m^3' %d3)",
+ "\n",
+ "\n",
+ "#Variable declaration\n",
+ "dens_water=1000.0 # water Density\n",
+ "h1=125.0 # height1 mm\n",
+ "h2=250.0 # height2 mm\n",
+ "d2=h1*dens_water/h2\n",
+ "\n",
+ "#result\n",
+ "\n",
+ "#a\n",
+ "print('(a)\\nDensity of Liquid = %d kg/m^3' %d2)\n",
+ "print('\\nSpecific Density of the liquid = %.1f' %(h1/h2))\n",
+ "\n",
+ "#(b)\n",
+ "print('\\n\\n(b)\\nIf Values of water and liquid interchanged:\\n')\n",
+ "d3=h2*dens_water/h1\n",
+ "print('\\nDensity of Liquid = %d kg/m^3' %d3)\n",
"print('\\nSpecific Density of the liquid = %.1f' %(h2/h1))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Density of Liquid = 500 kg/m^3",
- "",
- "Specific Density of the liquid = 0.5",
- "",
- "",
- "(b)",
- "If Values of water and liquid interchanged:",
- "",
- "",
- "Density of Liquid = 2000 kg/m^3",
- "",
+ "(a)\n",
+ "Density of Liquid = 500 kg/m^3\n",
+ "\n",
+ "Specific Density of the liquid = 0.5\n",
+ "\n",
+ "\n",
+ "(b)\n",
+ "If Values of water and liquid interchanged:\n",
+ "\n",
+ "\n",
+ "Density of Liquid = 2000 kg/m^3\n",
+ "\n",
"Specific Density of the liquid = 2.0"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.9, Page Number: 120<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''strain gauge wire length and cross section area'''",
- "",
- "import math",
- "#variable Declaration",
- "R=120.0 #resistance",
- "l=122.0 #length",
- "a=0.1 #area",
- "R1=140.0 #resistance in ohm",
- "",
- "#calculation",
- "rho=R*a/l",
- "l1=math.sqrt(R1*a*l/rho)",
- "l1=round(l1,0)",
- "",
- "#Result",
- "print('Length l1 = %d meters' %l1)",
- "A1=a*l/l1",
+ "\n",
+ "\n",
+ "import math\n",
+ "#variable Declaration\n",
+ "R=120.0 #resistance\n",
+ "l=122.0 #length\n",
+ "a=0.1 #area\n",
+ "R1=140.0 #resistance in ohm\n",
+ "\n",
+ "#calculation\n",
+ "rho=R*a/l\n",
+ "l1=math.sqrt(R1*a*l/rho)\n",
+ "l1=round(l1,0)\n",
+ "\n",
+ "#Result\n",
+ "print('Length l1 = %d meters' %l1)\n",
+ "A1=a*l/l1\n",
"print('\\nArea A1 = %.4f mm^2' %A1)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "Length l1 = 132 meters",
- "",
+ "Length l1 = 132 meters\n",
+ "\n",
"Area A1 = 0.0924 mm^2"
]
}
- ],
+ ],
"prompt_number": 1
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.10, Page Number: 121<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Capacitance calculation for variable dielectric'''",
- "",
- "c=0.57 #Constant",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "d=0.1 #distance between plates",
- "di1=100.0 #Dielectric constant",
- "di2=1000.0 #Dielectric constant",
- "",
- "#calculation",
- "c1=c*di1*10.0/d",
- "c1=round(c1,0)",
- "",
- "#result",
- "print('(a)\\nC1=%d pf' %c1)",
- "",
- "",
- "#(b)",
- "",
- "#calculation",
- "c2=c*di2*10/d",
- "",
- "#result",
- "print('\\n(b)\\nC2=%d pf' %c2)",
- "",
- "",
- "#(c)",
- "",
- "#calculation",
- "ds=0.09",
- "c11=c*di1*10/ds",
- "c12=c*di2*10/ds",
- "",
- "#result",
+ "\n",
+ "\n",
+ "c=0.57 #Constant\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "d=0.1 #distance between plates\n",
+ "di1=100.0 #Dielectric constant\n",
+ "di2=1000.0 #Dielectric constant\n",
+ "\n",
+ "#calculation\n",
+ "c1=c*di1*10.0/d\n",
+ "c1=round(c1,0)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nC1=%d pf' %c1)\n",
+ "\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#calculation\n",
+ "c2=c*di2*10/d\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nC2=%d pf' %c2)\n",
+ "\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#calculation\n",
+ "ds=0.09\n",
+ "c11=c*di1*10/ds\n",
+ "c12=c*di2*10/ds\n",
+ "\n",
+ "#result\n",
"print('\\n(c)\\nC1 = %.1f pf\\nC2 = %d pf'%(c11,c12))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "C1=5700 pf",
- "",
- "(b)",
- "C2=57000 pf",
- "",
- "(c)",
- "C1 = 6333.3 pf",
+ "(a)\n",
+ "C1=5700 pf\n",
+ "\n",
+ "(b)\n",
+ "C2=57000 pf\n",
+ "\n",
+ "(c)\n",
+ "C1 = 6333.3 pf\n",
"C2 = 63333 pf"
]
}
- ],
+ ],
"prompt_number": 10
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.11, Page Number: 121<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''pressure gauge caliberation'''",
- "",
- "#variable Declaration",
- "A=1.0 #area",
- "p1=10.0 #pressure",
- "",
- "#calculation",
- "W1=A*p1",
- "",
- "#Result",
- "print('W1 = %d kg' %W1)",
+ "\n",
+ "\n",
+ "#variable Declaration\n",
+ "A=1.0 #area\n",
+ "p1=10.0 #pressure\n",
+ "\n",
+ "#calculation\n",
+ "W1=A*p1\n",
+ "\n",
+ "#Result\n",
+ "print('W1 = %d kg' %W1)\n",
"print('\\nWith the 4 standard weights of 10kg, 20kg, 30kg and 40kg')"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "W1 = 10 kg",
- "",
+ "W1 = 10 kg\n",
+ "\n",
"With the 4 standard weights of 10kg, 20kg, 30kg and 40kg"
]
}
- ],
+ ],
"prompt_number": 11
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 2.12, Page Number: 122<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''pressure calculation using McLeod gauge'''",
- "",
- "#varable declaration",
- "p1=10**-2 #pressure in torr",
- "h1=20.0 #height in mm",
- "",
- "#xalculation",
- "K=p1/h1**2",
- "p2=K*30**2",
- "p2=p2*100.0",
- "",
- "#Result",
+ "\n",
+ "#varable declaration\n",
+ "p1=10**-2 #pressure in torr\n",
+ "h1=20.0 #height in mm\n",
+ "\n",
+ "#xalculation\n",
+ "K=p1/h1**2\n",
+ "p2=K*30**2\n",
+ "p2=p2*100.0\n",
+ "\n",
+ "#Result\n",
"print('The unknown pressure p2 = %.2f * 10^-2 torr' %p2)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"The unknown pressure p2 = 2.25 * 10^-2 torr"
]
}
- ],
+ ],
"prompt_number": 12
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/Chapter_3.ipynb b/Industrial_Instrumentation/Chapter_3.ipynb
index 6d26bc18..b7ff3a1a 100644
--- a/Industrial_Instrumentation/Chapter_3.ipynb
+++ b/Industrial_Instrumentation/Chapter_3.ipynb
@@ -1,391 +1,413 @@
{
"metadata": {
- "name": "Chapter_3"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:40aab97a0942d997de9cd8ee539182af9fd67e045ac34df8f9ba65083df3fe50"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter_3: Force Torque and Velocity<h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.1, Page Number: 163<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Force calculation'''",
- "",
- "#variable declaration",
- "m1=20 #mass of the body in Kg ",
- "a=5 #acceleration in m/s^2",
- "",
- "#calculation",
- "F=m1*a",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "m1=20 #mass of the body in Kg \n",
+ "a=5 #acceleration in m/s^2\n",
+ "\n",
+ "#calculation\n",
+ "F=m1*a\n",
+ "\n",
+ "#result\n",
"print('F = %d Newtons'%F)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"F = 100 Newtons"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.2, Page Number: 163<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Weight calculation'''",
- "",
- "#variable declaration",
- "m1=50 #mass of the body in Kg ",
- "g1=9.8 #acceleration due to gravity",
- "",
- "#calculation",
- "W2=m1*g1",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "m1=50 #mass of the body in Kg \n",
+ "g1=9.8 #acceleration due to gravity\n",
+ "\n",
+ "#calculation\n",
+ "W2=m1*g1\n",
+ "\n",
+ "#result\n",
"print('W = %d Newtons = %d kgf' %(W2,m1))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"W = 490 Newtons = 50 kgf"
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.3, Page Number: 164<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of specific gravity'''",
- "",
- "#variable declaration",
- "wt_material=2500.0 #weight of 1 m^3 material",
- "wt_water=1000.0 #weight of 1 m^3 water",
- "",
- "#calculation",
- "spe_grav=wt_material/wt_water",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "wt_material=2500.0 #weight of 1 m^3 material\n",
+ "wt_water=1000.0 #weight of 1 m^3 water\n",
+ "\n",
+ "#calculation\n",
+ "spe_grav=wt_material/wt_water\n",
+ "\n",
+ "#result\n",
"print('Specific gravity of the material = %.1f' %spe_grav)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Specific gravity of the material = 2.5"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.4, Page Number: 164<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Estimation of uncertainty due to sensitivity'''",
- "",
- "import math",
- "#variable declaration",
- "L=20.0 # length in cm",
- "W=2000.0 # Weight of mass in gm ",
- "db=0.02 # length in cm ",
- "Wb=100.0 # Weight of mass in gm ",
- "dG=0.5 # length in cm",
- "",
- "#calculation",
- "S=L/(2*W*db+Wb*dG)",
- "fi=0.2",
- "DeltaW=fi*math.pi/(180*S)",
- "",
- "#result",
- "print('S = %.3f rad/g' %S)",
+ "\n",
+ "\n",
+ "import math\n",
+ "#variable declaration\n",
+ "L=20.0 # length in cm\n",
+ "W=2000.0 # Weight of mass in gm \n",
+ "db=0.02 # length in cm \n",
+ "Wb=100.0 # Weight of mass in gm \n",
+ "dG=0.5 # length in cm\n",
+ "\n",
+ "#calculation\n",
+ "S=L/(2*W*db+Wb*dG)\n",
+ "fi=0.2\n",
+ "DeltaW=fi*math.pi/(180*S)\n",
+ "\n",
+ "#result\n",
+ "print('S = %.3f rad/g' %S)\n",
"print('\\nDeltaW = %.3f g' %DeltaW)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "S = 0.154 rad/g",
- "",
+ "S = 0.154 rad/g\n",
+ "\n",
"DeltaW = 0.023 g"
]
}
- ],
+ ],
"prompt_number": 9
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.5, Page Number: 164<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Torque Calculation'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "hp=746.0 # horse power",
- "P=5*hp # Saft power in Watts",
- "N=1500.0 # speed in rpm",
- "",
- "#calculation",
- "n=N/60.0",
- "T=P*60/(2*math.pi*n)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "hp=746.0 # horse power\n",
+ "P=5*hp # Saft power in Watts\n",
+ "N=1500.0 # speed in rpm\n",
+ "\n",
+ "#calculation\n",
+ "n=N/60.0\n",
+ "T=P*60/(2*math.pi*n)\n",
+ "\n",
+ "#result\n",
"print('T = %.0f Newton meters' %(math.ceil(T)))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"T = 1425 Newton meters"
]
}
- ],
+ ],
"prompt_number": 10
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.6, Page Number: 165<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Force calculation'''",
- "",
- "#variable declaration",
- "ch_l=0.075 #change in length",
- "orig_l=50.0 #Original length",
- "",
- "#calculation",
- "S=ch_l/orig_l",
- "E=9.66*10**5",
- "stress=E*S",
- "area=1.5",
- "f=stress*area",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "ch_l=0.075 #change in length\n",
+ "orig_l=50.0 #Original length\n",
+ "\n",
+ "#calculation\n",
+ "S=ch_l/orig_l\n",
+ "E=9.66*10**5\n",
+ "stress=E*S\n",
+ "area=1.5\n",
+ "f=stress*area\n",
+ "\n",
+ "#result\n",
"print('Strain = %.4f cm/cm\\nStress =%d kg/cm^2\\nForce = %.1f kg'%(S,stress,f))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "Strain = 0.0015 cm/cm",
- "Stress =1449 kg/cm^2",
+ "Strain = 0.0015 cm/cm\n",
+ "Stress =1449 kg/cm^2\n",
"Force = 2173.5 kg"
]
}
- ],
+ ],
"prompt_number": 11
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.7, Page Number: 165<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''resistance strain gauge'''",
- "",
- "import math",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "R1=120.0 # resistance in Ohm",
- "R2=120.0 # resistance in Ohm",
- "R3=120.0 # resistance in Ohm",
- "R4=120.0 # resistance in Ohm",
- "Rg=100.0 # resistance in Ohm",
- "",
- "#calculation",
- "C=(R1*R2*R4)+(R1*R3*R4)+(R1*R2*R3)+(R2*R3*R4)+(Rg*(R1+R4)*(R2+R3))",
- "C=C/(10**7)",
- "",
- "#result",
- "print('(a)\\nC=%.3f*10^7' %C)",
- "E=10",
- "F=(E*R3*R1*2*10**3)/(C*10**7)",
- "print('\\nF = %.1f *10^3 A/mm = %.1f mA/mm'%(F,F))",
- "",
- "#(b)",
- "",
- "#calculation",
- "Fe=2*10**-4",
- "E=10",
- "DeltaE=Fe*E/(4+4*10**-4)",
- "DeltaE=DeltaE*10**3",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "R1=120.0 # resistance in Ohm\n",
+ "R2=120.0 # resistance in Ohm\n",
+ "R3=120.0 # resistance in Ohm\n",
+ "R4=120.0 # resistance in Ohm\n",
+ "Rg=100.0 # resistance in Ohm\n",
+ "\n",
+ "#calculation\n",
+ "C=(R1*R2*R4)+(R1*R3*R4)+(R1*R2*R3)+(R2*R3*R4)+(Rg*(R1+R4)*(R2+R3))\n",
+ "C=C/(10**7)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nC=%.3f*10^7' %C)\n",
+ "E=10\n",
+ "F=(E*R3*R1*2*10**3)/(C*10**7)\n",
+ "print('\\nF = %.1f *10^3 A/mm = %.1f mA/mm'%(F,F))\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#calculation\n",
+ "Fe=2*10**-4\n",
+ "E=10\n",
+ "DeltaE=Fe*E/(4+4*10**-4)\n",
+ "DeltaE=DeltaE*10**3\n",
+ "\n",
+ "#Result\n",
"print('\\n(b)\\nDeltaEg=%.1f mV' %DeltaE)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "C=1.267*10^7",
- "",
- "F = 22.7 *10^3 A/mm = 22.7 mA/mm",
- "",
- "(b)",
+ "(a)\n",
+ "C=1.267*10^7\n",
+ "\n",
+ "F = 22.7 *10^3 A/mm = 22.7 mA/mm\n",
+ "\n",
+ "(b)\n",
"DeltaEg=0.5 mV"
]
}
- ],
+ ],
"prompt_number": 12
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.8, PAge Number: 167<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''speed measurement using stroboscope'''",
- "",
- "#(a)",
- "import math",
- "",
- "#variable Declaration",
- "r1=2500.0 # Highest flasing rate ",
- "r2=1500.0 # next Highest flasing rate ",
- "",
- "#calculation",
- "n=(r1*r2)/(r1-r2)",
- "",
- "#result",
- "print('(a)\\nn = %d rpm'%n)",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "N=5.0 # Fift time syncronization for same speed",
- "",
- "#calculation",
- "r5=n*r1/((r1*(N-1))+n)",
- "r5=math.ceil(r5)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "import math\n",
+ "\n",
+ "#variable Declaration\n",
+ "r1=2500.0 # Highest flasing rate \n",
+ "r2=1500.0 # next Highest flasing rate \n",
+ "\n",
+ "#calculation\n",
+ "n=(r1*r2)/(r1-r2)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nn = %d rpm'%n)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "N=5.0 # Fift time syncronization for same speed\n",
+ "\n",
+ "#calculation\n",
+ "r5=n*r1/((r1*(N-1))+n)\n",
+ "r5=math.ceil(r5)\n",
+ "\n",
+ "#result\n",
"print('\\n(b)\\nr5=%d Flashes/Minute' %r5)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "n = 3750 rpm",
- "",
- "(b)",
+ "(a)\n",
+ "n = 3750 rpm\n",
+ "\n",
+ "(b)\n",
"r5=682 Flashes/Minute"
]
}
- ],
+ ],
"prompt_number": 13
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 3.9, Page Number: 167<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''speed measurement using proximity'''",
- "",
- "#variable declaration",
- "rpm=1500.0 #rotation in rpm",
- "f=200.0 #frequency",
- "",
- "#calculation",
- "N=60*f/rpm",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "rpm=1500.0 #rotation in rpm\n",
+ "f=200.0 #frequency\n",
+ "\n",
+ "#calculation\n",
+ "N=60*f/rpm\n",
+ "\n",
+ "#result\n",
"print('No of teeth on the wheel\\nN=%d' %N)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "No of teeth on the wheel",
+ "No of teeth on the wheel\n",
"N=8"
]
}
- ],
+ ],
"prompt_number": 14
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/Chapter_4.ipynb b/Industrial_Instrumentation/Chapter_4.ipynb
index f58d6ec6..ea3f076f 100644
--- a/Industrial_Instrumentation/Chapter_4.ipynb
+++ b/Industrial_Instrumentation/Chapter_4.ipynb
@@ -1,554 +1,578 @@
{
"metadata": {
- "name": "Chapter_4"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:81d0436ef2f36f55ad662ab91b6d5e2e47a4c3c61b8080d3706a64417c68403d"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter 4: Acceleration Vibration and Density<h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.1, Page Number:209 <h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "''''mechanical system for a seismic instrument'''",
- "",
- "import math",
- "#(a)",
- "",
- "#variable Declaration",
- "k=50.0 #Spring constant ",
- "m=0.005 # mass in kg",
- "",
- "#calculation",
- "wn=math.sqrt(k/m)",
- "",
- "#result",
- "print('(a)\\nNatural frequency(wn)= %d rad/s' %wn)",
- "",
- "",
- "#(b)",
- "",
- "#calculation",
- "Cc=2*(m*k)**(0.5)",
- "",
- "#result",
+ "\n",
+ "import math\n",
+ "#(a)\n",
+ "\n",
+ "#variable Declaration\n",
+ "k=50.0 #Spring constant \n",
+ "m=0.005 # mass in kg\n",
+ "\n",
+ "#calculation\n",
+ "wn=math.sqrt(k/m)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nNatural frequency(wn)= %d rad/s' %wn)\n",
+ "\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#calculation\n",
+ "Cc=2*(m*k)**(0.5)\n",
+ "\n",
+ "#result\n",
"print('\\n(b)\\nCc=%d' %Cc)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Natural frequency(wn)= 100 rad/s",
- "",
- "(b)",
+ "(a)\n",
+ "Natural frequency(wn)= 100 rad/s\n",
+ "\n",
+ "(b)\n",
"Cc=1"
]
}
- ],
+ ],
"prompt_number": 1
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.2, Page Number:209<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Frequency and phase angle of motion'''",
- "",
- "#(a)",
- "import math",
- "",
- "#variable Declaration",
- "Cc=1.0 # damping ratio ",
- "C=0.7*Cc # Critical damping ratio ",
- "m=0.005 # mass",
- "k=50.0 # spring constant",
- "",
- "#calculation",
- "w=math.sqrt((k/m)-(C/(2*m))**2)",
- "",
- "#result",
- "print('(a)\\nw=%.1f rad/s' %w)",
- "",
- "#(b)",
- "",
- "#variable Declaration",
- "w1=250.0 # angular velocity",
- "",
- "#calculation",
- "theta=C*w1/(k-m*w1**2)",
- "print('\\ntheta=%f' %theta)",
- "fi=math.atan(-theta)",
- "fi=fi*180.0/math.pi",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "import math\n",
+ "\n",
+ "#variable Declaration\n",
+ "Cc=1.0 # damping ratio \n",
+ "C=0.7*Cc # Critical damping ratio \n",
+ "m=0.005 # mass\n",
+ "k=50.0 # spring constant\n",
+ "\n",
+ "#calculation\n",
+ "w=math.sqrt((k/m)-(C/(2*m))**2)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nw=%.1f rad/s' %w)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable Declaration\n",
+ "w1=250.0 # angular velocity\n",
+ "\n",
+ "#calculation\n",
+ "theta=C*w1/(k-m*w1**2)\n",
+ "print('\\ntheta=%f' %theta)\n",
+ "fi=math.atan(-theta)\n",
+ "fi=fi*180.0/math.pi\n",
+ "\n",
+ "#result\n",
"print('\\nfi = %d\u00b0'%fi)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "w=71.4 rad/s",
- "",
- "theta=-0.666667",
- "",
+ "(a)\n",
+ "w=71.4 rad/s\n",
+ "\n",
+ "theta=-0.666667\n",
+ "\n",
"fi = 33\u00b0"
]
}
- ],
+ ],
"prompt_number": 2
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.3, PAge Number: 210<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''time calculation for exponetial transient term'''",
- "import math",
- "",
- "#variable Declaration",
- "m=0.005 # mass ",
- "c=0.7 # damping ratio",
- "",
- "#calculation",
- "y=-math.log(0.01)",
- "t=y*2*m/c",
- "",
- "#result",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable Declaration\n",
+ "m=0.005 # mass \n",
+ "c=0.7 # damping ratio\n",
+ "\n",
+ "#calculation\n",
+ "y=-math.log(0.01)\n",
+ "t=y*2*m/c\n",
+ "\n",
+ "#result\n",
"print('t=%.4f Secs' %t)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"t=0.0658 Secs"
]
}
- ],
+ ],
"prompt_number": 3
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.4, Page Number:210<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Acceleration measurement'''",
- "",
- "#variable Declaration",
- "rg1=1200.0 #resistance in Ohm",
- "rg2=1200.0 #resistance in Ohm",
- "rg3=1200.0 #resistance in Ohm",
- "rg4=1200.0 #resistance in Ohm",
- "",
- "#calculation",
- "D1=rg1*5.0/100.0",
- "D2=rg2*5.0/100.0",
- "D3=rg3*5.0/100.0",
- "D4=rg4*5.0/100.0",
- "E=12.0",
- "v=E*(((rg1+D1)/(rg1+D1+rg2-D2))-((rg4-D4)/(rg3+D3+rg4-D4)))",
- "v=v*1000.0",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable Declaration\n",
+ "rg1=1200.0 #resistance in Ohm\n",
+ "rg2=1200.0 #resistance in Ohm\n",
+ "rg3=1200.0 #resistance in Ohm\n",
+ "rg4=1200.0 #resistance in Ohm\n",
+ "\n",
+ "#calculation\n",
+ "D1=rg1*5.0/100.0\n",
+ "D2=rg2*5.0/100.0\n",
+ "D3=rg3*5.0/100.0\n",
+ "D4=rg4*5.0/100.0\n",
+ "E=12.0\n",
+ "v=E*(((rg1+D1)/(rg1+D1+rg2-D2))-((rg4-D4)/(rg3+D3+rg4-D4)))\n",
+ "v=v*1000.0\n",
+ "\n",
+ "#result\n",
"print('V0=%d mV' %v)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V0=600 mV"
]
}
- ],
+ ],
"prompt_number": 4
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.5, Page Number:211<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''output voltage of quartz piezoelectric crystal'''",
- "",
- "#variable declaration",
- "g=0.06 # voltage sensitivity",
- "",
- "#calculation",
- "t=2.5*10**-3",
- "p=20*9.8*10**4",
- "E=g*t*p",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "g=0.06 # voltage sensitivity\n",
+ "\n",
+ "#calculation\n",
+ "t=2.5*10**-3\n",
+ "p=20*9.8*10**4\n",
+ "E=g*t*p\n",
+ "\n",
+ "#Result\n",
"print('E=%d V' %E)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"E=294 V"
]
}
- ],
+ ],
"prompt_number": 5
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.6, Page Number: 211<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Differential values of capacitor'''",
- "",
- "#resistance in Ohm",
- "c0=25.0 # capacitance in pF",
- "x0=0.5 # distance between plates",
- "x1=0.05 # steady state displacement ",
- "",
- "#calculations",
- "c1=c0*x0/(x0-x1)",
- "c2=c0*x0/(x0+x1)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#resistance in Ohm\n",
+ "c0=25.0 # capacitance in pF\n",
+ "x0=0.5 # distance between plates\n",
+ "x1=0.05 # steady state displacement \n",
+ "\n",
+ "#calculations\n",
+ "c1=c0*x0/(x0-x1)\n",
+ "c2=c0*x0/(x0+x1)\n",
+ "\n",
+ "#result\n",
"print('C1=%.2f pF\\nC2=%.2f pF'%(c1,c2))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "C1=27.78 pF",
+ "C1=27.78 pF\n",
"C2=22.73 pF"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.7, Page Number: 211<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Specific Gravity Conversion'''",
- "",
- "#(a)",
- "",
- "#Specific gravity at 60 degree F",
- "sg_at_60=1.02",
- "",
- "#calculation",
- "API=(141.5/sg_at_60)-131.5",
- "",
- "#result",
- "print('(a)\\nDegrees API = %.2f\u00b0API' %API)",
- "",
- "#(b)",
- "",
- "#calculation",
- "Be=145-145/sg_at_60",
- "",
- "#result",
- "print('\\n(b)\\nDegrees Baume(heavy) = %.1f\u00b0Be' %Be)",
- "",
- "",
- "#(c)",
- "",
- "#calculation",
- "Bk=(sg_at_60-1)*1000",
- "",
- "#result",
- "print('\\n(c)\\nDegrees Barkometer = %d\u00b0Bk' %Bk)",
- "",
- "#(d)",
- "",
- "#calculation",
- "Q=(sg_at_60-1)*1000",
- "",
- "#result",
- "print('\\n(c)\\nDegrees Quevenne = %d\u00b0Q' %Q)",
- "",
- "#(e)",
- "",
- "#calculation",
- "Tw=200*(sg_at_60-1.0)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#Specific gravity at 60 degree F\n",
+ "sg_at_60=1.02\n",
+ "\n",
+ "#calculation\n",
+ "API=(141.5/sg_at_60)-131.5\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nDegrees API = %.2f\u00b0API' %API)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#calculation\n",
+ "Be=145-145/sg_at_60\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nDegrees Baume(heavy) = %.1f\u00b0Be' %Be)\n",
+ "\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#calculation\n",
+ "Bk=(sg_at_60-1)*1000\n",
+ "\n",
+ "#result\n",
+ "print('\\n(c)\\nDegrees Barkometer = %d\u00b0Bk' %Bk)\n",
+ "\n",
+ "#(d)\n",
+ "\n",
+ "#calculation\n",
+ "Q=(sg_at_60-1)*1000\n",
+ "\n",
+ "#result\n",
+ "print('\\n(c)\\nDegrees Quevenne = %d\u00b0Q' %Q)\n",
+ "\n",
+ "#(e)\n",
+ "\n",
+ "#calculation\n",
+ "Tw=200*(sg_at_60-1.0)\n",
+ "\n",
+ "#result\n",
"print('\\n(d)\\nDegrees Twaddel = %d\u00b0Tw' %Tw)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Degrees API = 7.23\u00b0API",
- "",
- "(b)",
- "Degrees Baume(heavy) = 2.8\u00b0Be",
- "",
- "(c)",
- "Degrees Barkometer = 20\u00b0Bk",
- "",
- "(c)",
- "Degrees Quevenne = 20\u00b0Q",
- "",
- "(d)",
+ "(a)\n",
+ "Degrees API = 7.23\u00b0API\n",
+ "\n",
+ "(b)\n",
+ "Degrees Baume(heavy) = 2.8\u00b0Be\n",
+ "\n",
+ "(c)\n",
+ "Degrees Barkometer = 20\u00b0Bk\n",
+ "\n",
+ "(c)\n",
+ "Degrees Quevenne = 20\u00b0Q\n",
+ "\n",
+ "(d)\n",
"Degrees Twaddel = 4\u00b0Tw"
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.8, Page NUmber: 212<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of the volume of displacer'''",
- "",
- "import math",
- "",
- "#variable Declaration",
- "T=0.5 # Torque Tube Force",
- "sg1=1.02 # Maximum spe.gravity to be measured",
- "sg2=0.98 # Minimum spe.gravity to be measured",
- "wt=1000*10**-6",
- "",
- "#calculation",
- "v=T/((sg1-sg2)*wt)",
- "v=math.ceil(v)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable Declaration\n",
+ "T=0.5 # Torque Tube Force\n",
+ "sg1=1.02 # Maximum spe.gravity to be measured\n",
+ "sg2=0.98 # Minimum spe.gravity to be measured\n",
+ "wt=1000*10**-6\n",
+ "\n",
+ "#calculation\n",
+ "v=T/((sg1-sg2)*wt)\n",
+ "v=math.ceil(v)\n",
+ "\n",
+ "#result\n",
"print('V=%d cm^3' %v)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V=12500 cm^3"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.9, Page Number: 212<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Differential pressure Sensor'''",
- "",
- "import math",
- "",
- "#variavle declaration",
- "sg1=0.85 # Maximum spe.gravity to be measured",
- "sg2=0.8 # Minimum spe.gravity to be measured",
- "span=150.0 # D/P cell span",
- "",
- "",
- "#a",
- "",
- "#calculation",
- "H=span/(sg1-sg2)",
- "",
- "#result",
- "print('(a)\\nH=%d mm = %dm' %(H,H/1000))",
- "",
- "#b",
- "",
- "#calculation",
- "span_min=1500.0",
- "span2=span_min*(sg1-sg2)",
- "span2=math.ceil(span2)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variavle declaration\n",
+ "sg1=0.85 # Maximum spe.gravity to be measured\n",
+ "sg2=0.8 # Minimum spe.gravity to be measured\n",
+ "span=150.0 # D/P cell span\n",
+ "\n",
+ "\n",
+ "#a\n",
+ "\n",
+ "#calculation\n",
+ "H=span/(sg1-sg2)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nH=%d mm = %dm' %(H,H/1000))\n",
+ "\n",
+ "#b\n",
+ "\n",
+ "#calculation\n",
+ "span_min=1500.0\n",
+ "span2=span_min*(sg1-sg2)\n",
+ "span2=math.ceil(span2)\n",
+ "\n",
+ "#result\n",
"print('\\n(b)\\nD/P span = %d mm' %span2)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "H=3000 mm = 3m",
- "",
- "(b)",
+ "(a)\n",
+ "H=3000 mm = 3m\n",
+ "\n",
+ "(b)\n",
"D/P span = 75 mm"
]
}
- ],
+ ],
"prompt_number": 9
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.10, Page Number:212<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Specific Gravity of unknown liquid'''",
- "",
- "#variable declaration",
- "Ww=12-2 # Width of water",
- "dw=1000.0 # density of water",
- "",
- "#calculation",
- "v=Ww/dw",
- "dx=(10-2)/v",
- "sg=dx/dw ",
- "",
- "#result",
+ "\n",
+ "#variable declaration\n",
+ "Ww=12-2 # Width of water\n",
+ "dw=1000.0 # density of water\n",
+ "\n",
+ "#calculation\n",
+ "v=Ww/dw\n",
+ "dx=(10-2)/v\n",
+ "sg=dx/dw \n",
+ "\n",
+ "#result\n",
"print('Specific Gravity of X =%.1f' %sg)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Specific Gravity of X =0.8"
]
}
- ],
+ ],
"prompt_number": 10
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 4.11, PAge Number: 213<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of specific gravity'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "wt=1.5 # weight of object",
- " ",
- "#calculation",
- "v_obj=2.0/1000",
- "dx=wt/v_obj",
- "sg=dx/1000",
- "",
- "#result",
- "print('(a)\\nSpecific Gravity = %.2f' %sg)",
- "",
- "#(b)",
- "",
- "sgl=0.8 # specific grav of liquid",
- "dens=800.0 # density",
- "",
- "#calculation",
- "W1=dens*v_obj-wt",
- "",
- "#result",
- "print('\\n(b)\\nW1 = %.1f kg' %W1)",
- "",
- "",
- "#(c)",
- "",
- "#variable declaration",
- "sg2=1.2 # spe. grav.",
- "dens2=1200.0 # density",
- "",
- "#calculation",
- "W2=dens2*v_obj-wt",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "wt=1.5 # weight of object\n",
+ " \n",
+ "#calculation\n",
+ "v_obj=2.0/1000\n",
+ "dx=wt/v_obj\n",
+ "sg=dx/1000\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nSpecific Gravity = %.2f' %sg)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "sgl=0.8 # specific grav of liquid\n",
+ "dens=800.0 # density\n",
+ "\n",
+ "#calculation\n",
+ "W1=dens*v_obj-wt\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nW1 = %.1f kg' %W1)\n",
+ "\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#variable declaration\n",
+ "sg2=1.2 # spe. grav.\n",
+ "dens2=1200.0 # density\n",
+ "\n",
+ "#calculation\n",
+ "W2=dens2*v_obj-wt\n",
+ "\n",
+ "#result\n",
"print('\\n(c)\\nW2 = %.1f kg' %W2)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Specific Gravity = 0.75",
- "",
- "(b)",
- "W1 = 0.1 kg",
- "",
- "(c)",
+ "(a)\n",
+ "Specific Gravity = 0.75\n",
+ "\n",
+ "(b)\n",
+ "W1 = 0.1 kg\n",
+ "\n",
+ "(c)\n",
"W2 = 0.9 kg"
]
}
- ],
+ ],
"prompt_number": 11
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/Chapter_5.ipynb b/Industrial_Instrumentation/Chapter_5.ipynb
index fa1d0762..4ec568e3 100644
--- a/Industrial_Instrumentation/Chapter_5.ipynb
+++ b/Industrial_Instrumentation/Chapter_5.ipynb
@@ -1,874 +1,918 @@
{
"metadata": {
- "name": "Chapter_5"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:6f1ee33190d8c693b6015349dc3ea8fa65731657e9afb9deaa10542a8aa4bde7"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter 5: Flow <h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.1, Page Number: 310<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''flow rate calulation'''",
- "",
- "import math",
- "#(i)",
- "",
- "#variable declaration",
- "d=75.0*10**-3 # diameter of pipe",
- "a=math.pi*d**2/4 # area of cross section of pipe",
- "v=760.0*10**-3 # flow velocity",
- "",
- "#calculation",
- "Q=v*a",
- "Q=Q*10**3",
- "print('(i)\\nVolume Flow Rate Q=%.3f *10^-3 m^3/sec' %Q)",
- "rho=1000.0",
- "W=rho*Q*10**-3",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "#(i)\n",
+ "\n",
+ "#variable declaration\n",
+ "d=75.0*10**-3 # diameter of pipe\n",
+ "a=math.pi*d**2/4 # area of cross section of pipe\n",
+ "v=760.0*10**-3 # flow velocity\n",
+ "\n",
+ "#calculation\n",
+ "Q=v*a\n",
+ "Q=Q*10**3\n",
+ "print('(i)\\nVolume Flow Rate Q=%.3f *10^-3 m^3/sec' %Q)\n",
+ "rho=1000.0\n",
+ "W=rho*Q*10**-3\n",
+ "\n",
+ "#result\n",
"print('\\n(ii)\\nMass Flow rate W=%.3f kg/sec' %W)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(i)",
- "Volume Flow Rate Q=3.358 *10^-3 m^3/sec",
- "",
- "(ii)",
+ "(i)\n",
+ "Volume Flow Rate Q=3.358 *10^-3 m^3/sec\n",
+ "\n",
+ "(ii)\n",
"Mass Flow rate W=3.358 kg/sec"
]
}
- ],
+ ],
"prompt_number": 1
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.2, page Number:310<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Volumetric flow rate calculation'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "D=40.0 # Diameter of pipe",
- "d=20.0 # Diameter of Orifice",
- "mr=15.0 # Manometer reading",
- "",
- "#calculation",
- "h=(13.6-1)*15.0*10.0",
- "B=d/D",
- "M=1/math.sqrt(1-(B**4))",
- "Cd=0.5999",
- "x=math.sqrt(2*9.8*h*(10**-3))",
- "Q=x*Cd*M*(math.pi*((20*(10**-3))**2))/4",
- "Q=Q*3600.0",
- "",
- "#result",
- "print('Volumetric flow rate Q= %.4f m^3/hr' %Q)",
- "#Answer slightly deviates from answer given in the book because of pi value.",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "D=40.0 # Diameter of pipe\n",
+ "d=20.0 # Diameter of Orifice\n",
+ "mr=15.0 # Manometer reading\n",
+ "\n",
+ "#calculation\n",
+ "h=(13.6-1)*15.0*10.0\n",
+ "B=d/D\n",
+ "M=1/math.sqrt(1-(B**4))\n",
+ "Cd=0.5999\n",
+ "x=math.sqrt(2*9.8*h*(10**-3))\n",
+ "Q=x*Cd*M*(math.pi*((20*(10**-3))**2))/4\n",
+ "Q=Q*3600.0\n",
+ "\n",
+ "#result\n",
+ "print('Volumetric flow rate Q= %.4f m^3/hr' %Q)\n",
+ "#Answer slightly deviates from answer given in the book because of pi value.\n",
"#if pi=3.14, then answer is same as in textbook "
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Volumetric flow rate Q= 4.2649 m^3/hr"
]
}
- ],
+ ],
"prompt_number": 2
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.3, Page Number: 310<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Nominal flow velocity'''",
- "",
- "import math",
- "#variable declaration",
- "Re=10.0**5 # Reynolds number",
- "D=40.0*10**-3 # Diameter of pipe ",
- "v=10**-6 # Kinematic viscosity in m^2/sec",
- "",
- "#calculation",
- "V1=Re*v/D",
- "A1=(math.pi*(40.0*10**-3)**2)/4",
- "A2=(math.pi*(20.0*10**-3)**2)/4",
- "V2=V1*A1/A2",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "#variable declaration\n",
+ "Re=10.0**5 # Reynolds number\n",
+ "D=40.0*10**-3 # Diameter of pipe \n",
+ "v=10**-6 # Kinematic viscosity in m^2/sec\n",
+ "\n",
+ "#calculation\n",
+ "V1=Re*v/D\n",
+ "A1=(math.pi*(40.0*10**-3)**2)/4\n",
+ "A2=(math.pi*(20.0*10**-3)**2)/4\n",
+ "V2=V1*A1/A2\n",
+ "\n",
+ "#result\n",
"print('V2=%.1f m/sec' %V2)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V2=10.0 m/sec"
]
}
- ],
+ ],
"prompt_number": 3
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.4, Page Number: 311<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''pressure difference calculation'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "Cd=0.61 # discharge coefficient",
- "D=40.0*10**-3 # Diameter of pipe",
- "d=20.0*10**-3 # Diameter of Orifice ",
- "",
- "#calculation",
- "M=1/math.sqrt(1-(d/D)**4)",
- "V2=10.0",
- "rho=1000.0",
- "g=9.8",
- "X=V2*math.sqrt(rho/(2*g))/(Cd*M)",
- "p_diff=X**2",
- "p_diff=math.floor(p_diff/100)",
- "p_diff=p_diff/100.0",
- "",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "Cd=0.61 # discharge coefficient\n",
+ "D=40.0*10**-3 # Diameter of pipe\n",
+ "d=20.0*10**-3 # Diameter of Orifice \n",
+ "\n",
+ "#calculation\n",
+ "M=1/math.sqrt(1-(d/D)**4)\n",
+ "V2=10.0\n",
+ "rho=1000.0\n",
+ "g=9.8\n",
+ "X=V2*math.sqrt(rho/(2*g))/(Cd*M)\n",
+ "p_diff=X**2\n",
+ "p_diff=math.floor(p_diff/100)\n",
+ "p_diff=p_diff/100.0\n",
+ "\n",
+ "\n",
+ "#result\n",
"print('P1-P2 = %.2f kg/cm^2'%p_diff)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"P1-P2 = 1.28 kg/cm^2"
]
}
- ],
+ ],
"prompt_number": 4
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.5, Page Number: 312<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''volume flow rate for orifice and venturi Tubes'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "Cd=0.6 # discharge coefficient",
- "D=150.0*10**-3 # Diameter of pipe",
- "d=75.0*10**-3 # Diameter of Orifice ",
- "p=250.0 # pressure recorded",
- "g=9.8 # acceleration due to gravity",
- "rho=1000.0 # Water density ",
- "s=75.0*10**-3 # venturi tube size",
- "",
- "#(a)",
- "",
- "#calculation",
- "Q=Cd*math.pi*s**2*math.sqrt(2*g*p/rho)/(4*math.sqrt(1-(d/D)**4)) ",
- "",
- "#result",
- "print('(a) For orifice plate\\nQ=%f m^3/sec = %.3f litres/sec'%(Q,Q*1000))",
- "",
- "#calculation",
- "Cd1=0.99",
- "Q2=Cd1*math.pi*s**2*math.sqrt(2*g*p/rho)/(4*math.sqrt(1-(d/D)**4))",
- "",
- "#result",
- "print('\\n\\n(b)For venturi tube\\nQ=%f m^3/sec = %.2f litres/sec'%(Q2,Q2*1000))",
- "#Answer slightly deviates from answer given in the book because of pi value.",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "Cd=0.6 # discharge coefficient\n",
+ "D=150.0*10**-3 # Diameter of pipe\n",
+ "d=75.0*10**-3 # Diameter of Orifice \n",
+ "p=250.0 # pressure recorded\n",
+ "g=9.8 # acceleration due to gravity\n",
+ "rho=1000.0 # Water density \n",
+ "s=75.0*10**-3 # venturi tube size\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#calculation\n",
+ "Q=Cd*math.pi*s**2*math.sqrt(2*g*p/rho)/(4*math.sqrt(1-(d/D)**4)) \n",
+ "\n",
+ "#result\n",
+ "print('(a) For orifice plate\\nQ=%f m^3/sec = %.3f litres/sec'%(Q,Q*1000))\n",
+ "\n",
+ "#calculation\n",
+ "Cd1=0.99\n",
+ "Q2=Cd1*math.pi*s**2*math.sqrt(2*g*p/rho)/(4*math.sqrt(1-(d/D)**4))\n",
+ "\n",
+ "#result\n",
+ "print('\\n\\n(b)For venturi tube\\nQ=%f m^3/sec = %.2f litres/sec'%(Q2,Q2*1000))\n",
+ "#Answer slightly deviates from answer given in the book because of pi value.\n",
"#if pi=3.14, then answer is same as in textbook "
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a) For orifice plate",
- "Q=0.006060 m^3/sec = 6.060 litres/sec",
- "",
- "",
- "(b)For venturi tube",
+ "(a) For orifice plate\n",
+ "Q=0.006060 m^3/sec = 6.060 litres/sec\n",
+ "\n",
+ "\n",
+ "(b)For venturi tube\n",
"Q=0.009999 m^3/sec = 10.00 litres/sec"
]
}
- ],
+ ],
"prompt_number": 5
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.6, Page Number: 312<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''determination of Reynolds number'''",
- "",
- "import math",
- "",
- "#(i)",
- "",
- "#variable declaration",
- "V=0.02 # volumetric flow rate",
- "d=10*10**-2 # Diameter of pipe",
- "",
- "#calculation",
- "A=math.pi*d**2/4",
- "v=V/A",
- "rho=1000.0",
- "Re=rho*v*d/10**-3",
- "Re=Re/100000.0",
- "",
- "#result",
- "print('(i)\\nReynolds number(Re) = %.3f * 10^5'%Re)",
- "",
- "#(ii)",
- "",
- "#variable declaration",
- "Cd=0.98 # discharge coefficient ",
- "D=20*10**-2 # Diameter of pipe ",
- "d=10*10**-2 # Diameter of orifice",
- "",
- "#calculation",
- "M=1/math.sqrt(1-(d/D)**4)",
- "a2=math.pi*d**2/4",
- "Q=0.02",
- "g=9.8",
- "X=Q*math.sqrt(rho)/(M*Cd*a2*math.sqrt(2*g))",
- "p_diff=math.ceil(X**2)",
- "",
- "#result",
- "print('\\n(ii)\\nPressur_difference = %d kg/m^2 = %.4f kg/cm^2'%(p_diff,p_diff/10000))",
- "#Answer slightly deviates from answer given in the book because of pi value.",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#(i)\n",
+ "\n",
+ "#variable declaration\n",
+ "V=0.02 # volumetric flow rate\n",
+ "d=10*10**-2 # Diameter of pipe\n",
+ "\n",
+ "#calculation\n",
+ "A=math.pi*d**2/4\n",
+ "v=V/A\n",
+ "rho=1000.0\n",
+ "Re=rho*v*d/10**-3\n",
+ "Re=Re/100000.0\n",
+ "\n",
+ "#result\n",
+ "print('(i)\\nReynolds number(Re) = %.3f * 10^5'%Re)\n",
+ "\n",
+ "#(ii)\n",
+ "\n",
+ "#variable declaration\n",
+ "Cd=0.98 # discharge coefficient \n",
+ "D=20*10**-2 # Diameter of pipe \n",
+ "d=10*10**-2 # Diameter of orifice\n",
+ "\n",
+ "#calculation\n",
+ "M=1/math.sqrt(1-(d/D)**4)\n",
+ "a2=math.pi*d**2/4\n",
+ "Q=0.02\n",
+ "g=9.8\n",
+ "X=Q*math.sqrt(rho)/(M*Cd*a2*math.sqrt(2*g))\n",
+ "p_diff=math.ceil(X**2)\n",
+ "\n",
+ "#result\n",
+ "print('\\n(ii)\\nPressur_difference = %d kg/m^2 = %.4f kg/cm^2'%(p_diff,p_diff/10000))\n",
+ "#Answer slightly deviates from answer given in the book because of pi value.\n",
"#if pi=3.14, then answer is same as in textbook "
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(i)",
- "Reynolds number(Re) = 2.546 * 10^5",
- "",
- "(ii)",
+ "(i)\n",
+ "Reynolds number(Re) = 2.546 * 10^5\n",
+ "\n",
+ "(ii)\n",
"Pressur_difference = 323 kg/m^2 = 0.0323 kg/cm^2"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.7, Page Number: 313<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Fluid velocity and Volumetric flow rate'''",
- "",
- "import math",
- "",
- "#1kg/m^2=10 meters water head",
- "",
- "#variable declaration",
- "g=9.81 #acceleration due to gravity",
- "h=20.0 #height",
- "",
- "#calculation",
- "v=math.sqrt(2*g*h)",
- "d=300.0*10**-3",
- "A=(math.pi*d**2)/4",
- "A=math.floor(A*1000)",
- "A=A/1000.0",
- "Q=A*v",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#1kg/m^2=10 meters water head\n",
+ "\n",
+ "#variable declaration\n",
+ "g=9.81 #acceleration due to gravity\n",
+ "h=20.0 #height\n",
+ "\n",
+ "#calculation\n",
+ "v=math.sqrt(2*g*h)\n",
+ "d=300.0*10**-3\n",
+ "A=(math.pi*d**2)/4\n",
+ "A=math.floor(A*1000)\n",
+ "A=A/1000.0\n",
+ "Q=A*v\n",
+ "\n",
+ "#result\n",
"print('Q = %.3f m^3/sec'%Q)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Q = 1.387 m^3/sec"
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.8, Page Number:313<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Fluid velocity calculation'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "Cd=0.6 # coefficient of discharge ",
- "g=9.8 #acceleration due to gravity",
- "h=400*10**-3 #height",
- "",
- "#calculation",
- "V=Cd*math.sqrt(2*g*h)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "Cd=0.6 # coefficient of discharge \n",
+ "g=9.8 #acceleration due to gravity\n",
+ "h=400*10**-3 #height\n",
+ "\n",
+ "#calculation\n",
+ "V=Cd*math.sqrt(2*g*h)\n",
+ "\n",
+ "#result\n",
"print('V = %.2f m/sec' %V)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V = 1.68 m/sec"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.9, Page Number: 314<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''velocity measurement using pilot tube'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "Cd=0.98 # coefficient of discharge",
- "g=9.8 #acceleration due to gravity",
- "h=900.0*10**-3 #height",
- "",
- "#calculation",
- "V=Cd*math.sqrt(2*g*h)",
- "V=math.floor(V*100)",
- "V=(V/100.0)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "Cd=0.98 # coefficient of discharge\n",
+ "g=9.8 #acceleration due to gravity\n",
+ "h=900.0*10**-3 #height\n",
+ "\n",
+ "#calculation\n",
+ "V=Cd*math.sqrt(2*g*h)\n",
+ "V=math.floor(V*100)\n",
+ "V=(V/100.0)\n",
+ "\n",
+ "#result\n",
"print('V = %.2f m/sec' %V)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V = 4.11 m/sec"
]
}
- ],
+ ],
"prompt_number": 9
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.10, Page Number:314<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Determination of flow velocity'''",
- "",
- "import math",
- "",
- "#Variable declaration",
- "del_p=20*10**3 #Pa",
- "dens_water=1000 #kg/m^3",
- "dens_air=1.29 #kg/m^3",
- "",
- "#calculations",
- "",
- "#(i)When flowing fluid is water",
- "v=math.sqrt(2*del_p/dens_water)",
- "",
- "#(ii)When flowing fluid is air",
- "v1=math.sqrt(2*del_p/dens_air)",
- "",
- "#result",
- "print('\\n(i)When flowing fluid is water\\n\\tV=%.3f m/sec'%v)",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#Variable declaration\n",
+ "del_p=20*10**3 #Pa\n",
+ "dens_water=1000 #kg/m^3\n",
+ "dens_air=1.29 #kg/m^3\n",
+ "\n",
+ "#calculations\n",
+ "\n",
+ "#(i)When flowing fluid is water\n",
+ "v=math.sqrt(2*del_p/dens_water)\n",
+ "\n",
+ "#(ii)When flowing fluid is air\n",
+ "v1=math.sqrt(2*del_p/dens_air)\n",
+ "\n",
+ "#result\n",
+ "print('\\n(i)When flowing fluid is water\\n\\tV=%.3f m/sec'%v)\n",
"print('\\n(ii)When flowing fluid is air\\n\\tV=%.0f m/sec'%v1)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "",
- "(i)When flowing fluid is water",
- "\tV=6.325 m/sec",
- "",
- "(ii)When flowing fluid is air",
+ "\n",
+ "(i)When flowing fluid is water\n",
+ "\tV=6.325 m/sec\n",
+ "\n",
+ "(ii)When flowing fluid is air\n",
"\tV=176 m/sec"
]
}
- ],
+ ],
"prompt_number": 10
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.11, Page Number: 314<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''detemination of flow velocity'''",
- "",
- "import math",
- "",
- "# variable declaration",
- "dens=1026.0 # density of see water",
- "p=25.0*10**3 # pressure difference in manometer ",
- "",
- "#calculation",
- "V=math.sqrt(2*p/dens)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "# variable declaration\n",
+ "dens=1026.0 # density of see water\n",
+ "p=25.0*10**3 # pressure difference in manometer \n",
+ "\n",
+ "#calculation\n",
+ "V=math.sqrt(2*p/dens)\n",
+ "\n",
+ "#result\n",
"print('V=%.2f m/sec =%.3f km/hr'%(V,V*18/5))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V=6.98 m/sec =25.131 km/hr"
]
}
- ],
+ ],
"prompt_number": 11
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.12, Page Number: 314<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of flying speed of aircraft'''",
- "import math",
- "",
- "# variable declaration",
- "dens=1.29 # air density at height ",
- "",
- "#calculation",
- "p=12.5*1000",
- "V=math.sqrt(2*p/dens)",
- "",
- "",
- "#result",
+ "\n",
+ "import math\n",
+ "\n",
+ "# variable declaration\n",
+ "dens=1.29 # air density at height \n",
+ "\n",
+ "#calculation\n",
+ "p=12.5*1000\n",
+ "V=math.sqrt(2*p/dens)\n",
+ "\n",
+ "\n",
+ "#result\n",
"print('V=%.2f m/sec =%.2f km/hr'%(V,V*18/5))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V=139.21 m/sec =501.16 km/hr"
]
}
- ],
+ ],
"prompt_number": 12
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.13, Page Number: 315<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Maximum fluid handling capacity of Rotameter'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "Cd=0.6 # discharge coefficient",
- "Dp=0.05 # inside diameter of metering tube ",
- "Df=0.035 # diameter of rotameter ",
- "g=9.8 # acceleration due to gravity",
- "rho_f=3.9*10**3 # density of cylindrical float",
- "rho=1000.0 # water density ",
- "Vf=3.36*10**-5 # volume of the float",
- "",
- "#calculation",
- "Q=Cd*((Dp**2-Df**2)/Df)*math.sqrt(math.pi*g*Vf*(rho_f-rho)/(2*rho))",
- "Q=Q*10000.0",
- "",
- "#result",
- "print('Volumetric flow Q=%.4f *10^-4 m^3/sec' %Q)",
- "#Answer slightly deviates from answer given in the book because of pi value.",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "Cd=0.6 # discharge coefficient\n",
+ "Dp=0.05 # inside diameter of metering tube \n",
+ "Df=0.035 # diameter of rotameter \n",
+ "g=9.8 # acceleration due to gravity\n",
+ "rho_f=3.9*10**3 # density of cylindrical float\n",
+ "rho=1000.0 # water density \n",
+ "Vf=3.36*10**-5 # volume of the float\n",
+ "\n",
+ "#calculation\n",
+ "Q=Cd*((Dp**2-Df**2)/Df)*math.sqrt(math.pi*g*Vf*(rho_f-rho)/(2*rho))\n",
+ "Q=Q*10000.0\n",
+ "\n",
+ "#result\n",
+ "print('Volumetric flow Q=%.4f *10^-4 m^3/sec' %Q)\n",
+ "#Answer slightly deviates from answer given in the book because of pi value.\n",
"#if pi=3.14, then answer is same as in textbook "
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Volumetric flow Q=8.4652 *10^-4 m^3/sec"
]
}
- ],
+ ],
"prompt_number": 13
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.14, Page number: 315<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Determination of range of flow for ratameter'''",
- "",
- "import math",
- "# variable declaration",
- "Cd=1 # discharge coefficient",
- "Dp=0.018 # inside diameter of metering tube ",
- "Df=0.015 # diameter of rotameter ",
- "g=9.81 # acceleration due to gravity",
- "rho_f=2.7 # density of cylindrical float",
- "rho=0.8 # water density ",
- "Vf=520.0*10**-9 # volume of the float",
- "",
- "#case 1",
- "",
- "#caculation",
- "Qmin=Cd*((Dp**2-Df**2)/Df)*math.sqrt(math.pi*g*Vf*(rho_f-rho)/(2*rho))",
- "Qmin=Qmin*100000.0",
- "",
- "#result",
- "print('Case 1: When float is at the bottom\\n Volumetric flow Qmin=%.3f *10^-5 m^3/sec'%Qmin)",
- "",
- "#case 2",
- "",
- "#calculation",
- "Dp2=0.0617",
- "Qmax=Cd*((Dp2**2-Df**2)/Df)*math.sqrt(math.pi*g*Vf*(rho_f-rho)/(2*rho))",
- "Qmax=Qmax*100000",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "# variable declaration\n",
+ "Cd=1 # discharge coefficient\n",
+ "Dp=0.018 # inside diameter of metering tube \n",
+ "Df=0.015 # diameter of rotameter \n",
+ "g=9.81 # acceleration due to gravity\n",
+ "rho_f=2.7 # density of cylindrical float\n",
+ "rho=0.8 # water density \n",
+ "Vf=520.0*10**-9 # volume of the float\n",
+ "\n",
+ "#case 1\n",
+ "\n",
+ "#caculation\n",
+ "Qmin=Cd*((Dp**2-Df**2)/Df)*math.sqrt(math.pi*g*Vf*(rho_f-rho)/(2*rho))\n",
+ "Qmin=Qmin*100000.0\n",
+ "\n",
+ "#result\n",
+ "print('Case 1: When float is at the bottom\\n Volumetric flow Qmin=%.3f *10^-5 m^3/sec'%Qmin)\n",
+ "\n",
+ "#case 2\n",
+ "\n",
+ "#calculation\n",
+ "Dp2=0.0617\n",
+ "Qmax=Cd*((Dp2**2-Df**2)/Df)*math.sqrt(math.pi*g*Vf*(rho_f-rho)/(2*rho))\n",
+ "Qmax=Qmax*100000\n",
+ "\n",
+ "#result\n",
"print('\\n\\nCase 2: When float is at the bottom\\n Volumetric flow Qmax=%.2f *10^-5 m^3/sec'%Qmax)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "Case 1: When float is at the bottom",
- " Volumetric flow Qmin=2.879 *10^-5 m^3/sec",
- "",
- "",
- "Case 2: When float is at the bottom",
+ "Case 1: When float is at the bottom\n",
+ " Volumetric flow Qmin=2.879 *10^-5 m^3/sec\n",
+ "\n",
+ "\n",
+ "Case 2: When float is at the bottom\n",
" Volumetric flow Qmax=104.17 *10^-5 m^3/sec"
]
}
- ],
+ ],
"prompt_number": 14
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.15, Page Number:316<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of coal delivery for coal conveyor system'''",
- "",
- "# variable declaration",
- "W=165.0 # weight of material on section of length",
- "R=328.0 # Conveyor speed m/min",
- "L=16.0 # Length of weighting platform in m",
- "",
- "#calculation",
- "Q=W*R/L",
- "",
- "#result",
+ "\n",
+ "\n",
+ "# variable declaration\n",
+ "W=165.0 # weight of material on section of length\n",
+ "R=328.0 # Conveyor speed m/min\n",
+ "L=16.0 # Length of weighting platform in m\n",
+ "\n",
+ "#calculation\n",
+ "Q=W*R/L\n",
+ "\n",
+ "#result\n",
"print('Flow Rate Q=%.2f kg/min =%.1f kg/hour'%(Q,Q/60))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Flow Rate Q=3382.50 kg/min =56.4 kg/hour"
]
}
- ],
+ ],
"prompt_number": 15
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.16, Page Number:316<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Fluid velocity calculation'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "f=100.0 # beat frequency",
- "d=300.0*10**-3 # Sound path",
- "a=45.0 #angle between transmeter and receiver in degrees",
- "",
- "#calculation",
- "a_rad=45.0*math.pi/180.0",
- "v=f*d/(2*math.cos(a_rad))",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "f=100.0 # beat frequency\n",
+ "d=300.0*10**-3 # Sound path\n",
+ "a=45.0 #angle between transmeter and receiver in degrees\n",
+ "\n",
+ "#calculation\n",
+ "a_rad=45.0*math.pi/180.0\n",
+ "v=f*d/(2*math.cos(a_rad))\n",
+ "\n",
+ "#Result\n",
"print('Fluid Velocity V=%.1f m/sec'%v)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Fluid Velocity V=21.2 m/sec"
]
}
- ],
+ ],
"prompt_number": 16
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.17, Page Number: 316<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''volume flow rate'''",
- "",
- "# variable declaration",
- "r=150.0 # speed of rotation",
- "v=120.0 # volume trapped between gears and casting",
- "",
- "#clculation",
- "Q=4.0*v*r",
- "",
- "#result",
+ "\n",
+ "\n",
+ "# variable declaration\n",
+ "r=150.0 # speed of rotation\n",
+ "v=120.0 # volume trapped between gears and casting\n",
+ "\n",
+ "#clculation\n",
+ "Q=4.0*v*r\n",
+ "\n",
+ "#result\n",
"print('Volume flow rate Q=%d cm^3/min = %d litres/min'%(Q,Q/1000))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Volume flow rate Q=72000 cm^3/min = 72 litres/min"
]
}
- ],
+ ],
"prompt_number": 17
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.18, Page Number: 317<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''induced emf in electromagnetic flow meter'''",
- "",
- "import math",
- "",
- "# variable declaration",
- "Q=2500.0 # Quantitty flow rate",
- "d=2.75 # inner diameter",
- "",
- "#calculation",
- "a=(math.pi*d**2)/4",
- "v=Q/(60*a)",
- "B=60.0",
- "e=B*d*10**-2*v*10**-2",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "# variable declaration\n",
+ "Q=2500.0 # Quantitty flow rate\n",
+ "d=2.75 # inner diameter\n",
+ "\n",
+ "#calculation\n",
+ "a=(math.pi*d**2)/4\n",
+ "v=Q/(60*a)\n",
+ "B=60.0\n",
+ "e=B*d*10**-2*v*10**-2\n",
+ "\n",
+ "#result\n",
"print('Induced emf e =%.4f V=%.1f mV'%(e,e*1000))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Induced emf e =0.1157 V=115.7 mV"
]
}
- ],
+ ],
"prompt_number": 18
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.19, Pae Number:317<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''velocity of flow in electromagnetic flow meter'''",
- "",
- "# variable declaration",
- "e=0.2*10**-3 # voltage of electromagnetic flow meter",
- "B=0.08 # Flux density",
- "l=10.0*10**-2 # Diameter of pipe",
- "",
- "#calculation",
- "v=e/(B*l)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "# variable declaration\n",
+ "e=0.2*10**-3 # voltage of electromagnetic flow meter\n",
+ "B=0.08 # Flux density\n",
+ "l=10.0*10**-2 # Diameter of pipe\n",
+ "\n",
+ "#calculation\n",
+ "v=e/(B*l)\n",
+ "\n",
+ "#result\n",
"print('V = %.3f m/sec = %.2f cm/sec'%(v,v*100))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V = 0.025 m/sec = 2.50 cm/sec"
]
}
- ],
+ ],
"prompt_number": 19
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 5.20, Page Number: 317<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''average velocity of flow in electromagnetic flow meter'''",
- "",
- "# variable declaration",
- "ei=0.15*10**-3 # peak value",
- "em=2*ei # p-p amplifier output ",
- "B=0.1 # flux density",
- "l=60.0*10**-3 # diameter of the pipe",
- "",
- "#calculation",
- "v=em/(B*l)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "# variable declaration\n",
+ "ei=0.15*10**-3 # peak value\n",
+ "em=2*ei # p-p amplifier output \n",
+ "B=0.1 # flux density\n",
+ "l=60.0*10**-3 # diameter of the pipe\n",
+ "\n",
+ "#calculation\n",
+ "v=em/(B*l)\n",
+ "\n",
+ "#result\n",
"print('Velocity of flow V = %.2f m/sec = %.1f cm/sec'%(v,v*100))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Velocity of flow V = 0.05 m/sec = 5.0 cm/sec"
]
}
- ],
+ ],
"prompt_number": 20
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/Chapter_6.ipynb b/Industrial_Instrumentation/Chapter_6.ipynb
index d3a9a093..bdc5920d 100644
--- a/Industrial_Instrumentation/Chapter_6.ipynb
+++ b/Industrial_Instrumentation/Chapter_6.ipynb
@@ -1,534 +1,558 @@
{
"metadata": {
- "name": "Chapter_6"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:6148d2be2796832e7d2e9cefcc5c361a4c9dc07b22c355b627a74bd914199046"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter 6: Level<h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.1,Page Number:370<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''output current of two wire pressure transmitter'''",
- "",
- "#(a)",
- "",
- "# variable declaration",
- "p=1.5 # pressure applied",
- "a=4.0 # mA corresponds to 0 kg/cm^2",
- "b=20.0 # mA corresponds to 2 kg/cm^2",
- "",
- "#calculation",
- "wh=(((b-a)/2)*p)+a",
- "",
- "#result",
- "print('(a)just at the bottom level of the tank')",
- "print('Water head applied to the transmitter =%d mA'%wh)",
- "",
- "#(b)",
- "",
- "#calculation",
- "wh2=(((b-a)/2)*p)+2*a",
- "",
- "#result",
- "print('\\n\\n(b)5m below the bottom of the tank')",
- "print('Water head applied to the transmitter =%d mA' %wh2)",
- "",
- "#(c)",
- "",
- "#calculation",
- "wh3=(((b-a)/2)*p)",
- "",
- "#result",
- "print('\\n\\n(c)5m above the bottom of the tank')",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "# variable declaration\n",
+ "p=1.5 # pressure applied\n",
+ "a=4.0 # mA corresponds to 0 kg/cm^2\n",
+ "b=20.0 # mA corresponds to 2 kg/cm^2\n",
+ "\n",
+ "#calculation\n",
+ "wh=(((b-a)/2)*p)+a\n",
+ "\n",
+ "#result\n",
+ "print('(a)just at the bottom level of the tank')\n",
+ "print('Water head applied to the transmitter =%d mA'%wh)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#calculation\n",
+ "wh2=(((b-a)/2)*p)+2*a\n",
+ "\n",
+ "#result\n",
+ "print('\\n\\n(b)5m below the bottom of the tank')\n",
+ "print('Water head applied to the transmitter =%d mA' %wh2)\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#calculation\n",
+ "wh3=(((b-a)/2)*p)\n",
+ "\n",
+ "#result\n",
+ "print('\\n\\n(c)5m above the bottom of the tank')\n",
"print('Water head applied to the transmitter =%d mA'%wh3)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)just at the bottom level of the tank",
- "Water head applied to the transmitter =16 mA",
- "",
- "",
- "(b)5m below the bottom of the tank",
- "Water head applied to the transmitter =20 mA",
- "",
- "",
- "(c)5m above the bottom of the tank",
+ "(a)just at the bottom level of the tank\n",
+ "Water head applied to the transmitter =16 mA\n",
+ "\n",
+ "\n",
+ "(b)5m below the bottom of the tank\n",
+ "Water head applied to the transmitter =20 mA\n",
+ "\n",
+ "\n",
+ "(c)5m above the bottom of the tank\n",
"Water head applied to the transmitter =12 mA"
]
}
- ],
+ ],
"prompt_number": 1
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.2, Page Number:371<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''water level and current at different positions'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "b=20.0 # Maximum output",
- "a=4.0 # minimum output ",
- "op=16.0 # output in mA",
- "",
- "#calculation",
- "p=(op-a)*2/(b-a)",
- "p_h=p*10.0",
- "h=p_h-2-5",
- "",
- "#result",
- "print('(a)\\nh = %dm'%h)",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "p1=1 # pressure applied",
- "",
- "#calculation",
- "t_op=((b-a)/2)*p1+4",
- "",
- "#result",
- "print('\\n(b)\\nTransmitter output =%d mA'%t_op)",
- "",
- "#(c)",
- "",
- "#variable declaration",
- "p2=0.5 # applied pressure",
- "",
- "#calculation",
- "t_op1=((b-a)/2)*p2+4",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "b=20.0 # Maximum output\n",
+ "a=4.0 # minimum output \n",
+ "op=16.0 # output in mA\n",
+ "\n",
+ "#calculation\n",
+ "p=(op-a)*2/(b-a)\n",
+ "p_h=p*10.0\n",
+ "h=p_h-2-5\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nh = %dm'%h)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "p1=1 # pressure applied\n",
+ "\n",
+ "#calculation\n",
+ "t_op=((b-a)/2)*p1+4\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nTransmitter output =%d mA'%t_op)\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#variable declaration\n",
+ "p2=0.5 # applied pressure\n",
+ "\n",
+ "#calculation\n",
+ "t_op1=((b-a)/2)*p2+4\n",
+ "\n",
+ "#result\n",
"print('\\n(c)\\nTransmitter output =%d mA'%t_op1)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "h = 8m",
- "",
- "(b)",
- "Transmitter output =12 mA",
- "",
- "(c)",
+ "(a)\n",
+ "h = 8m\n",
+ "\n",
+ "(b)\n",
+ "Transmitter output =12 mA\n",
+ "\n",
+ "(c)\n",
"Transmitter output =8 mA"
]
}
- ],
+ ],
"prompt_number": 2
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.3, Page Number: 372<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Differential pressure output at different levels'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "b=20.0 # Maximum output",
- "a=4.0 # minimum output",
- "op=16.0 # actual output ",
- "wt_l1=25.0 # water level (i)",
- "",
- "#calculation",
- "t_op=((b-a)/100)*(100-75)+4",
- "",
- "#result",
- "print('(a)\\nWater level=+25cm\\nTransmitter output = %d mA' %t_op)",
- "",
- "#(b)",
- "",
- "#calculation",
- "wt_l2=-25.0 # water level (ii)",
- "t_op2=((b-a)/100)*(100-25)+4",
- "",
- "#result",
- "print('\\n(b)\\nWater level=-25cm\\nTransmitter output = %d mA' %t_op2)",
- "",
- "#(c)",
- "",
- "#Variable declaration",
- "t_op3=12.0 # Transmitter output ",
- "",
- "#calculation",
- "H=(100.0/(b-a))*(12-4) ",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "b=20.0 # Maximum output\n",
+ "a=4.0 # minimum output\n",
+ "op=16.0 # actual output \n",
+ "wt_l1=25.0 # water level (i)\n",
+ "\n",
+ "#calculation\n",
+ "t_op=((b-a)/100)*(100-75)+4\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nWater level=+25cm\\nTransmitter output = %d mA' %t_op)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#calculation\n",
+ "wt_l2=-25.0 # water level (ii)\n",
+ "t_op2=((b-a)/100)*(100-25)+4\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nWater level=-25cm\\nTransmitter output = %d mA' %t_op2)\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#Variable declaration\n",
+ "t_op3=12.0 # Transmitter output \n",
+ "\n",
+ "#calculation\n",
+ "H=(100.0/(b-a))*(12-4) \n",
+ "\n",
+ "#result\n",
"print('\\n(c)\\nHead Applied = %d cm\\nLevel corresponding to 50 cm head =0 cm' %H)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Water level=+25cm",
- "Transmitter output = 8 mA",
- "",
- "(b)",
- "Water level=-25cm",
- "Transmitter output = 16 mA",
- "",
- "(c)",
- "Head Applied = 50 cm",
+ "(a)\n",
+ "Water level=+25cm\n",
+ "Transmitter output = 8 mA\n",
+ "\n",
+ "(b)\n",
+ "Water level=-25cm\n",
+ "Transmitter output = 16 mA\n",
+ "\n",
+ "(c)\n",
+ "Head Applied = 50 cm\n",
"Level corresponding to 50 cm head =0 cm"
]
}
- ],
+ ],
"prompt_number": 3
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.4, Page Number: 373<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Displacer with spring balance'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "a=5.0*10**-4 #area",
- "l=8.0 #length",
- "dens=6.0*1000.0 #density",
- "",
- "#calculation",
- "w=a*l*dens",
- "",
- "#result",
- "print('(a)\\nWeight of the displacer if weighed in air = %d kg'%w)",
- "",
- "",
- "#(i)",
- "",
- "#variable declaration",
- "sbr1=23.0 # spring balance reading",
- "",
- "#calculation",
- "wloss1=w-sbr1",
- "L1=wloss1/(1000.0*a)",
- "",
- "#result",
- "print('\\n(i)\\tL1=%dm'%L1)",
- "",
- "",
- "#(ii)",
- "",
- "#variable declaration",
- "sbr2=22.0 # spring balance reading",
- "",
- "#calculation",
- "wloss2=w-sbr2",
- "L2=wloss2/(1000.0*a)",
- "",
- "#result",
- "print('\\n(ii)\\tL2=%dm'%L2)",
- "",
- "#(iii)",
- "",
- "#variable declaration",
- "sbr3=21.0 # spring balance reading",
- "",
- "#calculation",
- "wloss3=w-sbr3",
- "L3=wloss3/(1000.0*a)",
- "",
- "#result",
- "print('\\n(iii)\\tL3=%dm'%L3)",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "level=8.0 # level wen tank is full ",
- "",
- "#calculation",
- "wt=a*level*1000.0",
- "spring=w-wt",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "a=5.0*10**-4 #area\n",
+ "l=8.0 #length\n",
+ "dens=6.0*1000.0 #density\n",
+ "\n",
+ "#calculation\n",
+ "w=a*l*dens\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nWeight of the displacer if weighed in air = %d kg'%w)\n",
+ "\n",
+ "\n",
+ "#(i)\n",
+ "\n",
+ "#variable declaration\n",
+ "sbr1=23.0 # spring balance reading\n",
+ "\n",
+ "#calculation\n",
+ "wloss1=w-sbr1\n",
+ "L1=wloss1/(1000.0*a)\n",
+ "\n",
+ "#result\n",
+ "print('\\n(i)\\tL1=%dm'%L1)\n",
+ "\n",
+ "\n",
+ "#(ii)\n",
+ "\n",
+ "#variable declaration\n",
+ "sbr2=22.0 # spring balance reading\n",
+ "\n",
+ "#calculation\n",
+ "wloss2=w-sbr2\n",
+ "L2=wloss2/(1000.0*a)\n",
+ "\n",
+ "#result\n",
+ "print('\\n(ii)\\tL2=%dm'%L2)\n",
+ "\n",
+ "#(iii)\n",
+ "\n",
+ "#variable declaration\n",
+ "sbr3=21.0 # spring balance reading\n",
+ "\n",
+ "#calculation\n",
+ "wloss3=w-sbr3\n",
+ "L3=wloss3/(1000.0*a)\n",
+ "\n",
+ "#result\n",
+ "print('\\n(iii)\\tL3=%dm'%L3)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "level=8.0 # level wen tank is full \n",
+ "\n",
+ "#calculation\n",
+ "wt=a*level*1000.0\n",
+ "spring=w-wt\n",
+ "\n",
+ "#result\n",
"print('\\n(b):when the tank is full\\nSpring Balance reading = %d kg'%spring)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Weight of the displacer if weighed in air = 24 kg",
- "",
- "(i)\tL1=2m",
- "",
- "(ii)\tL2=4m",
- "",
- "(iii)\tL3=6m",
- "",
- "(b):when the tank is full",
+ "(a)\n",
+ "Weight of the displacer if weighed in air = 24 kg\n",
+ "\n",
+ "(i)\tL1=2m\n",
+ "\n",
+ "(ii)\tL2=4m\n",
+ "\n",
+ "(iii)\tL3=6m\n",
+ "\n",
+ "(b):when the tank is full\n",
"Spring Balance reading = 20 kg"
]
}
- ],
+ ],
"prompt_number": 4
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.5, Page Number: 374<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Buoyancy Force calculation'''",
- "",
- "#variable declaration",
- "rho=1000.0 # density of water ",
- "v=3.0 # displaced volume of water ",
- "",
- "#calculation",
- "Bw=rho*v",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "rho=1000.0 # density of water \n",
+ "v=3.0 # displaced volume of water \n",
+ "\n",
+ "#calculation\n",
+ "Bw=rho*v\n",
+ "\n",
+ "#Result\n",
"print('Buoyance Force(Bw) = %d kg'%Bw)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Buoyance Force(Bw) = 3000 kg"
]
}
- ],
+ ],
"prompt_number": 5
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.6, Page Number: 374<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Determination of displaced volume from Buoyancy Force'''",
- "",
- "#variable declaration",
- "rho=1000.0 # density of water",
- "Bw=5000.0 # Buoyancy Force",
- "",
- "#calculation",
- "v=Bw/rho",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "rho=1000.0 # density of water\n",
+ "Bw=5000.0 # Buoyancy Force\n",
+ "\n",
+ "#calculation\n",
+ "v=Bw/rho\n",
+ "\n",
+ "#result\n",
"print('V = %d m^3' %v)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"V = 5 m^3"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.7, Page Number: 374<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Determination of hydrostatic pressure in open tank'''",
- "",
- "#variable declaration",
- "rho=1000.0 # density of water",
- "h=10.0 # height of liquid",
- "",
- "#calculation",
- "P=rho*h",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "rho=1000.0 # density of water\n",
+ "h=10.0 # height of liquid\n",
+ "\n",
+ "#calculation\n",
+ "P=rho*h\n",
+ "\n",
+ "#result\n",
"print('P = %d kg/m^2 = %d kg/cm^2 '%(P,P/10000))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"P = 10000 kg/m^2 = 1 kg/cm^2 "
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.8, Page Number: 374<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Determination of hydrostatic pressure in closed tank'''",
- "",
- "#variable declaration",
- "rho=1000.0 # density of water",
- "h=15.0 # height of liquid ",
- "ex_p=1.0 # External pressure on liquid",
- "",
- "#calculation",
- "P=(rho*h/10000.0)+ex_p",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "rho=1000.0 # density of water\n",
+ "h=15.0 # height of liquid \n",
+ "ex_p=1.0 # External pressure on liquid\n",
+ "\n",
+ "#calculation\n",
+ "P=(rho*h/10000.0)+ex_p\n",
+ "\n",
+ "#result\n",
"print('P = %.1f kg/cm^2' %P)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"P = 2.5 kg/cm^2"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.9, Page Number:374<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Determination of height from hydrostatic pressure'''",
- "",
- "#variable declaration",
- "rho=1000.0 # density of water",
- "ex_p=0.5*10**4 # External pressure on liquid ",
- "P=1.6*10**4 #(rho*h/10000)+ex_p",
- "",
- "#calculation",
- "h=(P-ex_p)/1000.0",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "rho=1000.0 # density of water\n",
+ "ex_p=0.5*10**4 # External pressure on liquid \n",
+ "P=1.6*10**4 #(rho*h/10000)+ex_p\n",
+ "\n",
+ "#calculation\n",
+ "h=(P-ex_p)/1000.0\n",
+ "\n",
+ "#result\n",
"print('h = %d m' %h)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"h = 11 m"
]
}
- ],
+ ],
"prompt_number": 9
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 6.10, Page Number:375<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of level on the probe'''",
- "",
- "#variable declaration",
- "c2=100.0*10**-6 # capacitance in capacitance probe",
- "r1=10.0*10**3 # value of resistor in bride",
- "r2=100.0*10**3 # value of resistor in bride",
- "r3=50.0*10**3 # value of resistor in bride",
- "",
- "#calculation",
- "Cx=r1*c2/r3",
- "Cx=Cx*10**6",
- "",
- "#result",
- "print('Cx = %d microFarad'%Cx)",
- "c=5.0",
- "",
- "#calculation",
- "l=Cx/c",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "c2=100.0*10**-6 # capacitance in capacitance probe\n",
+ "r1=10.0*10**3 # value of resistor in bride\n",
+ "r2=100.0*10**3 # value of resistor in bride\n",
+ "r3=50.0*10**3 # value of resistor in bride\n",
+ "\n",
+ "#calculation\n",
+ "Cx=r1*c2/r3\n",
+ "Cx=Cx*10**6\n",
+ "\n",
+ "#result\n",
+ "print('Cx = %d microFarad'%Cx)\n",
+ "c=5.0\n",
+ "\n",
+ "#calculation\n",
+ "l=Cx/c\n",
+ "\n",
+ "#result\n",
"print('\\nLevel on the probe = %dm'%l)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "Cx = 20 microFarad",
- "",
+ "Cx = 20 microFarad\n",
+ "\n",
"Level on the probe = 4m"
]
}
- ],
+ ],
"prompt_number": 10
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/Chapter_7.ipynb b/Industrial_Instrumentation/Chapter_7.ipynb
index f42da02c..4a5cfd38 100644
--- a/Industrial_Instrumentation/Chapter_7.ipynb
+++ b/Industrial_Instrumentation/Chapter_7.ipynb
@@ -1,567 +1,594 @@
{
"metadata": {
- "name": "Chapter_7"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:7398e89d85008e2cdad3036771199a6877abb82c38f4bdc25b1a999f38a5b0fa"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter 7: Velocity Humidity and Moisture<h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.1, Page NUmber: 436<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of absolute viscosity'''",
- "",
- "#variable declaration",
- "f=2*9.8*10**5 # Force in Dynes",
- "A=100.0 # area in cm^2",
- "V=20.0 # velocity in m/sec",
- "l=10.0 # length in cm",
- "",
- "#calculation",
- "mu=(f/A)/(V/l)",
- "mu=mu/1000.0",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "f=2*9.8*10**5 # Force in Dynes\n",
+ "A=100.0 # area in cm^2\n",
+ "V=20.0 # velocity in m/sec\n",
+ "l=10.0 # length in cm\n",
+ "\n",
+ "#calculation\n",
+ "mu=(f/A)/(V/l)\n",
+ "mu=mu/1000.0\n",
+ "\n",
+ "#result\n",
"print('The absolute viscosity mu = %.1f*10^5 centipoises'%mu)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"The absolute viscosity mu = 9.8*10^5 centipoises"
]
}
- ],
+ ],
"prompt_number": 4
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.2, Page Number:437<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of kinematic relative and absolute viscosity'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "v=10.0 # absolute viscosity",
- "",
- "#calculation",
- "F=1/v",
- "",
- "#result",
- "print('(a)\\nFluidity = %.1f rhe'%F)",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "mu=10.0 # absolute viscosity",
- "rho=0.8 # density in m/cm^3",
- "",
- "#calculation",
- "ve=mu/rho",
- "",
- "#result",
- "print('\\n(b)\\nKinematic viscosity (v)= %.1f cm^2/sec'%ve)",
- "",
- "",
- "#(c)",
- "",
- "#variable declaration",
- "ab=1000.0 # absolute viscosity ",
- "abwt=1.002 # absolute viscosity of water at 20 deree celcius",
- "",
- "#calculation",
- "rv=ab/abwt",
- "",
- "#result",
- "print('\\n(c)\\nRelative viscosity = %d centipoises'%rv)",
- "",
- "#(d)",
- "",
- "#variable declaration",
- "PAS=10.0",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "v=10.0 # absolute viscosity\n",
+ "\n",
+ "#calculation\n",
+ "F=1/v\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nFluidity = %.1f rhe'%F)\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "mu=10.0 # absolute viscosity\n",
+ "rho=0.8 # density in m/cm^3\n",
+ "\n",
+ "#calculation\n",
+ "ve=mu/rho\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nKinematic viscosity (v)= %.1f cm^2/sec'%ve)\n",
+ "\n",
+ "\n",
+ "#(c)\n",
+ "\n",
+ "#variable declaration\n",
+ "ab=1000.0 # absolute viscosity \n",
+ "abwt=1.002 # absolute viscosity of water at 20 deree celcius\n",
+ "\n",
+ "#calculation\n",
+ "rv=ab/abwt\n",
+ "\n",
+ "#result\n",
+ "print('\\n(c)\\nRelative viscosity = %d centipoises'%rv)\n",
+ "\n",
+ "#(d)\n",
+ "\n",
+ "#variable declaration\n",
+ "PAS=10.0\n",
+ "\n",
+ "#Result\n",
"print('\\n(c)\\nAbsolute viscosity = 1000 centipoises =10 poises = 1PAS')"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Fluidity = 0.1 rhe",
- "",
- "(b)",
- "Kinematic viscosity (v)= 12.5 cm^2/sec",
- "",
- "(c)",
- "Relative viscosity = 998 centipoises",
- "",
- "(c)",
+ "(a)\n",
+ "Fluidity = 0.1 rhe\n",
+ "\n",
+ "(b)\n",
+ "Kinematic viscosity (v)= 12.5 cm^2/sec\n",
+ "\n",
+ "(c)\n",
+ "Relative viscosity = 998 centipoises\n",
+ "\n",
+ "(c)\n",
"Absolute viscosity = 1000 centipoises =10 poises = 1PAS"
]
}
- ],
+ ],
"prompt_number": 5
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.3, Page Number: 438<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Absolute viscosity of the Newtonian fluid'''",
- "",
- "import math",
- "#b)",
- "",
- "#variable declaration",
- "R=0.5 # radius",
- "L=5 # length",
- "p_diff=800.0 # pressure difference",
- "V=10.0 # volume",
- "",
- "#calculation",
- "mu=(math.pi*R**4)*p_diff/(8*V*L)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "#b)\n",
+ "\n",
+ "#variable declaration\n",
+ "R=0.5 # radius\n",
+ "L=5 # length\n",
+ "p_diff=800.0 # pressure difference\n",
+ "V=10.0 # volume\n",
+ "\n",
+ "#calculation\n",
+ "mu=(math.pi*R**4)*p_diff/(8*V*L)\n",
+ "\n",
+ "#result\n",
"print('(b)\\nmu=%.4f poise =%.2f centipoise'%(mu,mu*100))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(b)",
+ "(b)\n",
"mu=0.3927 poise =39.27 centipoise"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.4, Page Number: 439<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''kinematic viscosity and density calculation'''",
- "",
- "import math ",
- "#(a)",
- "",
- "#variable declaration",
- "g=980.0 # acceleration due to gravity",
- "h=4 # Height",
- "R=0.5 # radius",
- "V=10.0 # volume ",
- "l=5.0 # length ",
- "t=1.0",
- "",
- "#calculation",
- "v=(math.pi*g*h*t*R**4)/(8*l*V)",
- "",
- "#result",
- "print('(a)\\n v = %.2f stokes'%v)",
- "",
- "#calculation",
- "mu=0.3925",
- "rho=mu/v",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math \n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "g=980.0 # acceleration due to gravity\n",
+ "h=4 # Height\n",
+ "R=0.5 # radius\n",
+ "V=10.0 # volume \n",
+ "l=5.0 # length \n",
+ "t=1.0\n",
+ "\n",
+ "#calculation\n",
+ "v=(math.pi*g*h*t*R**4)/(8*l*V)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\n v = %.2f stokes'%v)\n",
+ "\n",
+ "#calculation\n",
+ "mu=0.3925\n",
+ "rho=mu/v\n",
+ "\n",
+ "#result\n",
"print('\\n(b)\\n Density of the fluid rho = %.3f gm/cm^3'%rho)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- " v = 1.92 stokes",
- "",
- "(b)",
+ "(a)\n",
+ " v = 1.92 stokes\n",
+ "\n",
+ "(b)\n",
" Density of the fluid rho = 0.204 gm/cm^3"
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.5, Page Number: 440<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Kinematic Viscosity in Saybolts Universal viscometer'''",
- "",
- "#variable declaration",
- "",
- "#(a)",
- "A=0.226 # value of A as per equation",
- "B=195.0 # value of B as per equation",
- "t=60.0 # Efflux time",
- "",
- "#calcullation",
- "v=A*t-B/t",
- "A1=0.220",
- "B1=135.0",
- "t1=140.0",
- "v1=A1*t1-B1/t1",
- "",
- "#result",
- "print('(a) Fluid X\\n v = %.2f centipoises'%v)",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "#(a)\n",
+ "A=0.226 # value of A as per equation\n",
+ "B=195.0 # value of B as per equation\n",
+ "t=60.0 # Efflux time\n",
+ "\n",
+ "#calcullation\n",
+ "v=A*t-B/t\n",
+ "A1=0.220\n",
+ "B1=135.0\n",
+ "t1=140.0\n",
+ "v1=A1*t1-B1/t1\n",
+ "\n",
+ "#result\n",
+ "print('(a) Fluid X\\n v = %.2f centipoises'%v)\n",
"print('\\n(b)Fluid Y\\n v = %.1f centipoises'%v1)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a) Fluid X",
- " v = 10.31 centipoises",
- "",
- "(b)Fluid Y",
+ "(a) Fluid X\n",
+ " v = 10.31 centipoises\n",
+ "\n",
+ "(b)Fluid Y\n",
" v = 29.8 centipoises"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.6, Page Number: 441<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of absolute viscosity'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "t=12.0 # time interval of falling ball in sec ",
- "Rsb=7.0 # Specific gravity of ball",
- "Rsf=1.12 # Specific gravity of fluid",
- "B=1.5 # Ball constant in centipoises",
- "",
- "#calculation",
- "mu=t*(Rsb-Rsf)*B",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "t=12.0 # time interval of falling ball in sec \n",
+ "Rsb=7.0 # Specific gravity of ball\n",
+ "Rsf=1.12 # Specific gravity of fluid\n",
+ "B=1.5 # Ball constant in centipoises\n",
+ "\n",
+ "#calculation\n",
+ "mu=t*(Rsb-Rsf)*B\n",
+ "\n",
+ "#result\n",
"print('mu= %.2f centipoises = %d centipoises(approx)'%(mu,math.ceil(mu)))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"mu= 105.84 centipoises = 106 centipoises(approx)"
]
}
- ],
+ ],
"prompt_number": 9
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.7, Page Number: 441<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of relative humidity'''",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "B=45.0 # dry bulb temperature",
- "W=25.0 # wet bulb temperature",
- "",
- "#result",
- "print('\\n(b)\\nPsychromatic differential : %d\u00b0C'%(B-W))",
- "print('\\n Relative humidity is 80%% corresponding to')",
- "print(' \\ntemperature 45\u00b0C and psychromatic differential 20\u00b0C')",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "B1=30.0 # dry bulb temperature",
- "W1=27.0 # wet bulb temperature",
- "",
- "#result",
- "print('\\n(b)\\nPsychromatic differential : %d\u00b0C'%(B1-W1))",
- "print('\\n Relative humidity is 80%% corresponding to')",
+ "\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "B=45.0 # dry bulb temperature\n",
+ "W=25.0 # wet bulb temperature\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nPsychromatic differential : %d\u00b0C'%(B-W))\n",
+ "print('\\n Relative humidity is 80%% corresponding to')\n",
+ "print(' \\ntemperature 45\u00b0C and psychromatic differential 20\u00b0C')\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "B1=30.0 # dry bulb temperature\n",
+ "W1=27.0 # wet bulb temperature\n",
+ "\n",
+ "#result\n",
+ "print('\\n(b)\\nPsychromatic differential : %d\u00b0C'%(B1-W1))\n",
+ "print('\\n Relative humidity is 80%% corresponding to')\n",
"print(' \\ntemperature 30\u00b0C and psychromatic differential 3\u00b0C')"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "",
- "(b)",
- "Psychromatic differential : 20\u00b0C",
- "",
- " Relative humidity is 80%% corresponding to",
- " ",
- "temperature 45\u00b0C and psychromatic differential 20\u00b0C",
- "",
- "(b)",
- "Psychromatic differential : 3\u00b0C",
- "",
- " Relative humidity is 80%% corresponding to",
- " ",
+ "\n",
+ "(b)\n",
+ "Psychromatic differential : 20\u00b0C\n",
+ "\n",
+ " Relative humidity is 80%% corresponding to\n",
+ " \n",
+ "temperature 45\u00b0C and psychromatic differential 20\u00b0C\n",
+ "\n",
+ "(b)\n",
+ "Psychromatic differential : 3\u00b0C\n",
+ "\n",
+ " Relative humidity is 80%% corresponding to\n",
+ " \n",
"temperature 30\u00b0C and psychromatic differential 3\u00b0C"
]
}
- ],
+ ],
"prompt_number": 10
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.8, Page Number: 441<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of Relative Humidity dew point and moisture content'''",
- "",
- "#variable declaration",
- "D=80.0 # intersection point of DB temperature",
- "W=66.5 # intersection point of WB temperature",
- "",
- "#Result",
- "",
- "#(a)",
- "print('(a)\\nThe intersection point of DB temperature 80\u00b0F and WB temperature 66.5\u00b0F')",
- "print(' \\nlines on the relative humidity curve for 50%.\\n RH = 50%')",
- "",
- "#(b)",
- "print('\\n(b)\\nFrom the point of intersection of the dry and wet bulb curves, move left')",
- "print(' \\nhorizontally to the dew point temperature curve where it meets at 60\u00b0F')",
- "print('\\nDew Point = 60\u00b0F')",
- "",
- "#(c)",
- "print('\\n(c)\\nFrom the point of intersection of the dry and wet bulb curves,')",
- "print('\\nhorizontally to the right to the moisture content plot where it meets at 76.')",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "D=80.0 # intersection point of DB temperature\n",
+ "W=66.5 # intersection point of WB temperature\n",
+ "\n",
+ "#Result\n",
+ "\n",
+ "#(a)\n",
+ "print('(a)\\nThe intersection point of DB temperature 80\u00b0F and WB temperature 66.5\u00b0F')\n",
+ "print(' \\nlines on the relative humidity curve for 50%.\\n RH = 50%')\n",
+ "\n",
+ "#(b)\n",
+ "print('\\n(b)\\nFrom the point of intersection of the dry and wet bulb curves, move left')\n",
+ "print(' \\nhorizontally to the dew point temperature curve where it meets at 60\u00b0F')\n",
+ "print('\\nDew Point = 60\u00b0F')\n",
+ "\n",
+ "#(c)\n",
+ "print('\\n(c)\\nFrom the point of intersection of the dry and wet bulb curves,')\n",
+ "print('\\nhorizontally to the right to the moisture content plot where it meets at 76.')\n",
"print('\\nMoisture Content : 76 grains of water per pound of dry air.')"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "The intersection point of DB temperature 80\u00b0F and WB temperature 66.5\u00b0F",
- " ",
- "lines on the relative humidity curve for 50%.",
- " RH = 50%",
- "",
- "(b)",
- "From the point of intersection of the dry and wet bulb curves, move left",
- " ",
- "horizontally to the dew point temperature curve where it meets at 60\u00b0F",
- "",
- "Dew Point = 60\u00b0F",
- "",
- "(c)",
- "From the point of intersection of the dry and wet bulb curves,",
- "",
- "horizontally to the right to the moisture content plot where it meets at 76.",
- "",
+ "(a)\n",
+ "The intersection point of DB temperature 80\u00b0F and WB temperature 66.5\u00b0F\n",
+ " \n",
+ "lines on the relative humidity curve for 50%.\n",
+ " RH = 50%\n",
+ "\n",
+ "(b)\n",
+ "From the point of intersection of the dry and wet bulb curves, move left\n",
+ " \n",
+ "horizontally to the dew point temperature curve where it meets at 60\u00b0F\n",
+ "\n",
+ "Dew Point = 60\u00b0F\n",
+ "\n",
+ "(c)\n",
+ "From the point of intersection of the dry and wet bulb curves,\n",
+ "\n",
+ "horizontally to the right to the moisture content plot where it meets at 76.\n",
+ "\n",
"Moisture Content : 76 grains of water per pound of dry air."
]
}
- ],
+ ],
"prompt_number": 11
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.9, Page Number: 442<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of relative humidity'''",
- "",
- "#variable declaration",
- "wt_vap=500.0 # Amount of water vapour present",
- "wt_vap_to_sat=1500.0 # Amount of water vapour added to saturate",
- "",
- "#calculation",
- "total=wt_vap+wt_vap_to_sat",
- "Rh=(wt_vap/total)*100",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "wt_vap=500.0 # Amount of water vapour present\n",
+ "wt_vap_to_sat=1500.0 # Amount of water vapour added to saturate\n",
+ "\n",
+ "#calculation\n",
+ "total=wt_vap+wt_vap_to_sat\n",
+ "Rh=(wt_vap/total)*100\n",
+ "\n",
+ "#result\n",
"print('RH = %d%%'%Rh)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"RH = 25%"
]
}
- ],
+ ],
"prompt_number": 12
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.10, Page Number: 442<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''percentage relative humidity'''",
- "",
- "#variable declaration",
- "pv=30.0 # partial pressure of water vapour",
- "ps=60.0 # Saturation partial pressure ",
- "",
- "#calculations",
- "Rh=(pv/ps)*100",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "pv=30.0 # partial pressure of water vapour\n",
+ "ps=60.0 # Saturation partial pressure \n",
+ "\n",
+ "#calculations\n",
+ "Rh=(pv/ps)*100\n",
+ "\n",
+ "#Result\n",
"print('%%RH = %d%%'%Rh)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"%RH = 50%"
]
}
- ],
+ ],
"prompt_number": 13
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.11, Page Number: 442<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''percentage increase in moisture content'''",
- "",
- "#variable declaration",
- "i1=250.0 # ionazation current ",
- "i2=350.0 # ionazation current ",
- "",
- "#calculation",
- "m=(i2-i1)*100/i1",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "i1=250.0 # ionazation current \n",
+ "i2=350.0 # ionazation current \n",
+ "\n",
+ "#calculation\n",
+ "m=(i2-i1)*100/i1\n",
+ "\n",
+ "#result\n",
"print('%% increase in moisture content = %d%%'%m)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"% increase in moisture content = 40%"
]
}
- ],
+ ],
"prompt_number": 14
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 7.12, Page Number: 443<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of moisture content'''",
- "",
- "#variable declaraton",
- "i2=150.0 # wet weight",
- "i1=125.0 # dry weight",
- "",
- "#calculation",
- "m=(i2-i1)*100/i1",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable declaraton\n",
+ "i2=150.0 # wet weight\n",
+ "i1=125.0 # dry weight\n",
+ "\n",
+ "#calculation\n",
+ "m=(i2-i1)*100/i1\n",
+ "\n",
+ "#result\n",
"print('Moisture percentage = %d%%'%m)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Moisture percentage = 20%"
]
}
- ],
+ ],
"prompt_number": 15
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/Chapter_8.ipynb b/Industrial_Instrumentation/Chapter_8.ipynb
index 8a84dda0..45717557 100644
--- a/Industrial_Instrumentation/Chapter_8.ipynb
+++ b/Industrial_Instrumentation/Chapter_8.ipynb
@@ -1,485 +1,507 @@
{
"metadata": {
- "name": "Chapter_8"
- },
- "nbformat": 2,
+ "name": "",
+ "signature": "sha256:d75e4cfd03813a2ebb58ae96e012a8b8020f7dffa90e8d93acabe5330e357932"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h1>Chapter 8:Fundamentals of measuring instruments <h1>"
]
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.1, Page Number: 507<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Flux density calculation'''",
- "",
- "#variable declaration",
- "fi=10.0*10**-6 # fi-flux",
- "inch=2.54*10**-2 # length",
- "A=inch**2 # area",
- "",
- "#calculation",
- "B =fi/A",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "#variable declaration\n",
+ "fi=10.0*10**-6 # fi-flux\n",
+ "inch=2.54*10**-2 # length\n",
+ "A=inch**2 # area\n",
+ "\n",
+ "#calculation\n",
+ "B =fi/A\n",
+ "\n",
+ "#Result\n",
"print('Flux Density B= %.1f mT'%(B*1000))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"Flux Density B= 15.5 mT"
]
}
- ],
+ ],
"prompt_number": 1
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.2, Page Number: 508<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Power Dissipation and accuracy of result'''",
- "",
- "#variable Declaration",
- "i=10*10**-3 # current in A",
- "R=1000.0 # resistance in ohm",
- "P=(i**2)*R # Power",
- "err_R=10.0 # Error in Resistance measurement",
- "err_I=(2.0/100)*25*100/10 # Error in current measurement",
- "",
- "#calculation",
- "err_I2=2*err_I",
- "err_p=err_I2+err_R",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "#variable Declaration\n",
+ "i=10*10**-3 # current in A\n",
+ "R=1000.0 # resistance in ohm\n",
+ "P=(i**2)*R # Power\n",
+ "err_R=10.0 # Error in Resistance measurement\n",
+ "err_I=(2.0/100)*25*100/10 # Error in current measurement\n",
+ "\n",
+ "#calculation\n",
+ "err_I2=2*err_I\n",
+ "err_p=err_I2+err_R\n",
+ "\n",
+ "#Result\n",
"print('%% error in I^2 = \u00b1 %d%%\\n%% error in Power = \u00b1 %d%%'%(err_I2,err_p))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "% error in I^2 = \u00b1 10%",
+ "% error in I^2 = \u00b1 10%\n",
"% error in Power = \u00b1 20%"
]
}
- ],
+ ],
"prompt_number": 2
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.3, Page Number: 508<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''max and min levels of input supply current'''",
- "",
- "#variable Declaration",
- "i1=37.0 # current in branch 1 ",
- "i2=42.0 # current in branch 2",
- "i3=13.0 # current in branch 3",
- "i4=6.7 # current in branch 4",
- "",
- "#Calculation",
- "Imax=(i1+i2)+(i1+i2)*(3.0/100)+(i3+i4)+(i3+i4)*(1.0/100)",
- "Imin=(i1+i2)-(i1+i2)*(3.0/100)+(i3+i4)-(i3+i4)*(1.0/100)",
- "",
- "#result",
- "print('Maximum level of total supply current = %.3f mA'%Imax)",
+ "\n",
+ "#variable Declaration\n",
+ "i1=37.0 # current in branch 1 \n",
+ "i2=42.0 # current in branch 2\n",
+ "i3=13.0 # current in branch 3\n",
+ "i4=6.7 # current in branch 4\n",
+ "\n",
+ "#Calculation\n",
+ "Imax=(i1+i2)+(i1+i2)*(3.0/100)+(i3+i4)+(i3+i4)*(1.0/100)\n",
+ "Imin=(i1+i2)-(i1+i2)*(3.0/100)+(i3+i4)-(i3+i4)*(1.0/100)\n",
+ "\n",
+ "#result\n",
+ "print('Maximum level of total supply current = %.3f mA'%Imax)\n",
"print('\\nMinimum level of total supply current = %.3f mA'%Imin)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "Maximum level of total supply current = 101.267 mA",
- "",
+ "Maximum level of total supply current = 101.267 mA\n",
+ "\n",
"Minimum level of total supply current = 96.133 mA"
]
}
- ],
+ ],
"prompt_number": 3
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.4, Page Number:508<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Time constant for thermometer'''",
- "",
- "import math",
- "",
- "#(a)",
- "",
- "#variable declaration",
- "T=200.0 # intermediate temperature ",
- "T0=300.0 # final temperature ",
- "Ti=70.0 # initial temperature ",
- "t=3.0 # time in seconds ",
- "",
- "#calculation",
- "x=(T-T0)/(Ti-T0)",
- "tow=-t/math.log(x)",
- "",
- "#result",
- "print('(a)\\nTime constant tow=%.1f s'%tow)",
- "",
- "",
- "#(b)",
- "",
- "#variable declaration",
- "t1=5.0 # time in seconds ",
- "#calculation",
- "T5=T0+((Ti-T0)*math.e**(-t1/tow))",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#(a)\n",
+ "\n",
+ "#variable declaration\n",
+ "T=200.0 # intermediate temperature \n",
+ "T0=300.0 # final temperature \n",
+ "Ti=70.0 # initial temperature \n",
+ "t=3.0 # time in seconds \n",
+ "\n",
+ "#calculation\n",
+ "x=(T-T0)/(Ti-T0)\n",
+ "tow=-t/math.log(x)\n",
+ "\n",
+ "#result\n",
+ "print('(a)\\nTime constant tow=%.1f s'%tow)\n",
+ "\n",
+ "\n",
+ "#(b)\n",
+ "\n",
+ "#variable declaration\n",
+ "t1=5.0 # time in seconds \n",
+ "#calculation\n",
+ "T5=T0+((Ti-T0)*math.e**(-t1/tow))\n",
+ "\n",
+ "#result\n",
"print('\\n(b)\\nTemperature after 5 seconds T5 = %.2f\u00b0C'%T5)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(a)",
- "Time constant tow=3.6 s",
- "",
- "(b)",
+ "(a)\n",
+ "Time constant tow=3.6 s\n",
+ "\n",
+ "(b)\n",
"Temperature after 5 seconds T5 = 242.61\u00b0C"
]
}
- ],
+ ],
"prompt_number": 4
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.5, Page Number:<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Error calculation of second order instrument'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "w=9.0 # excitation frequency",
- "wn=6.0 # natural frequency",
- "dr=0.6 # damping ratio",
- "",
- "#calculations",
- "",
- "x=w/wn",
- "Ar=1/math.sqrt(((1-(x)**2)**2)+(2*dr*x)**2)",
- "err=(1-Ar)*100",
- "",
- "#Result",
- "print('A=%.3f'%Ar)",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "w=9.0 # excitation frequency\n",
+ "wn=6.0 # natural frequency\n",
+ "dr=0.6 # damping ratio\n",
+ "\n",
+ "#calculations\n",
+ "\n",
+ "x=w/wn\n",
+ "Ar=1/math.sqrt(((1-(x)**2)**2)+(2*dr*x)**2)\n",
+ "err=(1-Ar)*100\n",
+ "\n",
+ "#Result\n",
+ "print('A=%.3f'%Ar)\n",
"print('\\nError = %.2f%%'%err)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "A=0.456",
- "",
+ "A=0.456\n",
+ "\n",
"Error = 54.37%"
]
}
- ],
+ ],
"prompt_number": 5
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.6, PAge Number: 510<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Output of first order instrument for unit step input'''",
- "",
- "#variable Declaration",
- "t=2.0 # output to be calculated after t seconds",
- "",
- "#calculation",
- "y=1-math.e**(-(t-1.5)/0.5)",
- "",
- "#result",
+ "\n",
+ "\n",
+ "#variable Declaration\n",
+ "t=2.0 # output to be calculated after t seconds\n",
+ "\n",
+ "#calculation\n",
+ "y=1-math.e**(-(t-1.5)/0.5)\n",
+ "\n",
+ "#result\n",
"print('y(t)at t=2 will be y(t)=%.3f'%y)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
"y(t)at t=2 will be y(t)=0.632"
]
}
- ],
+ ],
"prompt_number": 6
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.7, Page Number: 510<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Statistic of Temperature readings'''",
- "",
- "import math",
- "",
- "#variable declaration",
- "",
- "#Temperature Readings",
- "x1=98.5 # Reading 1",
- "x2=99.0 # Reading 2",
- "x3=99.5 # Reading 3 ",
- "x4=100.0 # Reading 4",
- "x5=100.5 # Reading 5",
- "x6=101.0 # Reading 6",
- "x7=101.5 # Reading 7",
- "# Frequency",
- "f1=4.0 # Reading 1",
- "f2=13.0 # Reading 2",
- "f3=19.0 # Reading 3",
- "f4=35.0 # Reading 4",
- "f5=17.0 # Reading 5",
- "f6=10.0 # Reading 6",
- "f7=2.0 # Reading 7",
- "",
- "#(i) Arithmatic Mean",
- "",
- "#calculation",
- "x_bar=((x1*f1)+(x2*f2)+(x3*f3)+(x4*f4)+(x5*f5)+(x6*f6)+(x7*f7))/(f1+f2+f3+f4+f5+f6+f7)",
- "",
- "#result",
- "print('(i)\\n\\tArithmatic Mean = %.2f\u00b0C'%x_bar)",
- "",
- "#(ii) Average Deviation",
- "",
- "#calculation",
- "D=(abs(x1-x_bar)*f1)+(abs(x2-x_bar)*f2)+(abs(x3-x_bar)*f3)+(abs(x4-x_bar)*f4)",
- "D=D+(abs(x5-x_bar)*f5)+(abs(x6-x_bar)*f6)+(abs(x7-x_bar)*f7)",
- "D=D/(f1+f2+f3+f4+f5+f6+f7)",
- "",
- "#result",
- "print('\\n(ii)\\n\\tAverage Deviation =%.4f\u00b0C'%D)",
- "",
- "#Standard deviation",
- "",
- "#Calculation",
- "sigma=((x1-x_bar)**2*f1)+((x2-x_bar)**2*f2)+((x3-x_bar)**2*f3)+((x4-x_bar)**2*f4)",
- "sigma=sigma+((x5-x_bar)**2*f5)+((x6-x_bar)**2*f6)+((x7-x_bar)**2*f7)",
- "sigma=math.sqrt(sigma)",
- "sigma=sigma/math.sqrt(f1+f2+f3+f4+f5+f6+f7)",
- "",
- "#result",
- "print('\\n(iii)\\n\\tStandard deviation = %.3f\u00b0C'%sigma)",
- "",
- "#variance",
- "",
- "#result",
- "print('\\n(iv)\\n\\tVariance = %.4f\u00b0C'%(sigma**2))",
- "",
- "#Probable Error",
- "",
- "#result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "#Temperature Readings\n",
+ "x1=98.5 # Reading 1\n",
+ "x2=99.0 # Reading 2\n",
+ "x3=99.5 # Reading 3 \n",
+ "x4=100.0 # Reading 4\n",
+ "x5=100.5 # Reading 5\n",
+ "x6=101.0 # Reading 6\n",
+ "x7=101.5 # Reading 7\n",
+ "# Frequency\n",
+ "f1=4.0 # Reading 1\n",
+ "f2=13.0 # Reading 2\n",
+ "f3=19.0 # Reading 3\n",
+ "f4=35.0 # Reading 4\n",
+ "f5=17.0 # Reading 5\n",
+ "f6=10.0 # Reading 6\n",
+ "f7=2.0 # Reading 7\n",
+ "\n",
+ "#(i) Arithmatic Mean\n",
+ "\n",
+ "#calculation\n",
+ "x_bar=((x1*f1)+(x2*f2)+(x3*f3)+(x4*f4)+(x5*f5)+(x6*f6)+(x7*f7))/(f1+f2+f3+f4+f5+f6+f7)\n",
+ "\n",
+ "#result\n",
+ "print('(i)\\n\\tArithmatic Mean = %.2f\u00b0C'%x_bar)\n",
+ "\n",
+ "#(ii) Average Deviation\n",
+ "\n",
+ "#calculation\n",
+ "D=(abs(x1-x_bar)*f1)+(abs(x2-x_bar)*f2)+(abs(x3-x_bar)*f3)+(abs(x4-x_bar)*f4)\n",
+ "D=D+(abs(x5-x_bar)*f5)+(abs(x6-x_bar)*f6)+(abs(x7-x_bar)*f7)\n",
+ "D=D/(f1+f2+f3+f4+f5+f6+f7)\n",
+ "\n",
+ "#result\n",
+ "print('\\n(ii)\\n\\tAverage Deviation =%.4f\u00b0C'%D)\n",
+ "\n",
+ "#Standard deviation\n",
+ "\n",
+ "#Calculation\n",
+ "sigma=((x1-x_bar)**2*f1)+((x2-x_bar)**2*f2)+((x3-x_bar)**2*f3)+((x4-x_bar)**2*f4)\n",
+ "sigma=sigma+((x5-x_bar)**2*f5)+((x6-x_bar)**2*f6)+((x7-x_bar)**2*f7)\n",
+ "sigma=math.sqrt(sigma)\n",
+ "sigma=sigma/math.sqrt(f1+f2+f3+f4+f5+f6+f7)\n",
+ "\n",
+ "#result\n",
+ "print('\\n(iii)\\n\\tStandard deviation = %.3f\u00b0C'%sigma)\n",
+ "\n",
+ "#variance\n",
+ "\n",
+ "#result\n",
+ "print('\\n(iv)\\n\\tVariance = %.4f\u00b0C'%(sigma**2))\n",
+ "\n",
+ "#Probable Error\n",
+ "\n",
+ "#result\n",
"print('\\n(v)\\n\\tProbable Error= %.4f\u00b0C'%(0.6745*sigma))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(i)",
- "\tArithmatic Mean = 99.93\u00b0C",
- "",
- "(ii)",
- "\tAverage Deviation =0.5196\u00b0C",
- "",
- "(iii)",
- "\tStandard deviation = 0.671\u00b0C",
- "",
- "(iv)",
- "\tVariance = 0.4501\u00b0C",
- "",
- "(v)",
+ "(i)\n",
+ "\tArithmatic Mean = 99.93\u00b0C\n",
+ "\n",
+ "(ii)\n",
+ "\tAverage Deviation =0.5196\u00b0C\n",
+ "\n",
+ "(iii)\n",
+ "\tStandard deviation = 0.671\u00b0C\n",
+ "\n",
+ "(iv)\n",
+ "\tVariance = 0.4501\u00b0C\n",
+ "\n",
+ "(v)\n",
"\tProbable Error= 0.4525\u00b0C"
]
}
- ],
+ ],
"prompt_number": 7
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.8, Page Number: 511<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''Calculation of damping coefficient and natural frequency for 2nd order instrument'''",
- "",
- "import math",
- "",
- "#variable Declaration",
- "wn=math.sqrt(3.0) # natural frequency of osscilation",
- "",
- "#Calculation",
- "x=3.2/(2*wn)",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "#variable Declaration\n",
+ "wn=math.sqrt(3.0) # natural frequency of osscilation\n",
+ "\n",
+ "#Calculation\n",
+ "x=3.2/(2*wn)\n",
+ "\n",
+ "#Result\n",
"print('Damping coefficient = %.3f\\nNatural frequency of Oscillation = %.3f'%(x,wn))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "Damping coefficient = 0.924",
+ "Damping coefficient = 0.924\n",
"Natural frequency of Oscillation = 1.732"
]
}
- ],
+ ],
"prompt_number": 8
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.9, Page Number: 512<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''calculation of Amplitude inaccuracy and phase shift from transfer function'''",
- "",
- "import math",
- "#variable declaration",
- "w=100.0 # natural frequency of osscilation",
- "",
- "#calculation",
- "fi=-math.atan(0.1*w)-math.atan(0.5*w)",
- "A=1/(math.sqrt(1+(0.1*w)**2)*(math.sqrt(1+(0.5*w)**2)))",
- "A=1*1000.0/math.ceil(1000*A)",
- "err=(1-1.0/A)*100",
- "",
- "#Result",
+ "\n",
+ "\n",
+ "import math\n",
+ "#variable declaration\n",
+ "w=100.0 # natural frequency of osscilation\n",
+ "\n",
+ "#calculation\n",
+ "fi=-math.atan(0.1*w)-math.atan(0.5*w)\n",
+ "A=1/(math.sqrt(1+(0.1*w)**2)*(math.sqrt(1+(0.5*w)**2)))\n",
+ "A=1*1000.0/math.ceil(1000*A)\n",
+ "err=(1-1.0/A)*100\n",
+ "\n",
+ "#Result\n",
"print('A=K/%d\\n%% error = %.1f%%\\nfi = %.2f\u00b0'%(A,err,fi*180/math.pi))"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "A=K/500",
- "% error = 99.8%",
+ "A=K/500\n",
+ "% error = 99.8%\n",
"fi = -173.14\u00b0"
]
}
- ],
+ ],
"prompt_number": 9
- },
+ },
{
- "cell_type": "markdown",
+ "cell_type": "markdown",
+ "metadata": {},
"source": [
"<h3>Example 8.10, Page Number: 512<h3>"
]
- },
+ },
{
- "cell_type": "code",
- "collapsed": false,
+ "cell_type": "code",
+ "collapsed": false,
"input": [
- "'''temperature and altitude calculation from first order thermometer placed in balloon'''",
- "",
- "#calculations",
- "R=0.15*10/50 # Temperature gradient",
- "K=1.0 # constant",
- "tow=15.0 # time constant ",
- "",
- "#Calculations",
- "deg=K*R*tow",
- "",
- "#(i)",
- "a=15-deg",
- "",
- "#(ii)",
- "alt_red=deg*50.0/0.15",
- "h=5000-alt_red",
- "",
- "#result",
- "print('(i)The actual temperature when instrument reads 15\u00b0C is %.2f\u00b0C'%a)",
- "print('\\n The true temperature at 5000 metres = %.2f '%a)",
+ "\n",
+ "#calculations\n",
+ "R=0.15*10/50 # Temperature gradient\n",
+ "K=1.0 # constant\n",
+ "tow=15.0 # time constant \n",
+ "\n",
+ "#Calculations\n",
+ "deg=K*R*tow\n",
+ "\n",
+ "#(i)\n",
+ "a=15-deg\n",
+ "\n",
+ "#(ii)\n",
+ "alt_red=deg*50.0/0.15\n",
+ "h=5000-alt_red\n",
+ "\n",
+ "#result\n",
+ "print('(i)The actual temperature when instrument reads 15\u00b0C is %.2f\u00b0C'%a)\n",
+ "print('\\n The true temperature at 5000 metres = %.2f '%a)\n",
"print('\\n(ii)\\nThe true altitude at which 15\u00b0C occurs is %d metres'%h)"
- ],
- "language": "python",
+ ],
+ "language": "python",
+ "metadata": {},
"outputs": [
{
- "output_type": "stream",
- "stream": "stdout",
+ "output_type": "stream",
+ "stream": "stdout",
"text": [
- "(i)The actual temperature when instrument reads 15\u00b0C is 14.55\u00b0C",
- "",
- " The true temperature at 5000 metres = 14.55 ",
- "",
- "(ii)",
+ "(i)The actual temperature when instrument reads 15\u00b0C is 14.55\u00b0C\n",
+ "\n",
+ " The true temperature at 5000 metres = 14.55 \n",
+ "\n",
+ "(ii)\n",
"The true altitude at which 15\u00b0C occurs is 4850 metres"
]
}
- ],
+ ],
"prompt_number": 10
}
- ]
+ ],
+ "metadata": {}
}
]
} \ No newline at end of file
diff --git a/Industrial_Instrumentation/ch2.ipynb b/Industrial_Instrumentation/ch2.ipynb
index 22755012..0f54145a 100644
--- a/Industrial_Instrumentation/ch2.ipynb
+++ b/Industrial_Instrumentation/ch2.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:3203164807ce532b672553754629f11a0a0db0c197fd3e21e75a10e9e0cb2a95"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,7 +28,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "# Convert the following readings of pressure to kPa assuming that barometer reads 760 mm of Hg.\n",
"\n",
"# Variables\n",
"rho_Hg = 13596.; \t\t\t#kg/m**3\n",
@@ -89,7 +89,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "# Find the pressure on the piston.\n",
"\n",
"import math \n",
"\n",
@@ -130,7 +129,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "#Find the gauge pressure \n",
"\n",
"# Variables\n",
"SG = 0.9;\n",
@@ -171,7 +169,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "#Find the absolute pressure in the condenser in Pa. \n",
"\n",
"# Variables\n",
"Vacuum_recorded = 740.; \t\t\t#mm of Hg\n",
@@ -209,11 +206,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The absolute pressure of the gas in the vessel in bar.\n",
- "(ii) Specific volume and density of the gas.\n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -267,9 +259,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the gas pressure.\n",
- "'''\n",
"\n",
"\n",
"# Variables\n",
@@ -310,9 +299,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the absolute pressure of steam.\n",
- "'''\n",
"\n",
"# Variables\n",
"h_H2O = 34.; \t\t\t#mm of Hg\n",
@@ -354,9 +340,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the absolute pressure of the gas \n",
- "'''\n",
"\n",
"# Variables\n",
"SG = 0.8;\n",
@@ -399,9 +382,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Estimate the mass of a piston that can be supported by a gas entrapped\n",
- "under the piston '''\n",
"\n",
"import math \n",
"\n",
@@ -444,9 +424,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate the kinetic energy of an artificial satellite revolves round the earth \n",
- "'''\n",
"\n",
"# Variables\n",
"v = 800.; \t\t\t#m/s\n",
@@ -486,11 +463,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find :\n",
- "(i) Heat transferred ;\n",
- "(ii) Mean specific heat of the gas.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -543,10 +516,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "what will be the temperature corresponding to the thermometric property of 3.5 on\n",
- "Celsius scale.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from numpy import *\n",
@@ -592,9 +562,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "What will be the reading on the thermometer where the gas thermometer reads 70\u00b0C ?\n",
- "'''\n",
"\n",
"def func(t): \n",
"\t return 0.20*t-5*10**(-4)*t**2\n",
@@ -635,9 +602,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "What is the amount of work done upon the atmosphere by the balloon ? \n",
- "'''\n",
"\n",
"# Variables\n",
"p = 101.325; \t\t#kPa\n",
@@ -675,9 +639,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the work done by the air which enters into an evacuated vessel\n",
- "from atmosphere when the valve is opened'''\n",
"\n",
"from scipy import integrate\n",
"\n",
@@ -718,10 +679,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "A piston and cylinder machine containing a fluid system has a stirring\n",
- "device as shown in Fig. 2.36. Find the net work transfer for the system.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -766,9 +724,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the net work done during the process.\n",
- "'''\n",
"\n",
"# Variables\n",
"A = 45.*10**(-4); \t #m**2\n",
@@ -808,9 +763,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the work done when the pressure increases from 1.5 bar to 7.5 bar.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -857,9 +810,6 @@
"input": [
"import math\n",
"\n",
- "'''\n",
- "To a closed system 150 kJ of work is supplied, determine the final volume and pressure of the system.\n",
- "'''\n",
"\n",
"# Variables\n",
"W = 150; \t\t\t#kJ\n",
@@ -898,9 +848,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the work done by the fluid on the piston.\n",
- "'''\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -949,9 +896,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the net work done by the fluid, for an initial volume of 0.05 m 3 .\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
diff --git a/Industrial_Instrumentation/ch3.ipynb b/Industrial_Instrumentation/ch3.ipynb
index 8e397388..e1873694 100644
--- a/Industrial_Instrumentation/ch3.ipynb
+++ b/Industrial_Instrumentation/ch3.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:ab490015435e8f1ac3990217bb57911661595e73c3c831b703cdf5b3388c40c5"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,9 +28,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the dryness fraction (quality) of steam \n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m_s = 50. \t\t\t#kg\n",
@@ -66,11 +65,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) Mass and volume of liquid ;\n",
- "(ii) Mass and volume of vapour.\n",
- "'''\n",
"\n",
"# Variables\n",
"V = 0.6; \t\t\t#m**3\n",
@@ -129,15 +123,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the following :\n",
- "(i) The pressure,\n",
- "(ii) The mass,\n",
- "(iii) The specific volume,\n",
- "(v) The specific entropy, and\n",
- "(iv) The specific enthalpy,\n",
- "(vi) The specific internal energy.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"V = 0.05; \t\t\t#m**3\n",
@@ -214,9 +200,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the amount of heat\n",
- "'''\n",
"\n",
"# Variables\n",
"m_w = 2.; \t\t\t#kg\n",
@@ -267,9 +250,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "What amount of heat would be required to produce 4.4 kg of steam \n",
- "'''\n",
"\n",
"# Variables\n",
"m = 4.4; \t\t\t#kg\n",
@@ -322,9 +302,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the mass of 0.15 m 3 of wet steam and calculate the heat of 1 m 3 of steam.\n",
- "'''\n",
+ "\n",
"# Variables\n",
"v = 0.15; \t\t\t#m**3\n",
"p = 4.; \t\t\t#bar\n",
@@ -369,11 +347,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine\n",
- "(i) The total heat supplied to feed water per hour to produce wet steam.\n",
- "(ii) The total heat absorbed per hour in the superheater.\n",
- "'''\n",
"\n",
"# Variables\n",
"m = 1000.; \t\t\t#kJ/kg.K\n",
@@ -421,11 +394,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the mean specific heat for superheated steam :\n",
- "(i) at 0.75 bar, between 100\u00b0C and 150\u00b0C ;\n",
- "(ii) at 0.5 bar, between 300\u00b0C and 400\u00b0C\n",
- "'''\n",
"\n",
"\n",
"print (\"(i) at 0.75 bar, between 100\u00b0C and 150\u00b0C\")\n",
@@ -479,9 +447,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the pressure and temperature of the steam at the new state.\n",
- "'''\n",
+ "\n",
"# Variables\n",
"m = 1.5; \t\t\t#kg\n",
"p = 5.; \t\t\t#bar\n",
@@ -543,12 +509,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine :\n",
- "(i) The mass of steam blown off ;\n",
- "(ii) The dryness fraction of steam in the vessel after cooling ;\n",
- "(iii) The heat lost by steam per kg during cooling.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"V = 0.9; \t\t\t#m**3\n",
@@ -620,11 +581,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) External work done during evaporation.\n",
- "(ii) Internal latent heat of steam.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p = 8*10**5; \t\t\t#Pa\n",
@@ -669,10 +626,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the heat supplied to raise the temperature of the steam to 300\u00b0C at constant pressure and\n",
- "percentage of this heat which appears as external work.\n",
- "'''\n",
+ "\n",
"\n",
"p1 = 10; \t\t\t#bar\n",
"import math \n",
@@ -722,9 +676,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the specific volume, enthalpy and internal energy of wet steam \n",
- "'''\n",
"\n",
"# Variables\n",
"p = 18.; \t\t\t#bar\n",
@@ -771,9 +722,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the dryness fraction, specific volume and internal energy of steam \n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p = 7.; \t\t\t#bar\n",
@@ -821,9 +770,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find the temperature, enthalpy and the internal energy.\n",
- "'''\n",
"\n",
"# Variables\n",
"p = 120.; \t\t\t#bar\n",
@@ -865,9 +811,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find the temperature,the specific volume and the internal energy.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p = 140.; \t\t\t#bar\n",
@@ -910,9 +854,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the internal energy per kg of superheated steam \n",
- "'''\n",
+ "\n",
"\n",
"# At 10 bar: From steam table for superheated steam\n",
"\n",
@@ -965,11 +907,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the internal energy of 1 kg of steam at 20 bar when\n",
- "(i) it is superheated, its temperature being 400\u00b0C ;\n",
- "(ii) it is wet, its dryness being 0.9.\n",
- "'''\n",
"\n",
"# Variables\n",
"m = 1.; \t\t\t#kg\n",
@@ -1024,9 +961,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the quality of steam supplied by the other boiler. Take c ps = 2.25 kJ/kg.\n",
- "'''\n",
+ "\n",
"# Variables\n",
"h_g1 = 2797.2; \t\t\t#kJ/kg\n",
"c_ps = 2.25;\n",
@@ -1071,9 +1006,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the entropy of 1 kg of wet steam \n",
- "'''\n",
+ "\n",
"\n",
"import math\n",
"\n",
@@ -1116,11 +1049,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find :\n",
- "(i) Drop in enthalpy ;\n",
- "(ii) Change in entropy.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 10.; \t\t\t#bar\n",
@@ -1177,10 +1106,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the entropy of 1 kg of superheated steam \n",
- "'''\n",
- "\n",
"\n",
"import math \n",
"\n",
@@ -1224,9 +1149,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the amount of work and heat transfer to or from steam\n",
- "'''\n",
+ "\n",
"# Variables\n",
"m = 3.; \t\t\t#kg\n",
"v1 = 0.75; \t\t\t#m**3/kg\n",
@@ -1281,9 +1204,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the dryness fraction of steam as it enters the tank \n",
- "'''\n",
"\n",
"# Variables\n",
"p = 5.; \t\t\t#bar\n",
@@ -1328,9 +1248,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the mass of steam condensed\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p = 1.1; \t\t\t#bar\n",
@@ -1375,9 +1293,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the dryness fraction of the steam \n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 8.; \t\t\t#bar\n",
@@ -1421,9 +1337,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Estimate the quality of steam supplied.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m_w = 2.; \t\t\t#kg\n",
@@ -1472,9 +1386,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the dryness fraction of the sample steam.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 15.; \t\t\t#bar\n",
diff --git a/Industrial_Instrumentation/ch4.ipynb b/Industrial_Instrumentation/ch4.ipynb
index 35fec4af..7eb1e631 100644
--- a/Industrial_Instrumentation/ch4.ipynb
+++ b/Industrial_Instrumentation/ch4.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:75cc662b83a20e10c962bb4b327ffefb7e8b88ef4b321db4fa8f1bf933a9eccf"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,8 +28,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "# Calculate the change in internal energy of the working fluid stating whether it is a gain or loss.\n",
- "\n",
+ "#\n",
"# Variables\n",
"Q = -50.; \t\t\t#kJ/kg\n",
"W = -100.; \t\t\t#kJ/kg\n",
@@ -64,9 +64,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate the heat flow to and from the cylinder\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"u1 = 450.; \t\t\t#kJ/kg\n",
@@ -104,9 +102,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the heat transferred from the nitrogen to the surroundings.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m = 0.3; \t\t\t#kg\n",
@@ -147,9 +143,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "How much did the internal energy of the gas change ?\n",
- "'''\n",
+ "\n",
"# Variables\n",
"p1 = 105.; \t\t\t#kPa\n",
"V1 = 0.4; \t\t\t#m**3\n",
@@ -189,11 +183,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine : (i) Work done ;\n",
- "(ii) Change in internal energy ; and\n",
- "(iii) Heat transferred\n",
- "'''\n",
+ "\n",
"import math\n",
"\n",
"# Variables\n",
@@ -248,9 +238,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the quantity of heat added to the system.\n",
- "'''\n",
+ "\n",
"\n",
"\n",
"# Variables\n",
@@ -291,11 +279,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine : \n",
- "(i) Work done ;\n",
- "(ii) Change in internal energy of the system.\n",
- "'''\n",
"\n",
"# Variables\n",
"Q2 = 9000.; \t\t\t#kJ\n",
@@ -337,13 +320,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine \u2206U, \u2206PE, \u2206KE, Q and W, when\n",
- "(i) the stone is about to enter the water,\n",
- "(ii) the stone has come to rest in the tank, and\n",
- "(iii) the heat is transferred to the surroundings in such an amount that the stone and water\n",
- "come to their initial temperature.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m = 20.; \t\t\t#kg\n",
@@ -404,14 +381,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) How much will be the heat that flows into the system along path lnm if the work done\n",
- "is 21 kJ ?\n",
- "(ii) When the system is returned from m to l along the curved path, the work done on the\n",
- "system is 42 kJ. Does the system absorb or liberate heat, and how much of the heat is absorbed\n",
- "or liberated ?\n",
- "(iii) If U l = 0 and U n = 84 kJ, find the heat absorbed in the processes ln and nm.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"Q_lqm = 168.; \t\t\t#kJ\n",
@@ -460,9 +430,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "What will be the change of internal energy of the system when its temperature changes\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -510,9 +478,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Completeing the table\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -587,9 +553,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the steam flow round the cycle in kg/s.\n",
- "'''\n",
"\n",
"# Variables\n",
"P = 1200.; \t\t\t#kW\n",
@@ -630,11 +593,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The change in internal energy ;\n",
- "(ii) The work done.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"dT = 25.; \t\t\t#0C\n",
@@ -677,12 +636,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Find the change in energy of the system.\n",
- "(ii) The system is returned to its initial volume by an adiabatic process which requires\n",
- "110 kJ of work. Find the change in energy of the system.\n",
- "(iii) For the combined processes of (i) and (ii) determine the change in energy of the system.\n",
- "'''\n",
"\n",
"# Variables\n",
"Q = 50.; \t\t\t#kJ\n",
@@ -736,11 +689,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) Change in internal energy ;\n",
- "(ii) Change in enthalpy.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -791,14 +740,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine:\n",
- "(i) If the expansion is quasi-static, find Q, \u2206U and W for the process.\n",
- "(ii) In another process, the same system expands according to the same pressure-volume\n",
- "relationship as in part (i), and from the same initial state to the same final state as in part (i), but\n",
- "the heat transfer in this case is 32 kJ. Find the work transfer for this process.\n",
- "(iii) Explain the difference in work transfer in parts (i) and (ii).\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"V1 = 0.25; \t\t\t#m**3\n",
@@ -853,13 +795,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find\n",
- "(i) Heat added/kg ;\n",
- "(ii) Work done/kg ;\n",
- "(iii) Change in internal energy/kg ;\n",
- "(iv) Change in enthalpy/kg.\n",
- "'''\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -928,9 +863,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the work done during the process.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m = 1.; \t\t\t#kg\n",
@@ -971,9 +904,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find the direction and magnitude of the work and heat transfer.\n",
- "'''\n",
+ "\n",
"\n",
"from numpy import *\n",
"from scipy.integrate import quad \n",
@@ -1030,11 +961,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The adiabatic work ;\n",
- "(ii) The values of internal energy at all end states if initial value is 105 kJ.\n",
- "'''\n",
"\n",
"# Variables\n",
"Qv = 90.; \t\t\t#kJ\n",
@@ -1088,12 +1014,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The work done ;\n",
- "(ii) The index of expansion, if the above processes are replaced by a single reversible polytropic\n",
- "process giving the same work between the same initial and final states.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"V1 = 0.2; \t\t\t#m**3\n",
@@ -1152,11 +1073,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Evaluate :\n",
- "(i) The work ;\n",
- "(ii) Decrease in internal energy of the system.\n",
- "'''\n",
"\n",
"# Variables\n",
"d = 0.15; \t\t\t#m\n",
@@ -1203,14 +1119,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The mass of gas ;\n",
- "(ii) The value of index \u2018n\u2019 for compression ;\n",
- "(iii) The increase in internal energy of the gas ;\n",
- "(iv) The heat received or rejected by the gas during compression.\n",
- "Take \u03b3 = 1.4, R = 294.2 J/kg\u00b0C.\n",
- "'''\n",
+ "\n",
"import math\n",
"\n",
"# Variables\n",
@@ -1274,12 +1183,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The final temperature ;\n",
- "(ii) The final volume ;\n",
- "(iii) The work done.\n",
- "'''\n",
"\n",
"# Variables\n",
"p1 = 1.02*10**5; \t#Pa\n",
@@ -1336,9 +1239,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate c p and c v .\n",
- "'''\n",
+ "\n",
"\n",
"from numpy import *\n",
"import math\n",
@@ -1390,9 +1291,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the heat flow to or from the cylinder walls.\n",
- "'''\n",
"\n",
"# Variables\n",
"n = 1.3;\n",
@@ -1441,12 +1339,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) Pressure at the end of constant volume cooling.\n",
- "(ii) Change in internal energy during constant volume process.\n",
- "(iii) Net work done and heat transferred during the cycle. Assume\n",
- "'''\n",
+ "\n",
"import math\n",
"\n",
"# Variables\n",
@@ -1513,9 +1406,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the net work done and heat transferred during the cycle.\n",
- "'''\n",
"\n",
"import math\n",
"\n",
@@ -1571,11 +1461,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Sketch the cycle on p-V diagram.\n",
- "(ii) Calculate the work done in each process starting whether it is done on or by the system\n",
- "and evaluate the net cyclic work and heat transfer.\n",
- "'''\n",
+ "\n",
"\n",
"%pylab inline\n",
"\n",
@@ -1705,9 +1591,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine theamount of heat added to the system so that piston moves by 3.5 cm.\n",
- "'''\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -1770,11 +1653,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The change in enthalpy (\u2206 h) ;\n",
- "(ii) Work done during the process (W).\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"r = 10.; \t\t\t#kg/min\n",
@@ -1837,12 +1716,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The rate at which heat is rejected to the turbine, and\n",
- "(ii) The area of the inlet pipe given that the specific volume of the gases at the inlet is\n",
- "0.45 m 3 /kg.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"\n",
@@ -1894,11 +1768,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The power required to drive the compressor ;\n",
- "(ii) The inlet and output pipe cross-sectional areas.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m = 0.5; \t\t\t#kg/s\n",
@@ -1954,9 +1824,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate the power developed by the turbine. Consider the boiler and turbine as single system\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"h1 = 800.; \t\t\t#kJ/kg\n",
@@ -1998,9 +1866,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the power output of the turbine.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"g = 9.8; \t\t\t#m/s**2\n",
@@ -2044,9 +1910,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the final enthalpy of steam.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 6.87; \t\t\t#bar\n",
@@ -2088,9 +1952,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the power capacity of the system in MW.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m = 220./60; \t\t\t#kg/s\n",
@@ -2135,9 +1997,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the capacity of the turbine if the gas flow is 5 kg/s.\n",
- "'''\n",
"\n",
"\n",
"# Variables\n",
@@ -2181,10 +2040,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find : (i) Motor power required to drive the compressor ;\n",
- "(ii) Ratio of inlet to outlet pipe diameter.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"C1 = 12.; \t\t\t#m/s\n",
@@ -2235,9 +2091,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Compute the amount of heat transfer to the atmosphere from the compressor per kg of air.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"W = -175.; \t\t\t #kJ/kg\n",
@@ -2277,12 +2131,6 @@
"collapsed": false,
"input": [
"\n",
- "'''\n",
- "(i) Find the velocity at exit of the nozzle.\n",
- "(ii) If the inlet area is 900 cm 2 and the specific volume at inlet is 0.187 m 3 /kg, find the mass\n",
- "flow rate.\n",
- "(iii) If the specific volume at the nozzle exit is 0.498 m 3 /kg, find the exit area of nozzle.\n",
- "'''\n",
"import math\n",
"\n",
"# Variables\n",
@@ -2339,9 +2187,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "evaluate the heat transfer from the water per kg of water flowing.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"h1 = 240.; \t\t\t#kJ/kg\n",
@@ -2380,9 +2226,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "evaluate the relative velocity of gas leaving the jet pipe. For the gas at t = 820\u00b0C, h = 800 kJ/kg and at 910\u00b0C, 915 kJ/kg.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -2424,9 +2268,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the capacity of the electric motor to run the pump.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -2474,9 +2316,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the velocity of the exhaust jet.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -2524,11 +2364,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate :\n",
- "(i) Rate of heat transfer to the air in the heat exchanger ;\n",
- "(ii) The power output from the turbine assuming no heat loss ;\n",
- "'''\n",
"\n",
"# Variables\n",
"t1 = 20.; \t\t\t#0C\n",
@@ -2584,11 +2419,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The state of steam after cooling ;\n",
- "(ii) The amount of heat rejected by the steam.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"V = 0.028; \t\t\t#m**3\n",
@@ -2644,11 +2475,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) Heat supplied ;\n",
- "(ii) Work done\n",
- "'''\n",
"\n",
"# Variables\n",
"m = 0.08; \t\t\t#kg\n",
@@ -2697,9 +2523,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the heat supplied, and show on a T-s diagram the area which represents the heat flow.\n",
- "'''\n",
+ "\n",
"from numpy import *\n",
"from matplotlib.pyplot import *\n",
"\n",
@@ -2789,12 +2613,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate per kg :\n",
- "(i) The change of internal energy ;\n",
- "(ii) The change of enthalpy ;\n",
- "(iii) The work done.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 7.*10**5; \t\t\t#Pa\n",
@@ -2858,11 +2677,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate per kg of steam :\n",
- "(i) Work done ;\n",
- "(ii) Heat flow to or from the cylinder walls.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -2923,11 +2738,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate per kg of steam :\n",
- "(i) The heat supplied ;\n",
- "(ii) The work done.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 100.; \t\t\t#bar\n",
@@ -2975,9 +2786,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the work done by the steam.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m = 1.; \t\t\t#kg\n",
@@ -3020,11 +2829,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate per kg of steam :\n",
- "(i) The work done during expansion ;\n",
- "(ii) The heat flow to or from the cylinder walls during the expansion.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 7.*10**5; \t\t\t#N/m**2\n",
@@ -3083,9 +2888,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the work done per kg of steam flow through the turbine\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 15.; \t\t\t#bar\n",
@@ -3133,9 +2936,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the quality of the steam leaving the nozzle.\n",
- "'''\n",
+ "\n",
"# Variables\n",
"p1 = 10.; \t\t\t#bar\n",
"t1 = 200.; \t\t\t#0C\n",
@@ -3178,9 +2979,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the initial dryness fraction of the steam.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"h1 = 2776.4; \t\t\t#kJ/kg\n",
@@ -3219,9 +3018,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the exit condition of steam using Mollier chart.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 10.; \t\t\t#bar\n",
@@ -3260,11 +3057,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Change in entropy ;\n",
- "(ii) Change in enthalpy ;\n",
- "(iii) Change in internal energy.\n",
- "'''\n",
+ "\n",
"\n",
"\n",
"import math \n",
@@ -3370,8 +3163,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "# Calculate the mass of air which has left the receiver.\n",
- "\n",
"\n",
"# Variables\n",
"V1 = 5.5; \t\t\t#m**3\n",
@@ -3418,10 +3209,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the work obtainable by utilising the kinetic energy of the discharge air to run a frictionless\n",
- "turbine\n",
- "'''\n",
+ "\n",
"# Variables\n",
"cp = 1.; \t\t\t#kJ/kg.K\n",
"cv = 0.711; \t\t\t#kJ/kg.K\n",
@@ -3471,11 +3259,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Final state condition ;\n",
- "(ii) Work done by the piston ;\n",
- "(iii) Heat transferred to oxygen.\n",
- "'''\n",
+ "\n",
"\n",
"#For oxygen\n",
"import math \n",
diff --git a/Industrial_Instrumentation/ch5.ipynb b/Industrial_Instrumentation/ch5.ipynb
index 575e68d6..66f7a8b4 100644
--- a/Industrial_Instrumentation/ch5.ipynb
+++ b/Industrial_Instrumentation/ch5.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:12efbfeaa3ed3ebbe140abe577bbac08dcae30fc36caa52e184adf21fd445870"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,11 +28,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The thermal efficiency \n",
- "(ii) The rate of heat rejection.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"Q1 = 1500./60; \t\t#kJ/s\n",
@@ -74,9 +71,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Is it possible to reach initial state by an adiabatic process ?\n",
- "'''\n",
"\n",
"# Variables\n",
"Q_12 = 30.; \t\t#kJ\n",
@@ -117,9 +111,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the co-efficient of performance and heat transfer rate in the condenser of a refrigerator \n",
- "'''\n",
+ "\n",
"# Variables\n",
"Q2 = 12000.; \t\t\t#kJ/h\n",
"W = 0.75*60*60; \t\t#kJ/h\n",
@@ -157,10 +149,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the least power necessary to pump this heat out continuously\n",
- "'''\n",
- "# Variables\n",
+ "\n",
"T2 = 261.; \t\t\t#K\n",
"T1 = 308.; \t\t\t#K\n",
"Q2 = 2.; \t\t\t#kJ/s\n",
@@ -197,11 +186,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) Heat abstracted from outside ;\n",
- "(ii) Co-efficient of performance.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -244,10 +229,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "What is the highest possible theoretical efficiency of a heat engine operating\n",
- "with a hot reservoir of furnace gases \n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"T1 = 2373; \t\t\t#K\n",
@@ -284,12 +266,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find :\n",
- "(i) Efficiency of the system ;\n",
- "(ii) The net work transfer ;\n",
- "(iii) Heat rejected to sink.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"T1 = 523.; \t\t\t#K\n",
@@ -333,10 +310,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "An inventor claims that his engine has few specifications :\n",
- "State whether his claim is valid or not.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"T1 = 1023.; \t\t#K\n",
@@ -382,9 +356,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the least rate of heat rejection per kW net output of the engine ?\n",
- "'''\n",
"\n",
"# Variables\n",
"T1 = 1273.; \t\t#K\n",
@@ -424,9 +395,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate the power required\n",
- "'''\n",
"\n",
"# Variables\n",
"one_ton_of_refrigeration = 210.; \t\t\t#kJ/min\n",
@@ -467,10 +435,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Which source (1 or 2) would you choose to supply energy to an ideal reversible heat engine that is to produce large amount of\n",
- "power if the temperature of the surroundings is 35\u00b0C ?\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"E = 12000.; \t\t#kJ/min\n",
@@ -522,12 +487,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- ".'''\n",
- "(i) Determine the heat transfer to the refrigerant and the net heat transfer to the reservoir\n",
- "at 50\u00b0C ;\n",
- "(ii) Reconsider (i) given that the efficiency of the heat engine and the C.O.P. of the refrig-\n",
- "erator are each 45 per cent of their maximum possible values.\n",
- "'''\n",
+ "\n",
"\n",
"\n",
"# Variables\n",
@@ -588,10 +548,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) determine the C.O.P. of the machine and work input required.\n",
- "(ii) determine the overall C.O.P. of the system.\n",
- "'''\n",
"\n",
"# Variables\n",
"T1 = 298.; \t\t\t#K\n",
@@ -648,12 +604,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) Power developed by the engine ;\n",
- "(ii) Fuel consumed per hour.\n",
- "Take enthalpy of fusion of ice = 334.5 kJ/kg.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"T_e1 = 493.; \t\t\t#K\n",
@@ -703,9 +654,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the intermediate temperature.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"T1 = 550.; \t\t\t#K\n",
@@ -742,12 +691,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine :\n",
- "(i) The temperature T 3 such that heat supplied to engine Q 1 is equal to the heat absorbed\n",
- "by refrigerator Q 2 .\n",
- "(ii) The efficiency of Carnot engine and C.O.P. of Carnot refrigerator.\n",
- "'''\n",
"\n",
"# Variables\n",
"T1 = 600.; \t\t\t#K\n",
@@ -794,9 +737,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "estimate the energy taken from the reservoir at 1077\u00b0C.\n",
- "'''\n",
"\n",
"# Variables\n",
"T3 = 278.; \t\t\t#K\n",
@@ -835,10 +775,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Classify which of the result report a reversible cycle or irreversible cycle or impossible\n",
- "results.\n",
- "'''\n",
+ "\n",
"# Variables\n",
"Q1 = 300.; \t\t\t#kJ/s\n",
"T1 = 290.; \t\t\t#0C\n",
@@ -895,9 +832,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Verify the Clausius inequality for the cycle.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"P1 = 0.124*10**5; \t\t\t#N/m**2\n",
@@ -943,7 +878,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''Verify the Clausius Inequality'''\n",
+ "\n",
"\n",
"# Variables\n",
"T1 = 437.; \t\t\t#K\n",
@@ -990,9 +925,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the entropy changes for the iron cube and the water. Is the process reversible ? If so why ?\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1044,11 +977,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The net heat flow from the air.\n",
- "(ii) The net entropy change.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1104,12 +1033,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The change of entropy,\n",
- "(ii) The heat flow, and\n",
- "(iii) The work done.\n",
- "'''\n",
"\n",
"%pylab inline\n",
"\n",
@@ -1222,9 +1145,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the change in entropy.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1265,9 +1186,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the change of entropy\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1317,9 +1236,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the change of entropy \n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -1369,10 +1285,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Show that the process is irreversible ;\n",
- "(ii) Calculate the change of entropy per kg of air.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1424,14 +1337,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine : \n",
- "(i) Change in enthalpy ;\n",
- "(ii) Change in internal energy ;\n",
- "(iii) Change in entropy ;\n",
- "(iv) Heat transfer ;\n",
- "(v) Work transfer.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1488,13 +1394,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) Change in internal energy,\n",
- "(ii) Work done,\n",
- "(iii) Heat transferred, and\n",
- "(iv) Change in entropy\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1551,9 +1451,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the net work. Also plot the processes on T-S diagram\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from matplotlib.pyplot import *\n",
@@ -1644,11 +1542,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The heat supplied.\n",
- "(ii) The entropy change.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"V1 = 0.004; \t\t\t#m**3\n",
@@ -1699,11 +1593,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) Change in entropy.\n",
- "(ii) Work done\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1756,12 +1646,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) Final specific volume and temperature.\n",
- "(ii) Change of internal energy, work done and heat interaction.\n",
- "(iii) Change in entropy.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1831,11 +1716,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(b)What would be the percentage error if the entropy change is calculated by dividing the\n",
- "quantity of heat exchanged by the mean absolute temperature during the process ?\n",
"\n",
- "'''\n",
"%pylab inline\n",
"import math\n",
"from matplotlib.pyplot import *\n",
@@ -1934,11 +1815,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate :\n",
- "(i) The net heat flow.\n",
- "(ii) The overall change in entropy.\n",
- "'''\n",
"\n",
"from matplotlib.pyplot import *\n",
"from numpy import *\n",
@@ -2032,11 +1908,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Constant volume heat addition till pressure becomes 5 bar, \n",
- "(ii) Constant pressure cooling, and \n",
- "(iii) Isothermal heating to initial state.\n",
- "'''\n",
"\n",
"import math \n",
"from matplotlib.pyplot import *\n",
@@ -2151,9 +2022,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the entropy change of 4 kg of a perfect gas \n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -2197,9 +2066,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find the entropy of the gas at 25 bar and 750 K temperature.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -2250,12 +2117,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) Final equilibrium temperature,\n",
- "(ii) Final pressure on each side of the diaphragm, and\n",
- "(iii) Entropy change of system.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -2323,9 +2185,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the change in entropy in each of the adiabatic processes.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -2374,11 +2234,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Determine the heat interactions with the other two sources of heat.\n",
- "(ii) Evaluate the entropy change due to each heat interaction with the engine.\n",
- "(iii) Total entropy change during the cycle.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from numpy import *\n",
@@ -2448,9 +2304,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the maximum amount of work that can be recovered as the system is cooled down to the temperature of the reservoir.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -2503,9 +2357,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Establish the direction of the flow of the air in the duct.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -2562,9 +2414,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the change of entropy due to mixing process.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -2610,14 +2460,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(a)find :\n",
- "(i) Entropy change of water ;\n",
- "(ii) Entropy change of the heat reservoir ;\n",
- "(iii) Entropy change of the universe.\n",
- "(b)what will the entropy change of the universe be ?\n",
- "(c) Explain how water might be heated from 0\u00b0C to 90\u00b0C \n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -2694,10 +2537,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Determine the entropy increase of the universe.\n",
- "(ii) What is the minimum amount of work necessary to convert the water back into ice at \u2013 5\u00b0C ?\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
diff --git a/Industrial_Instrumentation/ch6.ipynb b/Industrial_Instrumentation/ch6.ipynb
index a3874b6a..2fc63442 100644
--- a/Industrial_Instrumentation/ch6.ipynb
+++ b/Industrial_Instrumentation/ch6.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:b3244020b726410d1f880fd32ec7c61d578b2f34e3bde3131de02645aee53468"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,9 +28,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the irreversibility if the sink temperature is 293 K. \n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -78,11 +77,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find\n",
- "(i) The entropy produced during heat transfer ;\n",
- "(ii) The decrease in available energy after heat transfer.\n",
- "'''\n",
"\n",
"# Variables\n",
"T1 = 1000.; \t\t\t#K\n",
@@ -132,13 +126,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The availability if the system goes through the ideal work producing process.\n",
- "(ii) The availability and effectiveness if the air is cooled at constant pressure to atmos-\n",
- "pheric temperature without bringing it to complete dead state. Take c v = 0.718 kJ/kg K ;\n",
- "c p = 1.005 kJ/kg K\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -204,9 +192,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Obtain the results on the basis of 1 kg of water.\n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -257,9 +242,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find the loss in available energy due to above heat transfer.\n",
- "'''\n",
"\n",
"import math\n",
"\n",
@@ -309,9 +291,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the unavailable energy in 60 kg of water at 60\u00b0C \n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -360,9 +340,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find the loss in availability for the process.\n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -407,11 +384,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Determine the availability of the system if the surrounding pressure and temperature\n",
- "are 1 bar and 290 K respectively.\n",
- "(ii) determine the availability and effectiveness\n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -472,9 +444,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine actual and minimum power required to run the compressor. \n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -527,9 +497,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the loss in availability if the surrounding temperature is 290 K.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -584,9 +552,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the decrease in available energy \n",
- "'''\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -650,9 +615,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the loss in availability on the basis of one kg of oil per second.\n",
- "'''\n",
"\n",
"import math\n",
"\n",
@@ -706,9 +668,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate the net increase in entropy and unavailable energy when the system reaches common temperature\n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -760,10 +719,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "What is the fraction of the available energy in the heat transferred from the process vapour\n",
- "at 400\u00b0C that is lost due to the irreversible heat transfer at 200\u00b0C ?\n",
- "'''\n",
"\n",
"# Variables\n",
"T1 = 673.; \t\t\t#K\n",
@@ -802,9 +757,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the effectiveness of the heating process when the atmospheric temperature is 15\u00b0C.\n",
- "'''\n",
+ "\n",
"import math \n",
"\n",
"# Variables\n",
@@ -848,11 +801,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate :\n",
- "(i) The ratio of mass flow of air initially at 100\u00b0C to that initially at 20\u00b0C.\n",
- "(ii) The effectiveness of heating process, if the atmospheric temperature is 20\u00b0C.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -902,12 +851,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine :\n",
- "(i) The maximum work ;\n",
- "(ii) The change in availability ;\n",
- "(iii) The irreversibility.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -964,12 +908,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine per kg of air :\n",
- "(i) The decrease in availability ;\n",
- "(ii) The maximum work ;\n",
- "(iii) The irreversibility.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1027,11 +966,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine\n",
- "(i) The irreversibility ;\n",
- "(ii) The effectiveness.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1085,11 +1020,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) find the rise in the temperature of the bearings when the flywheel has come to rest.\n",
- "(ii) Calculate the greatest possible amount of the above heat which may be returned to the\n",
- "flywheel? What would be the final r.p.m. of the flywheel, if it is set in motion with this available energy ?\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -1160,11 +1091,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) Reversible work and actual work assuming the process to be adiabatic ;\n",
- "(ii) Irreversibility and effectiveness of the system on the basis of 1 kg of air flow.\n",
- "'''\n",
+ "\n",
"\n",
"import math\n",
"\n",
@@ -1230,12 +1157,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The isentropic efficiency of the process ;\n",
- "(ii) The loss of availability of the system assuming an atmospheric temperature of 20\u00b0C ;\n",
- "(iii) The effectiveness of the process ;\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p1 = 20.; \t\t\t#bar\n",
diff --git a/Industrial_Instrumentation/ch7.ipynb b/Industrial_Instrumentation/ch7.ipynb
index f35bb080..50954e24 100644
--- a/Industrial_Instrumentation/ch7.ipynb
+++ b/Industrial_Instrumentation/ch7.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:83b04c725ceaf9254a1b319f62cfdfa8f3ba518f51286a3d08dbbb299f685e47"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,14 +28,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the following :\n",
- "(i) Work done on the copper during the process,\n",
- "(ii) Change in entropy,\n",
- "(iii) The heat transfer,\n",
- "(iv) Change in internal energy, and\n",
- "(v) (c p \u2013 c v ) for this change of state.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"B = 5.*10**(-5); \t\t\t# /K\n",
@@ -89,9 +83,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Using Clausius-Claperyon\u2019s equation, find enthalpy of vapourisation.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"vg = 0.1274; \t\t\t#m**3/kg\n",
@@ -130,9 +122,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the pressure an ice skate blade must exert to allow smooth ice skate at \u2013 10\u00b0C.\n",
- "'''\n",
+ "\n",
"\n",
"import math\n",
"\n",
@@ -175,9 +165,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the specific volume v g of saturation mercury vapour at 0.1 bar\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"h_fg = 294.54; \t\t\t#kJ/kg\n",
diff --git a/Industrial_Instrumentation/ch8.ipynb b/Industrial_Instrumentation/ch8.ipynb
index 5b548006..0650ff08 100644
--- a/Industrial_Instrumentation/ch8.ipynb
+++ b/Industrial_Instrumentation/ch8.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:417a431bb73c0f7340e3aa0171c3fc4bd9ac17c782d95798e961af6aeee610ed"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,10 +28,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "How many kg of air must be removed from the chamber during the process ? Express this\n",
- "mass as a volume measured at 1 bar and 25\u00b0C.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -81,11 +79,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) How many kg of nitrogen will the flask hold at the designed conditions ?\n",
- "(ii) At what temperature must the fusible plug melt in order to limit the pressure of a full\n",
- "flask to a maximum of 150 bar ?\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"V = 0.04; \t\t\t#m**3\n",
@@ -135,12 +129,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) What mass of original gas must have escaped if the dimensions of the balloon is not\n",
- "changed ?\n",
- "(ii) Find the amount of heat to be removed to cause the same drop in pressure at constant\n",
- "volume.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -195,13 +184,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(i) Calculate pressure and the specific volume of the gas.\n",
- "(ii) evaluate the values of c p and c v .\n",
- "(iii) evaluate the final pressure of gas.\n",
- "(iv) Evaluate the increase in specific internal energy, the increase in specific enthalpy, increase\n",
- "in specific entropy and magnitude and sign of heat transfer.\n",
- "'''\n",
+ "\n",
"\n",
"from numpy import *\n",
"import math \n",
@@ -292,13 +275,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(a) \n",
- "determine :\n",
- "(i) The final specific volume, temperature and increase in entropy ;\n",
- "(ii) The work done and the heat transfer.\n",
- "(b) Repeat (a) assuming the process to be irreversible and adiabatic between end states.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -383,9 +360,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "determine the pressure in the spheres when the system attains equilibrium.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"d = 2.5; \t\t\t#m; diameter\n",
@@ -430,9 +405,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "evaluate the heat transfer rate from the gas and the power delivered by the turbine.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m = 6.5/60; \t\t\t#kg/s\n",
@@ -500,12 +473,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Evaluate the following :\n",
- "(i) The heat received in the cycle ;\n",
- "(ii) The heat rejected in the cycle ;\n",
- "(iii) Efficiency of the cycle.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -579,11 +547,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Compute the pressure by\n",
- "(i) Van der Waals\u2019 equation\n",
- "(ii) Perfect gas equation.\n",
- "'''\n",
+ "\n",
"\n",
"\n",
"# Variables\n",
@@ -633,13 +597,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Estimate the\n",
- "pressure exerted by CO 2 by using :\n",
- "(i) Perfect gas equation\n",
- "(ii) Van der Waals\u2019 equation\n",
- "(iii) Beattie Bridgeman equation.\n",
- "'''\n",
+ "\n",
"# Variables\n",
"V = 3.; \t\t\t#m**3\n",
"m = 10.; \t\t\t#kg\n",
@@ -699,11 +657,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "find :\n",
- "(i) The work done during the process\n",
- "(ii) The final pressure.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"from scipy.integrate import quad \n",
@@ -760,9 +714,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "compute the temperature.\n",
- "'''\n",
"\n",
"# Variables\n",
"pr = 20;\n",
@@ -801,9 +752,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the density using the compressibility chart\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p = 260.*10**5; \t\t\t#Pa\n",
@@ -846,9 +795,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "What should be the temperature of 1.3 kg of CO 2 gas to behave as an ideal ?\n",
- "'''\n",
+ "\n",
"# Variables\n",
"p = 200.*10**5; \t\t\t#Pa\n",
"pc = 73.86*10**5; \t\t\t#Pa\n",
@@ -888,9 +835,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find the mass of H 2 in the balloon using real gas equation.\n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -937,9 +881,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine the value of compressibility factor \n",
- "'''\n",
+ "\n",
"# Calculations\n",
"Z_cp = 3./2-9./8;\n",
"\n",
diff --git a/Industrial_Instrumentation/ch9.ipynb b/Industrial_Instrumentation/ch9.ipynb
index db39a5a3..fb7369a6 100644
--- a/Industrial_Instrumentation/ch9.ipynb
+++ b/Industrial_Instrumentation/ch9.ipynb
@@ -1,6 +1,7 @@
{
"metadata": {
- "name": ""
+ "name": "",
+ "signature": "sha256:48e3494ec100096b5d245db7f5c631c3ee779596f8c61001fb43d1b21ba3707b"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -27,11 +28,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The partial pressure of each constituent,\n",
- "(ii) The total pressure in the vessel, and\n",
- "'''\n",
"\n",
"# Variables\n",
"V = 0.35; \t\t\t#m**3\n",
@@ -91,10 +87,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate : (i) Gas constant for air ;\n",
- "(ii) Apparent molecular weight.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"R0 = 8.314;\n",
@@ -151,9 +144,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the analysis by volume and the partial pressure \n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p = 1.; \t\t\t#bar\n",
@@ -237,13 +228,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate for the mixture :\n",
- "(i) The masses of CO 2 , O 2 and N 2 , and the total mass ;\n",
- "(ii) The percentage carbon content by mass ;\n",
- "(iii) The apparent molecular weight and the gas constant for the mixture ;\n",
- "(iv) The specific volume of the mixture\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"p = 1.*10**5; \t\t\t#Pa\n",
@@ -335,11 +320,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate :\n",
- "(ii) The volume of the container.\n",
- "(i) The mass of O 2 required ;\n",
- "'''\n",
"\n",
"# Variables\n",
"p = 1.*10**5; \t\t\t#Pa\n",
@@ -394,9 +374,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate per mole of mixture the mass of mixture to be removed, and mass of CO to be added.\n",
- "'''\n",
+ "\n",
"\n",
"#Let composition of mixture by volume be denoted by c1\n",
"#Let Final composition desired be denoted by c2\n",
@@ -446,12 +424,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate per kg of gas :\n",
- "(i) The workdone ;\n",
- "(ii) The heat flow ;\n",
- "(iii) Change of entropy per kg of mixture.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -601,8 +574,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "# determine :\n",
- "# (i) Partial pressures of the constituents ; (ii) Gas constant of mixture.\n",
"\n",
"import math \n",
"\n",
@@ -680,16 +651,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Find :\n",
- "(i) The mole fraction of each constituent,\n",
- "(ii) The equivalent molecular weight of the mixture,\n",
- "(iii) The equivalent gas constant of the mixture,\n",
- "(iv) The partial pressures and partial volumes,\n",
- "(v) The volume and density of the mixture, and\n",
- "(vi) The c p and c v of the mixture.\n",
- "\n",
- "'''\n",
"\n",
"# Variables\n",
"p = 4.*10**5; \t\t \t#Pa\n",
@@ -829,12 +790,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The final temperature and pressure of the mixture ;\n",
- "(ii) The change of entropy of the system.\n",
"\n",
- "'''\n",
"\n",
"# Variables\n",
"Cv_O2 = 21.07; \t\t\t#kJ/mole K\n",
@@ -905,10 +861,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "(a) Calculate : (i) The final equilibrium pressure ;\n",
- "(ii) The amount of heat transferred to the surroundings ;\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -994,9 +947,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate the increase in entropy \n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1042,7 +993,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "# Calculate the mass of O 2 added.\n",
+ "\n",
"# Variables\n",
"m_N2 = 2.5; \t\t\t#kg \n",
"M_N2 = 28.;\n",
@@ -1084,13 +1035,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The moles of nitrogen per mole of oxygen ;\n",
- "(ii) The partial pressure of oxygen and nitrogen if the total pressure is atmosphere ;\n",
- "(iii) The kg of nitrogen per kg of mixture.\n",
"\n",
- "'''\n",
"\n",
"# Variables\n",
"n_O2 = 1.;\n",
@@ -1146,7 +1091,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- " # Find the masses of O 2 , N 2 and CO 2 in the cylinder.\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1216,12 +1161,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate-\n",
- "(i) The partial pressure ;\n",
- "(ii) The total pressure ;\n",
- "(iii) The mean value of R for the mixture.\n",
- "'''\n",
+ "\n",
"# Variables\n",
"V = 6; \t\t \t#m**3\n",
"A = 0.45; \n",
@@ -1283,13 +1223,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine-\n",
- "(i) The mole fraction of each component ; (ii) The average molecular weight ;\n",
- "(iii) The specific gas constant ;\n",
- "(iv) The volume and density ;\n",
- "(v) The partial pressures and partial volumes.\n",
- "'''\n",
+ "\n",
"\n",
"# Variables\n",
"m_O2 = 4.; \t\t\t#kg\n",
@@ -1381,11 +1315,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Calculate :\n",
- "(i) The final temperature of the mixture ; \n",
- "(ii) The change in entropy.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1450,9 +1380,6 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "calculate the entropy change in the mixing process.\n",
- "'''\n",
"\n",
"import math \n",
"\n",
@@ -1506,12 +1433,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "'''\n",
- "Determine :\n",
- "(i) The temperature of the equilibrium mixture ;\n",
- "(ii) The pressure of the mixture ;\n",
- "(iii) The change in entropy for each component and total value.\n",
- "'''\n",
+ "\n",
"\n",
"import math \n",
"\n",
@@ -1590,7 +1512,7 @@
"cell_type": "code",
"collapsed": false,
"input": [
- "# Calculate c v and c p of the mixture.\n",
+ "\n",
"\n",
"import math \n",
"\n",