{ "metadata": { "name": "" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Chapter 5:Gases" ] }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.1,Page no:177" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "Pbaro=688 #pressure in mm Hg\n", "\n", "#Calculation\n", "Patm=Pbaro/760.0 #pressure in atm\n", "\n", "#Result\n", "print\"The presuure in atmospheres is :\",round(Patm,3),\"atm\\n\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The presuure in atmospheres is : 0.905 atm\n", "\n" ] } ], "prompt_number": 40 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.2,Page no:178" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "Pbaro=732 #pressure in mm Hg\n", "\n", "#Calculation\n", "Patm=Pbaro/760.0 #pressure in atm\n", "P=Patm*1.01325*10**2 #pressure in kilo Pascal\n", "\n", "#Result\n", "print\"The presuure in kilo pascals is :\",round(P,1),\"kPa\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The presuure in kilo pascals is : 97.6 kPa\n", "\n" ] } ], "prompt_number": 41 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.3,Page no:186" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "V=5.43 #volume, L\n", "t=69.5 #temperature, C\n", "\n", "#Calculation\n", "T=t+273 #temperature, K\n", "n=1.82 #moles\n", "R=0.0821 #universal gas constant, L.atm/(K.mol)\n", "P=n*R*T/V #pressure, atm\n", "\n", "#Result\n", "print\"The presuure in atmospheres is :\",round(P,2),\"atm\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The presuure in atmospheres is : 9.42 atm\n", "\n" ] } ], "prompt_number": 42 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.4,Page no:187" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "m=7.4 #mass of NH3, g\n", "#at STP for NH3 for 1mole of NH3\n", "V1=22.41 # volume, L\n", "NH3=17.03 #molar mass of NH3, g\n", "\n", "#Calculation\n", "n=m/NH3 #moles of NH3\n", "V=n*V1 #volume, L\n", "\n", "#Result\n", "print\"The volume of NH3 under given conditions is :\",round(V,2),\"L\\n\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The volume of NH3 under given conditions is : 9.74 L\n", "\n" ] } ], "prompt_number": 43 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.5,Page no:188" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "V1=0.55 #volume, L\n", "P1=1 #pressure at sea level, atm\n", "P2=0.4 #pressurea at 6.5km height, atm\n", "\n", "#n1=n2 and T1=T2 given hence P1V1=P2V2\n", "#Calculation\n", "V2=P1*V1/P2 \n", "\n", "#Result\n", "print\"The volume of He balloon at height 6.5km above sea level is :\",round(V2,1),\"L\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The volume of He balloon at height 6.5km above sea level is : 1.4 L\n", "\n" ] } ], "prompt_number": 44 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.6,Page no:189" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "P1=1.2 # pressure initial, atm\n", "T1=18+273 #temperature initial, K\n", "T2=85+273 #temperature final, K\n", "#volume is constant\n", "\n", "#Calculation\n", "P2=P1*T2/T1 # pressure final,atm\n", "\n", "#Result\n", "print\"The final pressure is :\",round(P2,2),\"atm\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The final pressure is : 1.48 atm\n", "\n" ] } ], "prompt_number": 45 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.7,Page no:189" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "P1=6.4 # pressure initial, atm\n", "P2=1.0 # pressure final, atm\n", "T1=8+273 #temperature initial, K\n", "T2=25+273 #temperature final, K\n", "V1=2.1 #volume initial, mL\n", "\n", "#Calculation\n", "V2=P1*V1*T2/(T1*P2) # volume final, mL\n", "\n", "#Result\n", "print\"The final volume is :\",round(V2),\"mL\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The final volume is : 14.0 mL\n", "\n" ] } ], "prompt_number": 46 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.8,Page no:191" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "\n", "#taking 1 mole of CO2\n", "n=1 \n", "R=0.0821 #universal gas constant, L. atm/K.mol\n", "t=55 #temperature, C\n", "T=t+273 #temperature, K\n", "P=0.99 #.pressure, atm\n", "M=44.01 #molar mass of CO2, g\n", "\n", "#Calculation\n", "d1=P*M/(R*T) #density of CO2, g/L\n", "#altenate method\n", "#taking 1 mole of CO2\n", "mass=M #mass of CO2 in g =mol mass since we are considering 1 mole of CO2\n", "V=n*R*T/P #volume, L\n", "d2=mass/V #density=mass/volume, g/L\n", "\n", "#Result\n", "print\"The density of CO2 is :\",round(d1,2),\"g/L\\n\"\n", "print\"(Alternate Method)the density of CO2 is :\",round(d2,2),\"g/L\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The density of CO2 is : 1.62 g/L\n", "\n", "(Alternate Method)the density of CO2 is : 1.62 g/L\n", "\n" ] } ], "prompt_number": 47 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.9,Page no:192" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "d=7.71 # density, g/mL(given)\n", "R=0.0821 #universal gas constant, L. atm/K.mol\n", "T=36+273 # temp, K\n", "P=2.88 #pressure, atm\n", "\n", "#Calculation\n", "M1=d*R*T/P # mol. mass, g/mol\n", "#alternate method\n", "#considering 1 L of compound\n", "V=1 #volume, L\n", "n=P*V/(R*T) #no of moles\n", "m=7.71 #mass per 1 L, g\n", "M2=m/n # mol. mass, g/mol\n", "\n", "#Result\n", "print\"The molecular mass of given compound is :\",round(M1,1),\"g/mol\\n\"\n", "print\"{alternate method} the molecular mass of given compound is :\",round(M2,1),\" g/mol\\n\" \n", "print\"The molecular formula can be only found by trial and error method as given in the book \\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The molecular mass of given compound is : 67.9 g/mol\n", "\n", "{alternate method} the molecular mass of given compound is : 67.9 g/mol\n", "\n", "The molecular formula can be only found by trial and error method as given in the book \n", "\n" ] } ], "prompt_number": 49 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.10,Page no:193" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "percentSi=33 #percent of Si in compound\n", "percentF=67 #percent of F in compound\n", "P=1.7 #pressure, atm\n", "T=35+273 #temp. in K\n", "m=2.38 #mass, g\n", "V=0.21 #volume, L\n", "R=0.0821 #universal Gas constant, L.atm/K.mol\n", "m_sif3=85.09\n", "\n", "#Calculation\n", "nSi=percentSi/28.01 #moles of Si in 100g compound\n", "nF=percentF/19 #moles of F in 100g compound\n", "n=P*V/(R*T) #moles\n", "M=m/n #mol. mass=mass/moles, g/mol\n", "e=M/m_sif3\n", "\n", "#Result\n", "print\"The molecular mass of given compound is :\",round(M),\"g/mol\\n\"\n", "print\"Therefore,molecular formula is (SiF3)%.f\"%round(e),\"OR Si2F6\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The molecular mass of given compound is : 169.0 g/mol\n", "\n", "Therefore,molecular formula is (SiF3)2 OR Si2F6\n" ] } ], "prompt_number": 57 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.11,Page no:194" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "VC2H2=7.64 #volume of acetylene, L\n", "\n", "#Calculation\n", "VO2=VC2H2*5/2.0 #volume of O2 required for complete combustion as 5mol O2 react with 2mol acetylene for complete combustion\n", "\n", "#Result\n", "print\"The volume of O2 required for complete combustion of acetylene is :\",VO2,\"L\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The volume of O2 required for complete combustion of acetylene is : 19.1 L\n", "\n" ] } ], "prompt_number": 35 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.12,Page no:195" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "R=0.0821 #universal Gas constant, L.atm/K.mol\n", "T=80+273 #temp in K\n", "P=823/760.0 #pressure in atm\n", "m=60.0 #mass of NaN3, g\n", "NaN3=65.02 #mol. mass of NaN3, g\n", "\n", "#Calculation\n", "nN2=m*3.0/(2.0*NaN3) #moles of N2\n", "nN2=round(nN2,2)\n", "VN2=nN2*R*T/P #from ideal gas law\n", "#Result\n", "print\"\\t the volume of N2 generated is :\",round(VN2,1),\"L\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "\t the volume of N2 generated is : 36.9 L\n", "\n" ] } ], "prompt_number": 61 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.13,Page no:196" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "R=0.0821 #universal Gas constant, L.atm/K.mol\n", "T=312 #temp in K\n", "V=2.4*10**5 #volume, L\n", "P1=7.9*10**-3 #pressure initial in atm\n", "P2=1.2*10**-4 #pressure final in atm\n", "\n", "#Calculation\n", "Pdrop=P1-P2 #pressure drop, atm\n", "n=Pdrop*V/(R*T) #moles of Co2 reacted\n", "Li2CO3=73.89 #mol. mass of Li2CO3, g\n", "mLi2CO3=n*Li2CO3 #mass of Li2CO3, g\n", "\n", "\n", "#Result\n", "print\"The mass of Li2CO3 formed is :%.1e\"%mLi2CO3,\"g Li2CO3\\n\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The mass of Li2CO3 formed is :5.4e+03 g Li2CO3\n", "\n" ] } ], "prompt_number": 64 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.14,Page no:199" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "nNe=4.46 #moles of Ne\n", "nXe=2.15 #moles of Xe\n", "nAr=0.74 #moles of Ar\n", "PT=2 #total pressure in atm\n", "\n", "#Calculation\n", "XNe=nNe/(nNe+nAr+nXe) #mole fraction of Ne\n", "XAr=nAr/(nNe+nAr+nXe) #mole fraction of Ar\n", "XXe=nXe/(nNe+nAr+nXe) #mole fraction of Xe\n", "PNe=XNe*PT #partial pressure of Ne\n", "PAr=XAr*PT #partial pressure of Ar\n", "PXe=XXe*PT #partial pressure of Xe\n", "\n", "#Result\n", "print\"The partial pressures of Ne, Ar and Xe are:\"\n", "print\"PNe=\",round(PNe,2),\"atm\\n\",\"PAr=\",round(PAr,2),\"atm\\nPXe=\",round(PXe,3),\"atm \"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The partial pressures of Ne, Ar and Xe are:\n", "PNe= 1.21 atm\n", "PAr= 0.2 atm\n", "PXe= 0.585 atm \n" ] } ], "prompt_number": 70 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.15,Page no:200" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "PT=762 #pressure total, mmHg\n", "PH2O=22.4 #pressure of water vapor, mmHg\n", "PO2=PT-PH2O #pressure of O2, frm Dalton's law, mmHg\n", "M=32 #mol mass of O2, g\n", "R=0.0821 #universal Gas constant, L.atm/K.mol\n", "T=24+273 #temp in K\n", "V=0.128 #volume in L\n", "\n", "#Calculation\n", "m=(PO2/760)*V*M/(R*T) #mass of mass of O2 collected, g\n", "\n", "#Result\n", "print\"The mass of O2 collected is :\",round(m,3),\"g\\n\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The mass of O2 collected is : 0.163 g\n", "\n" ] } ], "prompt_number": 71 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.16,Page no:207" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "R=8.314 #universal Gas constant, J/K mol\n", "T=25+273 #temp in K\n", "import math\n", "#Calculation\n", "#for O2\n", "M=4.003*10**-3 #mol mass in kg\n", "Urms=math.sqrt(3*R*T/M) #rms velocity, m/s\n", "print\"\\t the rms velocity of O2 collected is :%.2e\"%Urms,\"m/s\\n\"\n", "#for N2\n", "M=28.02*10**-3 #mol mass in kg\n", "Urms=math.sqrt(3*R*T/M) #rms velocity, m/s\n", "\n", "#Result\n", "print\"\\t the rms velocity of N2 collected is :\",round(Urms),\" m/s\\n\"" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "\t the rms velocity of O2 collected is :1.36e+03 m/s\n", "\n", "\t the rms velocity of N2 collected is : 515.0 m/s\n", "\n" ] } ], "prompt_number": 1 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.17,Page no:209" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "t2=1.5 #diffusion time of compound, min\n", "t1=4.73 #diffusion time of Br, min\n", "M2=159.8 #mol mass of Br gas, g\n", "\n", "#Calculation\n", "M=(t2/t1)**2*M2 #molar gas of unknown gas, g(from Graham's Law of Diffusion)\n", "\n", "#Result\n", "print\"\\t the molar mass of unknown gas is :\",round(M,1),\"g/mol\\n\"\n" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "\t the molar mass of unknown gas is : 16.1 g/mol\n", "\n" ] } ], "prompt_number": 76 }, { "cell_type": "heading", "level": 2, "metadata": {}, "source": [ "Example no:5.18,Page no:213" ] }, { "cell_type": "code", "collapsed": false, "input": [ "#Variable declaration\n", "#(a)\n", "V=5.2 #volume, L\n", "T=47+273 \n", "n=3.5 \n", "R=0.0821 #universal Gas constant, L.atm/K.mol\n", "\n", "#Calculation\n", "P=n*R*T/V \n", "print\"The pressure of NH3 gas from ideal gas equation is :\",round(P,1),\"atm\\n\"\n", "#(b)\n", "a=4.17 #constant, atm.L2/mol2\n", "b=0.0371 #constant, L/mol\n", "Pc=a*n**2/V**2 #pressure correction term, atm\n", "Vc=n*b #volume correction term, L\n", "P=n*R*T/(V-Vc)-Pc #from van der waals equation, pressure, atm\n", "\n", "#Result\n", "print\"The pressure of NH3 gas from van der waals equation is :\",round(P,1),\"atm\\n\" " ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "The pressure of NH3 gas from ideal gas equation is : 17.7 atm\n", "\n", "The pressure of NH3 gas from van der waals equation is : 16.2 atm\n", "\n" ] } ], "prompt_number": 80 } ], "metadata": {} } ] }