SUMO - Simulation of Urban MObility
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HelpersHBEFA Class Reference

Helper methods for HBEFA-based emission computation. More...

#include <HelpersHBEFA.h>

Static Public Member Functions

static SUMOReal computeCO (SUMOEmissionClass c, double v, double a)
 Returns the amount of emitted CO given the vehicle type and state (in mg/s) More...
 
static SUMOReal computeCO2 (SUMOEmissionClass c, double v, double a)
 Returns the amount of emitted CO2 given the vehicle type and state (in mg/s) More...
 
static SUMOReal computeFuel (SUMOEmissionClass c, double v, double a)
 Returns the amount of consumed fuel given the vehicle type and state (in ml/s) More...
 
static SUMOReal computeHC (SUMOEmissionClass c, double v, double a)
 Returns the amount of emitted HC given the vehicle type and state (in mg/s) More...
 
static SUMOReal computeNOx (SUMOEmissionClass c, double v, double a)
 Returns the amount of emitted NOx given the vehicle type and state (in mg/s) More...
 
static SUMOReal computePMx (SUMOEmissionClass c, double v, double a)
 Returns the amount of emitted PMx given the vehicle type and state (in mg/s) More...
 

Static Private Member Functions

static SUMOReal compute (SUMOEmissionClass c, const int offset, double v, const double a)
 Computes the emitted pollutant amount using the given speed and acceleration. More...
 

Static Private Attributes

static double myFunctionParameter [42][36]
 The function parameter. More...
 

Detailed Description

Helper methods for HBEFA-based emission computation.

The parameter are stored per vehicle class; 6*6 parameter are used, sorted by the pollutant (CO2, CO, HC, fuel, NOx, PMx), and the function part (c0, cav1, cav2, c1, c2, c3).

Definition at line 53 of file HelpersHBEFA.h.

Member Function Documentation

static SUMOReal HelpersHBEFA::compute ( SUMOEmissionClass  c,
const int  offset,
double  v,
const double  a 
)
inlinestaticprivate

Computes the emitted pollutant amount using the given speed and acceleration.

As the functions are defining emissions in g/hour, the function's result is normed by 3.6 (seconds in an hour/1000) yielding mg/s. Negative acceleration results directly in zero emission.

Parameters
[in]cemission class for the function parameters to use
[in]offsetthe offset in the function parameters for the correct pollutant
[in]vThe vehicle's current velocity
[in]aThe vehicle's current acceleration

Definition at line 124 of file HelpersHBEFA.h.

References M_PI, MAX2(), myFunctionParameter, SUMOReal, SVE_P_LDV_7_7, SVE_UNKNOWN, and SVE_ZERO_EMISSIONS.

Referenced by computeCO(), computeCO2(), computeFuel(), computeHC(), computeNOx(), and computePMx().

SUMOReal HelpersHBEFA::computeCO ( SUMOEmissionClass  c,
double  v,
double  a 
)
static

Returns the amount of emitted CO given the vehicle type and state (in mg/s)

Parameters
[in]cThe vehicle emission class
[in]vThe vehicle's current velocity
[in]aThe vehicle's current acceleration
Returns
The amount of CO emitted by the given vehicle class when moving with the given velocity and acceleration [mg/s]

Definition at line 163 of file HelpersHBEFA.cpp.

References CO_OFFSET, and compute().

Referenced by PollutantsInterface::computeCO(), and PollutantsInterface::computeDefaultCO().

SUMOReal HelpersHBEFA::computeCO2 ( SUMOEmissionClass  c,
double  v,
double  a 
)
static

Returns the amount of emitted CO2 given the vehicle type and state (in mg/s)

Parameters
[in]cThe vehicle emission class
[in]vThe vehicle's current velocity
[in]aThe vehicle's current acceleration
Returns
The amount of CO2 emitted by the given vehicle class when moving with the given velocity and acceleration [mg/s]

Definition at line 169 of file HelpersHBEFA.cpp.

References CO2_OFFSET, and compute().

Referenced by PollutantsInterface::computeCO2(), and PollutantsInterface::computeDefaultCO2().

SUMOReal HelpersHBEFA::computeFuel ( SUMOEmissionClass  c,
double  v,
double  a 
)
static

Returns the amount of consumed fuel given the vehicle type and state (in ml/s)

As the general function returns mg/s, this implementation scales with 790 (average density of fuel)

Parameters
[in]cThe vehicle emission class
[in]vThe vehicle's current velocity
[in]aThe vehicle's current acceleration
Returns
The amount of fuel consumed by the given vehicle class when moving with the given velocity and acceleration [ml/s]

Definition at line 193 of file HelpersHBEFA.cpp.

References compute(), and FUEL_OFFSET.

Referenced by PollutantsInterface::computeDefaultFuel(), and PollutantsInterface::computeFuel().

SUMOReal HelpersHBEFA::computeHC ( SUMOEmissionClass  c,
double  v,
double  a 
)
static

Returns the amount of emitted HC given the vehicle type and state (in mg/s)

Parameters
[in]cThe vehicle emission class
[in]vThe vehicle's current velocity
[in]aThe vehicle's current acceleration
Returns
The amount of HC emitted by the given vehicle class when moving with the given velocity and acceleration [mg/s]

Definition at line 175 of file HelpersHBEFA.cpp.

References compute(), and HC_OFFSET.

Referenced by PollutantsInterface::computeDefaultHC(), and PollutantsInterface::computeHC().

SUMOReal HelpersHBEFA::computeNOx ( SUMOEmissionClass  c,
double  v,
double  a 
)
static

Returns the amount of emitted NOx given the vehicle type and state (in mg/s)

Parameters
[in]cThe vehicle emission class
[in]vThe vehicle's current velocity
[in]aThe vehicle's current acceleration
Returns
The amount of NOx emitted by the given vehicle class when moving with the given velocity and acceleration [mg/s]

Definition at line 181 of file HelpersHBEFA.cpp.

References compute(), and NOx_OFFSET.

Referenced by PollutantsInterface::computeDefaultNOx(), and PollutantsInterface::computeNOx().

SUMOReal HelpersHBEFA::computePMx ( SUMOEmissionClass  c,
double  v,
double  a 
)
static

Returns the amount of emitted PMx given the vehicle type and state (in mg/s)

Parameters
[in]cThe vehicle emission class
[in]vThe vehicle's current velocity
[in]aThe vehicle's current acceleration
Returns
The amount of PMx emitted by the given vehicle class when moving with the given velocity and acceleration [mg/s]

Definition at line 187 of file HelpersHBEFA.cpp.

References compute(), and PMx_OFFSET.

Referenced by PollutantsInterface::computeDefaultPMx(), and PollutantsInterface::computePMx().

Field Documentation

double HelpersHBEFA::myFunctionParameter
staticprivate

The function parameter.

Definition at line 150 of file HelpersHBEFA.h.

Referenced by compute().


The documentation for this class was generated from the following files: