#Given data
N= 100
A=4*3 # in cm**2
A=A*10**-4 # in m**2
i=20 # in mA
i=i*10**-3 # in A
B=0.05 # in T
T=N*i*B*A #in Nm
print "Torque developed by the coil = %0.1e Nm" %T
#Given data
N= 125
A=4*2.5 # in cm**2
A=A*10**-4 # in m**2
i=25 # in mA
i=i*10**-3 # in A
B=0.06 # in T
Td=N*i*B*A #in Nm
Tc_BY_theta= 25*10**-7 # in Nm/°
# Formula Tc=Td
theta= Td/Tc_BY_theta # in °
print "Deflection = %0.f degree" %theta
from __future__ import division
#Given data
N= 100
B=6*10**-2 # in Wb/m**2
A=3*4 # in cm**2
A=A*10**-4 # in m**2
V=300 # in volt
R=12000 # in ohm
i= V/R # in amp
Td=N*i*B*A #in Nm
Tc_BY_theta= 25*10**-7 # in Nm/°
# Formula Tc=Td
theta= Td/Tc_BY_theta # in °
print "Deflection = %0.f degree" %theta
from numpy import pi
#Given data
d= 42 # in mm
d=d*10**-3 # in meter
r= 0.6 # in meter
# Formula d= 2*theta*r
theta= d/(2*r) # radian
theta= 180*theta/pi # in °
print "Angle through which coil turn = %0.f°" %theta
#Given data
B=1.8*10**-3 # in Wb/m**2
K= 1.4*10**-7 # in Nm/radian
theta= 90 # in °
theta=theta*pi/180
Tc= K*theta # in N-m
i=5 # in mA
i=i*10**-3 # in amp
A=1.5*1.2 # in cm**2
A=A*10**-4 # in m**2
# Formula Tc= Td= B*i*A*N
N= Tc/(B*i*A)
N=round(N)
print "Number of turns = %0.f" %N
#Given data
B=0.1 # in T
C= 100*10**-7 # in Nm/radian
theta= 120 # in °
theta=theta*pi/180
Tc= C*theta # in N-m
N=200 # number of turns
A=2.5*2 # in cm**2
A=A*10**-4 # in m**2
# Formula Tc= Td= B*i*A*N
i= Tc/(B*A*N) # in amp
print "Current in the coil = %0.4f mA" %(i*10**3)
#Given data
d=150 # in mm
i=2.5 # in micro amp
R=200 # in ohm
V= R*i # in micro volt
r=2.5 # in meter
# Part(i)
Si= d/i # in mm/micro amp
print "Current sensitivity = %0.f mm/µA" %Si
# Part(ii)
Sv= d/V # in mm/micro volt
print "Voltage sensitivity = %0.1f mm/µV" %Sv
# Part(iii)
So= 1/(1/60*10**-6) # in ohm/mm
So=So*10**-6 # in Mohm
print "Megohm sensitivity = %0.f Mohm/mm" %So
# Part(iv)
i=5 # in micro amp
d=60*i # in mm
d=d*10**-3 # in meter
theta=d/(2*r) #in radian
print "The value of deflection = %0.2f radians" %theta
#Given data
Im= 50*10**-6 # in amp
Rm= 1000 # in ohm
I=1 # in amp
Rs= Rm/(I/Im-1) # in ohm
print "Resistance of ammeter shunt required = %0.7f ohm" %Rs
from fractions import Fraction
#Given data
Rm= 1.0 # in ohm
Rse= 4999 # in ohm
V=250 # full scale deflection voltage in volt
# Formula V= Im*(Rm+Rse)
Im= V/(Rm+Rse) # in amp
# Part(a)
Rs= 1/4999 # in ohm
Is= Im*Rm/Rs #in amp
I= Im+Is # in amp
print "Current range = %0.f A" %I
# Part(b)
I=50 # in amp
N=I/Im
Rs= Rm/(N-1) # in ohm
print "Required shunt resistance =",Fraction(Rs).limit_denominator(1000),"ohm"
#Given data
Im= 50 # in micro amp
Im=Im*10**-6 # in amp
Rm= 49 # in ohm
Rs= 1 # in ohm
Is= Im*Rm/Rs #in amp
I= Im+Is # in amp
# (i)
I1= I # in amp
I2= I*0.5 # in amp
I3= I*0.1 # in amp
print "Main circuit current at FSD = %0.1f mA" %(I1*10**3)
print "Main circuit current at 0.5 FSD = %0.2f mA" %(I2*10**3)
print "Main circuit current at 0.1 FSD = %0.2f mA" %(I3*10**3)
#Given data
Rm= 40 # in ohm
Im= 1 # in mA
# For switch at position 1 (lowest range of 10 mA)
I=10 # in mA
N1= I/Im
R1= Rm/(N1-1) # in ohm
# For switch at position 2 (range of 20 mA)
I=20 # in mA
N2= I/Im
R2= (R1+Rm)/N2 # in ohm
# For switch at position 3 (range of 30 mA)
I=30 # in mA
N3= I/Im
R3= (R1+Rm)/N3 # in ohm
# For switch at position 4 (range of 40 mA)
I=40 # in mA
N4= I/Im
R4= (R1+Rm)/N4 # in ohm
# For switch at position 5 (range of 50 mA)
I=50 # in mA
N5= I/Im
R5= (R1+Rm)/N5 # in ohm
r1= R1-R2 # in ohm
r2= R2-R3 # in ohm
r3= R3-R4 # in ohm
r4= R4-R5 # in ohm
r5= R5 # in ohm
print "Resistance of the various sections of the Ayrton's shunt :"
print "r1 = %0.3f ohm" %r1
print "r2 = %0.4f ohm" %r2
print "r3 = %0.4f ohm" %r3
print "r4 = %0.3f ohm" %r4
print "r5 = %0.3f ohm" %r5
#Given data
Rm= 1000 # in ohm
Im= 1 # in mA
Im=Im*10**-3 # in amp
r3=0.05 # in ohm
r2=0.45 # in ohm
r1=4.5 # in ohm
# For switch at contact 1
Rm1= Rm # in ohm
Rs1= r1+r2+r3 # in ohm
I1= Im*(Rm1/Rs1+1) # in A
I1=I1*10**3 # in mA
I1=round((I1/10))*10
print "Ammeter range at contact 1 = %0.f mA" %I1
# For switch at contact 2
Rm2= Rm+r1 # in ohm
Rs2= r2+r3 # in ohm
I2= Im*(Rm2/Rs2+1) # in A
I2=round(I2)
print "Ammeter range at contact 2 = %0.f A" %I2
# For switch at contact 3
Rm3= Rm+r1+r2 # in ohm
Rs3= r3 # in ohm
I3= Im*(Rm3/Rs3+1) # in A
I3=round(I3)
print "Ammeter range at contact 3 = %0.f A" %I3
from fractions import Fraction
#Given data
Rm= 10 # in ohm
Im= 50 # in mA
Im=Im*10**-3 # in amp
V=750 # in volt
R= V/Im-Rm # in ohm
print "External resistance = %0.f ohm" %R
# Part(ii)
I=100 # in A
N=I/Im
Rs= Rm/(N-1) # in ohm
print "Shunt resistance required =",Fraction(Rs).limit_denominator(10000),"ohm"
#Given data
Tc= 120*10**-6 # in N-m
B= 0.5 # in wb/m**2
N=100
A= 4*3 # in cm**2
A=A*10**-4# in m**2
Rm=0
V= 100*1
# Formula Tc= Td = B*I*N*A
I= Tc/(B*N*A) # in amp
R= V/I-Rm # in ohm
print "External required resistance = %0.f ohm" %R
#Given data
Im= 0.2*10**-3 # in amp
Rm= 10 # in ohm
V=100 # in volt
R= V/Im-Rm # in ohm
print "External required resistance = %0.2f kohm" %(R*10**-3)
Im1= 0.75*Im #in amp
V1= Im1*(R+Rm) # in volt
print "Applied voltage at instrument current 0.75 FSD = %0.f volts" %V1
Im2= 0.5*Im #in amp
V2= Im2*(R+Rm) # in volt
print "Applied voltage at instrument current 0.5 FSD = %0.f volts" %V2
Im3= 0.25*Im #in amp
V3= Im3*(R+Rm) # in volt
print "Applied voltage at instrument current 0.25 FSD = %0.f volts" %V3
Im4= 0.1*Im #in amp
V4= Im4*(R+Rm) # in volt
print "Applied voltage at instrument current 0.1 FSD = %0.f volts" %V4
#Given data
CS= 0.1*10**-3 # current sensitivity in amp
VS= 1/CS # voltage sensitivity in ohm/volt
VS= VS*10**-3 # in kohm/volt
Rm=500 # in ohm
Rm=Rm*10**-3 # in kohm
# (i) 0-10 V range
V=10 # full scale delection voltage in volt
R_T= VS*V # in kohm
R1= R_T-Rm # in kohm
print "Additional required resistance at 0-10 V range = %0.1f kohm" %R1
# (ii) 0-50 V range
V=50 # full scale delection voltage in volt
R_T= VS*V # in kohm
R2= R_T-R1-Rm # in kohm
print "Additional required resistance at 0-50 V range = %0.f kohm" %R2
# (i) 0-100 V range
V=100 # full scale delection voltage in volt
R_T= VS*V # in kohm
R3= R_T-R1-R2-Rm # in kohm
print "Additional required resistance at 0-100 V range = %0.f kohm" %R3
# (i) 0-500 V range
V=500 # full scale delection voltage in volt
R_T= VS*V # in kohm
R4= R_T-R1-R2-R3-Rm # in kohm
print "Additional required resistance at 0-500 V range = %0.f kohm" %R4
#Given data
E= 1.5 # in V
R1addRm= 10 # addition of R1 and Rm in kohm
Rx= 0
R=R1addRm+Rx # in kohm
R=R*10**3 # in ohm
I= E/R #meter FSD current in amp
# At 0.8 FSD
Im= 0.8*I # in amp
R= E/Im # in ohm
R=R*10**-3 # in kohm
Rx= R-R1addRm #in kohm
print "Unknown resistance at 0.8 FSD = %0.1f kΩ" %Rx
# At 0.5 FSD
Im= 0.5*I # in amp
R= E/Im # in ohm
R=R*10**-3 # in kohm
Rx= R-R1addRm #in kohm
print "Unknown resistance at 0.5 FSD = %0.f kΩ" %Rx
# At 0.25 FSD
Im= 0.25*I # in amp
R= E/Im # in ohm
R=R*10**-3 # in kohm
Rx= R-R1addRm #in kohm
print "Unknown resistance at 0.25 FSD = %0.f kΩ" %Rx
# At 0.1 FSD
Im= 0.1*I # in amp
R= E/Im # in ohm
R=R*10**-3 # in kohm
Rx= R-R1addRm #in kohm
print "Unknown resistance at 0.1 FSD = %0.f kΩ" %Rx
#Given data
Rm= 50 # in ohm
R1= 10 # in kohm
R1=R1*10**3 # in ohm
R2= 50 # in ohm
Im_FSD= 100*10**-6 #meter FSD current in amp
# At 0.5 FSD , with 1.5 V
E=1.5 # in volt
Im= 0.5*Im_FSD # in amp
Vm= Im*Rm # in volt
I0= Vm/R2 #in amp
I=I0+Im # in amp
Rx= E/I-R1 # in ohm
Rx=Rx*10**-3 #in kohm
print "Unknown resistance at 0.5 FSD with 1.5 V = %0.f kohm" %Rx
# With E= 1.25 V and Rx=0
E=1.25 # in volt
Rx=0
I=E/(R1+Rx) # in amp
I0=I-Im_FSD # in amp
Vm= Im_FSD*Rm # in volt
R2= Vm/I0 # in ohm
print "Zero adjuster resistance = %0.f ohm" %R2
# At 0.5 FSD , with 1.25 V
E=1.25 # in volt
Im= 0.5*Im_FSD # in amp
Vm= Im*Rm # in volt
I0= Vm/R2 #in amp
I=I0+Im # in amp
Rx= E/I-R1 # in ohm
Rx=Rx*10**-3 #in kohm
print "Unknown resistance at 0.5 FSD with 1.25 V = %0.f kohm" %Rx