echo.models.electrical.ev.v1g module

class echo.models.electrical.ev.v1g.EVV1G(uid: str = NOTHING, node_name: str = NOTHING, objective: en.numeric_expr.NumericExpression | float = 0, transformations: dict[str, Transform] = NOTHING, charge_mode: EVChargeMode | None = None, connection_port_name: str = 'cp', ports: dict[str, ElectricalDemand | ElectricalPort | MobileElectricalStorage] = NOTHING, charging_efficiency: float = 1, depth_of_discharge_limit: float = 0, discharging_efficiency: float = 1, enable_trip_slack: bool = False, soc_conserv: float | list[float] | list[list[float]] | ndarray | None = None, soc_conserv_cost: float | None = None, usage_power_limit: float | None = None, available: ndarray | list | None = None, initial_state_of_charge: float | None = None, interval_duration: int | None = None, set_stateful_attrs_at_init: bool = True, tod_charging: ndarray | list | str | None = None, usage: ndarray | list | None = None, port_dict_name_to_port_name_map: dict[str, str] | None = None, port_dict_name_to_port_uid_map: dict[str, str] | None = None, *, charging_power_limit: float, discharging_power_limit: float, max_capacity: float)

Bases: EVBase

An EV with demand managed charging.

set_stateful_attrs(available: ndarray | list | str, usage: ndarray | list | str, initial_state_of_charge: float, interval_duration: int) → None

Injects attributes with state into EV node and ports.

Parameters:
  • available – A List or ArrayType of bools representing the ability for the EV to charge. The bools can have values of [False, True] or [0, 1]. 0 and False indicate the EV is not available for charging, 1 and True indicate the EV is available for charging.

  • usage – An array representing the average power consumption from driving of the EV during a time interval. Units of power.

  • initial_state_of_charge – The initial charge present in the EV’s battery. Positive float of energy units, not percentage. Positive float with units of energy.

  • interval_duration – The duration between timestamps. Units of minutes.

Returns:

None