Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Battery electric vehicle meta facade #152

Open
wants to merge 28 commits into
base: feature/battery-electric-vehicle
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
8a274ae
add individual mobility sector facade from example (commit 6383a86)
JonasJeckstadt Jan 16, 2024
e62800c
adjust parameters (WIP)
JonasJeckstadt Jan 16, 2024
1d8365f
work on test for mobility_facade.
JonasJeckstadt Jan 18, 2024
199ee82
remove pkm_demand from IndividualMobilitySector facade.
JonasJeckstadt Jan 18, 2024
dde0974
remove transport_commodity_bus definition within IndividualMobilitySe…
JonasJeckstadt Jan 18, 2024
3ceb07e
fix label for Bev within IndividualMobilitySectror facade
JonasJeckstadt Jan 18, 2024
2f4d818
adjust IndividualMobilitySector facade to run with mobility_facade test
JonasJeckstadt Jan 18, 2024
9e50cad
Fix errors in docstring of Bev().
JonasJeckstadt Jan 22, 2024
660ba2c
Adjust parameters in IndividualMobilitySector facade (WIP).
JonasJeckstadt Jan 24, 2024
741c8cf
Update docstring of IndividualMobilitySector facade.
JonasJeckstadt Jan 25, 2024
2b75daa
Fix error with calculation of storage capacity.
JonasJeckstadt Feb 5, 2024
619e59a
Add invest_c_rate selection function to Bev() component.
JonasJeckstadt Feb 5, 2024
2dfb14f
Test _invest_c_rate method and fix issues.
JonasJeckstadt Feb 6, 2024
9d0ec2f
Adjust parameter definition of Bev and IndividualMobilitySector facad…
JonasJeckstadt Feb 8, 2024
39aa985
Update mobility_facade test.
JonasJeckstadt Feb 8, 2024
ffbad2f
Remove unused parameters from Bev facade and improve docstring.
JonasJeckstadt Feb 14, 2024
f90d68b
Add parameter availability_flex and availability_inflex.
JonasJeckstadt Feb 15, 2024
9210969
Merge branch 'feature/battery-electric-vehicle' into feature/battery-…
nailend Feb 26, 2024
81656fb
Fix minor error.
JonasJeckstadt Feb 26, 2024
638de45
Change processing of capacity value so it is used for flex and inflex…
JonasJeckstadt Mar 4, 2024
e169c37
Rename Bev classes
nailend Mar 13, 2024
8cf7a93
Adhere to pep8
nailend Mar 13, 2024
90faf86
Adjust BevTech name
nailend Mar 13, 2024
de58761
Update typemap
nailend Mar 13, 2024
85d350b
Add new imports
nailend Mar 27, 2024
5684b35
Bulk commit all changes
nailend Mar 27, 2024
eec7361
Test BEV fleet
nailend Mar 27, 2024
88e268b
Update graph plotting
nailend Mar 27, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
add individual mobility sector facade from example (commit 6383a86)
  • Loading branch information
JonasJeckstadt committed Jan 16, 2024
commit 8a274ae8210775bf9d10bc45e2cc92a7f7a270b9
122 changes: 122 additions & 0 deletions src/oemof/tabular/facades/experimental/battery_electric_vehicle.py
Original file line number Diff line number Diff line change
Expand Up @@ -453,3 +453,125 @@ def build_solph_components(self):

# many components in facade
self.subnodes = subnodes


# ToDo: remove facade-bus
# ToDo: name of class ok?
# ToDo: adjust parameters
# ToDo: adjust docstring
@dataclass_facade
class individual_mobility_sector(Facade):
r"""A fleet of Battery electric vehicles with vehicle-to-grid.
Note that the investment option is not available for this facade at
the current development state.
Parameters
----------
bus: oemof.solph.Bus
An oemof bus instance where the storage unit is connected to.
storage_capacity: int
The total storage capacity of the vehicles (e.g. in MWh)
drive_power: int
Total charging/discharging capacity of the vehicles (e.g. in MW)
drive_consumption : array-like
Profile of drive consumption of the fleet (relative to capacity).
max_charging_power : int
Max charging/discharging power of all vehicles (e.g. in MW)
availability : array-like
Ratio of available capacity for charging/vehicle-to-grid due to
grid connection.
efficiency_charging: float
Efficiency of charging the batteries, default: 1
v2g: bool
If True, vehicle-to-grid is enabled, default: False
loss_rate: float
min_storage_level : array-like
Profile of minimum storage level (min SOC)
max_storage_level : array-like
Profile of maximum storage level (max SOC).
balanced : boolean
Couple storage level of first and last time step.
(Total inflow and total outflow are balanced.)
transport_commodity: None
Bus for the transport commodity
input_parameters: dict
Dictionary to specify parameters on the input edge. You can use
all keys that are available for the oemof.solph.network.Flow class.
output_parameters: dict
see: input_parameters
"""

electricity_bus: Bus

storage_capacity: int

drive_power: int

max_charging_power: Union[float, Sequence[float]]

availability: Sequence[float]

label: str

# type: str = "ind_mob_sec"

drive_consumption: Sequence = None

efficiency_charging: float = 1

v2g: bool = False

transport_commodity_bus: Bus = None

input_parameters: dict = field(default_factory=dict)

output_parameters: dict = field(default_factory=dict)

expandable: bool = False

def build_solph_components(self):
transport_commodity_bus = Bus(label="transport_commodity")
transport_commodity_bus.type = "bus"

mobility_nodes = [transport_commodity_bus]

bev_controlled_v2g = Bev(
label="V2G",
electricity_bus=self.electricity_bus,
storage_capacity=self.storage_capacity,
drive_power=self.drive_power,
max_charging_power=self.max_charging_power,
availability=self.availability,
efficiency_charging=self.efficiency_charging,
v2g=True,
transport_commodity_bus=transport_commodity_bus,
)

mobility_nodes.append(bev_controlled_v2g)

bev_controlled = Bev(
label="BEV",
electricity_bus=self.electricity_bus,
storage_capacity=self.storage_capacity,
drive_power=self.drive_power,
max_charging_power=self.max_charging_power,
availability=self.availability,
efficiency_charging=self.efficiency_charging,
v2g=False,
transport_commodity_bus=transport_commodity_bus,
)

mobility_nodes.append(bev_controlled)

pkm_demand = Load(
label="pkm_demand",
type="Load",
carrier="pkm",
bus=transport_commodity_bus,
amount=400,
profile=[0, 1, 0],
)

mobility_nodes.append(pkm_demand)

# many components in facade
self.subnodes = mobility_nodes