Ask Your Question
0

Is there anyway I can count number of branches between specific buses?

asked 2019-01-15 21:04:08 -0600

newbee123 gravatar image

I'm trying to write a code to count the number of devices in the buses that user chose.

I know how to count things like generators, shunts, etc.. but I don't know if there is anyway to count the number of branches and transformers.

Is there anyone who tried this before?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2019-01-16 02:00:46 -0600

perolofl gravatar image

Use inibrn and nxtbrn3, for example, to loop all branches and transfomers connected to ibus:

ibus = 154
ierr = psspy.inibrn(ibus, 2)
while True:
    ierr, jbus, kbus, ickt = psspy.nxtbrn3(ibus)
    if ierr>0: break
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

[hide preview]

Question Tools

1 follower

Stats

Asked: 2019-01-15 21:04:08 -0600

Seen: 460 times

Last updated: Jan 16 '19