{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Chapter 23:Air-Conditioning Load Estimation"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 23.1,PAGE NUMBER:275"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "U factor=0.45 W/(m**2 K)\n"
     ]
    }
   ],
   "source": [
    "#Variable declaration\n",
    "R_si=0.3;# The inside resistance in (m**2 K)/W\n",
    "R_1=0.040/0.09;# The thermal resistance of concrete panels in  (m**2 K)/W\n",
    "R_2=0.050/0.037;# The thermal resistance of insulation in  (m**2 K)/W\n",
    "R_3=0.012/0.16;# The thermal resistance of plaster board in  (m**2 K)/W\n",
    "R_so=0.07;# The outside resistance in (m**2 K)/W\n",
    "\n",
    "#Calculation\n",
    "U=1/(R_si+R_1+R_2+R_3+R_so);# U factor in W/(m**2 K)\n",
    "print\"U factor=%0.2f W/(m**2 K)\"%U"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 23.2,PAGE NUMBER:278"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Total heat,Q_t=24.2 kW\n",
      "Latent heat,Q_l=15.5 kW\n",
      "Sensible heat,Q_s=8.5 kW\n"
     ]
    }
   ],
   "source": [
    "#Variable declaration\n",
    "T_d1=21;# The dry bulb temperature of air in °C\n",
    "H=45;# % saturation\n",
    "T_d2=27;# The dry bulb temperature of air in °C\n",
    "T_wb1=20;# The wet bulb temperature of air in °C\n",
    "m=1.35;# The mass flow rate of air in kg/s\n",
    "C_pa=1.006;# The specific heat capacity of air in kJ/kg.K\n",
    "C_pw=4.187;# The specific heat capacity of water in kJ/kg.K\n",
    "\n",
    "#Calculation\n",
    " # 1.Total heat:\n",
    "h_2=57.00;# Enthalpy at 27°C DB, 20°C WB in kJ/kg\n",
    "h_1=39.08;# Enthalpy at 21°C DB, 45% sat in kJ/kg\n",
    "dh=17.92;# Heat to be removed in kJ/kg\n",
    "Q_t=dh*m;# Total heat in kW\n",
    "print\"Total heat,Q_t=%2.1f kW\"% Q_t\n",
    "\n",
    "# 2.Latent heat:\n",
    "x_2=0.0117;# Moisture at 27°C DB, 20°C WB in kg/kg\n",
    "x_1=0.0070;# Moisture at 21°C DB, 45% sat in kg/kg\n",
    "dx=x_2-x_1;# Moisture to be removed in kg/kg\n",
    "Q_l=dx*m*2440;# Latent heat in kW\n",
    "print\"Latent heat,Q_l=%2.1f kW\"% Q_l\n",
    "\n",
    "# 3.Sensible heat:\n",
    "Q_s=(C_pa+((C_pw*x_2)))*(T_d2-T_d1)*m;# Sensible heat in kW\n",
    "print\"Sensible heat,Q_s=%1.1f kW\"% Q_s"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example 23.3,PAGE NUMBER:280"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "\n",
      "Net room load=11.625 kW\n"
     ]
    }
   ],
   "source": [
    "#Variable declaration\n",
    "Q_tl=15;# Total lighting load\n",
    "P_ra=90;# % of load taken from return air\n",
    "P_a=25;# % of load rejected to ambient\n",
    "\n",
    "#Calculation\n",
    "Q_ra=Q_tl*(P_ra*10**-2);# Picked up by return air in kW\n",
    "Q_a=Q_ra*(P_a*10**-2);# Rejected to ambient in kW\n",
    "Q_net=Q_tl-Q_a;# Net room load in kW \n",
    "print\"\\nNet room load=%2.3f kW\"%Q_net"
   ]
  }
 ],
 "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.11"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 0
}
