Models/Electric
Contents
Overview
Since version 0.24.0 SUMO includes a model for electric vehicles. It was implemented by Tamás Kurczveil and Pablo Alvárez López from the TU-Braunschweig. The core of the model is implemented in the vehicle device device.battery. Additional features are a charging station (which can be placed on any lane in the network) and a new output option --battery-output <FILE>.
You can find a test case for these implementations at [1]
Defining Electric Vehicles
To define an electric vehicle, it must be equipped with a battery device. This may be done using the option --device.battery.explicit <vehID1,vehID2,...> or simply setting --device.battery.probability 1 to equip all vehicles. Alternatively, the device may be specified using Generic vehicle parameters.
Additional properties of the vehicle and its electrical components must then be defined via parameters of the vehicle or its type.
These values have the following meanings:
| key | Value Type | Default | Description |
|---|---|---|---|
| maximumBatteryCapacity | float | 0 (kWh) | Maximum battery capacity Emax |
| maximumPower | float | 0 (kW) | Maximum power which the vehicle can reach |
| vehicleMass | float | 0 (kg) | Vehicle mass mveh |
| frontSurfaceArea | float | 0 (m2) | Front surface area Aveh |
| airDragCoefficient | float | 0 | Air drag coefficient cw |
| internalMomentOfInertia | float | 0 (kg·m2) | Mom. of inertia of int. rot. elements Jint |
| radialDragCoefficient | float | 0 | Radial drag coefficient crad |
| rollDragCoefficient | float | 0 | Rolling resistance coefficient croll |
| constantPowerIntake | float | 0 (kW) | Avg. (constant) power of consumers Pconst |
| propulsionEfficiency | float | 0 | Drive efficiency ηprop |
| recuperationEfficiency | float | 0 | Recuperation efficiency ηrecup |
An example of a vehicle with electric attribute:
<routes>
<vType id="ElectricBus" accel="1.0" decel="1.0" lenght="12" maxSpeed="100.0" sigma="0.0" minGap="2.5" color="1,1,1">
<param key="maximumBatteryCapacity" value="2000"/>
<param key="vehicleMass" value="10000"/>
<param key="frontSurfaceArea" value="5"/>
<param key="airDragCoefficient" value="0.6"/>
<param key="internalMomentOfInertia" value="0.01"/>
<param key="radialDragCoefficient" value="0.5"/>
<param key="rollDragCoefficient" value="0.01"/>
<param key="constantPowerIntake" value="100"/>
<param key="propulsionEfficiency" value="0.9"/>
<param key="recuperationEfficiency" value="0.9"/>
</vType>
</routes>
The initial energy content of the battery (by default MaxBatKap/2) can be set in the vehicle definitions
<routes>
<vehicle id="0" type="type1" depart="0" color="1,0,0">
<param key="actualBatteryCapacity" value="500"/>
</vehicle>
</routes>
Charging Stations
A charging station is a surface defined over an lane in which the vehicles equipped with a battery are charged. The basic structure and parameters of bus stops was used for the implementation of charging stations.
| key | Value Type | Value range | Default | Description |
|---|---|---|---|---|
| id | string | id | Charging station ID (Must be unique) | |
| lane | string | valid lane id | Lane of the charging station location | |
| startPos | float | lane.length < x < lane.length (negative values count backwards from the end of the lane) | 0 | Begin position in the specified lane |
| endPos | float | lane.length < x < lane.length (negative values count backwards from the end of the lane) | End position in the specified lane | |
| power | float | power > 0 | 22000 | Charging power Pchrg |
| efficiency | float | 0 <= efficiency <= 1 | 0.95 | Charging efficiency ηchrg |
| chargeInTransit | bool | 0 or 1 | 0 | Enable or disable charge in transit, i.e. vehicle must or must not to stop for charging |
| chargeDelay | float | chargeDelay > 0 | 0 | Time delay after the vehicles has reached / stopped on the charging station, before the energy transfer (charging) begins |
Charging stations are defined in additional using the following format:
<additional> <chargingStation chargeDelay="2" chargeInTransit="0" chrgpower="200000" efficiency="0.95" endPos="25" id="cS_2to19_0a" lane="2to19_0" startPos="10"/> </additional>
And are represented in the simulation as follows:
Stopping at a Charging Station
A stop at a charging station may either occur due to traffic condtions, stopping at a defined location or stopping at an explicit chargingStation as defined below:
<routes>
<vehicle id="v0" route="route0" depart="0">
<stop chargingStation="myChargingStationID" until="50"/>
</vehicle>
</routes>
battery-output
There are three output parameters to be set in the SUMO configuration to use the battery device:
<configuration>
<input>
<net-file value="netFile.xml"/>
<route-files value="routeFile.xml"/>
<additional-files value="additionalFile.xml"/>
</input>
<output>
<battery-output value="Battery.out.xml"/>
<battery-output.precision value="4"/>
<device.battery.probability value="1"/>
<summary-output value="summary_100.xml"/>
</output>
</configuration>
battery-output generates a file with this structure:
<battery-export>
<timestep time="0.00">
<vehicle id="vehicle01" Consum="0.00" actualBatteryCapacity="17500.00" maximumBatteryCapacity="35000.00"
chargingStationId="NULL" energyCharge="0.00" energyChargedInTransit="0.00" energyChargedStopped="0.00"
speed="12.92" acceleration="0.00" x="1428.27" y="25.57" lane="01to02_0"
posOnLane="0.00" timeStopped="0"/>
<vehicle id=..... */
</timestep>
<timestep time="1.00">
<vehicle id=.....
</timestep>
<timestep time=...
...
</timestep>
</battery-export>
| Name | Type | Description |
|---|---|---|
| time | int | Current timestep |
| id | string | id of vehicle |
| energyConsumed | double | energy consumption in this timestep |
| actualBatteryCapacity | double | energy content of the battery in this timestep |
| maximumBatteryCapacity | double | Max energy capacity of the battery |
| chargingStationId | string | If vehicle is over a charging station, this value is the id of the charging station, in other case, is NULL |
| energyCharged | double | Charge received in the current time step from a charging station (Only != 0 if vehicle is over a charging station) |
| energyChargedInTransit | double | Charge that a vehicle in transit received in the current time step from a charging station |
| energyChargedStopped | double | Charge that a stopped vehicle received in the current time step from a charging station |
| speed | double | Speed of vehicle in this timestep |
| acceleration | double | Acceleration of vehicle in this timestep |
| x | double | absolute position x of vehicle in the map |
| y | double | absolute position y of vehicle in the map |
| lane | string | id of the lane that the vehicle is currently on |
| posOnLane | double | Position of vehicle on its current lane |
| timeStopped | int | Counter with the number of timesteps that the vehicle has remained standing |
Model Details
All information about the implemented device (including details on the vehicle energy consumption and charging model) can be found in the following publication.
Publications
- Kurczveil, T., López, P.A., Schnieder, E., Implementation of an Energy Model and a Charging Infrastructure in SUMO. In: Behrisch, M., Krajzewicz, D., Weber, M. (eds.) Simulation of Urban Mobility. Lecture Notes in Computer Science, vol. 8594 , pp. 33--43. Springer, Heidelberg (2014)

