First time here? We are a friendly community of Power Systems Engineers. Check out the FAQ!
1 | initial version |
if you have list of the lines, all currents from them you can get very easy:
lines=[[5001,5013,"1"],
[5001,5035,"1"]] #put here as many lines as you want
l=len(lines)
for i in range (l):
error, amp = psspy.brnmsc(lines[i][0],lines[i][1],lines[i][2],"AMPS")
if error==0:
print str(i+1)+". Line: ",lines[i][0],lines[i][1],lines[i][2]," : ",round(amp,2)," A"
else:
print str(i+1)+". Line: ",lines[i][0],lines[i][1],lines[i][2]," : ","error in brnmsc"