import math
#initialisation of variables
GMD=0.7788*0.8/(2*100)
Mgmd=((1.6*3.2*1.6)**(1.0/3))
#Calculations
Z=2*(10**-4)*1000*math.log(2.015/.003115)
#Results
print("The self GMD of the conductor =%.6f metres" %GMD)
print("The mutual GMD of the conductor =%.3f metres " %Mgmd)
print("Inductance =%.3f mH/km\n" %Z)
import math
#initialisation of variables
r=1
D11=r**1
D12=2*r
D14=4*r
#Calculations
D13=math.sqrt(16-4)*r
Ds1=((1*2*2*math.sqrt(3)*4*2*math.sqrt(3)*2*2)**(1.0/7))*r
Ds7=((2*1*2*2**2*2*2)**(1.0/7))*r #we get this after Taking r outside the 1/7th root
Ds=((((1*2*2*math.sqrt(3)*4*2*math.sqrt(3)*2*2)**(1.0/7))**6)*((2*1*2*2**2*2*2)**(1.0/7)))**(1.0/7)*r
Dseq=((.7788)**(1.0/7))*Ds
#Results
print("Dseq.= %.2fr" %Dseq)
import math
#initialisation of variables
GMDa=0.001947 # GMD of conductor in group A
#Calculations
DSA=((.001947*6*12*.001947*6*6*0.001947*6*12)**(1.0/9))
DSB=math.sqrt(5*(10**-3)*.7788*6)
Dae=math.sqrt((9**2)+6**2)
Dcd=math.sqrt((12**2)+9**2)
DMA=((9*10.81*10.81*9*15*10.81)**(1.0/6))
LA=2*(10**-7)*(10**6)*math.log(DMA/DSA)
LB=2*(10**-7)*(10**6)*math.log(DMA/DSB)
Tot=LA+LB
#Results
print("inductance of line A,LA=%.3f mH/km" %LA) #Answers don't match due to difference in rounding off of digits
print("inductance of line B,LB=%.1f mH/km" %LB) #Answers don't match due to difference in rounding off of digits
print("total inductance of line =%.2f mH/km" %Tot) #Answers don't match due to difference in rounding off of digits
import math
#initialisation of variables
GMDc=1.266*0.7788*(10**-2) # self GMD of each conductor
Dbc=math.sqrt((4**2)+(.75**2))
Dab=Dbc
#Calculations
Dab=math.sqrt((4**2)+(8.25**2))
Daa=math.sqrt((8**2)+(7.5**2))
Dm1=(Dbc*8*7.5*9.1685)**(1.0/4)
Dm2=(Dbc*Dbc*9.1685*9.1685)**(1.0/4)
Dm3=Dm1
Dm=((Dm1*Dm2*Dm3)**(1.0/3))
Ds1=math.sqrt(GMDc*Daa) # self GMD of each phase
Ds3=Ds1
Ds2=math.sqrt(GMDc*9)
Ds=((Ds1*Ds2*Ds3)**(1.0/3))
Z=2*(10**-4)*(1000)*math.log(Dm/Ds)
#Results
print("inductance=%.3f mH/km/phase\n" %Z)
import math
#initialisation of variables
GMDs=.0069 #self GMD of the conductor
Dab=math.sqrt((3**2)+.5**2)
Dbc=Dab
Dac=6.0
#Calculations
Dab=math.sqrt((3**2)+6**2)
Daa=math.sqrt((6**2)+5.5**2)
Dm1=((3.04*6*5.5*6.708)**.25)
Dm2=((3.04*3.04*6.708*6.708)**.25)
Dm=4.89
Ds1=math.sqrt(GMDs*Daa)
Ds2=0.2217
Ds=.228
Z=2*(10**-7)*(10**6)*math.log(Dm/Ds)
#Results
print("inductance =%.3f mH/km" %Z)
import math
#initialisation of variables
Ds=math.sqrt(0.025*.4*.7788)
#Calculations
Dm=((6.5*13.0*6.5)**(1.0/3))
Z=2*(10**-4)*1000*math.log(Dm/Ds)
#Results
print("inductance =%.3f mH/km/phase" %Z)