 |
Eclipse SUMO - Simulation of Urban MObility
|
Go to the documentation of this file.
57 if (param ==
nullptr) {
70 energyDiff += 0.5 * mass * (v * v - lastV * lastV);
92 if (angleDiff != 0.) {
94 double radius =
SPEED2DIST(v) / fabs(angleDiff);
97 if (radius < 0.0001) {
99 }
else if (radius > 10000) {
112 if (energyDiff > 0) {
133 return energyDiff / 3600.;
HelpersEnergy()
Constructor (initializes myEmissionClassStrings)
@ SUMO_ATTR_PROPULSIONEFFICIENCY
Propulsion efficiency.
@ SUMO_ATTR_VEHICLEMASS
Vehicle mass.
double compute(const SUMOEmissionClass c, const PollutantsInterface::EmissionType e, const double v, const double a, const double slope, const std::map< int, double > *param) const
Computes the emitted pollutant amount using the given speed and acceleration.
std::map< int, double > myDefaultParameter
The default parameter.
EmissionType
Enumerating all emission types, including fuel.
@ SUMO_ATTR_CONSTANTPOWERINTAKE
Constant Power Intake.
static const int ENERGY_BASE
@ SUMO_ATTR_RECUPERATIONEFFICIENCY
Recuperation efficiency (constant)
void insert(const std::string str, const T key, bool checkDuplicates=true)
@ SUMO_ATTR_ROLLDRAGCOEFFICIENT
Roll Drag coefficient.
static const int ZERO_EMISSIONS
the first class in each model representing a zero emission vehicle
StringBijection< SUMOEmissionClass > myEmissionClassStrings
Mapping between emission class names and integer representations.
@ SUMO_ATTR_INTERNALMOMENTOFINERTIA
Internal moment of inertia.
Helper methods for PHEMlight-based emission computation.
@ SUMO_ATTR_AIRDRAGCOEFFICIENT
Air drag coefficient.
@ SUMO_ATTR_RADIALDRAGCOEFFICIENT
Radial drag coefficient.
@ SUMO_ATTR_RECUPERATIONEFFICIENCY_BY_DECELERATION
Recuperation efficiency (by deceleration)
@ SUMO_ATTR_FRONTSURFACEAREA
Front surface area.