summaryrefslogtreecommitdiff
path: root/Unified_Physics_by_S.L._Gupta,_Sanjeev_Gupta/Chapter2.ipynb
diff options
context:
space:
mode:
Diffstat (limited to 'Unified_Physics_by_S.L._Gupta,_Sanjeev_Gupta/Chapter2.ipynb')
-rw-r--r--Unified_Physics_by_S.L._Gupta,_Sanjeev_Gupta/Chapter2.ipynb247
1 files changed, 247 insertions, 0 deletions
diff --git a/Unified_Physics_by_S.L._Gupta,_Sanjeev_Gupta/Chapter2.ipynb b/Unified_Physics_by_S.L._Gupta,_Sanjeev_Gupta/Chapter2.ipynb
new file mode 100644
index 00000000..3996a39d
--- /dev/null
+++ b/Unified_Physics_by_S.L._Gupta,_Sanjeev_Gupta/Chapter2.ipynb
@@ -0,0 +1,247 @@
+{
+ "cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# 2: Molecular Spectroscopy"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example number 1, Page number 56"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 12,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "energy is 4.75 *10**-4 eV\n",
+ "angular velocity is 10.21 *10**11 rad/sec\n",
+ "answer in the book varies due to rounding off errors\n"
+ ]
+ }
+ ],
+ "source": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration \n",
+ "h=6.62*10**-34; #planck's constant\n",
+ "I=1.46*10**-46; #moment of inertia(kg-m**2)\n",
+ "e=1.6*10**-19; #charge(coulomb)\n",
+ "\n",
+ "#Calculations\n",
+ "Er=2*(h**2)/(8*math.pi**2*I*e); #energy(eV)\n",
+ "omega=math.sqrt(2*Er*e/I); #angular velocity(rad/sec)\n",
+ "\n",
+ "#Result\n",
+ "print \"energy is\",round(Er*10**4,2),\"*10**-4 eV\"\n",
+ "print \"angular velocity is\",round(omega*10**-11,2),\"*10**11 rad/sec\"\n",
+ "print \"answer in the book varies due to rounding off errors\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example number 2, Page number 62"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 15,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "frequency of vibration is 2.04 *10**13 Hertz\n",
+ "spacing between energy levels is 8.44 *10**-2 eV\n"
+ ]
+ }
+ ],
+ "source": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration \n",
+ "h=6.63*10**-34; #planck's constant\n",
+ "K=187; #force constant(N/m)\n",
+ "mew=1.14*10**-26; #reduced mass(kg)\n",
+ "c=6.242*10**18; #conversion factor\n",
+ "\n",
+ "#Calculations\n",
+ "vnew=math.sqrt(K/mew)/(2*math.pi); #frequency of vibration(Hertz)\n",
+ "delta_E=h*vnew; #spacing between energy levels(J)\n",
+ "delta_E=delta_E*c; #spacing between energy levels(eV)\n",
+ "\n",
+ "#Result\n",
+ "print \"frequency of vibration is\",round(vnew/10**13,2),\"*10**13 Hertz\"\n",
+ "print \"spacing between energy levels is\",round(delta_E*10**2,2),\"*10**-2 eV\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example number 3, Page number 68"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 3,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "wavelength of antistokes line 5401 angstrom\n"
+ ]
+ }
+ ],
+ "source": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration \n",
+ "lamda0=5460*10**-8; #wavelength(cm)\n",
+ "lamdas=5520*10**-8; #wavelength(cm)\n",
+ "\n",
+ "#Calculations\n",
+ "new0=1/lamda0; #frequency(cm-1)\n",
+ "news=1/lamdas; #frequency(cm-1)\n",
+ "delta_new=new0-news; #difference in frequency(cm-1)\n",
+ "new_as=delta_new+new0; #frequency of anti-stokes line(cm-1)\n",
+ "lamda_as=1*10**8/new_as; #wavelength of antistokes line(angstrom)\n",
+ "\n",
+ "#Result\n",
+ "print \"wavelength of antistokes line\",int(lamda_as),\"angstrom\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example number 4, Page number 68"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 9,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "raman shift is 459.2 *10**2 m-1\n",
+ "wavelength of antistokes line 4272.5 angstrom\n"
+ ]
+ }
+ ],
+ "source": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration \n",
+ "lamda0=4358*10**-10; #wavelength(m)\n",
+ "lamda1=4447*10**-10; #wavelength(m)\n",
+ "\n",
+ "#Calculations\n",
+ "new0=1/lamda0; #frequency(m-1)\n",
+ "new1=1/lamda1; #frequency(m-1)\n",
+ "rs=new0-new1; #raman shift(m-1)\n",
+ "new_as=new0+rs; #frequency of anti-stokes line(cm-1)\n",
+ "lamda_as=1*10**10/new_as; #wavelength of antistokes line(angstrom)\n",
+ "\n",
+ "#Result\n",
+ "print \"raman shift is\",round(rs/10**2,1),\"*10**2 m-1\"\n",
+ "print \"wavelength of antistokes line\",round(lamda_as,1),\"angstrom\""
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example number 5, Page number 71"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 12,
+ "metadata": {
+ "collapsed": false
+ },
+ "outputs": [
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "ratio of wave numbers is 1 : 0.52 : 0.31\n"
+ ]
+ }
+ ],
+ "source": [
+ "#importing modules\n",
+ "import math\n",
+ "from __future__ import division\n",
+ "\n",
+ "#Variable declaration \n",
+ "K1=4141.3; #wave number of HF(cm-1)\n",
+ "K2=2988.9; #wave number of HCl(cm-1)\n",
+ "K3=2309.5; #wave number of HI(cm-1)\n",
+ "c=1; #assume as common factor in ratio\n",
+ "\n",
+ "#Calculations\n",
+ "a=(K2/K1)**2; #ratio of wave numbers of HF and HCl\n",
+ "b=(K3/K1)**2; #ratio of wave numbers of HF and HI\n",
+ "\n",
+ "#Result\n",
+ "print \"ratio of wave numbers is\",c,\":\",round(a,2),\":\",round(b,2)"
+ ]
+ }
+ ],
+ "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.11"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}