In [1]:

```
import math
from __future__ import division
#initialisation of variables
l=5*0.305; #converting ft to metre
v=40*0.447; #converting mile/hr to m/sec
B=3*10**-5; #magnetic field in Tesla
#CALCULATIONS
ve=B*l*v; #calculating potential difference
#RESULTS
print"Potential difference in Volt =",round(ve,5);
```

In [2]:

```
import math
from __future__ import division
#initialisation of variables
i=0.707*10; #current in Ampere
r=20; #resistance in Ohm
#CALCULATIONS
p=i*i*r; #calculating power dissipated
#RESULTS
print"Power dissipated in Watt =",round(p,3);
```

In [3]:

```
import math
from __future__ import division
#initialisation of variables
r=5; #resistance in ohm
p=1000; #power in Watt
va=100; #potential diff in Volt for a
vb=100000; #potential diff in volt for b
#CALCULATIONS
ia=p/va; #calculating current
ib=p/vb; #calculating current
ha=ia*ia*r; #heat in Watt
hb=ib*ib*r; #heat in Watt
#RESULTS
print"Heat produced by a in Watt =",round(ha,3);
print"Heat produced by b in Watt =",round(hb,4);
```

In [4]:

```
import math
from __future__ import division
#initialisation of variables
i1=3; #current in Ampere
n2=500; #no. of turns
n1=100; #no. of turns
v1=120; #potential diff in volt
#CALCULATIONS
v2=(n2*v1)/n1; #calculating v2
i2=(n1*i1)/n2; #calculating i2
#RESULTS
print"Voltage in volt =",round(v2,3);
print"Current in Ampere =",round(i2,3);
```

In [5]:

```
import math
from __future__ import division
#initialisation of variables
p=10000; #power in Watt
v1=5000; #potential diff in volt
v2=240; #voltage in volt
#CALCULATIONS
i2=p/v2; #calculating i2
v=v1/v2;
#RESULTS
print"Ratio of turns =",round(v,3);
print"Maximum current in Ampere =",round(i2,3);
```

In [6]:

```
import math
from __future__ import division
#initialisation of variables
r=100; #resistance in ohm
v1=120; #potential diff in Volt
n2=50; #no. of turns
n1=200; #no. of turns
#CALCULATIONS
v2=(n2*v1)/n1; #potential diff in volt
i2=v2/r; #calculating current
i1=(n2/n1)*i2; #calculating current
#RESULTS
print"Current in primary circuit in Ampere =",round(i1,3);
```