summaryrefslogtreecommitdiff
path: root/3648/CH22/EX22.1
diff options
context:
space:
mode:
Diffstat (limited to '3648/CH22/EX22.1')
-rw-r--r--3648/CH22/EX22.1/Ex22_1.sce10
-rw-r--r--3648/CH22/EX22.1/Ex22_1.txt2
2 files changed, 12 insertions, 0 deletions
diff --git a/3648/CH22/EX22.1/Ex22_1.sce b/3648/CH22/EX22.1/Ex22_1.sce
new file mode 100644
index 000000000..819347a34
--- /dev/null
+++ b/3648/CH22/EX22.1/Ex22_1.sce
@@ -0,0 +1,10 @@
+//Example 22_1
+clc();
+clear;
+//To find the position and size of the image
+d1=5 //units in cm
+d2=30 //units in cm
+i=(d1*d2)/(d2-d1) //Units in cm
+d3=2 //units in cm
+I=(i/d2)*d3 //units in cm
+printf("The position of the image is i=%d cm\nThe Size of the image is I=%.2f cm High",i,I)
diff --git a/3648/CH22/EX22.1/Ex22_1.txt b/3648/CH22/EX22.1/Ex22_1.txt
new file mode 100644
index 000000000..3e899e85a
--- /dev/null
+++ b/3648/CH22/EX22.1/Ex22_1.txt
@@ -0,0 +1,2 @@
+The position of the image is i=6 cm
+The Size of the image is I=0.40 cm High \ No newline at end of file