{
 "metadata": {
  "name": "",
  "signature": "sha256:d284e33c3a44645a717587479459459fbad97c0b83247c27d3e8959966515278"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 2 Transport Phenomena in semiconductors"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.1 Page no 22"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Given\n",
      "n=10**20\n",
      "q=1.6*10**-19\n",
      "u=800\n",
      "e=1\n",
      "\n",
      "#Calculation\n",
      "J=n*q*u*e\n",
      "\n",
      "#Result\n",
      "print\"Electron current density is \",J*10**-4,\"*10**4 A/cm**2\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Electron current density is  1.28 *10**4 A/cm**2\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.2 Page no 27"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Given\n",
      "Nd=10**12                        #/cm**3\n",
      "ni=10**10                        #/cm**3\n",
      "Nd1=10**18\n",
      "\n",
      "#Calculation\n",
      "import math\n",
      "n=Nd+math.sqrt(Nd+4*(ni**2))/2.0\n",
      "n1=Nd1+math.sqrt(Nd1+4*(ni**2))/2.0\n",
      "\n",
      "#Result\n",
      "print\"(a) free electron at 10**12 is \", round(n*10**-12,2),\"*10**12 /cm**3\",\"and hole density is  p=9.999*10**7 /cm**3\"\n",
      "print\"(b) free electron at 10**18 is \",round(n1*10**-18,2),\"*10**18 /cm**3\",\"and hole density is p=10**2 /cm**3\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "(a) free electron at 10**12 is  1.01 *10**12 /cm**3 and hole density is  p=9.999*10**7 /cm**3\n",
        "(b) free electron at 10**18 is  1.0 *10**18 /cm**3 and hole density is p=10**2 /cm**3\n"
       ]
      }
     ],
     "prompt_number": 28
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.3 Page no 29"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Given\n",
      "K=6.02*10**23                     #atoms/mole\n",
      "b=72.6                            #g\n",
      "c=5.32                            #g/cm**3\n",
      "n=2.5*10**13                      #cm**3\n",
      "q=1.60*10**-19                     #C\n",
      "un=3800                            #cm**2/V-s\n",
      "up=1800                            #cm**2/V-s\n",
      "ni=2.5*10**13\n",
      "Nd=4.41*10**14\n",
      "x=1.60*10**-19\n",
      "n1=4.41*10**22                     #electron/cm**3\n",
      "\n",
      "#Calculation\n",
      "C=K*(1/b)*c\n",
      "A=n*q*(un+up)\n",
      "R=1/A\n",
      "p=ni**2/Nd\n",
      "A1=Nd*x*un\n",
      "R1=1/A1\n",
      "A2=n1*x*un\n",
      "X=A2/A1\n",
      "\n",
      "#Result\n",
      "print\"(a) Concentration of atoms in germanium is \", round(C*10**-22,2) *10**22,\"atoms/cm**3\"\n",
      "print\"(b) resistivity of intrinsic germanium at 300 degree K is \", round(R,1),\"ohm-cm\"\n",
      "print\"(c) Resistivity is \", round(R1,2),\"ohm-cm\"\n",
      "print\"(d) Ratio of conductivity is \",X"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "(a) Concentration of atoms in germanium is  4.41e+22 atoms/cm**3\n",
        "(b) resistivity of intrinsic germanium at 300 degree K  44.6 ohm-cm\n",
        "(c) Resistivity is  3.73 ohm-cm\n",
        "(d) Ratio of conductivity is  100000000.0\n"
       ]
      }
     ],
     "prompt_number": 53
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.5 Page no 35 "
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Given\n",
      "g=5*10**21\n",
      "t=2*10**-6                  #/cm**3\n",
      "\n",
      "#Calculation\n",
      "p=g*t\n",
      "\n",
      "#Result\n",
      "print\"Hole density in the semiconductor is \", p,\"/cm**3\""
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Hole density in the semiconductor is  1e+16 /cm**3\n"
       ]
      }
     ],
     "prompt_number": 56
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.7 Page no 40"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Given\n",
      "un=1200                             #cm**2/V-s\n",
      "n0=10.0**18                         #/cm**3\n",
      "ni=10**10                           #/cm**3\n",
      "up=500                              #cm**2/V-s\n",
      "t=2*10**-6                          #S\n",
      "K=5*10**15                          #/cm**3\n",
      "K1=8.620*10**-5                     #eV/degree K\n",
      "q=1.602*10**-19                     #C\n",
      "T=50\n",
      "Lp=51.0*10**-4\n",
      "p0=100\n",
      "Dn=31.2\n",
      "x=0\n",
      "\n",
      "#Calculation\n",
      "import math\n",
      "p0=ni**2/n0\n",
      "Dp=(((K1*T)/q)*up)*10**-18\n",
      "Jp=((q*Dp)/Lp)*(K-p0)*math.exp(x/Lp)\n",
      "Lp=math.sqrt(Dp*t)\n",
      "Jn=-((Dn/Dp)*Jp)*math.exp(x/Lp)\n",
      "Jn1=((Dn/Dp-1)*Jp)*math.exp(x/Lp)\n",
      "Jp1=((K*up)/(n0*un))*(Dn/Dp-1)*Jp\n",
      "\n",
      "#Result\n",
      "print\"The drift current density for holes is \", round(Jp1,4),\"exp(-x/Lp)\",\"A/cm**2\"\n",
      "print\"The diffusion current density for holes is \",round(Jp,2),\"exp(-x/Lp)\",\"A/cm**2\"\n",
      "print\"The diffusion current density for electrons is \",round(Jn,2),\"exp(-x/Lp)\",\"A/cm**2\"\n",
      "print\"The drift current density for electrons is \",round(Jn1,2),\"exp(-x/Lp)\",\"A/cm**2\"\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The drift current density for holes is  0.0058 exp(-x/Lp) A/cm**2\n",
        "The diffusion current density for holes is  2.11 exp(-x/Lp) A/cm**2\n",
        "The diffusion current density for electrons is  -4.9 exp(-x/Lp) A/cm**2\n",
        "The drift current density for electrons is  2.79 exp(-x/Lp) A/cm**2\n"
       ]
      }
     ],
     "prompt_number": 37
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2.8 Page no 41"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Given\n",
      "ni=1.5*10**10                       #/cm**3\n",
      "Nd=10**18                           #/cm**3\n",
      "Na=10**14\n",
      "Vt=2.4*10**18\n",
      "Na1=10**15\n",
      "Na2=10**16\n",
      "Na3=10**17\n",
      "Na4=10**18\n",
      "Na5=10**19\n",
      "\n",
      "#Calculation\n",
      "import math\n",
      "V0=Vt*(math.log(Na*Nd)/ni**2)\n",
      "V01=Vt*(math.log(Na1*Nd)/ni**2)\n",
      "V02=Vt*(math.log(Na2*Nd)/ni**2)\n",
      "V03=Vt*(math.log(Na3*Nd)/ni**2)\n",
      "V04=Vt*(math.log(Na4*Nd)/ni**2)\n",
      "V05=Vt*(math.log(Na5*Nd)/ni**2)\n",
      "\n",
      "#Result\n",
      "print\"Contact potential across the junction is \"\n",
      "print round(V0,2),\"\\n\", round(V01,2),\"\\n\" ,round(V02,2),\"\\n\" ,round(V03,2),\"\\n\",round(V04,1),\"\\n\",round(V05,0)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "Contact potential across the junction is \n",
        "0.79 \n",
        "0.81 \n",
        "0.84 \n",
        "0.86 \n",
        "0.9 \n",
        "1.0\n"
       ]
      }
     ],
     "prompt_number": 31
    }
   ],
   "metadata": {}
  }
 ]
}