Load Flow Analysis in OEMOF & Exporting Results to Excel

I am seeking advice on how to conduct load flow calculations in oemof for a given energy system model and how to export the simulation results directly to Excel for analysis. My focus is on capturing key operational parameters from the load flow results.

Could anyone provide insights or point me towards relevant examples or documentation on:

  1. Executing load flow analysis in oemof.
  2. Accessing and exporting these results to an Excel format.

Any tips on this would be greatly appreciated.

Thank you for your assistance.

Hi @AhmadAlHairi,

regarding your questions:

  1. There is an experimental feature for this. You can use the components ElectricalBus and ElectricalLine for DC optimal power flow simulations. Please note, that the term “experimental” refers to those components being not comprehensively tested, documented or used. It might even be non-functional anymore. oemof.solph’s focus is rather on modeling (small or large) scale energy systems and the energy flows, but not so much on the electrotechnical constraints around these. You can give it a try, but you can also explore alternatives such as PyPSA which was built for / around power flow modeling.
  2. For oemof.solph, your results come in a dict with two keys, sequences for time series information and scalars (or period_scalars). You can access them like any python dictionary object and use pandas to store to csv, Excel (.xlsx) or whatever format you wish (using pd.to_csv() resp. pd.to_excel). Please have a look at the oemof examples which show you how to access your results using the processing and views modules. oemof-solph/examples at dev · oemof/oemof-solph · GitHub.

Hope that helps and good luck!

1 Like

Hi @AhmadAlHariri,

adding to what @dlr_jk said, the ElectricalLine does not work in the current versions of solph and network. The implementation assumes an entity in a graph can be both, a node and an edge. However, this is not the case and no longer supported in oemof.network. Older versions of network (v0.4 but also some v0.5.0a1 pre-releases) allowed it.

Cheers,
Patrik

1 Like