summaryrefslogtreecommitdiff
path: root/1535/CH1/EX1.6
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /1535/CH1/EX1.6
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 '1535/CH1/EX1.6')
-rwxr-xr-x1535/CH1/EX1.6/Ch01Ex6.sci10
1 files changed, 10 insertions, 0 deletions
diff --git a/1535/CH1/EX1.6/Ch01Ex6.sci b/1535/CH1/EX1.6/Ch01Ex6.sci
new file mode 100755
index 000000000..d9d9930d3
--- /dev/null
+++ b/1535/CH1/EX1.6/Ch01Ex6.sci
@@ -0,0 +1,10 @@
+// Scilab Code Ex1.6 : Page-25 (2010)
+lambda1 = 400e-09; // Lower limit of wavelength of visible region, m
+lambda2 = 700e-09; // Upper limit of wavelength of visible region, m
+c = 3e+08; // Speed of light in vacuum, m/s
+f1 = c/lambda1; // Upper limit of frequency of visible region, m
+f2 = c/lambda2; // Lower limit of frequency of visible region, m
+printf("\nThe frequency equivalent of %3g nm to %3g nm is %3.1e Hz to %3.1e Hz", lambda1/1e-09, lambda2/1e-09, f1, f2);
+
+// Result
+// The frequency equivalent of 400 nm to 700 nm is 7.5e+014 Hz to 4.3e+014 Hz