diff options
Diffstat (limited to 'Engineering_Thermodynamics/ch2.ipynb')
-rwxr-xr-x | Engineering_Thermodynamics/ch2.ipynb | 136 |
1 files changed, 136 insertions, 0 deletions
diff --git a/Engineering_Thermodynamics/ch2.ipynb b/Engineering_Thermodynamics/ch2.ipynb new file mode 100755 index 00000000..d11b05b0 --- /dev/null +++ b/Engineering_Thermodynamics/ch2.ipynb @@ -0,0 +1,136 @@ +{ + "metadata": { + "name": "", + "signature": "sha256:b3d39c917cf6a960ba7edac2c3153505a96c95d76c51386c4b445bdbf3a8a712" + }, + "nbformat": 3, + "nbformat_minor": 0, + "worksheets": [ + { + "cells": [ + { + "cell_type": "heading", + "level": 1, + "metadata": {}, + "source": [ + "Chapter 2 : Temperature" + ] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.1 Page No : 35" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math \n", + "\n", + "# Variables\n", + "d = 1\n", + "l = 1; \t\t\t# Assuming\n", + "\n", + "# Calculation\n", + "A_ACDB = (math.pi/4)*(1./3)*((1.05*d)**2)*10.5*l - (math.pi/4)*(1./3)*d**2*10*l ; \t\t\t# Area of ABCD\n", + "A_AEFB = (math.pi/4)*(1./3)*((1.1*d)**2)*11*l - (math.pi/4)*(1./3)*d**2*10*l;\n", + "t = 100*(A_ACDB/A_AEFB);\n", + "\n", + "# Results\n", + "print \"The straight bore thermometer reading would e %.1f degree Celcius\"%t\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The straight bore thermometer reading would e 47.6 degree Celcius\n" + ] + } + ], + "prompt_number": 3 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.2 Page No : 37" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "from hornerc import horner\n", + "\n", + "# Calculation\n", + "#e0 = horner(e, 0.); \t\t\t# e.m.f. at t = 0 degree\n", + "e100 = horner([0,0.2,-5e-04], 100.); \t\t\t# e.m.f. at t = 100 degree\n", + "e50 = horner([0,0.2,-5e-04],50); \t\t\t# e.m.f. at t = 50 degreer\n", + "r = (100./e100)*e50; \t\t\t# Reading of thermocouple at t = 50degree\n", + "\n", + "# Results\n", + "print \"Reading of thermocouple at t = 50 degree is %.2f degree Celcius \"%r\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Reading of thermocouple at t = 50 degree is 58.33 degree Celcius \n" + ] + } + ], + "prompt_number": 2 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.3 Page No : 37" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "\n", + "# Variables\n", + "R0 = 2.8; \t\t\t# Resistence at t=0 degree in ohm\n", + "R100 = 3.8; \t\t\t# Resistence at t = 100 degree in ohm\n", + "\n", + "# Calculation\n", + "a = (R100/R0 - 1)*0.01; \t\t\t# alpha\n", + "R = 5.8; \t\t\t# Indicated ressistace in ohm\n", + "t = (R/R0 - 1)/a; \t\t\t# Temperature in degree\n", + "\n", + "# Results\n", + "print \"The temperature when indicated resismath.tance is 5.8 ohm is \",t,\"degree\"\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The temperature when indicated resismath.tance is 5.8 ohm is 300.0 degree\n" + ] + } + ], + "prompt_number": 3 + } + ], + "metadata": {} + } + ] +}
\ No newline at end of file |