In [ ]:
__copyright__ = "Reiner Lemoine Institut gGmbH"
__author__    = "gplssm, birgits"


## Abschulssworkshop open_eGo 30. Oktober 2018¶

### Installation¶

Zur Verwendung dieses Notebooks wird die aktuelle eDisGo Version sowie das python package jupyter benötigt. Installiere diese mit

pip install eDisGo
pip install jupyter


Zur Darstellung der MS-Netze auf einer Karte kann optional das python package contextily installiert werden (möglicherweise benötigt contextily einige Systemanwendungen, die zusätzlich installiert werden müssen):

pip install contextily


## Einstieg ¶

### ding0 Netz erstellen ¶

Für die Verwendung von eDisGo werden Netztopologiedaten benötigt. Die derzeit einzige unterstützte Quelle hierfür sind ding0 Netze (=> weiteres in der ding0 Session). Diese können entweder von zenodo heruntergeladen oder selbst erstellt werden. Im Folgenden wird kurz gezeigt, wie ein ding0 Netz erstellt werden kann. Dieses soll im Folgenden für alle Anwendungsfälle als Beispielnetz dienen. Voraussetzung für die Verwendung von ding0 ist ein Nutzerkonto auf der OpenEnergy Platform (OEP) (=> weiteres dazu in der OEP Session).

In [1]:
# imports zur Erstellung eines ding0 Netzes
from egoio.tools import db
from sqlalchemy.orm import sessionmaker
from ding0.core import NetworkDing0
from ding0.tools.results import save_nd_to_pickle

/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/psycopg2/__init__.py:144: UserWarning: The psycopg2 wheel package will be renamed from release 2.8; in order to keep installing from binary please use "pip install psycopg2-binary" instead. For details see: <http://initd.org/psycopg/docs/install.html#binary-install-from-pypi>.
""")
/home/birgit/virtualenvs/edisgo_release/lib/python3.6/importlib/_bootstrap.py:219: RuntimeWarning: numpy.dtype size changed, may indicate binary incompatibility. Expected 96, got 88
return f(*args, **kwds)
/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/sqlalchemy/ext/declarative/base.py:338: SAWarning: Ignoring declarative-like tuple value of attribute segment: possibly a copy-and-paste error with a comma left at the end of the line?
"left at the end of the line?" % k)
/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/sqlalchemy/ext/declarative/base.py:338: SAWarning: Ignoring declarative-like tuple value of attribute cable: possibly a copy-and-paste error with a comma left at the end of the line?
"left at the end of the line?" % k)

In [2]:
# wähle zu erstellendes Mittelspannungsnetz durch Angabe der Netz-Regions ID
mv_grid_districts = [460]
ding0_grid = 'ding0_grid_example.pkl'

In [3]:
engine = db.connection(section='oedb')
session = sessionmaker(bind=engine)()

# instanziiere ding0 Network Objekt
nd = NetworkDing0(name='network')

# erstelle ding0 Netz
nd.run_ding0(session=session,
mv_grid_districts_no=mv_grid_districts)

# exportiere das Netz als pickle Datei
save_nd_to_pickle(nd, filename=ding0_grid)

INFO:ding0:=====> MV Grid Districts imported
WARNING:ding0:Generator generator_run_of_river_hydro_mvgd460_863757 has no la_id and was assigned to a random LV Grid District (lv_grid_district_402809).
WARNING:ding0:Generator generator_run_of_river_hydro_mvgd460_873919 has no la_id and was assigned to a random LV Grid District (lv_grid_district_133650).
WARNING:ding0:Generator generator_run_of_river_hydro_mvgd460_874864 has no la_id and was assigned to a random LV Grid District (lv_grid_district_133447).
WARNING:ding0:Generator generator_run_of_river_hydro_mvgd460_874866 has no la_id and was assigned to a random LV Grid District (lv_grid_district_135392).
INFO:ding0:=====> Generators imported
INFO:ding0:=====> MV Grids parametrized
WARNING:ding0:
INFO:ding0:=====> MV Grids validated
INFO:ding0:lv_grid_district_399941 has got no residential load. No grid is created.
INFO:ding0:lv_grid_district_403155 has got no residential load. No grid is created.
INFO:ding0:lv_load_area_85334 is of type aggregated. No grid is created.
INFO:ding0:lv_grid_district_133192 has got no residential load. No grid is created.
INFO:ding0:lv_grid_district_401632 has got no residential load. No grid is created.
INFO:ding0:lv_grid_district_135931 has got no residential load. No grid is created.
INFO:ding0:lv_grid_district_399236 has got no residential load. No grid is created.
INFO:ding0:=====> LV model grids created
INFO:ding0:==> MV Routing for mv_grid_460 done
INFO:ding0:==> MV Sat1 for mv_grid_460 done
INFO:ding0:==> MV Sat2 for mv_grid_460 done
INFO:ding0:==> MV Stations for mv_grid_460 done
INFO:ding0:=====> MV Routing (Routing, Connection of Satellites & Stations) performed
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_863811.Connected to lv_station_127332.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_873960.Connected to lv_station_127333.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_863828.Connected to lv_station_399941.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_873938.Connected to lv_station_131998.
INFO:ding0:lv_load_area_85334 is of type aggregated. LV generators are not connected to LV grids.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_874882.Connected to lv_station_133651.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_874118.Connected to lv_station_401632.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_874931.Connected to lv_station_401632.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_872487.Connected to lv_station_134178.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_872432.Connected to lv_station_134810.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_875093.Connected to lv_station_134951.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_863834.Connected to lv_station_135389.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_875079.Connected to lv_station_135390.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_872445.Connected to lv_station_135391.
WARNING:ding0:No valid conn. target found for generator_solar_solar_roof_mounted_mvgd460_873961.Connected to lv_station_136168.
INFO:ding0:=====> Generators connected
INFO:ding0:=====> Branch IDs set
INFO:ding0:=====> MV Circuit Breakers relocated
INFO:ding0:=====> MV Circuit Breakers opened
INFO:ding0:Only MV side bus of MVStation will be added.
WARNING:ding0:Node lv_station_132213 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132188 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496358 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132189 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132191 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132190 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132192 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132194 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132193 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132198 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132197 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132196 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132195 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496362 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132199 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132202 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132201 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132205 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132200 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132204 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132208 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132207 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132203 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132206 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132209 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132210 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132212 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132220 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132211 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132214 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132215 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132219 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132216 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132217 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132218 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132221 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132222 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132223 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132227 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132224 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132225 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132226 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132228 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132229 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node circuit_breaker_1 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_2 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_3 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_4 is not connected to the graph and will be omitted in power flow analysis.
INFO:pypsa.pf:Slack bus for sub-network 0 is HV_460_trd
INFO:pypsa.pf:Performing non-linear load-flow on AC sub-network SubNetwork 0 for snapshots DatetimeIndex(['1970-01-01 00:00:00', '1970-01-01 01:00:00'], dtype='datetime64[ns]', freq='H')
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.034455 seconds
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.039170 seconds
INFO:ding0:==> 71 nodes have voltage issues.
INFO:ding0:==> 71 branches were reinforced.
INFO:ding0:Only MV side bus of MVStation will be added.
WARNING:ding0:Node lv_station_132213 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132188 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496358 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132189 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132191 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132190 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132192 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132194 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132193 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132198 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132197 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132196 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132195 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496362 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132199 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132202 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132201 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132205 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132200 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132204 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132208 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132207 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132203 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132206 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132209 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132210 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132212 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132220 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132211 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132214 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132215 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132219 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132216 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132217 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132218 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132221 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132222 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132223 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132227 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132224 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132225 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132226 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132228 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132229 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node circuit_breaker_1 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_2 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_3 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_4 is not connected to the graph and will be omitted in power flow analysis.
INFO:pypsa.pf:Slack bus for sub-network 0 is HV_460_trd
INFO:pypsa.pf:Performing non-linear load-flow on AC sub-network SubNetwork 0 for snapshots DatetimeIndex(['1970-01-01 00:00:00', '1970-01-01 01:00:00'], dtype='datetime64[ns]', freq='H')
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.033595 seconds
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.037006 seconds
INFO:ding0:==> 67 nodes have voltage issues.
INFO:ding0:==> 70 branches were reinforced.
INFO:ding0:Only MV side bus of MVStation will be added.
WARNING:ding0:Node lv_station_132213 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132188 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496358 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132189 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132191 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132190 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132192 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132194 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132193 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132198 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132197 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132196 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132195 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496362 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132199 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132202 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132201 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132205 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132200 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132204 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132208 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132207 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132203 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132206 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132209 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132210 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132212 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132220 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132211 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132214 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132215 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132219 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132216 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132217 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132218 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132221 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132222 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132223 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132227 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132224 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132225 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132226 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132228 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132229 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node circuit_breaker_1 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_2 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_3 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_4 is not connected to the graph and will be omitted in power flow analysis.
INFO:pypsa.pf:Slack bus for sub-network 0 is HV_460_trd
INFO:pypsa.pf:Performing non-linear load-flow on AC sub-network SubNetwork 0 for snapshots DatetimeIndex(['1970-01-01 00:00:00', '1970-01-01 01:00:00'], dtype='datetime64[ns]', freq='H')
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.031970 seconds
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.039030 seconds
INFO:ding0:==> 42 nodes have voltage issues.
INFO:ding0:==> 61 branches were reinforced.
INFO:ding0:Only MV side bus of MVStation will be added.
WARNING:ding0:Node lv_station_132213 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132188 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496358 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132189 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132191 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132190 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132192 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132194 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132193 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132198 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132197 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132196 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132195 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_496362 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132199 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132202 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132201 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132205 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132200 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132204 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132208 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132207 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132203 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132206 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132209 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132210 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132212 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132220 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132211 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132214 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132215 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132219 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132216 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132217 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132218 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132221 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132222 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132223 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132227 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132224 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132225 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132226 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132228 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node lv_station_132229 is not connected to the graph and will be omitted in power flow analysis. LA is aggr. True
WARNING:ding0:Node circuit_breaker_1 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_2 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_3 is not connected to the graph and will be omitted in power flow analysis.
WARNING:ding0:Node circuit_breaker_4 is not connected to the graph and will be omitted in power flow analysis.
INFO:pypsa.pf:Slack bus for sub-network 0 is HV_460_trd
INFO:pypsa.pf:Performing non-linear load-flow on AC sub-network SubNetwork 0 for snapshots DatetimeIndex(['1970-01-01 00:00:00', '1970-01-01 01:00:00'], dtype='datetime64[ns]', freq='H')
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.031785 seconds
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.039320 seconds
INFO:ding0:==> All voltage issues in MV grid could be solved using reinforcement.
INFO:ding0:4 in lv_grid_179885 have voltage issues
INFO:ding0:==> 25 branches were reinforced.
INFO:ding0:==> 17 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_179886 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_127329 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_127330 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_127331 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:16 in lv_grid_127332 have voltage issues
INFO:ding0:==> 41 branches were reinforced.
INFO:ding0:==> 38 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_127333 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_402231 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_402819 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_399941 have voltage issues
INFO:ding0:==> 2 branches were reinforced.
WARNING:ding0:==> There are 2 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_399742 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_400196 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_402115 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_402945 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131197 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131198 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_131199 have voltage issues
INFO:ding0:==> 3 branches were reinforced.
WARNING:ding0:==> There are 3 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_131205 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_131206 have voltage issues
INFO:ding0:==> 16 branches were reinforced.
WARNING:ding0:==> There are 16 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_131444 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131520 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131521 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131522 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131523 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131524 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:6 in lv_grid_131525 have voltage issues
INFO:ding0:==> 6 branches were reinforced.
WARNING:ding0:==> There are 6 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:2 in lv_grid_131542 have voltage issues
INFO:ding0:==> 36 branches were reinforced.
WARNING:ding0:==> There are 36 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_131543 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131544 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131551 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131552 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131553 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:18 in lv_grid_131572 have voltage issues
INFO:ding0:==> 31 branches were reinforced.
INFO:ding0:==> 27 branches were reinforced.
WARNING:ding0:==> There are 27 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:2 in lv_grid_131573 have voltage issues
INFO:ding0:==> 3 branches were reinforced.
WARNING:ding0:==> There are 3 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_403155 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131997 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_131998 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_513211 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_402809 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_401639 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_403015 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_403047 have voltage issues
WARNING:ding0:Branch branch_4030470000001 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_4030470000002 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:==> There are 2 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_132686 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_132687 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:4 in lv_grid_133183 have voltage issues
INFO:ding0:==> 4 branches were reinforced.
WARNING:ding0:==> There are 4 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_133184 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133192 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133447 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_133448 have voltage issues
INFO:ding0:==> 2 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_133449 have voltage issues
INFO:ding0:==> 34 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133450 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133451 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133452 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:6 in lv_grid_133453 have voltage issues
INFO:ding0:==> 29 branches were reinforced.
INFO:ding0:==> 26 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133454 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133455 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_513239 have voltage issues
INFO:ding0:==> 2 branches were reinforced.
WARNING:ding0:==> There are 2 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_133650 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_133651 have voltage issues
INFO:ding0:==> 16 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_133652 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:4 in lv_grid_133653 have voltage issues
INFO:ding0:==> 30 branches were reinforced.
WARNING:ding0:==> There are 30 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:2 in lv_grid_133654 have voltage issues
INFO:ding0:==> 24 branches were reinforced.
WARNING:ding0:==> There are 24 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_400542 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:4 in lv_grid_401632 have voltage issues
INFO:ding0:==> 4 branches were reinforced.
WARNING:ding0:==> There are 4 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_134176 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134177 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:10 in lv_grid_134178 have voltage issues
INFO:ding0:==> 38 branches were reinforced.
WARNING:ding0:==> There are 38 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_134200 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134201 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134202 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134203 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_402684 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_399140 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:8 in lv_grid_134676 have voltage issues
WARNING:ding0:Branch branch_1346760000024 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_1346760000058 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_1346760000059 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_1346760000110 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_1346760000109 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_1346760000092 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_1346760000025 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:Branch branch_1346760000091 could not be reinforced (voltage issues) as there is no appropriate cable type available. Original type is retained.
WARNING:ding0:==> There are 8 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_134677 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134678 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134679 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134806 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134807 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:4 in lv_grid_134808 have voltage issues
INFO:ding0:==> 35 branches were reinforced.
WARNING:ding0:==> There are 35 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_134809 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134810 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134886 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134887 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134950 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_134951 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135132 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135133 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_515408 have voltage issues
INFO:ding0:==> 2 branches were reinforced.
WARNING:ding0:==> There are 2 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:2 in lv_grid_403167 have voltage issues
INFO:ding0:==> 2 branches were reinforced.
WARNING:ding0:==> There are 2 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_135154 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_490063 have voltage issues
INFO:ding0:==> 2 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_490064 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_403347 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135155 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135232 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_399442 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135369 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135370 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135381 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135382 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135383 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_135384 have voltage issues
INFO:ding0:==> 17 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135385 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135386 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135387 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_135388 have voltage issues
INFO:ding0:==> 60 branches were reinforced.
WARNING:ding0:==> There are 60 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_135389 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135390 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135391 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135392 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135393 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:4 in lv_grid_135394 have voltage issues
INFO:ding0:==> 4 branches were reinforced.
WARNING:ding0:==> There are 4 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_135395 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_135396 have voltage issues
INFO:ding0:==> 2 branches were reinforced.
WARNING:ding0:==> There are 2 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_135397 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135398 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135399 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135400 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135401 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135402 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_135403 have voltage issues
INFO:ding0:==> 32 branches were reinforced.
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135404 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135405 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_399421 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_400214 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135900 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135929 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135930 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_135931 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_399236 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_403085 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136166 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136167 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136168 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136208 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136209 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136210 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_402676 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136615 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136616 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:2 in lv_grid_136617 have voltage issues
INFO:ding0:==> 25 branches were reinforced.
WARNING:ding0:==> There are 25 branches that cannot be reinforced (no appropriate cable available).
INFO:ding0:0 in lv_grid_136618 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136619 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:0 in lv_grid_136620 have voltage issues
INFO:ding0:==> All voltage issues in LV grid could be solved using reinforcement.
INFO:ding0:=====> MV Circuit Breakers closed


### EDisGo API ¶

Die EDisGo Klasse stellt die top-level API für den Import von Daten (Netztopologie, Zeitreihen, technische Parameter, etc.), die Durchführung von Lastflussberechnung, Netzausbau, Speicherintegration, etc., sowie die Erstellung von Plots dar (siehe Klassendokumentation für weitere Informationen).

Der folgende Code importiert das soeben erstellte ding0 Netz und initialisiert eine worst-case Analyse (Starklast- und Rückspeisefall). Die Definition von Starklast- und Rückspeisefall ist in dem Konfigurationsfile 'config_timeseries.cfg' hinterlegt und kann dort angepasst werden, was später noch gezeigt wird.

In [4]:
from edisgo import EDisGo

# instanziiere EDisGo API Objekt
edisgo = EDisGo(ding0_grid='ding0_grid_example.pkl',
worst_case_analysis='worst-case')


Was ist bei der Initialisierung passiert?

• Netztopologie wurde importiert
• Lasten und Generatoren wurden Zeitreihen zugewiesen
• (bei Angabe eines Szenarios wird der Kraftwerkspark geupdatet)

Netztopologie

Die Netztopologie ist als separate, ungerichtete Graphen für das MS-Netz und die darunterliegende NS-Netze abgebildet. (Die Graphen sind Unterklassen des networkx.Graph und um einige Funktionalitäten erweitert). Kabel und Leitungen werden als Kanten abgebildet, andere Komponenten wie Lasten, Generatoren, etc. als Knoten. Die Repräsentation als Graph erlaubt die Anwendung effizienter Graphenalgorithmen, z.B. für Plausibilitätschecks ob das Netz zusammenhängend ist oder mehrere Komponenten aufweist oder zur Bestimmung des kürzesten Pfades und der Pfadlänge zum Umspannwerk, sowie eines geeigneten Knotens zur Strangauftrennung bei der Behebung von Spannungsproblemen.

# MS Netz
edisgo.network.mv_grid
# MS graph
edisgo.network.mv_grid.graph
# NS Netze
edisgo.network.mv_grid.lv_grids


Zudem gibt es eine PyPSA Repräsentation des Netzes für die Nutzung der Lastflussberechnungssoftware PyPSA.

edisgo.network.pypsa

In [5]:
%matplotlib inline
import matplotlib.pyplot as plt

Using matplotlib backend: TkAgg


Visualisierung des MS Netzes:

In [6]:
# plotte MS-Netz
edisgo.plot_mv_grid_topology(technologies=True)

/home/birgit/virtualenvs/edisgo_release/git_repos/eDisGo/edisgo/tools/plots.py:415: UserWarning: Boolean Series key will be reindexed to match DataFrame index.
pypsa_network.lines.bus1.isin(pypsa_plot.buses.index)]


Bei den NS-Netzen handelt es sich um Referenznetze, welche nicht georeferenziert sind. Es können daher nur die Graphen der Netzes geplottet werden.

In [7]:
import networkx as nx

# wähle Graphen eines beliebigen Niederspannungsnetzes
lv_graph = list(edisgo.network.mv_grid.lv_grids)[5].graph

# zeichne den Graphen
nx.draw(lv_graph)

/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/networkx/drawing/nx_pylab.py:126: MatplotlibDeprecationWarning: pyplot.hold is deprecated.
Future behavior will be consistent with the long-time default:
plot commands add elements without first clearing the
Axes and/or Figure.
b = plt.ishold()
/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/networkx/drawing/nx_pylab.py:138: MatplotlibDeprecationWarning: pyplot.hold is deprecated.
Future behavior will be consistent with the long-time default:
plot commands add elements without first clearing the
Axes and/or Figure.
plt.hold(b)
/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/matplotlib/__init__.py:917: UserWarning: axes.hold is deprecated. Please remove it from your matplotlibrc and/or style files.
warnings.warn(self.msg_depr_set % key)
/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/matplotlib/rcsetup.py:152: UserWarning: axes.hold is deprecated, will be removed in 3.0
warnings.warn("axes.hold is deprecated, will be removed in 3.0")


Last- und Einspeisezeitreihen

Hier werden beispielhaft die Lastzeitreihe einer beliebigen Last in der MS sowie eines beliebigen Generators in der MS dargestellt.

Zur Info: In eDisGo wird immer mit Zeitreihen gerechnet, weshalb bei der Erstellung des Last- und Einspeisefalls Zeitreihen mit einem Dummy-Zeitstempel erstellt werden. Die erste Stunde stellt den Einspeisefall dar, die zweite Stunde den Lastfall.

Folgende Default-Werte werden für den Starklast- und Rückspeisefall genutzt:

Betriebsfälle Rückspeisefall Starklastfall
Last (MS) 15% 100%
Last (NS) 10% 100%
PV 85% 0%
andere Gen. 100% 0%
In [8]:
fig, axes = plt.subplots(nrows=2, ncols=1, sharex=True)

# plotte Lastzeitreihe einer Last im MS-Netz

# plotte Einspeisezeitreihe eines Generators im MS-Netz
edisgo.network.mv_grid.generators[0].timeseries.p.plot(kind='bar', ax=axes[1], title='Generator')
plt.xticks(rotation=0);


### Lastflussberechnung ¶

Nachdem das API Objekt instanziiert wurde, kann schon die erste Lastflussanalyse für die beiden Auslegungsfälle durchgeführt werden.

Zur Erinnerung wie das API Objekt instanziiert wurde:

edisgo = EDisGo(ding0_grid='ding0_grid_example.pkl',
worst_case_analysis='worst-case')

In [9]:
# nicht-linearer power flow
edisgo.analyze()

INFO:pypsa.pf:Slack bus for sub-network 0 is Bus_MVStation_460
INFO:pypsa.pf:Performing non-linear load-flow on AC sub-network SubNetwork 0 for snapshots DatetimeIndex(['1970-01-01 00:00:00', '1970-01-01 01:00:00'], dtype='datetime64[ns]', freq='H')
INFO:pypsa.pf:Newton-Raphson solved in 3 iterations with error of 0.000000 in 0.346884 seconds
INFO:pypsa.pf:Newton-Raphson solved in 4 iterations with error of 0.000000 in 0.457950 seconds


Zur Veranschaulichung der Netzsituation können nun bspw. die Leitungsbelastung sowie die Spannungsabweichungen (Abweichung von 1 p.u.) im Mittelspannungsnetz visualisiert werden.

In [10]:
# plotte Leitungsbelastungen

In [11]:
# plotte Spannungsabweichungen
edisgo.plot_mv_voltages()

ERROR:tornado.application:Exception in callback functools.partial(<function wrap.<locals>.null_wrapper at 0x7f7f18242488>)
Traceback (most recent call last):
File "/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/tornado/ioloop.py", line 758, in _run_callback
ret = callback()
File "/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/tornado/stack_context.py", line 300, in null_wrapper
return fn(*args, **kwargs)
File "/home/birgit/virtualenvs/edisgo_release/lib/python3.6/site-packages/ipykernel/kernelbase.py", line 306, in advance_eventloop
eventloop(self)
TypeError: 'NoneType' object is not callable


## Anwendungsfall konventioneller Netzausbau ¶

Die Netzausbaumethodik orientiert sich an der DENA Verteilnetzstudie [1] sowie der Verteilnetzstudie Baden-Württemberg [2].

Per default sind getrennte Spannungsabweichungsvorgaben vorgesehen, sowie zunächst eine Behebung der Überlastungsprobleme und anschließend die Behebung von Spannungsproblemen. Nach jedem Ausbauschritt wird eine nicht-lineare Lastflussberechnung durchgeführt, um weitere etwaig bestehende Netzprobleme zu identifizieren. (Für weitere Informationen siehe Dokumentation.)

Zur Berechnung des Netzausbaubedarfs werden Szenarien benötigt, für die diese berechnet werden sollen. Im open_eGo Projekt wurde folgende Szenarien entwickelt.

### Zukunftsszenarien¶

Szenario Anteil EE Quelle
NEP2035 65.8% Netzentwicklungsplan NEP 2015
ego100 100% scenario A of the "Leitstudie 2010"

Erzeugungskapazitäten (Wind und PV) in dem Beispielnetz im Status Quo:

In [12]:
from edisgo.grid.tools import get_gen_info
gen_info = get_gen_info(edisgo.network, fluctuating=True)
gen_info.groupby(['type']).sum().loc[:, ['nominal_capacity']]

Out[12]:
nominal_capacity
type
solar 10203.791
wind 15251.000

Update der Erzeugungskapazitäten für das Szenario NEP2035:

In [13]:
edisgo.import_generators(generator_scenario='nep2035')

WARNING:root:Right now only solar and wind generators can be imported from the oedb.


Erzeugungskapazitäten (Wind und PV) in dem Beispielnetz im NEP2035 Szenario:

In [14]:
gen_info = get_gen_info(edisgo.network, fluctuating=True)
gen_info.groupby(['type']).sum().loc[:, ['nominal_capacity']]

Out[14]:
nominal_capacity
type
solar 19466.791
wind 53826.000
In [24]:
edisgo.plot_mv_grid_topology(technologies=True)


Welche Überlastungen und Spannungsbandverletzungen bestehen nun durch den Ausbau von Wind und PV?

In [15]:
edisgo.analyze()

INFO:pypsa.pf:Slack bus for sub-network 0 is Bus_MVStation_460
INFO:pypsa.pf:Performing non-linear load-flow on AC sub-network SubNetwork 0 for snapshots DatetimeIndex(['1970-01-01 00:00:00', '1970-01-01 01:00:00'], dtype='datetime64[ns]', freq='H')
INFO:pypsa.pf:Newton-Raphson solved in 4 iterations with error of 0.000000 in 0.503301 seconds
INFO:pypsa.pf:Newton-Raphson solved in 4 iterations with error of 0.000000 in 0.459880 seconds

In [16]:
# Hilfsfunktionen zur Übersicht über Überlastungs- und Spannungsprobleme
from edisgo.flex_opt import check_tech_constraints
import pandas as pd

def get_voltage_issues(edisgo):
mv_issues = check_tech_constraints.mv_voltage_deviation(edisgo.network, voltage_levels='mv')
lv_issues = check_tech_constraints.lv_voltage_deviation(edisgo.network, voltage_levels='lv')
issues = {**mv_issues, **lv_issues}
issues_df = pd.DataFrame()
for k, v in issues.items():
issues_df = pd.concat([issues_df, v])
if not issues_df.empty:
return issues_df.v_mag_pu.sort_values(ascending=False)
else:
return issues_df

issues_df = pd.concat([mv_issues, lv_issues])
if not issues_df.empty:
else:
return issues_df

In [17]:
# erstelle Listen über bestehende Überlastungsprobleme und Spannungsbandverletzungen
voltage_issues = get_voltage_issues(edisgo)

# plotte bestehende Leitungsüberlastungen und Spannungsbandverletzungen
fig, axes = plt.subplots(nrows=1, ncols=2)
ax1 = voltage_issues.hist(ax=axes[0], bins=50)
ax1.set_title('Spannungsbandverletzungen')

edisgo.plot_mv_voltages()