First time here? We are a friendly community of Power Systems Engineers. Check out the FAQ!

Ask Your Question
2

How can I find all 500kV buses in an area?

asked Jan 10 '12

JervisW gravatar image

My saved case has over 100 buses that are 500kV in a PSSE area (area 3). Finding all of the 500kV area 3 buses is easy using the filters on the PSSE user interface. But my question is how to find those bus numbers in Python?

1 answer

Sort by » oldest newest most voted
3

answered Jan 13 '12

jtrain gravatar image

I'd use the Subsystem Data Retrieval and Subsystem Definition APIs. Use these to create a subsystem of buses based on a filter, and then retrieve attributes like Voltage and Angle.

# filter all area 3, 500kV buses and put into subsystem 1.
psspy.bsys(
  sid=1,
  usekv=1,             # filter based on Base kV
  basekv=[500,500],    # select buses with base voltage 500kV
  numarea=1,
  areas=[3],           # only buses in area 3
)

# now get the bus numbers for buses in subsystem 1.
ierr, target_buses = psspy.abusint(
  sid=1,
  flag=1,              # only in service buses.
  string=["NUMBER", "TYPE"]    # request bus numbers and types.
)

There is a lot more you can do with subsystem data retrieval functions (like abusint). Look at Chapter 8 of the PSSE Application Program Interface (API) manual.

link

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.
Want to format code in your answer? Here is a one minute demo on Youtube

Add Answer

[hide preview]

Question Tools

Stats

Asked: Jan 10 '12

Seen: 3,332 times

Last updated: Jan 13 '12