summaryrefslogtreecommitdiff
path: root/1016/CH5/EX5.1
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /1016/CH5/EX5.1
downloadScilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip
initial commit / add all books
Diffstat (limited to '1016/CH5/EX5.1')
-rwxr-xr-x1016/CH5/EX5.1/ex5_1.sce20
1 files changed, 20 insertions, 0 deletions
diff --git a/1016/CH5/EX5.1/ex5_1.sce b/1016/CH5/EX5.1/ex5_1.sce
new file mode 100755
index 000000000..fda7cd3ae
--- /dev/null
+++ b/1016/CH5/EX5.1/ex5_1.sce
@@ -0,0 +1,20 @@
+clc;clear;
+//Example 5.1
+
+//given values
+W1=4;//wavelength in Angstrom
+W2=1;//wavelength in Angstrom
+e=1.6*10^-19;//the charge on electron in C
+m=9.12*10^-31;//mass of electron in kg
+
+//calculation
+disp("Part (i)");
+E=12400/W1;
+disp(E,'The energy in eV is');
+v=sqrt(E*e*2/m);
+disp(v,'The velocity in m/s is');
+disp("Part (ii)");
+E=12400/W2;
+disp(E,'The energy in eV is');
+v=sqrt(E*e*2/m);
+disp(v,'The velocity in m/s is') \ No newline at end of file