summaryrefslogtreecommitdiff
path: root/sample_notebooks/maheshvattikuti
diff options
context:
space:
mode:
Diffstat (limited to 'sample_notebooks/maheshvattikuti')
-rwxr-xr-xsample_notebooks/maheshvattikuti/chapter1.ipynb1147
1 files changed, 1147 insertions, 0 deletions
diff --git a/sample_notebooks/maheshvattikuti/chapter1.ipynb b/sample_notebooks/maheshvattikuti/chapter1.ipynb
new file mode 100755
index 00000000..9eda293b
--- /dev/null
+++ b/sample_notebooks/maheshvattikuti/chapter1.ipynb
@@ -0,0 +1,1147 @@
+{
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "\n",
+ "# chapter1: De Broglie Matter Waves"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##example 1.1;page no:10"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 3,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.1,page no:10\n",
+ "\n",
+ " de Broglie wavelength of earth in metres is= 3.68e-63\n"
+ ]
+ }
+ ],
+ "source": [
+ "# cal of de brogle wavelength of earth\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "M = 6.*10**24 # Mass of earth in Kg\n",
+ "v = 3.*10**4 # Orbital velocity of earth in m/s\n",
+ "h = 6.625*10**-34 # Plank constant\n",
+ "print(\"Example 1.1,page no:10\")\n",
+ "lamda=h/(M*v) \n",
+ "print(\"\\n de Broglie wavelength of earth in metres is=\"),round(lamda,65)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.2;page no:10"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 4,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.2,page no:11\n",
+ "\n",
+ " de Broglie wavelength of body in metres is= 6.625e-35\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de Broglie wavelength of body\n",
+ "#intiation of all variables\n",
+ "#given that\n",
+ "M = 1 # Mass of object in Kg\n",
+ "v = 10 # velocity of object in m/s\n",
+ "h = 6.625*10**-34 # Plank constant\n",
+ "print(\"Example 1.2,page no:11\");\n",
+ "lamda=h/(M*v)#calculation of de Broglie wavelength\n",
+ "print(\"\\n de Broglie wavelength of body in metres is=\"),round(lamda,38)\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##example 1.3;page no:11"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 5,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.3,page no:11\n",
+ "\n",
+ " de Broglie wavelength of body in metres is= 6.625e-09\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of body\n",
+ "#intiation of all variables \n",
+ "# Given that\n",
+ "m = 1e-30 # Mass of any object in Kg\n",
+ "v = 1e5 # velocity of object in m/s\n",
+ "h = 6.625e-34 # Plank constant\n",
+ "print(\"Example 1.3,page no:11\")\n",
+ "lamda=h/(m*v) # calculation of de Broglie wavelength in metres\n",
+ "print(\"\\n de Broglie wavelength of body in metres is=\"),round(lamda,12)\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "##example 1.4;page no:15"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 6,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.4,page no:15\n",
+ "velocity of electron in m/s: 1000.0\n",
+ "momentum of electron in Kgm/s: 9.1e-28\n",
+ "de Broglie wavelength of electron is: 7.27e-07\n",
+ "Note:The value given in the book for lamda is wrong hence corrected above\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of velocity,momenteum and wave lenght of electron\n",
+ "#intiation of all variables \n",
+ "# Given that\n",
+ "import math\n",
+ "KE = 4.55e-25 # Kinetic energy of an electron in Joule\n",
+ "m = 9.1e-31 # Mass of any object in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.4,page no:15\")\n",
+ "v = math.sqrt(2*KE/m) # Calculation of velocity of moving electron\n",
+ "p = m*v #Calculation of momentum of moving electron\n",
+ "lamda= h/p # calculation of de Broglie wavelength\n",
+ "print(\"velocity of electron in m/s:\"),round(v)\n",
+ "print(\"momentum of electron in Kgm/s:\"),round(p,29)\n",
+ "print(\"de Broglie wavelength of electron is:\"),round(lamda,9)\n",
+ "print(\"Note:The value given in the book for lamda is wrong hence corrected above\")\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.5;page no:16"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 7,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.5,page no:16\n",
+ "de Broglie wavelength of proton is: 2.645e-14\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of proton\n",
+ "#intiation of all variables \n",
+ "#Given that\n",
+ "c = 3e8 # speed of light in m/s\n",
+ "v = c/20 # Speed of proton in m/s\n",
+ "m = 1.67e-27 # Mass of proton in Kg\n",
+ "h = 6.625e-34 # Plank constant\n",
+ "print(\"Example 1.5,page no:16\")\n",
+ "lamda= h/(m*v) # calculation of de Broglie wavelength\n",
+ "print(\"de Broglie wavelength of proton is:\"),round(lamda,17)\n",
+ "# Answer in book is 6.645e-14m which is a calculation mistake\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.6;page no:16"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 1,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.6,page no:16\n",
+ "\n",
+ " de Broglie wavelength of neutron in angstrom= 7.99e-05\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of neutron\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "e = 12.8 # Energy of neutron in MeV\n",
+ "c = 3.e8 # speed of light in m/s\n",
+ "m = 1.675e-27 # Mass of neutron in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.6,page no:16\")\n",
+ "rest_e = m*c**2/(1e6*1.6e-19)# rest mass energy of neutron in MeV\n",
+ "if e/rest_e < 0.015:\n",
+ "\tE = e\n",
+ "else:\n",
+ "\tE = rest_e +e\n",
+ "lamda = h/(math.sqrt(2*m*e*1e6*1.6e-19)) # calculation of de Broglie wavelength\n",
+ "print(\"\\n de Broglie wavelength of neutron in angstrom=\"),round(lamda*1e10,7)\n",
+ "# Answer in book is 8.04e-5 angstrom which is misprinted\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.7;page no:17"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 7,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.7,page no:17\n",
+ "\n",
+ " de Broglie wavelength of neutron in angstrom= 1.734\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of neutron\n",
+ "#intiation of all variables \n",
+ "#Given that\n",
+ "import math\n",
+ "e = 1.602e-19 # charge on electron in coulomb\n",
+ "V = 50. # Applied voltage in volts\n",
+ "m = 9.1e-31 # Mass of electron in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.7,page no:17\")\n",
+ "lamda= h/(math.sqrt(2*e*V*m)) # calculation of de Broglie wavelength\n",
+ "print(\"\\n de Broglie wavelength of neutron in angstrom=\"),round(lamda*1e10,3)\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.9;page no:18"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 8,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.9,page no:18\n",
+ "de Broglie wavelength associated with the electron in angstrom= 1.67\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength associated with the electron\n",
+ "#intiation of all variables \n",
+ "#Given that\n",
+ "import math\n",
+ "e = 1.6e-19 # charge on electron in coulomb\n",
+ "V = 54 # Applied voltage in volts\n",
+ "m = 9.1e-31 # Mass of electron in Kg\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.9,page no:18\")\n",
+ "lamda = h/(math.sqrt(2*e*V*m)) # calculation of de Broglie wavelength\n",
+ "print(\"de Broglie wavelength associated with the electron in angstrom=\"),round(lamda*1e10,2)\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.10;page no:19"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 9,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.10,page no:19\n",
+ "velocity of electron in m/s: 59299945.33\n",
+ "momentum of electron in Kgm/s: 5.3963e-23\n",
+ "de Broglie wavelength of electron in angstrom= 0.123\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of velocity of electron,momentum of electron,de Broglie wavelength of electron\n",
+ "#intiation of all variables \n",
+ "#Given that\n",
+ "import math\n",
+ "E = 10. # Energy of electron in KeV\n",
+ "me = 9.1e-31 # Mass of electron in Kg\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.10,page no:19\")\n",
+ "v = math.sqrt(2*E*1.6e-16/me) # Calculation of velocity of moving electron\n",
+ "p = me*v #Calculation of momentum of moving electron\n",
+ "lamda = h/p # calculation of de Broglie wavelength\n",
+ "print(\"velocity of electron in m/s:\"),round(v,2)\n",
+ "print(\"momentum of electron in Kgm/s:\"),round(p,27)\n",
+ "print(\"de Broglie wavelength of electron in angstrom=\"),round(lamda*1e10,3)\n",
+ "# Answers in book are v = 5.93e6 m/s, p = 5.397e-24 kgm/s, lambda = 1.23 angstrom\n",
+ "# Which is due to wrong calculation"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.11;page no:20"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 10,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.11,page no:20\n",
+ " velocity of neutron in m/s: 3964.072\n",
+ " Kinetic energy of neutron in eV= 0.082\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of velocity and kinetic energy of neutron\n",
+ "#intiation of all variables \n",
+ "#Given that\n",
+ "lamda= 1 # de Broglie wavelength of neutron in angstrom\n",
+ "m = 1.67e-27 # Mass of electron in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.11,page no:20\")\n",
+ "v = h/(m*lamda*1e-10) # Calculation of velocity of moving neutron\n",
+ "print(\" velocity of neutron in m/s:\"),round(v,3)\n",
+ "E = 1./2.*m*v**2 # Calculation of kinetic energy of moving neutron\n",
+ "print(\" Kinetic energy of neutron in eV=\"),round(E/1.6e-19,3)\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.12;page no:20"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 12,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.12,page no:20\n",
+ "Wavelength of electron in metres= 2.74e-11\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of electron\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "E = 2 # Energy of accelerated electron in KeV\n",
+ "m = 9.1e-31 # Mass of electron in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.12,page no:20\")\n",
+ "lamda = h/math.sqrt(2*m*E*1e3*1.6e-19) # Calculation of velocity of moving electron\n",
+ "print(\"Wavelength of electron in metres=\"),round(lamda,13)\n",
+ "# Answer in book is 2.74e-12m\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.13;page no:21"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 13,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.13,page no:21\n",
+ "Wavelength of matter wave in angstrom= 1.48e-05\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of matter wave\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "v = 2e8 # speed of moving proton in m/s\n",
+ "c = 3e8 # speed of light in m/s\n",
+ "m = 1.67e-27 # Mass of proton in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.13,page no:21\")\n",
+ "lamda = h/(m*v/math.sqrt(1-(v/c)**2)) # Calculation of velocity of moving electron\n",
+ "print(\"Wavelength of matter wave in angstrom=\"),round(lamda*1e10,7)\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.14;page no:22"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 31,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.14,page no:22\n",
+ "Momentum of photon in Kgm/s while Momentum of electron in Kgm/s which are equal: 6.63e-24 6.63e-24\n",
+ "Total Energy of photon in joule while Total Energy of electron in MeV: 1.989e-15 2.42e-17\n",
+ "Ratio of kinetic energies in: 0.0121\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of momentum,total energy and ratio of kinetic energy of photon\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "lamda = 1# wavelength in m/s\n",
+ "m_e = 9.1e-31 # Mass of electron in Kg\n",
+ "m_p = 1.67e-27 # Mass of proton in kg\n",
+ "c = 3e8 # speed of light in m/s\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.14,page no:22\")\n",
+ "p_e = h/(lamda*1e-10) # Momentum of electron\n",
+ "p_p = h/(lamda*1e-10) # Momentum of photon\n",
+ "print(\"Momentum of photon in Kgm/s while Momentum of electron in Kgm/s which are equal:\"),round(p_p,26),round(p_e,26)\n",
+ "E_e = p_e**2/(2*m_e) +m_e*c**2 # Total energy of electron\n",
+ "E_e1=(2.42*10**-17)+(m_e*c**2/1.6*10**-19)\n",
+ "E_p = h*c/(lamda*1e-10) # Total energy of photon\n",
+ "print(\"Total Energy of photon in joule while Total Energy of electron in MeV:\"),round(E_p,18),E_e1\n",
+ "K_e = p_e**2/(2*m_e) # Kinetic energy of electron \n",
+ "K_p = h*c/(lamda*1e-10)# Kinetic energy of photon\n",
+ "r_K = K_e/K_p # Ratio of kinetic energies\n",
+ "print(\"Ratio of kinetic energies in:\"),round(r_K,4)\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.15;page no:24"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.15,page no:24\n",
+ "de Broglie wavelength of neutron in angstrom: 0.0573\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of neutron\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "e = 25 # Energy of neutron in eV\n",
+ "c = 3e8 # speed of light in m/s\n",
+ "m = 1.67e-27 # Mass of neutron in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.15,page no:24\")\n",
+ "rest_e = m*c**2/(1e6*1.6e-19)# rest mass energy of neutron in MeV\n",
+ "if e/rest_e < 0.015:\n",
+ " E = e;\n",
+ "else:\n",
+ "\tE = rest_e +e;\n",
+ "lamda = h/(math.sqrt(2*m*e*1.6e-19)) # calculation of de Broglie wavelength\n",
+ "print(\"de Broglie wavelength of neutron in angstrom:\"),round(lamda*1e10,4)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.16;page no:24"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 14,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.16,page no:24\n",
+ "de Broglie wavelength of neutron in angstrom: 0.00717\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of neutron \n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "e = 2*1.6e-19 # charge on alpha particle in coulomb\n",
+ "V = 200 # Applied voltage in volts\n",
+ "m = 4*1.67e-27 # Mass of alpha particle in Kg\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.16,page no:24\")\n",
+ "lamda=h/(math.sqrt(2*e*V*m)) # calculation of de Broglie wavelength\n",
+ "print(\"de Broglie wavelength of neutron in angstrom:\"),round(lamda*1e10,5)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.17;page no:25"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 18,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.17,page no:25\n",
+ "de Broglie wavelength of ball in angstrom: 6.62e-26\n",
+ "de Broglie wavelength of electron in angstrom: 7.27\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of ball and electron\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "M = 20 # Mass of ball in Kg\n",
+ "V = 5 # velocity of of ball in m/s\n",
+ "m = 9.1e-31 #Mass of electron in Kg\n",
+ "v = 1e6 # velocity of of electron in m/s\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.17,page no:25\")\n",
+ "lambda_b = h/(M*V) # calculation of de Broglie wavelength for ball\n",
+ "lambda_e = h/(m*v) # calculation of de Broglie wavelength electron\n",
+ "print(\"de Broglie wavelength of ball in angstrom:\"),round(lambda_b*1e10,34)\n",
+ "print(\"de Broglie wavelength of electron in angstrom:\"),round(lambda_e*1e10,2)\n",
+ "# answer in book is 6.62e-22 angstrom for ball\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.18;page no:26"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 15,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.18,page no:26\n",
+ "Wavelength of neutron in angstrom: 0.286\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of de brogle wavelength of neutron\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "E = 1 # Energy of neutron in eV\n",
+ "m = 1.67e-27 # Mass of neutron in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "print(\"Example 1.18,page no:26\")\n",
+ "lamda = h/math.sqrt(2*m*E*1.6e-19) # Calculation of velocity of moving electron\n",
+ "print(\"Wavelength of neutron in angstrom:\"),round(lamda*1e10,3)\n",
+ "# Answer in book is 6.62e-22 angstrom\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.19;page no:27"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 20,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.19,page no:27\n",
+ "Applied voltage on electron in V: 602.0\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of Applied voltage on electron \n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "lamda = 0.5# wavelength of electron in angstrom\n",
+ "m = 9.1e-31 # Mass of electron in Kg\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "q = 1.6e-19 # charge on electron in coulomb\n",
+ "print(\"Example 1.19,page no:27\")\n",
+ "V = h**2/(2*m*q*(lamda*1e-10)**2) # Calculation of velocity of moving electron\n",
+ "print(\"Applied voltage on electron in V:\"),round(V,1)\n",
+ "# Answer in book is 601.6 Volt\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.21;page no:29"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 21,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.21,page no:29\n",
+ "Wavelength of neutron at degree Celsius in angstrom: 1.43\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of wavelength of neutron\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "k = 8.6e-5 # Boltzmann constant\n",
+ "t = 37 # Temperature in degree Celsius\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "m = 1.67e-27 # Mass of neutron\n",
+ "print(\"Example 1.21,page no:29\")\n",
+ "lamda = h/math.sqrt(3*m*(k*1.6e-19)*(t+273))# Calculation of wavelength\n",
+ "print(\"Wavelength of neutron at degree Celsius in angstrom:\"),round(lamda*1e10,2)\n",
+ "\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.22;page no:29"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 22,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.22,page no:29\n",
+ "Wavelength of helium at degree Celsius in angstrom: 0.727\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of wavelength of helium\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "k = 8.6e-5 # Boltzmann constant\n",
+ "t = 27 # Temperature in degree Celsius\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "m = 6.7e-27 # Mass of helium atom\n",
+ "print(\"Example 1.22,page no:29\")\n",
+ "lamda = h/math.sqrt(3*m*(k*1.6e-19)*(t+273))# Calculation of wavelength\n",
+ "print(\"Wavelength of helium at degree Celsius in angstrom:\"),round(lamda*1e10,3)\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.23;page no:30"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 17,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.23,page no:30\n",
+ "lamda= 8.67e-11\n",
+ "D/2*x= 0.05\n",
+ "tan(theta)= 0.05\n",
+ "Interatomic spacing of crystal in angstrom: 8.67\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of Interatomic spacing of crystal\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "E = 200. # energy of electrons in eV\n",
+ "x = 20. # distance of screen in cm\n",
+ "D = 2. # diameter of ring in cm\n",
+ "h = 6.62e-34 # Plank constant\n",
+ "m = 9.1e-31 # Mass of electron in kg\n",
+ "print(\"Example 1.23,page no:30\")\n",
+ "lamda= h/math.sqrt(2*m*E*1.6e-19) # Calculation of wavelength\n",
+ "print(\"lamda=\"),round(lamda,13)\n",
+ "print(\"D/2*x=\"),D/(2*x)\n",
+ "p=D/(2*x)\n",
+ "print(\"tan(theta)=\"),p\n",
+ "d = lamda/(2*p)# calculation of interatomic spacing of crystal\n",
+ "print(\"Interatomic spacing of crystal in angstrom:\"),round(d*1e10,2)\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.24;page no:31"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 21,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.24,page no:31\n",
+ "Velocity of electron in ground state in M/s= 2.31\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of velocity of electron \n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "r = 0.5 # Bohr radius of hydrogen in angstrom\n",
+ "m = 9.1e-31 # Mass of neutron in Kg\n",
+ "h = 6.6e-34 # Plank constant\n",
+ "print(\"Example 1.24,page no:31\")\n",
+ "v = h/(2*3.14*r*1e-10*m) # velocity of electron in ground state\n",
+ "print(\"Velocity of electron in ground state in M/s=\"),round(v/10**6,2)\n",
+ "# Answer in book is 2.31e6 m/s\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.25;page no:32"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 25,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.25,page no:32\n",
+ "Velocity of electron in ground state in m/s: 1237.0\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of Velocity of electron in ground state\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "lamda = 5890 # wavelength of yellow radiation in angstrom\n",
+ "m = 9.1e-31 # Mass of neutron in Kg\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.25,page no:32\")\n",
+ "v = h/(lamda*1e-10*m) # velocity of electron in ground state\n",
+ "print(\"Velocity of electron in ground state in m/s:\"),round(v,1)\n",
+ "# Answer in book is 1.24e3 m/s\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.26;page no:33"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 26,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.26,page no:33\n",
+ "Velocity of neutron in m/s: 1985.0\n",
+ "Kinetic energy of neutron in eV: 0.021\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of Velocity and kinetic energy of neutron\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "lamda = 2 # wavelength of neutron in angstrom\n",
+ "m = 1.67e-27 # Mass of neutron in Kg\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.26,page no:33\")\n",
+ "v = h/(lamda*1e-10*m) # velocity of neutron\n",
+ "k = 0.5*m*v**2 # Kinetic energy of neutron\n",
+ "print(\"Velocity of neutron in m/s:\"),round(v,1)\n",
+ "print(\"Kinetic energy of neutron in eV:\"),round(k/1.6e-19,3)\n",
+ "# Answer in book is 0.021eV\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.29;page no:36"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 22,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.29,page no:36\n",
+ "theta 72.6\n",
+ "theta1= 56.84\n",
+ "For first order, sin(theta) in For second order sin(theta) must be which is not possible for any value of angle.So no maxima occur for higher orders: 1.91\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of theta and theta1 \n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "v1 = 50 # Previous applied voltage\n",
+ "v2 = 65 # final applied voltage\n",
+ "k = 12.28 \n",
+ "d = 0.91 # Spacing in a crystal in angstrom\n",
+ "print(\"Example 1.29,page no:36\")\n",
+ "lamda = k/math.sqrt(v1)\n",
+ "theta= math.asin(lamda/(2*d))# Angel for initial applied voltage\n",
+ "lamda1 = k/math.sqrt(v2)# wavelength for final applied voltage\n",
+ "theta1 = math.asin(lamda1/(2*d))# Angel for final applied voltage\n",
+ "#print(\"lamda1/1.82=\"),math.asin(lamda1/1.82)\n",
+ "print(\"theta\"),round(theta*180/3.14,1)\n",
+ "print(\"theta1=\"),round(theta1*180/3.14,2)\n",
+ "print(\"For first order, sin(theta) in For second order sin(theta) must be which is not possible for any value of angle.So no maxima occur for higher orders:\"),round(2*math.sin(theta),2)\n",
+ "#print(\"Angle of diffraction for first order of beam is degree at Volts:\"),round((math.theta1*180/math.pi),2)\n",
+ "# Answer in book is 57.14 degree"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.30;page no:45"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 28,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.30,page no:45\n",
+ "Group velocity of seawater waves in m/s: 16.29\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of Group velocity of seawater waves\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "lamda = 680 # Wavelength in m\n",
+ "g = 9.8 #Acceleration due to gravity\n",
+ "print(\"Example 1.30,page no:45\")\n",
+ "v_g = 0.5*math.sqrt(g*lamda/(2*3.14)) # Calculation of group velocity\n",
+ "print(\"Group velocity of seawater waves in m/s:\"),round(v_g,2)\n",
+ "# Answer in book is 16.29 m/s\n"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.32;page no:47"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 29,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.32,page no:47\n",
+ "Group velocity of de Broglie waves is c : 0.9966\n",
+ " phase velocity of de Broglie waves is c 1.0034\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of group and phase velocity of de brogle waves \n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "lamda = 2e-13 # de Broglie wavelength of an electron in m\n",
+ "c = 3e8 # Speed of light in m/s\n",
+ "m = 9.1e-31 # Mass of electron in Kg\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.32,page no:47\")\n",
+ "E = h*c/(lamda*1.6e-19) \n",
+ "E_rest = m*c**2/(1.6e-19) # Calculation of rest mass energy\n",
+ "E_total = math.sqrt(E**2+E_rest**2) # Total energy in eV\n",
+ "v_g = c*math.sqrt(1-(E_rest/E_total)**2) # Group velocity\n",
+ "v_p = c**2/v_g # Phase velocity\n",
+ "print(\"Group velocity of de Broglie waves is c :\"),round(v_g/c,4)\n",
+ "print(\" phase velocity of de Broglie waves is c\"),round(v_p/c,4)"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## example 1.33;page no:48"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 23,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "Example 1.33,page no:48\n",
+ "Kinetic energy of electron in KeV: 293.33\n",
+ "Group velocity of de Broglie waves is c in m/s: 0.7719\n",
+ "phase velocity of de Broglie waves is c in m/s: 1.295\n"
+ ]
+ }
+ ],
+ "source": [
+ "#cal of Kinetic energy of electron,group velocity and phase velocity of de Broglie waves\n",
+ "#intiation of all variables \n",
+ "#given that\n",
+ "import math\n",
+ "lamda = 2.e-12 # de Broglie wavelength of an electron in m\n",
+ "c = 3.e8 # Speed of light in m/s\n",
+ "m = 9.1e-31 # Mass of electron in Kg\n",
+ "h = 6.63e-34 # Plank constant\n",
+ "print(\"Example 1.33,page no:48\")\n",
+ "E = h*c/(lamda*1.6e-19) # Energy due to momentum\n",
+ "E_rest = m*c**2/(1.6e-19) # Calculation of rest mass energy\n",
+ "E_total = math.sqrt(E**2+E_rest**2) # Total energy in eV\n",
+ "KE = E_total - E_rest # Kinetic energy\n",
+ "v_g = c*math.sqrt(1-(E_rest/E_total)**2) # Group velocity\n",
+ "v_p = c**2/v_g # Phase velocity\n",
+ "print(\"Kinetic energy of electron in KeV:\"),round(KE/1000,2)\n",
+ "print(\"Group velocity of de Broglie waves is c in m/s:\"),round(v_g/c,4)\n",
+ "print(\"phase velocity of de Broglie waves is c in m/s:\"),round(v_p/c,3)\n",
+ "# Answer in book is v_g = 0.6035c & v_p = 1.657c\n"
+ ]
+ }
+ ],
+ "metadata": {
+ "kernelspec": {
+ "display_name": "Python 2",
+ "language": "python",
+ "name": "python2"
+ },
+ "language_info": {
+ "codemirror_mode": {
+ "name": "ipython",
+ "version": 2
+ },
+ "file_extension": ".py",
+ "mimetype": "text/x-python",
+ "name": "python",
+ "nbconvert_exporter": "python",
+ "pygments_lexer": "ipython2",
+ "version": "2.7.10"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}