summaryrefslogtreecommitdiff
path: root/1985/CH6/EX6.2/Chapter6_Example2.sce
diff options
context:
space:
mode:
Diffstat (limited to '1985/CH6/EX6.2/Chapter6_Example2.sce')
-rwxr-xr-x1985/CH6/EX6.2/Chapter6_Example2.sce13
1 files changed, 13 insertions, 0 deletions
diff --git a/1985/CH6/EX6.2/Chapter6_Example2.sce b/1985/CH6/EX6.2/Chapter6_Example2.sce
new file mode 100755
index 000000000..7da6ce6e5
--- /dev/null
+++ b/1985/CH6/EX6.2/Chapter6_Example2.sce
@@ -0,0 +1,13 @@
+clc
+clear
+//Input data
+r=[0.1,0.4]//Radii of curvature in m
+u=[1.5230,1.5145]//Refractive indices of the lens for violet and red light respectively
+
+//Calculations
+fr=1/((u(2)-1)*((1/r(1))-(1/r(2))))//Focal length of the lens for red light in m
+fv=1/((u(1)-1)*((1/r(1))-(1/r(2))))//Focal length of the lens for violet light in m
+f=fr-fv//Longitudinal chromatic aberration in m
+
+//Output
+printf('Longitudinal chromatic aberration for an object at infinity is %3.4f m',f)