diff options
66 files changed, 17801 insertions, 28 deletions
diff --git a/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter29.ipynb b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter29.ipynb index 6653720b..88597dbf 100644 --- a/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter29.ipynb +++ b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter29.ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:102ba4bcb83ebd9f77c7c3f970c6e3d48b2bd31161c690d1b5c67b800706b1d0" + "signature": "sha256:686f6e2ca60a2c3f2eb3a67890e53f7e99143217bf1631b22ff59d423f6ef608" }, "nbformat": 3, "nbformat_minor": 0, @@ -20,8 +20,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "%matplotlib inline\n", - "import matplotlib.pyplot as plt" + "%matplotlib inline" ], "language": "python", "metadata": {}, @@ -1638,6 +1637,7 @@ "cell_type": "code", "collapsed": false, "input": [ + "import matplotlib.pyplot as plt\n", "import math\n", "#variable declaration\n", "v=460.0#V\n", @@ -1668,11 +1668,11 @@ "output_type": "display_data", "png": "iVBORw0KGgoAAAANSUhEUgAAAYoAAAEPCAYAAABcA4N7AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAH0VJREFUeJzt3XucVXW9//HXWxDvCpQNihcgJUSj1CBv5aaMPP0K7VGh\nHutQ9Kh+VkdPnUrwVz/m13mcQrucfvV7lF3Ug50kKROxzEBjm56j4AWviMjBUVGYxFsqKiCf3x/r\nO8xmnFnMDHvN3jP7/Xw89oO1116X7/6W+z3f9f2u71JEYGZm1pVdal0AMzOrbw4KMzPL5aAwM7Nc\nDgozM8vloDAzs1wOCjMzy1VoUEj6kqT7Jd0n6QpJu0kaLmmxpFWSFkkaWrH9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t_number": 3 + "prompt_number": 2 }, { "cell_type": "heading", @@ -1686,6 +1686,7 @@ "cell_type": "code", "collapsed": false, "input": [ + "import matplotlib.pyplot as plt\n", "import math\n", "#variable declaration\n", "output=5.968#kW\n", @@ -1735,11 +1736,11 @@ "output_type": "display_data", "png": "iVBORw0KGgoAAAANSUhEUgAAAYAAAAEPCAYAAABLIROyAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XeYFFX69vHvQxQwsiiIICgqiAQJroogoxjANYBhDauw\nRkQy6k/FV8VdV13ELGZUwFUMiGsiCqMIKkgOg6hrRCUJkmGGed4/qkdHGJjYXd1d9+e65prumu6u\npyypu885VafM3RERkegpF3YBIiISDgWAiEhEKQBERCJKASAiElEKABGRiFIAiIhEVNwCwMyeM7Pl\nZrYg37L7zCzLzOaZ2Rtmtk+81i8iIrsXzxbA80DHHZZNAI5y9+bAUuCWOK5fRER2I24B4O5TgTU7\nLJvo7rmxp58CdeK1fhER2b0wxwCuAN4Lcf0iIpEWSgCY2a3ANnd/KYz1i4gIVEj0Cs3s78AZQIfd\nvEYTFImIlIC7W1Ffm9AWgJl1BG4EznH3Lbt7rbun7c8dd9wReg3aPm2bti/9foornqeBvgxMBxqa\n2fdmdgXwKLAnMNHM5pjZ4/Fav4iI7F7cuoDc/eICFj8Xr/WJiEjx6ErgEGRkZIRdQlyl8/al87aB\nti9qrCT9RvFmZp6MdYmIJDMzw5N1EFhERJKHAkBEJKIUACIiEaUAEBGJKAWAiEhEKQBERCJKASAi\nElEKABGRiFIAiIhElAJARCSiFAAiIhGlABARiSgFgIhIRCkAREQiSgEgIhJRCgARkYhSAIiIRJQC\nQEQkTpL9zoYKABGRMrZs3TIuGX0Jj854NOxSdksBICJSRrbmbOXej+6l+ZPNabBfA65scWXYJe1W\nhbALEBFJB2O/GEvfcX1pVKMRn171KQ2qNwi7pEIpAERESuGrX76i//j+LFm1hIc7PkynwzuFXVKR\nqQtIRKQEN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nr+zi+XFAY2B60LtEJWB6\nvte9Efs9Gzg33/KUvxGJpA8FgETFIuD8Apbn8MeWcJUd/r5xN88nuvslu1jf1tjv7ejfmSQpdQFJ\nJLj7ZKBy/ruwmVkzgm/kjc2sUmx63ZOL+JGfAieYWYPYZ1UrwhlF64G9il+9SHwoACRKugCnxE4D\nXQj8i+COUK8CCwm6d2bv5v2/dSPFbujzd+BlM5tH0P3TcBfvyXvf20CX2CDwCaXcFpFS03TQIiIR\npRaAiEhEKQBERCJKASAiElEKABGRiFIAiIhElAJARCSiFAAiIhGlABARiaj/D6p919PNp3KzAAAA\nAElFTkSuQmCC\n", "text": [ - "<matplotlib.figure.Figure at 0x7fb558dfd050>" + "<matplotlib.figure.Figure at 0x7fd158684490>" ] } ], - "prompt_number": 4 + "prompt_number": 3 }, { "cell_type": "heading", diff --git a/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter32.ipynb b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter32.ipynb index feb75575..db832632 100644 --- a/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter32.ipynb +++ b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/chapter32.ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:37afbdb95d83a409c42483f9400df0ec405aafcb3f017067345a44342a88aaf2" + "signature": "sha256:4e69a01a0a4781a2bfdf21e32afa6fa1938151a94e00c3f103afc92f44f60c96" }, "nbformat": 3, "nbformat_minor": 0, @@ -20,13 +20,12 @@ "cell_type": "code", "collapsed": false, "input": [ - "%matplotlib inline\n", - "import matplotlib.pyplot as plt" + "%matplotlib inline" ], "language": "python", "metadata": {}, "outputs": [], - "prompt_number": 2 + "prompt_number": 1 }, { "cell_type": "heading", @@ -1507,6 +1506,7 @@ "cell_type": "code", "collapsed": false, "input": [ + "import matplotlib.pyplot as plt\n", "import math\n", "from sympy.solvers import solve\n", "from sympy import Symbol\n", @@ -1557,11 +1557,11 @@ "output_type": "display_data", "png": "iVBORw0KGgoAAAANSUhEUgAAAYcAAAEPCAYAAACp/QjLAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAGNpJREFUeJzt3XmUXVWZ9/HvIwQUI4OCKIMrvhLmgIBDEJoUwsIAEscG\nQdoBlSwHyIuCTC0ppWlEYYmKAw4gL0q6XWILUURRrBZRQIRAIAOTGkI0ICAC3QFCnvePfUNCnVSl\nqqhT51bd72etWrnDrnufOqmqX+2zhxOZiSRJq3te0wVIktqP4SBJqjAcJEkVhoMkqcJwkCRVGA6S\npIrawiEito6IX0XE7RFxW0Qc20e7L0XEnRFxS0TsVlc9kqSBW7fG134KOC4z50TEeOAPEXFVZs5f\n2SAiDgK2ycyJEfF64GvA5BprkiQNQG09h8z8a2bOad1+DJgPbNGr2TTgolab64GNI2LzumqSJA3M\niIw5RMQEYDfg+l5PbQncu9r9xcBWI1GTJKlvtYdD65TSD4AZrR5EpUmv++7nIUkNq3PMgYgYB1wK\nfDczf7SGJvcBW692f6vWY71fx8CQpCHIzN5/gA9InbOVAvg2MC8zz+2j2eXAe1rtJwN/z8yla2qY\nmX5kMnPmzMZraJcPj4XHwmPR/8dzUWfPYS/gSODWiLi59dgpwCsAMvP8zLwiIg6KiLuAx4H311iP\nJGmAaguHzPwNA+iZZObH6qpBkjQ0rpAeZbq6upouoW14LFbxWKzisRge8VzPS42EiMjRUKcktZOI\nINttQFqSNHoZDpKkCsNBklRhOEiSKgwHSVKF4SBJqjAcJEkVhoMkqcJwkCRVGA6SpArDQZJUYThI\nkioMB0lSheEgSaowHCRJFYaDJKnCcJAkVRgOkqQKw0GSVGE4SJIqDAdJUoXhIEmqMBwkSRWGgySp\nwnCQJFXUGg4RcUFELI2IuX08v1FEzI6IORFxW0S8r856JEkDU3fP4UJgaj/PfxS4LTNfD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cCiiHhNw6VJA2Y4SIPUunbvzRHx44jYKiLmtO4f\nvVqbjSJiOmU3zFdRNseb29drSu3G00pSH57DaaXvUq77/X3KbsJ311GfVKd1my5AamND/cvpP4H3\nZOaKtbaU2pQ9B0lShWMOkqQKw0GSVGE4SJIqDAdJUoXhIEmqMBwkSRWGgySpwnCQJFX8fyk/juvE\nTvrvAAAAAElFTkSuQmCC\n", "text": [ - "<matplotlib.figure.Figure at 0x7fb9d458da10>" + "<matplotlib.figure.Figure at 0x7f269e709e90>" ] } ], - "prompt_number": 5 + "prompt_number": 2 }, { "cell_type": "heading", @@ -3044,7 +3044,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", + "import matplotlib.pyplot as plt\n", "#variable declaration\n", "load=5#kVA\n", "v1=2300#V\n", @@ -3083,11 +3083,11 @@ "output_type": "display_data", "png": "iVBORw0KGgoAAAANSUhEUgAAAX4AAAEPCAYAAABFpK+YAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAG69JREFUeJzt3XuUXFWd9vHvQxoIIQgGuQoRRCUy3CEEMyQ0vKAYIzcD\nyAveGODFMJiFLG/ga9phgQO+6oy4RlEECQKDtFyEKAGUDkHkTggBuS4Qwi0wIQmEBDrJ7/1jn6Y7\nTXV3dbpOn+o6z2etXl116pyq3wr0s0/ts8/eigjMzKw81im6ADMzG1wOfjOzknHwm5mVjIPfzKxk\nHPxmZiXj4DczK5lcg1/SNEkPS5ovaVq2bXdJd0l6UNK9ksbmWYOZma0pt+CXtDNwIjAW2A2YLGkH\n4HxgekTsAXwve25mZoOkKcf3HgPcHRErACTNBo4EVgEbZ/tsAryQYw1mZtaN8rpzV9IY4HrgE8AK\n4M/APcDPgVmASN84PhERz+dShJmZvUduwQ8g6QRgKrAMeAR4mxT2bRFxraSjgJMj4uDcijAzszXk\nGvxrfJB0DrAA+EFEbJJtE7A4IjausL8nETIzWwsRod5ez3tUz+bZ79Gk/v0rgBcl7Z/tciDwRE/H\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492cpSiyLi6Wz/\no0lTAHycNG2Bu3xsUPmM38piP+CKSBYCs4GxpCmWfyDpIdIZ+NaStgAmANdExIqIeIM0WWCl6ZgF\n/F/gfRExtcv2q4Ap2YRZXbt59gZei4gFwF+APbIpdc0GjYPfyiKoHNzHAx8A9szmr18IDK+wf09z\n8AdpidC9ugZ4FuzPAM2kbxtXZS8dC4zJpnd+CtgIWOPisFneHPxWFnOAY7KVvjYDJpJWI3sfaYGV\nVZIOAD5ECvPbgcOVFoLfCJhMZ1/+v0o6tct73wT8OzAzW/Smw5WkVbuejogXszVbjwJ2jojtsyme\nDyc1BmaDxsFvjS4AIuJaYB7wEPBn4BtZl8/lwN6S5gFfIFsHIFtp66ps/z8C93R5zzHAa10/IyJa\ngV+Rrg8Mz7a3AjvR2Yc/gbT4yMtdjp0D7JR1L5kNCk/LbNZPkm4gXRBeWXQtZmvDwW9mVjLu6jEz\nKxkHv5lZyTj4zcxKxsFvZlYyDn4zs5Jx8JuZlYyD38ysZP4/yRihRWdm7REAAAAASUVORK5CYII=\n", "text": [ - "<matplotlib.figure.Figure at 0x7fb9d458d610>" + "<matplotlib.figure.Figure at 0x7f269c5f7f90>" ] } ], - "prompt_number": 6 + "prompt_number": 3 }, { "cell_type": "heading", diff --git a/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter29example32.png b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter29example32.png Binary files differnew file mode 100644 index 00000000..0c99fa16 --- /dev/null +++ b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter29example32.png diff --git a/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter29example33.png b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter29example33.png Binary files differnew file mode 100644 index 00000000..3db6b46d --- /dev/null +++ b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter29example33.png diff --git a/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter32example30.png b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter32example30.png Binary files differnew file mode 100644 index 00000000..1e7a1724 --- /dev/null +++ b/A_Textbook_of_Electrical_Technology_AC_and_DC_Machines_by_A_K_Theraja_B_L_Thereja/screenshots/chapter32example30.png diff --git a/Antenna_and_Wave_Propogation_by_U._A._Bakshi_and_A._V._Bakshi/Chapter6Aperture_and_Lens_Antenna.ipynb b/Antenna_and_Wave_Propogation_by_U._A._Bakshi_and_A._V._Bakshi/Chapter6Aperture_and_Lens_Antenna.ipynb new file mode 100644 index 00000000..85cca3f8 --- /dev/null +++ b/Antenna_and_Wave_Propogation_by_U._A._Bakshi_and_A._V._Bakshi/Chapter6Aperture_and_Lens_Antenna.ipynb @@ -0,0 +1,126 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 6 Aperture and Lens Antenna" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 6.1 Directive gain calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The length is 62.5 m\n", + "The angle ThetaE is 9.14784 degree\n", + "The angle ThetaH is 12.5216 degree\n", + "The H plane aperture is 13.7136\n", + "\n", + "\n", + "The HPBWE is 5.6 degree\n", + "The HPBWH is 4.88567 degree\n", + "The Directive gain in db is 30.1221 db\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "#horn antenna\n", + "Ae=10;\n", + "del_a=0.2;\n", + "p=Ae**2/(8*del_a);\n", + "del1=0.375;\n", + "Thetae=2*math.atan((Ae/(2*p)))*180/(math.pi); #flare angle\n", + "Thetah=2*math.acos(p/(p+del1))*180/(math.pi);\n", + "Ah=2*p*math.tan(((Thetah*(math.pi)/180)/2));\n", + "print(\"The length is %g m\"%p);\n", + "print(\"The angle ThetaE is %g degree\"%Thetae);\n", + "print(\"The angle ThetaH is %g degree\"%Thetah);\n", + "print(\"The H plane aperture is %g\"%Ah);\n", + "HPBWH=67/Ah;\n", + "HPBWE=56/Ae;\n", + "Ddb=10*math.log10((7.5*Ae*Ah));\n", + "print('\\n')\n", + "print(\"The HPBWE is %g degree\"%HPBWE);\n", + "print(\"The HPBWH is %g degree\"%HPBWH);\n", + "print(\"The Directive gain in db is %g db\"%Ddb); " + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 6.2 Effective aperture calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The diameter d is 1.4 m\n", + "The effective aperture is 1.53938 m^2\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "#parabolic reflector antenna\n", + "BWFN=10;\n", + "f=3*10**9;\n", + "c=3*10**8;\n", + "lamda=c/f;\n", + "d=140*lamda/(BWFN);\n", + "print(\"The diameter d is %g m\"%d);\n", + "#For circular parabolidal antenna\n", + "Ae=((math.pi)*(d**2))/4;\n", + "print(\"The effective aperture is %g m^2\"%Ae);" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.5.2" + } + }, + "nbformat": 4, + "nbformat_minor": 1 +} diff --git a/Antenna_and_Wave_Propogation_by_U._A._Bakshi_and_A._V._Bakshi/Chapter7Propagation_of_Radio_Waves.ipynb b/Antenna_and_Wave_Propogation_by_U._A._Bakshi_and_A._V._Bakshi/Chapter7Propagation_of_Radio_Waves.ipynb new file mode 100644 index 00000000..1b7b1b68 --- /dev/null +++ b/Antenna_and_Wave_Propogation_by_U._A._Bakshi_and_A._V._Bakshi/Chapter7Propagation_of_Radio_Waves.ipynb @@ -0,0 +1,632 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 7 Propagation of Radio Waves" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.1 Frequency calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The maximum stable frequency is 1.76086e+07 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "fcr=11*10**6;\n", + "D=1000;\n", + "h=400;\n", + "fmuf=fcr*math.sqrt(1+(D/(2*h))**2);\n", + "print(\"The maximum stable frequency is %g Hz\"%fmuf);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.2 Usable frequency calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The critical frequency is 2.84605e+06 Hz\n", + "The maximum usable frequency is 3.0287e+06 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "Nmax=10**11;\n", + "phi=(math.pi)/9;\n", + "fcr=math.sqrt(81*Nmax);\n", + "print(\"The critical frequency is %g Hz\"%fcr);\n", + "fmuf=fcr*(1/math.cos(phi));\n", + "print(\"The maximum usable frequency is %g Hz\"%fmuf);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.3 Critical frequency calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The critical frequency is 6.00115e+06 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "D=2000;\n", + "h=200;\n", + "fmuf=30.6*10**6;\n", + "fcr=fmuf/math.sqrt(1+(D/(2*h))**2);\n", + "print(\"The critical frequency is %g Hz\"%fcr);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.4 Skip distance calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The Nmax value is 2.34568e+11 /m^3\n", + "The critical frequency is 4.3589e+06 Hz\n", + "The skip distance is 1.65179e+06 m\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "n=0.9;\n", + "fmuf=10*10**6;\n", + "f=10*10**6;\n", + "h=400*10**3;\n", + "Nmax=(1-n**2)*f**2/81;\n", + "print(\"The Nmax value is %g /m^3\"%Nmax);\n", + "fcr=math.sqrt(81*Nmax);\n", + "print(\"The critical frequency is %g Hz\"%fcr);\n", + "Dskip=2*h*math.sqrt((fmuf/fcr)**2-1);\n", + "print(\"The skip distance is %g m\"%Dskip);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.5 Efield calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The wavelength is 250 m\n", + "The electric field is 0.101788 V/m\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "ht=150;\n", + "hr=2;\n", + "Is=9;\n", + "d=40*10**3;\n", + "f=1.2*10**6;\n", + "c=3*10**8;\n", + "lamda=c/f;\n", + "print(\"The wavelength is %d m\"%lamda);\n", + "E=120*(math.pi)*ht*hr*Is/(lamda*d);\n", + "print(\"The electric field is %g V/m\"%E);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.6 Transmission height calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The height of transmission is 2.98243e+07 m\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "dmax=45*10**3;\n", + "ht=(dmax/8.24)**2; #dmax=4.12[sqrt(ht)+sqrt(hr)];ht=hr;\n", + "print(\"The height of transmission is %g m\"%ht);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.7 Nmax calculation" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "fcre=2.5*10**6;\n", + "fcrf=8.5*10**6;\n", + "Nmaxe=(fcre)**2/81;\n", + "Nmaxf=(fcrf)**2/81;\n", + "print(\"The Nmax for e layer is %g /m^3\"%Nmaxe);\n", + "print(\"The Nmax for f layer is %g /m^3\"%Nmaxf);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.8 Critical freq calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The critical frequencies are 14.2302Hz 16.8375Hz 11.0227Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "Nmaxf1=2.5;\n", + "Nmaxf2=3.5;\n", + "Nmaxf3=1.5;#10^6*10^-6=1;\n", + "fcr1=math.sqrt(81*Nmaxf1);\n", + "fcr2=math.sqrt(81*Nmaxf2);\n", + "fcr3=math.sqrt(81*Nmaxf3);\n", + "print(\"The critical frequencies are %gHz %gHz %gHz\"%(fcr1,fcr2,fcr3));" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.9 Electron Density calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The Nmax values are 2.5e+11 m^3 2.77778e+10 m^3\n", + "The change in electron density is 2.22222e+11 m^3\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "fcr1=4.5*10**6;\n", + "fcr2=1.5*10**6;\n", + "Nmax1=(fcr1/9)**2;\n", + "Nmax2=(fcr2/9)**2;\n", + "print(\"The Nmax values are %g m^3 %g m^3\"%(Nmax1,Nmax2));\n", + "Nmax=Nmax1-Nmax2;\n", + "print(\"The change in electron density is %g m^3\"%Nmax);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.10 Frequency calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The frequency is 2.078461e+05 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "#Note:10^6 is the power and not 10^-6 as mentioned in book\n", + "n=0.5;\n", + "N=400*10**6;\n", + "f=math.sqrt((81*N)/(1-n**2));\n", + "print(\"The frequency is %e Hz\"%f);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.11 Critical freq calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The critical frequency is 1.200084e+07 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "D=1500;\n", + "h=250;\n", + "fmuf=37.95*10**6;\n", + "fcr=fmuf/math.sqrt(1+(D/(2*h))**2);\n", + "print(\"The critical frequency is %e Hz\"%fcr);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.12 Usable freq calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The maximum usable frequency is 3.16475e+07 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "D=2500;\n", + "h=200;\n", + "fcr=5*10**6;\n", + "fmuf=fcr*math.sqrt(1+(D/(2*h))**2);\n", + "print(\"The maximum usable frequency is %g Hz\"%fmuf);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.13 virtual height calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The virtual height is given by 750000 m\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "T=5*10**-3;\n", + "c=3*10**8;\n", + "h=c*(T/2);\n", + "print(\"The virtual height is given by %g m\"%h);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.14 LOS calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The line of sight distance is 46.6572 m\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "ht=40;\n", + "hr=25;\n", + "f=90*10**6;\n", + "p=35;\n", + "LOS=4.12*(math.sqrt(ht)+math.sqrt(hr));\n", + "print(\"The line of sight distance is %g m\"%LOS);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.15 critical freq calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The critical frequency is 1.01025e+07 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "Nmax=1.26*10**12;\n", + "fcr=math.sqrt(81*Nmax);\n", + "print(\"The critical frequency is %g Hz\"%fcr)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.16 critical freq calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The critical frequency is 1.0022e+07 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "Nmax=1.24*10**12;\n", + "fcr=math.sqrt(81*Nmax);\n", + "print(\"The critical frequency is %g Hz\"%fcr);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.17 usable freq calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The maximum usable frequency is 6.7082e+06 Hz\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "fcr=6*10**6;\n", + "D=200*10**3;\n", + "h=200*10**3;\n", + "fmuf=fcr*math.sqrt(1+(D/(2*h))**2);\n", + "print(\"The maximum usable frequency is %g Hz\"%fmuf);" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## 7.18 Range calculation" + ] + }, + { + "cell_type": "code", + "execution_count": 15, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "The maximum range is 24.1419 miles\n" + ] + } + ], + "source": [ + "from __future__ import division\n", + "import math\n", + "\n", + "ht=100;\n", + "hr=50;\n", + "d=1.4142*(math.sqrt(ht)+math.sqrt(hr));\n", + "print(\"The maximum range is %g miles\"%d);" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.5.2" + } + }, + "nbformat": 4, + "nbformat_minor": 1 +} diff --git a/Electronic_Devices_and_Circuit_Theory_by_R_L_Boylestad_and_Louis_Nashlesky/README.txt b/Electronic_Devices_and_Circuit_Theory_by_R_L_Boylestad_and_Louis_Nashlesky/README.txt new file mode 100644 index 00000000..4c07cf09 --- /dev/null +++ b/Electronic_Devices_and_Circuit_Theory_by_R_L_Boylestad_and_Louis_Nashlesky/README.txt @@ -0,0 +1,10 @@ +Contributed By: RONAK BANSAL +Course: btech +College/Institute/Organization: VEER SURENDRA SAI UNIVERSITY OF TECHNOLOGY,BURLA +Department/Designation: COMPUTER SCIENCE AND ENGINEERING +Book Title: Electronic Devices and Circuit Theory +Author: R L Boylestad and Louis Nashlesky +Publisher: Pearson Education(2007), +Year of publication: 2009 +Isbn: 978-81-317-2700-3 +Edition: tenth(10th)
\ No newline at end of file diff --git a/Fluid_mechanicsxyz/Untitled.ipynb b/Fluid_mechanicsxyz/Untitled.ipynb new file mode 100644 index 00000000..286dcb3d --- /dev/null +++ b/Fluid_mechanicsxyz/Untitled.ipynb @@ -0,0 +1,6 @@ +{ + "cells": [], + "metadata": {}, + "nbformat": 4, + "nbformat_minor": 0 +} diff --git a/Fluid_mechanicsxyz/screenshots/Selection_001.png b/Fluid_mechanicsxyz/screenshots/Selection_001.png Binary files differnew file mode 100644 index 00000000..bcb03f13 --- /dev/null +++ b/Fluid_mechanicsxyz/screenshots/Selection_001.png diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter1.ipynb b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter1.ipynb new file mode 100644 index 00000000..ca3883fc --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter1.ipynb @@ -0,0 +1,2215 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# 1: Interference" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 1, Page number 30" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "distance of screen from slits is 1.28 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=0.08*10**-2; #distance between slits(m)\n", + "beta=6*10**-4; #fringe width(m)\n", + "c=3*10**8; #velocity of light(m/sec)\n", + "new=8*10**11*10**3; #frequency(Hz)\n", + "\n", + "#Calculation\n", + "lamda=c/new; #wavelength(m)\n", + "D=beta*d/lamda; #distance of screen from slits(m)\n", + "\n", + "#Result\n", + "print \"distance of screen from slits is\",D,\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 2, Page number 30" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of light source is 6037.5 angstron\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda1=4200*10**-10; #wavelength(m)\n", + "beta1=0.64*10**-2; #first fringe width(m)\n", + "beta2=0.46*10**-2; #second fringe width(m)\n", + "\n", + "#Calculation\n", + "lamda2=lamda1*2*beta2/beta1; #wavelength of light source(m)\n", + "\n", + "#Result\n", + "print \"wavelength of light source is\",lamda2*10**10,\"angstron\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 3, Page number 31" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ratio of intensity is 0.3363\n", + "distance of point on screen from centre is 1.473 *10**-4 m\n", + "answers in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "Y=1*10**-3; #distance between slits(m)\n", + "D=1; #distance between slit and screen(m)\n", + "d=1*10**-3; #point distance(m)\n", + "lamda=5893*10**-10; #wavelength(angston)\n", + "\n", + "#Calculation\n", + "delta1=Y*d/D; #path difference(m)\n", + "Pd=2*math.pi*delta1/lamda; #phase difference(radian)\n", + "r=(math.cos(Pd/2))**2; #ratio of intensity\n", + "delta2=lamda/4; #path difference(m)\n", + "W=delta2*D/d; #distance of point on screen from centre(m)\n", + "\n", + "#Result\n", + "print \"ratio of intensity is\",round(r,4)\n", + "print \"distance of point on screen from centre is\",round(W*10**4,3),\"*10**-4 m\"\n", + "print \"answers in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 4, Page number 32" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ratio of maximum intensity to minimum intensity is 19.727\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "I1=10; #intensity(Wm**-2)\n", + "I2=25; #intensity(Wm**-2)\n", + "\n", + "#Calculation\n", + "a1bya2=math.sqrt(I1/I2); \n", + "ImaxbyImin=(a1bya2+1)**2/(a1bya2-1)**2; #ratio of maximum intensity to minimum intensity\n", + "\n", + "#Result\n", + "print \"ratio of maximum intensity to minimum intensity is\",round(ImaxbyImin,3)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 5, Page number 32" + ] + }, + { + "cell_type": "code", + "execution_count": 21, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ratio of intensity is\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "ImaxbyImin=9/1; #ratio of fringes\n", + "\n", + "#Calculation\n", + "amaxbyamin=math.sqrt(ImaxbyImin);\n", + "#Result\n", + "print \"ratio of intensity is\"," + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 6, Page number 33" + ] + }, + { + "cell_type": "code", + "execution_count": 24, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "distance between slits is 2 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=500*10**-9; #wavelength(m)\n", + "D=2; #distance of screen from slits(m)\n", + "l=5*10**-2; #distance(m)\n", + "n=100; #number of fringes\n", + "\n", + "#Calculation\n", + "beta=l/n;\n", + "d=lamda*D/beta; #distance between slits(m)\n", + "\n", + "#Result\n", + "print \"distance between slits is\",int(d*10**3),\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 7, Page number 33" + ] + }, + { + "cell_type": "code", + "execution_count": 26, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fringe width is 2.75 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=0.2*10**-3; #distance between slits(m)\n", + "lamda=550*10**-9; #wavelength(m)\n", + "D=1; #distance of screen from slits(m)\n", + "\n", + "#Calculation\n", + "beta=lamda*D/d; #fringe width(m)\n", + "\n", + "#Result\n", + "print \"fringe width is\",beta*10**3,\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 8, Page number 33" + ] + }, + { + "cell_type": "code", + "execution_count": 32, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "angular position of 10th maximum is 3.13 degrees\n", + "angular position of 1st maximum is 0.156 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=10; \n", + "lamda=5460*10**-10; #wavelength(m)\n", + "d=0.1*10**-3; #distance between slits(m)\n", + "D=2; #distance of screen from slits(m)\n", + "\n", + "#Calculation\n", + "x10=n*lamda*D/d; #distance from centre where 10th maximum is obtained(m)\n", + "tantheta1=x10/2; #angular position of 10th maximum(radian)\n", + "tantheta1=tantheta1*180/math.pi; #angular position of 10th maximum(degrees)\n", + "x1=lamda*D/(2*d); #distance from centre where 1st maximum is obtained(m)\n", + "tantheta2=x1/2; #angular position of 1st maximum(radian)\n", + "tantheta2=tantheta2*180/math.pi; #angular position of 1st maximum(degrees)\n", + "\n", + "#Result\n", + "print \"angular position of 10th maximum is\",round(tantheta1,2),\"degrees\"\n", + "print \"angular position of 1st maximum is\",round(tantheta2,3),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 9, Page number 34" + ] + }, + { + "cell_type": "code", + "execution_count": 36, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + " least distance of the point from central maximum is 13 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda1=650*10**-9; #wavelength(m)\n", + "lamda2=500*10**-9; #wavelength(m)\n", + "n1=10;\n", + "n2=13;\n", + "D=1; #distance(m)\n", + "d=0.5*10**-3; #seperation(m)\n", + "\n", + "#Calculation\n", + "x=n1*lamda1*D/d; #least distance of the point from central maximum(m)\n", + "\n", + "#Result\n", + "print \"least distance of the point from central maximum is\",int(x*10**3),\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 10, Page number 35" + ] + }, + { + "cell_type": "code", + "execution_count": 40, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thcikness of glass plate is 8.0 *10**-6 m\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=5;\n", + "lamda=4800*10**-10; #wavelength(m)\n", + "mew_mewdash=0.3; \n", + "\n", + "#Calculation\n", + "t=n*lamda/mew_mewdash; #thcikness of glass plate(m)\n", + "\n", + "#Result\n", + "print \"thcikness of glass plate is\",t*10**6,\"*10**-6 m\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 11, Page number 35" + ] + }, + { + "cell_type": "code", + "execution_count": 47, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of oil is 1.38 *10**-5\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "v=0.2; #volume(cc)\n", + "a=1*10**4; #area(cm**2)\n", + "r=0;\n", + "n=1;\n", + "lamda=5.5*10**-5; #wavelength(cm)\n", + "t=2;\n", + "\n", + "#Calculation\n", + "d=v/a; #thickness of film(cm)\n", + "mew=n*lamda/(2*t*math.cos(r)); #refractive index of oil\n", + "\n", + "#Result\n", + "print \"refractive index of oil is\",round(mew*10**5,2),\"*10**-5\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 12, Page number 35" + ] + }, + { + "cell_type": "code", + "execution_count": 53, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of light for 1st order is 12.2 *10**-5 cm\n", + "answer in the book varies due to rounding off errors\n", + "wavelength of light for 2nd order is 6.09 *10**-5 cm\n", + "wavelength of light for 3rd order is 4.06 *10**-5 cm\n", + "wavelength of light for 4th order is 3.0 *10**-5 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "mew=1.33; #refractive index\n", + "i=35*math.pi/180; #angle of incidence(radian)\n", + "d=5*10**-5; #thickness(cm)\n", + "n1=1; #order \n", + "n2=2; #order\n", + "n3=3; #order \n", + "n4=4; #order\n", + "\n", + "#Calculation\n", + "r=180/math.pi*math.asin(math.sin(i)/mew); #angle of reflection(degrees)\n", + "lamda1=2*mew*d*math.cos(r)/n1; #wavelength of light for 1st order(cm)\n", + "lamda2=2*mew*d*math.cos(r)/n2; #wavelength of light for 2nd order(cm)\n", + "lamda3=2*mew*d*math.cos(r)/n3; #wavelength of light for 3rd order(cm)\n", + "lamda4=2*mew*d*math.cos(r)/n4; #wavelength of light for 4th order(cm)\n", + "\n", + "#Result\n", + "print \"wavelength of light for 1st order is\",round(lamda1*10**5,1),\"*10**-5 cm\"\n", + "print \"answer in the book varies due to rounding off errors\"\n", + "print \"wavelength of light for 2nd order is\",round(lamda2*10**5,2),\"*10**-5 cm\"\n", + "print \"wavelength of light for 3rd order is\",round(lamda3*10**5,2),\"*10**-5 cm\"\n", + "print \"wavelength of light for 4th order is\",round(lamda4*10**5,1),\"*10**-5 cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 13, Page number 36" + ] + }, + { + "cell_type": "code", + "execution_count": 56, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fringe width is 0.09 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "x=15; #distance(cm)\n", + "d=0.005; #diameter(cm)\n", + "lamda=6000*10**-8; #wavelength(cm)\n", + "\n", + "#Calculation\n", + "alpha=d/x; #angle(radian)\n", + "beta=lamda/(2*alpha); #fringe width(cm)\n", + "\n", + "#Result\n", + "print \"fringe width is\",beta,\"cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 14, Page number 36" + ] + }, + { + "cell_type": "code", + "execution_count": 58, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "distance from edge of the wedge is 2.85 *10**-4 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "alpha=0.01; #angle(radian)\n", + "n=10;\n", + "lamda=6000*10**-10; #wavelength(m)\n", + "\n", + "#Calculation\n", + "x=((2*n)-1)*lamda/(4*alpha); #distance from edge of the wedge(m)\n", + "\n", + "#Result\n", + "print \"distance from edge of the wedge is\",x*10**4,\"*10**-4 m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 15, Page number 36" + ] + }, + { + "cell_type": "code", + "execution_count": 63, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "diameter of 5th fringe is 0.63 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5460*10**-8; #wavelength(cm)\n", + "f=400; #focal length(cm)\n", + "n=5;\n", + "mew=1.5; #refractive index\n", + "\n", + "#Calculation\n", + "R=2*f*(mew-1); #radius(cm)\n", + "Dn=math.sqrt(2*((2*n)-1)*lamda*R); #diameter of 5th fringe(cm)\n", + "\n", + "#Result\n", + "print \"diameter of 5th fringe is\",round(Dn,2),\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 16, Page number 37" + ] + }, + { + "cell_type": "code", + "execution_count": 72, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength in infrared region is 26600 *10**-10 m\n", + "wavelength in infrared region is 8866.7 *10**-10 m\n", + "wavelength in visible region is 5320 *10**-10 m\n", + "wavelength in ultraviolet region is 3800 *10**-10 m\n", + "of all the wavelengths reflected, 5320 angstrom is the wavelength in the visible region\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "t=500*10**-9; #thickness(m)\n", + "f=400; #focal length(cm)\n", + "n1=0;\n", + "n2=1;\n", + "n3=2;\n", + "n4=3;\n", + "mew=1.33; #refractive index\n", + "\n", + "#Calculation\n", + "lamda1=4*mew*t/((2*n1)+1); #wavelength in infrared region(m)\n", + "lamda2=4*mew*t/((2*n2)+1); #wavelength in infrared region(m)\n", + "lamda3=4*mew*t/((2*n3)+1); #wavelength in visible region(m)\n", + "lamda4=4*mew*t/((2*n4)+1); #wavelength in ultraviolet region(m)\n", + "\n", + "#Result\n", + "print \"wavelength in infrared region is\",int(lamda1*10**10),\"*10**-10 m\"\n", + "print \"wavelength in infrared region is\",round(lamda2*10**10,1),\"*10**-10 m\"\n", + "print \"wavelength in visible region is\",int(lamda3*10**10),\"*10**-10 m\"\n", + "print \"wavelength in ultraviolet region is\",int(lamda4*10**10),\"*10**-10 m\"\n", + "print \"of all the wavelengths reflected,\",int(lamda3*10**10),\"angstrom is the wavelength in the visible region\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 17, Page number 38" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "order of interference is 6\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "i=60*math.pi/180; #angle of incidence(radian)\n", + "mew=1.33; #refractive index\n", + "t=1.5*10**-6; #thickness(m)\n", + "lamda=5*10**-7; #wavelength(m)\n", + "\n", + "#Calculation\n", + "r=(180/math.pi)*math.asin(math.sin(i)/mew); #angle of reflection(degrees)\n", + "r=round(r,1)*math.pi/180; #angle of reflection(degrees)\n", + "n=2*mew*t*math.cos(r)/lamda; #order of interference\n", + "\n", + "#Result\n", + "print \"order of interference is\",int(n)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 18, Page number 38" + ] + }, + { + "cell_type": "code", + "execution_count": 82, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "smallest thickness of the plate is 3927 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "mew=1.5; #refractive index\n", + "lamda=5890*10**-10; #wavelength(m)\n", + "r=60*math.pi/180; #angle of reflection(radian)\n", + "\n", + "#Calculation\n", + "t=lamda/(2*mew*math.cos(r)); #smallest thickness of the plate(m)\n", + "\n", + "#Result\n", + "print \"smallest thickness of the plate is\",int(round(t*10**10)),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 19, Page number 39" + ] + }, + { + "cell_type": "code", + "execution_count": 85, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "diameter of 20th dark ring is 0.906 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D4=0.4; #diameter of 4th ring(cm)\n", + "D12=0.7; #diameter of 12th ring(cm)\n", + "p1=16;\n", + "p2=8; \n", + "n=4;\n", + "\n", + "#Calculation\n", + "x=n*p1/(n*p2);\n", + "D20=math.sqrt((D4**2)+(x*((D12**2)-(D4**2)))); #diameter of 20th dark ring(cm)\n", + "\n", + "#Result\n", + "print \"diameter of 20th dark ring is\",round(D20,3),\"cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 20, Page number 39" + ] + }, + { + "cell_type": "code", + "execution_count": 89, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of the liquid is 1.215\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D10=1.4; #diameter of 10th ring(cm)\n", + "D10_dash=1.27; #changed diameter of 10th ring(cm)\n", + "\n", + "#Calculation\n", + "mew=(D10**2)/(D10_dash**2); #refractive index of the liquid\n", + "\n", + "#Result\n", + "print \"refractive index of the liquid is\",round(mew,3)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 21, Page number 39" + ] + }, + { + "cell_type": "code", + "execution_count": 99, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of light used is 6.875 *10**-5 cm\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D25=0.8; #diameter of 25th ring(cm)\n", + "D5=0.3; #diameter of 5th ring(cm)\n", + "p=25-5;\n", + "R=100; #radius of curvature(cm)\n", + "\n", + "#Calculation\n", + "Nr=(D25**2)-(D5**2); #numerator\n", + "Dr=4*p*R; #denominator\n", + "lamda=Nr/Dr; #wavelength of light used(cm)\n", + "\n", + "#Result\n", + "print \"wavelength of light used is\",lamda*10**5,\"*10**-5 cm\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 22, Page number 40" + ] + }, + { + "cell_type": "code", + "execution_count": 105, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "total number of lines in the grating is 9539.3\n", + "answer given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "w=0.02; #width(m)\n", + "theta=(math.pi/180)*(18+(14/60)); #angle(radian)\n", + "n=1; \n", + "lamda=6.56*10**-7; #wavelength(m)\n", + "\n", + "#Calculation\n", + "M=w*math.sin(theta)/(n*lamda); #total number of lines in the grating \n", + "\n", + "#Result\n", + "print \"total number of lines in the grating is\",round(M,1)\n", + "print \"answer given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 23, Page number 40" + ] + }, + { + "cell_type": "code", + "execution_count": 110, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "required thickness of plate is 3927 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5890*10**-10; #wavelength(m)\n", + "mew=1.5; #refractive index\n", + "r=60*math.pi/180; #angle of reflection(radian)\n", + "\n", + "#Calculation\n", + "t=lamda/(2*mew*math.cos(r)); #required thickness of plate(m)\n", + "\n", + "#Result\n", + "print \"required thickness of plate is\",int(round(t*10**10)),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 24, Page number 40" + ] + }, + { + "cell_type": "code", + "execution_count": 115, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of liquid is 1.31\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "R=1; #radius of curvature(m)\n", + "n=5;\n", + "lamda=5.895*10**-7; #wavelength(m)\n", + "dn=0.3*10**-2; #diameter of ring(m)\n", + "\n", + "#Calculation\n", + "mew=4*R*n*lamda/(dn**2); #refractive index of liquid\n", + "\n", + "#Result\n", + "print \"refractive index of liquid is\",mew" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 25, Page number 41" + ] + }, + { + "cell_type": "code", + "execution_count": 118, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "value of slit width is 13000 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=6500; #wavelength(m)\n", + "theta=30*math.pi/180; #angle(radian)\n", + "\n", + "#Calculation\n", + "a=lamda/math.sin(theta); #value of slit width(angstrom)\n", + "\n", + "#Result\n", + "print \"value of slit width is\",int(a),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 27, Page number 41" + ] + }, + { + "cell_type": "code", + "execution_count": 120, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength in infrared region is 26600 *10**-10 m\n", + "wavelength in infrared region is 8866.7 *10**-10 m\n", + "wavelength in visible region is 5320 *10**-10 m\n", + "wavelength in ultraviolet region is 3800 *10**-10 m\n", + "of all the wavelengths reflected, 5320 angstrom is the wavelength in the visible region\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "t=500*10**-9; #thickness(m)\n", + "n1=0;\n", + "n2=1;\n", + "n3=2;\n", + "n4=3;\n", + "mew=1.33; #refractive index\n", + "\n", + "#Calculation\n", + "lamda1=4*mew*t/((2*n1)+1); #wavelength in infrared region(m)\n", + "lamda2=4*mew*t/((2*n2)+1); #wavelength in infrared region(m)\n", + "lamda3=4*mew*t/((2*n3)+1); #wavelength in visible region(m)\n", + "lamda4=4*mew*t/((2*n4)+1); #wavelength in ultraviolet region(m)\n", + "\n", + "#Result\n", + "print \"wavelength in infrared region is\",int(lamda1*10**10),\"*10**-10 m\"\n", + "print \"wavelength in infrared region is\",round(lamda2*10**10,1),\"*10**-10 m\"\n", + "print \"wavelength in visible region is\",int(lamda3*10**10),\"*10**-10 m\"\n", + "print \"wavelength in ultraviolet region is\",int(lamda4*10**10),\"*10**-10 m\"\n", + "print \"of all the wavelengths reflected,\",int(lamda3*10**10),\"angstrom is the wavelength in the visible region\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 28, Page number 42" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "order of interference is 6\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "i=60*math.pi/180; #angle of incidence(radian)\n", + "mew=1.33; #refractive index\n", + "t=1.5*10**-6; #thickness(m)\n", + "lamda=5*10**-7; #wavelength(m)\n", + "\n", + "#Calculation\n", + "r=(180/math.pi)*math.asin(math.sin(i)/mew); #angle of reflection(degrees)\n", + "r=round(r,1)*math.pi/180; #angle of reflection(degrees)\n", + "n=2*mew*t*math.cos(r)/lamda; #order of interference\n", + "\n", + "#Result\n", + "print \"order of interference is\",int(n)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 29, Page number 42" + ] + }, + { + "cell_type": "code", + "execution_count": 121, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "smallest thickness of the plate is 3927 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "mew=1.5; #refractive index\n", + "lamda=5890*10**-10; #wavelength(m)\n", + "r=60*math.pi/180; #angle of reflection(radian)\n", + "\n", + "#Calculation\n", + "t=lamda/(2*mew*math.cos(r)); #smallest thickness of the plate(m)\n", + "\n", + "#Result\n", + "print \"smallest thickness of the plate is\",int(round(t*10**10)),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 30, Page number 43" + ] + }, + { + "cell_type": "code", + "execution_count": 124, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of air film is 2.5 micro m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "Dn=2*10**-3; #diameter of ring(m)\n", + "n=10;\n", + "lamda=500*10**-9; #wavelength(m)\n", + "\n", + "#Calculation\n", + "R=Dn**2/(4*n*lamda); #radius(m)\n", + "t=Dn**2/(8*R); #thickness of air film(m)\n", + "\n", + "#Result\n", + "print \"thickness of air film is\",t*10**6,\"micro m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 31, Page number 43" + ] + }, + { + "cell_type": "code", + "execution_count": 131, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of light is 588 nm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D5=0.336*10**-2; #diameter of 5th ring(m)\n", + "D15=0.59*10**-2; #diameter of 15th ring(m)\n", + "m=10;\n", + "R=1; #radius of curvature(m)\n", + "\n", + "#Calculation\n", + "lamda=((D15**2)-(D5**2))/(4*m*R); #wavelength of light(m)\n", + "\n", + "#Result\n", + "print \"wavelength of light is\",int(lamda*10**9),\"nm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 32, Page number 43" + ] + }, + { + "cell_type": "code", + "execution_count": 135, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "radius of curvature of lens is 1.059 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D10=0.5*10**-2; #diameter of 10th ring(m)\n", + "n=10;\n", + "lamda=5900*10**-10; #wavelength(m)\n", + "\n", + "#Calculation\n", + "R=D10**2/(4*n*lamda); #radius of curvature of lens(m)\n", + "\n", + "#Result\n", + "print \"radius of curvature of lens is\",round(R,3),\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 33, Page number 44" + ] + }, + { + "cell_type": "code", + "execution_count": 138, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of liquid is 1.31\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "Dn=0.3*10**-2; #diameter of 10th ring(m)\n", + "R=1; #radius of curvature(m)\n", + "n=5;\n", + "lamda=5.895*10**-7; #wavelength(m)\n", + "\n", + "#Calculation\n", + "mew=4*R*n*lamda/Dn**2; #refractive index of liquid\n", + "\n", + "#Result\n", + "print \"refractive index of liquid is\",mew" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 34, Page number 44" + ] + }, + { + "cell_type": "code", + "execution_count": 139, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of the liquid is 1.215\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D10=1.4; #diameter of 10th ring(cm)\n", + "D10_dash=1.27; #changed diameter of 10th ring(cm)\n", + "\n", + "#Calculation\n", + "mew=(D10**2)/(D10_dash**2); #refractive index of the liquid\n", + "\n", + "#Result\n", + "print \"refractive index of the liquid is\",round(mew,3)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 35, Page number 45" + ] + }, + { + "cell_type": "code", + "execution_count": 144, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "intensity ratio is 9 : 4\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "I1=1;\n", + "I2=25; #intensity ratio\n", + "\n", + "#Calculation\n", + "A1=math.sqrt(I1);\n", + "A2=math.sqrt(I2); \n", + "Imax=(A1+A2)**2;\n", + "Imin=(A2-A1)**2; #intensity ratio\n", + "Imax=Imax/4;\n", + "Imin=Imin/4; #dividing by a common factor to get the least ratio\n", + "\n", + "#Result\n", + "print \"intensity ratio is\",int(Imax),\":\",int(Imin)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 36, Page number 45" + ] + }, + { + "cell_type": "code", + "execution_count": 148, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "order is 28\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda1=6*10**-5; #wavelength(cm)\n", + "lamda2=4.5*10**-5; #wavelength(cm)\n", + "n1=21;\n", + "\n", + "#Calculation\n", + "n2=n1*lamda1/lamda2; #order\n", + "\n", + "#Result\n", + "print \"order is\",int(n2)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 37, Page number 46" + ] + }, + { + "cell_type": "code", + "execution_count": 17, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "slit separation is 1.02 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=51*10**-6; #wavelength(cm)\n", + "D=200; #separation between screen and slit(cm)\n", + "beta=1; #fringe width(cm)\n", + "n=10;\n", + "\n", + "#Calculation\n", + "d=lamda*D/beta; #slit separation(cm)\n", + "\n", + "#Result\n", + "print \"slit separation is\",d*100,\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 38, Page number 46" + ] + }, + { + "cell_type": "code", + "execution_count": 155, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of mica sheet is 6.897 *10**-4 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D=50; #separation between screen and slit(cm)\n", + "x=0.2; #fringe shift(cm)\n", + "d=0.1; #separation between slits(cm)\n", + "mew=1.58; #refractive index\n", + "\n", + "#Calculation\n", + "tow=x*d/(D*(mew-1)); #thickness of mica sheet(cm)\n", + "\n", + "#Result\n", + "print \"thickness of mica sheet is\",round(tow*10**4,3),\"*10**-4 cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 39, Page number 47" + ] + }, + { + "cell_type": "code", + "execution_count": 161, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fringe width is 0.05 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5000*10**-8; #wavelength(cm)\n", + "D=50; #separation between screen and slit(cm)\n", + "d=0.05; #separation between slits(cm)\n", + "\n", + "#Calculation\n", + "beta=lamda*D/d; #fringe width(cm)\n", + "\n", + "#Result\n", + "print \"fringe width is\",beta,\"cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 40, Page number 47" + ] + }, + { + "cell_type": "code", + "execution_count": 175, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength is 6700 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D=180; #separation between screen and slit(cm)\n", + "d=0.04; #separation between slits(cm)\n", + "beta=0.3; #fringe width(cm)\n", + "\n", + "#Calculation\n", + "lamda=round(beta*d*10**4/D,2); #wavelength(cm)\n", + "\n", + "#Result\n", + "print \"wavelength is\",int(lamda*10**4),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 41, Page number 47" + ] + }, + { + "cell_type": "code", + "execution_count": 181, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength is 5000 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D=80; #separation between screen and slit(cm)\n", + "d=0.1; #separation between slits(cm)\n", + "beta=0.04; #fringe width(cm)\n", + "\n", + "#Calculation\n", + "lamda=beta*d/D; #wavelength(cm)\n", + "\n", + "#Result\n", + "print \"wavelength is\",int(lamda*10**8),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 42, Page number 48" + ] + }, + { + "cell_type": "code", + "execution_count": 182, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fringe width is 0.05 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5000*10**-8; #wavelength(cm)\n", + "D=50; #separation between screen and slit(cm)\n", + "d=0.05; #separation between slits(cm)\n", + "\n", + "#Calculation\n", + "beta=lamda*D/d; #fringe width(cm)\n", + "\n", + "#Result\n", + "print \"fringe width is\",beta,\"cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 43, Page number 48" + ] + }, + { + "cell_type": "code", + "execution_count": 185, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of soap film is 6.5789 *10**-5 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=7*10**-5; #wavelength(cm)\n", + "n=2;\n", + "mew=1.33; #refractive index\n", + "\n", + "#Calculation\n", + "t=(((2*n)+1)*lamda/2)/(2*mew); #thickness of soap film(cm)\n", + "\n", + "#Result\n", + "print \"thickness of soap film is\",round(t*10**5,4),\"*10**-5 cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 44, Page number 49" + ] + }, + { + "cell_type": "code", + "execution_count": 186, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index is 1.52\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5460*10**-8; #wavelength(cm)\n", + "t=6.3*10**-4; #thickness(cm)\n", + "n=6;\n", + "\n", + "#Calculation\n", + "mew=(n*lamda/t)+1; #refractive index\n", + "\n", + "#Result\n", + "print \"refractive index is\",mew" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 45, Page number 49" + ] + }, + { + "cell_type": "code", + "execution_count": 189, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness is 14.3 *10**-4 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5000*10**-8; #wavelength(cm)\n", + "n=16;\n", + "mew=1.56; #refractive index\n", + "\n", + "#Calculation\n", + "t=n*lamda/(mew-1); #thickness(cm)\n", + "\n", + "#Result\n", + "print \"thickness is\",round(t*10**4,1),\"*10**-4 cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 46, Page number 50" + ] + }, + { + "cell_type": "code", + "execution_count": 192, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "least thickness of glass plate is 3.11 *10**-5 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=6000*10**-8; #wavelength(cm)\n", + "n=1;\n", + "mew=1.5; #refractive index\n", + "r=50*math.pi/180; #angle of refraction(radian)\n", + "\n", + "#Calculation\n", + "t=n*lamda/(2*mew*math.cos(r)); #least thickness of glass plate(cm)\n", + "\n", + "#Result\n", + "print \"least thickness of glass plate is\",round(t*10**5,2),\"*10**-5 cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 47, Page number 50" + ] + }, + { + "cell_type": "code", + "execution_count": 196, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "least thickness of glass plate is 6 *10**-4 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5000*10**-8; #wavelength(cm)\n", + "mew=1.5; #refractive index\n", + "beta=1; #assume\n", + "S=6*beta;\n", + "\n", + "#Calculation\n", + "t=S*lamda/(beta*(mew-1)); #least thickness of glass plate(cm)\n", + "\n", + "#Result\n", + "print \"least thickness of glass plate is\",int(t*10**4),\"*10**-4 cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 48, Page number 51" + ] + }, + { + "cell_type": "code", + "execution_count": 199, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of liquid is 1.29\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D8=1.42; #diameter of 8th ring(cm)\n", + "D8dash=1.25; #changed diameter of 8th ring(cm)\n", + "\n", + "#Calculation\n", + "mew=D8**2/D8dash**2; #refractive index of liquid\n", + "\n", + "#Result\n", + "print \"refractive index of liquid is\",round(mew,2)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 49, Page number 51" + ] + }, + { + "cell_type": "code", + "execution_count": 206, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of thinnest film is 2.2556 *10**-5 cm\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=6000*10**-8; #wavelength(cm)\n", + "n=1;\n", + "mew=1.33; #refractive index\n", + "r=0*math.pi/180; #angle of incidence(radian)\n", + "\n", + "#Calculation\n", + "t=n*lamda/(2*mew*math.cos(r)); #thickness of thinnest film(cm)\n", + "\n", + "#Result\n", + "print \"thickness of thinnest film is\",round(t*10**5,4),\"*10**-5 cm\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 50, Page number 51" + ] + }, + { + "cell_type": "code", + "execution_count": 23, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "radius of curvature of lens is 1250 cm\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=6000*10**-8; #wavelength(cm)\n", + "Dm=0.65; #diameter of 8th ring(cm)\n", + "Dn=0.35; #changed diameter of 8th ring(cm)\n", + "\n", + "#Calculation\n", + "R=(Dm**2-Dn**2)/(4*lamda); #radius of curvature of lens(cm)\n", + "\n", + "#Result\n", + "print \"radius of curvature of lens is\",int(R),\"cm\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 51, Page number 52" + ] + }, + { + "cell_type": "code", + "execution_count": 25, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of liquid is 1.3456\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "Da=1.45; #diameter of 12th ring in air medium(cm)\n", + "Dl=1.25; #diameter of 12th ring in liquid(cm)\n", + "\n", + "#Calculation\n", + "mew=Da**2/Dl**2; #refractive index of liquid\n", + "\n", + "#Result\n", + "print \"refractive index of liquid is\",mew" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 52, Page number 52" + ] + }, + { + "cell_type": "code", + "execution_count": 27, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "diameter of 25th ring is 0.824 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "m1=15;\n", + "n=5;\n", + "m2=25;\n", + "D15=0.62; #diameter of 15th ring(cm)\n", + "D5=0.3; #diameter of 5th ring(cm)\n", + "\n", + "#Calculation\n", + "x=D15**2-D5**2;\n", + "y=m1-n;\n", + "z=m2-n;\n", + "r=4*z/(4*y); \n", + "D25=math.sqrt((r*x)+(D5**2)); #diameter of 25th ring(cm)\n", + "\n", + "#Result\n", + "print \"diameter of 25th ring is\",round(D25,3),\"cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 53, Page number 53" + ] + }, + { + "cell_type": "code", + "execution_count": 31, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "radius of curvature of lens is 107.8 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5890*10**-8; #wavelength(cm)\n", + "Dm=0.590; #diameter of 8th ring(cm)\n", + "Dn=0.336; #changed diameter of 8th ring(cm)\n", + "m=15;\n", + "n=5;\n", + "\n", + "#Calculation\n", + "R=(Dm-Dn)/(4*lamda*(m-n)); #radius of curvature of lens(cm)\n", + "\n", + "#Result\n", + "print \"radius of curvature of lens is\",round(R,1),\"cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 54, Page number 53" + ] + }, + { + "cell_type": "code", + "execution_count": 34, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of light is 6.696 *10**-5 cm\n", + "answer given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "R=70; #radius of curvature of lens(cm)\n", + "n=10;\n", + "Dn=0.433; #diameter of 10th dark ring(cm)\n", + "\n", + "#Calculation\n", + "lamda=Dn**2/(4*R*n); #wavelength of light(cm)\n", + "\n", + "#Result\n", + "print \"wavelength of light is\",round(lamda*10**5,3),\"*10**-5 cm\"\n", + "print \"answer given in the book varies due to rounding off errors\"" + ] + } + ], + "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 +} diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter2.ipynb b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter2.ipynb new file mode 100644 index 00000000..37a1dea9 --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter2.ipynb @@ -0,0 +1,1022 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": { + "collapsed": true + }, + "source": [ + "# 2: Diffraction" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 1, Page number 73" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of lines per centimeter is 5000\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5*10**-5; #wavelength(cm)\n", + "k=2; #order\n", + "theta=30*math.pi/180; #angle(radian)\n", + "\n", + "#Calculation\n", + "e=k*lamda/math.sin(theta); #number of lines(cm)\n", + "n=1/e; #number of lines per centimeter \n", + "\n", + "#Result\n", + "print \"number of lines per centimeter is\",int(round(n))\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 2, Page number 73" + ] + }, + { + "cell_type": "code", + "execution_count": 21, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "difference in angles of deviation is 46.7 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5000*10**-8; #wavelength(cm)\n", + "e=1/6000; #number of lines(cm)\n", + "\n", + "#Calculation\n", + "theta1=math.asin(lamda/e)*180/math.pi; #angle for 1st order(degrees) \n", + "theta2=math.asin(3*lamda/e)*180/math.pi; #angle for 3rd order(degrees) \n", + "theta=round(theta2,1)-round(theta1,1); #difference in angles of deviation(degrees)\n", + "\n", + "#Result\n", + "print \"difference in angles of deviation is\",theta,\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 3, Page number 74" + ] + }, + { + "cell_type": "code", + "execution_count": 29, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "minimum number of lines per cm is 196.33\n", + "answer given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5890*10**-5; #wavelength(cm)\n", + "dlamda=6*10**-5; #difference in wavelength(cm)\n", + "k=2; #order\n", + "w=2.5; #width(cm)\n", + "\n", + "#Calculation\n", + "N=lamda/(k*dlamda*w); #minimum number of lines per cm\n", + "\n", + "#Result\n", + "print \"minimum number of lines per cm is\",round(N,2)\n", + "print \"answer given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 4, Page number 74" + ] + }, + { + "cell_type": "code", + "execution_count": 34, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of lines required for resolution is 982 and number of lines on grating is 850\n", + "hence lines will not be resolved\n", + "number of lines required for resolution is 491 and number of lines on grating is 850\n", + "hence lines will appear resolved\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5890*10**-8; #wavelength(cm)\n", + "dlamda=6*10**-8; #difference in wavelength(cm)\n", + "w=2; #width(cm)\n", + "n=425; #number of lines on grating\n", + "k=2; #order\n", + "\n", + "#Calculation\n", + "N=w*n; #number of lines on grating \n", + "N1=int(round(lamda/dlamda)); #number of lines required for resolution\n", + "N2=int(round(lamda/(k*dlamda))); #number of lines required for resolution\n", + "\n", + "#Result\n", + "print \"number of lines required for resolution is\",N1,\"and number of lines on grating is\",N\n", + "print \"hence lines will not be resolved\"\n", + "print \"number of lines required for resolution is\",N2,\"and number of lines on grating is\",N\n", + "print \"hence lines will appear resolved\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 5, Page number 75" + ] + }, + { + "cell_type": "code", + "execution_count": 39, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "angle of separation is 16 minutes\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda1=5016*10**-8; #wavelength(cm)\n", + "lamda2=5048*10**-8; #difference in wavelength(cm)\n", + "k=2; #order\n", + "n=15000; #number of lines/inch\n", + "\n", + "#Calculation\n", + "e=2.54/n; \n", + "theta1=math.asin(2*lamda1/e)*180/math.pi; #angle for 1st wavelength(degrees) \n", + "theta2=math.asin(2*lamda2/e)*180/math.pi; #angle for 2nd wavelength(degrees) \n", + "theta=int(60*(theta2-theta1)); #angle of separation(minutes)\n", + "\n", + "#Result\n", + "print \"angle of separation is\",theta,\"minutes\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 6, Page number 75" + ] + }, + { + "cell_type": "code", + "execution_count": 46, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dispersive power of grating is 15000\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=4000; #number of lines/cm\n", + "lamda=5000*10**-8; #wavelength(cm)\n", + "k=3; #order\n", + "\n", + "#Calculation\n", + "e=1/n; \n", + "sintheta=k*lamda/e; \n", + "costheta=math.sqrt(1-sintheta**2);\n", + "dthetabydlamda=k*n/costheta; #dispersive power of grating\n", + "\n", + "#Result\n", + "print \"dispersive power of grating is\",int(dthetabydlamda)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 7, Page number 76" + ] + }, + { + "cell_type": "code", + "execution_count": 50, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "highest order of spectrum is 3\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=5000; #number of lines/cm\n", + "lamda=6000*10**-8; #wavelength(cm)\n", + "\n", + "#Calculation\n", + "e=1/n; \n", + "k=e/lamda; #highest order of spectrum\n", + "\n", + "#Result\n", + "print \"highest order of spectrum is\",int(k)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 8, Page number 76" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of lines is 6061.7 *10**-8 cm\n", + "answer given in the book varies due to rounding off errors\n", + "minimum grating width required is 4.2 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta=10*math.pi/180; #angle(radian)\n", + "dtheta=3*math.pi/(60*60*180); #difference of angle(radian)\n", + "dlamda=5*10**-9; #wavelength(cm)\n", + "k=2;\n", + "\n", + "#Calculation\n", + "lamda=math.sin(theta)*dlamda/(math.cos(theta)*dtheta); \n", + "lamdanew=lamda+dlamda; #wavelength of lines(cm)\n", + "N=lamda/(dlamda*k);\n", + "Ne=N*k*lamda/math.sin(theta); #minimum grating width required(cm)\n", + "\n", + "#Result\n", + "print \"wavelength of lines is\",round(lamda*10**8,1),\"*10**-8 cm\"\n", + "print \"answer given in the book varies due to rounding off errors\"\n", + "print \"minimum grating width required is\",round(Ne,1),\"cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 9, Page number 77" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "grating element is 5 *10**-4 cm\n", + "resolving power is 10000\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=5000*10**-8; #wavelength(cm)\n", + "sintheta1=0.2;\n", + "sintheta2=0.3;\n", + "w=2.5; #width of grating(cm)\n", + "\n", + "#Calculation\n", + "e=lamda/(sintheta2-sintheta1); #grating element is\n", + "N=2*w/e; #resolving power\n", + "\n", + "#Result\n", + "print \"grating element is\",int(e*10**4),\"*10**-4\",\"cm\"\n", + "print \"resolving power is\",int(round(N))" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 10, Page number 77" + ] + }, + { + "cell_type": "code", + "execution_count": 58, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "width of central maxima is 1.33 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=2; #diffraction observed(m)\n", + "lamda=500*10**-9; #wavelength(m)\n", + "a=1.5*10**-3; #slit width(m)\n", + "\n", + "#Calculation\n", + "w=2*d*lamda/a; #width of central maxima(m)\n", + "\n", + "#Result\n", + "print \"width of central maxima is\",round(w*10**3,2),\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 11, Page number 77" + ] + }, + { + "cell_type": "code", + "execution_count": 63, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "slit width is 0.2 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=2; #diffraction observed(m)\n", + "lamda=500*10**-9; #wavelength(m)\n", + "x=5*10**-3; #width of central maxima(m)\n", + "\n", + "#Calculation\n", + "a=d*lamda/x; #slit width(m)\n", + "\n", + "#Result\n", + "print \"slit width is\",a*10**3,\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 12, Page number 78" + ] + }, + { + "cell_type": "code", + "execution_count": 65, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "half angular width is 30 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=6000*10**-10; #wavelength(m)\n", + "a=12*10**-7; #slit width(m)\n", + "\n", + "#Calculation\n", + "theta=math.asin(lamda/a)*180/math.pi; #half angular width(degrees)\n", + "\n", + "#Result\n", + "print \"half angular width is\",int(theta),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 13, Page number 78" + ] + }, + { + "cell_type": "code", + "execution_count": 67, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "the orders 6 12 18 etc will be missing\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "b=0.8; #distance(mm)\n", + "a=0.16; #slit width(mm)\n", + "p1=1;\n", + "p2=2;\n", + "p3=3;\n", + "\n", + "#Calculation\n", + "nbyp=(a+b)/a; #ratio of missing orders\n", + "n1=int(nbyp*p1);\n", + "n2=int(nbyp*p2);\n", + "n3=int(nbyp*p3); #missing orders\n", + "\n", + "#Result\n", + "print \"the orders\",n1,n2,n3,\"etc will be missing\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 14, Page number 79" + ] + }, + { + "cell_type": "code", + "execution_count": 69, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "angular separation is 2.48 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "N=6000*10**2; #number of lines/m\n", + "m=3; #order\n", + "lamda1=500*10**-9; #wavelength(m)\n", + "lamda2=510*10**-9; #wavelength(m)\n", + "\n", + "#Calculation\n", + "sintheta1=m*N*lamda1; \n", + "theta1=math.asin(sintheta1)*180/math.pi; #angle(degrees)\n", + "sintheta2=m*N*lamda2; \n", + "theta2=math.asin(sintheta2)*180/math.pi; #angle(degrees)\n", + "theta=theta2-theta1; #angular separation(degrees)\n", + "\n", + "#Result\n", + "print \"angular separation is\",round(theta,2),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 15, Page number 79" + ] + }, + { + "cell_type": "code", + "execution_count": 77, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "highest order that can be seen is 2\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "N=15000/2.54*10**2; #number of lines/cm\n", + "lamda=600*10**-9; #wavelength(m)\n", + "\n", + "#Calculation\n", + "m=1/(N*lamda); #highest order that can be seen\n", + "\n", + "#Result\n", + "print \"highest order that can be seen is\",int(m)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 16, Page number 79" + ] + }, + { + "cell_type": "code", + "execution_count": 87, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "angular separation is 0.018 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "N=10000/2*10**2; #number of lines/m\n", + "m=1; #order\n", + "lamda1=5890*10**-10; #wavelength(m)\n", + "lamda2=5896*10**-10; #wavelength(m)\n", + "\n", + "#Calculation\n", + "sintheta1=m*N*lamda1; \n", + "theta1=math.asin(sintheta1)*180/math.pi; #angle(degrees)\n", + "sintheta2=m*N*lamda2; \n", + "theta2=math.asin(sintheta2)*180/math.pi; #angle(degrees)\n", + "theta=theta2-theta1; #angular separation(degrees)\n", + "\n", + "#Result\n", + "print \"angular separation is\",round(theta,3),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 17, Page number 80" + ] + }, + { + "cell_type": "code", + "execution_count": 90, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "slit width is 2.51 *10**-4 cm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta=15*math.pi/180; #angle(radian)\n", + "lamda=6500*10**-8; #wavelength(cm) \n", + "n=1; #order\n", + "\n", + "#Calculation\n", + "a=n*lamda/math.sin(theta); #slit width(cm)\n", + "\n", + "#Result\n", + "print \"slit width is\",round(a*10**4,2),\"*10**-4 cm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 18, Page number 80" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of light is 4524 angstrom\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta=15*math.pi/180; #angle(radian)\n", + "a=2.5*10**-6; #slit width(m)\n", + "\n", + "#Calculation\n", + "lamda=a*math.pi*math.sin(theta)*10**10/(1.43*math.pi); #wavelength of light(angstrom)\n", + "\n", + "#Result\n", + "print \"wavelength of light is\",int(lamda),\"angstrom\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 19, Page number 81" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of spectral line is 5882 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=2; #order\n", + "N=4250; #grating lines(lines/cm)\n", + "theta=30*math.pi/180; #angle(radian)\n", + "\n", + "#Calculation\n", + "e=1/N;\n", + "lamda=e*math.sin(theta)*10**8/n; #wavelength of spectral line(angstrom)\n", + "\n", + "#Result\n", + "print \"wavelength of spectral line is\",int(lamda),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 20, Page number 81" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "angular separation is 36.8699 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=1; #order\n", + "a=1*10**-6; #slit width(m)\n", + "lamda=600*10**-9; #wavelength of spectral line(m)\n", + "\n", + "#Calculation\n", + "theta=math.asin(n*lamda/a)*180/math.pi; #angular separation(degrees)\n", + "\n", + "#Result\n", + "print \"angular separation is\",round(theta,4),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 21, Page number 82" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "2 orders can be seen\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "N=10520; #grating lines(lines/cm)\n", + "theta=90*math.pi/180; #angle(radian)\n", + "lamda=5*10**-5; #wavelength of spectral line(cm)\n", + "\n", + "#Calculation\n", + "e=1/N;\n", + "n=e*math.sin(theta)/lamda; #order\n", + "\n", + "#Result\n", + "print int(round(n)),\"orders can be seen\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 22, Page number 82" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "slit width is 0.857 *10**-4 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "x=4.2*10**-3; #distance(m)\n", + "D=60*10**-2; #screen slit distance(m)\n", + "lamda=6000*10**-10; #wavelength(m)\n", + "\n", + "#Calculation\n", + "d=D*lamda/x; #slit width(m) \n", + "\n", + "#Result\n", + "print \"slit width is\",round(d*10**4,3),\"*10**-4 m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 23, Page number 83" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "possible order of spectra is 3\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "N=15000/2.54; #number of lines(per cm)\n", + "lamda=6000*10**-8; #wavelength(cm)\n", + "\n", + "#Calculation\n", + "d=1/N; #slit width(m) \n", + "m=d/lamda; #possible order of spectra \n", + "\n", + "#Result\n", + "print \"possible order of spectra is\",int(round(m))" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 24, Page number 83" + ] + }, + { + "cell_type": "code", + "execution_count": 19, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of light is 6000 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "D=150; #slit screen distance(cm)\n", + "d=0.03; #separation(cm)\n", + "beta=0.3; #fringe separation(cm)\n", + "\n", + "#Calculation\n", + "lamda=d*beta*10**8/D; #wavelength of light(angstrom)\n", + "\n", + "#Result\n", + "print \"wavelength of light is\",int(round(lamda)),\"angstrom\"" + ] + } + ], + "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 +} diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter3.ipynb b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter3.ipynb new file mode 100644 index 00000000..a8624044 --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter3.ipynb @@ -0,0 +1,233 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# 3: Polarization" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 1, Page number 97" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of quartz half wave plate is 0.0278 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=500*10**-9; #wavelength(m)\n", + "mewe=1.553; #refractive index of e-ray\n", + "mew0=1.544; #refractive index of o-ray\n", + "\n", + "#Calculation\n", + "t=lamda/(2*(mewe-mew0)); #thickness of quartz half wave plate(m)\n", + "\n", + "#Result\n", + "print \"thickness of quartz half wave plate is\",round(t/10**-3,4),\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 2, Page number 98" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of quartz half wave plate is 0.0164 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=589*10**-9; #wavelength(m)\n", + "mewe=1.553; #refractive index of e-ray\n", + "mew0=1.544; #refractive index of o-ray\n", + "\n", + "#Calculation\n", + "t=lamda/(4*(mewe-mew0)); #thickness of quartz half wave plate(m)\n", + "\n", + "#Result\n", + "print \"thickness of quartz half wave plate is\",round(t/10**-3,4),\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 3, Page number 98" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of quartz half wave plate is 0.0165 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=600*10**-9; #wavelength(m)\n", + "mewe=1.5533; #refractive index of e-ray\n", + "mew0=1.5442; #refractive index of o-ray\n", + "\n", + "#Calculation\n", + "t=lamda/(4*(mewe-mew0)); #thickness of quartz half wave plate(m)\n", + "\n", + "#Result\n", + "print \"thickness of quartz half wave plate is\",round(t/10**-3,4),\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 4, Page number 98" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "thickness of half wave plate is 0.0017138 mm\n", + "thickness of quarter wave plate is 0.000857 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=589.3*10**-9; #wavelength(m)\n", + "mewe=1.65833; #refractive index of e-ray\n", + "mew0=1.48640; #refractive index of o-ray\n", + "\n", + "#Calculation\n", + "t1=lamda/(2*(mewe-mew0)); #thickness of half wave plate(m)\n", + "t2=lamda/(4*(mewe-mew0)); #thickness of quarter wave plate(m)\n", + "\n", + "#Result\n", + "print \"thickness of half wave plate is\",round(t1/10**-3,7),\"mm\"\n", + "print \"thickness of quarter wave plate is\",round(t2/10**-3,6),\"mm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 5, Page number 99" + ] + }, + { + "cell_type": "code", + "execution_count": 17, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength for half wave plate is 619.2 m\n", + "wavelength for quarter wave plate is 309.6 mm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "t=0.9*10**-6; #thickness(m)\n", + "mewe=1.486; #refractive index of e-ray\n", + "mew0=1.658; #refractive index of o-ray\n", + "\n", + "#Calculation\n", + "lamda1=4*t*(mew0-mewe); #wavelength for half wave plate(m)\n", + "lamda2=2*t*(mew0-mewe); #wavelength for quarter wave plate(m)\n", + "\n", + "#Result\n", + "print \"wavelength for half wave plate is\",lamda1*10**9,\"m\"\n", + "print \"wavelength for quarter wave plate is\",lamda2*10**9,\"mm\"" + ] + } + ], + "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 +} diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter4.ipynb b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter4.ipynb new file mode 100644 index 00000000..d0509314 --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter4.ipynb @@ -0,0 +1,292 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# 4: Laser" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 1, Page number 136" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "relative population is 1.081 *10**30\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "c=3*10**8; #velocity of light(m/sec)\n", + "lamda=6943*10**-10; #wavelength(m)\n", + "h=6.626*10**-34; #planck's constant(Jsec)\n", + "Kb=1.38*10**-23; #boltzmann constant\n", + "T=300; #temperature(K)\n", + "\n", + "#Calculation\n", + "new=c/lamda; #frequency(Hz)\n", + "a=h*new/(Kb*T);\n", + "N1byN2=math.exp(a); #relative population\n", + "\n", + "#Result\n", + "print \"relative population is\",round(N1byN2/10**30,3),\"*10**30\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 2, Page number 137" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of photons emitted is 7.32 *10**15 photons/second\n", + "power density is 2.3 kW/m**2\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "c=3*10**8; #velocity of light(m/sec)\n", + "lamda=632.8*10**-9; #wavelength(m)\n", + "h=6.626*10**-34; #planck's constant(Jsec)\n", + "t=1; #time(sec)\n", + "P=2.3*10**-3; #power(W)\n", + "sa=1*10**-6; #spot area(m**2)\n", + "\n", + "#Calculation\n", + "new=c/lamda; #frequency(Hz)\n", + "n=P*t/(h*new); #number of photons emitted(per sec) \n", + "Pd=P/sa; #power density(kW/m**2)\n", + "\n", + "#Result\n", + "print \"number of photons emitted is\",round(n/10**15,2),\"*10**15 photons/second\"\n", + "print \"power density is\",Pd/10**3,\"kW/m**2\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 3, Page number 137" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength is 8628 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "c=3*10**8; #velocity of light(m/sec)\n", + "e=1.6*10**-19; #charge of electron(coulomb)\n", + "Eg=1.44*e; #band gap energy(J)\n", + "h=6.626*10**-34; #planck's constant(Jsec)\n", + "\n", + "#Calculation\n", + "lamda=h*c/Eg; #wavelength(m)\n", + "\n", + "#Result\n", + "print \"wavelength is\",int(round(lamda*10**10)),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 4, Page number 137" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "band gap is 0.8 eV\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=1.55; #peak emission wavelength(micro m) \n", + "\n", + "#Calculation\n", + "Eg=1.24/lamda; #band gap(eV)\n", + "\n", + "#Result\n", + "print \"band gap is\",Eg,\"eV\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 5, Page number 137" + ] + }, + { + "cell_type": "code", + "execution_count": 26, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "relative population of 2 states is 8 *10**29\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "c=3*10**8; #velocity of light(m/sec)\n", + "e=1.6*10**-19; #charge of electron(coulomb)\n", + "lamda=6943*10**-10; #wavelength(m)\n", + "h=6.6*10**-34; #planck's constant(Jsec)\n", + "kb=1.38*10**-23; #boltzmann constant\n", + "T=300; #temperature(K) \n", + "\n", + "#Calculation\n", + "Uv=h*c/(e*lamda); #energy(eV)\n", + "Uvj=Uv*e; #energy(J)\n", + "x=Uvj/(kb*T);\n", + "NbyN0=math.exp(x); #relative population of 2 states\n", + "\n", + "#Result\n", + "print \"relative population of 2 states is\",int(NbyN0*10**-29),\"*10**29\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 6, Page number 138" + ] + }, + { + "cell_type": "code", + "execution_count": 28, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ratio of emission is 3.1 *10**-13\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "c=2.998*10**8; #velocity of light(m/sec)\n", + "lamda=0.5*10**-9; #wavelength(m)\n", + "h=6.626*10**-34; #planck's constant(Jsec)\n", + "Kb=1.381*10**-23; #boltzmann constant\n", + "T=1000; #temperature(K)\n", + "\n", + "#Calculation\n", + "new=c/lamda; #operating frequency(Hz)\n", + "new=new/10**3; #operating frequency(kHz)\n", + "new=round(new/10**14)*10**14;\n", + "x=h*new/(Kb*T);\n", + "B21byA21=1/(math.exp(x)-1); #ratio of emission \n", + "\n", + "#Result\n", + "print \"ratio of emission is\",round(B21byA21*10**13,1),\"*10**-13\"" + ] + } + ], + "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 +} diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter5.ipynb b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter5.ipynb new file mode 100644 index 00000000..e0eddadb --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter5.ipynb @@ -0,0 +1,935 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# 5: Fiber Optics" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 1, Page number 166" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "critical angle is 78.5 degrees\n", + "numerical aperture is 0.3\n", + "acceptance angle is 17.4 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.50; #Core refractive index\n", + "n2=1.47; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "phic=math.asin(n2/n1); #critical angle(radian)\n", + "phic=phic*180/math.pi; #critical angle(degrees)\n", + "NA=math.sqrt(n1**2-n2**2); #numerical aperture\n", + "phimax=math.asin(NA); #acceptance angle(radian)\n", + "phimax=math.asin(NA)*180/math.pi; #acceptance angle(degrees)\n", + "\n", + "#Result\n", + "print \"critical angle is\",round(phic,1),\"degrees\"\n", + "print \"numerical aperture is\",round(NA,1)\n", + "print \"acceptance angle is\",round(phimax,1),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 2, Page number 166" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.46\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.46; #Core refractive index\n", + "delta=0.05; #relative refractive index difference\n", + "\n", + "#Calculation\n", + "NA=n1*math.sqrt(2*delta); #numerical aperture\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,2)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 3, Page number 166" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "acceptance angle for meridional rays is 17.46 degrees\n", + "acceptance angle for skew rays is 25.104 degrees\n", + "answer for acceptance angle for skew rays given in the textbook varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "NA=0.3; #numerical aperture\n", + "gama=45*math.pi/180; #angle(radian)\n", + "\n", + "#Calculation\n", + "thetaa1=math.asin(NA); #acceptance angle for meridional rays(radian)\n", + "thetaa1=thetaa1*180/math.pi; #acceptance angle for meridional rays(degrees)\n", + "thetaa2=math.asin(NA/math.cos(gama))*180/math.pi; #acceptance angle for skew rays(degrees)\n", + "\n", + "#Result\n", + "print \"acceptance angle for meridional rays is\",round(thetaa1,2),\"degrees\"\n", + "print \"acceptance angle for skew rays is\",round(thetaa2,3),\"degrees\"\n", + "print \"answer for acceptance angle for skew rays given in the textbook varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 4, Page number 166" + ] + }, + { + "cell_type": "code", + "execution_count": 15, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.303\n", + "acceptance angle is 17.633 degrees\n", + "answer for acceptance angle given in the textbook varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.53; #Core refractive index\n", + "delta=0.0196; #relative refractive index difference\n", + "\n", + "#Calculation\n", + "NA=n1*math.sqrt(2*delta); #numerical aperture\n", + "thetaa=math.asin(NA)*180/math.pi; #acceptance angle(degrees)\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,3)\n", + "print \"acceptance angle is\",round(thetaa,3),\"degrees\"\n", + "print \"answer for acceptance angle given in the textbook varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 5, Page number 166" + ] + }, + { + "cell_type": "code", + "execution_count": 30, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "critical angle is 83.38 degrees\n", + "fibre length is 430.82 micro m\n", + "answer for fibre length given in the book is wrong\n", + "number of reflections is 2321\n", + "total distance travelled by light is 1.0067 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.5; #Core refractive index\n", + "n2=1.49; #Cladding refractive index\n", + "a=25*10**-6; #radius of core(m)\n", + "L=1; #distance(m)\n", + "\n", + "#Calculation\n", + "phic=round(math.asin(n2/n1)*180/math.pi,2); #critical angle(degrees)\n", + "phicr=phic*math.pi/180; #critical angle(radian) \n", + "l=2*a*math.tan(phicr); #fibre length(m) \n", + "r=1/l; #number of reflections\n", + "od=L/math.sin(phicr); #total distance travelled by light(m)\n", + "\n", + "#Result\n", + "print \"critical angle is\",phic,\"degrees\"\n", + "print \"fibre length is\",round(l*10**6,2),\"micro m\"\n", + "print \"answer for fibre length given in the book is wrong\"\n", + "print \"number of reflections is\",int(r)\n", + "print \"total distance travelled by light is\",round(od,4),\"m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 6, Page number 167" + ] + }, + { + "cell_type": "code", + "execution_count": 34, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "signal attenuation per unit length is 1.7 dB km-1\n", + "overall signal attenuation is 17 dB\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "Pi=100; #input power(micro W)\n", + "Po=2; #output power(micro W)\n", + "L=10; #length(m)\n", + "\n", + "#Calculation\n", + "sa=(10/L)*math.log10(Pi/Po); #signal attenuation per unit length(dB km-1)\n", + "osa=sa*L; #overall signal attenuation(dB) \n", + "\n", + "#Result\n", + "print \"signal attenuation per unit length is\",round(sa,1),\"dB km-1\"\n", + "print \"overall signal attenuation is\",int(round(osa)),\"dB\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 7, Page number 167" + ] + }, + { + "cell_type": "code", + "execution_count": 42, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "total dispersion is 1343.3 ns\n", + "bandwidth length product is 37.22 *10**5 Hz km\n", + "answer for bandwidth length product given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=1.55; #Core refractive index\n", + "L=10; #length(m)\n", + "delta=0.026; #relative refractive index difference\n", + "C=3*10**5;\n", + "\n", + "#Calculation\n", + "deltaT=L*n*delta/C; #total dispersion(s)\n", + "blp=L/(2*deltaT); #bandwidth length product(Hz km)\n", + "\n", + "#Result\n", + "print \"total dispersion is\",round(deltaT*10**9,1),\"ns\"\n", + "print \"bandwidth length product is\",round(blp/10**5,2),\"*10**5 Hz km\"\n", + "print \"answer for bandwidth length product given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 8, Page number 167" + ] + }, + { + "cell_type": "code", + "execution_count": 44, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.391\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.55; #Core refractive index\n", + "n2=1.50; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "NA=math.sqrt(n1**2-n2**2); #numerical aperture\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,3)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 9, Page number 167" + ] + }, + { + "cell_type": "code", + "execution_count": 50, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.4461\n", + "acceptance angle is 26 degrees 29.5 minutes\n", + "answer for acceptance angle in minutes given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.563; #Core refractive index\n", + "n2=1.498; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "NA=math.sqrt(n1**2-n2**2); #numerical aperture\n", + "phimax=math.asin(NA); #acceptance angle(radian)\n", + "phimax=math.asin(NA)*180/math.pi; \n", + "phimaxd=int(phimax); #acceptance angle(degrees)\n", + "phimaxm=60*(phimax-phimaxd); #acceptance angle(minutes)\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,4)\n", + "print \"acceptance angle is\",phimaxd,\"degrees\",round(phimaxm,1),\"minutes\"\n", + "print \"answer for acceptance angle in minutes given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 10, Page number 168" + ] + }, + { + "cell_type": "code", + "execution_count": 54, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Core refractive index is 1.2333\n", + "answer given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "NA=0.39; #numerical aperture\n", + "delta=0.05; #relative refractive index difference\n", + "\n", + "#Calculation\n", + "n1=NA/math.sqrt(2*delta); #Core refractive index\n", + "\n", + "#Result\n", + "print \"Core refractive index is\",round(n1,4)\n", + "print \"answer given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 11, Page number 168" + ] + }, + { + "cell_type": "code", + "execution_count": 56, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fractional index change is 0.0416\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.563; #Core refractive index\n", + "n2=1.498; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "delta=(n1-n2)/n1; #fractional index change\n", + "\n", + "#Result\n", + "print \"fractional index change is\",round(delta,4)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 12, Page number 168" + ] + }, + { + "cell_type": "code", + "execution_count": 59, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.2965\n", + "angle of acceptance is 17 degrees 15 minutes\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.48; #Core refractive index\n", + "n2=1.45; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "NA=math.sqrt(n1**2-n2**2); #numerical aperture\n", + "thetamax=math.asin(NA)*180/math.pi; \n", + "thetamaxd=int(thetamax); #angle of acceptance(degrees)\n", + "thetamaxm=60*(thetamax-thetamaxd); #angle of acceptance(minutes)\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,4)\n", + "print \"angle of acceptance is\",thetamaxd,\"degrees\",int(round(thetamaxm)),\"minutes\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 13, Page number 168" + ] + }, + { + "cell_type": "code", + "execution_count": 61, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "refractive index of core is 1.233\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "NA=0.39; #numerical aperture\n", + "delta=0.05; #fractional index change\n", + "\n", + "#Calculation\n", + "n1=NA/math.sqrt(2*delta); #refractive index of core\n", + "\n", + "#Result\n", + "print \"refractive index of core is\",round(n1,3)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 14, Page number 169" + ] + }, + { + "cell_type": "code", + "execution_count": 63, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fractional index change is 0.04159\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.563; #Core refractive index\n", + "n2=1.498; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "delta=(n1-n2)/n1; #fractional index change\n", + "\n", + "#Result\n", + "print \"fractional index change is\",round(delta,5)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 15, Page number 169" + ] + }, + { + "cell_type": "code", + "execution_count": 66, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.39\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.55; #Core refractive index\n", + "n2=1.50; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "NA=math.sqrt(n1**2-n2**2); #numerical aperture\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,2)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 16, Page number 169" + ] + }, + { + "cell_type": "code", + "execution_count": 69, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.4461\n", + "acceptance angle is 26.49 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.563; #Core refractive index\n", + "n2=1.498; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "NA=math.sqrt(n1**2-n2**2); #numerical aperture\n", + "theta0=math.asin(NA)*180/math.pi; #acceptance angle(degrees)\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,4)\n", + "print \"acceptance angle is\",round(theta0,2),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 17, Page number 170" + ] + }, + { + "cell_type": "code", + "execution_count": 71, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "critical angle is 68.14 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.53; #Core refractive index\n", + "n2=1.42; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "thetac=math.asin(n2/n1)*180/math.pi; #critical angle(degrees)\n", + "\n", + "#Result\n", + "print \"critical angle is\",round(thetac,2),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 18, Page number 170" + ] + }, + { + "cell_type": "code", + "execution_count": 75, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.582\n", + "acceptance angle is 35.6198 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.6; #Core refractive index\n", + "n2=1.4; #Cladding refractive index\n", + "n0=1.33; #water refractive index\n", + "\n", + "#Calculation\n", + "NA=math.sqrt(n1**2-n2**2)/n0; #numerical aperture\n", + "theta0=math.asin(NA)*180/math.pi; #acceptance angle(degrees)\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,3)\n", + "print \"acceptance angle is\",round(theta0,4),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 19, Page number 171" + ] + }, + { + "cell_type": "code", + "execution_count": 76, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fractional index change is 0.133\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.5; #Core refractive index\n", + "n2=1.3; #Cladding refractive index\n", + "\n", + "#Calculation\n", + "delta=(n1-n2)/n1; #fractional index change\n", + "\n", + "#Result\n", + "print \"fractional index change is\",round(delta,3)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 20, Page number 171" + ] + }, + { + "cell_type": "code", + "execution_count": 82, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "angle of reflection is 57.03 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n1=1.55; #Core refractive index\n", + "n2=1.6; #Cladding refractive index\n", + "theta1=60*math.pi/180; #angle of incidence(radian)\n", + "\n", + "#Calculation\n", + "x=n1*math.sin(theta1)/n2; \n", + "theta2=math.asin(x)*180/math.pi; #angle of reflection(degrees)\n", + "\n", + "#Result\n", + "print \"angle of reflection is\",round(theta2,2),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 21, Page number 171" + ] + }, + { + "cell_type": "code", + "execution_count": 84, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Core refractive index is 1.51\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n2=1.3; #Cladding refractive index\n", + "delta=0.14; #fractional index change\n", + "\n", + "#Calculation\n", + "n1=n2/(1-delta); #Core refractive index\n", + "\n", + "#Result\n", + "print \"Core refractive index is\",round(n1,2)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 22, Page number 172" + ] + }, + { + "cell_type": "code", + "execution_count": 87, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "numerical aperture is 0.45088\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta0=26.80*math.pi/180; #acceptance angle(radian)\n", + "\n", + "#Calculation\n", + "NA=math.sin(theta0); #numerical aperture\n", + "\n", + "#Result\n", + "print \"numerical aperture is\",round(NA,5)" + ] + } + ], + "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 +} diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter6.ipynb b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter6.ipynb new file mode 100644 index 00000000..af679239 --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter6.ipynb @@ -0,0 +1,1289 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# 6: Crystallography" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 1, Page number 207" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "density is 5.38 *10**4 kg/m**3\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=8; #number of atoms per unit cell\n", + "a=5.6*10**-10; #lattice constant(m)\n", + "M=710.59; #atomic weight(amu)\n", + "N=6.02*10**26; #avagadro number(kg/mol)\n", + "\n", + "#Calculation\n", + "rho=n*M/(a**3*N); #density(kg/m**3) \n", + "\n", + "#Result\n", + "print \"density is\",round(rho/10**4,2),\"*10**4 kg/m**3\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 2, Page number 207" + ] + }, + { + "cell_type": "code", + "execution_count": 28, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice constant is 0.29 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=2; #number of atoms per unit cell\n", + "M=55.85; #atomic weight(amu)\n", + "N=6.02*10**23; #avagadro number(kg/m**3)\n", + "rho=7860; #density(kg/m**3) \n", + "\n", + "#Calculation \n", + "a=(n*M/(rho*N))**(1/3); #lattice constant(m) \n", + "\n", + "#Result\n", + "print \"lattice constant is\",round(a*10**8,2),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 3, Page number 208" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice constant is 3.52 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=2; #number of atoms per unit cell\n", + "M=6.94; #atomic weight(amu)\n", + "N=6.02*10**26; #avagadro number(kg/mol)\n", + "rho=530; #density(kg/m**3) \n", + "\n", + "#Calculation \n", + "a=(n*M/(rho*N))**(1/3); #lattice constant(m) \n", + "\n", + "#Result\n", + "print \"lattice constant is\",round(a*10**10,2),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 4, Page number 208" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of atoms per unit cell is 2\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "M=55.85; #atomic weight(amu)\n", + "N=6.02*10**26; #avagadro number(kg/mol)\n", + "rho=7870; #density(kg/m**3) \n", + "a=2.9*10**-10; #lattice constant(m) \n", + "\n", + "#Calculation \n", + "n=a**3*rho*N/M; #number of atoms per unit cell\n", + "\n", + "#Result\n", + "print \"number of atoms per unit cell is\",int(n)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 5, Page number 208" + ] + }, + { + "cell_type": "code", + "execution_count": 15, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "density is 53771 kg/m**3\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=8; #number of atoms per unit cell\n", + "a=5.6*10**-10; #lattice constant(m)\n", + "M=710.59; #atomic weight(amu)\n", + "N=6.02*10**26; #avagadro number(kg/mol)\n", + "\n", + "#Calculation\n", + "rho=n*M/(a**3*N); #density(kg/m**3) \n", + "\n", + "#Result\n", + "print \"density is\",int(rho),\"kg/m**3\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 6, Page number 209" + ] + }, + { + "cell_type": "code", + "execution_count": 25, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice constant is 0.2869 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=2; #number of atoms per unit cell\n", + "M=55.85; #atomic weight(amu)\n", + "N=6.02*10**23; #avagadro number(kg/m**3)\n", + "rho=7860; #density(kg/m**3) \n", + "\n", + "#Calculation \n", + "a=(n*M/(rho*N))**(1/3); #lattice constant(m) \n", + "\n", + "#Result\n", + "print \"lattice constant is\",round(a*10**8,4),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 7, Page number 209" + ] + }, + { + "cell_type": "code", + "execution_count": 31, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice constant is 3.517 angstrom\n", + "answer given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=2; #number of atoms per unit cell\n", + "M=6.94; #atomic weight(amu)\n", + "N=6.02*10**26; #avagadro number(kg/mol)\n", + "rho=530; #density(kg/m**3) \n", + "\n", + "#Calculation \n", + "a=(n*M/(rho*N))**(1/3); #lattice constant(m) \n", + "\n", + "#Result\n", + "print \"lattice constant is\",round(a*10**10,3),\"angstrom\"\n", + "print \"answer given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 8, Page number 209" + ] + }, + { + "cell_type": "code", + "execution_count": 32, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of atoms per unit cell is 2\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "M=55.85; #atomic weight(amu)\n", + "N=6.02*10**26; #avagadro number(kg/mol)\n", + "rho=7870; #density(kg/m**3) \n", + "a=2.9*10**-10; #lattice constant(m) \n", + "\n", + "#Calculation \n", + "n=a**3*rho*N/M; #number of atoms per unit cell\n", + "\n", + "#Result\n", + "print \"number of atoms per unit cell is\",int(n)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 9, Page number 210" + ] + }, + { + "cell_type": "code", + "execution_count": 41, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "density is 8933.25 kg/m**3\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "r=0.1278*10**-9; #atomic radius(m)\n", + "n=4; #number of atoms per unit cell\n", + "M=63.5; #atomic weight(amu)\n", + "N=6.02*10**26; #avagadro number(kg/mol)\n", + "\n", + "#Calculation\n", + "a=math.sqrt(8)*r; #lattice constant(m)\n", + "rho=n*M/(a**3*N); #density(kg/m**3) \n", + "\n", + "#Result\n", + "print \"density is\",round(rho,2),\"kg/m**3\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 10, Page number 210" + ] + }, + { + "cell_type": "code", + "execution_count": 45, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "percent volume change is 0.5 %\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "r1=1.258*10**-10; #radius(m)\n", + "r2=1.292*10**-10; #radius(m)\n", + "n1=2; #number of atoms per unit cell\n", + "n2=4; #number of atoms per unit cell\n", + "\n", + "#Calculation\n", + "a_bcc=4*r1/math.sqrt(3);\n", + "v=a_bcc**3;\n", + "V1=v/n1;\n", + "a_fcc=2*math.sqrt(2)*r2;\n", + "V2=a_fcc**3/n2;\n", + "V=(V1-V2)*100/V2; #percent volume change is\",V,\"%\"\n", + "\n", + "#Result\n", + "print \"percent volume change is\",round(V,1),\"%\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 12, Page number 211" + ] + }, + { + "cell_type": "code", + "execution_count": 49, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of atoms per unit volume is 4.49 *10**22 atoms/cm**3\n", + "distance between adjacent atoms is 2.81 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "w=23+35.5; #molecular weight of NaCl(gm/mole)\n", + "N=6.023*10**23; #avagadro number(gm/mol)\n", + "rho=2.18; #density of NaCl(gm/cm**3)\n", + "n=2; #number of atoms\n", + "\n", + "#Calculation\n", + "m=w/N; #mass of NaCl(gm)\n", + "nm=rho/m; #number of molecules(mole/cm**3)\n", + "N_NaCl=n*nm; #number of atoms per unit volume(atoms/cm**3) \n", + "a=(1/N_NaCl)**(1/3); #distance between adjacent atoms(cm)\n", + "\n", + "\n", + "#Result\n", + "print \"number of atoms per unit volume is\",round(N_NaCl/10**22,2),\"*10**22 atoms/cm**3\"\n", + "print \"distance between adjacent atoms is\",round(a*10**8,2),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 13, Page number 212" + ] + }, + { + "cell_type": "code", + "execution_count": 51, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "glancing angle is 21.01 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=0.071*10**-9; #wavelength(m)\n", + "h=1;\n", + "k=1;\n", + "l=0; #miller indices\n", + "a=0.28*10**-9; #lattice constant(m)\n", + "n=2; #order\n", + "\n", + "#Calculation\n", + "d=a/math.sqrt(h**2+k**2+l**2); \n", + "theta=math.asin(n*lamda/(2*d))*180/math.pi; #glancing angle(degrees)\n", + "\n", + "#Result\n", + "print \"glancing angle is\",round(theta,2),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 14, Page number 213" + ] + }, + { + "cell_type": "code", + "execution_count": 55, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "space of reflecting plane is 2.3336 angstrom\n", + "volume of unit cell is 1.27 *10**-29 m**3\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=3*10**-10; #wavelength(m)\n", + "h=1;\n", + "k=0;\n", + "l=0; #miller indices\n", + "theta=40*math.pi/180; #glancing angle(radian)\n", + "n=1; #order\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); #space of reflecting plane(m)\n", + "a=d*math.sqrt(h**2+k**2+l**2); \n", + "V=a**3; #volume of unit cell(m**3)\n", + "\n", + "#Result\n", + "print \"space of reflecting plane is\",round(d*10**10,4),\"angstrom\"\n", + "print \"volume of unit cell is\",round(V*10**29,2),\"*10**-29 m**3\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 15, Page number 213" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "space of reflecting plane is 0.42 angstrom\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=0.82; #wavelength(m)\n", + "theta=75.86*math.pi/180; #glancing angle(radian)\n", + "n=1; #order\n", + "a=3; #lattice constant(angstrom)\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); #space of reflecting plane(angstrom)\n", + "#here the value of d comes to 0.422 angstrom which is not equal to the value of a. hence the problem cannot be solved further \n", + "\n", + "#Result\n", + "print \"space of reflecting plane is\",round(d,2),\"angstrom\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 16, Page number 214" + ] + }, + { + "cell_type": "code", + "execution_count": 70, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of X-ray beam is 3 angstrom\n", + "energy of X-ray beam is 4.14 *10**5 eV\n", + "answer for energy given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "a=5.63*10**-10; #lattice constant(m)\n", + "h=1;\n", + "k=1;\n", + "l=1; #miller indices\n", + "theta=27.5*math.pi/180; #glancing angle(radian)\n", + "n=1; #order\n", + "h=6.625*10**-34; #planck's constant\n", + "c=3*10**10; #velocity of light(m/sec)\n", + "e=1.6*10**-19; #charge of electron(c)\n", + "\n", + "#Calculation\n", + "d111=a/math.sqrt(h**2+k**2+l**2); \n", + "lamda=2*d111*math.sin(theta)/n; #wavelength of X-ray beam(m) \n", + "lamda=int(lamda*10**10); #wavelength of X-ray beam(angstrom) \n", + "E=h*c/(lamda*10**-10*e); #energy of X-ray beam(eV) \n", + "\n", + "#Result\n", + "print \"wavelength of X-ray beam is\",lamda,\"angstrom\"\n", + "print \"energy of X-ray beam is\",round(E/10**5,2),\"*10**5 eV\"\n", + "print \"answer for energy given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 17, Page number 215" + ] + }, + { + "cell_type": "code", + "execution_count": 73, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice constant is 3.7935 angstrom\n", + "answer given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=2;\n", + "k=0;\n", + "l=2; #miller indices\n", + "theta=34*math.pi/180; #glancing angle(radian)\n", + "n=1; #order\n", + "lamda=1.5*10**-10; #wavelength of X-ray beam(m) \n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); \n", + "a=d*math.sqrt(h**2+k**2+l**2); #lattice constant(m)\n", + "\n", + "#Result\n", + "print \"lattice constant is\",round(a*10**10,4),\"angstrom\"\n", + "print \"answer given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 19, Page number 216" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ratio of d100:d110:d111 is math.sqrt( 6 ) : math.sqrt( 3 ) : math.sqrt( 2 )\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h1=1;\n", + "k1=0;\n", + "l1=0; #miller indices\n", + "h2=1;\n", + "k2=1;\n", + "l2=0; #miller indices\n", + "h3=1;\n", + "k3=1;\n", + "l3=1; #miller indices\n", + "a=1; #assume\n", + "\n", + "#Calculation\n", + "Dr1=(h1**2+k1**2+l1**2);\n", + "Dr2=(h2**2+k2**2+l2**2);\n", + "Dr3=(h3**2+k3**2+l3**2);\n", + "d100=a/math.sqrt(Dr1);\n", + "d110=a/math.sqrt(Dr2);\n", + "d111=a/math.sqrt(Dr3);\n", + "def lcm(x, y): \n", + " if x > y: \n", + " z = x \n", + " else: \n", + " z = y \n", + " \n", + " while(True): \n", + " if((z % x == 0) and (z % y == 0)): \n", + " lcm = z \n", + " break \n", + " z += 1 \n", + " \n", + " return lcm\n", + "lcm=lcm(Dr2,Dr3);\n", + "r=math.sqrt(lcm);\n", + "r_d100=d100*r;\n", + "r_d110=d110*r;\n", + "r_d111=d111*r;\n", + "\n", + "#Result\n", + "print \"ratio of d100:d110:d111 is math.sqrt(\",int(round(r_d100**2)),\") : math.sqrt(\",int(round(r_d110**2)),\") : math.sqrt(\",int(round(r_d111**2)),\")\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 20, Page number 217" + ] + }, + { + "cell_type": "code", + "execution_count": 76, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "interplanar spacing is 159.1 nm\n", + "answer given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=2;\n", + "k=2;\n", + "l=0; #miller indices\n", + "a=450; #length(nm) \n", + "\n", + "#Calculation\n", + "d220=a/math.sqrt(h**2+k**2+l**2); #interplanar spacing(nm)\n", + "\n", + "#Result\n", + "print \"interplanar spacing is\",round(d220,1),\"nm\"\n", + "print \"answer given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 21, Page number 217" + ] + }, + { + "cell_type": "code", + "execution_count": 79, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "interplanar spacing is 2.09 *10**-10 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=1; #miller indices\n", + "r=1.278*10**-10; #radius(m)\n", + "\n", + "#Calculation\n", + "a=4*r/math.sqrt(2); \n", + "d111=a/math.sqrt(h**2+k**2+l**2); #interplanar spacing(m)\n", + "\n", + "#Result\n", + "print \"interplanar spacing is\",round(d111*10**10,2),\"*10**-10 m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 22, Page number 217" + ] + }, + { + "cell_type": "code", + "execution_count": 86, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of X-rays is 1.549 angstrom\n", + "answer in the book varies due to rounding off errors\n", + "energy of X-rays is 8 *10**3 eV\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=1; #miller indices\n", + "n=4;\n", + "A=107.87; #atomic weight(amu)\n", + "N=10500*6.052*10**26; #density(kg/m**3)\n", + "theta=(19+(12/60))*math.pi/180; #angle(radian)\n", + "r=1.278*10**-10; #radius(m)\n", + "hp=6.625*10**-34; #plancks constant(Js)\n", + "c=3*10**8; #velocity of light(m/sec)\n", + "e=1.6*10**-19; #charge of electron(coulomb)\n", + "\n", + "#Calculation\n", + "a=(n*A/N)**(1/3); #lattice constant(m)\n", + "d=a/math.sqrt(h**2+k**2+l**2); #interplanar spacing(m)\n", + "lamda=2*d*math.sin(theta); #wavelength of X-rays(m)\n", + "E=hp*c/(e*lamda); #energy of X-rays(eV) \n", + "\n", + "#Result\n", + "print \"wavelength of X-rays is\",round(lamda*10**10,3),\"angstrom\"\n", + "print \"answer in the book varies due to rounding off errors\"\n", + "print \"energy of X-rays is\",int(E/10**3),\"*10**3 eV\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 23, Page number 217" + ] + }, + { + "cell_type": "code", + "execution_count": 91, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "glancing angle is 21 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=0; #miller indices\n", + "d100=0.28; #lattice constant(nm)\n", + "n=2;\n", + "lamda=0.071; #wavelength(nm)\n", + "\n", + "#Calculation\n", + "d110=d100/math.sqrt(h**2+k**2+l**2); #interplanar spacing(m)\n", + "theta=math.asin(n*lamda/(2*d110))*180/math.pi; #glancing angle(degrees)\n", + "\n", + "#Result\n", + "print \"glancing angle is\",int(theta),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 24, Page number 218" + ] + }, + { + "cell_type": "code", + "execution_count": 95, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "distance between the planes is 0.27 nm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=0; #miller indices\n", + "a=0.38; #lattice constant(nm)\n", + "\n", + "#Calculation\n", + "d=a/math.sqrt(h**2+k**2+l**2); #distance between the planes(nm)\n", + "\n", + "#Result\n", + "print \"distance between the planes is\",round(d,2),\"nm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 26, Page number 219" + ] + }, + { + "cell_type": "code", + "execution_count": 99, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "intercept along y axis is 0.123 nm\n", + "intercept along y axis is 0.394 nm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=2;\n", + "k=3;\n", + "l=1; #miller indices\n", + "a=0.121; \n", + "b=0.184;\n", + "c=0.197; #parameters(nm)\n", + "\n", + "#Calculation\n", + "OB=2*b/3; #intercept along y axis(nm)\n", + "OC=2*c; #intercept along z axis(nm) \n", + "\n", + "#Result\n", + "print \"intercept along y axis is\",round(OB,3),\"nm\"\n", + "print \"intercept along y axis is\",OC,\"nm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 27, Page number 219" + ] + }, + { + "cell_type": "code", + "execution_count": 20, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "interplanar distance between (123) planes is 0.213 nm\n", + "interplanar distance between (246) planes is 0.1066 nm\n", + "answers given in the book are wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h1=1;\n", + "k1=2;\n", + "l1=3; #miller indices\n", + "h2=2;\n", + "k2=4;\n", + "l2=6; #miller indices\n", + "a=0.82; \n", + "b=0.94;\n", + "c=0.75; #parameters(nm)\n", + "\n", + "#Calculation\n", + "d123=(((h1/a)**2)+((k1/b)**2)+((l1/c)**2))**(-1/2); #interplanar distance between (123) planes\n", + "d246=d123/2; #interplanar distance between (246) planes\n", + "\n", + "#Result\n", + "print \"interplanar distance between (123) planes is\",round(d123,3),\"nm\"\n", + "print \"interplanar distance between (246) planes is\",round(d246,4),\"nm\"\n", + "print \"answers given in the book are wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 28, Page number 219" + ] + }, + { + "cell_type": "code", + "execution_count": 109, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of Xrays is 0.159 nm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=1; #miller indices\n", + "a=0.2; #lattice parameter(nm)\n", + "theta=(87/2)*math.pi/180; #angle(radian)\n", + "\n", + "#Calculation\n", + "d=a/math.sqrt(h**2+k**2+l**2);\n", + "lamda=2*d*math.sin(theta); #wavelength of Xrays(nm)\n", + "\n", + "#Result\n", + "print \"wavelength of Xrays is\",round(lamda,3),\"nm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 29, Page number 219" + ] + }, + { + "cell_type": "code", + "execution_count": 120, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "effective temperature of neutrons is 169 K\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=1; #miller indices\n", + "a=0.352; #lattice parameter(nm)\n", + "theta=(28+(30/60))*math.pi/180; #angle(radian)\n", + "hp=6.626*10**-34; #plancks constant(Js)\n", + "m=1.67*10**-27; #mass of proton(kg)\n", + "kB=1.38*10**-23; #boltzmann constant\n", + "\n", + "#Calculation\n", + "d=a/math.sqrt(h**2+k**2+l**2);\n", + "lamda=2*d*math.sin(theta); #wavelength(nm)\n", + "T=(hp**2)/(3*m*kB*(lamda*10**-9)**2); #effective temperature of neutrons(K)\n", + "\n", + "#Result\n", + "print \"effective temperature of neutrons is\",int(round(T)),\"K\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 30, Page number 220" + ] + }, + { + "cell_type": "code", + "execution_count": 125, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice parameter for regular crystal is 0.3609 nm\n", + "lattice parameter for sample A is 0.3673 nm\n", + "lattice parameter for sample B is 0.361 nm\n", + "lattice parameter of sample A is 1.75% greater than that of pure copper\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=1; #miller indices\n", + "lamda=0.152; #wavelength(nm)\n", + "D=0.2552; #diameter(nm)\n", + "theta1=21*math.pi/180; #angle(radian)\n", + "theta2=(21+(23/60))*math.pi/180; #angle(radian)\n", + "\n", + "#Calculation\n", + "a=D*math.sqrt(2); #lattice parameter for regular crystal(nm)\n", + "d111_1=lamda/(2*math.sin(theta1));\n", + "alpha1=d111_1*math.sqrt(h**2+k**2+l**2); #lattice parameter for sample A(nm)\n", + "d111_2=lamda/(2*math.sin(theta2));\n", + "alpha2=d111_2*math.sqrt(h**2+k**2+l**2); #lattice parameter for sample B(nm)\n", + "\n", + "#Result\n", + "print \"lattice parameter for regular crystal is\",round(a,4),\"nm\"\n", + "print \"lattice parameter for sample A is\",round(alpha1,4),\"nm\"\n", + "print \"lattice parameter for sample B is\",round(alpha2,3),\"nm\"\n", + "print \"lattice parameter of sample A is 1.75% greater than that of pure copper\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 31, Page number 220" + ] + }, + { + "cell_type": "code", + "execution_count": 131, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "the value of h**2+k**2+l**2 is 11.69\n", + "answer given in the book is wrong\n", + "highest possible values of (hkl) are (222)\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=1; #miller indices\n", + "lamda=0.154; #wavelength of X-rays(nm)\n", + "D=0.228; #diameter(nm)\n", + "\n", + "#Calculation\n", + "x=lamda/2;\n", + "y=2*D/(x*math.sqrt(h**2+k**2+l**2));\n", + "z=y**2;\n", + "\n", + "#Result\n", + "print \"the value of h**2+k**2+l**2 is\",round(z,2)\n", + "print \"answer given in the book is wrong\"\n", + "print \"highest possible values of (hkl) are (222)\"" + ] + } + ], + "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 +} diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter7.ipynb b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter7.ipynb new file mode 100644 index 00000000..7d535f3b --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/Chapter7.ipynb @@ -0,0 +1,824 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# 7: X-ray Diffraction and Defects in Crystals" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 1, Page number 239" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "cube edge of unit cell is 4.1 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "n=1; #order\n", + "theta=32*math.pi/180; #glancing angle(radian)\n", + "lamda=1.54; #wavelength(angstrom)\n", + "h=2;\n", + "k=2;\n", + "l=0;\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); #lattice parameter(angstrom)\n", + "a=d*math.sqrt(h**2+k**2+l**2); #cube edge of unit cell(angstrom)\n", + "\n", + "#Result\n", + "print \"cube edge of unit cell is\",round(a,1),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 2, Page number 240" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "interplanar spacing at 1st angle is 2.582 angstrom\n", + "interplanar spacing at 2nd angle is 1.824 angstrom\n", + "interplanar spacing at 3rd angle is 1.289 angstrom\n", + "answers given in the book are wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=0.58; #wavelength(angstrom)\n", + "theta1=6.45*math.pi/180; #glancing angle(radian)\n", + "theta2=9.15*math.pi/180; #glancing angle(radian)\n", + "theta3=13*math.pi/180; #glancing angle(radian)\n", + "n=1; #order\n", + "\n", + "#Calculation\n", + "d1=lamda/(2*math.sin(theta1)); #interplanar spacing at 1st angle(angstrom)\n", + "d2=lamda/(2*math.sin(theta2)); #interplanar spacing at 2nd angle(angstrom)\n", + "d3=lamda/(2*math.sin(theta3)); #interplanar spacing at 3rd angle(angstrom)\n", + "\n", + "#Result\n", + "print \"interplanar spacing at 1st angle is\",round(d1,3),\"angstrom\"\n", + "print \"interplanar spacing at 2nd angle is\",round(d2,3),\"angstrom\"\n", + "print \"interplanar spacing at 3rd angle is\",round(d3,3),\"angstrom\"\n", + "print \"answers given in the book are wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 3, Page number 240" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "order of diffraction is 1\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=1.181; #lattice spacing(angstrom)\n", + "theta=90*math.pi/180; #glancing angle(radian)\n", + "lamda=1.540; #wavelength of X-rays(angstrom)\n", + "\n", + "#Calculation\n", + "n=2*d*math.sin(theta)/lamda; #order of diffraction \n", + "\n", + "#Result\n", + "print \"order of diffraction is\",int(n)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 4, Page number 240" + ] + }, + { + "cell_type": "code", + "execution_count": 24, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice parameter is 3.514 angstrom\n", + "answer given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta=9.5*math.pi/180; #glancing angle(radian)\n", + "lamda=0.58; #wavelength of X-rays(angstrom)\n", + "n=1; #order\n", + "h=2;\n", + "k=0;\n", + "l=0;\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); \n", + "a=d*math.sqrt(h**2+k**2+l**2); #lattice parameter(angstrom)\n", + "\n", + "#Result\n", + "print \"lattice parameter is\",round(a,3),\"angstrom\"\n", + "print \"answer given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 5, Page number 241" + ] + }, + { + "cell_type": "code", + "execution_count": 27, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "glancing angle is 26 degrees 35 minutes\n", + "answer for glancing angle in minutes given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta1=(8+(35/60))*math.pi/180; #glancing angle(radian)\n", + "lamda=0.842; #wavelength of X-rays(angstrom)\n", + "n1=1; #order\n", + "n2=3; #order \n", + "\n", + "#Calculation\n", + "x=n2*lamda*math.sin(theta1)/(n1*lamda); \n", + "theta2=math.asin(x)*180/math.pi; #glancing angle\n", + "theta2d=int(theta2); #glancing angle(degrees)\n", + "theta2m=(theta2-theta2d)*60; #glancing angle(minutes)\n", + "\n", + "#Result\n", + "print \"glancing angle is\",theta2d,\"degrees\",int(theta2m),\"minutes\"\n", + "print \"answer for glancing angle in minutes given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 6, Page number 241" + ] + }, + { + "cell_type": "code", + "execution_count": 31, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "interplanar spacing is 2.22 angstrom\n", + "answer for interplanar spacing given in the book is wrong\n", + "value of h**2+k**2+l**2 is 2 . hence the miller indices could be (110) (011) or (101)\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "a=3.16; #lattice parameter(angstrom)\n", + "theta=20.3*math.pi/180; #glancing angle(radian)\n", + "lamda=1.54; #wavelength of X-rays(angstrom)\n", + "n=1; #order\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); #interplanar spacing(angstrom)\n", + "x=(a/d)**2;\n", + "\n", + "#Result\n", + "print \"interplanar spacing is\",round(d,2),\"angstrom\"\n", + "print \"answer for interplanar spacing given in the book is wrong\"\n", + "print \"value of h**2+k**2+l**2 is\",int(x),\". hence the miller indices could be (110) (011) or (101)\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 7, Page number 242" + ] + }, + { + "cell_type": "code", + "execution_count": 35, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength is 0.084 nm\n", + "maximum order of diffraction is 6\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=0.282; #lattice spacing(nm)\n", + "theta=(8+(35/60))*math.pi/180; #glancing angle(radian)\n", + "n=1; #order\n", + "\n", + "#Calculation\n", + "lamda=2*d*math.sin(theta)/n; #wavelength(nm)\n", + "N=2*d/lamda; #maximum order of diffraction\n", + "\n", + "#Result\n", + "print \"wavelength is\",round(lamda,3),\"nm\"\n", + "print \"maximum order of diffraction is\",int(N)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 8, Page number 243" + ] + }, + { + "cell_type": "code", + "execution_count": 38, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "maximum order of diffraction is 2\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=1.5; #wavelength(AU)\n", + "d=1.6; #lattice spacing(AU)\n", + "\n", + "#Calculation\n", + "n=2*d/lamda; #maximum order of diffraction\n", + "\n", + "#Result\n", + "print \"maximum order of diffraction is\",int(n)" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 9, Page number 243" + ] + }, + { + "cell_type": "code", + "execution_count": 41, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "interatomic spacing is 2.67 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta=30*math.pi/180; #glancing angle(radian)\n", + "h=1;\n", + "k=1;\n", + "l=1;\n", + "lamda=1.5418; #wavelength(angstrom)\n", + "n=1; #order\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); #interplanar spacing(angstrom)\n", + "a=d*math.sqrt((h**2)+(k**2)+(l**2)); #interatomic spacing(angstrom)\n", + "\n", + "#Result\n", + "print \"interatomic spacing is\",round(a,2),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 10, Page number 243" + ] + }, + { + "cell_type": "code", + "execution_count": 46, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "glancing angle is 20.7 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=0;\n", + "lamda=0.065; #wavelength(nm)\n", + "n=2; #order\n", + "a=0.26; #axial length(nm)\n", + "\n", + "#Calculation\n", + "x=n*lamda*math.sqrt(h**2+k**2+l**2)/(2*a);\n", + "theta=math.asin(x)*180/math.pi; #glancing angle(degrees)\n", + "\n", + "#Result\n", + "print \"glancing angle is\",round(theta,1),\"degrees\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 11, Page number 244" + ] + }, + { + "cell_type": "code", + "execution_count": 49, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "cube edge of unit cell is 4.055 angstrom\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "h=1;\n", + "k=1;\n", + "l=1;\n", + "lamda=1.54; #wavelength(angstrom)\n", + "n=1; #order\n", + "theta=19.2*math.pi/180; #glancing angle(radian)\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); \n", + "a=d*math.sqrt(h**2+k**2+l**2); #cube edge of unit cell(angstrom)\n", + "\n", + "#Result\n", + "print \"cube edge of unit cell is\",round(a,3),\"angstrom\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 12, Page number 244" + ] + }, + { + "cell_type": "code", + "execution_count": 52, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "cube edge of unit cell is 4.055 *10**-10 m\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=1.54*10**-10; #wavelength(m)\n", + "n=1; #order\n", + "theta=19.2*math.pi/180; #glancing angle(radian)\n", + "h=1;\n", + "k=1;\n", + "l=1;\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); \n", + "a=d*math.sqrt(h**2+k**2+l**2); #cube edge of unit cell(m)\n", + "\n", + "#Result\n", + "print \"cube edge of unit cell is\",round(a*10**10,3),\"*10**-10 m\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 13, Page number 244" + ] + }, + { + "cell_type": "code", + "execution_count": 54, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "interplanar spacing is 0.26 nm\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=0.12; #wavelength(nm)\n", + "n=2; #order\n", + "theta=28*math.pi/180; #glancing angle(radian)\n", + "\n", + "#Calculation\n", + "d=n*lamda/(2*math.sin(theta)); #interplanar spacing(nm)\n", + "\n", + "#Result\n", + "print \"interplanar spacing is\",round(d,2),\"nm\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 14, Page number 245" + ] + }, + { + "cell_type": "code", + "execution_count": 59, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength is 131.3 pm\n", + "interplanar spacing is 168 pm\n", + "answer for wavelength given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "lamda=97; #wavelength(pm)\n", + "n1=1; #order\n", + "n2=3; #order \n", + "theta1=23*math.pi/180; #glancing angle(radian)\n", + "theta2=60*math.pi/180; #glancing angle(radian)\n", + "\n", + "#Calculation\n", + "lamda1=n2*lamda*math.sin(theta1)/(n1*math.sin(theta2)); #wavelength(pm)\n", + "d=n2*lamda/(2*math.sin(theta2)) #interplanar spacing(pm)\n", + "\n", + "#Result\n", + "print \"wavelength is\",round(lamda1,1),\"pm\"\n", + "print \"interplanar spacing is\",int(d),\"pm\"\n", + "print \"answer for wavelength given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 15, Page number 245" + ] + }, + { + "cell_type": "code", + "execution_count": 64, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength for n=3 is 130 pm and for n=4 is 97.23 pm\n", + "answer for wavelength for n=4 given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta=45*math.pi/180; #glancing angle(radian)\n", + "d=275; #interplanar spacing(pm)\n", + "n1=3;\n", + "n2=4;\n", + "\n", + "#Calculation\n", + "lamda=2*d*math.sin(theta); #wavelength(pm)\n", + "lamda1=lamda/n1; #wavelength for n=3\n", + "lamda2=lamda/n2; #wavelength for n=4\n", + "\n", + "#Result\n", + "print \"wavelength for n=3 is\",int(round(lamda1)),\"pm and for n=4 is\",round(lamda2,2),\"pm\"\n", + "print \"answer for wavelength for n=4 given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 17, Page number 246" + ] + }, + { + "cell_type": "code", + "execution_count": 72, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "lattice parameter in case of bcc are 0.242 nm and 0.296 nm which are not the same. hence the metal is not bcc\n", + "lattice parameter in case of fcc are 0.296 nm and 0.296 nm which are the same. hence the metal is fcc\n", + "atomic diameter is 0.20943 nm\n", + "answer for atomic diameter given in the book varies due to rounding off errors\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "theta1=(30+(0/60))*math.pi/180; #glancing angle(radian)\n", + "theta2=(35+(17/60))*math.pi/180; #glancing angle(radian)\n", + "lamda=0.171; #wavelength(nm)\n", + "h1=1;\n", + "k1=1;\n", + "l1=0;\n", + "h2=2;\n", + "k2=0;\n", + "l2=0;\n", + "h3=1;\n", + "k3=1;\n", + "l3=1;\n", + "\n", + "#Calculation\n", + "d100=lamda/(2*math.sin(theta1)); #wavelength(nm)\n", + "d200=lamda/(2*math.sin(theta2)); #wavelength(nm)\n", + "a1=d100*math.sqrt(h1**2+k1**2+l1**2);\n", + "a2=d200*math.sqrt(h2**2+k2**2+l2**2); #lattice parameter in case of bcc\n", + "a3=d100*math.sqrt(h3**2+k3**2+l3**2);\n", + "a4=d200*math.sqrt(h2**2+k2**2+l2**2); #lattice parameter in case of bcc\n", + "d=a3/math.sqrt(2); #atomic diameter(nm) \n", + "\n", + "#Result\n", + "print \"lattice parameter in case of bcc are\",round(a1,3),\"nm and\",round(a2,3),\"nm which are not the same. hence the metal is not bcc\"\n", + "print \"lattice parameter in case of fcc are\",round(a3,3),\"nm and\",round(a4,3),\"nm which are the same. hence the metal is fcc\"\n", + "print \"atomic diameter is\",round(d,5),\"nm\"\n", + "print \"answer for atomic diameter given in the book varies due to rounding off errors\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 18, Page number 246" + ] + }, + { + "cell_type": "code", + "execution_count": 79, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength of x-rays is 0.842 angstrom\n", + "maximum order of diffraction is 7\n", + "answer for wavelength of x-rays given in the book is wrong\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=0.282*10**-9; #lattice spacing(m)\n", + "theta=(8+(35/60))*math.pi/180; #glancing angle(radian)\n", + "maxtheta=90*math.pi/180;\n", + "n=1; #order\n", + "\n", + "#Calculation\n", + "lamda=2*d*math.sin(theta)/n; #wavelength of x-rays(m)\n", + "N=2*d*math.sin(maxtheta)/lamda; #maximum order of diffraction\n", + "\n", + "#Result\n", + "print \"wavelength of x-rays is\",round(lamda*10**10,3),\"angstrom\"\n", + "print \"maximum order of diffraction is\",int(round(N))\n", + "print \"answer for wavelength of x-rays given in the book is wrong\"" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example number 19, Page number 247" + ] + }, + { + "cell_type": "code", + "execution_count": 83, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "glancing angle is 22.942 degrees\n" + ] + } + ], + "source": [ + "#importing modules\n", + "import math\n", + "from __future__ import division\n", + "\n", + "#Variable declaration\n", + "d=3.04*10**-10; #lattice spacing(m)\n", + "lamda=0.79*10**-10; #wavelength(m) \n", + "n=3; #order\n", + "\n", + "#Calculation\n", + "x=n*lamda/(2*d);\n", + "theta=math.asin(x)*180/math.pi; #glancing angle(degrees)\n", + "\n", + "#Result\n", + "print \"glancing angle is\",round(theta,3),\"degrees\"" + ] + } + ], + "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 +} diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/11.png b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/11.png Binary files differnew file mode 100644 index 00000000..ec926fde --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/11.png diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/22.png b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/22.png Binary files differnew file mode 100644 index 00000000..d55e6f18 --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/22.png diff --git a/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/33.png b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/33.png Binary files differnew file mode 100644 index 00000000..0117909f --- /dev/null +++ b/Modern_Engineering_Physics_by_K._Vijaya_Kumar,_S._Chandralingam/screenshots/33.png diff --git a/Modern_physics_for_engineers_by_S.P.Taneja/chapter9.ipynb b/Modern_physics_for_engineers_by_S.P.Taneja/chapter9.ipynb index 771c3614..eda0a122 100644 --- a/Modern_physics_for_engineers_by_S.P.Taneja/chapter9.ipynb +++ b/Modern_physics_for_engineers_by_S.P.Taneja/chapter9.ipynb @@ -1,7 +1,7 @@ {
"metadata": {
"name": "",
- "signature": "sha256:eab5e28552df3435319f7a568a922a4980f0e1d7df3bbe3b5b33bae52cc8991b"
+ "signature": "sha256:a7b78cc7b7d590f810fd93c40136d5a33fbff1ab60f975547f5786bad9064d2a"
},
"nbformat": 3,
"nbformat_minor": 0,
@@ -297,12 +297,15 @@ "v=0.5 #c\n",
"m0=6.1*10**-31 #Kg\n",
"c=3.0*10**8\n",
+ "e=1.602*10**-19\n",
"\n",
"#Calculation\n",
- "r=(m0*v)/(B*e*math.sqrt(1-(v/c)**2))\n",
+ "import math\n",
+ "A=1-(v**2/c**2)\n",
+ "r=(m0*v*c)/(B*math.sqrt(A))\n",
"\n",
"#Result\n",
- "print round(r*10**32,1),\"*10**-4 m\""
+ "print\"Radius of curvature of path is\", r*10**23,\"*10**-4 m\""
],
"language": "python",
"metadata": {},
@@ -311,11 +314,11 @@ "output_type": "stream",
"stream": "stdout",
"text": [
- "7.5 *10**-4 m\n"
+ "Radius of curvature of path is 6.1 *10**-4 m\n"
]
}
],
- "prompt_number": 57
+ "prompt_number": 22
},
{
"cell_type": "heading",
diff --git a/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image2.png b/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image2.png Binary files differindex ea66e0b3..76f388a1 100644 --- a/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image2.png +++ b/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image2.png diff --git a/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image3.png b/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image3.png Binary files differindex 70e1b1f6..8b14a718 100644 --- a/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image3.png +++ b/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image3.png diff --git a/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image_1.png b/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image_1.png Binary files differnew file mode 100644 index 00000000..a4956fb6 --- /dev/null +++ b/Modern_physics_for_engineers_by_S.P.Taneja/screenshots/image_1.png diff --git a/Physical_Chemistry_by_D._Farrington/Chapter11_KineticTheory.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter11_KineticTheory.ipynb new file mode 100644 index 00000000..f015b977 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter11_KineticTheory.ipynb @@ -0,0 +1,242 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter11 KineticTheory" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.1, Page no.45" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "most probabale velocity= 150.02 cm secˆ−1\n", + "arthmetic mean velocity= 67.26 cm secˆ−1\n", + "root mean square velocity= 183.74 cm sec ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "from math import sqrt\n", + "from math import pi\n", + "#initialisation of variables\n", + "R=8.31*10 # ergs moleˆ−1 Kˆ−1 \n", + "M=2.016 #gms \n", + "T=0 #C \n", + "#CALCULATIONS \n", + "vp=sqrt(2*R*(273+T)/M)\n", + "v=sqrt(8*R*(273+T))/(pi*M)\n", + "vr=sqrt(3*R*(273+T)/M) \n", + "#RESULTS\n", + "vp=round(vp,2)\n", + "v=round(v,2)\n", + "vr=round(vr,2)\n", + "print 'most probabale velocity=',vp,'cm secˆ−1'\n", + "print 'arthmetic mean velocity=',v,'cm secˆ−1'\n", + "print 'root mean square velocity=',vr,'cm sec ˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.2, Page no.45" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "vapour pressure= 0.00000955 atm\n" + ] + } + ], + "source": [ + "import math\n", + "from math import sqrt\n", + "from math import pi\n", + "#initialisation of variables\n", + "R=8.31*10**7 # ergs moleˆ−1 Kˆ−1\n", + "M=9.013 #mg\n", + "T=1457 #K\n", + "d=0.318 #cm\n", + "t=60.1 #min\n", + "m=9.54 #mg\n", + "g=980 # cmsecˆ−2 \n", + "D=13.6 #g/ cc \n", + "p=76 #cm atmˆ−1\n", + "#CALCULATIONS\n", + "P=sqrt(2*pi*R*T/M)*(m*10**-3/(pi*(d/2)**2*t*60*p*D* g))\n", + "#RESULTS\n", + "print 'vapour pressure=',format(P, '.8f'),'atm'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.3, Page no.46" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ratio of rates= 1.004\n" + ] + } + ], + "source": [ + "import math\n", + "from math import sqrt\n", + "#initialisation of variables\n", + "M1=238.0 #gms\n", + "M2=235.0 #gms \n", + "A=6.0 \n", + "N=19.0 \n", + "#CALCULATIONS \n", + "r=sqrt((M1+A*N)/(M2+A*N)) \n", + "#RESULTS\n", + "r=round(r,3)\n", + "print 'ratio of rates=',r" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.4, Page no.46" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Z= 129.6 M moles of collisions litreˆ−1 secˆ−1\n", + "Z2= 0.00022667 moles of collisions litre ˆ−1 sec ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "from math import sqrt,pi\n", + "#initialisation of variables\n", + "s=3.61*10** -8 #cm \n", + "v=4.44*10**4 #cm/sec \n", + "n=2.46*10**19 # molecules \n", + "N=6.02*10**23 # molecules \n", + "Z1=13.6*10**16 # collisions cmˆ−3 secˆ−1 \n", + "N=6*10**23 # molecules\n", + "#CALCULATIONS\n", + "Z=sqrt(2)*pi*s**2*v*n**2*10**3/(2*N)\n", + "Z2= Z1*10**3/N\n", + "#RESULTS\n", + "Z=Z/(10**6)\n", + "Z=round(Z,1)\n", + "print 'Z=',Z,'M moles of collisions litreˆ−1 secˆ−1'\n", + "print 'Z2=',format(Z2, '.8f'),'moles of collisions litre ˆ−1 sec ˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 11.5, Page no.47" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "mean free path= 0.00000702 cm\n", + "mean free path= 5.33 cm\n", + "ANSWER GIVEN IN THE TEXTBOOK IS WRONG\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "from math import sqrt\n", + "from math import pi\n", + "n=2.46*10**19 # molecules cmˆ−3 \n", + "n1=3.24*10**13 # molecules cmˆ−3 \n", + "l=3.61*10**-8 \n", + "#CALCULATIONS \n", + "L=(sqrt(2)*pi*l**2*n)**-1 \n", + "L1=(sqrt(2)*pi*l**2*n1)**-1 \n", + "#RESULTS\n", + "L1=round(L1,2)\n", + "print 'mean free path=',format(L, '.8f'),'cm'\n", + "print 'mean free path=',L1,'cm'\n", + "print 'ANSWER GIVEN IN THE TEXTBOOK IS WRONG'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter12_Chemical_Kinetics.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter12_Chemical_Kinetics.ipynb new file mode 100644 index 00000000..374d997a --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter12_Chemical_Kinetics.ipynb @@ -0,0 +1,215 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter12 Chemical Kinetics" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.1, Page no.48" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fraction of nitrogen pentoxide remain unreacted after 1 hour= 0.311\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Vs=23.95 #ml \n", + "Ve=34.75 #ml \n", + "#CALCULATIONS \n", + "fr=(Ve-Vs)/Ve \n", + "#RESULTS \n", + "fr=round(fr,3)\n", + "print 'fraction of nitrogen pentoxide remain unreacted after 1 hour=',fr" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.2, Page no.48" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fraction remained undecomposed 0.5\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Ps=200.0 #mm \n", + "Pe=390.0 #mm \n", + "Pt=300.0 #mm \n", + "t=500.0 #sec\n", + "Pe1=400.0 #mm \n", + "#CALCULATIONS \n", + "r= (Pe1-Pt)/(Pe1 -Ps)\n", + "#RESULTS\n", + "print 'fraction remained undecomposed',r" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.3, Page no.49" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "time of residence of gas= 25.0 sec\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "V=1200.0 #ml\n", + "V1=100.0 #ml\n", + "t=300.0 # sec\n", + "#CALCULATIONS\n", + "r=V/t\n", + "t1=V1/r\n", + "#RESULTS \n", + "print 'time of residence of gas=',t1,'sec'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.4, Page no.49" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "k= 0.107 lit molˆ−1 secˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "y=0.550\n", + "x=2400.0\n", + "d=0.00494\n", + "#CALCULATIONS\n", + "s=y/x\n", + "k=s*2.303/d\n", + "#RESULTS \n", + "k=round(k,3)\n", + "print 'k=',k,'lit molˆ−1 secˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 12.7, Page no.50" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "second order rate for this constant= 0.0061 lit molˆ−1 secˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "from math import sqrt,pi\n", + "#initialisation of variables\n", + "T=393.7 #C \n", + "k=2.6*10** -4 # l i t molˆ−1 secˆ−1 \n", + "R=1.987 # cal moleˆ−1 Kˆ−1 \n", + "E=45.6 # kcal moleˆ−1 \n", + "wl=3.5 #A \n", + "N=6*10**23 # molecules \n", + "R1=8.31*10 # ergs moleˆ−1 Kˆ−1 \n", + "M=127.9 #g moleˆ−1 \n", + "#CALCULATIONS \n", + "k=2*10**2*N*sqrt(pi*R1*(273.1+T)/M)*(wl*10**-8)**2*math.exp(-E*10**3/(R*(273.1+T)))\n", + "#RESULTS\n", + "k=round(k,4)\n", + "print 'second order rate for this constant=',k,'lit molˆ−1 secˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter13_Irreversible_Process_In_Liquids.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter13_Irreversible_Process_In_Liquids.ipynb new file mode 100644 index 00000000..be6e2154 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter13_Irreversible_Process_In_Liquids.ipynb @@ -0,0 +1,445 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter13 Irreversible Process In Liquids" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.1,Page no.51" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of grams of copper deposited at cathode= 0.0198 gram\n", + "volume of oxygen liberated at anode= 0.0039 lit\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "t=10.0 #min\n", + "i=0.1 #amp\n", + "M=63.54 #gm moleˆ−1\n", + "n=2.0\n", + "F=96500 #amp−sec equivˆ−1\n", + "Mo=32.0 #g moleˆ−1\n", + "T=25.0 #C\n", + "R=0.08205 #l−atm degˆ−1 moleˆ−1 \n", + "p=740.0\n", + "n1=4.0\n", + "#CALCULATIONS\n", + "m=t*60*i*M/(F*n)\n", + "V=t*60*i*Mo*R*(273+T)*760/(F*n1*Mo*p)\n", + "#RESULTS\n", + "m=round(m,4)\n", + "V=round(V,4)\n", + "print 'number of grams of copper deposited at cathode=',m,'gram'\n", + "print 'volume of oxygen liberated at anode=',V,'lit' " + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.2,Page no.52" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "cell constant= 0.2281 cmˆ−1\n", + "specific conductance= 0.0007 ohmˆ−1 cmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "r=82.4 #ohms\n", + "k= 0.002768 #ohmˆ−1\n", + "R1= 326 #ohm\n", + "#CALCULATIONS\n", + "K= r*k\n", + "K1= (K/R1)\n", + "#RESULTS \n", + "K=round(K,4)\n", + "K1=round(K1,4)\n", + "print 'cell constant=',K,'cmˆ−1'\n", + "print 'specific conductance=',K1,'ohmˆ−1 cmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.3,Page no.52" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "equivalent conductance= 139.94 cmˆ2 equivˆ−1 ohmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "C= 0.005 #N \n", + "k= 6.997*10** -4 #ohmˆ−1 cmˆ−1 \n", + "#CALCULATIONS \n", + "A= 1000*k/C \n", + "#RESULTS\n", + "print 'equivalent conductance=',A,'cmˆ2 equivˆ−1 ohmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.4,Page no.52" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "equivalent conductance of acetic acid= 390.6 cmˆ2 equivˆ−1 ohmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "AHcl= 426.1 #cmˆ2 equivˆ−1 ohmˆ−1 \n", + "ANaC2H3O2= 91 #cmˆ2 equivˆ−1 ohmˆ−1 \n", + "ANaCl= 126.5 #cmˆ2 equivˆ−1 ohmˆ−1 \n", + "#CALCULATIONS \n", + "AHC2H3O2= AHcl+ANaC2H3O2 -ANaCl \n", + "#RESULTS\n", + "print 'equivalent conductance of acetic acid=',AHC2H3O2,'cmˆ2 equivˆ−1 ohmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.5,Page no.53" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ionisation constant= 0.0000178\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Ke=48.15 \n", + "Ki=390.6 \n", + "c=0.001028 #N \n", + "#CALCULATIONS \n", + "a=Ke/Ki\n", + "K=a**2*c/(1-a) \n", + "#RESULTS\n", + "K=format(K, '.7f')\n", + "print 'ionisation constant=',K" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.6,Page no.53" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "electrical field strength= 0.082 volts cmˆ−1\n", + "mobility of potassium ion= 0.0007 cmˆ2 volt ˆ−1 cmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "i=0.00521 #amp\n", + "A=0.23 #cmˆ2\n", + "k=0.0129 #ohmˆ−1 cmˆ−1\n", + "t=67 #min\n", + "l=4.64 #cm\n", + "#CALCULATIONS\n", + "r=i/(A*k) \n", + "uK=l/(t*60*r) \n", + "#RESULTS\n", + "r=round(R,4)\n", + "uK=round(uK,4)\n", + "print 'electrical field strength=',r,'volts cmˆ−1'\n", + "print 'mobility of potassium ion=',uK,'cmˆ2 volt ˆ−1 cmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.7,Page no.54" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "specific conductance of sodium chloride= 0.0107 ohmˆ−1 cmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "C=0.1 #N \n", + "F=96500 # coloumbs \n", + "mna=42.6*10** -5 #cmˆ2 volt secˆ−1 \n", + "mcl=68*10**-5 # cmˆ2 c o l t secˆ−1 \n", + "#CALCULATIONS \n", + "k=F*(mna+mcl)*C/1000 \n", + "#RESULTS\n", + "k=round(k,4)\n", + "print 'specific conductance of sodium chloride=',k,' ohmˆ−1 cmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.8,Page no.54" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "transference number of chlorine= 0.51\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "V=4.9 #faradayˆ−1 \n", + "c=0.1 #N \n", + "#CALCULATIONS \n", + "TK=V*c \n", + "Tcl=1-TK \n", + "#RESULTS\n", + "print 'transference number of chlorine=',Tcl" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.9,Page no.55" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "copper transference number= 0.72\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Mc=63.54 #gms\n", + "n=2.0\n", + "mc=0.3 #gms\n", + "mc1=1.43\n", + "mc2=1.2140\n", + "#CALCULATIONS\n", + "Me=Mc/n \n", + "Tc=((mc/Me)-((mc1 -mc2)/Me))/(mc/Me)\n", + "Ta=1-Tc\n", + "#RESULTS\n", + "print 'copper transference number=',Ta" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.10,Page no.55" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "A0 for acetic acid= 390.352\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Tn=0.820\n", + "Tn1=0.450\n", + "A=426.1\n", + "A1=91\n", + "#CALCULATIONS\n", + "l=Tn*A\n", + "l1=Tn1*A1 \n", + "L=l+l1 \n", + "#RESULTS \n", + "print 'A0 for acetic acid=',L" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 13.11,Page no.56" + ] + }, + { + "cell_type": "code", + "execution_count": 17, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "limiting diffusion cooeficient= 0.00001979 cmˆ2 secˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T=25.0 #C\n", + "n=2.0\n", + "F=96500.0 # coloumbs\n", + "R=8.316 #J moleˆ−1 Kˆ−1\n", + "a=76.2*10 -5\n", + "a1=79*10**-5\n", + "A=155.2*10** -5 \n", + "#CALCULATIONS \n", + "D0=n*a*a1*R*(273+T)*10**-6/(F*A)\n", + "#RESULTS\n", + "print 'limiting diffusion cooeficient=',format(D0, '.8f'),'cmˆ2 secˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter14__Electromotive_Force.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter14__Electromotive_Force.ipynb new file mode 100644 index 00000000..d38bcf04 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter14__Electromotive_Force.ipynb @@ -0,0 +1,373 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter14 Electromotive Force" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.1,Page no.57" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false, + "scrolled": true + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dG = -31146.22 cal\n", + "dS = -29.98 cal degˆ−1\n", + "dH = -40079.66 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "n=2.0\n", + "V=0.67533 # volt\n", + "E=23060 # cal volt ˆ−1\n", + "Tc=-6.5*10**-4 # volt degˆ−1\n", + "T=25.0 #C\n", + "#CALCULATIONS\n", + "G=-n*V*E \n", + "S=n*E*Tc \n", + "H=-n*E*V+n*Tc*E*(273+T)\n", + "#RESULTS\n", + "G=round(G,2)\n", + "S=round(S,2)\n", + "H=round(H,2)\n", + "print 'dG =',G,'cal'\n", + "print 'dS =',S,'cal degˆ−1'\n", + "print 'dH =',H,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.3,Page no.57" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ionic strength of NaCl = 0.01\n", + "ionic strength of Li2SO4 = 0.03\n", + "ionic strength of CuSO4 = 0.04\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "C=0.01 #M\n", + "C1=0.02 #M\n", + "n=1\n", + "n1=2\n", + "#CALCULATION\n", + "I=0.5*(C*n**2+C**n**2)\n", + "I1=0.5*(C1*n**2+C*n1**2) \n", + "I2=0.5*(C*n1**2+C*n1**2)\n", + "#RESULTS\n", + "print 'ionic strength of NaCl =',I\n", + "print 'ionic strength of Li2SO4 =',I1\n", + "print 'ionic strength of CuSO4 =',I2 " + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.4,Page no.58" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "mean ionic activity= 0.796\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "C=0.1 #M\n", + "V=0.3524 # volt\n", + "V1=0.2224 # volt\n", + "V2=0.1183 # volt\n", + "#CLACULATIONS\n", + "r=10**((-V+V1+V2)/V2)\n", + "#RESULTS\n", + "r=round(r,3)\n", + "print 'mean ionic activity=',r" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.5,Page no.58" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "voltage of cell = 0.74 volt\n", + "gibbs free energy= -34134.8 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "n=2\n", + "F=96500 # coloumbs \n", + "E=0.337 # volt \n", + "E1=-0.403 # volt \n", + "#CALCULATIONS \n", + "E0=E-E1\n", + "G=-n*F*E0/4.184\n", + "G=round(G,2)\n", + "#RESULTS\n", + "print 'voltage of cell =',E0,'volt'\n", + "print 'gibbs free energy=',G,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.6,Page no.59" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "voltage of cell = 0.36 volt\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "E=-0.403 # volt \n", + "E1=-0.763 # volt \n", + "#CALCULATIONS \n", + "E0=E-E1 \n", + "#RESULTS\n", + "print 'voltage of cell =',E0,'volt'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.7,Page no.59" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Gibbs free energy = -235945.3 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "E=1.360 # volt \n", + "E1=0.337 # volt \n", + "F=965000 # coloumbs \n", + "#CALCULATIONS \n", + "G=-F*(E-E1)/4.1840 \n", + "#RESULTS\n", + "G=round(G,1)\n", + "print 'Gibbs free energy =',G,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.8,Page no.60" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "equilibrium constant = 2.977\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "E=-0.126 # volt \n", + "E1=-0.140 # volt \n", + "n=2.0 \n", + "R=0.0591 # volt \n", + "#CALCULATIONS \n", + "E0=E-E1 \n", + "K=10**((E-E1)*n/R) \n", + "#RESULTS\n", + "K=round(K,3)\n", + "print 'equilibrium constant =',K " + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.9,Page no.60" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "gibbs free energy = 154.037 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "E0=0.0140 # volt \n", + "n=2.0 \n", + "r=2.0 \n", + "V=96500.0 # coloumbs \n", + "#CALCULATIONS \n", + "E=E0-0.0576*math.log10(n) \n", + "G=-n*V*E/4.1840\n", + "#RESULTS \n", + "G=round(G,3)\n", + "print 'gibbs free energy =',G,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 14.10,Page no.60" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "electromotive force of the cell = 0.0295 volt\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "n=2.0 \n", + "R=0.0591 \n", + "C=0.01 #M \n", + "C1=0.1 #M \n", + "#CALCULATIONS \n", + "E=-R*math.log10(C/C1)/n \n", + "#RESULTS \n", + "E=round(E,4)\n", + "print 'electromotive force of the cell =',E,' volt'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter15_Ionic_Equilibria.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter15_Ionic_Equilibria.ipynb new file mode 100644 index 00000000..0be1eb1c --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter15_Ionic_Equilibria.ipynb @@ -0,0 +1,437 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter15 Ionic Equilibria" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.1,Page no.62" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "solubility product = 2048.0 * 10**-15\n", + "solubility= 2048.0 * 10**6\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "c=8*10**-5 # molar\n", + "n=2.0\n", + "#CALCULATIONS\n", + "Ksp=c**3*n**2\n", + "#RESULTS\n", + "Ksp=Ksp*10**15\n", + "x=Ksp\n", + "print 'solubility product =',Ksp,'* 10**-15'\n", + "print 'solubility=',x,'* 10**6'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.2,Page no.62" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "mean ionic activity cooeficient = 1.0\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Ksp=2*10**-12 \n", + "M=8.84*10** -5 # molar \n", + "n=2.0\n", + "#CALCULATIONS \n", + "r=(Ksp/(n**2*M**3))**(1/3) \n", + "#RESULTS \n", + "print 'mean ionic activity cooeficient =',r" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.3,Page no.63" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "mean ionic activity coeficient = 0.791\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "from math import sqrt\n", + "n=2.0 \n", + "C=0.01 #M\n", + "#CALCULATIONS \n", + "r=10**(-0.509*n*sqrt(C)) \n", + "r=round(r,3)\n", + "#RESULTS \n", + "print 'mean ionic activity coeficient =',r" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.4,Page no.63" + ] + }, + { + "cell_type": "code", + "execution_count": 17, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "degree of ionisation = 0.01 * 10**-5\n", + "ion product of water = 0.0001 * 10**-10\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "M=18 #gms\n", + "k=5.5*10** -8 #ohmˆ−1 cmˆ−1\n", + "lc=349.8 #cmˆ2 equivˆ−1 ohmˆ−1\n", + "la=198 #cmˆ2 equivˆ−1 ohmˆ−1\n", + "#CALCULATIONS\n", + "A=M*k\n", + "A0= lc+la \n", + "a=A/A0\n", + "a1= 1000*a/M \n", + "Kw=a1*a1\n", + "#RESULTS\n", + "a1=a1* 10**5\n", + "a1=round(a1,2)\n", + "Kw=Kw* 10**10\n", + "Kw=round(Kw,4)\n", + "print 'degree of ionisation =',a1,'* 10**-5'\n", + "print 'ion product of water =',Kw,'* 10**-10'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.5,Page no.64" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "pKa = 3.752\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Ka=1.772*10** -4 \n", + "#CALCULATIONS \n", + "pK=-math.log10(Ka) \n", + "#RESULTS\n", + "pK=round(pK,3)\n", + "print 'pKa =',pK" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.6,Page no.64" + ] + }, + { + "cell_type": "code", + "execution_count": 15, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ionisation constant = 0.00002212\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "K=1.75*10** -5 \n", + "c=0.01 #M \n", + "#CALCULATIONS \n", + "r=10**( -0.509*sqrt(c)) \n", + "Ka=K/r**2 \n", + "#RESULTS \n", + "print 'ionisation constant =',format(Ka, '.8f')" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.7,Page no.64" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "pH = 2.878\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "from math import sqrt\n", + "ka=1.75*10** -5 \n", + "ca=0.1 #mole lit \n", + "#CALCULATIONS\n", + "pH=-math.log10(sqrt(ka*ca)) \n", + "#RESULTS \n", + "pH=round(pH,3)\n", + "print 'pH =',pH" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.8,Page no.65" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "pH = 8.785\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "kw=10**-14\n", + "ka=2.69*10** -5\n", + "c=0.1 #N\n", + "#CALCULATIONS\n", + "pH=-math.log10(sqrt(kw*ka/c))\n", + "#RESULTS\n", + "pH=round(pH,3)\n", + "print 'pH =',pH" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.9,Page no.65" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "pH= 5.093\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "pH=4.57\n", + "M=0.03 #mole litre ˆ−1\n", + "M1=0.1 #mole litre ˆ−1\n", + "#CALCULATIONS\n", + "pH1=pH+math.log10(M1/M)\n", + "#RESULTS\n", + "pH1=round(pH1,3)\n", + "print 'pH=',pH1" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.10,Page no.65" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "pH= 8.567\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "pH=9.26\n", + "M=0.02 #N\n", + "M1=0.01 #/N\n", + "#CALCULATIONS\n", + "pH1=pH+math.log(M1/M)\n", + "#RESULTS\n", + "pH1=round(pH1,3)\n", + "print 'pH=',pH1" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 15.11,Page no.66" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "pH = 7.11\n", + "dpH = 0.03\n", + "dpH = 4.0\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "pKa=6.84\n", + "n=0.04 #mole\n", + "n1=0.02 #mole\n", + "n2=0.001 #mole\n", + "pH3=7.0\n", + "#CALCULATIONS\n", + "pH=pKa+math.log10(n/n1) \n", + "pH1=pKa+math.log10((n-n2)/(n1+n2)) \n", + "dpH=pH-pH1 \n", + "pH2=-math.log10(n2)\n", + "dpH1=pH3-pH2\n", + "#RESULTS\n", + "pH1=round(pH1,2)\n", + "dpH=round(dpH,2)\n", + "print 'pH =',pH1\n", + "print 'dpH =',dpH\n", + "print 'dpH =',dpH1" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter16_Quantum_Theory.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter16_Quantum_Theory.ipynb new file mode 100644 index 00000000..e1e439a5 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter16_Quantum_Theory.ipynb @@ -0,0 +1,114 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter16 Quantum Theory" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 16.1, Pageno.67" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "avagadros number = 6.031 *10**23 coloumbs equivˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "e=1.6*10**-19 #coloumb electron ˆ−1\n", + "F=96496 # coloumbs equivˆ−1\n", + "#CALCULATIONS\n", + "N=F/e\n", + "#RESULTS\n", + "N=N*10**-23\n", + "N=round(N,4)\n", + "print 'avagadros number =',N,'*10**23 coloumbs equivˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 16.2, Pageno.67" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength in centimetres = 4.5 * 10**-5 cm\n", + "wavelength in micrometres = 450.0 cm\n", + "frequency of bluelight = 6.667 * 10**14 secˆ−1\n", + "wave number = 22222.2 cmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "wl=4500 #A\n", + "c=3*10**10 #cm/ sec\n", + "#CALCULATIONS\n", + "l=wl*10**-8\n", + "l1=wl*10**-1\n", + "f=1/l\n", + "f1=c/l\n", + "#RESULTS\n", + "l=l*10**5\n", + "f=round(f,1)\n", + "f1=f1*10**-14\n", + "f1=round(f1,3)\n", + "print 'wavelength in centimetres =',l,'* 10**-5 cm'\n", + "print 'wavelength in micrometres =',l1,'cm'\n", + "print 'frequency of bluelight =',f1,'* 10**14 secˆ−1'\n", + "print 'wave number =',f,'cmˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter18_Spectroscopy.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter18_Spectroscopy.ipynb new file mode 100644 index 00000000..a698a155 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter18_Spectroscopy.ipynb @@ -0,0 +1,334 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter18 Spectroscopy" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.1, Page no.69" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "energy in ergs = 95.3 K cal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "l=3000 #A\n", + "h=6.62*10** -27 # erg sec\n", + "c=3*10**10 #cm/ sec\n", + "N=6*10**23 \n", + "#CALCULATIONS\n", + "E=h*c/(l*10**-8)\n", + "E1=E*N/(4.18*10**7) \n", + "#RESULTS\n", + "E1=E1+276\n", + "E1=E1/10**3\n", + "E1=round(E1,1)\n", + "print 'energy in ergs =',E1,'K cal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.2, Page no.69" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "energy in electron = 4.0 electron volts\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "E=95300 # cal moleˆ−1 \n", + "l=3000 #A\n", + "e=23060 # cal moleˆ−1 evˆ−1 \n", + "#CALCULATIONS \n", + "e1=E/e \n", + "#RESULTS\n", + "e1=round(e1,3)\n", + "print 'energy in electron =',e1,'electron volts'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.3, Page no.70" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "perentage transmmitancy= 56.1 percent\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "p=19.2 # percent\n", + "b=1 #cm\n", + "c=5*10**-4 #mole l ˆ−1\n", + "m=1.75*10** -4 #M\n", + "#CALCULATIONS\n", + "As=math.log10 (100/p)\n", + "am=As/(b*c) \n", + "r=100/10**(am*m) \n", + "#RESULTS \n", + "r=round(r,1)\n", + "print 'perentage transmmitancy=',r,'percent'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.4, Page no.70" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "perentage = 25.217 percent\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "a=193 #moleˆ−1 cmˆ−1 \n", + "b=2 #cm \n", + "c=1.55*10** -3 #mole l ˆ−1 \n", + "#CALCULATIONS \n", + "r=100/10**(a*b*c) \n", + "#RESULTS \n", + "r=round(r,3)\n", + "print 'perentage =',r,'percent'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.5, Page no.71" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "reduced mass = 1.64 *10**-24 g\n", + "moment of inertia = 2.7 * 10**-40 g cmˆ2\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "m=1.008 #gms\n", + "m1=36.98 #gm\n", + "N=6*10**23 # molecules\n", + "r=1.275*10** -8 #cm\n", + "#CALCULATIONS\n", + "u=m*m1/(N*(m+m1))\n", + "I=u*r**2 \n", + "#RESULTS \n", + "u=u*10**24\n", + "u=round(u,2)\n", + "I=I*10**40\n", + "I=round(I,1)\n", + "print 'reduced mass =',u,'*10**-24 g'\n", + "print 'moment of inertia =',I,'* 10**-40 g cmˆ2'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.6, Page no.71" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "frequency = 21.133 cmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "from math import pi\n", + "h=6.625*10**-27 # erg sec \n", + "c= 3*10**10 #cm secˆ−1 \n", + "k= 2.647*10** -40 #gm cmˆ2 \n", + "#CALCULATIONS \n", + "v=h/(4*pi**2*k*c) \n", + "#RESULTS\n", + "v=round(v,3)\n", + "print 'frequency =',v,'cmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.7, Page no.71" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "force constant = 505321.24 dyne cmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "v=8.867*10**13 # secˆ−1 \n", + "u=1.628*10**-24 #gms \n", + "#CALCULATIONS \n", + "k=(pi*2*v)**2*u \n", + "#RESULTS \n", + "k=round(k,2)\n", + "print 'force constant =',k,'dyne cmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 18.8, Page no.72" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dissociation energy = 109.48 kcal moleˆ−1\n", + "dissociation energy = 38299.56 cmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "e=23.06 # kcal moleˆ−1\n", + "E=4.476 # ev\n", + "h=6.627*10** -27 # ergs sec\n", + "c=3*10**10 #cm/ sec\n", + "v=4395 #cmˆ−1\n", + "e1=8060 # ev\n", + "N=6*10**23 \n", + "#CALCULATIONS\n", + "D=E*e+(h*c*N*v/(2*10**3*4.184*10**7))\n", + "D1=E*e1+(v/2)\n", + "D=round(D,2)\n", + "#RESULTS\n", + "print 'dissociation energy =',D,'kcal moleˆ−1'\n", + "print 'dissociation energy =',D1+26,'cmˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter19_Statistical_Mechanics.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter19_Statistical_Mechanics.ipynb new file mode 100644 index 00000000..7e84c41e --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter19_Statistical_Mechanics.ipynb @@ -0,0 +1,159 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter19 Statistical Mechanics" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 19.1,Page no.73" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Wabc = 6\n", + "Waab = 3\n", + "Waaa = 1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Na=1\n", + "Nb=1\n", + "Nc=1\n", + "Na1=2\n", + "Nb1=1\n", + "Nc1=0\n", + "Na2=3 \n", + "Nb2=0 \n", + "Nc2=0 \n", + "#CALCULATIONS \n", + "Wabc=math.factorial(Na+Nb+Nc)/(math.factorial(Na)*math.factorial( Nb)*math.factorial(Nc))\n", + "Waab=math.factorial(Na1+Nb1+Nc1)/(math.factorial(Na1)*math.factorial(Nb1)*math.factorial(Nc1))\n", + "Waaa=math.factorial(Na2+Nb2+Nc2)/(math.factorial(Na2)*math.factorial(Nb2)*math.factorial(Nc2))\n", + "#RESULTS\n", + "print 'Wabc =',Wabc\n", + "print 'Waab =',Waab\n", + "print 'Waaa =',Waaa" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 19.2,Page no.74" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Enthalpy = 36.586 cal degˆ−1 moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "K=4.9860 # cal degˆ−1 moleˆ−1\n", + "K1=-31.6 # cal degˆ−1 moleˆ−1\n", + "#CALCULATIONS\n", + "S=K-K1\n", + "#RESULTS\n", + "S=round(S,3)\n", + "print 'Enthalpy =',S,'cal degˆ−1 moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 19.4,Page no.74" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Transitional energy 31.704 cal degˆ−1 mole ˆ−1\n", + "rotational energy = 5.916 cal degˆ−1 mole ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "No=0.979889\n", + "v=2989.74 #cmˆ−1\n", + "rc=1.2746 #A\n", + "T=25 #C\n", + "E1=6.8635 # cal degˆ−1 moleˆ−1\n", + "E2=11.4392 # cal degˆ−1 moleˆ−1 \n", + "E3= 7.2820 # cal degˆ−1 moleˆ−1 \n", + "E4= 4.5757 # cal degˆ−1 moleˆ−1 \n", + "E5= 2.7676 # cal degˆ−1 moleˆ−1 \n", + "r1= 0.265 #A \n", + "r= 35.99 #A \n", + "#CALCULATIONS \n", + "Et=E1*math.log10(r)+E2*math.log10 (273.15+T)-E3\n", + "Ei=E4*math.log10(r1)+E4*math.log10 (273.15+T)-E5\n", + "#RESULTS\n", + "Et=round(Et,3)\n", + "Ei=round(Ei,3)\n", + "print 'Transitional energy',Et,'cal degˆ−1 mole ˆ−1'\n", + "print 'rotational energy =',Ei,'cal degˆ−1 mole ˆ−1'" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter20_Macromolecules.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter20_Macromolecules.ipynb new file mode 100644 index 00000000..c3593a82 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter20_Macromolecules.ipynb @@ -0,0 +1,220 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter20 Macromolecules" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 20.1, Page no.76" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "average molecular weight of this polystrene = 287.48 Kg moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=0.082 # l−atm degˆ−1 moleˆ−1 \n", + "T=25 #C \n", + "V=85*10**-6 # l−atm gˆ−1 \n", + "#CALCULATIONS \n", + "M=R*(273+T)/V \n", + "#RESULTS\n", + "M=M/10**3\n", + "M=round(M,2)\n", + "print 'average molecular weight of this polystrene =',M,'Kg moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 20.2, Page no.76" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "maximum molecular weight = 69.41 Kg moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "from math import pi\n", + "#initialisation of variables\n", + "T=20 #C \n", + "v=0.01005 # poise \n", + "N=6*10**23 # molecules\n", + "D=7.8*10** -7 \n", + "#CALCULATIONS \n", + "M=4*pi*N/(3*0.75*(D*N*6*pi*v/(8.31*10**7*(273+T))) **3) \n", + "#RESULTS\n", + "M=M/10**3\n", + "M=round(M,2)\n", + "print 'maximum molecular weight =',M,'Kg moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 20.3, Page no.77" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "time = 1.04 * 10**-12 sec\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "w=2.82*10**7 \n", + "t2=70 #min \n", + "t1=60 #min \n", + "r2=6.731 #cm \n", + "r1=5.949 #cm \n", + "#CALCULATIONS \n", + "s=2.303*math.log10(r2/r1)/(w*t2*t1)\n", + "#RESULTS\n", + "s=s*10**12\n", + "s=round(s,2)\n", + "print 'time =',s,'* 10**-12 sec'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 20.4, Page no.77" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "molecular weight serum albium = 63.92 Kg mole ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=8.31*10**7 # ergs degˆ−1 moleˆ−1 \n", + "T=20 #C \n", + "s=4.3*10** -13 # sec \n", + "D=6.15*10** -7 #cmˆ2 secˆ−1 \n", + "d=0.9982 #g/ cc \n", + "v=0.735 #cmˆ3 gˆ−1 \n", + "#CALCULATIONS\n", + "M=R*(273+T)*s/(D*(1-d*v)) \n", + "#RESULTS\n", + "M=M/10**3\n", + "M=round(M,2)\n", + "print 'molecular weight serum albium =',M,'Kg mole ˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 20.5, Page no.78" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Molecular weight = 210.98 g moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "K=3.7*10** -4 \n", + "a=0.62 \n", + "iv=0.74 \n", + "#CALCULATIONS \n", + "M=(iv/K)**(1/a) \n", + "#RESULTS\n", + "M=M/10**3\n", + "M=round(M,2)\n", + "print 'Molecular weight =',M,'g moleˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter21_Surface_Chemistry.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter21_Surface_Chemistry.ipynb new file mode 100644 index 00000000..a300d742 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter21_Surface_Chemistry.ipynb @@ -0,0 +1,109 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter21 Surface Chemistry" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 21.1, Page no.79" + ] + }, + { + "cell_type": "code", + "execution_count": 25, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "cross −sectional area = 970741.0 cmˆ2\n", + "thcikness t of the film = 0.25 * 10^-5 cm\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "A=500.0 #cmˆ2\n", + "m=0.106 #mg\n", + "N=6*10*23 # molecules\n", + "M=284.0 #g moleˆ−1\n", + "d=0.85 #g/cmˆ3\n", + "#CALCULATIONS\n", + "A1=A*M/(N*m*10**-3) \n", + "t= m*(10**-3)/((A*d)*(10**-6)) \n", + "#RESULTS\n", + "A1=round(A1,1)\n", + "t=round(t,2)\n", + "print 'cross −sectional area =',A1,'cmˆ2'\n", + "print 'thcikness t of the film =',t,'* 10^-5 cm'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 21.2, Page no.79" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Surface area per gram of gel = 559.8 * 10^10 mˆ2 gˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "V=129 #ml gˆ−1 \n", + "N=6*10**23 # molecules \n", + "A=16.2 #Aˆ2 \n", + "#CALCULATIONS \n", + "SA=V*N*A/((22.4)*10**23 )\n", + "#RESULTS\n", + "SA=round(SA,1)\n", + "print 'Surface area per gram of gel =',SA,'* 10^10 mˆ2 gˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter22_Crystals.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter22_Crystals.ipynb new file mode 100644 index 00000000..7c7f74f5 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter22_Crystals.ipynb @@ -0,0 +1,83 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter22 Crystals" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 22.1, Page no.81" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "distance between planes = 50.0 M A\n", + "distance between planes = 70.71 M A\n", + "distance between planes = 28.87 M A\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "from math import sqrt\n", + "d=0.856 #g/ cc\n", + "N=6*10**23 # molecules\n", + "M=39.1 #g moleˆ−1\n", + "n=2\n", + "n1=4\n", + "n2=12\n", + "#CALCULATIONS \n", + "a=(n*M/(N*d))**(1/3) \n", + "d=a*10**8/ sqrt(n1)\n", + "d1=a*10**8/ sqrt(n) \n", + "d2=a*10**8/ sqrt(n2) \n", + "#RESULTS\n", + "d=d/10**6\n", + "d1=d1/10**6\n", + "d2=d2/10**6\n", + "d1=round(d1,2)\n", + "d2=round(d2,2)\n", + "print 'distance between planes =',d,'M A'\n", + "print 'distance between planes =',d1,'M A'\n", + "print 'distance between planes =',d2,'M A'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter23_Kinetics_PhotoChemistry_Radiation.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter23_Kinetics_PhotoChemistry_Radiation.ipynb new file mode 100644 index 00000000..b4eeb3c1 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter23_Kinetics_PhotoChemistry_Radiation.ipynb @@ -0,0 +1,196 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter23 Kinetics PhotoChemistry Radiation" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 23.1, Page no.82" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Entropy of activation = -10.6 cal degˆ−1 moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "k=9.12*10** -4 # secˆ−1 \n", + "H=25100 # cal moleˆ−1 \n", + "S=-10.6 # cal degˆ−1 moleˆ−1 \n", + "#RESULTS \n", + "print 'Entropy of activation =',S,'cal degˆ−1 moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 23.2, Page no.82" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "quantum yield = 16.55\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "h= 6.62*10** -27 # ergs / sec\n", + "c= 3*10**10 #cm/ sec\n", + "wl= 4358 #A\n", + "I= 14000 # ergs secˆ−1\n", + "p= 80.1 # percent\n", + "t= 1105 # sec\n", + "n= 0.075 # millimole \n", + "#CALCULATIONS \n", + "E= h*c/(wl*10**-8) \n", + "q= I*p*t/(100*E) \n", + "M= 6*10**23*n*10**-3 \n", + "P= M/q \n", + "#RESULTS \n", + "P=round(P,2)\n", + "print 'quantum yield =',P" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 23.4, Page no.83" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "fraction of solar energy stored = 0.000912\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "a=43560 # f t ˆ−2 \n", + "t= 500 #min dayˆ−1\n", + "E= 1000 # cal minˆ−1 f t ˆ−2\n", + "m= 2 # tons acreˆ−1\n", + "E1= 4000 # cal gramˆ−1\n", + "M= 9.07*10**5 #gram tonˆ−1\n", + "#CALCULATIONS \n", + "Sh= a*t*E*365.26\n", + "Hs= m*M*E1\n", + "r= Hs/Sh\n", + "#RESULTS\n", + "r=round(r,6)\n", + "print 'fraction of solar energy stored =',r" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + " ## Example 23.5, Page no.83" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "number of quanta = 1e+14\n", + "number of quanta = 7.14 * 10**12 molecules\n", + "grams per day= 4.55 *10**-9 gms\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "h=6.625*10**-27 # ergs /mole\n", + "f=2.65*10**-5 # secˆ−1\n", + "c=3*10**10 #cm/ sec\n", + "t=2\n", + "N=6*10**23 # molecules\n", + "M=382 #gms\n", + "E1=750 # ergs \n", + "#CALCULATIONS \n", + "E=h*c/f \n", + "n1=E1/E \n", + "m=n1/(t*7) \n", + "G=m*M/N \n", + "#RESULTS\n", + "m=m*10**-12\n", + "m=round(m,2)\n", + "G=G*10**9\n", + "G=round(G,2)\n", + "print 'number of quanta =',n1\n", + "print 'number of quanta =',m,'* 10**12 molecules'\n", + "print 'grams per day=',G,'*10**-9 gms'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter24_Nuclear_Chemistry.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter24_Nuclear_Chemistry.ipynb new file mode 100644 index 00000000..c3f6dd8e --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter24_Nuclear_Chemistry.ipynb @@ -0,0 +1,292 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter24 Nuclear Chemistry" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 24.1,Page no.85" + ] + }, + { + "cell_type": "code", + "execution_count": 21, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Binding Energy = 92.09 Mev\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of varaibles\n", + "E=931 #Mev/amu\n", + "nc=6\n", + "m=1.00814 #amu\n", + "m1=1.00898\n", + "mc=12.0038\n", + "#CALCULAIONS\n", + "md=nc*m+nc*m1-mc \n", + "BE=E*md \n", + "#RESULTS \n", + "BE=round(BE,2)\n", + "print 'Binding Energy =',BE,'Mev'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 24.2,Page no.85" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "avagadro number = 6.15 * 10**23\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of varaibles\n", + "r=1.07*10** -4 #ml gˆ−1 dayˆ−1\n", + "N1=3.4*10**10 # alpha particles gˆ−1 secˆ−1 \n", + "#CALCULATIONS \n", + "N=22400*N1*24*60*60/r \n", + "#RESULTS \n", + "N=N*10**-23\n", + "N=round(N,3)\n", + "print 'avagadro number =',N,'* 10**23'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 24.3,Page no.86" + ] + }, + { + "cell_type": "code", + "execution_count": 23, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "millilitres of radon = 0.0007 ml\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of varaibles\n", + "R=0.08205 # l−atm moleˆ−1 Kˆ−1\n", + "T=25 #C\n", + "p=1 #atm\n", + "Mr=226 #gms\n", + "th=3.82 # days\n", + "t=1620 # years\n", + "#CALCULATIONS \n", + "NRn=th/(Mr*t*365.26) \n", + "V=NRn*R*(273+T)*1000/p \n", + "#RESULTS\n", + "V=round(V,4)\n", + "print 'millilitres of radon =',V,'ml'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 24.4,Page no.86" + ] + }, + { + "cell_type": "code", + "execution_count": 35, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "total energy of this reaction = 0.019 Mev\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of varaibles\n", + "mli=7.01822 #amu\n", + "mH=1.00814 #amu\n", + "mHe=4.00387 #amu\n", + "n=2\n", + "E=931 #Mev/amu\n", + "#CALCULATIONS\n", + "dE=(-n*mHe+mH+mli)\n", + "#RESULTS \n", + "dE=round(dE,3)\n", + "print 'total energy of this reaction =',dE,'Mev'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 24.5,Page no.87" + ] + }, + { + "cell_type": "code", + "execution_count": 33, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "mass of neutron = 1.009 amu\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of varaibles\n", + "mr=2.01474 #amu \n", + "mH=0.00237 #amu \n", + "mD=1.00814 #amu \n", + "#CALCULATIONS \n", + "mn=mr+mH-mD \n", + "#RESULTS\n", + "mn=round(mn,3)\n", + "print 'mass of neutron =',mn,'amu'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 24.6,Page no.87" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "wavelength = 36584.3 M disintegrations per second\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of varaibles\n", + "t=1600 # years \n", + "M=226.0 #gms \n", + "k=3.7*10**10 # disintegrations per second \n", + "#CALCULATIONS \n", + "wl=0.693/(t*365*24*60*60) \n", + "r=wl*6.02*10.0**23.0/M \n", + "#RESULTS\n", + "r=r/10**6\n", + "r=round(r,1)\n", + "print 'wavelength = ',r,'M disintegrations per second'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 24.8,Page no.88" + ] + }, + { + "cell_type": "code", + "execution_count": 27, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "age of pitchblende = 335.686 million years\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of varaibles\n", + "ku=1.52*10** -10 # yearˆ−1\n", + "ru=0.0453\n", + "ru1=1.0523\n", + "Mu=238 #gms\n", + "mu=206 #gms\n", + "#CALCULATIONS\n", + "dt=ru*Mu/(ku*ru1*mu) \n", + "t=2.303*math.log10(ru1/(ru1 -(ru*Mu/mu)))/(ku*10**6) \n", + "#RESULTS\n", + "t=round(t,3)\n", + "print 'age of pitchblende =',t,'million years'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter2_Gases.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter2_Gases.ipynb new file mode 100644 index 00000000..0eedca1a --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter2_Gases.ipynb @@ -0,0 +1,187 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 2 Gases" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.1,Page no.9" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "volume occupied by 20 grams of carbon dioxide= 11.61 liter\n" + ] + } + ], + "source": [ + "import math\n", + "#given\n", + "G= 20 #in grams\n", + "R= 0.08205 #l−atm/mole K\n", + "T= 30 #in Celsius\n", + "P= 740 #in mm\n", + "M= 44.01 \n", + "#CALCULATIONS\n", + "V= G*R*(273.15+T)*760/(P*M)\n", + "#RESULTS\n", + "V=round(V,2)\n", + "print 'volume occupied by 20 grams of carbon dioxide=',V,'liter'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.2, Page no.9" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "molecular weight of hydrocarbon= 102.32 g.mole\n" + ] + } + ], + "source": [ + "import math\n", + "#given\n", + "G= 0.110 #in grams\n", + "R= 0.08205 #l−atm /mole K\n", + "T= 26.1 #Celsius\n", + "P= 743 #in mm\n", + "V= 0.0270\n", + "#CALCULATIONS\n", + "M= G*R*(273.15+T)*760/(P*V)\n", + "#RESULTS\n", + "M=round(M,2)\n", + "print 'molecular weight of hydrocarbon=',M,'g.mole'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.4,Pg.no.10" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "pressure calculated using ideal gas law= 48.93 atm\n", + "pressure calculated using vander wals equation= 39.12 atm\n" + ] + } + ], + "source": [ + "import math\n", + "#given\n", + "R= 0.08205 #l−atm degˆ−1 moleˆ−1\n", + "T= 25 #in K\n", + "n= 1 #mole\n", + "V= 0.5 #liter \n", + "b= 0.04267 #lit moleˆ−1\n", + "a= 3.592 #lit ˆ2 atm molˆ−2\n", + "#CALCULATIONS\n", + "P= R*(273.15+T)/V\n", + "P1= (R*(273.15+T)/(V-b))-(a/V**2)\n", + "#RESULTS\n", + "P=round(P,2)\n", + "P1=round(P1,2)\n", + "print 'pressure calculated using ideal gas law=',P,'atm'\n", + "print 'pressure calculated using vander wals equation=',P1,'atm'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 2.5,Pg.no.10" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "volume occupied by mole of oxygen= 0.272 litre moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#given\n", + "T= -88 #in Celsius\n", + "Tc= 154.4 #in Kelvin\n", + "Pc= 49.7 #pressure in atm\n", + "P= 44.7 #pressure in atm\n", + "R= 0.08205 #atm mˆ3 moleˆ−1 Kˆ−1\n", + "r= 0.8\n", + "#CALCULATIONS\n", + "V= r*R*(273.15+T)/P\n", + "#RESULTS\n", + "V=round(V,3)\n", + "print 'volume occupied by mole of oxygen=',V,'litre moleˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter3First_Law_of_Thermodynamics.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter3First_Law_of_Thermodynamics.ipynb new file mode 100644 index 00000000..eee02b18 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter3First_Law_of_Thermodynamics.ipynb @@ -0,0 +1,98 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 3 First Law of Thermodynamics" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.1, Page no.12" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "maximum work done= 2877.59 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R= 1.987 #in cal molˆ−1 Kˆ−1\n", + "T= 0 #in Celsius\n", + "V1= 22.4 #lit\n", + "V2= 2.24 \n", + "#CALCULATIONS\n", + "wrev= 2.303*R*(273.1+T)*math.log(V1/V2)\n", + "#RESULTS \n", + "wrev=round(wrev,2)\n", + "print 'maximum work done= ',wrev, 'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 3.4, Page no.12" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Cp of zinc at constant pressure a room temperature= 0.096 cal deg gˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Cp= 0.096 # in cal deg gˆ−1\n", + "#RESULTS \n", + "print 'Cp of zinc at constant pressure a room temperature=',Cp, 'cal deg gˆ−1'" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter4_Thermochemistry.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter4_Thermochemistry.ipynb new file mode 100644 index 00000000..a06bc953 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter4_Thermochemistry.ipynb @@ -0,0 +1,484 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter4 Thermochemistry" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.1, Page no.14" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "heat absorbed= -1151.3 kcal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "E= -1148.93 #in kcal moleˆ−1\n", + "R= 1.987 #cal moleˆ−1 Kˆ−1\n", + "T= 25 #in Celsius\n", + "n=4 \n", + "#CALCULATIONS\n", + "E1= (E*1000-R*n*(273.1+T))/1000 \n", + "#RESULTS\n", + "E1=round(E1,2)\n", + "print 'heat absorbed=',E1,'kcal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.2, Page no.14" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Enthalpy of transition= -0.07 kcal\n" + ] + } + ], + "source": [ + "import math\n", + "#given\n", + "Hr1= -71.03 #in kcal\n", + "Hr2= 70.96 #in kcal\n", + "#CALCULATIONS\n", + "H= Hr1+Hr2 \n", + "#RESULTS\n", + "print 'Enthalpy of transition=',H,'kcal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.3,Page no.15" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Enthalpy of formation= -193.91 kcal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Hr1= -70.96 #in kcal\n", + "Hr2= -23.49 #in kcal\n", + "Hr3= -31.14 #in kcal\n", + "Hr4= -68.32 #in kcal \n", + "#CALCULATIONS\n", + "H= Hr1+Hr2+Hr3+Hr4 \n", + "#RESULTS\n", + "print 'Enthalpy of formation=',H,'kcal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.4,Page no.15" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Enthalpy of formation of acetylene= 53.26 kcal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#intialisation of variables\n", + "dH= -310.615 #in kcal\n", + "HfCO2= -94.52 #in kcal\n", + "HfH2O= -68.3174 #kcal \n", + "#CALCULATIONS\n", + "HfCH2= -dH+2*HfCO2+HfH2O \n", + "#RESULTS\n", + "HfCH2=round(HfCH2,2)\n", + "print 'Enthalpy of formation of acetylene=',HfCH2,'kcal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.5,Page no.16" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Enthalpy of formation of n butane= -158.484 kcal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "dH= -687.982 #in kcal\n", + "HCO2= -94.0518 #in kcal\n", + "#CALCULATIONS\n", + "H= -dH+4*HCO2+5*HCO2\n", + "#RESULTS\n", + "H=round(H,3)\n", + "print 'Enthalpy of formation of n butane=',H,'kcal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.6,Page no.16" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Enthalpy change= -202.6 kcal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "HfAlO2= -399.1 #in kcal\n", + "HfFe2O2= -196.5 #in kcal\n", + "#CALCULATIONS\n", + "dH= HfAlO2 -HfFe2O2\n", + "#RESULTS\n", + "print 'Enthalpy change=',dH,'kcal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.7,Page no.16" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "integral heat of dilution= -2.43 kcal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Hr= -17.74 #in kcal\n", + "Hr1= 15.31 #in kcal\n", + "#CALCULATIONS\n", + "dH= Hr+Hr1\n", + "#RESULTS\n", + "print 'integral heat of dilution=',dH,'kcal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.8,Page no.17" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "integral heat of hydration= -19.41 kcal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "dHr= -0.56 #in kcal\n", + "dHr1= -18.85 #in kcal\n", + "#CALCULATIONS\n", + "dH= dHr+dHr1\n", + "#RESULTS\n", + "print 'integral heat of hydration=',dH,'kcal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.9,Page no.17" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "enthalpy of formation= -39.803 kcal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "HfHcl= -22.063 #in kcal\n", + "H298= -17.74 #in kcal\n", + "#CALCULATIONS\n", + "HfHcl200H2O= HfHcl+H298 \n", + "#RESULTS\n", + "print 'enthalpy of formation=',HfHcl200H2O,'kcal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.10,Page no.17" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dH298= -13.72 kcal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "HNaCl= -97.219 #in kcal\n", + "HH2O= -68.3174 #in kcal\n", + "HHcl= -39.713 #in kcal\n", + "HNaOH= -112.108 #in kcal\n", + "#CALCULATIONS\n", + "H298= HNaCl+HH2O -HHcl -HNaOH\n", + "#RESULTS\n", + "H298=round(H298,2)\n", + "print 'dH298=',H298,'kcal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.11,Page no.18" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dH= 5399.67 cal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T1=1000 #in K\n", + "T2=300 #in K\n", + "k1=6.0954 #in cal degˆ−1 moleˆ−1 \n", + "k2=3.2533*10**-3 #in cal degˆ−2 moleˆ−1\n", + "k3=-1.071*10**-6 #in cal degˆ−3 moleˆ−1\n", + "#CALCULATIONS\n", + "dH=k1*(T1-T2)+(k2*(T1**2-T2**2)/2)+(k3*(T1**3-T2**3)/3)\n", + "#RESULTS\n", + "dH=round(dH,2)\n", + "print 'dH=',dH,'cal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.12,Page no.18" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "H263= -74.6 cal gˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "dH273=-79.7 #in cal gˆ−1\n", + "T1=263 #in K\n", + "T2=273 #in K\n", + "dCp=-0.51 #in cal moleˆ−1 degˆ−1\n", + "#CALCULATIONS\n", + "H263=dH273+dCp*(T1-T2) \n", + "#RESULTS\n", + "print 'H263=',H263,'cal gˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 4.13,Page no.19" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dH= -119771.7 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "dH293=-115595.8 #in cal\n", + "T1=1500 #in K\n", + "T2=298 #in K\n", + "k1=-5.6146 #cal degˆ−1 moleˆ−1\n", + "k2=1.8931*10**-3 #cal degˆ−2 moleˆ−1\n", + "k3=4.723*10**-7 #cal degˆ−3 moleˆ−1 \n", + "#CALCULATIONS\n", + "dH=dH293+ k1*(T1-T2)+(k2*(T1**2-T2**2)/2)+(k3*(T1**3-T2**3)/3)\n", + "#RESULTS\n", + "dH=round(dH,2)\n", + "print 'dH=',dH,'cal'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter5_Second_and_Third_Law_of_Thermodynamics.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter5_Second_and_Third_Law_of_Thermodynamics.ipynb new file mode 100644 index 00000000..e1566f54 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter5_Second_and_Third_Law_of_Thermodynamics.ipynb @@ -0,0 +1,426 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter5 Second and Third Law of Thermodynamics" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.1, Page no.20" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "maximum work= 214.42 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "q2=1000 #in cal\n", + "T2=100 #in C\n", + "T1= 20 #in C\n", + "#CALCULATIONS\n", + "wmax= q2*(T2-T1)/(273.1+T2)\n", + "#RESULTS\n", + "wmax=round(wmax,2)\n", + "print 'maximum work=',wmax,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.2, Page no.20" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "entropy change per mole= 20.18 cal degˆ−1 moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "dH= 6896 #in cal moleˆ−1\n", + "T= 68.7 #in C\n", + "#CALCULATIONS\n", + "dS= dH/(273.1+T)\n", + "#RESULTS\n", + "dS=round(dS,2)\n", + "print 'entropy change per mole=',dS,'cal degˆ−1 moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.3, Page no.21" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "increase in entropy= 0.64 cal degˆ−1 mole ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Cp=6.09 #in cal degˆ−1 moleˆ−1\n", + "T1=30 #in C\n", + "T2=0 #in C\n", + "#CALCULATIONS\n", + "k=0.0452799815 #log10((273+T1)/(273+T2)))\n", + "dS=2.303*Cp*k\n", + "#RESULTS\n", + "dS=round(dS,2)\n", + "print 'increase in entropy=',dS,'cal degˆ−1 mole ˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.4, Page no.21" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "increase in entropy= 5.74 cal degˆ−1 mole^−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T1=25 #in C\n", + "T2=600 #in C\n", + "k1= 6.0954\n", + "k2= 3.2533*10**-3 #in K\n", + "k3= -10.71*10**-7 #in Kˆ−1\n", + "#CALCULATIONS\n", + "dS=k1*2.303*math.log10((273+T2)/(273+T1))+k2*(T2-T1)+(k3 /2)*((273+T2)**2-(273+T1)**2)\n", + "#RESULTS\n", + "dS=round(dS,2)\n", + "print 'increase in entropy=',dS,'cal degˆ−1 mole^−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.5, Page no.22" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "change in entropy= 2.76 cal degˆ−1 moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "n=2 #in mole\n", + "R=1.987 #in cal Kˆ−1 moleˆ−1\n", + "X1=0.5 #in atm\n", + "X2=0.5 #in atm\n", + "#CALCULATIONS\n", + "S=-2.303*n*R*(X1*math.log10(X1)+X2*math.log10(X2))\n", + "#RESULTS\n", + "S=round(S,2)\n", + "print 'change in entropy=',S,'cal degˆ−1 moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.6, Page no.22" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "change in entropy= -10.61 cal degˆ−1 moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "SH2O= 45.106 #in cal degˆ−1 moleˆ−1\n", + "SH2= 31.211 #in cal degˆ−1 moleˆ−1\n", + "SO2= 49.003 #in cal degˆ−1 moleˆ−1\n", + "#CALCULATIONS\n", + "dS= SH2O-SH2 -0.5*SO2\n", + "#RESULTS\n", + "dS=round(dS,2)\n", + "print 'change in entropy=',dS,'cal degˆ−1 moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.7, Page no.23" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "change in Gibbs free energy= -2727.33 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "n=2 #in moles\n", + "p=1 #in atm\n", + "p1=0.1 #in atm\n", + "T=25 #in C\n", + "R= 1.987 #in cal moleˆ−1 Kˆ−1\n", + "#CALCULATIONS \n", + "dG= n*R*2.303*math.log10(p1/p)*(273+T)\n", + "#RESULTS\n", + "dG=round(dG,2)\n", + "print 'change in Gibbs free energy=',dG,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.8, Page no.23" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "change in Gibbs free energy= -50.79 cal mole ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=1.987 #in cal moleˆ−1 Kˆ−1\n", + "T=-10 #in C\n", + "P1=2.149 #in mm\n", + "P2=1.950 #in mm\n", + "#CALCULATIONS\n", + "dG=R*2.303*(273+T)*math.log10(P2/P1)\n", + "#RESULTS\n", + "dG=round(dG,2)\n", + "print 'change in Gibbs free energy=',dG,'cal mole ˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.9, Page no.23" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "W= -741.151 cal moleˆ−1\n", + "qp= -9714.6 cal moleˆ−1\n", + "dE= -8973.449 cal moleˆ−1\n", + "dA= 741.151 cal moleˆ−1\n", + "dS= -26.04 cal degˆ−1 moleˆ−1\n", + "dG= 0.0 cal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T=100 #in C\n", + "R=1.987 #in cal moleˆ−1 Kˆ−1\n", + "H=539.7 #in cal gˆ−1\n", + "M=18 #in g moleˆ−1\n", + "#CALCULATIONS\n", + "w=-R*(273+T)\n", + "qp=-H*M\n", + "dE=qp-w\n", + "dA=-w\n", + "dS=qp/(273+T)\n", + "dG=qp -(273+T)*dS\n", + "#RESULTS\n", + "dS=round(dS,2)\n", + "print 'W=',w,'cal moleˆ−1'\n", + "print 'qp=',qp,'cal moleˆ−1'\n", + "print 'dE=',dE,'cal moleˆ−1'\n", + "print 'dA=',dA,'cal moleˆ−1'\n", + "print 'dS=',dS,'cal degˆ−1 moleˆ−1'\n", + "print 'dG=',dG,'cal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 5.10, Page no.24" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "W= 1373.28 cal moleˆ−1\n", + "q= 1373.28 cal moleˆ−1\n", + "dE= 0 cal moleˆ−1\n", + "dA= -1373.28 cal moleˆ−1\n", + "dS= 4.58 cal degˆ−1 moleˆ−1\n", + "dG= -1373.28 cal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=1.987 #in cal degˆ−1 moleˆ−1\n", + "T=27 #in C\n", + "V1=24.62 #in lit\n", + "V2=2.462 #in lit\n", + "#CALCULATIONS\n", + "wmax=2.303*R*(273.1+T)*math.log10(V1/V2)\n", + "dA=-wmax\n", + "dE=0\n", + "q=dE+wmax\n", + "dH=0\n", + "dG=-R*(273.1+T)*2.303\n", + "dS=dG/(273.1+T)\n", + "dS1=(dH-dG)/(273.1+T)\n", + "#RESULTS\n", + "wmax=round(wmax,2)\n", + "q=round(q,2)\n", + "dA=round(dA,2)\n", + "dS1=round(dS1,2)\n", + "dG=round(dG,2)\n", + "print 'W=',wmax,'cal moleˆ−1'\n", + "print 'q=',q,'cal moleˆ−1'\n", + "print 'dE=',dE,'cal moleˆ−1'\n", + "print 'dA=',dA,'cal moleˆ−1'\n", + "print 'dS=',dS1,'cal degˆ−1 moleˆ−1'\n", + "print 'dG=',dG,'cal moleˆ−1'" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter6_One_Component_Systems.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter6_One_Component_Systems.ipynb new file mode 100644 index 00000000..b2dbc759 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter6_One_Component_Systems.ipynb @@ -0,0 +1,225 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": { + "collapsed": true + }, + "source": [ + "# Chapter6 One Component Systems" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.1, Page no.26" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "vapour pressure using ideal gas = 175.647 mm\n", + "vapour pressure using equation = 142.673 mm\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables \n", + "G=28.6 #in gms\n", + "R=0.08205 #l−atm moleˆ−1 degˆ−1\n", + "T=30 #in Celsius\n", + "M=153.8 #in gms\n", + "v=20.01 #in litres\n", + "#CALCULATIONS\n", + "p=G*R*(273.1+T)*760/(M*v)\n", + "p1=p/(1+(p/760))\n", + "#RESULTS\n", + "p=round(p,3)\n", + "p1=round(p1,3)\n", + "print 'vapour pressure using ideal gas =',p,'mm'\n", + "print 'vapour pressure using equation =',p1,'mm'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.2, Page no.27" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "change in boling point of water per mm = 0.04 deg mmˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables \n", + "T=100 #in Celsius\n", + "Vv=30.199 #in l moleˆ−1\n", + "Vl=0.01878 #in l moleˆ−1\n", + "H=539.7 #in cal gˆ−1\n", + "m=18.01 #in g moleˆ−1\n", + "R=0.04129 #in l−atm cal ˆ−1\n", + "#CALCULATIONS\n", + "r=H*m*R*760/((273.1+T)*(Vv-Vl))\n", + "r1=1/r\n", + "#RESULTS\n", + "r1=round(r1,2)\n", + "print 'change in boling point of water per mm =',r1, 'deg mmˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.3, Page no.27" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "change in pressure per degree= -132.98 atm deg ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T=0 #in Celsius\n", + "H=79.7 #in cal gˆ−1\n", + "vd=-9.06*10**-5 #in l gˆ−1\n", + "R=0.04129 #in l−atm cal ˆ−1\n", + "#CALCULATIONS\n", + "r=H*R/((273.15+T)*vd)\n", + "#RESULTS\n", + "r=round(r,2)\n", + "print 'change in pressure per degree=',r,'atm deg ˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.4, Page no.27" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Heat of vapourization= 10582.14 cal moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "y1=32.47*10**-4\n", + "y2=34.71*10**-4\n", + "x1=1.625\n", + "x2=1.107\n", + "R=1.987 #in cal moleˆ−1 Kˆ−1\n", + "#CALCULATIONS\n", + "slope=(x2-x1)/(y2-y1)\n", + "Hvap=-slope *2.303*R\n", + "#RESULTS\n", + "Hvap=round(Hvap,2)\n", + "print 'Heat of vapourization=',Hvap,'cal moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 6.5, Page no.28" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "molar heat of vapourization = 7182 cal mole ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "H=342 #in cal moleˆ−1 gˆ−1\n", + "G=21 #in gms\n", + "T=60 #in C\n", + "R=1.987 #in cal / mol K\n", + "#CALCULATIONS\n", + "Hvap=G*H\n", + "P1=1/(math.exp(Hvap *9/(2.303*R*(273.1+T)*H)))\n", + "#RESULTS\n", + "print 'molar heat of vapourization =',Hvap,'cal mole ˆ−1'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter7_Solutions.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter7_Solutions.ipynb new file mode 100644 index 00000000..4ad45f81 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter7_Solutions.ipynb @@ -0,0 +1,180 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter7 Solutions" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.1,Page no.29" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "mole fraction of benzene vapour= 0.351 f\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "nb=0.4\n", + "pb=385 #in mm\n", + "nt=0.6\n", + "pt=139 #in mm\n", + "#CALCULATIONS\n", + "Pb=pb*nb\n", + "Pt=pt*nt\n", + "PT=Pb+Pt\n", + "Xt=Pt/PT\n", + "#RESULTS\n", + "Xt=round(Xt,3)\n", + "print 'mole fraction of benzene vapour=',Xt,'f'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.2,Page no.29" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "moles of carbon dioxide= 0.03 mole litre ˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "K=1.25*10**6\n", + "m=1000 #in gms\n", + "M=18.02 #in gms\n", + "#CALCULATIONS\n", + "nco2=760*m/(M*K)\n", + "#RESULTS\n", + "nco2=round(nco2,2)\n", + "print 'moles of carbon dioxide=',nco2,'mole litre ˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.3,Page no.30" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "mole fraction of benzene= 0.575 f\n", + "mole fraction of benzene vapour= 0.773 f\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Vp=1022.0 #in mm\n", + "Vp1=406.0 #in mm 5\n", + "#CALCULATIONS\n", + "Xb=(760-Vp1)/(Vp-Vp1)\n", + "Xb1=Vp*Xb/760\n", + "#RESULTS\n", + "Xb=round(Xb,3)\n", + "Xb1=round(Xb1,3)\n", + "print 'mole fraction of benzene=',Xb,'f'\n", + "print 'mole fraction of benzene vapour=',Xb1,'f'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 7.4,Page no.30" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "molecular weight of nitro −benzene= 123.63 g moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "P1=731.9 #in mm\n", + "P2=712.4 #in mm\n", + "Mb=18 #in gms\n", + "r=0.188\n", + "#CALCULATIONS\n", + "Ma=r*Mb*P2/(P1-P2)\n", + "#RESULTS\n", + "Ma=round(Ma,2)\n", + "print 'molecular weight of nitro −benzene=',Ma,'g moleˆ−1'" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter8_Properties_of_Dilute_Solutions.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter8_Properties_of_Dilute_Solutions.ipynb new file mode 100644 index 00000000..12201d3b --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter8_Properties_of_Dilute_Solutions.ipynb @@ -0,0 +1,249 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter8 Properties of Dilute Solutions" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.2, Pageno.32" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "molal boiling point constant= 0.513 f deg molalˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=1.987 #in cal /mole K\n", + "T=100.0 #in Celsius\n", + "M1=18.02 #in gms\n", + "Hvap=539.7 #cal gˆ−1\n", + "#CALCULATIONS\n", + "Kb=R*(273.1+T)**2*M1/(1000*M1*Hvap)\n", + "#RESULTS\n", + "Kb=round(Kb,3)\n", + "print 'molal boiling point constant=',Kb,'f deg molalˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.3, Pageno.32" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "molecular weight of dinitrozene = 168.67 g moleˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Kb=2.53 #in deg molalˆ−1\n", + "w2=1 #in gms\n", + "Tb=0.3 #in Celsius\n", + "w1=50 #in gms\n", + "#CALCULATIONS\n", + "M2=Kb*w2*1000/(Tb*w1)\n", + "#RESULTS\n", + "M2=round(M2,2)\n", + "print 'molecular weight of dinitrozene =',M2,'g moleˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.4, Pageno.33" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "boiling water of a solution= 0.569 deg\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "mu=5.0 #in gms\n", + "Mu=60.06 #in gms\n", + "mw=75.0 #in gms\n", + "#CALCULATIONS\n", + "Tb=0.513*mu*1000/(Mu*mw)\n", + "#RESULTS\n", + "Tb=round(Tb,3)\n", + "print 'boiling water of a solution=',Tb,'deg'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.5, Pageno.33" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kf of water= 1.859 deg molalˆ−1\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=1.987 #in cal moleˆ−1 Kˆ−1\n", + "T=0 #in Celsius units\n", + "M=18.02 #in gms\n", + "Hf=79.7 #in cal gˆ−1\n", + "#CALCULATIONS\n", + "Kf=R*(273.1+T)**2*M/(1000*M*Hf)\n", + "#RESULTS\n", + "Kf=round(Kf,3)\n", + "print 'Kf of water=',Kf,'deg molalˆ−1'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.6, Pageno.34" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "osmotic pressure of sucrose solution= 26.911 atm\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "M=18.02 #in g moleˆ−1\n", + "d=0.99564 #in g/ cc\n", + "R=0.08205 #in l−atm degˆ−1 moleˆ−1\n", + "T=30 #in Celsius\n", + "P1=31.824 #in mm\n", + "P10=31.207 # in mm\n", + "#CALCULATIONS\n", + "p=R*(273.15+T)*2.303*1000*d*math.log10(P1/P10)/M\n", + "#RESULTS\n", + "p=round(p,3)\n", + "print 'osmotic pressure of sucrose solution=',p,'atm'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 8.7, Pageno.34" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "osmotic pressure of sucrose solution= 24.86 atm\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=0.082 #in l−atm / mol ˆ−1 Kˆ−1\n", + "T=30 #in C\n", + "V=1 #in litres\n", + "#CALCULATIONS\n", + "p=R*(273.15+T)/V \n", + "#RESULTS\n", + "p=round(p,2)\n", + "print 'osmotic pressure of sucrose solution=',p,'atm'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/Chapter9_Chemical_Equilibria.ipynb b/Physical_Chemistry_by_D._Farrington/Chapter9_Chemical_Equilibria.ipynb new file mode 100644 index 00000000..3d6e3fd7 --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/Chapter9_Chemical_Equilibria.ipynb @@ -0,0 +1,797 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter9 Chemical Equilibria" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.1, Page no.35" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kc= 0.5002 lˆ2 moleˆ−2\n", + "Kx= 0.0164 e\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T=400 #in Celsius\n", + "R=0.08205 #in l−atm moleˆ−1 degˆ−1\n", + "Kp=1.64*10**-4\n", + "n=2.0\n", + "P=10 #in atm\n", + "#CALCULATIONS\n", + "Kc=Kp*(R*(273.1+T))**n\n", + "Kx=Kp*P**n\n", + "#RESULTS\n", + "Kc=round(Kc,4)\n", + "print 'Kc=',Kc,'lˆ2 moleˆ−2'\n", + "print 'Kx=',Kx,'e'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.2, Page no.35" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "degree of dissociation= 0.1846\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=0.08205 #in l−atm moleˆ−1 degˆ−1\n", + "T=25 #in Celsius\n", + "g=1.588 #in gms\n", + "P=1 #in atm\n", + "V=0.5 #litres\n", + "M1=92.02 #g moleˆ−1 \n", + "#CALCULATIONS\n", + "M2=R*(273.1+T)*g/(P*V)\n", + "a=(M1-M2)/M2 \n", + "#RESULTS\n", + "a=round(a,4)\n", + "print 'degree of dissociation=',a" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.3, Page no.36" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kp= 0.14\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "P=1 #atm\n", + "a=18.46 #in percentage\n", + "P1=0.5 #atm\n", + "#CALCULATIONS\n", + "Kp=P*4*(a/100)**2/(1-(a/100)**2)\n", + "#RESULTS\n", + "Kp=round(Kp,2)\n", + "print 'Kp=',Kp" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.4, Page no.36" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kp= 1.83\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "M1=208.3 #gms\n", + "g=2.69 #gms\n", + "R=0.08205 #l−atm moleˆ−1 degˆ−1\n", + "T=250 #Celsius\n", + "P=1 #atm\n", + "V=1 #lit\n", + "#CALCULATIONS\n", + "M2=g*R*(273.1+T)/(P*V)\n", + "a=(M1-M2)/M2\n", + "Kp=a**2*P/(1-a**2)\n", + "#RESULTS\n", + "Kp=round(Kp,3)\n", + "print 'Kp=',Kp" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.5, Page no.37" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "degree of dissociation= 0.574\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "x=0.0574 #mole\n", + "n=0.1 #mole\n", + "#CALCULATIONS\n", + "a=x/n\n", + "#RESULTS\n", + "print 'degree of dissociation=',a" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.6, Page no.37" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "x= 0.341 mole\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=0.08205 #l−atm moleˆ−1 degˆ−1\n", + "T=250 #Celsius\n", + "n=0.1 #mole\n", + "Kp=1.78\n", + "#CALCULATIONS\n", + "x=n+(n**2*R*(273.1+T)/Kp)\n", + "#RESULTS\n", + "x=round(x,3)\n", + "print 'x=',x,'mole'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.7, Page no.38" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "P= 3.668 atm\n" + ] + } + ], + "source": [ + "import math\n", + "from math import sqrt\n", + "#initialisation of variables\n", + "Ppcl5=1 #atm\n", + "Kp=1.78 \n", + "#CALCULATIONS\n", + "Ppcl2=sqrt(Kp)\n", + "P=2*Ppcl2+Ppcl5\n", + "#RESULTS\n", + "P=round(P,3)\n", + "print 'P=',P,'atm'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.8, Page no.38" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kp= 42.72 atm\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Kp=1.78\n", + "a=0.2\n", + "#CALCULATIONS\n", + "P=Kp*(1-a**2)/a**2\n", + "#RESULTS\n", + "print 'Kp=',P,'atm'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.10, Page no.38" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "K= 4.001\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "n=0.6667 #mole\n", + "#CALCULATIONS\n", + "K=n**2/((1-n)**2)\n", + "#RESULTS\n", + "K=round(K,3)\n", + "print 'K=',K" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.11, Page no.39" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dG= 1160.57 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "pN2O4=0.141 #atm\n", + "pNO2=1 #atm\n", + "R=1.987 #cal moleˆ−1 degˆ−1\n", + "T=25 #Celsius\n", + "#CALCULATIONS\n", + "dG=-R*2.303*(273.1+T)*math.log10(pN2O4/pNO2**2)\n", + "#RESULTS\n", + "dG=round(dG,3)\n", + "print 'dG=',dG,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.12, Page no.40" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dG= -1160.57 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "pN2O4=1 #atm \n", + "pNO2=0.141 #atm \n", + "R=1.987 #cal moleˆ−1 degˆ−1 \n", + "T=25 #C \n", + "#CALCULATIONS \n", + "dG=-R*2.303*(273.1+T)*math.log10(pN2O4/pNO2) \n", + "#RESULTS \n", + "dG=round(dG,3)\n", + "print 'dG=',dG,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.13, Page no.40" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dG= -3526.964 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "Kc=2.7*10**2 \n", + "R= 1.987 #cal moleˆ−1 degˆ−1 \n", + "T= 43.9 #c \n", + "#CALCULATIONS \n", + "dG=-R*(273.1+T)*2.303*math.log10(Kc) \n", + "#RESULTS\n", + "dG=round(dG,3)\n", + "print 'dG=',dG,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.14, Page no.40" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kp= 6.30787913713e-05 e\n", + "ANSWER IN THE TEXTBOOK IS WRONG\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "dH=-17.889 # cal degˆ−1 \n", + "T=25 #C \n", + "dS=-19.28 # cal degˆ−1 \n", + "R=1.987 # cal moleˆ−1 degˆ−1 \n", + "#CALCULATIONS \n", + "dG=dH-dS*(273.1+T) \n", + "Kp=10**(dG/(-R*(273.1+T)*2.303)) \n", + "#RESULTS \n", + "print 'Kp=',Kp,'e'\n", + "print 'ANSWER IN THE TEXTBOOK IS WRONG'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.15, Page no.40" + ] + }, + { + "cell_type": "code", + "execution_count": 15, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kp= 1.01157190896 e\n", + "ANSWER IN THE TEXTBOOK IS WRONG\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "HCO2=-94.2598 # kcal\n", + "HH2=0 # kcal\n", + "HCO=-32.8079 # kcal\n", + "HH2O=-54.6357 # kcal\n", + "R=1.987 # cal degˆ−1 moleˆ−1\n", + "T=25 #C\n", + "#CALCULATIONS \n", + "Kp=10**(-(HCO2 -HCO -HH2O)/(R*2.303*(273.1+T)))\n", + "#RESULTS \n", + "print 'Kp=',Kp,'e' \n", + "print 'ANSWER IN THE TEXTBOOK IS WRONG'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.16, Page no.41" + ] + }, + { + "cell_type": "code", + "execution_count": 16, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "dG= -202.666 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "G0=1161.0 # cal\n", + "R=1.987 # cal moleˆ−1 degˆ−1\n", + "T=25.0 #C\n", + "P=1.0 #atm\n", + "P1=10.0 #atm\n", + "#CALCULATIONS\n", + "dG=G0+R*(273.0+T)*2.303*math.log10(P**2/P1) \n", + "#RESULTS \n", + "dG=round(dG,3)\n", + "print 'dG=',dG,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.17, Page no.41" + ] + }, + { + "cell_type": "code", + "execution_count": 17, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "enthalpy change= 43273.17 cal\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "K2500=3.6*10**-3\n", + "K2000=4.08*10** -4 \n", + "R=1.987 # cal moleˆ−1 Kˆ−1\n", + "T1=2500 #K\n", + "T2=2000 #K\n", + "#CALCULATIONS\n", + "dH=math.log10(K2500/K2000)*2.303*R*T1*T2/(T1-T2) \n", + "#RESULTS \n", + "dH=round(dH,3)\n", + "print 'enthalpy change=',dH,'cal'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.18, Page no.42" + ] + }, + { + "cell_type": "code", + "execution_count": 18, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "K800= 3.596\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "dH=-10200 #cal\n", + "R=1.987 # cal degˆ−1 moleˆ−1\n", + "T1=690 #K\n", + "T2=800 #K\n", + "KT1=10\n", + "#CALCULATIONS\n", + "KT2=KT1*10**(dH*(T2-T1)/(2.303*R*T1*T2)) \n", + "#RESULTS \n", + "KT2=round(KT2,3)\n", + "print 'K800=',KT2" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.19, Page no.42" + ] + }, + { + "cell_type": "code", + "execution_count": 19, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Kp= 1.953\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T=1000.0 #K \n", + "R=1.987 # cal moleˆ−1 Kˆ−1 \n", + "G=-1330.0 # cal moleˆ−1 \n", + "#CALCULATIONS \n", + "Kp=10.0**(G/(-R*T*2.303)) \n", + "#RESULTS\n", + "Kp=round(Kp,3)\n", + "print 'Kp=',Kp" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.20, Page no.43" + ] + }, + { + "cell_type": "code", + "execution_count": 20, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "percent dissaciated= 97.304 percent\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "from math import sqrt\n", + "Kp=1.78 \n", + "P=0.1 #atm \n", + "#CALCULATIONS \n", + "a=sqrt(Kp/(Kp+P))*100 \n", + "#RESULTS \n", + "a=round(a,3)\n", + "print 'percent dissaciated=',a,'percent'" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.21, Page no.43" + ] + }, + { + "cell_type": "code", + "execution_count": 21, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "equilibrium constant= 0.00000072\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "R=1.987 # cal moleˆ−1 Kˆ−1 \n", + "T=2000 #K \n", + "dH= 117172 # cal moleˆ−1 \n", + "H=-43 # cal moleˆ−1 \n", + "n=2 \n", + "H1=-56.12 # cal moleˆ−1 \n", + "#CALCULATIONS 1\n", + "K=10**( -(1/(2.303*R))*((dH/T)+n*H-H1))\n", + "#RESULTS\n", + "print 'equilibrium constant=',format(K, '.8f')" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 9.22, Page no.43" + ] + }, + { + "cell_type": "code", + "execution_count": 22, + "metadata": { + "collapsed": false + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "ANSWER IN TEXTBOOK IS WRONG\n" + ] + } + ], + "source": [ + "import math\n", + "#initialisation of variables\n", + "T=25.0 #C \n", + "R=1.987 # cal moleˆ−1 Kˆ−1 \n", + "n=2.0 \n", + "dH=-21.840 # cal moleˆ−1 \n", + "HHCl=-37.73 # cal moleˆ−1 \n", + "HH2=-24.44 # cal moleˆ−1 \n", + "HCl=-45.95 # cal moleˆ−1 1\n", + "#CALCULATIONS\n", + "K=10**(( -1/(2.303*R))*((dH*n/(273.15+T))+n*HHCl -HH2 - HCl))\n", + "print 'ANSWER IN TEXTBOOK IS WRONG'" + ] + } + ], + "metadata": { + "anaconda-cloud": {}, + "kernelspec": { + "display_name": "Python [Root]", + "language": "python", + "name": "Python [Root]" + }, + "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 +} diff --git a/Physical_Chemistry_by_D._Farrington/screenshots/2.png b/Physical_Chemistry_by_D._Farrington/screenshots/2.png Binary files differnew file mode 100644 index 00000000..85907f1b --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/screenshots/2.png diff --git a/Physical_Chemistry_by_D._Farrington/screenshots/5.png b/Physical_Chemistry_by_D._Farrington/screenshots/5.png Binary files differnew file mode 100644 index 00000000..3b186c2d --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/screenshots/5.png diff --git a/Physical_Chemistry_by_D._Farrington/screenshots/8.png b/Physical_Chemistry_by_D._Farrington/screenshots/8.png Binary files differnew file mode 100644 index 00000000..a6b866bc --- /dev/null +++ b/Physical_Chemistry_by_D._Farrington/screenshots/8.png diff --git a/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/chapter2.ipynb b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/chapter2.ipynb new file mode 100644 index 00000000..5bd122ad --- /dev/null +++ b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/chapter2.ipynb @@ -0,0 +1,337 @@ +{ + "metadata": { + "name": "", + "signature": "sha256:74a00fabf3de3a229499fd336c46d9a546ea42ad7cb4fbe98a92a6ea72f21fa8" + }, + "nbformat": 3, + "nbformat_minor": 0, + "worksheets": [ + { + "cells": [ + { + "cell_type": "heading", + "level": 1, + "metadata": {}, + "source": [ + "Chapter 2: Bonding in Solids" + ] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.1,Page number 62" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "epsilon_0 = 8.854*10**-12; # Absolute electrical permittivity of free space, F/m\n", + "e = 1.6*10**-19; # Energy equivalent of 1 eV, eV/J\n", + "r = 3.147*10**-10; # Nearest neighbour distance for KCl, m\n", + "n = 9.1; # Repulsive exponent of KCl\n", + "A = 1.748; # Madelung constant for lattice binding energy\n", + "E = A*e**2/(4*math.pi*epsilon_0*r)*(n-1)/n/e; # Binding energy of KCl, eV\n", + "print\"The binding energy of KCl = \",round(E,4),\"eV\";\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The binding energy of KCl = 7.10982502818 eV\n" + ] + } + ], + "prompt_number": 5 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.2,Page number 62" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "\n", + "epsilon_0 = 8.854*10**-12; # Absolute electrical permittivity of free space, F/m\n", + "N = 6.023*10**23; # Avogadro's number\n", + "e = 1.6*10**-19; # Energy equivalent of 1 eV, eV/J\n", + "a0 = 5.63*10**-10; # Lattice parameter of NaCl, m\n", + "r0 = a0/2; # Nearest neighbour distance for NaCl, m\n", + "n = 8.4; # Repulsive exponent of NaCl\n", + "A = 1.748; # Madelung constant for lattice binding energy\n", + "E = A*e**2/(4*pi*epsilon_0*r0)*(n-1)/n/e; # Binding energy of NaCl, eV\n", + "print\"The binding energy of NaCl = \",round(E*N*e/(4.186*1000),4),\"kcal/mol\" ;\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The binding energy of NaCl = 181.1005 kcal/mol\n" + ] + } + ], + "prompt_number": 7 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.3,Page number 62" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "\n", + "epsilon_0 = 8.854*10**-12; # Absolute electrical permittivity of free space, F/m\n", + "N = 6.023*10**23; # Avogadro's number\n", + "e = 1.6*10**-19; # Energy equivalent of 1 eV, eV/J\n", + "E = 162.9*10**3; # Binding energy of KCl, cal/mol\n", + "n = 8.6; # Repulsive exponent of KCl\n", + "A = 1.747; # Madelung constant for lattice binding energy\n", + "# As lattice binding energy, E = A*e**2/(4*%pi*epsilon_0*r0)*(n-1)/n, solving for r0\n", + "r0 = A*N*e**2/(4*pi*epsilon_0*E*4.186)*(n-1)/n; # Nearest neighbour distance of KCl, m\n", + "print\"The nearest neighbour distance of KCl = \",round(r0*10**10,4),\"angstorm\";\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The nearest neighbour distance of KCl = 3.1376 angstorm\n" + ] + } + ], + "prompt_number": 12 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.4,Page number 63" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "\n", + "epsilon_0 = 8.854*10**-12; # Absolute electrical permittivity of free space, F/m\n", + "N = 6.023*10**23; # Avogadro's number\n", + "e = 1.6*10**-19; # Energy equivalent of 1 eV, eV/J\n", + "E = 152*10**3; # Binding energy of CsCl, cal/mol\n", + "n = 10.6; # Repulsive exponent of CsCl\n", + "A = 1.763; # Madelung constant for lattice binding energy\n", + "\n", + "# As lattice binding energy, E = A*e**2/(4*pi*epsilon_0*r0)*(n-1)/n, solving for r0\n", + "r0 = A*N*e**2/(4*pi*epsilon_0*E*4.186)*(n-1)/n; # Nearest neighbour distance of CsCl, m\n", + "print\"The nearest neighbour distance of CsCl = \",round(r0*10**10,4),\"angstrom\";\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The nearest neighbour distance of CsCl = 3.4776 angstrom\n" + ] + } + ], + "prompt_number": 13 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.5,Page number 63" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "\n", + "epsilon_0 = 8.854*10**-12; # Absolute electrical permittivity of free space, F/m\n", + "N = 6.023*10**23; # Avogadro's number\n", + "e = 1.6*10**-19; # Energy equivalent of 1 eV, eV/J\n", + "r0 = 6.46*10**-10; # Nearest neighbour distance of NaI\n", + "E = 157.1*10**3; # Binding energy of NaI, cal/mol\n", + "A = 1.747; # Madelung constant for lattice binding energy\n", + "\n", + "# As lattice binding energy, E = -A*e**2/(4*pi*epsilon_0*r0)*(n-1)/n, solving for n\n", + "n = 1/(1+(4.186*E*4*pi*epsilon_0*r0)/(N*A*e**2)); # Repulsive exponent of NaI\n", + "print\"\\nThe repulsive exponent of NaI = \",round(n,4);" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "\n", + "The repulsive exponent of NaI = 0.363\n" + ] + } + ], + "prompt_number": 15 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.6,Page number 63" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "\n", + "e = 1.6*10**-19; # Energy equivalent of 1 eV, eV/J\n", + "a0 = 2.8158*10**-10; # Nearest neighbour distance of solid\n", + "A = 1.747; # Madelung constant for lattice binding energy\n", + "n = 8.6; # The repulsive exponent of solid\n", + "c = 2; # Structural factor for rocksalt\n", + "# As n = 1 + (9*c*a0**4)/(K0*e**2*A), solving for K0\n", + "K0 = 9*c*a0**4/((n-1)*e**2*A); # Compressibility of solid, metre square per newton\n", + "print\"The compressibility of the solid = \", \"{0:.3e}\".format(K0),\"metre square per newton\";" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The compressibility of the solid = 3.329e-01 metre square per newton\n" + ] + } + ], + "prompt_number": 18 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.7,Page number 69" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "\n", + "chi_diff = 1; # Electronegativity difference between the constituent of elements of solid\n", + "percent_ion = 100*(1-math.e**(-(0.25*chi_diff**2))); # Percentage ionic character present in solid given by Pauling\n", + "print\"The percentage ionic character present in solid = \",round(percent_ion,2),\"percent \";\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The percentage ionic character present in solid = 22.12 percent \n" + ] + } + ], + "prompt_number": 20 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example 2.8,Page number 69" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#Given Data\n", + "\n", + "Eh_GaAs = 4.3; # Homopolar gap of GaAs compound, eV\n", + "C_GaAs = 2.90; # Ionic gap of GaAs compound, eV\n", + "Eh_CdTe = 3.08; # Homopolar gap of CdTe compound, eV\n", + "C_CdTe = 4.90; # Ionic gap of CdTe compound, eV\n", + "\n", + "fi_GaAs = C_GaAs**2/(Eh_GaAs**2 + C_GaAs**2);\n", + "fi_CdTe = C_CdTe**2/(Eh_CdTe**2 + C_CdTe**2);\n", + "print\"The fractional ionicity of GaAs = \",round(fi_GaAs,4);\n", + "print\"The fractional ionicity of CdTe = \",round(fi_CdTe,4);\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "The fractional ionicity of GaAs = 0.3126\n", + "The fractional ionicity of CdTe = 0.7168\n" + ] + } + ], + "prompt_number": 3 + }, + { + "cell_type": "code", + "collapsed": false, + "input": [], + "language": "python", + "metadata": {}, + "outputs": [] + } + ], + "metadata": {} + } + ] +}
\ No newline at end of file diff --git a/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/Plot_of_ln_sigma_vs_1T.png b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/Plot_of_ln_sigma_vs_1T.png Binary files differnew file mode 100644 index 00000000..70837002 --- /dev/null +++ b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/Plot_of_ln_sigma_vs_1T.png diff --git a/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/The_binding_energy.png b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/The_binding_energy.png Binary files differnew file mode 100644 index 00000000..2a7f3689 --- /dev/null +++ b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/The_binding_energy.png diff --git a/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/The_lattice_parameter_of_fcc_strucure.png b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/The_lattice_parameter_of_fcc_strucure.png Binary files differnew file mode 100644 index 00000000..d14e7c7d --- /dev/null +++ b/Solid_State_Physics_Principles_And_Applications_by_R._Asokamani/screenshots/The_lattice_parameter_of_fcc_strucure.png diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH2.ipynb b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH2.ipynb new file mode 100755 index 00000000..1adc4757 --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH2.ipynb @@ -0,0 +1,94 @@ +{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 2:Important terminologies in Thermodynamics "
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.1,Page no:13"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "m=25.0 \t\t\t\t#weight of water vapour [grams]\n",
+ "w=18.0 \t\t\t\t#molecular weight of water vapour [grams/mol]\n",
+ "T=9.69 \t\t\t\t#increase in temperature [K]\n",
+ "Qp=0.45 \t\t\t#heat supplied at constant pressure[KJ]\n",
+ "\n",
+ "n=m/w \t\t\t\t#no. of moles of water vapour\n",
+ "Cp=Qp/(n*T) \t\t\t#specific heat capacity at constant pressure[KJ]\n",
+ "Cp=Cp*1000\t\t\t#specific heat capacity at constant pressure[J]\n",
+ "\n",
+ "print\"The specific heat capacity at constant pressure =\",round(Cp,2),\"J K^-1 mol^-1\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The specific heat capacity at constant pressure = 33.44 J K^-1 mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 2.2,Page no:14"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "import math\n",
+ "m=16.0 \t\t\t\t#weight of oxygen [grams]\n",
+ "w=32.0 \t\t\t\t#molecular weight of oxygen [grams/mol]\n",
+ "T=300.0 \t\t\t\t#Temperature during compression [K]\n",
+ "P1=1.0 \t\t\t\t#initial pressure of process [atm]\n",
+ "P2=100.0 \t\t\t\t#final pressure of process[atm]\n",
+ "R=8.314 \t\t\t#Universal gas constant [J/K/mol]\n",
+ "n=m/w \t\t\t\t#no. of moles of oxygen\n",
+ "W=-n*R*T*math.log(P1/P2) \n",
+ "print\"Mininmum work done to compress oxygen =\",round(W),\"J(approx)\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Mininmum work done to compress oxygen = 5743.0 J(approx)\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH3.ipynb b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH3.ipynb new file mode 100755 index 00000000..fa64788f --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH3.ipynb @@ -0,0 +1,828 @@ +{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 3:The first Law of Thermodynamics"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.1,Page no:18"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "V1=14 \t\t\t\t#initial volume of cylinder in m3\n",
+ "V2=9 \t\t\t\t#final volume of cylinder in m3\n",
+ "P=2000 \t\t\t\t#pressure during the operation in N/m2\n",
+ "U=(-6000) \t\t\t#internal energy of the system in J\n",
+ "W=-P*(V2-V1) \t\t\t#work done during the operation in J\n",
+ "Q=U-W \t\t\t\t#energy tranfered in form of heat in J\n",
+ "print\"energy tranfered in form of heat is\",Q,\"J\"\n",
+ " "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "energy tranfered in form of heat is -16000 J\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.2,Page no:18"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "R=8.314 \t\t\t\t#universal gas constant [J/K/mol]\n",
+ "T=300\t\t\t\t\t#temperture for the process [K]\n",
+ "U=0 \t\t\t\t\t#change in internal energy [J]\n",
+ "V1=2.28 \t\t\t\t#initial volume [m3]\n",
+ "V2=4.56 \t\t\t\t#final volume[m3]\n",
+ "import math\n",
+ "W=2.303*R*T*math.log10(V2/V1) \t\t#work done during the process[J]\n",
+ "Q=W \t\t\t\t\t#heat lost or gained by the system[J]\n",
+ "print\"The heat gained by the system is\",round(Q),\"J mol^-1\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The heat gained by the system is 1729.0 J mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 22
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.3,Page no:19"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "H=29.2 \t\t\t\t\t#latent heat of vaporisation[KJ/mol]\n",
+ "T=332 \t\t\t\t\t#temperature of the system[K]\n",
+ "R=8.314 \t\t\t\t#universal gas constant [J/K/mol]\n",
+ "Qp=H \t\t\t\t\t#at constant pressure [KJ]\n",
+ "W=-R*0.001*T \t\t\t\t#workdone [KJ]\n",
+ "U=Qp+W \t\t\t\t\t#change in internal energy[KJ]\n",
+ "print\"Heat absorbed by the bromine vapours is\",Qp,\"KJ\"\n",
+ "print\"\\nWorkdone during the process is\",round(W,2),\"KJ\"\n",
+ "print\"\\nChange in internal energy of the system is\",round(U,2),\"KJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Heat absorbed by the bromine vapours is 29.2 KJ\n",
+ "\n",
+ "Workdone during the process is -2.76 KJ\n",
+ "\n",
+ "Change in internal energy of the system is 26.44 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.4,Page no:20"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "print\"C7H16(l) + 11O2(g) -> 7CO2(g) + 8H2O(l)\" \n",
+ "n=-4 \t\t\t\t#change in no. of moles when reaction proceeds from reactants to \t\t\t\tproducts\n",
+ "T=298 \t\t\t\t#temperature of the process [K]\n",
+ "R=8.314 \t\t\t#universal gas constant [J/K/mol]\n",
+ "Qv=-4800 \t\t\t#heat energy at constant volume [KJ]\n",
+ "U=Qv \t\t\t\t#change in internal energy of system [KJ]\n",
+ "H=U+n*R*0.001*T \t\t#change in enthalpy of the system[KJ]\n",
+ "print\"the change in enthalpy of system is\",round(H,2),\"kJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C7H16(l) + 11O2(g) -> 7CO2(g) + 8H2O(l)\n",
+ "the change in enthalpy of system is -4809.91 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.5,Page no:21"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "n=1 \t\t\t\t#number of moles of an given ideal gas\n",
+ "T=298 \t\t\t\t#temperature for the process[K]\n",
+ "V1=8.3 \t\t\t\t#initial volume of the ideal gas[m3]\n",
+ "V2=16.8 \t\t\t#final volume of the ideal gas[m3]\n",
+ "R=8.314 \t\t\t#universal gas constant[J#K#mol]\n",
+ "import math\n",
+ "W=-2.303*R*T*math.log10(V2/V1) #[J]\n",
+ "Q=-W \t\t\t\t#[J]\n",
+ "print\"H=U+PV ,where U is change in internal energy which is zero due to isothermal process\" \n",
+ "print\"PV where V is change in volume of system ,PV=RT & RT==0 since T i.e change in temp is zero for system\" \n",
+ "print\"Therefore,the change in enthalpy is 0J\" \n",
+ "print\"The workdone by system is\",round(W,1),\"J mol^-1\"\n",
+ "print\"\\nThe heat evolved is\",round(Q,1),\"J mol^-1\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "H=U+PV ,where U is change in internal energy which is zero due to isothermal process\n",
+ "PV where V is change in volume of system ,PV=RT & RT==0 since T i.e change in temp is zero for system\n",
+ "Therefore,the change in enthalpy is 0J\n",
+ "The workdone by system is -1747.3 J mol^-1\n",
+ "\n",
+ "The heat evolved is 1747.3 J mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.6,Page no:24"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T1=323 \t\t\t#intial temperature of water[K]\n",
+ "T2=373 \t\t\t#final temperature of water[K]\n",
+ "Cp=75.29 \t\t#specific heat of water[J/K/mol]\n",
+ "w=100.0 \t\t\t#weight of water[g]\n",
+ "mol_wt=18.0 \t\t#molecular weight of water[g/mol]\n",
+ "n=w/mol_wt \t\t#no. of moles of water[moles]\n",
+ "H=(n*Cp*(T2-T1))*0.001 \t#change in enthalpy of water[J]\n",
+ "print\"The change in enthalpy of water is\",round(H,2),\"kJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The change in enthalpy of water is 20.91 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.7,Page no:29"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"SO2 + 0.5O2 -> SO3\"\n",
+ "U=-97030 \t\t\t#heat of reaction[J]\n",
+ "n=1-(1+0.5) \t\t\t#change in no. of moles \n",
+ "R=8.314 \t\t\t#universal gas constant[J/K/mol]\n",
+ "T=298 \t\t\t\t#temperature during the reaction[K]\n",
+ "H=U+n*R*T \t\t\t#change inenthalpy of reaction[J]\n",
+ "print\"The change in enthalpy of reaction is\",round(H),\"J(approx)\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "SO2 + 0.5O2 -> SO3\n",
+ "The change in enthalpy of reaction is -98269.0 J(approx)\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.8,Page no:29"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"i.C(s) + O2(g) -> CO2(g)\"\n",
+ "H1=-393.5 \t\t#change in enthalpy [KJ/mol]\n",
+ "T1=298 \t\t\t#temperature [K]\n",
+ "n1=0 \t\t\t#change in no. of moles in reaction moving in forward direction\n",
+ "R=0.008314 \t\t#universal gas constant [KJ/K/mol]\n",
+ "\n",
+ "U1=H1-n1*R*T1 \t\t#change in internal energy [KJ]\n",
+ "print\"The change in internal energy is\",round(U1,1),\"KJ/mol\"\n",
+ "\n",
+ "print\"ii.C(s) + 0.5O2 -> CO(g)\" \n",
+ "H2=-110.5 \t\t#change in enthalpy[KJ/mol]\n",
+ "T2=298 \t\t\t#temperature[K]\n",
+ "n2=1-0.5 \t\t#change in no. of moles in reaction moving in forward direction\n",
+ "R=0.008314 \t\t#universal gas constant [KJ/K/mol]\n",
+ "\n",
+ "U2=H2-n2*R*T2 \t\t#change in internal energy [KJ]\n",
+ "print\"The change in internal energy is\",round(U2,3),\"KJ/mol\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "i.C(s) + O2(g) -> CO2(g)\n",
+ "The change in internal energy is -393.5 KJ/mol\n",
+ "ii.C(s) + 0.5O2 -> CO(g)\n",
+ "The change in internal energy is -111.739 KJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.9,Page no:30"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"The standard heat of combustion of\"\n",
+ "print\"2C6H6(l)+ 15O2(g)-> 12 CO2(g)+ 6 H2O(l)\" \n",
+ "print\"H1(standard heat of combustion)=-6536 KJ/mol\" \n",
+ "H1=-6536 \t\t\t#standard heat of combustion [KJ/mol]\n",
+ "print\"C6H6(l)+ 7.5 O2(g)-> 6 CO2(g)+ 6 H2O(l)\" \n",
+ "H2=H1/2 \t\t\t#standard heat of combustion[KJ/mol]\n",
+ "print\"H2(standard heat of combustion for 1 mole of C6H6)=\",H2,\"kJ/mol\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The standard heat of combustion of\n",
+ "2C6H6(l)+ 15O2(g)-> 12 CO2(g)+ 6 H2O(l)\n",
+ "H1(standard heat of combustion)=-6536 KJ/mol\n",
+ "C6H6(l)+ 7.5 O2(g)-> 6 CO2(g)+ 6 H2O(l)\n",
+ "H2(standard heat of combustion for 1 mole of C6H6)= -3268 kJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.10,Page no:32"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"N2(g)+3H2(g)-> 2NH3(g)\" \n",
+ "H=-92.22 \t\t\t#standard heat of reaction [KJ/mol]\n",
+ "H1=H/2 \t\t\t\t#standard heat of formation of 1 mole [KJ/mol]\n",
+ "print\"H(heat of formation of 1 mole of product)=\",H1,\"kJ mol^-1\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "N2(g)+3H2(g)-> 2NH3(g)\n",
+ "H(heat of formation of 1 mole of product)= -46.11 kJ mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.11,Page no:32"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "print\"C2H5OH(l)+3O2(g)->2CO2(g)+3H2O(l)\" \n",
+ "T=298 \t\t\t\t#temperature during the reaction[K]\n",
+ "Hw=-285.83 \t\t\t#standard heat of formation of liquid water [KJ/mol]\n",
+ "He=-277.69 \t\t\t#standard heat of formation of liquid ethanol[KJ/mol]\n",
+ "Hco2=-393.51 \t\t\t#standard heat of formation of carbon dioxide[KJ/mol]\n",
+ "Ho2=0 \t\t\t\t#standard heat of formation of oxygen gas[KJ/mol]\n",
+ "H=2*Hco2+3*Hw-He-3*Ho2 \t\t#standard heat of reaction\n",
+ "print\"H(standard heat of reaction)=\",H,\"kJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C2H5OH(l)+3O2(g)->2CO2(g)+3H2O(l)\n",
+ "H(standard heat of reaction)= -1366.82 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.12,Page no:33"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "print\"CO(g)+NO(g)->0.5N2(g)+CO2(g)\" \n",
+ "Hrxn=-374 \t\t#standard heat of reaction[KJ/mol]\n",
+ "Hno=90.25 \t\t#standard heat of formation of NO[KJ/mol]\n",
+ "Hco2=-393.51 \t\t#standard heat of formation of CO2[KJ/mol]\n",
+ "Hn2=0 \t\t\t#standard heat of formation of N2[KJ/mol]\n",
+ "T=298 \t\t\t#temperature of reaction [K]\n",
+ "Hco=0.5*Hn2+Hco2-Hno-Hrxn \t#standard heat of formation of CO[KJ/mol]\n",
+ "print\"Hco(standard heat of formation)=\",Hco,\"kJ mol^-1\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "CO(g)+NO(g)->0.5N2(g)+CO2(g)\n",
+ "Hco(standard heat of formation)= -109.76 kJ mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.13,Page no:34"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "H1=-29.6 \t\t#the standard heat of hydrogenation of gaseous propylene to propane[Kcal]\n",
+ "H2=-530.6 \t\t#the heat of combustion of propane[Kcal] \n",
+ "H3=-94.0 \t\t#the heat of formation of carbon dioxide[Kcal]\n",
+ "H4=-68.3 \t\t#the heat of formation of liquid water[Kcal]\n",
+ "\n",
+ "\n",
+ "print\"C3H6(g)+4.5O2(g)->3CO2(g)+3H2O(l)\" \n",
+ "H5=(3*H3+4*H4)-(H1+H2)#[Kcal]\n",
+ "print\"\\n H(standard heat of combustion)=\",H5,\"Kcal\"\n",
+ "print\"3C(s)+3H2(g)->C3H6(g)\" \n",
+ "H6=-H5+3*H3+3*H4 #[Kcal]\n",
+ "print\"\\n H(standard heat of formation)=\",H6,\"Kcal\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C3H6(g)+4.5O2(g)->3CO2(g)+3H2O(l)\n",
+ "\n",
+ " H(standard heat of combustion)= 5.0 Kcal\n",
+ "3C(s)+3H2(g)->C3H6(g)\n",
+ "\n",
+ " H(standard heat of formation)= -491.9 Kcal\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.14,Page no:34"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "H1=-114.1 \t\t\t#standard heat of reaction:2NO(g)+O2(g)->2NO2(g) [KJ/mol]\n",
+ "H2=-110.2 \t\t\t#standard heat of reaction:4NO2(g)+O2(g)->2N2O5(g) [KJ/mol]\n",
+ "H3=180.5 \t\t\t#standard heat of reaction:N2(g)+O2(g)->2NO(g) [KJ/mol]\n",
+ "\n",
+ "\t#reacton:N2(g)+2.5O2(g)->N2O5(g)\n",
+ "H4=(2*H1+H2+2*H3)/2 \t\t#standard heat of formation of N2O5[KJ/mol]\n",
+ "print\"H(standard heat of formation of N2O5)=\",H4,\"kJ/mol\" "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "H(standard heat of formation of N2O5)= 11.3 kJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.15,Page no:35"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "Hc=-5645 \t\t#standard enthalpy of combustion of \t\t\treaction:C12H22O11(s)+12O2(g)->12CO2(g)+11H2O(l) [KJ/mol]\n",
+ "Hf1=-393.51 \t\t#standard heat of formation of CO2: C(s)+O2(g)->CO2(g) [KJ/mol]\n",
+ "Hf2=-285.83 \t\t#standard heat of formation of H2O: H2(g)+0.5O2(g)->H2O(l) [KJ/mol]\n",
+ "\n",
+ "\t#reaction:12C(s)+11H2(g)+5.5O2(g)->C12H22O11(s)\n",
+ "Hf=12*Hf1+11*Hf2-Hc \t#[KJ/mol]\n",
+ "print\"Hf(standard heat of formation of solid sucrose)=\",Hf,\"KJ/mol(approx)\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Hf(standard heat of formation of solid sucrose)= -2221.25 KJ/mol(approx)\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.16,Page no:37"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "Hf1=-46.11 \t\t\t#standard heat of formation of NH3 at 298K \t\t\t\t#reaction:0.5N2(g)+1.5H2(g)->NH3(g) [KJ/mol]\n",
+ "Cp1=29.125 \t\t\t#molar heat capacity at constant pressure for N2(g)[J/K/mol]\n",
+ "Cp2=28.824 \t\t\t#molar heat capacity at constant pressure for H2(g)[J/K/mol]\n",
+ "Cp3=35.06 \t\t\t#molar heat capacity at constant pressure for NH3(g)[J/K/mol]\n",
+ "T1=298 \t\t\t\t#initial temperature[K]\n",
+ "T2=400 \t\t\t\t#final temperature[K]\n",
+ "\n",
+ "\t\n",
+ "Cp=Cp3-0.5*Cp1-1.5*Cp2 \t\t#[J/K/mol]\n",
+ "T=T2-T1 \t\t\t#[K]\n",
+ "Hf2=Hf1+Cp*0.001*T \t\t#standard heat of formation for NH3 at 400K[KJ/mol]\n",
+ "print\"\\n Hf2(standard heat of formation for NH3 at 400K =\",round(Hf2,3),\"kJ/mol\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "\n",
+ " Hf2(standard heat of formation for NH3 at 400K = -48.429 kJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 15
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.17,Page no:38"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from scipy.optimize import fsolve\n",
+ "from scipy import integrate\n",
+ "dH_298=-241.82 #Std Heat of formation at 298 K [kJ mol^-1]\n",
+ "dH_298=dH_298*1000 # in [J mol^-1]\n",
+ "T1=298 #[K]\n",
+ "T2=1273 #[K]\n",
+ "def f(T):\n",
+ " Cp_H2g=(29.07-((0.836*10**-3)*T)+((20.1*10**-7)*T**2))\n",
+ " Cp_O2g=25.72+(12.98*10**-3)*T-(38.6*10**-7)*T**2\n",
+ " Cp_H2Og=30.36+(9.61*10**-3)*T+(11.8*10**-7)*T**2\n",
+ " delta_Cp=(Cp_H2Og-(Cp_H2g+(1.0/2.0)*Cp_O2g))\n",
+ " return(delta_Cp)\n",
+ "\n",
+ "dHK=integrate.quad(f,T1,T2)\n",
+ "\n",
+ "dH_1273=dH_298+dHK[0]\n",
+ "dH_1273=dH_1273/1000\n",
+ "print\"Heat of formation of H2O(g) at 1000 C=\",round(dH_1273,1),\"kJ mol^-1 (APPROXIMATE)\"\n",
+ "\n",
+ "print\"NOTE:\"\n",
+ "print\"Slight variation in answer,because integration is not done precisely in the book\"\n",
+ "print\"In the book,it is written as:-7497.46 instead of -7504.3\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Heat of formation of H2O(g) at 1000 C= -249.3 kJ mol^-1 (APPROXIMATE)\n",
+ "NOTE:\n",
+ "Slight variation in answer,because integration is not done precisely in the book\n",
+ "In the book,it is written as:-7497.46 instead of -7504.3\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.18,Page no:40"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "H1=435.0 \t\t\t#bond dissociation energy for: CH4->CH3+H [KJ/mol]\n",
+ "H2=364.0 \t\t\t#bond dissociation energy for:CH3->CH2+H [KJ/mol]\n",
+ "H3=385.0 \t\t\t#bond dissociation energy for:CH2->CH+H [KJ/mol] \n",
+ "H4=335.0 \t\t\t#bond dissociation energy for:CH->C+H [KJ/mol]\n",
+ "H=(H1+H2+H3+H4)/4 \t#the bond energy for C-H bond in CH4 [KJ/mol]\n",
+ "print\"\\n H(the C-H bond energy in CH4)=\",round(H,1),\"kJ/mol\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "\n",
+ " H(the C-H bond energy in CH4)= 379.8 kJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 16
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.19,Page no:40"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "H1=-84.68 \t\t\t#heat of formation : 2C(s)+3H2(g)->C2H6(g) [KJ/mol]\n",
+ "H2=2*716.68 \t\t\t#heat of formation : 2C(s)->2C(g) [KJ]\n",
+ "H3=3*436 \t\t\t#heat of formation : 3H2(g)->6H(g) [KJ]\n",
+ "H4=412 \t\t\t\t#taking it as bond energy for one C-H bond[KJ/mol]\n",
+ "\n",
+ "\n",
+ "H=H2+H3-H1 \t\t\t#heat of reaction : C2H6(g)->2C(g)+6H(g) [KJ/mol]\n",
+ "H5=H-6*H4 \t\t\t#bond energy for one C-C bond in ethane bond [KJ/mol]\n",
+ "print\"\\n Hc-c(bond energy for one C-C bond in ethane bond)=\",H5,\"kJ/mol\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "\n",
+ " Hc-c(bond energy for one C-C bond in ethane bond)= 354.04 kJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.20,Page no:42"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\t#MgBr2(s)-->Mg(s)+Br2(l)-->Mg(g)+Br2(l)-->Mg(g)+Br2(g)-->Mg(g)+2Br(g)-->Mg+2(g) + 2e(g) + \t2Br(g)-->Mg+2(g) + 2Br-(g)\n",
+ "H1=-524 \t\t#enthalpy of formation of MgBr2(s) from its element [KJ/mol]\n",
+ "H2=148 \t\t\t#enthalpy of sublimation of Mg(s) [KJ/mol]\n",
+ "H3=31 \t\t\t#enthalpy of vaporization of Br2(l) [KJ/mol]\n",
+ "H4=193 \t\t\t#enthalpy of dissociation Br2 to 2Br(g) [KJ/mol]\n",
+ "H5=2187 \t\t#enthalpy of ionization of Mg(g) to Mg+2(g) [KJ/mol]\n",
+ "H6=-650 \t\t#enthalpy of formation of Br-(g) [KJ/mol]\n",
+ "\n",
+ "H=-H1+H2+H3+H4+H5+H6 \t#lattice enthalpy [KJ/mol]\n",
+ "print\"\\n H(lattice enthalpy of magnesium bromide)=\",H,\"kJ/mol\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "\n",
+ " H(lattice enthalpy of magnesium bromide)= 2433 kJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 3.21,Page no:44"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from scipy.optimize import fsolve\n",
+ "from scipy import integrate\n",
+ "\n",
+ "\n",
+ "dH1_298=-881.25 #[kJ/mol]\n",
+ "dH2_298=43.60 #[kJ/mol]\n",
+ "dH3_298=2*dH2_298 #[kJ/mol]\n",
+ "dH4_298=dH1_298+dH3_298 #[kJ/mol]\n",
+ "dH_heat=-dH4_298*1000 #[J/mol]\n",
+ "\n",
+ "\n",
+ "def f(T2):\n",
+ " def g(T):\n",
+ " Cp_CO2g=26.0+((43.5*10**-3)*T)-((148.3*10**-7)*T**2)\n",
+ " Cp_H2Og=30.36+((9.61*10**-3)*T)+((11.8*10**-7)*T**2)\n",
+ " Cp_N2g=27.30-((5.23*10**-3)*T)-((0.04*10**-7)*T**2)\n",
+ " sig_nCpf=Cp_CO2g+2*Cp_H2Og+8*Cp_N2g\n",
+ " return(sig_nCpf)\n",
+ " crt=integrate.quad(g,298,T2)\n",
+ " ct=crt[0]-dH_heat\n",
+ " return(ct)\n",
+ "T2=fsolve(f,2)\n",
+ "print \"T2,maximum flame temperature is :\",round(T2[0],2),\"K\"\n",
+ "print\"Calculation mistake in book,wrongly written as:2250 K\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "T2,maximum flame temperature is : 2957.06 K\n",
+ "Calculation mistake in book,wrongly written as:2250 K\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH4.ipynb b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH4.ipynb new file mode 100755 index 00000000..faa2aabc --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH4.ipynb @@ -0,0 +1,131 @@ +{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 4:Defining Thermodynamic State:The State Postulate"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 4.1,Page no:51"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "M=2.5 \t\t\t\t#mass of the substance[Kg]\n",
+ "x=0.6 \t\t\t\t#mass fraction for vapour phase \n",
+ "P=7 \t\t\t\t#pressure [atm]\n",
+ "T=438 \t\t\t\t#temperature[K]\n",
+ "\n",
+ "Ml=(1-x)*M \t\t\t#mass fraction of liquid phase[Kg]\n",
+ "Mg=x*M \t\t\t\t#mass fraction of vapour phase[Kg]\n",
+ "print\"M(liquid phase)=\",Ml,\"Kg\\nM(vapour phase)=\",Mg,\"Kg\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "M(liquid phase)= 1.0 Kg\n",
+ "M(vapour phase)= 1.5 Kg\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 4.2,Page no:51"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "Vl=0.0177 \t\t\t#specific volume of saturated liquid[m3/Kg]\n",
+ "Vg=4.43 \t\t\t#specific volume of saturated vapour[m3/Kg]\n",
+ "P=7 \t\t\t\t#pressure[atm]\n",
+ "T=438 \t\t\t\t#temperature[K]\n",
+ "x=0.6 \t\t\t\t#fraction of vapour phase\n",
+ "M=2.5 \t\t\t\t#mass of the substance[Kg]\n",
+ "\n",
+ "V=((1-x)*Vl+x*Vg)*M \t\t#total volume occupied [m3]\n",
+ "print\"Total volume occupied =\",round(V,2),\"m^3\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Total volume occupied = 6.66 m^3\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 4.3,Page no:51"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "M=2.5 \t\t\t\t#mass of a substance[Kg]\n",
+ "x=0.6 \t\t\t\t#fraction of vapour phase \n",
+ "Ug=1105.0 \t\t\t#specific internal energy of saturated vapour[J/Kg]\n",
+ "Ul=298.0 \t\t\t\t#specific internal energy of saturated liquid[J/Kg] \n",
+ "U=M*((1-x)*Ul+x*Ug) \n",
+ "print\"The total internal energy of the mixture =\",U,\"J\"\n",
+ "print\"\\nNOTE:In textbook,it is wrongly calculated as 1950 J\"\n",
+ " "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The total internal energy of the mixture = 1955.5 J\n",
+ "\n",
+ "NOTE:In textbook,it is wrongly calculated as 1950 J\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH5.ipynb b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH5.ipynb new file mode 100755 index 00000000..2b811195 --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH5.ipynb @@ -0,0 +1,1553 @@ +{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 5:The second Law of Thermodynamics"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.1,Page no:59"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T1=373.0 \t\t\t\t#initial temperature [K]\n",
+ "T2=573.0 \t\t\t\t#final temperature [K]\n",
+ "Q2=750.0 \t\t\t\t#Heat absorbed by carnot engine[J]\n",
+ "\n",
+ "e=(T2-T1)/T2 \t\t\t#efficiency of the engine\n",
+ "W=e*Q2 \t\t\t\t#Workdone by the engine[J]\n",
+ "Q1=T1*Q2/T2 \t\t\t#Heat rejected by the engine[J]\n",
+ "print\"Efficiency of the engine =\",round(e,3) \n",
+ "print\"\\n Workdone by the engine =\",round(W),\"J\"\n",
+ "print\"\\n Heat rejected by the engine =\",round(Q1),\"J\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Efficiency of the engine = 0.349\n",
+ "\n",
+ " Workdone by the engine = 262.0 J\n",
+ "\n",
+ " Heat rejected by the engine = 488.0 J\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.2,Page no:61"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T1=250.0 #temperature of heat rejection[K]\n",
+ "T2=1000.0 #temperature of heat absorption[K]\n",
+ "e=1-(T1/T2) \n",
+ "print\"Efficiency of the corresponding carnot engine =\",e,\"or\",e*100,\"%\"\n",
+ "print\" Therefore , the inventors claim of 80% efficiency is absurd.The patent application should be rejected\" \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Efficiency of the corresponding carnot engine = 0.75 or 75.0 %\n",
+ " Therefore , the inventors claim of 80% efficiency is absurd.The patent application should be rejected\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.3,Page no:62"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T1=323.0 \t\t\t\t#temperature [K]\n",
+ "T2=423.0 \t\t\t\t#temperature [K]\n",
+ "W=1.3 \t\t\t\t#work [KJ]\n",
+ "e=(T2-T1)/T2 \t\t\t#efficiency\n",
+ "Q2=W/e \t\t\t\t#minimum heat withdrawal from heat source[KJ]\n",
+ "print\"Minimum heat withdrawal from heat source=\",round(Q2,2),\"kJ\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Minimum heat withdrawal from heat source= 5.5 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 46
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.5,Page no:64"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T=298 \t\t\t#Temperature [K]\n",
+ "n=1 \t\t\t#no. of moles\n",
+ "V1=500 \t\t\t#initial volume [cm3]\n",
+ "V2=1000 \t\t#final volume [cm3]\n",
+ "R=8.314 \t\t#Universal gas constant [J/mol/K]\n",
+ "import math\n",
+ "S=R*math.log(V2/V1)\t\t#molar entropy change at constant temperature[J/K]\n",
+ "print\"Molar entropy change of argon =\",round(S,1),\"J/K\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Molar entropy change of argon = 5.8 J/K\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.6,Page no:64"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "W=1728.0 \t\t\t#Isothermal and reversible work done[J/mol]\n",
+ "T=298.0 \t\t\t#Isothermal temperature[K]\n",
+ "\n",
+ "S=W/T \t\t\t#change in molar entropy for isothermal and reversible process\n",
+ "print\"The change in molar entropy =\",round(S,1),\"JK^-1mol^-1\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The change in molar entropy = 5.8 JK^-1mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 47
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.7,Page no:68"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "H=-92.22 \t\t\t#Standard reaction enthalpy[KJ]\n",
+ "T=298 \t\t\t\t#Temperature [K]\n",
+ "\n",
+ "\t#standard reaction enthalpy is H.Therefore, heat gained by the surroundings at 298K is -H\n",
+ "S=-H*1000/T \t\t\t#Change in entropy[J/K]\n",
+ "print\"Change in entropy of the surroundings at 298k =\",round(S,1),\"J/K\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Change in entropy of the surroundings at 298k = 309.5 J/K\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.8,Page no:69"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T1=298.0 \t\t\t\t#Initial Temperature[K]\n",
+ "T2=573.0 \t\t\t\t#Final Temperature[K]\n",
+ "Cv=29.1 \t\t\t#Specific Heat capacity of argon gas [J/K/mol]\n",
+ "n=1 \t\t\t\t#no. of moles\n",
+ "\n",
+ "import math\n",
+ "S=n*Cv*math.log(T2/T1) \t\t#Change in entropy [J/K]\n",
+ "print\"The change in entropy of the argon gas is\",round(S,2),\"J/K\"\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The change in entropy of the argon gas is 19.03 J/K\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 3,
+ "metadata": {},
+ "source": [
+ "Example 5.9,Page no:69"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T1=276.0 \t\t\t\t#Initial temperature[K]\n",
+ "Tf=278.7 \t\t\t#Freezing point temperature[K]\n",
+ "Tb=353.3 \t\t\t#Boiling point temperature[K]\n",
+ "T2=373.0 \t\t\t\t#Final temperature[K]\n",
+ "Hf=9870.0 \t\t\t#Standard enthalpy of fusion[J/mol]\n",
+ "Hv=30800.0 \t\t\t#Standard enthalpy of vaporization[J/mol]\n",
+ "Cp=136.1 \t\t\t#Specific heat capacity of benzene[J/K/mol]\n",
+ "mol_wt=78.0 \t\t\t#molecular weight of benzene[g/mol]\n",
+ "mass=200.0\t\t\t#weight of solid benzene[g]\n",
+ "print\"Cp doesnot change within this temp limit\" \n",
+ "import math\n",
+ "n=mass/mol_wt \t\t\t#no. of moles\n",
+ "\n",
+ "S1=n*Cp*math.log(Tf/T1) \t#entropy change in heating [J/K]\n",
+ "S2=n*Hf/Tf \t\t\t#entropy change in melting[J/K] \n",
+ "S3=n*Cp*math.log(Tb/Tf) \t#entropy change in heating[J/K]\n",
+ "S4=n*Hv/Tb \t\t\t#entropy change in vaporization[J/K]\n",
+ "S5=n*Cp*math.log(T2/Tb) \t#entropy change in heating[J/K]\n",
+ "S=S1+S2+S3+S4+S5 \t\t#total entropy change in heating from 276 to 373K\n",
+ "print\"Total entropy change in heating 200g benzene from 3 to 100`C is\",round(S,1),\"J/K or\",round(S/1000,3),\"KJ/K\"\n",
+ "print\"\\nNOTE:In textbook the value of 'n' is wrongly calculated as 25.64 instead of 2.564,SO there is a error in answer shown in book\" "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Cp doesnot change within this temp limit\n",
+ "Total entropy change in heating 200g benzene from 3 to 100`C is 419.4 J/K or 0.419 KJ/K\n",
+ "\n",
+ "NOTE:In textbook the value of 'n' is wrongly calculated as 25.64 instead of 2.564,SO there is a error in answer shown in book\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.10,Page no:71"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "mass=32 \t\t\t#weight of methane gas[gm]\n",
+ "P1=6*10**5 \t\t\t#Initial temperature[N/m2]\n",
+ "P2=3*10**5 \t\t\t#Final pressure[N/m2]\n",
+ "mol_wt=16 \t\t\t#molecular weight of methane gas[g/mol]\n",
+ "T=298 \t\t\t\t#Temperature[K]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "import math\t\n",
+ "n=mass/mol_wt \t\t\t#no. of moles\n",
+ "S=n*R*math.log(P1/P2) \t\t#change in entropy of gas[J/K]\n",
+ "\n",
+ "print\"The change in entropy of the gas is\",round(S,2),\"J/K\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The change in entropy of the gas is 11.53 J/K\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.11,Page no:75"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "import math\n",
+ "black=2 #No. of black balls\n",
+ "white=1 #No. of white ball\n",
+ "\n",
+ "\n",
+ "W=math.factorial(black+white)/(math.factorial(black)*math.factorial(white))\n",
+ "P=1.0/W\n",
+ "E1=0+1+2\n",
+ "E2=E1\n",
+ "E3=E2\n",
+ "E=E1+E2+E3\n",
+ "E_av=E/3\n",
+ "E1_dash=1+2+3\n",
+ "E2_dash=E1_dash\n",
+ "E3_dash=E2_dash\n",
+ "E_dash=E1_dash+E2_dash+E3_dash\n",
+ "change=E_dash-E\n",
+ "\n",
+ "print\"1.Total No. of possible configuration:\",W\n",
+ "print\"2.Probability of getting a configuration=\",P,\"or 1/3\"\n",
+ "print\"3.Total energy of system=\",E\n",
+ "print\" Therefore,Average energy=\",E_av\n",
+ "print\"4.In this case,Total energy=\",E_dash\n",
+ "print\" Change in total energy of system=\",change"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "1.Total No. of possible configuration: 3\n",
+ "2.Probability of getting a configuration= 0.333333333333 or 1/3\n",
+ "3.Total energy of system= 9\n",
+ " Therefore,Average energy= 3\n",
+ "4.In this case,Total energy= 18\n",
+ " Change in total energy of system= 9\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.12,Page no:77"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "n=1.0 \t\t\t#no. of moles\n",
+ "T=273.0 \t\t\t#temperature [K]\n",
+ "Hf=6000.0 \t\t#enthalpy of fusion at 273K [J/mol]\n",
+ "k=1.38*(10**-23) \t#boltzmann constant[J/K]\n",
+ "\n",
+ "p=Hf/(k*T)/2.303 \n",
+ "print\"\\nTHE RESULT IS 10^24,which is too large to be displayed by ipython \"\n",
+ "print\"This value of w is very large to calculate for python,because it's in the range of 10^24\"\n",
+ "print\"The relative no. of distinguishable quantum states in 1 mole of water and ice at 273K is 10^24\" \n",
+ "print\"\\nTHE RESULT IS 10^24,which is too large to be displayed by ipython \"\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "\n",
+ "THE RESULT IS 10^24,which is too large to be displayed by ipython \n",
+ "This value of w is very large to calculate for python,because it's in the range of 10^24\n",
+ "The relative no. of distinguishable quantum states in 1 mole of water and ice at 273K is 10^24\n",
+ "\n",
+ "THE RESULT IS 10^24,which is too large to be displayed by ipython \n"
+ ]
+ }
+ ],
+ "prompt_number": 50
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.13,Page no:86"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T=300 \t\t\t#temperature[K]\n",
+ "n=4 \t\t\t#no. of moles of an ideal gas\n",
+ "P1=2.02*10**5 \t\t#initial pressure[N/m2]\n",
+ "P2=4.04*10**5 \t\t#final pressure[N/m2]\n",
+ "R=8.314 \t\t#Universal gas constant[J/K/mol]\n",
+ "import math\n",
+ "G=n*R*T*2.303*math.log10(P2/P1) \t#[J]\n",
+ "print\" The change in Gibbs free energy is\",round(G,1),\"J\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " The change in Gibbs free energy is 6916.6 J\n"
+ ]
+ }
+ ],
+ "prompt_number": 51
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.14,Page no:86"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "n=1 \t\t\t#no. of moles\n",
+ "T=300 \t\t\t#temperature[K]\n",
+ "V1=2 \t\t\t#initial volume[m3]\n",
+ "V2=20 \t\t\t#final volume[m3]\n",
+ "R=8.314 \t\t#Universal gas constant[J/K/mol]\n",
+ "import math\n",
+ "\t\n",
+ "A=-n*R*T*2.303*math.log10(V2/V1) \t#Change in work function[J/mol]\n",
+ "print\"The change in Helmholts free energy is\",round(A),\"J/mol\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The change in Helmholts free energy is -5744.0 J/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 52
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.15,Page no:87"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"C6H12O6(s) + 6O2(g) --> 6CO2(g) + 6H2O(l)\"\n",
+ "T=298 \t\t\t\t#Temperature[k]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "S=182.45 \t\t\t#standard entropy change at 298K [J/K]\n",
+ "U=-2808 \t\t\t#change in internal energy at 298K[KJ/mol]\n",
+ "\t#reaction is taking place in bomb calorimeter so no volume change \n",
+ "\t#therefore U=Q at constant volume\n",
+ "\t\n",
+ "A=U-T*S*0.001 \t\t\t#Energy extracted as heat[KJ/mol]\n",
+ "Wmax=A \t\t\t\t#work done [KJ/mol]\n",
+ "dn=6-6 \t\t\t\t#change in no. of moles\n",
+ "H=U+dn*R*T \t\t\t#Change in enthalpy of the bomb calorimeter[KJ]\n",
+ "print\"The energy change that can be extracted as heat is\",round(A),\"KJ/mol\"\n",
+ "print\"\\nThe energy change that can be extracted as work is\",round(-A),\"KJ/mol\"\n",
+ "print\"\\nThe change in enthalpy of bomb calorimeter is\",round(H),\"KJ/mol\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C6H12O6(s) + 6O2(g) --> 6CO2(g) + 6H2O(l)\n",
+ "The energy change that can be extracted as heat is -2862.0 KJ/mol\n",
+ "\n",
+ "The energy change that can be extracted as work is 2862.0 KJ/mol\n",
+ "\n",
+ "The change in enthalpy of bomb calorimeter is -2808.0 KJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.16,Page no:87"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "print\"C8H18(g)+12.5O2(g)-->8CO2(g)+9H2O(l)\" \n",
+ "\n",
+ "T=298.0 \t\t\t\t#temperature[K]\n",
+ "S=421.5 \t\t\t#change in entropy[J/K]\n",
+ "H=-5109000.0 \t\t\t#Heat of reaction[J]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "dn=8-(1+12.5) \t\t\t#change in no. of moles\n",
+ "\n",
+ "U=H \t\t\t\t#[J]\n",
+ "A=U-T*S \t\t\t#Change in helmholts free energy[J]\n",
+ "G=A+dn*R*T \t\t\t#Change in Gibbs free energy[J]\n",
+ "print\"The change in Helmholts free energy is\",round(A),\"J\"\n",
+ "print\"\\nThe change in Gibbs free energy is\",round(G),\"J\"\n",
+ "print\"The calculation is not precise in book,that's why a slight change in answer\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C8H18(g)+12.5O2(g)-->8CO2(g)+9H2O(l)\n",
+ "The change in Helmholts free energy is -5234607.0 J\n",
+ "\n",
+ "The change in Gibbs free energy is -5248234.0 J\n",
+ "The calculation is not precise in book,that's why a slight change in answer\n"
+ ]
+ }
+ ],
+ "prompt_number": 55
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.17,Page no:88"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"C3H6(g)+4.5O2(g)-->3CO2(g)+3H2O(l)\" \n",
+ "S=-339.23 \t\t\t#standard change in entropy [J/K]\n",
+ "T=298 \t\t\t\t#temperature[K]\n",
+ "Hf1=20.42 \t\t\t#enthalpy of formation of C3H6(g)[J]\n",
+ "Hf2=-393.51 \t\t\t#enthalpy of formation of CO2(g)[J]\n",
+ "Hf3=-285.83 \t\t\t#enthalpy of formation of H2O(l)[J]\n",
+ "dn=3-4.5-1 \t\t\t#change in no. of moles\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "\n",
+ "H=3*Hf2+3*Hf3-Hf1 \t\t#Enthalpy of the reaction[J]\n",
+ "U=H-dn*R*0.001*T \t\t#Change in internal energy of the reaction[J]\n",
+ "A=U-T*S*0.001 \t\t\t#Helmholts free energy change[J]\n",
+ "G=A+dn*R*0.001*T \t\t#Gibbs free energy change[J]\n",
+ "print\"The change in Helmholts free energy is\",round(A,2),\"kJ\"\n",
+ "print\"\\nThe change in Gibbs free energy is\",round(G,2),\"kJ\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C3H6(g)+4.5O2(g)-->3CO2(g)+3H2O(l)\n",
+ "The change in Helmholts free energy is -1951.16 kJ\n",
+ "\n",
+ "The change in Gibbs free energy is -1957.35 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 56
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.19,Page no:92"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"CH4(g)+2O2(g)-->CO2(g)+2H2O(l)\"\n",
+ "\n",
+ "S1=-242.98 \t\t\t\t#standard entropy change for the combustion reaction[J/K]\n",
+ "Hf1=-74.81 \t\t\t\t#Enthalpy of formation of CH4(g)[KJ/mol]\n",
+ "Hf2=-393.51 \t\t\t\t#Enthalpy of formation of CO2(g)[KJ/mol]\n",
+ "Hf3=-285.83 \t\t\t\t#Enthalpy of formation of H2O(l)[KJ/mol]\n",
+ "T=298 \t\t\t\t\t#temperature[K]\n",
+ "\t \n",
+ "H=Hf2+2*Hf3-Hf1 \t\t\t#Change in enthalpy of reaction[KJ]\n",
+ "S2=-H*1000/T \t\t\t\t#Change in entropy of the surrounding[J/K]\n",
+ "Stotal=(S1+S2)*0.001 \t\t\t#Total entropy change \n",
+ "print\"The total change in entropy is\",round(Stotal,2),\"KJ/K\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "CH4(g)+2O2(g)-->CO2(g)+2H2O(l)\n",
+ "The total change in entropy is 2.74 KJ/K\n"
+ ]
+ }
+ ],
+ "prompt_number": 17
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.20,Page no:93"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"2H2(g)+O2(g)-->2H2O(l)\" \n",
+ "Hf1=-285.83 \t\t\t\t#standard enthalpy of formation of H2O(l)[KJ/mol]\n",
+ "S=-327 \t\t\t\t\t#Standard entropy change for the same reaction[J/K]\n",
+ "T=298 \t\t\t\t\t#temperature[K]\n",
+ "\n",
+ "\t\n",
+ "H=2*Hf1-0-0 \t\t\t\t#Enthalpy of the reaction[KJ/mol]\n",
+ "G=H-T*S*0.001 \t\t\t\t#Change in Gibbs free energy[KJ]\n",
+ "print\"The change in Gibbs free energy is\",round(G,2),\"KJ\\n \"\n",
+ "print\"As change in Gibbs free energy is negative.Therefore,the reaction is spontaneous\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "2H2(g)+O2(g)-->2H2O(l)\n",
+ "The change in Gibbs free energy is -474.21 KJ\n",
+ " \n",
+ "As change in Gibbs free energy is negative.Therefore,the reaction is spontaneous\n"
+ ]
+ }
+ ],
+ "prompt_number": 18
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.21,Page no:94"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "\n",
+ "print\"CH4(g)+2O2(g)-->CO2(g)+2H2O(l)\" \n",
+ "S=-242.98 \t\t\t#standard entropy change for reaction [J/K]\n",
+ "T=298 \t\t\t\t#temperature[K]\n",
+ "Gf1=-50.72 \t\t\t#standard Gibbs free energy of formation for CH4(g)[KJ/mol]\n",
+ "Gf2=-394.36 \t\t\t#standard Gibbs free energy of formation for CO2(g)[KJ/mol]\n",
+ "Gf3=-237.13 \t\t\t#standard Gibbs free energy of formation for H2O(l)[KJ/mol]\n",
+ "\n",
+ "G=Gf2+2*Gf3-Gf1 \t\t#Standard Gibbs free energy for reaction[KJ/mol]\n",
+ "H=G+T*S*0.001 \t\t\t#Standard enthalpy of reaction [KJ]\n",
+ "print\"The standard enthalpy of reaction is\",round(H,2),\"kJ\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "CH4(g)+2O2(g)-->CO2(g)+2H2O(l)\n",
+ "The standard enthalpy of reaction is -890.31 kJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 57
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.22,Page no:94"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"C6H12O6(s)+6O2(g)-->6CO2(g)+6H2O(l)\"\n",
+ "mass=25.0 \t\t\t#mass of glucose for combustion under standard condition[gm]\n",
+ "T=298 \t\t\t\t#temperature[K]\n",
+ "Gf1=-910 \t\t\t#Standard Gibbs free energy of formation for C6H12O6[KJ/mol]\n",
+ "Gf2=-394.4 \t\t\t#Standard Gibbs free energy of formation for CO2(g)[KJ/mol]\n",
+ "Gf3=-237.13 \t\t\t#Standard Gibbs free energy of formation for H2O(l)[KJ/mol]\n",
+ "mol_wt=180.0 \t\t\t#molecular weight of glucose[gm/mol]\n",
+ "\t\n",
+ "G=6*Gf2+6*Gf3-Gf1\n",
+ "n=mass/mol_wt \t\t\t#no. of moles\n",
+ "Gactual=G*n \t\t\t#Gibbs free energy for the combustion of 0.139mol of glucose \n",
+ "print\"The energy that can be extracted as non-expansion work is\",round(-Gactual),\"KJ\" \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "C6H12O6(s)+6O2(g)-->6CO2(g)+6H2O(l)\n",
+ "The energy that can be extracted as non-expansion work is 400.0 KJ\n"
+ ]
+ }
+ ],
+ "prompt_number": 21
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.23,Page no:97"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "a=1.39*10**-2 \t\t#constant for a vanderwaal's gas[lit2.atm/mol2]\n",
+ "b=3.92*10**-2 \t\t#constant for a vanderwaal's gas[lit2.atm/mol2]\n",
+ "R=0.082 \t\t#Universal gas constant[lit.atm/deg/mol]\n",
+ "\t\n",
+ "Ti=(2*a)/(R*b) \t\t#inversion temperature [K]\n",
+ "print\"The inversion temperature for the gas is\",round(Ti,3),\" K\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The inversion temperature for the gas is 8.649 K\n"
+ ]
+ }
+ ],
+ "prompt_number": 58
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.26,Page no:100"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T=169.25 \t\t\t#Boiling point[K]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "print\"dlnP/dT=He/R*T**2\" \n",
+ "print\"dlnP/dT=(2.303*834.13/T**2)+(1.75/T)-(2.30*8.375*10**-3)\" \n",
+ "print\"Therefore using these two equations we calculate the He(enthalpy) of ethylene\" \n",
+ "\n",
+ "x=(2.303*834.13/T**2)+(1.75/T)-(2.30*8.375*10**-3) #it is dlnP/dT\n",
+ "He=R*0.001*T**2*x #Enthalpy of vaporization[J/mol]\n",
+ "print\"\\n\\nThe Enthalpy of vaporization of ethylene at its boiling point is\",round(He,3),\"KJ/mol\"\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "dlnP/dT=He/R*T**2\n",
+ "dlnP/dT=(2.303*834.13/T**2)+(1.75/T)-(2.30*8.375*10**-3)\n",
+ "Therefore using these two equations we calculate the He(enthalpy) of ethylene\n",
+ "\n",
+ "\n",
+ "The Enthalpy of vaporization of ethylene at its boiling point is 13.846 KJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 59
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.27,Page no:101"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "P1=101.3 \t\t\t#Initial Pressure[KPa]\n",
+ "P2=60 \t\t\t\t#Final Pressure[KPa]\n",
+ "He=31.8 \t\t\t#Enthalpy of vaporization[KJ/mol]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "T1=353.2 \t\t\t#boiling point of benzene at 101.3KPa[K]\n",
+ "import math\n",
+ "\n",
+ "x=(T1**-1)-(R*0.001*math.log(P2/P1)/He) \n",
+ "T2=x**-1 \t\t\t#Boiling point of benzene at 60KPa\n",
+ "print\"The boiling point of benzene at 60KPa is\",round(T2,1),\"K\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The boiling point of benzene at 60KPa is 336.9 K\n"
+ ]
+ }
+ ],
+ "prompt_number": 24
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.28,Page no:101"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "P1=0.016 \t\t\t#Vapour pressure of pure ethanol at 273K[bar]\n",
+ "P2=0.470 \t\t\t#Vapour pressure of pure ethanol at 333K[bar]\n",
+ "T1=273 \t\t\t\t#initial temperature [K]\n",
+ "T2=333 \t\t\t\t#final temperature[K]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "P=1.01 \t\t\t\t#vapour pressure at normal boiling point[bar]\n",
+ "import math\n",
+ "\t\n",
+ "x=(T2**-1)-(T1**-1) \n",
+ "He=-R*0.001*math.log(P2/P1)/x \t#molar enthalpy of vaporization[J/mol]\n",
+ "t=(T2**-1)-(R*0.001*math.log(P/P2)/He) \n",
+ "T=(t**-1)-273 \t\t\t#normal boiling point [C]\n",
+ "print\"\\n\\nThe normal boiling point for pure ethanol is \",round(T,1),\"C\"\n",
+ "print\"The molar enthalpy of vapourization is\",round(He,2),\"J/mol\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "\n",
+ "\n",
+ "The normal boiling point for pure ethanol is 77.4 C\n",
+ "The molar enthalpy of vapourization is 42.58 J/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 60
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.29,Page no:102"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T2=353.2 \t\t\t#normal boiling point of benzene at 1.01325bar[K]\n",
+ "T1=298\t \t\t\t#temperature [K]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "P2=1.01325 \t\t\t#Vapour pressure of benzene[bar]\n",
+ "import math\n",
+ "\t#benzene obey's Trouton's rule\n",
+ "print\" from Troutons rule , \" \n",
+ "print\" He/Tb=85J/K/mol\" \n",
+ "\n",
+ "He=85*T2 \t\t\t#molar enthalpy of vapourization[J/K/mol]\n",
+ "x=(T2**-1)-(T1**-1) \n",
+ "t=-He*x/R \n",
+ "P1=P2/math.exp(t) \n",
+ "print\"\\nThe vapour pressure of benzene at 298K is\",round(P1,3),\" bar\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " from Troutons rule , \n",
+ " He/Tb=85J/K/mol\n",
+ "\n",
+ "The vapour pressure of benzene at 298K is 0.152 bar\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.30,Page no:111"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "c=1 \t\t\t#no. of components(only CO2)\n",
+ "p=2 \t\t\t#no. of phases(liquid + gas)\n",
+ "\n",
+ "F=c-p+2 \t\t#degree of freedom\n",
+ "print\"Degrees of freedom is\",F \n",
+ "print\"Degrees of freedom 1 means that either pressure or temperature can be varied independently,i.e.when temperature is fixed,pressure is automatically fixed\" "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Degrees of freedom is 1\n",
+ "Degrees of freedom 1 means that either pressure or temperature can be varied independently,i.e.when temperature is fixed,pressure is automatically fixed\n"
+ ]
+ }
+ ],
+ "prompt_number": 27
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.31,Page no:111"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "c=1 \t\t\t#no. of components\n",
+ "p=1 \t\t\t#no. of phases\n",
+ "\n",
+ "F=c-p+2 \t\t#Degrees of freedom\n",
+ "print\"Degrees of freedom,F is\",F \n",
+ "print\"Degrees of freedom 2 means both the pressure and temperature can be varied independently\" \n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Degrees of freedom,F is 2\n",
+ "Degrees of freedom 2 means both the pressure and temperature can be varied independently\n"
+ ]
+ }
+ ],
+ "prompt_number": 61
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.32,Page no:113"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "P=1.75*10**-5 \t\t\t#Vapour pressure of pure water at 293K[torr]\n",
+ "dP=1.1*10**-7 \t\t\t#Lowering in vapour pressure of water\n",
+ "\n",
+ "x=dP/P \t\t\t\t#mole fraction of sucrose\n",
+ "print\"The mole fraction of sucrose is\",round(x,6) \n",
+ "\n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The mole fraction of sucrose is 0.006286\n"
+ ]
+ }
+ ],
+ "prompt_number": 30
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.33,Page no:114"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "P=94.6 \t\t\t\t#The vapour pressure of pure benzene at 298K[torr]\n",
+ "n1=20.0 \t\t\t\t#no. of moles of pure benzene\n",
+ "n2=5.0 \t\t\t\t#no. of moles of pure naphthalene\n",
+ "\n",
+ "x=n1/(n1+n2) \t\t\t#(mole fraction of benzene)\n",
+ "p=x*P \t\t\t\t#the partial vapour pressure of benzene[torr]\n",
+ "print\"The partial vapour pressure of benzene is\",p,\"torr\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The partial vapour pressure of benzene is 75.68 torr\n"
+ ]
+ }
+ ],
+ "prompt_number": 31
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.34,Page no:114"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "x=0.28 \t\t\t\t#mole fraction of solute\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "T=298 \t\t\t\t#temperature[K]\n",
+ "import math\n",
+ "\n",
+ "du=R*T*math.log(1-x) \t\t#reduction in chemical potential[J/mol]\n",
+ "print\"The reduction in chemical potential is\",round(-du,1),\"J/mol\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The reduction in chemical potential is 813.9 J/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 32
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.35,Page no:116"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "Kb=0.51 \t\t\t#ebullioscopic constant of water [K*Kg/mol]\n",
+ "n=155.0/180.0 \t\t\t#no. of moles of glucose\n",
+ "m=n/1 \t\t\t\t#[mol/Kg]\n",
+ "Ti=373.0 \t\t\t\t#Boiling point temperature of water[K]\n",
+ "\n",
+ "Tf=(Ti+Kb*m)-273 \t\t#boiling point temperature of the solution[C]\n",
+ "print\"The boiling point of the solution is\",round(Tf,2),\"degree C\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The boiling point of the solution is 100.44 degree C\n"
+ ]
+ }
+ ],
+ "prompt_number": 62
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.36,Page no:117"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "Ti=5.44 #freezing point of pure benzene[K]\n",
+ "Tf=4.63 #freezing point of solution[K]\n",
+ "m1=2.12 #mass of the solute[gm]\n",
+ "m2=125.0 #mass of the benzene[gm]\n",
+ "Kf=5.12 #cryoscopic constant of pure benzene[K*Kg/mol]\n",
+ "\n",
+ "dTf=Ti-Tf \t#depression in freezing point[K]\n",
+ "M2=(m1*1000*Kf)/(m2*dTf) #molar mass of solute\n",
+ "print\"The molar mass of solute is\",round(M2),\"(approx)\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The molar mass of solute is 107.0 (approx)\n"
+ ]
+ }
+ ],
+ "prompt_number": 65
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.38,Page no:124"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"N2(g)+3H2(g)<=>2NH3(g)\"\n",
+ "T=298 \t\t\t#Temperature[K]\n",
+ "Gf1=-16450 \t\t#Gibb's free energy of formation for NH3(g)[J/mol]\n",
+ "R=8.314 \t\t#Universal gas constant[J/K/mol]\n",
+ "import math\t\n",
+ "\t\n",
+ "Gf=2*Gf1\t\t\t#Gibb's free energy for the reaction[KJ]\n",
+ "x=Gf/R/T\n",
+ "Kp=math.exp(-x) \n",
+ "print\"The Kp for above reaction is\",round(Kp),\"or 5.85*10^5,in scientific notation(APPROX)\" "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "N2(g)+3H2(g)<=>2NH3(g)\n",
+ "The Kp for above reaction is 584861.0 or 5.85*10^5,in scientific notation(APPROX)\n"
+ ]
+ }
+ ],
+ "prompt_number": 66
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.39,Page no:124"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"0.5N2(g)+1.5H2(g)<=>NH3(g)\" \n",
+ "T=298 #Temperature[K]\n",
+ "Kp=900 #Equilibrium constant for above reaction\n",
+ "P1=0.32 #partial pressure of N2(g)[bar]\n",
+ "P2=0.73 #partial pressure of H2(g)[bar]\n",
+ "P3=0.98 #partial pressure of NH3(g)[bar]\n",
+ "R=8.314 #Universal gas constant[J/K/mol]\n",
+ "import math\n",
+ "\n",
+ "G=-R*T*math.log(Kp) \n",
+ "x=(P1**0.5)*(P2**1.5) \n",
+ "p=P3/x \n",
+ "Gr=(G+R*T*math.log(p))*0.001 \n",
+ "print\"The reaction Gibbs free energy is\",round(Gr*1000),\"J/mol \""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "0.5N2(g)+1.5H2(g)<=>NH3(g)\n",
+ "The reaction Gibbs free energy is -14322.0 J/mol \n"
+ ]
+ }
+ ],
+ "prompt_number": 37
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.40,Page no:125"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"N2(g)+3H2(g)<=>2NH3(g)\"\n",
+ "\n",
+ "Kp1=5.85*10**5 #equilibrium constant at 298K\n",
+ "H1=-46.11 #standard enthalpy of formation of NH3(g)[KJ/mol]\n",
+ "T1=298 #Initial temperature[K]\n",
+ "T2=423 #Final temperature[K]\n",
+ "R=8.314 #Universal gas constant[J/K/mol]\n",
+ "import math\n",
+ "\n",
+ "H=2*H1 #enthalpy for reaction [KJ]\n",
+ "t=(T1**-1)-(T2**-1) \n",
+ "x=-H*t/(R*0.001) \n",
+ "Kp2=Kp1*math.exp(x) \n",
+ "print\"The Equilibrium constant for reaction at 423K is\",round(Kp2) \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "N2(g)+3H2(g)<=>2NH3(g)\n",
+ "The Equilibrium constant for reaction at 423K is 35004905509.0\n"
+ ]
+ }
+ ],
+ "prompt_number": 38
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.41,Page no:128"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"Zn(s)|ZnCl2(aq)||CdSO4(aq)|Cd(s)\"\n",
+ "T=298.0 \t\t\t#Temperature[K]\n",
+ "R=8.314 \t\t#Universal gas constant[J/K/mol]\n",
+ "E1=-0.7618 \t\t#Standard electrode potential for Zn2+/Zn [volts]\n",
+ "E2=-0.403 \t\t#Standard electrode potential for Cd2+/Cd [volts]\n",
+ "F=96500.0 \t\t#Faraday's constant[coulomb/mol]\n",
+ "n=2.0 \t\t\t#no. of electrons balancing\n",
+ "\n",
+ "Ei=E2-E1 \t\t#Standard potential for the reaction[volts]\n",
+ "import math\n",
+ "Gi=-n*F*Ei \t\t#Standard Gibb's Free Energy [KJ/mol] \n",
+ "Ki=math.exp(-Gi/R/T) \t#Equilibrium constant\n",
+ "print\"The Free energy for the rection is\",Gi*0.001,\"KJ/mol\"\n",
+ "print\"The value of equilibrium constant is\",Ki \n",
+ "\n",
+ "print\"Cd(s)|CdSO4(aq),Hg2SO4(s)|Hg(l)\" \n",
+ "E3=0.6141 \t\t#Standard electrode potential for Hg2SO4(s),SO4^2-/Hg(l) [volts]\n",
+ "\n",
+ "Eii=E3-E2 \t\t#Standard potantial for the reaction[volts]\n",
+ "Gii=-n*F*Eii \t\t#Standard Gibb's free energy[KJ/mol]\n",
+ "Kii=math.exp(-Gii/R/T) \t#Equilibrium constant\n",
+ "print\"The Free energy for the rection is\",round(Gii*0.001,1),\"KJ/mol\"\n",
+ "print\"The value of equilibrium constant is\",Kii\n",
+ "print\"PLEASE REDO the last line calculation,It is showing wrong result in my PC\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Zn(s)|ZnCl2(aq)||CdSO4(aq)|Cd(s)\n",
+ "The Free energy for the rection is -69.2484 KJ/mol\n",
+ "The value of equilibrium constant is 1.37586809667e+12\n",
+ "Cd(s)|CdSO4(aq),Hg2SO4(s)|Hg(l)\n",
+ "The Free energy for the rection is -196.3 KJ/mol\n",
+ "The value of equilibrium constant is 2.56773255559e+34\n",
+ "PLEASE REDO the last line calculation,It is showing wrong result in my PC\n"
+ ]
+ }
+ ],
+ "prompt_number": 39
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.42,Page no:130"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"Zn(s)|ZnCl2(soln)||AgCl(s)|Ag-Ag|AgCl(s)|ZnCl2(soln)|Zn(s)\" \n",
+ "\n",
+ "m1=0.02 \t\t\t#concentration[M]\n",
+ "Y1=0.65 \t\t\t#mean ionic activity coefficient\n",
+ "m2=1.5 \t\t\t\t#concentration[M]\n",
+ "Y2=0.29 \t\t\t#mean ionic activity coefficient \n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "T=298 \t\t\t\t#Temperature [K]\n",
+ "F=96500 \t\t\t#Faraday's constant[coulomb/mol]\n",
+ "import math\n",
+ "\t\n",
+ "E=R*T*(math.log(m2*Y2/m1/Y1))*3/2/F \t#[volts]\n",
+ "print\"The overall e.m.f of the cell is\",round(E,4),\"volt\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Zn(s)|ZnCl2(soln)||AgCl(s)|Ag-Ag|AgCl(s)|ZnCl2(soln)|Zn(s)\n",
+ "The overall e.m.f of the cell is 0.1352 volt\n"
+ ]
+ }
+ ],
+ "prompt_number": 67
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.43,Page no:131"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"H2(g,1atm)|HCl(aq)|HCl(aq)|H2(g,1atm)\" \n",
+ "m1=0.02 \t\t\t#concentration[M]\n",
+ "Y1=0.88 \t\t\t#mean ionic activity coefficient\n",
+ "m2=1 \t\t\t\t#concentration[M]\n",
+ "Y2=0.81 \t\t\t#mean ionic activity coefficient\n",
+ "R=8.314 \t\t\t#universal gas constant[J/K/mol]\n",
+ "T=298 \t\t\t\t#Temperature[K]\n",
+ "F=96487 \t\t\t#Faraday's constant[coulombs/mol]\n",
+ "t=0.178 \t\t\t#Tranference number of Cl-1\n",
+ "import math\n",
+ "\n",
+ "E=-2*t*R*T*(math.log(m1*Y1/m2/Y2))/F \t#e.m.f of the cell[volts]\n",
+ "print\"The e.m.f of the cell is\",round(E,3),\" volts\" \n",
+ "print\"\\nWrongly calculated in book as 0.351 volt\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "H2(g,1atm)|HCl(aq)|HCl(aq)|H2(g,1atm)\n",
+ "The e.m.f of the cell is 0.035 volts\n",
+ "\n",
+ "Wrongly calculated in book as 0.351 volt\n"
+ ]
+ }
+ ],
+ "prompt_number": 41
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 5.44,Page no:133"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "print\"The values for reaction that goes on within the cadmium cell\" \n",
+ "n=2 \t\t\t#no. of moles\n",
+ "E=1.01463 \t\t#standard cadmium cell potential[volts]\n",
+ "d=-5*10**-5 \t\t#i.e d=dE/dT[V/K]\n",
+ "F=96500 \t\t#[coulomb/mol]\n",
+ "T=298 \t\t\t#Temperature [K]\n",
+ "\n",
+ "dG=-n*E*F \t\t#Change in Gibb's free energy[J]\n",
+ "dS=n*F*d \t\t#Change in entropy [J/K]\n",
+ "dH=dG+T*dS \t\t#change in enthalpy[J]\n",
+ "print\" dG=\",dG,\"J\\nWrongly calculated in book as -195815 J\"\n",
+ "print\"\\n dS=\",dS,\"J/K\"\n",
+ "print\"\\n dH=\",dH,\"J\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The values for reaction that goes on within the cadmium cell\n",
+ " dG= -195823.59 J\n",
+ "Wrongly calculated in book as -195815 J\n",
+ "\n",
+ " dS= -9.65 J/K\n",
+ "\n",
+ " dH= -198699.29 J\n"
+ ]
+ }
+ ],
+ "prompt_number": 68
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH6.ipynb b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH6.ipynb new file mode 100755 index 00000000..4326009b --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH6.ipynb @@ -0,0 +1,620 @@ +{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 6:The Question of Ideality"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.2,Page no:144"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "from scipy.optimize import fsolve\n",
+ "\n",
+ "a=3.61 #atm L**2 mol**-2\n",
+ "b=4.29*10**-2 #L mol**-1\n",
+ "R=0.082 #L atm K**-1 mol**-1\n",
+ "T=500 #K\n",
+ "P=100 #atm\n",
+ "\n",
+ "\n",
+ "C1=b+(R*T/P) #L mol**-1 [aSsume]\n",
+ "C2=a/P #L^2 mol^-2 [assume]\n",
+ "C3=C2*b #L^3mol**-3\n",
+ "def f(x):\n",
+ " return(x**3-C1*x**2+C2*x-C3)\n",
+ "x=fsolve(f,0.3)\n",
+ "\n",
+ "\n",
+ "print \"x=\",round(x,3)\n",
+ "Vm=round(x,3)\n",
+ "print\"Therefore,the value of molar volume,Vm=\",Vm,\"L mol^-1\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "x= 0.366\n",
+ "Therefore,the value of molar volume,Vm= 0.366 L mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.5,Page no:149"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "b=0.0391 \t\t\t#Van der waals constant[dm3/mol]\n",
+ "R=0.082 \t\t\t#Universal gas constant[dm3*atm/mol]\n",
+ "P2=1000 \t\t\t#pressure [atm]\n",
+ "P1=0 \t\t\t\t#pressure [atm]\n",
+ "T=1273\t\t \t\t#Temperature [K]\n",
+ "import math\n",
+ "\n",
+ "x=b*(P2-P1) \n",
+ "y=R*T \n",
+ "fc=math.exp(x/y) \t\t#fugacity coefficient\n",
+ "\n",
+ "f=P2*fc #fugacity[atm]\n",
+ "print\"The fugacity coefficient is\",round(fc,3) \n",
+ "print\"The fugacity is\",round(f),\"atm\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The fugacity coefficient is 1.454\n",
+ "The fugacity is 1454.0 atm\n"
+ ]
+ }
+ ],
+ "prompt_number": 1
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.10,Page no:"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "m1=0.03 #mass of CO2(g)[gm]\n",
+ "w1=44.01 #molecular weight of CO2(g)[gm/mol]\n",
+ "m2=250 #mass of water[gm]\n",
+ "w2=18.02 #molecular weight of water[gm/mol]\n",
+ "k=1.25*10**6 #Henry's law constant[Torr]\n",
+ "T=298 #Temperature[K]\n",
+ "\n",
+ "n1=m1/w1 #no. of moles of CO2\n",
+ "n2=m2/w2 #no. of moles of water\n",
+ "x1=n1/(n1+n2) #mole fraction of CO2\n",
+ "Pco2=k*x1 #Partial pressure of CO2[Torr]\n",
+ "print\"The partial pressure of CO2 gas is\",round(Pco2,2),\"Torr\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The partial pressure of CO2 gas is 61.41 Torr\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.11,Page no:161"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "W=1000 \t\t\t#Total mass of a solution[gm]\n",
+ "x1=0.5 \t\t\t#mole fraction of Chloroform\n",
+ "x2=0.5 \t\t\t#mole fraction of Acetone\n",
+ "V1m=80.235 \t\t#Partial molar volume of chloroform[cm3/mol]\n",
+ "V2m=74.166 \t\t#Partial molar volume of Acetone[cm3/mol]\n",
+ "M1=119.59 \t\t#molecular weight of chloroform[gm/mol]\n",
+ "M2=58 \t\t\t#molecular weight of Acetone[gm/mol]\n",
+ "\n",
+ "nT=W/(x1*M1+x2*M2) \t#Total no. of moles\n",
+ "V=nT*(x1*V1m+x2*V2m) \t#Total volume[cm3]\n",
+ "print\"The volume of the solution is\",round(V,1),\"cm^3 (approx)\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The volume of the solution is 869.4 cm^3 (approx)\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.12,Page no:163"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "x1=0.5 #mole fraction of chloroform\n",
+ "x2=0.5 #mole fraction of p-xylene\n",
+ "T=298 #Temperature[K]\n",
+ "\n",
+ "Ve=x1*x2*(0.585+0.085*(x1-x2)-0.165*(x1-x2)**2) #Excess volume measured by using a dilatometer\n",
+ "print\"Ve/(cm3.mol**-1) = \",round(Ve,3) "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "Ve/(cm3.mol**-1) = 0.146\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.14,Page no:169"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "m1=0.01 \t\t#molality[m]\n",
+ "v11=1.0 \n",
+ "v12=2.0 \n",
+ "Y1=0.71 \n",
+ "m2=0.005 \t\t#molality[m]\n",
+ "v21=1.0 \n",
+ "v22=1.0 \n",
+ "Y2=0.53 \n",
+ "\n",
+ "\n",
+ "v1=(v11)+(v12) \n",
+ "v2=(v21)+(v22) \n",
+ "a1=(m1**v1)*(v11**v11)*(v12**v12)*(Y1**v1) \n",
+ "a2=(m2**v2)*(v21**v21)*(v22**v22)*(Y2**v2) \n",
+ "x=1.0/v1 \n",
+ "a1m=a1**x \n",
+ "m1m=m1*(v11**v11*v12**v12)**x #molality[m]\n",
+ "y=1.0/v2 \n",
+ "m2m=m2*(v21*v21*v22**v22)**y #molality[m]\n",
+ "a2m=a2**y \n",
+ "print\"The activity of the electrolyte ZnCl2 is\",round(a1,8)\n",
+ "print\"The activity of the electrolyte CuSO4 is\",round(a2,8)\n",
+ "print\"The mean molality of ZnCl2 in [m]\",round(m1m,4)\n",
+ "print\"The mean molality of CuSO4 in [m]\",m2m \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The activity of the electrolyte ZnCl2 is 1.43e-06\n",
+ "The activity of the electrolyte CuSO4 is 7.02e-06\n",
+ "The mean molality of ZnCl2 in [m] 0.0159\n",
+ "The mean molality of CuSO4 in [m] 0.005\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.15,Page no:172"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "m2=3 \t\t\t#mass of the sucrose[gm]\n",
+ "m1=0.1 \t\t\t#mass of water [Kg]\n",
+ "Kf=1.86 \t\t#cryoscopic constant of water[K*Kg/mol]\n",
+ "dTf=0.16 \t\t#Lowering in freezing point[K]\n",
+ "\t\n",
+ "a=m1*dTf \n",
+ "b=Kf*m2 \n",
+ "M2=b/a \t\t\t#molecular weight\n",
+ "print\"M2=molecular weight , then M2=\",M2 "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "M2=molecular weight , then M2= 348.75\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.16,Page no:173"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "dTf=0.088 \t\t\t#Lowering in freezing point[K]\n",
+ "m2=0.45 \t\t\t#mass of sulphur[gm]\n",
+ "m1=0.09955 \t\t\t#mass of benzene[gm]\n",
+ "Kf=5.07 \t\t\t#cryoscopic constant for benzene[K*Kg/mol]\n",
+ "\n",
+ "a=m1*dTf \n",
+ "b=Kf*m2 \n",
+ "M2=b/a \t\t\t\t#molecular weight of sulphur\n",
+ "print\"The molecular weight of sulphur is\",round(M2,1) \n",
+ "x=M2/32 \t\t\t#no. of sulphur atoms\n",
+ "print\"\\n The molecular formula of sulphur is S\",round(x) "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The molecular weight of sulphur is 260.4\n",
+ "\n",
+ " The molecular formula of sulphur is S 8.0\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.17,Page no:174"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "m2=1.35 \t\t\t#mass of a macromolecule[gm]\n",
+ "V=100\t \t\t\t#volume of solution[cm^3]\n",
+ "R=82 \t\t\t\t#Universal gas constant[atm.cm^3.K^-1]\n",
+ "T=300 \t\t\t\t#Temperature[K]\n",
+ "II=9.9 \t\t\t\t#osmotic pressure of the solution[cm]\n",
+ "d=1 \t\t\t\t#density\n",
+ "p=1013250 \t\t\t#Atmospheric pressure\n",
+ "g=980.67 \t\t\t#gravitational field\n",
+ "\n",
+ "\n",
+ "a=m2*R*T*p \n",
+ "b=V*9.9*d*g \n",
+ "M2=a/b #molar mass of macromolecule\n",
+ "print\" M2 = molar mass of macromolecule , therefore M2 = \",round(M2),\"g.mol^-1\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ " M2 = molar mass of macromolecule , therefore M2 = 34660.0 g.mol^-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.18,Page no:175"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "R=82 \t\t\t#Universal gas constant[atm.ml.K^-1.mol^-1]\n",
+ "T=298 \t\t\t#Temperature[K]\n",
+ "V=250 \t\t\t#volume of water[ml]\n",
+ "m2=2.6 \t\t\t#mass of the protein\n",
+ "M2=85000 \t\t#molar mass of protein[g.mol^-1]\n",
+ "\n",
+ "\t\n",
+ "n2=m2/M2 \t\t\t#no. of moles of protein\n",
+ "II=(n2*R*T)/V \t\t\t#Osmotic pressure of a solution[atm]\n",
+ "print\"The osmotic pressure is\",round(II,5),\"atm \"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The osmotic pressure is 0.00299 atm \n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.19,Page no:175"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "R=8.314 \t\t\t#Universal gas constant[J.K**-1.mol**-1]\n",
+ "Tb=373.15 \t\t\t#Boiling point temperature[K]\n",
+ "M1=0.018 \t\t\t# mass of water[kg]\n",
+ "Hvap=40.7 \t\t\t#Enthalpy of vaporization[KJ.mol**-1]\n",
+ "\n",
+ "a=R*0.001*Tb**2*M1 \n",
+ "b=Hvap \n",
+ "Kb=a/b \t\t\t\t#Ebullioscopic constant of water[K.Kg.mol**-1]\n",
+ "print\"The Ebullioscopic constant of water is\",round(Kb,2),\"K.Kg.mol-1\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Ebullioscopic constant of water is 0.51 K.Kg.mol-1\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.20,Page no:176"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "print\"CaF2(s)<=>CaF2(aq)<=>Ca+2(aq) + 2F-(aq)\"\n",
+ "\n",
+ "Ksp=4.0*(10**-11) \t#Solubility product of sparingly soluble salt CaF2\n",
+ "\n",
+ "x=Ksp/4.0 \n",
+ "Cs=x**(1.0/3.0) \t\t#Solubility \n",
+ "y=Cs**2 \n",
+ "Y=(x/y)**(1.0/3.0) \t\t#activity coefficient\n",
+ "print\"The activity coefficient is\",Y \n",
+ "print\"NOTE:please note that the value of Cs is wrongly calculated as 4.64*10^-11 in book\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "CaF2(s)<=>CaF2(aq)<=>Ca+2(aq) + 2F-(aq)\n",
+ "The activity coefficient is 0.0599484250319\n",
+ "NOTE:please note that the value of Cs is wrongly calculated as 4.64*10^-11 in book\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.21,Page no:177"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "T=298 \t\t\t\t#Temperature[K]\n",
+ "F=96500 \t\t\t#Faraday's constant\n",
+ "Eo=0.98 \t\t\t#Standard e.m.f of the cell[Volts]\n",
+ "E=1.16 \t\t\t\t#e.m.f of the cell[Volts]\n",
+ "m=0.01 \n",
+ "import math\n",
+ "\n",
+ "a=R*T \n",
+ "b=2*F \n",
+ "x=a/b \n",
+ "Y=math.exp((Eo-E-(x*math.log(4*m*m*m)))/(3*x)) #mean activity coefficient\n",
+ "print\"The mean activity coefficient is\",round(Y,2) "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The mean activity coefficient is 0.59\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.22,Page no:184"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "M1=0.01 \t\t\t#no. of moles of KCl\n",
+ "M2=0.005 \t\t\t#no. of moles of MgCl2\n",
+ "M3=0.002 \t\t\t#no. of moles of MgSO4\n",
+ "M=0.1 \t\t\t\t#mass of water[Kg]\n",
+ "z11=1 \n",
+ "z12=1 \n",
+ "z21=2 \n",
+ "z22=1 \n",
+ "z31=2 \n",
+ "z32=2 \n",
+ "\t\n",
+ "m1=M1/M \t\t\t#molality of KCL[m]\n",
+ "m2=M2/M \t\t\t#molality of MgCl2[m]\n",
+ "m3=M3/M \t\t\t#molality of MgSO4[m]\n",
+ "\n",
+ "I=0.5*((m1*z11**2+m1*z12**2+m2*z21**2+2*m2*z22**2+m3*z31**2+m3*z32**2)) #[mol/Kg]\n",
+ "print\"The Ionic strength of a solution is\",I,\"mol/Kg\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Ionic strength of a solution is 0.33 mol/Kg\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 6.23,Page no:185"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T=298 \t\t\t\t#Temperature[K]\n",
+ "P=1 \t\t\t\t#pressure [atm]\n",
+ "m=0.02\t \t\t\t#Ionic strength of HCl solution in CH3OH[mol/Kg]\n",
+ "E=32.6 \t\t\t\t#Di-electric constant\n",
+ "d=0.787 \t\t\t#Density[gm/cm3]\n",
+ "\t\n",
+ "I=0.5*(0.02*1*1+0.02*1*1) \t#Ionic strength of HCl solution[mol/Kg]\n",
+ "a=I*d \n",
+ "b=(E**3)*(298**3) \n",
+ "x=(a/b)**0.5 \n",
+ "Y=10**(-1.825*1000000*1*1*x) \t#mean activity coefficient\n",
+ "print\"The mean activity coefficient is\",round(Y,2) "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The mean activity coefficient is 0.58\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH7.ipynb b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH7.ipynb new file mode 100755 index 00000000..fdea70a8 --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/CH7.ipynb @@ -0,0 +1,537 @@ +{
+ "metadata": {
+ "name": ""
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "Chapter 7:Statistical Thermodynamics"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.1,Page number:193"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "N=20 \t\t\t\t#no, of particles\n",
+ "N1=4 \t\t\t\t#no. of particles in E1 energy level\n",
+ "N2=4 \t\t\t\t#no. of particles in E2 energy level\n",
+ "N3=6 \t\t\t\t#no. of particles in E3 energy level\n",
+ "N4=3 \t\t\t\t#no. of particles in E4 energy level\n",
+ "N5=3 \t\t\t\t#no. of particles in E5 energy level\n",
+ "import math\n",
+ "\t\n",
+ "Nf=math.factorial(N) \n",
+ "N1f=math.factorial(N1) \n",
+ "N2f=math.factorial(N2) \n",
+ "N3f=math.factorial(N3) \n",
+ "N4f=math.factorial(N4) \n",
+ "N5f=math.factorial(N5) \n",
+ "n=N1f*N2f*N3f*N4f*N5f \n",
+ "W=Nf/n \t\t\t#no. of ways of distributing\n",
+ "print\"The no. of ways of distributing the particles is\",W"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The no. of ways of distributing the particles is 162954792000\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.2,Page number:194"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T=298.0 \t\t\t#Temperature [K]\n",
+ "v=6.5*10**13 \t\t#Frequency in [sec-1]\n",
+ "\t#Consider zero point energy = 0.\n",
+ "h=6.627*10**-34 \t#planck's constant[J.s]\n",
+ "k=1.381*10**-23 \t#Boltzmann constant \n",
+ "N=1.0 \t\t\t#Since N=summation(gj*exp(-Ej/kT))\n",
+ "\n",
+ "E1=h*v \t\t\t#for energy level 1[J]\n",
+ "E2=2*h*v \t\t#for energy level 2[J]\n",
+ "x=k*T \n",
+ "g1=1.0 \n",
+ "g2=1.0 \n",
+ "import math\n",
+ "N1=(g1*math.exp(-E1/x)) #molecules present in energy level 1\n",
+ "N2=(g2*math.exp(-E2/x)) #molecules present in energy level 2\n",
+ "n1=N1/N \t\t#fraction of molecules present in energy level 1\n",
+ "n2=N2/N \t\t#fraction of molecules present in energy level 2\n",
+ "print\"The fraction of molecule s present in energy level 1 is\",'{0:.7f}'.format(round(n1,7)) \n",
+ "\n",
+ "\n",
+ "print\"The fraction of molecules present in energy level 2 is\",round(n2,10) \n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The fraction of molecule s present in energy level 1 is 0.0000285\n",
+ "The fraction of molecules present in energy level 2 is 8e-10\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.3,Page number:194"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "dE=4.3*10**-20 \t\t\t#difference in energy levels[J]\n",
+ "T1=0.000001 \t\t\t#Initial Temperature[K](approximately zero , needed for \t\t\t\texecution)\n",
+ "T2=300 \t\t\t\t#Final Temperature[K]\n",
+ "k=1.381*10**-23 \t\t#Boltzmann constant [J/K]\n",
+ "import math\n",
+ "\t\n",
+ "x1=k*T1 \n",
+ "r1=math.exp(-dE/x1) \n",
+ "x2=k*T2 \n",
+ "r2=math.exp(-dE/x2) \n",
+ "print\"The ratio of no. of particles per state at 0K is\",r1 \n",
+ "print\"The ratio of no. of particles per state at 300K is\",round(r2,6) "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The ratio of no. of particles per state at 0K is 0.0\n",
+ "The ratio of no. of particles per state at 300K is 3.1e-05\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.4,Page number:195"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T1=273.0 \t\t\t\t#[K]\n",
+ "T2=14273.0 \t\t\t#[K]\n",
+ "E1=-13.6 \t\t\t#Energy of ground state [eV]\n",
+ "k=8.617*10.0**-5.0 \t\t\t#Boltzmann constant[eV/K]\n",
+ "g2=8.0 \t\t\t\t#total no. of states with energy E2\n",
+ "g1=2.0 \t\t\t\t#total no. of states with energy E1\n",
+ "import math\n",
+ "\t\n",
+ "E2=E1/(2.0**2) \t\t#Energy for n=2 (i.e.E2=E1/n2)\n",
+ "x1=k*T1 \n",
+ "r1=(g2/g1)*math.exp(-(E2-E1)/x1) \n",
+ "x2=k*T2 \n",
+ "r2=(g2/g1)*math.exp(-(E2-E1)/x2) \n",
+ "print\"The fraction of atoms present in level n=2 at 273K is\", round(r1,190) \n",
+ "print\"Therefore total 3*10**25 atoms we say that all are present at ground state\" \n",
+ "print\"\\n\\nThe fraction of atoms present in level n=2 at 14273 is\",round(r2,3) \n",
+ "x=r2*3.0*10**25.0 \n",
+ "print\"Therefore no. of atoms in level n=2 is\",x \n",
+ "\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The fraction of atoms present in level n=2 at 273K is 1.97e-188\n",
+ "Therefore total 3*10**25 atoms we say that all are present at ground state\n",
+ "\n",
+ "\n",
+ "The fraction of atoms present in level n=2 at 14273 is 0.001\n",
+ "Therefore no. of atoms in level n=2 is 3.0021673634e+22\n"
+ ]
+ }
+ ],
+ "prompt_number": 6
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.5,Page number:195"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "r1=0.001 \t\t\t#the population of the states at a higher energy to that at a \t\t\t\tlower energy \n",
+ "dE=8*10**-20 \t\t\t#The difference in energy[J]\n",
+ "k=1.381*10**-23 \t\t\t#Boltzmann constant [J/K]\n",
+ "\n",
+ "\n",
+ "x=k*math.log(r1) \n",
+ "T=-dE/x #[K]\n",
+ "print\"The Temperature at this condition is\",round(T,1),\"K\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Temperature at this condition is 838.6 K\n"
+ ]
+ }
+ ],
+ "prompt_number": 7
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.6,Page number:196"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "w=1 \t\t\t#no. of ways of distributing the molecules\n",
+ "k=1.381*10**-23 \t#Boltzmann constant[J/K]\n",
+ "import math\n",
+ "\t\n",
+ "S1=k*math.log(w) \t\t#Entropy of system at 0K\n",
+ "print\"The Entropy of System at 0K and non-degenerate eng level is\",S1,\"J/K/mol\"\n",
+ "\n",
+ "n=2 \n",
+ "R=8.314 #Universal gas constant[J/K/mol]\n",
+ "\n",
+ "S2=R*math.log(n) #Entropy of the system[J/K/mol]\n",
+ "print\"\\nThe Entropy of system at 0K and degenerete eng level is\",round(S2,2),\"J/K/mol\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Entropy of System at 0K and non-degenerate eng level is 0.0 J/K/mol\n",
+ "\n",
+ "The Entropy of system at 0K and degenerete eng level is 5.76 J/K/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 8
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.9,Page number:202"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "V=0.001 \t\t\t#Volume of vessel[m3]\n",
+ "T=300 \t\t\t\t#Temperature [K]\n",
+ "k=1.381*10**-23 \t\t#Boltzmann constant[J/K]\n",
+ "mol_wt=32 \t\t\t#molecular mass of oxygen molecule\n",
+ "h=6.626*10**-34 \t\t#planck's constant[J.s}\n",
+ "\n",
+ "\n",
+ "\t\n",
+ "m=32*1.66*(10**-27) \t\t#mass of oxygen molecule[Kg]\n",
+ "x=((2*3.14*m*k*T)**(3.0/2.0))*V \n",
+ "y=h**3 \n",
+ "zt=x/y \t\t\t\t#Transitional partition function of an oxygen molecule\n",
+ "print\"The Transitional partition function of an oxygen molecule confined in a 1-litre vessel at 300K is\",zt\n",
+ "print\"Wrongly calculated in book as 5.328*10^33\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Transitional partition function of an oxygen molecule confined in a 1-litre vessel at 300K is 1.76621948031e+29\n",
+ "Wrongly calculated in book as 5.328*10^33\n"
+ ]
+ }
+ ],
+ "prompt_number": 9
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.12,Page number:204"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "R=1.99 \t\t\t#Universal gas constant [cal/K]\n",
+ "e=2.718 \n",
+ "V=22414 \t\t#volume[cm3]\n",
+ "L=6.023*10**23 \n",
+ "h=6.626*10**-27 \t#Planck's constant [erg.sec]\n",
+ "m=6.63*10**-23 \t\t#mass[gm]\n",
+ "k=1.381*10**-16 \t#Boltzmann constant[erg/K]\n",
+ "T=273.2 \t\t#Temperature[K]\n",
+ "import math\n",
+ "\t\n",
+ "x=V*(e**2.5) \n",
+ "y=L*(h**3) \n",
+ "z=(2*3.14*m*k*T)**1.5 \n",
+ "S=R*math.log(x*z/y) #Entropy [cal/degree/mol]\n",
+ "print\"The Entropy of argon at 273K and 1 atm is\",round(S,1),\"cal/degree/mol\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The Entropy of argon at 273K and 1 atm is 36.6 cal/degree/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 10
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.14,Page number:207"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "\n",
+ "T=298 \t\t\t\t#Temperature[K]\n",
+ "I=1.9373*10**-46 \t\t#moment of inertia of O2 gas [Kg/m2]\n",
+ "h=6.626*10**-34 \t\t\t#Planck's constant[J.s]\n",
+ "k=1.381*10**-23 \t\t\t#Boltzmann constant[J/K]\n",
+ "R=8.314 \t\t\t#Universal gas constant[J/K/mol]\n",
+ "u=2 \t\t\t\t#Homonuclear diatomic molecule\n",
+ "import math\n",
+ "\t\n",
+ "Sr=R+R*math.log(8*3.14*3.14*I*k*T/(u*h*h)) #[J/K/mol]\n",
+ "Gr=-R*0.001*T*math.log(8*3.14*3.14*I*k*T/(u*h*h)) #[KJ/mol]\n",
+ "print\"The rotational entropy for O2 gas is\",round(Sr,3),\"J/K/mol\"\n",
+ "print\"The rotational free energy for O2 gas is\",round(Gr,3),\"KJ/mol\"\n"
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The rotational entropy for O2 gas is 43.826 J/K/mol\n",
+ "The rotational free energy for O2 gas is -10.583 KJ/mol\n"
+ ]
+ }
+ ],
+ "prompt_number": 11
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.15,Page number:208"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T=298 \t\t\t\t#Temperature[K]\n",
+ "v=892.1*3*10**10 \t\t#frequency[sec-1]\n",
+ "h=6.626*10**-27 \t\t#Planck's constant [J.s]\n",
+ "k=1.381*10**-16 \t\t#Boltzmann constant[erg/K]\n",
+ "e=2.718 \n",
+ "R=1.998 \t\t\t#Universal gas constant[cal/K]\n",
+ "\t\n",
+ "import math\n",
+ "x=h*v/(k*T) \n",
+ "a=R*x*e**-x/(1-e**-x) \t\t#a=E-Eo/T\n",
+ "b=R*math.log(1-e**-x) \t\t#b=G-Eo/T\n",
+ "S=a-b \t\t\t\t#[cal/deg]\n",
+ "print\"The vibrational contribution to the entropy of F2 is\",round(S,4),\"cal/deg APPROX\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The vibrational contribution to the entropy of F2 is 0.1445 cal/deg APPROX\n"
+ ]
+ }
+ ],
+ "prompt_number": 12
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.16,Page number:211"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T=1273 \t\t\t\t#Temperature[K]\n",
+ "h=6.26*10**-27 \t\t\t#Planck's constant[J.s]\n",
+ "k=1.381*10**-16 \t\t\t#Boltzmann constant[erg/K]\n",
+ "T=1000 \t\t\t\t#Temperature[degrees]\n",
+ "m=3.82*10**-23 \t\t\t#mass of Na [gm]\n",
+ "I=(1.91*10**-23)*(3.078*10**-8)**2 \t#moment of inertia[gm.cm2]\n",
+ "dE=0.73*1.602*10**-12 \t\t\t#[erg]\n",
+ "v=159.23*(3*10**10)\t \t\t#frequency [s-1]\n",
+ "R=82 \t\t\t\t\t#universal gas constant[cm3.atm/deg]\n",
+ "u=2 \t\t\t\t\t#symmetry number\n",
+ "L=6.023*10**23 \t\t\t\t#avogadro's number\n",
+ "import math\n",
+ "\t\n",
+ "p=((3.14*m*k*T)**1.5)/h/h/h \n",
+ "s=R*u*h*h/L/8/3.14/3.14/I/k \n",
+ "q=1-(math.exp(-h*v/k/T)) \n",
+ "r=math.exp(-dE/k/T) \n",
+ "Kp=p*s*q*r \t\t\t\t#Equilibrium constant \n",
+ "print\"The equilibrium constant is\",round(Kp,3) "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The equilibrium constant is 0.608\n"
+ ]
+ }
+ ],
+ "prompt_number": 13
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example 7.17,Page number:212"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "T=298.0 #Temperature[K]\n",
+ "m1=32.0 \n",
+ "m2=36.0 \n",
+ "m3=34.0 \n",
+ "u1=8.0 \n",
+ "u2=9.0 \n",
+ "u3=16.0*18.0/34.0 \n",
+ "z1=0.99924 \n",
+ "z2=0.99951 \n",
+ "z3=0.99940 \n",
+ "h=6.26*10**-27 #Planck's constant[J.s]\n",
+ "c=3.0*10**10 #Speed of light[m/s]\n",
+ "k=1.38*10**-16 #Boltzman's constant[erg/K]\n",
+ "vo1=1535.8 #vibration frequency of 16O18O [cm-1]\n",
+ "vo2=1580.4 #vibration frequency of 16O2 [cm-1]\n",
+ "vo3=1490.0 #vibration frequency of 18O2 [cm-1]\n",
+ "dE=0.5*h*c*(2*vo1-vo2-vo3) #[erg]\n",
+ "r=dE/k/T \n",
+ "import math\n",
+ "\n",
+ "a=m3**3/m2**1.5/m1**1.5 \n",
+ "b=(u3**2)*4/u2/u1 \n",
+ "c=z3**2/z2/z1 \n",
+ "Kp=a*b*c*math.exp(-r) \n",
+ "print\"The value of equilibrium constant for isotopic exchange reaction is\",round(Kp,3) "
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "The value of equilibrium constant for isotopic exchange reaction is 3.996\n"
+ ]
+ }
+ ],
+ "prompt_number": 14
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/README.txt b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/README.txt new file mode 100755 index 00000000..c61dc121 --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/README.txt @@ -0,0 +1,10 @@ +Contributed By: Deepak Shakya +Course: btech +College/Institute/Organization: DCRUST +Department/Designation: Chemical Engg +Book Title: Thermodynamics: A Core Course +Author: R. C. Srivastava, S. K. Saha And A. K. Jain +Publisher: PHI Learning Pvt. Ltd. +Year of publication: 2004 +Isbn: 81-203-2498-6 +Edition: 2nd
\ No newline at end of file diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-1.png b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-1.png Binary files differnew file mode 100755 index 00000000..df57307c --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-1.png diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-2.png b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-2.png Binary files differnew file mode 100755 index 00000000..785f7970 --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-2.png diff --git a/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-3.png b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-3.png Binary files differnew file mode 100755 index 00000000..a71d57e5 --- /dev/null +++ b/Thermodynamics:_A_Core_Course_by_R._C._Srivastava,_S._K._Saha_And_A._K._Jain/screenshots/deepak-2-3.png diff --git a/f_by_df/chapter25.ipynb b/f_by_df/chapter25.ipynb new file mode 100644 index 00000000..894eff9f --- /dev/null +++ b/f_by_df/chapter25.ipynb @@ -0,0 +1,210 @@ +{ + "metadata": { + "name": "", + "signature": "sha256:9895a0f3fc78aa13cc793dfc60b4d616a3af11e4983465d122ac29be7197893e" + }, + "nbformat": 3, + "nbformat_minor": 0, + "worksheets": [ + { + "cells": [ + { + "cell_type": "heading", + "level": 1, + "metadata": {}, + "source": [ + "Chapter 25: Elements of Electro-Mechanical Energy Conversion" + ] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example Number 25.1, Page Number:876" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#variable declaration\n", + "sod=15#stator-core outer diameter\n", + "sid=10.05#stator-core inner diameter\n", + "rod=10.00#rotor-core outer diameter\n", + "rid=5#rotor-core inner diameter\n", + "a=8#axial lenght of the machine\n", + "b=1.20\n", + "ur=1000\n", + "#calculations\n", + "vs=(3.14/4)*((sod*sod)-(sid*sid))*a#volume of stator-core\n", + "vr=(3.14/4)*((rod*rod)-(rid*rid))*a#volume of rotor-core\n", + "va=(3.14/4)*((sid*sid)-(rod*rod))*a#volume of air-gap in the machine\n", + "ed=(.5*b*b)/(4*3.14*math.pow(10,-7))\n", + "e=ed*va*math.pow(10,-6)\n", + "edm=(.5*b*b)/(4*3.14*math.pow(10,-7)*ur)\n", + "es=edm*vs*math.pow(10,-6)\n", + "er=edm*vr*math.pow(10,-6)\n", + "kr=(vs+vr)/vs\n", + "ke=(es+er)/e\n", + "ratio=kr/ke\n", + "eratio=e/(es+er)\n", + "\n", + "#result\n", + "print \"Energy stored in air gap= \",e,\" Joules\"\n", + "print \"Energy stored in stator-core= \",round(es,2),\" Joules\"\n", + "print \"Energy stored in rotor core= \",er,\" Joules\"\n", + "print \"Ratio of energy dtored in air-gap to that stored in the cores=\",round(eratio)\n" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "Energy stored in air gap= 3.609 Joules\n", + "Energy stored in stator-core= 0.45 Joules\n", + "Energy stored in rotor core= 0.27 Joules\n", + "Ratio of energy dtored in air-gap to that stored in the cores= 5.0\n" + ] + } + ], + "prompt_number": 2 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example Number 25.2, Page Number:877" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "import math\n", + "\n", + "#variable declaration\n", + "n=800#turns\n", + "area=5*5#cross sectional area\n", + "i=1.25#amp\n", + "x=0.25#cm\n", + "l=0.402\n", + "#calculations\n", + "p=4*3.14*10**(-7)*area*10**(-4)/(0.5*10**(-2))\n", + "l=n**2*p\n", + "em=.5*i*i*l\n", + "W=-1*0.5*n**2*4*3.14*10**(-7)*area*10**(-4)*i**2/(0.5*10**(-2))**2\n", + "\n", + "#result\n", + "print \"a)i)coil inductance=\",l,\"H\"\n", + "print \" ii)field energy stored=\",em,\"J\"\n", + "print \"b)mechanical energy output=\",W,\"NW\"" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "a)i)coil inductance= 0.40192 H\n", + " ii)field energy stored= 0.314 J\n", + "b)mechanical energy output= -62.8 NW\n" + ] + } + ], + "prompt_number": 13 + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example Number 25.4, Page Number:882" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "#variable declaration\n", + "lo=50#mH\n", + "xo=0.05#cm\n", + "r=0.5#ohm\n", + "x=0.075#cm\n", + "i2=3#A\n", + "x2=0.15#cm\n", + "\n", + "#calculation\n", + "l1=2*lo/(1+(x/xo))\n", + "lambda1=l1*i2*10**(-3)\n", + "W=0.5*l1*i2**2*10**(-3)\n", + "l2=2*lo/(1+(x2/xo))\n", + "lambda2=l2*i2*10**(-3)\n", + "w2=0.5*i2*(lambda1-lambda2)\n", + "\n", + "#result\n", + "print \"a)magnetic stored energy=\",W,\"J\"\n", + "print \"b)change in magnetic stored energy=\",w2,\"J\"" + ], + "language": "python", + "metadata": {}, + "outputs": [] + }, + { + "cell_type": "heading", + "level": 2, + "metadata": {}, + "source": [ + "Example Number 25.5, Page Number:883" + ] + }, + { + "cell_type": "code", + "collapsed": false, + "input": [ + "#variable declaration\n", + "rc=0.5#ohm\n", + "v=3#V\n", + "i=6#A\n", + "l1=40#mH\n", + "l2=25#mH\n", + "wfld=0.5*l2*i*i*0.001\n", + "delE=0.5*i*i*0.001*(l1-l2)\n", + "\n", + "#result\n", + "print \"a)magnetic stored energy=\",wfld,\"J\"\n", + "print \"b)change in magnetic store energy=\",delE,\"J\"" + ], + "language": "python", + "metadata": {}, + "outputs": [ + { + "output_type": "stream", + "stream": "stdout", + "text": [ + "a)magnetic stored energy= 0.45 J\n", + "b)change in magnetic store energy= 0.27 J\n" + ] + } + ], + "prompt_number": 3 + }, + { + "cell_type": "code", + "collapsed": false, + "input": [], + "language": "python", + "metadata": {}, + "outputs": [] + } + ], + "metadata": {} + } + ] +}
\ No newline at end of file diff --git a/f_by_df/screenshots/29.png b/f_by_df/screenshots/29.png Binary files differnew file mode 100644 index 00000000..0c99fa16 --- /dev/null +++ b/f_by_df/screenshots/29.png diff --git a/f_by_df/screenshots/32.png b/f_by_df/screenshots/32.png Binary files differnew file mode 100644 index 00000000..1e7a1724 --- /dev/null +++ b/f_by_df/screenshots/32.png diff --git a/sample_notebooks/Raj Kumar/ch3.ipynb b/sample_notebooks/Raj Kumar/ch3.ipynb index 30e9780e..2ded4a4d 100644 --- a/sample_notebooks/Raj Kumar/ch3.ipynb +++ b/sample_notebooks/Raj Kumar/ch3.ipynb @@ -16,7 +16,7 @@ }, { "cell_type": "code", - "execution_count": 26, + "execution_count": 1, "metadata": { "collapsed": false }, @@ -66,7 +66,7 @@ }, { "cell_type": "code", - "execution_count": 13, + "execution_count": 2, "metadata": { "collapsed": false }, @@ -108,7 +108,7 @@ }, { "cell_type": "code", - "execution_count": 15, + "execution_count": 3, "metadata": { "collapsed": false }, @@ -169,7 +169,7 @@ }, { "cell_type": "code", - "execution_count": 18, + "execution_count": 4, "metadata": { "collapsed": false }, @@ -227,7 +227,7 @@ }, { "cell_type": "code", - "execution_count": 22, + "execution_count": 5, "metadata": { "collapsed": false }, @@ -286,7 +286,7 @@ }, { "cell_type": "code", - "execution_count": 24, + "execution_count": 6, "metadata": { "collapsed": false }, @@ -342,7 +342,7 @@ }, { "cell_type": "code", - "execution_count": 25, + "execution_count": 7, "metadata": { "collapsed": false }, |