{
 "metadata": {
  "name": ""
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 10:The Solid state"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 10.1,Page no:342"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration \n",
      "import math\n",
      "Ro= 0.281  #equilibrium distance between ions, nm\n",
      "alpha= 1.748  #Madelung constant\n",
      "n= 9  #exponent, from observed compressibilities of NaCl\n",
      "e= 1.6*(10**(-19))  #charge of an electron, C\n",
      "Po= 8.85*(10**(-12))  #Permittivity of free space, F/m\n",
      "\n",
      "#Calculation\n",
      "K=1.0/(4*(math.pi)*Po)  #constant, N.m**2/C**2\n",
      "Uo= -(K*alpha*(e**2)*(1.0-(1.0/n)))/(Ro*(10**(-9)))  #Potential energy per ion pair, J\n",
      "Uo= Uo/e  #converting to eV\n",
      "E1= 5.14  #Ionisation energy for Na, eV\n",
      "E2= -3.61  #electron affinity of Cl, eV\n",
      "E= E1+E2  #Electron transfer energy, eV\n",
      "Ecohesive = (Uo +E)  #per electron pair, eV\n",
      "Ecohesive= Ecohesive/2.0  #for each ion, eV\n",
      "\n",
      "#Result\n",
      "print\"The cohesive energy in NaCl is: \",round(Ecohesive,2),\"eV\"\n",
      "print\"\\nWhich is not far from experimental value of -3.28 eV\"\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The cohesive energy in NaCl is:  -3.21 eV\n",
        "\n",
        "Which is not far from experimental value of -3.28 eV\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {},
     "source": [
      "Example 10.2,Page no:350"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "\n",
      "#Variable declaration \n",
      "A= 1.0  #cross-sectional area of wire, mm**2\n",
      "I= 1.0  #current in wire, A\n",
      "n= 8.5*(10**28)  # electrons/m**3\n",
      "e= 1.6*(10**(-19))  #charge of an electron, C\n",
      "\n",
      "#Calculation\n",
      "Vdrift= I/(n*(A*(10**(-6)))*e)  #m/s\n",
      "\n",
      "#Result\n",
      "print\"The drift velocity of electrons in the copper wire is:%.2g\"%Vdrift,\"m/s\"\n",
      "print\"\\nNOTE:Calculation mistake in book.Wrongly written as 7.4*10^-4\"\n",
      " \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The drift velocity of electrons in the copper wire is:7.4e-05 m/s\n",
        "\n",
        "NOTE:Calculation mistake in book.Wrongly written as 7.4*10^-4\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 3,
     "metadata": {},
     "source": [
      "Example 10.3,Page no:353"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration \n",
      "n= 8.48*(10**28)  #free electron density, m**(-3)\n",
      "Vfermi= 1.57*(10**6)  #Fermi Velocity, m/s\n",
      "rho= 1.72*(10**(-8))  #resistivity, ohm\n",
      "e= 1.6*(10**(-19))  #charge of an electron, C\n",
      "Me= 9.1*(10**(-31))  #mass of electron, kg\n",
      "\n",
      "#Calculation\n",
      "lamda= Me*Vfermi/(n*(e**2)*rho)  #m\n",
      "lamda= lamda*(10**9)  #converting to nm\n",
      "\n",
      "#Result\n",
      "print\"The mean free path is:\",round(lamda,1),\"nm\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The mean free path is: 38.3 nm\n"
       ]
      }
     ],
     "prompt_number": 4
    }
   ],
   "metadata": {}
  }
 ]
}