Chapter 23 : Mirrors and lenses

Example 23.1 Page No: 760

In [1]:
from __future__ import division
AC= 1.8-.1#in m
AD=.5*AC
CF=.10#/in m
X=.5*CF#in m
FA=1.8#in m
d=FA-AD-X
print "The hight = %0.2f m"%d
The hight = 0.90 m

Example 23.2 Page No : 767

In [3]:
p=25#in cm
f=10#in cm
x=(1/f)-(1/p)
q=1/x
p=25
M=-(q/p)
print "part a"
print "The magnification when object is at 25cm : %0.2f"%M
p=5#in cm
f=10#in cm
x=(1/f)-(1/p)
q=1/x
p=5
M=-(q/p)
print "part c"
print "The magnification when object is at 5cm : %0.2f"%M
part a
The magnification when object is at 25cm : -0.67
part c
The magnification when object is at 5cm : 2.00

Example 23.3 Page No: 768

In [5]:
p=20#in cm
f=-8#in cm
x=(1/f)-(1/p)
q=1/x
p=25
M=-(q/p)
print "part a"
print "The position of final image = %0.2f cm"%q
print "part b"
print "The magnification : %0.2f"%M
part a
The position of final image = -5.71 cm
part b
The magnification : 0.23

Example 23.4 Page No: 769

In [6]:
p=40#in cm
q=-(2*p)

x=(1/p)-(1/q)
f=1/x
print "The focal length = %0.2f cm"%f
#Answer given in book is wrong
The focal length = 26.67 cm

Example 23.5 Page No: 770

In [7]:
p=20#in cm
n1=1.5#in cm
n2=1#in cm
R=-30#in cm
x=(n2-n1)/R
y=n1/p
s=x-y
q=1/s
print "The position of final image = %0.2f cm"%q
M=(n1*q)/(n2*p)
print "The magnification when object = %0.2f cm"%M
h=2#in cm
h1=-M*h
print "The Position of image = %0.2f cm"%h1
The position of final image = -17.14 cm
The magnification when object = -1.29 cm
The Position of image = 2.57 cm

Example 23.7 Page No: 777

In [8]:
p=30#in cm
f=10#in cm
x=(1/f)-(1/p)
q=1/x

M=-(q/p)
print "part a"
print "The position of final image = %0.2f cm"%q
print "The magnification : %0.2f"%M
p=5#in cm
f=10#in cm
x=(1/f)-(1/p)
q=1/x
M=-(q/p)
print "part b"
print "The position of final image = %0.2f cm"%q
print "The magnification : %0.2f"%M
part a
The position of final image = 15.00 cm
The magnification : -0.50
part b
The position of final image = -10.00 cm
The magnification : 2.00

Example 23.8 Page No: 778

In [9]:
p=30#in cm
f=-10#in cm
x=(1/f)-(1/p)
q=1/x

M=-(q/p)
print "part a"
print "The position of final image = %0.2f cm"%q
print "The magnification : %0.2f"%M
p=10#in cm
f=-10#in cm
x=(1/f)-(1/p)
q=1/x
M=-(q/p)
print "part b"
print "The position of final image = %0.2f cm"%q
print "The magnification : %0.2f"%M
p=5#in cm
f=-10#in cm
x=(1/f)-(1/p)
q=1/x
M=-(q/p)
print "part c"
print "The position of final image = %0.2f cm"%q
print "The magnification : %0.2f"%M
part a
The position of final image = -7.50 cm
The magnification : 0.25
part b
The position of final image = -5.00 cm
The magnification : 0.50
part c
The position of final image = -3.33 cm
The magnification : 0.67

Example 23.9 Page No: 779

In [2]:
p=30#in cm
f=10#in cm
x=(1/f)-(1/p)
q=1/x

M1=-(q/p)

p=5#in cm
f=20#in cm
x=(1/f)-(1/p)
q=1/x

M2=-(q/p)


M=M1*M2
print "The magnification : %0.2f"%M
The magnification : -0.67