digiplan.map.calculations#
Module for calculations used for choropleths or charts.
Capacities
#
Bases: Calculation
Oemof postprocessing calculation to read capacities.
calculate_result()
#
Read attribute "capacity" from parameters.
Flows
#
StorageCapacities
#
Bases: Calculation
Oemof postprocessing calculation to read storage capacities.
calculate_result()
#
Read attribute "storage_capacity" from parameters.
areas_per_municipality_2045(parameters, *, aggregate_pv_ground=True)
#
Calculate areas for each municipality depending on capacities in user settings.
batteries_per_municipality()
#
Return battery count per municipality.
battery_capacities_per_municipality()
#
Return battery capacity per municipality.
calculate_capita_for_value(df)
#
calculate_potential_shares(parameters)
#
Calculate potential shares depending on user settings.
calculate_square_for_value(df)
#
calculate_wind_and_pv_distribution(df, parameters)
#
Calculate wind and pv distribution based on parameters.
capacities(simulation_id)
#
Calculate capacities from simulation_id.
capacities_per_municipality()
#
Calculate capacity of renewables per municipality in MW.
Returns#
pd.DataFrame Capacity per municipality (index) and technology (column)
capacities_per_municipality_2045(parameters, *, aggregate_pv_ground=True)
#
Calculate capacities from 2045 scenario per municipality in MW.
companies_per_municipality()
#
Return companies per municipality.
electricity_demand_per_municipality(year=2022)
#
Calculate electricity demand per sector per municipality in GWh.
Returns#
pd.DataFrame Electricity demand per municipality (index) and sector (column)
electricity_demand_per_municipality_2045(user_settings)
#
Calculate electricity demand per sector per municipality in GWh in 2045.
Returns#
pd.DataFrame Electricity demand per municipality (index) and sector (column)
electricity_from_from_biomass(simulation_id)
#
Calculate electricity from biomass.
Biomass share to electricity comes from following parts: - biomass is turned into biogas - biogas powers central and decentral BPCHP which outputs to electricity bus - wood powers central and decentral EXTCHP which outputs to electricity bus
- biogas is further upgraded into methane
- methane powers following components which all output to electricity bus:
- BPCHP (central/decentral)
- EXTCHP (central/decentral)
- gas turbine
Regarding the power delivered by methane, we have to distinguish between methane from import and methane from upgraded biomass. This is done, by calculating the share of both and multiplying output respectively.
Returns#
pd.Series containing one entry for electric energy powered by biomass
electricity_heat_demand(simulation_id)
#
electricity_overview(year)
#
electricity_overview_from_user(simulation_id)
#
employment_per_municipality()
#
Return employees per municipality.
energies_per_municipality()
#
Calculate energy of renewables per municipality in GWh.
Returns#
pd.DataFrame Energy per municipality (index) and technology (column)
energies_per_municipality_2045(parameters)
#
Calculate energies from 2045 scenario per municipality in MWh.
energy_shares_2045_per_municipality(parameters)
#
Calculate energy shares of renewables from electric demand per municipality in 2045.
Returns#
pd.DataFrame Energy share per municipality (index) and technology (column)
energy_shares_2045_region(parameters)
#
Calculate energy shares of renewables from electric demand for region in 2045.
Like energy_shares_2045_per_municipality() but with weighted demand for correct totals.
Returns#
pd.DataFrame Energy share per municipality (index) and technology (column)
energy_shares_per_municipality()
#
Calculate energy shares of renewables from electric demand per municipality.
Returns#
pd.DataFrame Energy share per municipality (index) and technology (column)
energy_shares_region()
#
Calculate energy shares of renewables from electric demand for region.
Like energy_shares_per_municipality() but with weighted demand for correct totals.
Returns#
pd.DataFrame Energy share per municipality (index) and technology (column)
get_heat_production(distribution, year)
#
Calculate hea production per technology for given distribution and year.
get_reduction(simulation_id)
#
Return electricity reduction from renewables and imports.
get_regional_independency(simulation_id)
#
Return electricity autarky for 2022 and user scenario.
heat_demand_per_municipality(year)
#
Calculate heat demand per sector per municipality in GWh.
Returns#
pd.DataFrame Heat demand per municipality (index) and sector (column)
heat_demand_per_municipality_2045(user_settings)
#
Calculate heat demand per sector per municipality in GWh in 2045.
Returns#
pd.DataFrame Heat demand per municipality (index) and sector (column)
heat_overview(simulation_id, distribution)
#
renewable_electricity_production(simulation_id)
#
Return electricity production from renewables including biomass.
select_wind_year(technology_df, wind_year)
#
Select corresponding wind year based on wind year. Drop non-corresponding wind years.
storage_capacities(simulation_id)
#
Calculate storage capacities from simulation_id.
storage_charge_discharge(simulation_id)
#
Calculate battery charge and discharge of small and large scale batteries for given simulation_id.
value_per_municipality(series)
#
Shares values across areas (dummy function).
wind_turbines_per_municipality_2045(parameters)
#
Calculate number of wind turbines from 2045 scenario per municipality.