susantoj / PYPOWER-Dynamics

Python-based transient stability simulation program
BSD 3-Clause "New" or "Revised" License
57 stars 31 forks source link

Adopt a more flexible case structure #9

Open rwl opened 9 years ago

rwl commented 9 years ago

In this branch I have been experimenting with a more flexible structure for case data:

https://github.com/rwl/PYPOWER-Dynamics/tree/pypf

I didn't want to have to update all of the OPF functions in PYPOWER so I moved the necessary PF functions into a new pypf package. There is still a dependency on PYPOWER for the remaining functions.

The new case data classes should make it straightforward to add columns for new attributes. By way of demonstration, I committed the 3 phase fault analysis function by @susantoj and added faultMVA, Rgen and Xdpp attributes.

I took the liberty of doing away with the BUS_I column. The former GEN_BUS, F_BUS and T_BUS columns are now assumed to be the zero-based bus index. This removes the need for ext2int and int2ext conversions, but may have some as yet unforeseen downsides. A convert_ppc function allows PYPOWER case data dicts to be reused and performs the necessary conversions.