From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 2855/CH1/EX1.1/Ex1_1.sce | 19 +++++++++++++++++++ 2855/CH1/EX1.10/Ex1_10.sce | 10 ++++++++++ 2855/CH1/EX1.11/Ex1_11.sce | 10 ++++++++++ 2855/CH1/EX1.12/Ex1_12.sce | 11 +++++++++++ 2855/CH1/EX1.13/Ex1_13.sce | 12 ++++++++++++ 2855/CH1/EX1.14/Ex1_14.sce | 19 +++++++++++++++++++ 2855/CH1/EX1.15/Ex1_15.sce | 14 ++++++++++++++ 2855/CH1/EX1.16/Ex1_16.sce | 19 +++++++++++++++++++ 2855/CH1/EX1.17/Ex1_17.sce | 22 ++++++++++++++++++++++ 2855/CH1/EX1.18/Ex1_18.sce | 13 +++++++++++++ 2855/CH1/EX1.2/Ex1_2.sce | 21 +++++++++++++++++++++ 2855/CH1/EX1.3/Ex1_3.sce | 19 +++++++++++++++++++ 2855/CH1/EX1.4/Ex1_4.sce | 22 ++++++++++++++++++++++ 2855/CH1/EX1.5/Ex1_5.sce | 21 +++++++++++++++++++++ 2855/CH1/EX1.6/Ex1_6.sce | 14 ++++++++++++++ 2855/CH1/EX1.7/Ex1_7.sce | 14 ++++++++++++++ 2855/CH1/EX1.8/Ex1_8.sce | 18 ++++++++++++++++++ 2855/CH1/EX1.9/Ex1_9.sce | 10 ++++++++++ 18 files changed, 288 insertions(+) create mode 100644 2855/CH1/EX1.1/Ex1_1.sce create mode 100755 2855/CH1/EX1.10/Ex1_10.sce create mode 100755 2855/CH1/EX1.11/Ex1_11.sce create mode 100755 2855/CH1/EX1.12/Ex1_12.sce create mode 100755 2855/CH1/EX1.13/Ex1_13.sce create mode 100755 2855/CH1/EX1.14/Ex1_14.sce create mode 100755 2855/CH1/EX1.15/Ex1_15.sce create mode 100755 2855/CH1/EX1.16/Ex1_16.sce create mode 100755 2855/CH1/EX1.17/Ex1_17.sce create mode 100755 2855/CH1/EX1.18/Ex1_18.sce create mode 100644 2855/CH1/EX1.2/Ex1_2.sce create mode 100644 2855/CH1/EX1.3/Ex1_3.sce create mode 100755 2855/CH1/EX1.4/Ex1_4.sce create mode 100755 2855/CH1/EX1.5/Ex1_5.sce create mode 100755 2855/CH1/EX1.6/Ex1_6.sce create mode 100755 2855/CH1/EX1.7/Ex1_7.sce create mode 100644 2855/CH1/EX1.8/Ex1_8.sce create mode 100755 2855/CH1/EX1.9/Ex1_9.sce (limited to '2855/CH1') diff --git a/2855/CH1/EX1.1/Ex1_1.sce b/2855/CH1/EX1.1/Ex1_1.sce new file mode 100644 index 000000000..826a3efe2 --- /dev/null +++ b/2855/CH1/EX1.1/Ex1_1.sce @@ -0,0 +1,19 @@ + + + + + +//Example1-1 +//Given +clc; +clear all; +printf("(i) t1=d/c \n"); +printf(" (ii) t2=[(d-5)/c]+[5/v2] \n"); +printf(" v2=c/n2 \n"); +printf(" t2=(d+2.5)/c\n"); +printf(" (iii) delta_t=t2-t1=(d+2.5-d)/c\n"); +c=3*10^8; //Speed of light in m/s +delta_t=2.5*10^-2/c; //converted 2.5 cm into meters +printf('The time difference %e s",delta_t ); +printf("\n Arrival time difference of two monochromatic beams is %0.0f ps",delta_t*10^12) +// Answer misprinted in the book diff --git a/2855/CH1/EX1.10/Ex1_10.sce b/2855/CH1/EX1.10/Ex1_10.sce new file mode 100755 index 000000000..2cc6c1f21 --- /dev/null +++ b/2855/CH1/EX1.10/Ex1_10.sce @@ -0,0 +1,10 @@ +//Example no 1-10 +//page no. 26 +clc; +clear; +//p=m/{m+[2*n/(1-n)^2]^2}; + +m=5; //no. of reflective plates +n=1.33; //refractive indices +p=m/{m+[2*n/(1-(n)^2)]^2}; //degree of polarisation +printf("\n The degree of polarisation is %0.1f \n",p); diff --git a/2855/CH1/EX1.11/Ex1_11.sce b/2855/CH1/EX1.11/Ex1_11.sce new file mode 100755 index 000000000..043da93d6 --- /dev/null +++ b/2855/CH1/EX1.11/Ex1_11.sce @@ -0,0 +1,10 @@ +//Example no 1-11 +//page no. 26 +clc; +clear; +//m= p*{m+[2*n/(1-n)^2]^2}; + +n=1.5; //refractive indices +p=0.45; //degree of polarisation +m={p*[2*n/(1-n^2)]^2}/(1-p); +printf("\n Thus it will require %0.0f reflective plate to achive a degree of polarization equal to 0.45",m); //Result mis rounded of to nearest integer diff --git a/2855/CH1/EX1.12/Ex1_12.sce b/2855/CH1/EX1.12/Ex1_12.sce new file mode 100755 index 000000000..7118228bb --- /dev/null +++ b/2855/CH1/EX1.12/Ex1_12.sce @@ -0,0 +1,11 @@ + +//Example no 1-12 +//page no. 27 +clc; +clear; +//I1/I0=cos(w)^2 +//k=I1/I0; + +w=30; //angle bw polarizer and analyser in degee +k=cosd(w)^2; +disp(k,'The ratio of optical ray intensity ,I1/I0='); //Result diff --git a/2855/CH1/EX1.13/Ex1_13.sce b/2855/CH1/EX1.13/Ex1_13.sce new file mode 100755 index 000000000..f397c1c8a --- /dev/null +++ b/2855/CH1/EX1.13/Ex1_13.sce @@ -0,0 +1,12 @@ +//Example no 1-13 +//page no. 27 +clc; +clear; +//I1/I0=cos(w)^2 +//Given I1/I0=0.55 + +k=sqrt(0.55); //from above formulae +printf("\n cos w is %0.2f ",k); +printf("\n The angle bw polarizer and analyser , w is %0.0f degree",acos(k)*180/%pi);//Result + + diff --git a/2855/CH1/EX1.14/Ex1_14.sce b/2855/CH1/EX1.14/Ex1_14.sce new file mode 100755 index 000000000..feb56582f --- /dev/null +++ b/2855/CH1/EX1.14/Ex1_14.sce @@ -0,0 +1,19 @@ +//Example no 1-14 +//page no. 29 +clc; +clear; +disp('Solution (i) is '); +ne=1.4;//refractive index +no=1.25; //refractive index +c=3*10^8; //in m/s +T=2*10^-5; //in m +l=740; //in nm +t=[ne-no]*T/c; //time difference +printf("\n Time difference, t is %0.2f ps",t*10^12);// result +disp('Solution (ii) is '); +le=l/ne; +lo=l/no; +fi=2*%pi*T*(1/le-1/lo)*10^9; +printf("\n Phase difference is %0.1f rad",fi);// result +// Answer misprinted in book + diff --git a/2855/CH1/EX1.15/Ex1_15.sce b/2855/CH1/EX1.15/Ex1_15.sce new file mode 100755 index 000000000..d14fe5215 --- /dev/null +++ b/2855/CH1/EX1.15/Ex1_15.sce @@ -0,0 +1,14 @@ + + +//page no. 31 +//Example no 1-15 +//E=h*v=h*c/l; +clc; +clear; +E=3; //In KeV +//1eV=1.6*10^-19 +h=6.63*10^-34; //plank constant in J/s +c=3*10^8; // speed of light in m/s +l=h*c/(E*10^3*1.6*10^-19);// wavelength in nm +printf("wavelength of a electromagnetic radiation is %0.3f nm",l*10^9);//result + diff --git a/2855/CH1/EX1.16/Ex1_16.sce b/2855/CH1/EX1.16/Ex1_16.sce new file mode 100755 index 000000000..6923f701f --- /dev/null +++ b/2855/CH1/EX1.16/Ex1_16.sce @@ -0,0 +1,19 @@ + +//page no. 31 +//Example no 1-16 +clc; +clear; +disp('Solution (i) is '); +l=670//in nm +h=6.63*10^-34; // plank constant in J/s +c=3*10^17//speed of light in nm/sec +Ek=0.75//In eV +phi=(h*c/l)/(1.6*10^-19) -Ek; +phi=round(phi*10)/10; //round to 1 decimal point +printf("\n Characteristic of material = %0.1f eV\n",phi);//result +disp('Solution (ii) is '); +fc=phi*1.6*10^-19/h*10^-12;// frequency in THz//result +fc=round(fc); +printf("\n Cuttoff frequency is = %0.0f THz\n",fc);//result +lc=c/(fc*10^12); //in nm +printf("\n Cuttoff wavelength is = %0.0f nm\n",lc);//result diff --git a/2855/CH1/EX1.17/Ex1_17.sce b/2855/CH1/EX1.17/Ex1_17.sce new file mode 100755 index 000000000..6c14e84b3 --- /dev/null +++ b/2855/CH1/EX1.17/Ex1_17.sce @@ -0,0 +1,22 @@ + + +//page no. 31 +//Example no 1-17 +clc; +clear all; +disp('Solution (i) is '); +l=0.045;//wavelength in nm +h=6.63*10^-34; //planks constant in J/s +c=3*10^8; //speed of light in m/s +E=h*c/l/10^-9; //energy of photon in eV +mprintf("\n E = %e J",E); +E1=E/(1.6*10^-19); // energy in joule +mprintf("\n E = %e eV",E1); +e=1.6*10^-19; // charge of electron +disp('Solution (ii) is '); +V=E/e; +printf("\n Required voltage is = %0.2f KV",V/1000);// result + +// Value of wavelenght in problem is .45 but in the solution is .045 +//the value considered above is .045 + diff --git a/2855/CH1/EX1.18/Ex1_18.sce b/2855/CH1/EX1.18/Ex1_18.sce new file mode 100755 index 000000000..40281af6e --- /dev/null +++ b/2855/CH1/EX1.18/Ex1_18.sce @@ -0,0 +1,13 @@ +//page no. 36 +//Example no 1-18 +clc; +clear; + +disp('Solution (i) is '); +x=620// difference in particle momentum In nm +h=6.63*10^-34// planks constant In J/s +//p=h/(4*%pi*x); +//m*v=h/(4*%pi*x); +m=9.11*10^-31 //In kg // mass of electron +v=h /(4*%pi* x *10^-9*m);// electron velocity +printf("\n The uncertanity in electron velocity is %0.0f m/s \n",v);// result diff --git a/2855/CH1/EX1.2/Ex1_2.sce b/2855/CH1/EX1.2/Ex1_2.sce new file mode 100644 index 000000000..532587036 --- /dev/null +++ b/2855/CH1/EX1.2/Ex1_2.sce @@ -0,0 +1,21 @@ + + + + + +//given +//page no 5 +clc; +clear; +//Applying Snell's law +a=1*sin(428)/1.333;//a=sin(w2) +printf("Angle of refraction is %0.1f\n ",a) +printf("\n Angle of refraction is %0.0f degree \n ",asin(a)*57.27) +c=3*10^8; //speed of light in m/s +n2=1.333; //refractive index of 2nd medium +v2=c/n2; //velocity in second medium in m/s +n1=1; //refractive index of 1st medium +l1=620; //in nm wavelength +printf("\n Velocity of optical ray through medium second %0.02f*10^8 m/s\n",v2/10^8); +l2= (n1*l1)/n2; //wavelength in 2nd medium in nm +printf("\n Wavelenght of optical ray through medium second %0.1f nm",l2); //Result diff --git a/2855/CH1/EX1.3/Ex1_3.sce b/2855/CH1/EX1.3/Ex1_3.sce new file mode 100644 index 000000000..f38bc4bcc --- /dev/null +++ b/2855/CH1/EX1.3/Ex1_3.sce @@ -0,0 +1,19 @@ + + + + + +//given +//page no 5 +clc; +clear; +n1=1; //refractive index of air +n2=1.56; //refractive index of medium +w1=60; //in deg C +//using snell's law +a= n1*sind(w1)/n2; //a=sin(w1) +w2=asind(a); //in degree +printf("Angle of refraction is %0.2f degree\n ",w2); +B=w1-w2; //in degree +printf("Angle of deviation is %0.1f degree\n ",B) +// The answer doesn't match because of priting errorsin calculation as sin(608) diff --git a/2855/CH1/EX1.4/Ex1_4.sce b/2855/CH1/EX1.4/Ex1_4.sce new file mode 100755 index 000000000..ef4150dea --- /dev/null +++ b/2855/CH1/EX1.4/Ex1_4.sce @@ -0,0 +1,22 @@ +//given +//page no 6 +clc; +disp('Solution (i)'); + w=5/12.5; // tan(w)=5/12.5; +printf("\n The value of tan(w2) is %0.1f \n",w); +w2=atan(w)*180/%pi; +//w2=atan(w)*180/%pi +printf("\n The value of w2 is %0.1f degree\n",w2); +printf("\n The value of sin(w2) is %0.2f \n",sin(w2*%pi/180)); +disp('Solution (ii)'); +//Applying snell's law +n1=1.05; +n2=1.5; +w1=(n2*sin(w2*%pi/180))/n1;//a=sin(w1) +printf("\n The value of sin(w1) is %0.2f \n",w1); +printf("\n The value of w1 is %0.0f degree \n",asin(w1)*180/%pi); +//value of w1 +//tan(w1)=(p-x)12.5; +k=0.62*12.5; +d=1.05*[(12.5)^2+(k)^2]^0.5 +1.5*(12.5^2+5^2)^0.5;//d=1.05[(h1)^2+(k)^2]^0.5 +n2(h2^2+x^2)^0.5; +printf("\n the optical distance is %0.2f cm\n",d); diff --git a/2855/CH1/EX1.5/Ex1_5.sce b/2855/CH1/EX1.5/Ex1_5.sce new file mode 100755 index 000000000..7dba1ca7c --- /dev/null +++ b/2855/CH1/EX1.5/Ex1_5.sce @@ -0,0 +1,21 @@ +//Ex1_5 +//given +//page no 11 +clc; +clear; +c=3*10^8; +disp('Solution (i) is '); +ri=1.5;//refractive index +u=830// in nm +l=u/ri; //in nm +printf("\n Wavelength is %0.0f nm \n",l); +disp('Solution (ii) is '); +l=round(l); // rounding to nearest integer +f=c/(l*10^-9)*10^-12; //in THz +printf("\n frequency is %0.0f THz\n",f); +disp('Solution (iii) is '); +f=round(f); // rounding to nearest integer +v=l*10^-9*f*10^12; //in m/s +mprintf("\n phase velocity is %.3e m/s\n",v);//answer is getting rounding off due to larger calculation + + diff --git a/2855/CH1/EX1.6/Ex1_6.sce b/2855/CH1/EX1.6/Ex1_6.sce new file mode 100755 index 000000000..79ccf1a45 --- /dev/null +++ b/2855/CH1/EX1.6/Ex1_6.sce @@ -0,0 +1,14 @@ +//Ex1_6 +//given +//page no 12 +clc; +clear; +disp('Solution (i) is '); +l=720; //wavelength in nm +n=1.5; //refractive index +lm=l/n; +disp('nm',lm,'Wavelenth is'); //result +disp('Solution (ii) is '); +c=3*10^8; //in m/s speed of light +u=c/n; +disp('m/s',u,'Velocity is'); //result diff --git a/2855/CH1/EX1.7/Ex1_7.sce b/2855/CH1/EX1.7/Ex1_7.sce new file mode 100755 index 000000000..6130a7d1a --- /dev/null +++ b/2855/CH1/EX1.7/Ex1_7.sce @@ -0,0 +1,14 @@ +//Ex1_7 +//given +//page no 12 +clc; +clear; +disp('Solution (i)'); +c=3*10^8; //in m/s speed of light +l=640; //in nm +u=2.2*10^8; //in m/s +lm=u*l/c; //wavelenth in medium +printf("\n The wavelength is %0.1f nm\n",lm);// The answer in the book is misprinted +disp('Solution (ii)'); +n=l/lm; //refractive index +printf("\n Refractive Index is %0.3f \n",n);//The answer in the book is misprinted diff --git a/2855/CH1/EX1.8/Ex1_8.sce b/2855/CH1/EX1.8/Ex1_8.sce new file mode 100644 index 000000000..13206aed4 --- /dev/null +++ b/2855/CH1/EX1.8/Ex1_8.sce @@ -0,0 +1,18 @@ + + + + + +//Ex1_8 +//given +//page no 12 +clc; +clear; +//k=aa+as=6.3; +//Given values from research +k=6.3; //combined attenuation due to absorption and scattering +d=25; //in cm +disp('Solution (ii)'); +//Io/Ii=exp(-(ao+ai)*d); d in m +j=exp(-(k)*d/100); //Io/Ii ratio +printf("\n Io is %0.3f of Ii \n",j); //result diff --git a/2855/CH1/EX1.9/Ex1_9.sce b/2855/CH1/EX1.9/Ex1_9.sce new file mode 100755 index 000000000..f5ee5dde2 --- /dev/null +++ b/2855/CH1/EX1.9/Ex1_9.sce @@ -0,0 +1,10 @@ +//Ex1_9 +//given +//page no 13 +clc; +clear; +// Given formula Io/Ii=exp(-(ao+ai)*d); +// k=aa+as=63.1; +// Io/Ii=1.5 +d=log(.15)/-63.1; //length of tube +printf("\nLength of tube, d = %0.0f cm \n",d*100); //Result -- cgit