electrical_neighbours¶
The central module containing all code dealing with electrical neighbours
-
class
ElectricalNeighbours
(dependencies)[source]¶ Bases:
egon.data.datasets.Dataset
Add lines, loads, generation and storage for electrical neighbours
This dataset creates data for modelling the considered foreign countries and writes that data into the database tables that can be read by the eTraGo tool. Neighbouring countries are modelled in a lower spatial resolution, in general one node per country is considered. Defined load timeseries as well as generatrion and storage capacities are connected to these nodes. The nodes are connected by AC and DC transmission lines with the German grid and other neighbouring countries considering the grid topology from ENTSO-E.
- Dependencies
- Resulting tables
grid.egon_etrago_bus
is extendedgrid.egon_etrago_link
is extendedgrid.egon_etrago_line
is extendedgrid.egon_etrago_load
is extendedgrid.egon_etrago_load_timeseries
is extendedgrid.egon_etrago_storage
is extendedgrid.egon_etrago_generator
is extendedgrid.egon_etrago_generator_timeseries
is extendedgrid.egon_etrago_transformer
is extended
-
name
= 'ElectricalNeighbours'¶
-
version
= '0.0.7'¶
-
buses
(scenario, sources, targets)[source]¶ Insert central buses in foreign countries per scenario
Parameters: - sources (dict) – List of dataset sources
- targets (dict) – List of dataset targets
Returns: central_buses (geoapndas.GeoDataFrame) – Buses in the center of foreign countries
-
calc_capacities
()[source]¶ Calculates installed capacities from TYNDP data
Returns: pandas.DataFrame – Installed capacities per foreign node and energy carrier
-
central_buses_egon100
(sources)[source]¶ Returns buses in the middle of foreign countries based on eGon100RE
Parameters: sources (dict) – List of sources Returns: pandas.DataFrame – Buses in the center of foreign countries
-
central_transformer
(scenario, sources, targets, central_buses, new_lines)[source]¶ Connect central foreign buses with different voltage levels
Parameters: - sources (dict) – List of dataset sources
- targets (dict) – List of dataset targets
- central_buses (geopandas.GeoDataFrame) – Buses in the center of foreign countries
- new_lines (geopandas.GeoDataFrame) – Lines that connect cross-border lines to central bus per country
Returns: None.
-
choose_transformer
(s_nom)[source]¶ Select transformer and parameters from existing data in the grid model
It is assumed that transformers in the foreign countries are not limiting the electricity flow, so the capacitiy s_nom is set to the minimum sum of attached AC-lines. The electrical parameters are set according to already inserted transformers in the grid model for Germany.
Parameters: s_nom (float) – Minimal sum of nominal power of lines at one side Returns: - int – Selected transformer nominal power
- float – Selected transformer nominal impedance
-
cross_border_lines
(scenario, sources, targets, central_buses)[source]¶ Adds lines which connect border-crossing lines from osmtgmod to the central buses in the corresponding neigbouring country
Parameters: - sources (dict) – List of dataset sources
- targets (dict) – List of dataset targets
- central_buses (geopandas.GeoDataFrame) – Buses in the center of foreign countries
Returns: new_lines (geopandas.GeoDataFrame) – Lines that connect cross-border lines to central bus per country
-
foreign_dc_lines
(scenario, sources, targets, central_buses)[source]¶ Insert DC lines to foreign countries manually
Parameters: - sources (dict) – List of dataset sources
- targets (dict) – List of dataset targets
- central_buses (geopandas.GeoDataFrame) – Buses in the center of foreign countries
Returns: None.
-
get_cross_border_buses
(scenario, sources)[source]¶ Returns buses from osmTGmod which are outside of Germany.
Parameters: sources (dict) – List of sources Returns: geopandas.GeoDataFrame – Electricity buses outside of Germany
-
get_cross_border_lines
(scenario, sources)[source]¶ Returns lines from osmTGmod which end or start outside of Germany.
Parameters: sources (dict) – List of sources Returns: geopandas.GeoDataFrame – AC-lines outside of Germany
-
get_foreign_bus_id
()[source]¶ Calculte the etrago bus id from Nodes of TYNDP based on the geometry
Returns: pandas.Series – List of mapped node_ids from TYNDP and etragos bus_id
-
get_map_buses
()[source]¶ Returns a dictonary of foreign regions which are aggregated to another
Returns: Combination of aggregated regions
-
insert_generators
(capacities)[source]¶ Insert generators for foreign countries based on TYNDP-data
Parameters: capacities (pandas.DataFrame) – Installed capacities per foreign node and energy carrier Returns: None.
-
insert_storage
(capacities)[source]¶ Insert storage units for foreign countries based on TYNDP-data
Parameters: capacities (pandas.DataFrame) – Installed capacities per foreign node and energy carrier Returns: None.
-
map_carriers_tyndp
()[source]¶ Map carriers from TYNDP-data to carriers used in eGon :returns: dict – Carrier from TYNDP and eGon