{
 "metadata": {
  "name": "",
  "signature": "sha256:4015b0a9a33cac1d31d06283c1020edbd79893138244c7d49c1c64131de1b42b"
 },
 "nbformat": 3,
 "nbformat_minor": 0,
 "worksheets": [
  {
   "cells": [
    {
     "cell_type": "heading",
     "level": 1,
     "metadata": {},
     "source": [
      "Chapter6-Beta-Decay"
     ]
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex1-pg240"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.1: : Page- 240 (2011)\n",
      "#find The rate at which energy is emitted\n",
      "T = 5*24*60*60;    ## Half life of the substance, sec\n",
      "N = 6.023e+026*4e-06/210;        ## Number of atoms\n",
      "D = 0.693/T;           ## Disintegration constant, per sec\n",
      "K = D*N;                ## Rate of disintegration, \n",
      "E = 0.34*1.60218e-013;        ## Energy of the beta particle, joule\n",
      "P = E*K;                    ##   Rate at which energy is emitted, watt\n",
      "print'%s %.2f %s'%(\"\\nThe rate at which energy is emitted = \",P,\" watt\");\n",
      "\n",
      "## Result\n",
      "## The rate at which energy is emitted = 1 watt \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The rate at which energy is emitted =  1.00  watt\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex2-pg241"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.2 : : Page-241 (2011)\n",
      "#find The magnetic field perpendicular to the beam of the particle \n",
      "M_0 = 9.10939e-031;         ## Rest mass of the electron, Kg\n",
      "C = 2.92e+08;            ## Velocity of the light, metre per sec\n",
      "E = 1.71*1.60218e-013;        ## Energy of the beta particle, joule\n",
      "e = 1.60218e-019;                ## Charge of the electron, C \n",
      "R = 0.1;                     ## Radius of the orbit, metre\n",
      "B = M_0*C*(E/(M_0*C**2)+1)*1/(R*e); ## Magnetic field perpendicular to the beam  of the particle, weber per square metre\n",
      "\n",
      "print'%s %.2f %s'%(\"\\nThe magnetic field perpendicular to the beam of the particle = \",B,\" Wb/square-metre\");\n",
      "\n",
      "## Result\n",
      "## The magnetic field perpendicular to the beam of the particle = 0.075 Wb/square-metre \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The magnetic field perpendicular to the beam of the particle =  0.08  Wb/square-metre\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex3-pg241"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "##  Exa6.3 : : Page-241 (2011)\n",
      "#find The energy of the electron and The energy of the converted gamma ray photon \n",
      "import math\n",
      "m_0 = 9.10963e-031;         ## Rest mass of the electron, Kg\n",
      "e = 1.60218e-019;           ## Charge of the electron, C\n",
      "c = 2.9979e+08;            ## Velocity of the light, metre per sec\n",
      "BR = 3381e-006;     ## Field-radius product, tesla-m\n",
      "E_k = 37.44;    ## Binding energy of k-electron\n",
      "v = 1/math.sqrt((m_0/(BR*e))**2+1/c**2); ## Velocity of the converson electron, m/s\n",
      "E = m_0*c**2*(1/math.sqrt(1-v**2/c**2)-1.)/(e*1e+003);   ## Energy of the electron, keV \n",
      "E_C = E+E_k;            ## Energy of the converted gamma ray photon, KeV\n",
      "print'%s %.2f %s  %.2f %s'%(\"\\nThe energy of the electron = \",E,\" keV \" and \" The energy of the converted gamma ray photon =\", E_C,\" keV\");\n",
      "\n",
      "## Result\n",
      "## The energy of the electron = 624.11 keV \n",
      "## The energy of the converted gamma ray photon = 661.55 keV \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The energy of the electron =  624.11  The energy of the converted gamma ray photon =  661.55  keV\n"
       ]
      }
     ],
     "prompt_number": 1
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex4-pg241"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.4 : : Page-241 (2011)\n",
      "#find The rest energy carried out by the neutrino\n",
      "import math\n",
      "E = 18.1;                ## Energy carried by beta particle, keV \n",
      "E_av = E/3.;               ## Average energy carried away by beta particle, keV\n",
      "E_r = E-E_av;            ## The rest energy carried out by the neutrino, keV\n",
      "\n",
      "print'%s %.2f %s'%(\"\\nThe rest energy carried out by the neutrino : \",E_r,\" KeV\");\n",
      "\n",
      "## Result\n",
      "## The rest energy carried out by the neutrino : 12.067 KeV \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The rest energy carried out by the neutrino :  12.07  KeV\n"
       ]
      }
     ],
     "prompt_number": 2
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex5-pg242"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.5: : Page-242(2011)\n",
      "#find The maximum energy available to the electrons in the beta decay\n",
      "import math\n",
      "M_Na = -8420.40;        ## Mass of sodium 24, keV\n",
      "M_Mg = -13933.567;      ## Mass of magnesium 24, keV\n",
      "E = (M_Na-M_Mg)/1000.;    ## Energy of the electron, MeV\n",
      "print'%s %.2f %s'%(\"\\nThe maximum energy available to the electrons in the beta decay = \",E,\" MeV\");\n",
      "\n",
      "## Result\n",
      "## The maximum energy available to the electrons in the beta decay = 5.513 MeV \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The maximum energy available to the electrons in the beta decay =  5.51  MeV\n"
       ]
      }
     ],
     "prompt_number": 3
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex6-pg242"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.6: : Page-242 (2011)\n",
      "#find The linear momentum of neutrino and The linear momentum of beta particle\n",
      "import math\n",
      "c = 1.;  ## For simplicity assume speed of light to be unity, m/s\n",
      "E_0 = 0.155;        ## End point energy, mega electron volts\n",
      "E_beta = 0.025;        ## Energy of beta particle, mega electron volts\n",
      "E_v = E_0-E_beta;        ## Energy of the neutrino, mega electron volts\n",
      "p_v = E_v/c;            ## Linear momentum of neutrino, mega electron volts per c\n",
      "m = 0.511;            ## Mass of an electron, Kg\n",
      "M = 14*1.66e-27;        ## Mass of carbon 14,Kg\n",
      "c = 3e+8;                ## Velocity of light, metre per sec\n",
      "e = 1.60218e-19;            ## Charge of an electron, coulomb\n",
      "p_beta = math.sqrt(2*m*E_beta);    ## Linear momentum of beta particle, MeV/c\n",
      "sin_theta = p_beta/p_v*math.sin(45/57.3);    ## Sine of angle theta\n",
      "p_R = p_beta*math.cos(45/57.3)+p_v*math.sqrt(1-sin_theta**2);  ## Linear momemtum of recoil nucleus, MeV/c\n",
      "E_R = (p_R*1.6e-13/2.9979e+08)**2/(2.*M*e);  ## Recoil energy of product nucleus, MeV\n",
      "print'%s %.2f %s %.2f %s %.2f %s '%(\"\\nThe linear momentum of neutrino = \",p_v,\" MeV/c\" and \"The linear momentum of beta particle =\",p_beta,\" MeV/c\" and \"The energy of the recoil nucleus = \",E_R,\" eV\")\n",
      "\n",
      "## Result\n",
      "## The linear momentum of neutrino = 0.13 MeV/c \n",
      "## The linear momentum of beta particle = 0.1598 MeV/c \n",
      "## The energy of the recoil nucleus = 1.20 eV \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The linear momentum of neutrino =  0.13 The linear momentum of beta particle = 0.16 The energy of the recoil nucleus =  1.20  eV \n"
       ]
      }
     ],
     "prompt_number": 4
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex7-pg242"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.7: : Page-242 (2011)\n",
      "#find The energy of the beta particle and The ratio of beta particle energy with end point energy\n",
      "import math\n",
      "N = 3.7e+10*60;        ## Number of disintegration, per sec\n",
      "H = 0.0268*4.182;        ## Heat produced at the output, joule\n",
      "E = H/(N*1.6e-013);        ## Energy of the beta particle, joule\n",
      "M_Bi = -14.815;            ## Mass of Bismuth, MeV\n",
      "M_Po = -15.977;            ## Mass of polonium, MeV\n",
      "E_0 = M_Bi-M_Po;            ## End point energy, MeV\n",
      "E_ratio = E/E_0;            ## Ratio of beta particle energy with end point energy\n",
      "print'%s %.2f %s  %.2f %s '%(\"\\nThe energy of the beta particle = \",E,\" MeV\" and \"The ratio of beta particle energy with end point energy =\" ,E_ratio,\"\");\n",
      "\n",
      "## Result\n",
      "## The energy of the beta particle = 0.316 MeV \n",
      "## The ratio of beta particle energy with end point energy = 0.272  \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The energy of the beta particle =  0.32 The ratio of beta particle energy with end point energy =  0.27  \n"
       ]
      }
     ],
     "prompt_number": 5
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex8-pg243"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.8: : Page-243 (2011)\n",
      "#find The parity of the 2.9 MeV level in be-8 and The threshold energy for lithium 7 neutron capture\n",
      "import math\n",
      "l = 2.;    ## Orbital angular momentum quantum number\n",
      "P = (+1)**2*(-1)**l;    ## Parity of the 2.9 MeV level in Be-8\n",
      "M_Li = 7.0182;        ## Mass of lithium, MeV\n",
      "M_Be = 7.998876;        ## Mass of beryllium, MeV\n",
      "m_n = 1.;                ## Mass of neutron, MeV\n",
      "E_th = (M_Li+m_n-M_Be)*931.5;    ## Threshold energy, MeV\n",
      "print'%s %.2f %s %.2f %s'%(\"\\nThe parity of the 2.9 MeV level in be-8 = \",+P,\" \" and\"The threshold energy for lithium 7 neutron capture = \",E_th,\" MeV\");\n",
      "\n",
      "## Result\n",
      "## The parity of the 2.9 MeV level in be-8 = +1 \n",
      "## The threshold energy for lithium 7 neutron capture = 18 MeV \n"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The parity of the 2.9 MeV level in be-8 =  1.00 The threshold energy for lithium 7 neutron capture =  18.00  MeV\n"
       ]
      }
     ],
     "prompt_number": 6
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex9-pg243"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "##Page-243(2011)\n",
      "import math\n",
      "import numpy\n",
      "#find  pairs are stable or not\n",
      "M =numpy.zeros((4,2));\n",
      "M[0,0] = 7.0182*931.5;    ## Mass of lithium, MeV\n",
      "M[0,1] = 7.0192*931.5;    ## Mass of beryllium, MeV\n",
      "M[1,0] = 13.0076*931.5;    ## Mass of carbon, MeV\n",
      "M[1,1] = 13.0100*931.5;    ## Mass of nitrogen, MeV\n",
      "M[2,0] = 19.0045*931.5;    ## Mass of fluorine, MeV\n",
      "M[2,1] = 19.0080*931.5;    ## Mass of neon, MeV\n",
      "M[3,0] = 33.9983*931.5;    ## Mass of phosphorous, MeV\n",
      "M[3,1] = 33.9987*931.5;    ## Mass of sulphur, MeV\n",
      "j = 0; \n",
      "## Check the stability !!!!\n",
      "for i in range  (0,3):\n",
      "    if round (M[i,j+1]-M[i,j]) == 1:\n",
      "        print(\"\\n From pair a :\")\n",
      "        print(\"\\n         Be(4,7) is unstable\");\n",
      "    elif round (M[i,j+1]-M[i,j]) == 2:\n",
      "        print(\"\\n From pair b :\")\n",
      "        print(\"\\n         N(7,13) is unstable\");\n",
      "    elif round (M[i,j+1]-M[i,j]) == 3:\n",
      "        print(\"\\n From pair c :\")\n",
      "        print(\"\\n         Ne(10,19) is unstable\");\n",
      "    elif round (M[i,j+1]-M[i,j]) == 0:\n",
      "        print(\"\\n From pair d :\")\n",
      "        print(\"\\n         P(15,34) is unstable\");\n",
      "    \n",
      "\n",
      "\n",
      "## Result\n",
      "## \n",
      "## From pair a :\n",
      "##         Be(4,7) is unstable\n",
      "## From pair b :\n",
      "##         N(7,13) is unstable\n",
      "## From pair c :\n",
      "##         Ne(10,19) is unstable\n",
      "## From pair d :\n",
      "##         P(15,34) is unstable "
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        " From pair a :\n",
        "\n",
        "         Be(4,7) is unstable\n",
        "\n",
        " From pair b :\n",
        "\n",
        "         N(7,13) is unstable\n",
        "\n",
        " From pair c :\n",
        "\n",
        "         Ne(10,19) is unstable\n"
       ]
      }
     ],
     "prompt_number": 7
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex10-pg244"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.10: : Page-244 (2011)\n",
      "#find The half life of H3 \n",
      "import math\n",
      "tau_0 = 7000.;        ## Time constant, sec\n",
      "M_mod_sqr = 3.;        ## Nuclear matrix\n",
      "E_0 = 0.018;        ## Energy of beta spectrum, MeV \n",
      "ft = 0.693*tau_0/M_mod_sqr;   ## Comparative half life\n",
      "fb = 10**(4.0*math.log10(E_0)+0.78+0.02);    ##\n",
      "t = 10**(math.log10(ft)-math.log10(fb));   ## Half life of H3, sec\n",
      "print'%s %.2f %s'%(\"\\nThe half life of H3 = \",t,\" sec\");\n",
      "\n",
      "## Result\n",
      "## The half life of H3 = 2.44e+009 sec "
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The half life of H3 =  2441293526.34  sec\n"
       ]
      }
     ],
     "prompt_number": 8
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex11-pg244"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.11: : Page-244 (2011)\n",
      "import math\n",
      "#find 92 percent beta emission  \n",
      "t_p = 33./0.92*365.*84800.;    ## Partial half life for beta emission, sec\n",
      "E_0 = 0.51;        ## Kinetic energy\n",
      "Z = 55.;            ## Atomic number of cesium\n",
      "log_fb = 4.0*math.log10(E_0)+0.78+0.02*Z-0.005*(Z-1)*math.log10(E_0);    ## Comparitive half life\n",
      "log_ft1 = log_fb+math.log10(t_p);     ## Forbidden tansition\n",
      "## For 8 percent beta minus emission\n",
      "t_p = 33./0.08*365.*84800.;    ## Partial half life, sec\n",
      "E_0 = 1.17;        ## Kinetic energy\n",
      "Z = 55;            ## Atomic energy\n",
      "log_fb = 4.0*math.log10(E_0)+0.78+0.02*Z-0.005*(Z-1)*math.log10(E_0);    ## Comparitive half life\n",
      "log_ft2 = log_fb+math.log10(t_p);    ## Forbidden transition\n",
      "## Check the degree of forbiddenness !!!!!\n",
      "if log_ft1 <= 10: \n",
      "    print(\"\\nFor 92 percent beta emission :\")\n",
      "    print(\"\\n\\tTransition is once forbidden and parity change\");\n",
      "\n",
      "if log_ft2 >= 10:\n",
      "    print(\"\\nFor 8 percent beta emission :\")\n",
      "    print(\"\\n\\t ransition is twice forbidden and no parity change\");\n",
      "\n",
      "\n",
      "## Result\n",
      "## For 92 percent beta emission :\n",
      "##\tTransition is once forbidden and parity change\n",
      "## For 8 percent beta emission :\n",
      "##\tTransition is twice forbidden and no parity change\n",
      " "
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "For 92 percent beta emission :\n",
        "\n",
        "\tTransition is once forbidden and parity change\n",
        "\n",
        "For 8 percent beta emission :\n",
        "\n",
        "\t ransition is twice forbidden and no parity change\n"
       ]
      }
     ],
     "prompt_number": 9
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex12-pg244"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.12: : Page-244(2011)\n",
      "#find The value of coupling constant and The ratio of coupling constant\n",
      "import math\n",
      "h_kt = 1.05457e-34;    ## Reduced planck's constant, joule sec\n",
      "c = 3e+08;             ## velocity of light, metre per sec\n",
      "m_e = 9.1e-31;         ## Mass of the electron, Kg\n",
      "ft_O = 3162.28;        ## Comparative half life for oxygen\n",
      "ft_n = 1174.90;        ## Comparative half life for neutron\n",
      "M_f_sqr = 2.            ## Matrix element\n",
      "g_f = math.sqrt(2*math.pi**3*h_kt**7.*math.log(2.)/(m_e**5*c**4*ft_O*M_f_sqr));    ## Coupling constant, joule cubic metre\n",
      "C_ratio = (2.*ft_O/(ft_n)-1.)/3.;    ## Ratio of coupling strength\n",
      "print'%s %.3e %s %.2f %s'%(\"\\nThe value of coupling constant = \",g_f,\" joule cubic metre\" and \"The ratio of coupling constant = \",C_ratio,\"\");\n",
      "\n",
      "## Result\n",
      "## The value of coupling constant = 1.3965e-062 joule cubic metre\n",
      "## The ratio of coupling constant = 1.461 "
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The value of coupling constant =  1.397e-62 The ratio of coupling constant =  1.46 \n"
       ]
      }
     ],
     "prompt_number": 10
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex13-pg245"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.13: : Page-245 (2011)\n",
      "#find The relative capture rate in holmium 161\n",
      "import math\n",
      "Q_EC = 850.;        ## Q value for holmium 161, keV\n",
      "B_p = 2.0;    ## Binding energy for p-orbital electron, keV\n",
      "B_s = 1.8;        ## Binding energy for s-orbital electron, keV\n",
      "M_ratio = 0.05*(Q_EC-B_p)**2./(Q_EC-B_s)**2;    ## Matrix ratio\n",
      "Q_EC = 2.5;        ## Q value for holmium 163, keV\n",
      "C_rate = M_ratio*(Q_EC-B_s)**2./(Q_EC-B_p)**2.*100.;    ## The relative capture rate in holmium, percent\n",
      "print'%s %.2f %s'%(\"\\nThe relative capture rate in holmium 161 = \",C_rate,\" percent\");\n",
      "\n",
      "## Result\n",
      "## The relative capture rate in holmium 161 = 9.8 percent "
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The relative capture rate in holmium 161 =  9.80  percent\n"
       ]
      }
     ],
     "prompt_number": 11
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex14-pg246"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.14: : Page-246 (2011)\n",
      "#find The average energy of beta particles\n",
      "import math\n",
      "t_half = 12.5*365*24;        ## Half life of hydrogen 3, hour\n",
      "D = math.log(2)/t_half;      ## Decay constant, per hour\n",
      "N_0 = 6.023e+26;             ## Avogadro's number, per mole\n",
      "m = 0.1e-03;                ## Mass of tritium, Kg\n",
      "dN_by_dt = D*m*N_0/3.;  ## Decay rate, per hour\n",
      "H = 21*4.18;                ## Heat produed, joule \n",
      "E = H/dN_by_dt;             ## The average energy of the beta particle, joule\n",
      "print'%s %.2e %s  %.2f %s'%(\"\\nThe average energy of beta particles =\",E,\"joule = \",E/1.6e-016,\" keV\");\n",
      "\n",
      "## Result\n",
      "## The average energy of beta particles = 6.91e-016 joule = 4.3 keV \n",
      " "
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "The average energy of beta particles = 6.91e-16 joule =   4.32  keV\n"
       ]
      }
     ],
     "prompt_number": 12
    },
    {
     "cell_type": "heading",
     "level": 2,
     "metadata": {},
     "source": [
      "Ex15-pg246"
     ]
    },
    {
     "cell_type": "code",
     "collapsed": false,
     "input": [
      "## Exa6.15: : Page-246 (2011)\n",
      "#find antiparallel spin and parallel spin\n",
      "import math\n",
      "import numpy\n",
      "a='antiparallel spin'\n",
      "b='parallel spin'\n",
      "S=([a, b])\n",
      "\n",
      "\n",
      "for i in range  (0,1):\n",
      "    if S[i] == 'antiparallel spin' :\n",
      "       print(\"\\nFor Fermi types :\")\n",
      "       print(\"\\n\\n The selection rules for allowed transitions are :  \\n\\tdelta I is zero \\n\\tdelta pi is plus \\nThe emited neutrino and electron have %s\")\n",
      "       print \"S(i,1)\"\n",
      "    elif S[i] == 'parallel spin':\n",
      "       print(\"\\nFor Gamow-Teller types :\")\n",
      "       print(\"\\nThe selection rules for allowed transitions are : \\n\\tdelta I is zero,plus one and minus one\\n\\tdelta pi is plus\\nThe emited neutrino and electron have %s\")\n",
      "       print(\"S(i,1)\") \n",
      "    \n",
      "\n",
      "## Calculation of ratio of transition probability\n",
      "M_F = 1.;    ## Matrix for Fermi particles\n",
      "g_F = 1.;        ## Coupling constant of fermi particles\n",
      "M_GT = 5/3.;        ## Matrix for Gamow Teller\n",
      "g_GT = 1.24;        ## Coupling constant of Gamow Teller\n",
      "T_prob = g_F**2*M_F/(g_GT**2*M_GT);    ## Ratio of transition probability\n",
      "## Calculation of Space phase factor\n",
      "e = 1.6e-19;        ## Charge of an electron, coulomb\n",
      "c = 3e+08;            ## Velocity of light, metre per sec\n",
      "K = 8.99e+9;        ## Coulomb constant\n",
      "R_0 = 1.2e-15;        ## Distance of closest approach, metre\n",
      "A = 57.;            ## Mass number\n",
      "Z = 28.;            ## Atomic number \n",
      "m_n = 1.6749e-27;    ## Mass of neutron, Kg\n",
      "m_p = 1.6726e-27;    ## Mass of proton, Kg\n",
      "m_e = 9.1e-31;        ## Mass of electron. Kg\n",
      "E_1 = 0.76;         ## First excited state of nickel\n",
      "delta_E = ((3*e**2*K/(5*R_0*A**(1/3.))*((Z+1.)**2-Z**2))-(m_n-m_p)*c**2)/1.6e-13;         ## Mass difference, mega electron volts\n",
      "E_0 = delta_E-(2*m_e*c**2)/1.6e-13;    ## End point energy, mega electron volts\n",
      "P_factor = (E_0-E_1)**5/E_0**5;    ## Space phase factor \n",
      "print'%s %.2f %s %.2f %s '%(\"\\nThe ratio of transition probability =\",T_prob,\"\"and\"\\nThe space phase factor =\",P_factor,\"\");\n",
      " \n",
      "## Result\n",
      "## The emited neutrino and electron have antiparallel spin\n",
      "## For Gamow-Teller types :\n",
      "## The selection rules for allowed transitions are : \n",
      "##\tdelta I is zero,plus one and minus one\n",
      "##\tdelta pi is plus\n",
      "## The emited neutrino and electron have parallel spin\n",
      "## The ratio of transition probability = 0.39\n",
      "## The space phase factor = 0.62 a"
     ],
     "language": "python",
     "metadata": {},
     "outputs": [
      {
       "output_type": "stream",
       "stream": "stdout",
       "text": [
        "\n",
        "For Fermi types :\n",
        "\n",
        "\n",
        " The selection rules for allowed transitions are :  \n",
        "\tdelta I is zero \n",
        "\tdelta pi is plus \n",
        "The emited neutrino and electron have %s\n",
        "S(i,1)\n",
        "\n",
        "The ratio of transition probability = 0.39  0.62  \n"
       ]
      }
     ],
     "prompt_number": 13
    }
   ],
   "metadata": {}
  }
 ]
}