summaryrefslogtreecommitdiff
path: root/Applied_Physics_ii_by_H_J_Sawant/1-Interference_of_Light.ipynb
diff options
context:
space:
mode:
Diffstat (limited to 'Applied_Physics_ii_by_H_J_Sawant/1-Interference_of_Light.ipynb')
-rw-r--r--Applied_Physics_ii_by_H_J_Sawant/1-Interference_of_Light.ipynb951
1 files changed, 951 insertions, 0 deletions
diff --git a/Applied_Physics_ii_by_H_J_Sawant/1-Interference_of_Light.ipynb b/Applied_Physics_ii_by_H_J_Sawant/1-Interference_of_Light.ipynb
new file mode 100644
index 0000000..b17d01a
--- /dev/null
+++ b/Applied_Physics_ii_by_H_J_Sawant/1-Interference_of_Light.ipynb
@@ -0,0 +1,951 @@
+{
+"cells": [
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Chapter 1: Interference of Light"
+ ]
+ },
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_1: find_the_wavelength_of_light_in_the_visible_spectrum.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_1,pg 1-11\n",
+"\n",
+"i=45 //angle of incidence\n",
+"\n",
+"u=1.2 //refractive index of soap film\n",
+"\n",
+"t=4*10^-5 //thickness of soap film\n",
+"\n",
+"r=asind(sind(i)/u) //by Snell's law\n",
+"\n",
+"//for dark band '2*u*t*cos(r) = n*lam'\n",
+"\n",
+"wavelength_1=(2*u*t*cosd(r)/1)*10^8 //for n=1\n",
+"\n",
+"wavelength_2=(2*u*t*cosd(r)/2)*10^8 //for n=2\n",
+"\n",
+"wavelength_3=(2*u*t*cosd(r)/3)*10^8 //for n=3\n",
+"\n",
+"//visible range of wavelengths is 4000 A. to 7000 A.\n",
+"\n",
+"printf('\n for n=1 wavelength = %.1f A.\n',wavelength_1)\n",
+"\n",
+"printf('\n for n=2 wavelength = %.1f A.\n',wavelength_2)\n",
+"\n",
+"printf('\n for n=3 wavelength = %.2f A.\n',wavelength_3)\n",
+"\n",
+"printf('\n hence, none of the wavelengths from the visible region are absent in reflected light ')"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_2: find_the_wavelength_of_light_in_the_visible_spectrum.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_2,pg 1-12\n",
+"\n",
+"u=1.33 //refractive index of soap film\n",
+"\n",
+"t=5*10^-5 //thickness of soap film\n",
+"\n",
+"//for normal incidence \n",
+"\n",
+"r=0 //angle of refraction\n",
+"\n",
+"//for constructive interference '2*u*t*cos(r) = (2*n-1)*wavelength/2'\n",
+"\n",
+"wavelength_1=(2*u*t*cos(r)*2/(2*1-1))*10^8 //for n=1\n",
+"\n",
+"wavelength_2=(2*u*t*cos(r)*2/(2*2-1))*10^8 //for n=2\n",
+"\n",
+"wavelength_3=(2*u*t*cos(r)*2/(2*3-1))*10^8 //for n=3\n",
+"\n",
+"wavelength_4=(2*u*t*cos(r)*2/(2*4-1))*10^8 //for n=4\n",
+"\n",
+"//visible range of wavelengths is 4000 A. to 7000 A.\n",
+"\n",
+"printf('\n for n=1 wavelength = %.1f A.\n',wavelength_1)\n",
+"\n",
+"printf('\n for n=2 wavelength = %.1f A.\n',wavelength_2)\n",
+"\n",
+"printf('\n for n=3 wavelength = %.1f A.\n',wavelength_3)\n",
+"\n",
+"printf('\n for n=4 wavelength = %.1f A.\n',wavelength_4)\n",
+"\n",
+"printf('\n The wavelength will be reflected is wavelength = %.1f A.\n',wavelength_3)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_3: find_the_order_of_interference_band.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_3,pg 1-12\n",
+"\n",
+"u=4/3 //refractive index of soap film\n",
+"\n",
+"t=1.5*10^-4 //thickness of soap film \n",
+"\n",
+"wavelength=5*10^-5 //wavelength of light \n",
+"\n",
+"i=45 //angle of incidece\n",
+"\n",
+"r=asind(sind(i)/u) //by Snell's law\n",
+"\n",
+"n=2*u*t*cosd(r)/wavelength //for nth dark band\n",
+"\n",
+"printf('\n the order of an interference band is n = %.0f',n)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_4: find_the_thickness_of_soap_film.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_4,pg 1-13\n",
+"\n",
+"//for constructive interference 2 u t cos(r) = (2 n -1) wavelength/2\n",
+"\n",
+"u=1.33\n",
+"\n",
+"i=45\n",
+"\n",
+"r=asind(sind(i)/u) //by Snell's law\n",
+"\n",
+"n=1 //for minimum thickness \n",
+"\n",
+"wavelength=5896*10^-8\n",
+"\n",
+"t=(2*n-1)*wavelength/(4*u*cosd(r))\n",
+"\n",
+"printf('\n the minimum thickness of soap film is t = %.7f cm',t)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_5: find_the_thickness_of_oil_layer.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_5,pg 1-14\n",
+"\n",
+"u=1.3 //refractive index of liquid\n",
+" \n",
+"r=0 //angle of refraction for normal incidence\n",
+" \n",
+"wavelength_1=7000 //wavelength of light \n",
+"\n",
+"wavelength_2=5000 //wavelength of light \n",
+"\n",
+"//for destructive interference '2*u*t*cos(r) = (2*n-1)*wavelength/2'\n",
+"\n",
+"//'n' order for 'wavelength_1' and 'n+1' order for 'wavelength_2'\n",
+"\n",
+"//as LHS is same for both the wavelengths, therefore\n",
+"\n",
+"//(2*n-1)*7000/2 =(2*(n+1)-1)*5000/2\n",
+"\n",
+"n=3 //number of orders \n",
+"\n",
+"t=((2*n)-1)*wavelength_1/(4*u*cosd(r))\n",
+"\n",
+"printf('\nThe thickness of oil layer is t = %.2f A.',t)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_6: find_the_thickness_of_film.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_6,pg 1-15\n",
+"\n",
+"n=8 \n",
+"\n",
+"wavelength=5890*10^-8 //wavelength of light \n",
+"\n",
+"u=1.46 //refractive index of oil\n",
+"\n",
+"i=30 //angle of incidence\n",
+"\n",
+"r=asind(sind(i)/u) //by Snell's law\n",
+"\n",
+"t=n*wavelength/(2*u*cosd(r))\n",
+"\n",
+"printf('\n the thickness of an oil film is t =%.7f cm',t)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_7: find_the_minimum_thickness_of_film.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_7,pg 1-15\n",
+"\n",
+"u=1.5 //refractive index of thin film\n",
+"\n",
+"r1=60 //angle of refraction\n",
+"\n",
+"wavelength=5890*10^-8 //wavelength of light\n",
+"\n",
+"n=1 //for minimum thickness\n",
+"\n",
+"t1=n*wavelength/(2*u*cosd(r1))\n",
+"\n",
+"printf('\n the thickness of an oil film is t =%.7f cm',t1)\n",
+"\n",
+"r2=0 //for normal incidence \n",
+"\n",
+"t2=n*wavelength/(2*u*cosd(r2))\n",
+"\n",
+"printf('\n the thickness of an oil film is t =%.7f cm',t2)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_8: find_the_refractive_index_of_oil.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_8,pg 1-16\n",
+"\n",
+"V=0.2 //volume of oil\n",
+"\n",
+"A=10^4 //area\n",
+"\n",
+"t=V/A //Thickness of oil film\n",
+"\n",
+"r=0 //for normal incidence\n",
+"\n",
+"n=1 //for 1st dark band\n",
+"\n",
+"wavelength=5.5*10^-5 //wavelength of light \n",
+"\n",
+"u=n*wavelength/(2*t*cosd(r))\n",
+"\n",
+"printf('\nrefractive index of oil is u = %.3f',u)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.2_9: find_the_wavelength_of_light_in_the_visible_region.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_2_9,pg 1-17\n",
+"\n",
+"u=1.2 //refractive index of oil film\n",
+"\n",
+"t=2*10^-7 //thickness of oil film\n",
+"\n",
+"r=60 //angle of refraction\n",
+"\n",
+"//for destructive interference '2*u*t*cos(r) = (2*n-1)*wavelength/2'\n",
+"\n",
+"wavelength_1=(2*u*t*cosd(r)*2/(2*1-1))*10^10 //for n=1\n",
+"\n",
+"wavelength_2=(2*u*t*cosd(r)*2/(2*2-1))*10^10 //for n=2\n",
+"\n",
+"wavelength_3=(2*u*t*cosd(r)*2/(2*3-1))*10^10 //for n=3\n",
+"\n",
+"//visible range of wavelengths is 4000*10^-10 m to 7000*10^-10 m\n",
+"\n",
+"printf('\n for n=1 wavelength = %.f A.\n',wavelength_1)\n",
+"\n",
+"printf('\n for n=2 wavelength = %.f A.\n',wavelength_2)\n",
+"\n",
+"printf('\n for n=3 wavelength = %.f A.\n',wavelength_3)\n",
+"\n",
+"printf('\n The wavelength will be reflected is wavelength = %.f A.\n',wavelength_1)\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.3_1: find_wavelength_of_monochromatic_light.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_3_1,pg 1-21\n",
+"\n",
+"N=10 //no of dark fringes \n",
+"\n",
+"d=1.2 //distance between consecutive fringes \n",
+"\n",
+"B_air=d/N //fringe width in air\n",
+"\n",
+"a=(40/3600)*(%pi/180) //angle made by film in radians \n",
+"\n",
+"wavelength=2*a*B_air //as fringe width in air is 'B_air = wavelength/(2*a)'\n",
+"\n",
+"printf('\nThe wavelength of monochromatic light is = %.8f cm\n',wavelength)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.3_2: calculate_the_angle_of_wedge.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_3_2,pg 1-22\n",
+"\n",
+"wavelength=5893*10^-8 //wavelength of light \n",
+"\n",
+"B=0.1 //fringe width\n",
+"\n",
+"u=1.52 //refractive index of glass wedge\n",
+"\n",
+"a=(wavelength/(2*u*B))*3600*(180/%pi) //as fringe spacing is 'B = wavelength/(2*a*u)'\n",
+"\n",
+"printf('\nThe angle of wedge is a =%.2f seconds \n',a)\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.3_3: calculate_the_wavelength_of_light.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_3_3,pg 1-22\n",
+"\n",
+"B=0.25 //fringe width\n",
+"\n",
+"u=1.4 //refractive index of film\n",
+"\n",
+"a=(20/3600)*(%pi/180) //angle made by film in radians\n",
+"\n",
+"wavelength=2*a*B*u //as fringe width is 'B = wavelength/(2*a*u)'\n",
+"\n",
+"printf('\nThe wavelength of monochromatic light is = %.8f cm\n',wavelength)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.3_4: find_the_number_of_fringes.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_3_4,pg 1-23\n",
+"\n",
+"wavelength=5.82*10^-5 //wavelength of a monochromatic light\n",
+"\n",
+"u=1.5 //refractive index of glass\n",
+"\n",
+"a=(20/3600)*(%pi/180) //angle made by glass film in radians\n",
+"\n",
+"B=wavelength/(2*u*a) //The fringe width \n",
+"\n",
+"N=1/B //the number of fringes per cm\n",
+"\n",
+"printf('\nThe number of fringes per cm = %.f \n',N)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.3_5: find_the_diameter_of_wire.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_3_5,pg 1-24\n",
+"\n",
+"wavelength=6*10^-5 //wavelength of light \n",
+"\n",
+"B=0.1 //fringe width(as there are 10 fringes)\n",
+"\n",
+"u=1 //refractive index of air wedge\n",
+"\n",
+"a=wavelength/(2*u*B) //as fringe spacing is 'B = wavelength/(2*a*u)'\n",
+"\n",
+"dist=10 //distance of plane of rectangular pieces from wire \n",
+"\n",
+"d=a*dist //as for small angle 'tan(a) = a = d/dist'\n",
+"\n",
+"printf('\nThe diameter of wire is d = %.3f cm\n',d)\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.3_6: find_the_separation_between_consecutive_bright_fringes.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_3_6,pg 1-24\n",
+"\n",
+"a=10^-4 //as for small angle 'tan(a) = a'\n",
+"\n",
+"wavelength=5900*10^-10 //wavelength of light in air\n",
+"\n",
+"u=1 //refractive index of air \n",
+"\n",
+"B=wavelength/(2*u*a) //The fringe width \n",
+"\n",
+"printf('\nThe fringe width is B = %.5f m\n',B)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_11: find_the_diameter_of_ring.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_11,pg 1-37\n",
+"\n",
+"D_4=0.4 //diameter of 4th dark ring\n",
+"\n",
+"D_12=0.7 //diameter of 12th dark ring \n",
+"\n",
+"const=D_4^2/(4*4) //assume (R*wavelength = const) for 4th dark ring\n",
+"\n",
+"D_20=sqrt(4*20*const) //For 20th dark ring \n",
+"\n",
+"printf('\nDiameter of 20th dark ring is D20 = %.3f cm\n',D_20)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_12: calculate_the_wavelength_of_light.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_12,pg 1-38\n",
+"\n",
+"n_1=5 //5th ring \n",
+"\n",
+"n_2=15 //15th ring \n",
+"\n",
+"p=n_2-n_1 //difference between rings\n",
+"\n",
+"Dn_1=0.336 //diameter of 5th ring \n",
+"\n",
+"Dn_2=0.59 //diameter of 15th ring\n",
+"\n",
+"R=100 //Radius of curvature\n",
+"\n",
+"wavelength=(Dn_2^2-Dn_1^2)/(4*p*R)*10^8 //wavelength of light \n",
+"\n",
+"printf('\nwavelength of light is = %.f A.',wavelength)\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_1: find_the_ring_number.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_1,pg 1-32\n",
+"\n",
+"//let the diameter of nth dark ring be double the diameter of that of 40th ring \n",
+"\n",
+"//as Dn^2 = 4*R*n*wavelength\n",
+"\n",
+"n_1=40 //40 th dark ring\n",
+"\n",
+"n=4*n_1 //as diameter is double\n",
+"\n",
+"printf('\nThe ring number is n= %.f',n)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_2: find_radius_of_curvature_and_thickness_of_film.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_2,pg 1-32\n",
+"\n",
+"//For dark rings Dn=sqrt(4*R*n*wavelength)\n",
+"\n",
+"n=10 //10th ring\n",
+"\n",
+"Dn=0.5 //diameter of 10th ring \n",
+"\n",
+"wavelength=5*10^-5 //wavelength of light\n",
+"\n",
+"R=Dn^2/(4*n*wavelength) //radius of curvature \n",
+"\n",
+"t=Dn^2/(8*R) //thickness of film\n",
+"\n",
+"printf('\nThe radius of curvature is R = %.2f cm\n',R)\n",
+"\n",
+"printf('\nThe thickness of film is t = %.5f cm\n',t)\n",
+"\n",
+"//mistake in textbook"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_3: find_the_radius_of_curvature.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_3,pg 1-33\n",
+"\n",
+"n_1=5 //5th ring \n",
+"\n",
+"n_2=15 //15th ring \n",
+"\n",
+"p=n_2-n_1 //difference between rings\n",
+"\n",
+"Dn_1=0.336 //diameter of 5th ring \n",
+"\n",
+"Dn_2=0.59 //diameter of 15th ring\n",
+"\n",
+"wavelength=5890*10^-8 //wavelength of light\n",
+"\n",
+"R=(Dn_2^2-Dn_1^2)/(4*p*wavelength) //radius of curvature\n",
+"\n",
+"printf('\nThe radius of curvature is R = %.2f cm\n',R)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_4: find_the_wavelength_of_light.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_4,pg 1-33\n",
+"\n",
+"//as n1 = nth ring n2 = (n+8)th ring\n",
+"\n",
+"p=8 //difference between rings\n",
+"\n",
+"Dn_1=0.42 //diameter of 5th ring \n",
+"\n",
+"Dn_2=0.7 //diameter of 15th ring\n",
+"\n",
+"R=200 //radius of curvature\n",
+"\n",
+"wavelength=(Dn_2^2-Dn_1^2)/(4*p*R) //wavelength of light\n",
+"\n",
+"printf('\nThe wavelength of light is wavelength = %.6f cm\n',wavelength)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_5: find_the_refractive_index_of_liquid.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter-1,Example1_4_5,pg 1-34\n",
+"\n",
+"Dn_1=0.218 //Diameter of nth ring\n",
+"\n",
+"Dn_2=0.451 //Diameter of (n+10)th ring\n",
+"\n",
+"wavelength=5893*10^-8 //wavelength of light \n",
+"\n",
+"R=90 //Radius of curvature \n",
+"\n",
+"p=10\n",
+"\n",
+"u=(4*p*wavelength*R)/(Dn_2^2-Dn_1^2) //Refractive index of liquid \n",
+"\n",
+"printf('\nRefractive index of liquid is u = %.3f',u)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_6: find_the_diameter_of_dark_ring.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//chapter-1,Example1_4_6,pg 1-34\n",
+"\n",
+"//For nth dark ring Dn^2 =4*R*n*wavelength\n",
+"\n",
+"D_5=0.42 //Diameter of 5th dark ring\n",
+"\n",
+"D_10=sqrt(2*D_5^2) //as number of ring double, the diameter is sqrt(2) times the diameter of original ring\n",
+"\n",
+"printf('\nThe diameter of 10th dark ring is D10 = %.3f cm',D_10)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_7: find_the_diameter_of_dark_ring.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_7,pg 1-35\n",
+"\n",
+"R=200 //radius of curvature\n",
+"\n",
+"wavelength_1=6000*10^-8 //wavelength of light for nth dark ring\n",
+"\n",
+"wavelength_2=5000*10^-8 //wavelength of light for (n+1)th dark ring\n",
+"\n",
+"//as nth ring due to wavelength_1= 6000*10^-8 cm is coincide with (n+1)th ring due to wavelength_2=5000*10^-8 cm\n",
+"\n",
+"//therefore 6*n = 5*(n+1)\n",
+"\n",
+"n=5\n",
+"\n",
+"Dn=sqrt(4*R*n*wavelength_1)\n",
+"\n",
+"printf('\nDiameter of nth dark ring due to wavelength 6000 A. is Dn = %.4f cm\n',Dn)\n",
+"\n",
+"//wrong ans in textbook"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.4_8: find_the_refractive_index_of_liquid.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_4_8,pg 1-35\n",
+"\n",
+"D_air=2.3 //Diameter of bright ring in air\n",
+"\n",
+"D_liquid=2 //Diameter of bright ring in liquid\n",
+"\n",
+"u=D_air^2/D_liquid^2 //Refractive index of liquid\n",
+"\n",
+"printf('\n The refractive index of liquid is u = %.4f \n',u)"
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.7_1: find_the_thickness_of_coating.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_7_1,pg 1-42\n",
+"\n",
+"wavelength=560 //wavelength of light in air\n",
+"\n",
+"u=2.0 //refractive index of silicon monoxide material\n",
+"\n",
+"//The wavelength of 'wavelength_1' in a medium of refractive index 'u' is \n",
+"\n",
+"wavelength_1=wavelength/u\n",
+"\n",
+"t=wavelength_1/4 //thickness of the film \n",
+"\n",
+"printf('\nThe thickness of the film is = %.f nm\n',t)\n",
+""
+ ]
+ }
+,
+{
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "## Example 1.7_2: find_the_thickness_of_coating.sce"
+ ]
+ },
+ {
+"cell_type": "code",
+ "execution_count": null,
+ "metadata": {
+ "collapsed": true
+ },
+ "outputs": [],
+"source": [
+"//Chapter-1,Example1_7_2,pg 1-42\n",
+"\n",
+"wavelength=6000 //wavelength of light in air\n",
+"\n",
+"u=1.2 //refractive index of transparant material\n",
+"\n",
+"wavelength_1=wavelength/u //The wavelength of wavelength_1 in a medium of refractive index 'u'\n",
+" \n",
+"t=wavelength_1/4 //thickness of coating\n",
+"\n",
+"printf('\nThe thickness of coating to eliminate reflection is t = %.f A.\n',t)"
+ ]
+ }
+],
+"metadata": {
+ "kernelspec": {
+ "display_name": "Scilab",
+ "language": "scilab",
+ "name": "scilab"
+ },
+ "language_info": {
+ "file_extension": ".sce",
+ "help_links": [
+ {
+ "text": "MetaKernel Magics",
+ "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md"
+ }
+ ],
+ "mimetype": "text/x-octave",
+ "name": "scilab",
+ "version": "0.7.1"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 0
+}