In [1]:

```
#Given
f=5.0 #cm
D=25
#Calculation
M=1+(D/f)
#Result
print"Magnifying power is",M
```

In [6]:

```
#Given
f=6.25 #cm
v=-25
#Calculation
u=v*f/(v-f)
M=1+(D/f)
M1=D/f
#Result
print"(i) The distance of the object from the lens is", M
print"(ii) Anguar magnification is",M1
```

In [15]:

```
#Given
u=-9
f=10 #cm
v1=-25.0
#Calculation
v=u*f/(u+f)
M=v/u
u=-v1*f/(v1-f)
M1=1-(v1/f)
#Result
print"(i) Magnification is", M,"\n Size of each square in the image will appear as 100 mm**2"
print"(ii) Magnification is",M1
```

In [28]:

```
#Given
v=-25
f=10.0
#Calculation
u=-v*f/(f-v)
m=-v/u
M=1-(v/f)
#Result
print"(a) Distance is", round(u,2),"cm"
print"(b) Magnification is",m
print"(c) Magnification is",M
```

In [29]:

```
#Given
M=-30
fe=5 #cm
D=25 #cm
#Calculation
m0=M/(1+(D/fe))
#Result
print"Magnification produced is",m0
```

In [34]:

```
#Given
f0=4
u0=-6
D=25
fe=6.0
#Calculation
v0=f0*u0/(f0+u0)
M=v0/u0*(1+(D/fe))
#Result
print"Magnification produceed by the microscope is", round(M,2)
```

In [41]:

```
#Given
L=20
fe=5
f0=1.0
#Calculation
v01=L-fe
u0=v01*f0/(f0-v01)
M=v01*D/(u0*fe)
#Result
print"Magnification power is", M,"\nThe -ve sigh shows that the image formed is inverted and real"
```

In [46]:

```
#Given
f=36 #cm
M=-8
#Calculation
fe=-f/(M-1)
f0=-M*fe
#Result
print"Focal length of the lenses is", fe,"cm and",f0,"cm"
```

In [49]:

```
#Given
f=75 #cm
fe=5.0
D=25
#Calculation
M=-f/fe*(1+(fe/D))
#Result
print"Magnying power is",M
```

In [54]:

```
#Given
f0=140
fe=5
D=25.0
#Calculation
M=-f0/fe
M1=-(f0/fe)*(1+(fe/D))
#Result
print"(a) Magnefying power, when telescope is in normal adjustment is", M
print"(b) Magnifying power, when image is formed at least distance of distinct vision is is",M1
```

In [71]:

```
#Given
f0=1 #m
fe=0.05
I=0.92*10**-2
u0=38*10**-7
fe1=5.0 #cm
ve=-25
#Calculation
d=I*u0/f0
L=f0+fe
ue=ve*fe1/(fe1-ve)
L1=(f0*10**2)-ue
#Result
print"(i) Distance between two lenses is", L*10**2,"cm"
print"(ii) Distance when final image at 25 cm from the eye is",round(L1,2),"cm"
```

In [74]:

```
#Given
M=-20
R=120
#Calculation
f0=R/2.0
fe=-f0/M
#Result
print"Focal length of the eye piece is",fe,"cm"
```

In [76]:

```
#Given
d=0.8 #cm
D=508
#Calculation
B=D**2/d**2
#Result
print"The telescope can see a star ",B,"time sfarther than the faintest star that can be seen with naked eye."
```

In [87]:

```
#Given
ve=-25 #cm
fe=6.25
a=15
f0=2
#Calculation
ue=-ve*fe/(ve-fe)
v0=a+ue
u0=f0*v0/(f0-v0)
v01=a-fe
u01=v01*f0/(f0-v01)
#Result
print"(a) Distance when final image at least distance of distinct vision is", u0,"cm"
print"(b) Distance when final image is at infinity is",round(u01,2),"cm"
```

In [95]:

```
#Given
a=10
D=24
fe=20.0
#Calculation
import math
A=a/(1+(D/fe))/100.0
#Result
print"Angle is", round(A,4),"radian"
```

In [103]:

```
#Given
f0=-0.5 #m
fe=0.01
d=3.48*10**6
r=3.8*10**8
a1=15
#Calculation
M=f0/fe
a=d/r
I=a*a1
#Result
print"(a) Angular Magnification of the telescope is",M
print"(b) Diameter of the image is", round(I,3),"m"
```