{
 "metadata": {
  "name": ""
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter 20: Cathode Ray Oscilloscope"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 1, Page 575"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "#Variable declaration\n",
      "e=1.6*10**-19#e=charge of an electron\n",
      "Va=1000.#Va=potential difference in volts\n",
      "m=9.11*10**-31#m=mass of an electron\n",
      "\n",
      "#Calculations&Results\n",
      "v=math.sqrt((2*e*Va)/m)#v=axial velocity of an electron\n",
      "l=2*10**-2#l=axial length of deflecting plates in metre\n",
      "t=l/v#t=transit time of the beam through the deflecting plates\n",
      "print \"The transit time is = %.2e s\"%t\n",
      "Vd=20#Vd=potential difference applied between the deflecting plates in volts\n",
      "s=5*10**-3#s=separation between the plates in metre\n",
      "ta=(e*Vd)/(s*m)#ta=the traverse acceleration imparted to the electrons by the deflecting voltage\n",
      "print \"Traverse acceleration is = %.3e m/s^2\"%ta\n",
      "L=25*10**-2#L=distance of the CRT screen from the centre of the deflecting plates in metre\n",
      "d=(l*L*Vd)/(2*s*Va)#d=deflection of the spot on the CRT screen\n",
      "print \"Spot deflection is = %.f cm\"%(d*100)#d is converted in terms of cm\n",
      "S=d/Vd#S=deflection sensitivity\n",
      "print \"Deflection sensitivity is = %.1f mm/V\"%(S/10**-3)#S is converted in terms of mm/V"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The transit time is = 1.07e-09 s\n",
        "Traverse acceleration is = 7.025e+14 m/s^2\n",
        "Spot deflection is = 1 cm\n",
        "Deflection sensitivity is = 0.5 mm/V\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 2, Page 575"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "#Variable declaration\n",
      "e=1.6*10**-19#e=charge of an electron\n",
      "Va=1000#Va=potential difference in volts\n",
      "m=9.11*10**-31#m=mass of an electron\n",
      "\n",
      "#Calculations\n",
      "v=math.sqrt((2*e*Va)/m)#v=axial velocity of an electron\n",
      "l=1.5*10**-2#l=axial length of deflecting plates in metre\n",
      "t=l/v#t=transit time of the beam through the deflecting plates\n",
      "#T=time period of the sinusoidal deflecting voltage \n",
      "#tmax=maximum transit time\n",
      "#(0.1/360)*T=tmax,since 1 cycle corresponds to 360 degrees\n",
      "T=(t*360)/0.1\n",
      "f=1/T#f=highest frequency of the deflecting voltage\n",
      "\n",
      "#Results\n",
      "print \"The highest frequency of the deflecting voltage is = %.f kHz\"%(f/1000)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The highest frequency of the deflecting voltage is = 347 kHz\n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 3, Page 576"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "#Variable declaration\n",
      "V=1000#V=potential difference in volts\n",
      "#B=150 gauss (given)\n",
      "B=1.5*10**-2#B=magnetic field in tesla\n",
      "l=1*10**-2#l=axial length of deflecting plates in metre\n",
      "L1=20*10**-2#L1=(L+(l/2))=distance of the fluorescent screen from the centre of the deflection system in metre\n",
      "e=1.6*10**-19#e=charge of an electron\n",
      "m=9.11*10**-31#m=mass of an electron\n",
      "\n",
      "#Calculations&Results\n",
      "d=B*math.sqrt(e/(2*V*m))*l*L1#d=deflection of the spot \n",
      "print \"The deflection of the spot is=%.1f cm\"%(d*100)\n",
      "Sm=d/B#Sm=magnetic deflection sensitivity\n",
      "print \"The magnetic deflection sensitivity is=%.2f mm/gauss\"%(Sm/10)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The deflection of the spot is=28.1 cm\n",
        "The magnetic deflection sensitivity is=1.87 mm/gauss\n"
       ]
      }
     ],
     "prompt_number": 6
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 4, Page 576"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "sw=10#sw=sweep width in cm\n",
      "n=5./2#n=number of cycles given by vertical deflection plates\n",
      "\n",
      "#Calculations\n",
      "c=sw/n#c=centimetres occupied by one cycle of signal\n",
      "ct=0.1#ct=calibrated time base of CRO in ms/cm\n",
      "t=ct*c#t=time interval corresponding to centimetres occupied by one cycle of signal\n",
      "T=t/5#T=time period of the signal,since the scale is 5 times magnified\n",
      "f=1/T#f=frequency of the signal\n",
      "\n",
      "#Results\n",
      "print \"The frequency of the signal is = %.1f kHz\"%f"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The frequency of the signal is = 12.5 kHz\n"
       ]
      }
     ],
     "prompt_number": 8
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 5, Page 576"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "#Variable declaration\n",
      "#Let fv=frequency of the vertical signals in kHz\n",
      "#fh=frequency of the horizontal signals \n",
      "#Number of horizontal tangencies=nh\n",
      "#Number of vertical tangencies=nv\n",
      "#fv/fh=nh/nv\n",
      "fh=1\n",
      "nh=3.\n",
      "nv=4\n",
      "\n",
      "#Calculations\n",
      "fv=(nh/nv)*fh\n",
      "\n",
      "#Results\n",
      "print \"The frequency of the vertical signal is = %.f Hz\"%(fv*1000)\n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "The frequency of the vertical signal is = 750 Hz\n"
       ]
      }
     ],
     "prompt_number": 10
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Example 6, Page 576"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "import math\n",
      "\n",
      "#Variable declaration\n",
      "#slope of the major axis is negative (given)\n",
      "A=2.6#A=The maximum y-displacement\n",
      "vyo=1.1#vyo=the vertical displacement\n",
      "\n",
      "#Calculations&Results\n",
      "sino=(vyo/A)#o=phase difference between the two voltages\n",
      "x=math.degrees(math.asin(sino))\n",
      "\n",
      "#Results\n",
      "print \"As the major axis of the ellipse has a negative slope,phase difference between the two voltages must lie between\",\\\n",
      "\"90 degree and 180 degree\"\n",
      "print \"Therefore,phase difference between the voltages is = %.f degrees\"%(180-x)"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "As the major axis of the ellipse has a negative slope,phase difference between the two voltages must lie between 90 degree and 180 degree\n",
        "Therefore,phase difference between the voltages is = 155 degrees\n"
       ]
      }
     ],
     "prompt_number": 18
    }
   ],
   "metadata": {}
  }
 ]
}