diff options
author | Thomas Stephen Lee | 2015-09-04 22:04:10 +0530 |
---|---|---|
committer | Thomas Stephen Lee | 2015-09-04 22:04:10 +0530 |
commit | 41f1f72e9502f5c3de6ca16b303803dfcf1df594 (patch) | |
tree | f4bf726a3e3ce5d7d9ee3781cbacfe3116115a2c /Applied_Physics_by_P_K_Palanisamy/Chapter1_1.ipynb | |
parent | 9c9779ba21b9bedde88e1e8216f9e3b4f8650b0e (diff) | |
download | Python-Textbook-Companions-41f1f72e9502f5c3de6ca16b303803dfcf1df594.tar.gz Python-Textbook-Companions-41f1f72e9502f5c3de6ca16b303803dfcf1df594.tar.bz2 Python-Textbook-Companions-41f1f72e9502f5c3de6ca16b303803dfcf1df594.zip |
add/remove/update books
Diffstat (limited to 'Applied_Physics_by_P_K_Palanisamy/Chapter1_1.ipynb')
-rwxr-xr-x | Applied_Physics_by_P_K_Palanisamy/Chapter1_1.ipynb | 214 |
1 files changed, 214 insertions, 0 deletions
diff --git a/Applied_Physics_by_P_K_Palanisamy/Chapter1_1.ipynb b/Applied_Physics_by_P_K_Palanisamy/Chapter1_1.ipynb new file mode 100755 index 00000000..49ab34ca --- /dev/null +++ b/Applied_Physics_by_P_K_Palanisamy/Chapter1_1.ipynb @@ -0,0 +1,214 @@ +{
+ "metadata": {
+ "name": "",
+ "signature": "sha256:358f4a01b294025154ed5b68aa4867e70b7293d6e35ba5318010f0ecabaea268"
+ },
+ "nbformat": 3,
+ "nbformat_minor": 0,
+ "worksheets": [
+ {
+ "cells": [
+ {
+ "cell_type": "heading",
+ "level": 1,
+ "metadata": {},
+ "source": [
+ "1: Bonding in Solids"
+ ]
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example number 1.1, Page number 1.4"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration\n",
+ "IE_1 = 502 #first ionisation energy(kJ/mol)\n",
+ "EA_B = -335 #electron affinity for B atom(kJ/mol)\n",
+ "e = 1.602*10**-19\n",
+ "r = 0.3 #inter ionic seperation(nm)\n",
+ "epsilon0 = 8.85*10**-12 #permittivity of free space(C/N-m)\n",
+ "\n",
+ "#Calculation\n",
+ "r = r*10**-9 #inter ionic seperation(m)\n",
+ "N = 6.022*10**23*10**-3\n",
+ "E = (-e**2*N)/(4*math.pi*epsilon0*r) #electrostatic attraction energy(kJ/mol)\n",
+ "dE = IE_1+EA_B+E; #net change in energy per mole\n",
+ "\n",
+ "#Result\n",
+ "print \"electrostatic attraction energy is\",int(E),\"kJ/mol\"\n",
+ "print \"net change in energy is\",int(dE),\"kJ/mol\"\n",
+ "print \"A+B- molecule will be stable\"\n",
+ "print \"answer for net change,dE given in the book is wrong\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "electrostatic attraction energy is -463 kJ/mol\n",
+ "net change in energy is -296 kJ/mol\n",
+ "A+B- molecule will be stable\n",
+ "answer for net change,dE given in the book is wrong\n"
+ ]
+ }
+ ],
+ "prompt_number": 2
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example number 1.2, Page number 1.5"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration\n",
+ "IP_K = 4.1 #IP of K(eV)\n",
+ "EA_Cl = 3.6 #EA of Cl(eV)\n",
+ "e = 1.602*10**-19\n",
+ "epsilon0 = 8.85*10**-12 \n",
+ "\n",
+ "#Calculation\n",
+ "delta_E = IP_K - EA_Cl #energy required(eV)\n",
+ "#if their total energy is 0, delta_E = Ec\n",
+ "Ec = delta_E\n",
+ "R = e/(4*math.pi*epsilon0*Ec) #seperation between ion pair(m)\n",
+ "R = R*10**9 #seperation between ion pair(nm)\n",
+ "R = math.ceil(R*10**3)/10**3; #rounding off to 3 decimals\n",
+ "\n",
+ "#Result\n",
+ "print \"energy required to form K+Cl- ion pair is\",delta_E,\"eV\"\n",
+ "print \"seperation between ion pair is\",R,\"nm\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "energy required to form K+Cl- ion pair is 0.5 eV\n",
+ "seperation between ion pair is 2.881 nm\n"
+ ]
+ }
+ ],
+ "prompt_number": 3
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example number 1.3, Page number 1.6"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration\n",
+ "e = 1.602*10**-19\n",
+ "EA = 3.65 #electron affinity of Cl(eV)\n",
+ "IP = 5.14 #ionisation energy of Na(eV)\n",
+ "epsilon0 = 8.85*10**-12\n",
+ "r0 = 236 #equilibrium distance(pm)\n",
+ "\n",
+ "#Calculation\n",
+ "r0 = r0*10**-12 #equilibrium distance(m)\n",
+ "V = (-e**2)/(4*math.pi*epsilon0*r0) ##potential energy(J)\n",
+ "V = V/e #potential energy(eV)\n",
+ "Ue = V\n",
+ "BE = -Ue - IP + EA #bond energy(eV)\n",
+ "BE = math.ceil(BE*10**3)/10**3; #rounding off to 3 decimals\n",
+ "\n",
+ "#Result\n",
+ "print \"bond energy for NaCl molecule is\",BE,\"eV\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "bond energy for NaCl molecule is 4.614 eV\n"
+ ]
+ }
+ ],
+ "prompt_number": 4
+ },
+ {
+ "cell_type": "heading",
+ "level": 2,
+ "metadata": {},
+ "source": [
+ "Example number 1.4, Page number 1.19"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "collapsed": false,
+ "input": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration\n",
+ "e = 1.602*(10**-19)\n",
+ "epsilon0 = 8.85*(10**-12)\n",
+ "r0 = 0.281 #equilibrium seperation(nm)\n",
+ "A = 1.748 #Madelung constant\n",
+ "n = 9 #born repulsive exponent\n",
+ "\n",
+ "#Calculation\n",
+ "r0 = r0*10**-9 #equilibrium seperation(m)\n",
+ "CE = (A*e**2)*(1-(1/n))/(4*math.pi*epsilon0*r0) #cohesive energy(J)\n",
+ "CE = CE/e #cohesive energy(eV)\n",
+ "CE = math.ceil(CE*10**3)/10**3; #rounding off to 3 decimals\n",
+ "\n",
+ "#Result\n",
+ "print \"cohesive energy of NaCl is\",CE,\"eV\""
+ ],
+ "language": "python",
+ "metadata": {},
+ "outputs": [
+ {
+ "output_type": "stream",
+ "stream": "stdout",
+ "text": [
+ "cohesive energy of NaCl is 7.966 eV\n"
+ ]
+ }
+ ],
+ "prompt_number": 5
+ }
+ ],
+ "metadata": {}
+ }
+ ]
+}
\ No newline at end of file |