示例#1
0
 def burdenVAgtc(self,VA,pf,Isec):
     """
     calculates the complex impedance of a burden from its VA, PF and secondary current
     """
     if pf >= 0:  #check sign convention for PF, '-'for capacitive
         multiplier = 1.0
     else:
         multiplier = -1.0
     magZ = VA/Isec**2
     phi = GTC.acos(pf)
     Z = magZ*GTC.cos(phi)+ multiplier*1j*magZ*GTC.sin(phi)
     return Z
示例#2
0
 def burdenZgtc(self,Z,Isec):
     """
     returns a burden in the form of VA and PF based on its impedance
     uses GTC functions to cope if Z is a GTC ucomplex
     """
     if Z.imag >= 0:  #check sign convention for PF, '-'for capacitive
         multiplier = 1.0
     else:
         multiplier = -1.0
     phase = GTC.phase(Z)
     # phi = cmath.phase(Z)
     PF = GTC.cos(phase)*multiplier
     magZ = GTC.magnitude(Z)
     VA = magZ*Isec**2
     return (VA, PF)