summaryrefslogtreecommitdiff
path: root/Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb
diff options
context:
space:
mode:
authorTrupti Kini2016-09-09 23:30:25 +0600
committerTrupti Kini2016-09-09 23:30:25 +0600
commit5e4af9aebb389109363666017f67e986e96a9906 (patch)
treec742461131f848fc6bc7a1938672eba69f20ceb2 /Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb
parentcd810407802a7f89116285be29c37f8e4c477111 (diff)
downloadPython-Textbook-Companions-5e4af9aebb389109363666017f67e986e96a9906.tar.gz
Python-Textbook-Companions-5e4af9aebb389109363666017f67e986e96a9906.tar.bz2
Python-Textbook-Companions-5e4af9aebb389109363666017f67e986e96a9906.zip
Added(A)/Deleted(D) following books
A Heat_Transfer_Principles_And_Applications_by_Dutta/README.txt A Heat_Transfer_Principles_And_Applications_by_Dutta/ch10.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch11.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch2.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch3.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch4.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch5.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch6.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch7.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch8.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/ch9.ipynb A Heat_Transfer_Principles_And_Applications_by_Dutta/screenshots/10.png A Heat_Transfer_Principles_And_Applications_by_Dutta/screenshots/5.png A Heat_Transfer_Principles_And_Applications_by_Dutta/screenshots/51.png A Heat_Transfer_in_SI_units_by_Holman/Chapter1.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter10.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter11.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter2.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter3.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter5.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter6.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter7.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter8.ipynb A Heat_Transfer_in_SI_units_by_Holman/Chapter9.ipynb A Heat_Transfer_in_SI_units_by_Holman/README.txt A Heat_Transfer_in_SI_units_by_Holman/screenshots/9.1.png A Heat_Transfer_in_SI_units_by_Holman/screenshots/9.2.png A Heat_Transfer_in_SI_units_by_Holman/screenshots/9.4.png A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter1.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter2.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter3.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter4.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter5.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter6.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter7.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter8.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/Chapter9.ipynb A Power_Electronics_Principles_and_Applications_by_Jacob/README.txt A Power_Electronics_Principles_and_Applications_by_Jacob/screenshots/4.png A Power_Electronics_Principles_and_Applications_by_Jacob/screenshots/5.png A Power_Electronics_Principles_and_Applications_by_Jacob/screenshots/6.png A sample_notebooks/AviralYadav/Chapter5.ipynb
Diffstat (limited to 'Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb')
-rw-r--r--Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb669
1 files changed, 669 insertions, 0 deletions
diff --git a/Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb b/Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb
new file mode 100644
index 00000000..3363aee9
--- /dev/null
+++ b/Heat_Transfer_in_SI_units_by_Holman/Chapter4.ipynb
@@ -0,0 +1,669 @@
+{
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Chapter 4 Unsteady State Conduction"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.1"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "hV/A/k is: 0.0024 which is less than 0.1,So by eq 4.5\n",
+ "hA/pcV is 0.000334448160535 per second\n",
+ "Time is 5818.0 seconds\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.1\n",
+ "# Calculate the time required for ball to attain a temperature of 150 deg C.\n",
+ "\n",
+ "#variables:\n",
+ "\n",
+ "c=460.0 \t# kJ/kg\n",
+ "k=35.0 \t#W/m\n",
+ "d=0.05 \t# diameter in meter\n",
+ "r=d/2 \t\t# radius in meter\n",
+ "h=10.0 \t#convection heat transfer coeff in W/sq meter\n",
+ "T=150.0 \t#Temperature in deg C\n",
+ "p=7800 \t#Density in kg/cubic meter\n",
+ "Ti=100.0 \t# T,infinity ..in celsius\n",
+ "To=450.0 \t# in Celsius\n",
+ "\n",
+ "#CALCULATION\n",
+ "\n",
+ "import math \n",
+ "A=(4*math.pi) * (r**2) \t\t\t #Arear in sq meter\n",
+ "V=(A*r/3) \t\t\t\t # Volume in cubic meters\n",
+ "c1=(h*(V/A))/k \t \t\t #it is less than 0.1 So,\n",
+ "print \"hV/A/k is:\",round(c1,4),\"which is less than 0.1,So by eq 4.5\"\n",
+ "c2=((h*A)/(p*c*V)) \t\t # assumed variable for easiness\n",
+ "\n",
+ "#RESULTS\n",
+ "\n",
+ "print \"hA/pcV is\",c2,\"per second\"\n",
+ "t=(-1/c2)*(math.log((T-Ti)/(To-Ti))) \n",
+ "print \"Time is\",round(t),\"seconds\"\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.2"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 4,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Temperature at depth of 0 .025 m after 30 s for case 1 is 118.5 degree celsius \n",
+ "Temperature at depth of 0 . 0 2 5 m after 30 second for case 2 is 79.3 degree celsius\n",
+ "Surface temperature after 30 second is: 199.4 degree celsius \n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.2\n",
+ "#Calculate the temperature at a depth of 2.5 cm after 0.5 min for both cases\n",
+ "import math\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "k = 45 \t\t\t\t# [W/m per deg C ] thermal conductivity of steel block\n",
+ "alpha = 1.4*10**( -5) ; \t# [ square meter / s ] constant\n",
+ "Tb = 35 \t\t\t# [ degree celsius ] block temperature\n",
+ "x = 0.025 \t\t\t# [m] depth at which temperature is calculated\n",
+ "t = 30 \t\t\t\t# [s]time after which temperature is to be calculated\n",
+ "To = 250 \t\t\t# [ degree celsius]\n",
+ "\n",
+ "\n",
+ "#CALCULATION & rESULT\n",
+ "\n",
+ "er=(x/(2*math.sqrt(alpha*t)))\t \t # error function short form\n",
+ "T_x_t = (To +(Tb -To)*( math.erf(er))) \n",
+ "\t\t\t\t\t # for the constant heat flux case B we \t\t\t\t\t\t make use of eq4.13 a\n",
+ "\t\t\t # since qo/A is given\n",
+ "\n",
+ "print \"Temperature at depth of 0 .025 m after 30 s for case 1 is\",round(T_x_t,1),\" degree celsius \"\n",
+ "q_by_A = 3.2*10**(5) ; \t\t\t\t# [W/ s qua r e meter ]\n",
+ "\n",
+ "T_x_t1 =(Tb +(2* q_by_A*math.sqrt(alpha*t/math.pi)*math.exp(-(x**2)/(4*alpha *t))/k) -(q_by_A *x*(1 - math.erf(er))/k)) \t\t# [ degree celsius ]\n",
+ "\n",
+ "print \"Temperature at depth of 0 . 0 2 5 m after 30 second for case 2 is\",round(T_x_t1,1),\"degree celsius\" \n",
+ "\t\t\t\t# for the constant heat flux case the surface \t\t\t\t temperature after 30 s would be evaluated with x= 0 \t\t\t\t in equation(4.13 a )\n",
+ "x = 0 \t\t\t\t\t\t\t\t# [m] at the surface\n",
+ "\n",
+ "T_x_o = Tb +(2* q_by_A *math.sqrt(alpha*t/math.pi) * math.exp (-(x **2)/(4*alpha*t))/k) -(q_by_A*x*(1 -math.erf (er))/k) \t\t# [degree celsius]\n",
+ "\n",
+ "print \"Surface temperature after 30 second is:\",round(T_x_o,1) ,\"degree celsius \" \n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.3"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 5,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "ASSUMPTION: Negligible radiation effects\n",
+ "At x=0\n",
+ "At x=2mm ie 0.002 m\n",
+ "0.002\n",
+ "T =: 513.0 Celsius\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.3\n",
+ "#Estimate the temperature at the surface and at a depth of 2 mm after 2 sec\n",
+ " \t\t\t#Qo/A=10^7 J/sq meter\n",
+ "import math \t \t# import math file\n",
+ "\n",
+ "#variable declaration\n",
+ "\n",
+ "c1=10 \t\t# =Qo/A laser pulse in MJ/sq meter\n",
+ "c1=(c1*10**6) \t\t# convert in joule from MJ\n",
+ "p=7800 \t\t\t# Density in kg/cubic meter\n",
+ "c=460\t\t\t#J/kg\n",
+ "a=(0.44*(10**(-5))) \t# sq m/sec\n",
+ "t=2 \t\t\t# time in seconds\n",
+ "Ti=40.0 \t\t# initial temp in deg C\n",
+ "\n",
+ "print \"ASSUMPTION: Negligible radiation effects\"\n",
+ "#From eqq 4.13,:\n",
+ "print \"At x=0\"\n",
+ "\n",
+ "#calculation\n",
+ "To=Ti+(c1/(p*c*math.sqrt((math.pi)*a*t)))\n",
+ "print \"At x=2mm ie 0.002 m\"\n",
+ "x=0.002\n",
+ "print x\n",
+ "T=(Ti+(c1/(p*c*math.sqrt((math.pi)*a*t)))*(math.exp(-(x**2)/(4*a*t))))\n",
+ "\n",
+ "#RESULTS\n",
+ "print \"T =:\", round(T),\"Celsius\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.5"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 6,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "The iteration are listed below\n",
+ " h*math.sqrt(alpha*t)/k x/(2*sqrt(alpha*t)) (T_x_t-Ts)/(Te-Ts)\n",
+ "1000 0.708 0.069 0.41\n",
+ "3000 1.226 0.04 0.61\n",
+ "4000 1.415 0.035 0.68\n",
+ "Consequently the time required is approximately 3000 second\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.5:Sudden exposure of semi-infinite solid slab to convection\n",
+ "# Calculate time req for the temp to reach 120 deg C at depth of 4 cm\n",
+ "\n",
+ "#VARIABLE DECLARATION\n",
+ "\n",
+ "alpha = 8.4*10**(-5) \t\t# [square meter/s] constant\n",
+ "Ts = 200\t\t # [degree celsius] initial temperature of of slab\n",
+ "Te = 70\t\t\t\t# [degree celsius] environment temperature \n",
+ "k = 215 \t\t\t# [W/m deg C] heat transfer coefficient of slab\n",
+ "h = 525 \t\t\t# [W/sq m degree celsius] heat transfer coefficient \n",
+ "x = 0.04\t\t\t# [m] depth at which temperature is calculated\n",
+ "T_x_t = 120 \t\t\t# [degree celsius] temperature at depth 0.04 m\n",
+ "\n",
+ "\t# using eq 4-15 or figure (4-5) for solution of this problem\n",
+ "\t# by using figure it is easier to calculate it involves iterative method to \tsolve because time appeares in both the variables \n",
+ "\n",
+ "\t# h*sqrt(alpha*t)/k and x/(2*sqrt(alpha*t))\n",
+ "K = (T_x_t-Ts)/(Te-Ts) \n",
+ "\t# Seek the values of t such that the above value of K is equal to the value of \tK which comes out from graph\n",
+ "\n",
+ "# values of t and obtain other readings\n",
+ "\n",
+ "#CALCULATION & RESULT\n",
+ "\n",
+ "print \"The iteration are listed below\"\n",
+ "\t# at t = 1000s\n",
+ "import math\n",
+ "t = 1000 # [s] time\n",
+ "A = h*math.sqrt(alpha*t)/k \n",
+ "B = x/(2*math.sqrt(alpha*t)) \n",
+ "\n",
+ "print \" h*math.sqrt(alpha*t)/k x/(2*sqrt(alpha*t)) (T_x_t-Ts)/(Te-Ts)\"\n",
+ "\n",
+ "print t,\" \",round(A,3),\" \",round(B,3),\" \",\"0.41\"\n",
+ "\n",
+ "t = 3000 \t\t\t# [s] time\n",
+ "A = h*math.sqrt(alpha*t)/k \n",
+ "B = x/(2*math.sqrt(alpha*t)) \n",
+ "\n",
+ "print t,\" \",round(A,3),\" \",round(B,3),\" \",\"0.61\"\n",
+ "\n",
+ "t = 4000 \t\t\t# [s] time\n",
+ "A = h*math.sqrt(alpha*t)/k \n",
+ "B = x/(2*math.sqrt(alpha*t)) \n",
+ " \n",
+ "print t,\" \",round(A,3),\" \",round(B,3),\" \",\"0.68\"\n",
+ "print \"Consequently the time required is approximately 3000 second\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.6"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 7,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Temperature at a depth of 1.25 cm from one of faces after 1 min of exposure of plate to the environment is 147.7 degree celsius\n",
+ "Energy removed per unit area from the plate in this time is 6475950.0 J/square meter\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.6-aluminium plate suddenly exposed to convection\n",
+ "#Calculate Energy removed /Area from the plate at this time\n",
+ "\n",
+ "#VARIABLE DECLARATION\n",
+ "alpha = 8.4*10**(-5) \t\t\t# [square meter/s] constant\n",
+ "Ts = 200 \t\t\t\t# [deg celsius] initial temperature of plate\n",
+ "Te = 70 \t\t\t\t# [degree celsius] environment temperature \n",
+ "k = 215 \t\t\t\t# [W/m deg C] heat transfer coeff of plate\n",
+ "h = 525 \t\t\t\t#[W/sq m deg C] heat transfer coefficient \n",
+ "x = 0.0125 \t\t\t\t#[m] depth at which temperature is calculated\n",
+ "t = 60\t\t\t\t\t#[s]time after which temperature is calculated\n",
+ "L = 0.025 \t\t\t\t# [m] thickness of plate\n",
+ "\n",
+ "#CALCULATION\n",
+ "\n",
+ "theta_i = Ts-Te\t\t\t\t # [degree celsius]\n",
+ "\n",
+ "\t\t\t# then \n",
+ "Z = alpha*t/L**2 \n",
+ "X = k/(h*L) \n",
+ "x_by_L = x/L \n",
+ "\t\n",
+ "\t\t\t# from figure 4-7(page no.-144-145)\n",
+ "\n",
+ "theta_o_by_theta_i = 0.61 \n",
+ "theta_o = theta_o_by_theta_i*theta_i # [degree celsius]\n",
+ "\t\t\t# from figure 4-10(page no.-149) at x/L = 0.5,\n",
+ "theta_by_theta_o = 0.98 \n",
+ "theta = theta_by_theta_o*theta_o \t# [degree celsius]\n",
+ "T = Te+theta \t\t\t\t# [degree celsius]\n",
+ "\n",
+ "\t\t\t# using Figure 4-14(page no.-152). For this calculation we \t\t\trequire the following properties of aluminium:\n",
+ "\t\n",
+ "rho = 2700 \t\t\t\t# [kg/cubic meter]\n",
+ "C = 900 \t\t\t\t# [J/kg degree celsius]\n",
+ "\n",
+ "\t\t\t# for figure 4-14(page no.-152) we need \n",
+ "\n",
+ "V = h**2*alpha*t/(k**2) \n",
+ "B = h*L/k \n",
+ "\n",
+ "\t\t\t# from figure 4-14(page no.-152)\n",
+ "\n",
+ "Q_by_Qo = 0.41 \n",
+ "\n",
+ "\t\t\t# for unit area \n",
+ "Qo_by_A = rho*C*2*L*theta_i \t\t# [J/square meter]\n",
+ "\n",
+ "# Now, heat removed per unit surface area is \n",
+ "Q_by_A = Qo_by_A*Q_by_Qo \t\t# [J/square meter]\n",
+ "\n",
+ "#RESULTS\n",
+ "\n",
+ "print\"Temperature at a depth of 1.25 cm from one of faces after 1 min of exposure of plate to the environment is\",round(T,1),\" degree celsius\" \n",
+ "\n",
+ "print\"Energy removed per unit area from the plate in this time is\",Q_by_A,\" J/square meter\" "
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.7"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 8,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Temperature at a radius of 1.25 cm is 118.4 degree celsius\n",
+ "Heat lost per unit length 1 minute after the cylinder is exposed to the environment is 403174.0 J/m\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example4.7-Long cylinder suddenly exposed to convection \n",
+ "\n",
+ "#VARIABLE DECLARATION\n",
+ "\n",
+ "d = 0.05 \t\t\t# [m] diameter of cylinder\n",
+ "Ti = 200 \t\t\t# [degree C] initial temperature of aluminium cylinder\n",
+ "Tinf = 70 \t\t\t# [degree celsius] temperature of environment\n",
+ "h = 525 \t\t\t# [W/sq m degree celsius] heat transfer coefficient\n",
+ "\n",
+ "#CALCULATION\n",
+ "\n",
+ "# we have\n",
+ "theta_i = Ti-Tinf \t\t# [degree celsius]\n",
+ "alpha = 8.4*10**(-5) \t\t# [square meter/s]\n",
+ "ro = d/2 \t\t\t# [m]\n",
+ "t = 60 \t\t\t\t# [s]\n",
+ "k = 215\t\t # [W/m degree celsius]\n",
+ "r = 0.0125 \t\t\t# [m]\n",
+ "rho = 2700 \t\t\t# [kg/cubic meter]\n",
+ "C = 900 \t\t\t# [J/kg degree celsius]\n",
+ "\n",
+ "\t# we compute\n",
+ "\n",
+ "Z = alpha*t/ro**2 \n",
+ "X = k/(h*ro) \n",
+ "r_by_ro = r/ro \n",
+ "\n",
+ "\n",
+ "\t# from figure 4-8(page no.-146)\n",
+ "theta_o_by_theta_i = 0.38 \n",
+ "\n",
+ "\t# from figure 4-11(page no.-150) at r/ro = 0.5\n",
+ "theta_by_theta_o = 0.98 \n",
+ "\n",
+ "\t# so that \n",
+ "theta_by_theta_i = theta_o_by_theta_i*theta_by_theta_o \n",
+ "theta = theta_i*theta_by_theta_i \t# [degree celsius]\n",
+ "T = Tinf+theta \t\t\t\t# [degree celsius]\n",
+ "\n",
+ "\t# to compute the heat lost, we determine\n",
+ "V = h**2*alpha*t/k**2 \n",
+ "B = h*ro/k \n",
+ "\n",
+ "\t# from figure 4-15(page no.-153)\n",
+ "Q_by_Qo = 0.65 \n",
+ "\n",
+ "\t# for unit length\n",
+ "import math\n",
+ "Qo_by_L = rho*C*math.pi*ro**2*theta_i \t# [J/m]\n",
+ "\n",
+ "\t#actual heat lost per unit length is \n",
+ "Q_by_L = Qo_by_L*Q_by_Qo \t\t# [J/m]\n",
+ "\n",
+ "\n",
+ "\n",
+ "#RESULTS\n",
+ "\n",
+ "print\"Temperature at a radius of 1.25 cm is\",round(T,1),\" degree celsius\" \n",
+ "print\"Heat lost per unit length 1 minute after the cylinder is exposed to the environment is\",round(Q_by_L),\"J/m\" "
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.8"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 10,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "The temperature at the axis is: 117.6 degree celsius\n",
+ "The temperature at the surface is 116.2 degree celsius\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.8-\n",
+ "#Calculate temperature at axis and surface of th cylinder 10 cm from end 1 min after exposure\n",
+ "\n",
+ "#VARIABLES DECLARATION\n",
+ "import math\n",
+ "\n",
+ "d = 0.05 \t\t# [m] diameter of aluminium cylinder \n",
+ "Ti = 200 \t\t# [degree celsius] initial temperature of of cylinder\n",
+ "Te = 70 \t\t# [degree celsius] environment temperature\n",
+ "k = 215 \t\t# [W/m degree celsius] heat transfer coefficient of plate\n",
+ "h = 525 \t\t# [W/sq m degree celsius] convection heat transfer coefficient \n",
+ "alpha = 8.4*10**(-5) # [square meter/s] constant\n",
+ "x = 0.10 \t\t# [m] distance at which temperature is calculated from end\n",
+ "t = 60 \t\t\t# [s] time after which temperature is measured\n",
+ "\t# so that the parameters for use with figure(4-5)\n",
+ "\n",
+ "#CALCULATION\n",
+ "A = h*math.sqrt(alpha*t)/k \n",
+ "B = x/(2*math.sqrt(alpha*t)) \n",
+ "# from figure (4-5)\n",
+ "z = 1-0.036 \n",
+ "S_of_X = z \n",
+ "\t# for the infinite cylinder we seek both the axis- and surface-temperature \tratios.\n",
+ "\t# the parameters for use with fig(4-8) are \n",
+ "r_o = d/2 \t\t\t# [m] radius of aluminium cylinder \n",
+ "r = d/2 \t\t\t# [m] for surface temperature ratio\n",
+ "C = k/(h*r_o) \n",
+ "D = (alpha*t/r_o**(2)) \n",
+ "y = 0.38 \n",
+ "\n",
+ "\t# this is the axis temperature ratio.\n",
+ "\t# to find the surface-temperature ratio,we enter figure (4-11),using \n",
+ "R = r/r_o \n",
+ "u = 0.97 \n",
+ "# thus \n",
+ "w = y \t\t\t# at r = 0\n",
+ "v = y*u \t\t# at r = r_o\n",
+ "C_of_O_axis = w \t# at r = 0\n",
+ "C_of_O_r_o = v \t\t# at r = r_o\n",
+ "\t# combining the solutions for the semi-infinite slab and infinite cylinder, we \thave \n",
+ "t = S_of_X*C_of_O_axis \n",
+ "s = S_of_X*C_of_O_r_o \n",
+ "\t# the corresponding temperatures are \n",
+ "T_axis = Te+t*(Ti-Te) \n",
+ "T_r_o = Te+s*(Ti-Te) \n",
+ "\n",
+ "\n",
+ "#RESULTS\n",
+ "\n",
+ "print\"The temperature at the axis is:\",round(T_axis,1),\" degree celsius\"\n",
+ "print\"The temperature at the surface is\",round(T_r_o,1),\" degree celsius\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.9"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 13,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Temperature at a radial position of 0.0125 m and a distance of 0.00625m from one end of cylinder 60 second after exposure to environment is 104.5 degree celsius\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.9\n",
+ "# finite length cylinder suddenly exposed to convection \n",
+ "\n",
+ "#Variable declaration\n",
+ "\n",
+ "d = 0.05 \t\t\t# [m] diameter of aluminium cylinder \n",
+ "Ti = 200 \t\t\t# [degree celsius] initial temperature of of cylinder\n",
+ "Te = 70\t\t\t # [degree celsius] environment temperature\n",
+ "k = 215 \t\t\t# [W/m deg celsius] heat transfer coefficient of plate\n",
+ "h = 525 \t\t\t# [W/sq m deg C] convection heat transfer coefficient \n",
+ "alpha = 8.4*10**(-5) \t\t#[square meter/s] constant\n",
+ "x1 = 0.00625 \t\t\t#[m]dist at which temperature is calculated from end\n",
+ "t = 60 \t\t\t\t# [s] time after which temperature is measured\n",
+ "r = 0.0125 \t\t\t# [m] radius at which temperature is calculated\n",
+ "\t# to solve this problem we combine the solutions from heisler charts for an \t\tinfinite cylinder and an infinite plate in accordance with the combination \t\tshown in fig (4-18f)\n",
+ "\t# for the infinite plate problem \n",
+ "L = 0.05\t\t\t # [m]\n",
+ "\n",
+ "#CALCULATION\n",
+ "\n",
+ "\t# the x position is measured fromthe center of the plate so that\n",
+ "x = L-x1 \t\t\t# [m]\n",
+ "A = k/(h*L) \n",
+ "B = (alpha*t/L**(2)) \n",
+ "\t# from figures (4-17) and (4-10) respectively\n",
+ "thetha_o_by_i = 0.75 \n",
+ "thetha_by_i = 0.95 \n",
+ "\t# so that\n",
+ "thetha_by_i_plate = thetha_o_by_i*thetha_by_i \n",
+ "\t# for the cylinder \n",
+ "r_o = d/2 \t\t\t# [m] radius of the cylinder\n",
+ "R = r/r_o \n",
+ "C = k/(h*r_o) \n",
+ "D = (alpha*t/r_o**(2)) \n",
+ "\t# and from figures (4-8) and (4-11), respectively\n",
+ "thetha_o_by_i_cyl = 0.38 \n",
+ "thetha_by_o = 0.98 \n",
+ "\t# so that\n",
+ "thetha_by_i_cyl = thetha_o_by_i_cyl*thetha_by_o \n",
+ "\t# combining the solutions for the plate and cylinder gives\n",
+ "thetha_by_i_short_cyl = thetha_by_i_plate*thetha_by_i_cyl \n",
+ "\t#thus\n",
+ "T = Te+thetha_by_i_short_cyl*(Ti-Te) \n",
+ "\n",
+ "#RESULTS\n",
+ "print\"Temperature at a radial position of 0.0125 m and a distance of 0.00625m from one end of cylinder 60 second after exposure to environment is\",round(T,1),\"degree celsius\" "
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Exa 4.10"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 14,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "The actual heat loss in the 1-minute: 40.2 kJ\n"
+ ]
+ }
+ ],
+ "source": [
+ "#Example 4.10\n",
+ "# heat loss for finite-length cylinder \n",
+ "\n",
+ "#Variable declaration\n",
+ "d = 0.05 \t\t# [m] diameter of aluminium cylinder\n",
+ "l = 0.1 \t\t# [m] length of aluminium cylinder \n",
+ "Ti = 200\t\t# [degree celsius] initial temperature of of cylinder\n",
+ "Te = 70 \t\t# [degree celsius] environment temperature\n",
+ "k = 215 \t\t# [W/m degree celsius] heat transfer coefficient of plate\n",
+ "h = 525 \t\t# [W/sq m deg celsius] convection heat transfer coefficient \n",
+ "alpha = 8.4*10**(-5) \t#[square meter/s] constant\n",
+ "x1 = 0.00625 \t\t#[m] distance at which temperature is calculated from end\n",
+ "t = 60 \t\t\t#[s]time after which temperature is measured\n",
+ "r = 0.0125 #[m] radius at which temperature is calculated\n",
+ "\n",
+ "\n",
+ "#CALCULATION\n",
+ "\t\n",
+ "\t# calculate the dimensionless heat-loss ratio for the infinite plate and \tinfinite cylinder which make up the multidimensional body\n",
+ "\t# for the plate we have \n",
+ "L = 0.05 \t\t# [m]\n",
+ "A = h*L/k \n",
+ "B = h**(2)*alpha*t/k**(2) \n",
+ "\t# from figure (4-14), for the plate, we read \n",
+ "Q_by_Q_o_plate = 0.22 \n",
+ "\n",
+ "\t# for the cylinder \n",
+ "r_o = 0.025 \t\t# [m]\n",
+ "\t# so we calculate \n",
+ "C = h*r_o/k \n",
+ "\t# and from figure(4-15) we have \n",
+ "Q_by_Q_o_cyl = 0.55 \n",
+ "\n",
+ "\t# the two heat ratios may be inserted in equation(4-22) to give \n",
+ "Q_by_Q_o_tot = Q_by_Q_o_plate+Q_by_Q_o_cyl*(1-Q_by_Q_o_plate) \n",
+ "c = 896 \t\t# [J/kg degree celsius] specific heat of aluminium\n",
+ "rho = 2707 \t\t# [kg/cubic meter] density of aluminium\n",
+ "\n",
+ "import math\n",
+ "\n",
+ "V = math.pi*r_o**(2)*l \t# [cubic meter]\n",
+ "Qo = rho*c*V*(Ti-Te) \t# [J]\n",
+ "Q = Qo*Q_by_Q_o_tot \t# [J] the actual heat loss in the 1-minute \n",
+ "\n",
+ "#RESULTS\n",
+ "\n",
+ "print \"The actual heat loss in the 1-minute:\",round((Q/1000),1),\" kJ\" "
+ ]
+ }
+ ],
+ "metadata": {
+ "kernelspec": {
+ "display_name": "Python 2",
+ "language": "python",
+ "name": "python2"
+ },
+ "language_info": {
+ "codemirror_mode": {
+ "name": "ipython",
+ "version": 2
+ },
+ "file_extension": ".py",
+ "mimetype": "text/x-python",
+ "name": "python",
+ "nbconvert_exporter": "python",
+ "pygments_lexer": "ipython2",
+ "version": "2.7.6"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}