Eclipse SUMO - Simulation of Urban MObility
Loading...
Searching...
No Matches
PHEMlightdllV5::CEP Class Reference

#include <CEP.h>

Public Types

enum  eNormalizingType { eNormalizingType_RatedPower , eNormalizingType_DrivingPower }

Public Member Functions

double CalcEngPower (double power, const double ratedPower)
 CEP (VEHPHEMLightJSON::VEH *Vehicle, std::vector< std::string > &headerLineFCvalues, std::vector< std::vector< double > > &matrixFCvalues, std::vector< std::string > &headerLinePollutants, std::vector< std::vector< double > > &matrixPollutants, std::vector< double > &idlingFCvalues, std::vector< double > &idlingPollutants)
double getAuxPower () const
const std::string & getCalcType () const
double GetCO2Emission (double _FC, double _CO, double _HC, Helpers *VehicleClass)
double getCrossSectionalArea () const
double getCWValue () const
double GetEmission (const std::string &pollutant, double power, double speed, Helpers *VehicleClass, const double drivingPower, const double ratedPower)
double getFMot (const double speed, const double ratedPower, const double wheelRadius)
const std::string & getFuelType () const
const bool & getHeavyVehicle () const
double GetPMaxNorm (double speed)
const double & getRatedPower () const
double getResistance (const double speed, const double f0) const
double getResistanceF0 () const
double GetRotationalCoeffecient (double speed)
double getVehicleLoading () const
double getVehicleMass () const
double getVehicleMassRot () const
double getWheelRadius () const
void setCalcType (const std::string &value)
void setFuelType (const std::string &value)
void setRatedPower (const double &value)

Protected Attributes

double _auxPower
double _axleRatio
std::map< std::string, std::vector< double > > _cepNormalizedCurvePollutants
double _crossSectionalArea
double _cWValue
std::vector< double > _dragNormTable
double _effectiveWheelDiameter
double _engineIdlingSpeed
double _engineRatedSpeed
std::map< std::string, double > _FleetMix
std::vector< double > _gearTransmissionCurve
std::map< std::string, double > _idlingValueFCvalues
std::map< std::string, double > _idlingValuesPollutants
double _massVehicle
std::vector< double > _nNormTable
std::vector< double > _normalizedPowerPatternFCvalues
std::vector< double > _normalizedPowerPatternPollutants
std::map< std::string, std::vector< double > > _normedCepCurveFCvalues
double _pNormP0
double _pNormP1
double _pNormV0
double _pNormV1
double _resistanceF0
double _resistanceF1
double _resistanceF2
double _resistanceF3
double _resistanceF4
std::vector< double > _speedCurveRotational
std::vector< double > _speedPatternRotational
double _vehicleLoading
double _vehicleMassRot

Private Member Functions

bool CalcfCValMix (double &_fCBr, double &_fCHC, double &_fCCO, double &_fCCO2, Helpers *VehicleClass)
void FindLowerUpperInPattern (int &lowerIndex, int &upperIndex, const std::vector< double > &pattern, double value, double scale=1.)
bool GetfcVals (const std::string &_fuelTypex, double &_fCBr, double &_fCHC, double &_fCCO, double &_fCCO2, Helpers *VehicleClass)
void InitializeInstanceFields ()
double Interpolate (double px, double p1, double p2, double e1, double e2)

Private Attributes

std::string privateCalcType
std::string privateFuelType
bool privateHeavyVehicle
double privateRatedPower

Detailed Description

Definition at line 41 of file V5/cpp/CEP.h.

Member Enumeration Documentation

◆ eNormalizingType

Enumerator
eNormalizingType_RatedPower 
eNormalizingType_DrivingPower 

Definition at line 43 of file V5/cpp/CEP.h.

Constructor & Destructor Documentation

◆ CEP()

Member Function Documentation

◆ CalcEngPower()

double PHEMlightdllV5::CEP::CalcEngPower ( double power,
const double ratedPower )

Definition at line 196 of file V5/cpp/CEP.cpp.

References _normalizedPowerPatternFCvalues.

Referenced by HelpersPHEMlight5::compute().

Here is the caller graph for this function:

◆ CalcfCValMix()

bool PHEMlightdllV5::CEP::CalcfCValMix ( double & _fCBr,
double & _fCHC,
double & _fCCO,
double & _fCCO2,
Helpers * VehicleClass )
private

Definition at line 296 of file V5/cpp/CEP.cpp.

References _FleetMix, GetfcVals(), and PHEMlightdllV5::Helpers::setErrMsg().

Referenced by GetCO2Emission().

Here is the caller graph for this function:

◆ FindLowerUpperInPattern()

void PHEMlightdllV5::CEP::FindLowerUpperInPattern ( int & lowerIndex,
int & upperIndex,
const std::vector< double > & pattern,
double value,
double scale = 1. )
private

Definition at line 399 of file V5/cpp/CEP.cpp.

References invalid_return< std::string >::value.

Referenced by GetEmission(), getFMot(), and GetRotationalCoeffecient().

Here is the caller graph for this function:

◆ getAuxPower()

double PHEMlightdllV5::CEP::getAuxPower ( ) const
inline

Definition at line 67 of file V5/cpp/CEP.h.

References _auxPower, and getRatedPower().

Referenced by HelpersPHEMlight5::calcPower(), and HelpersPHEMlight5::compute().

Here is the caller graph for this function:

◆ getCalcType()

const std::string & PHEMlightdllV5::CEP::getCalcType ( ) const

Definition at line 180 of file V5/cpp/CEP.cpp.

References privateCalcType.

Referenced by HelpersPHEMlight5::calcPower(), CEP(), and HelpersPHEMlight5::compute().

Here is the caller graph for this function:

◆ GetCO2Emission()

double PHEMlightdllV5::CEP::GetCO2Emission ( double _FC,
double _CO,
double _HC,
Helpers * VehicleClass )

Definition at line 273 of file V5/cpp/CEP.cpp.

References CalcfCValMix(), GetfcVals(), and getFuelType().

Referenced by HelpersPHEMlight5::compute().

Here is the caller graph for this function:

◆ getCrossSectionalArea()

double PHEMlightdllV5::CEP::getCrossSectionalArea ( ) const
inline

Definition at line 79 of file V5/cpp/CEP.h.

References _crossSectionalArea.

Referenced by HelpersPHEMlight5::calcWheelPower(), and HelpersPHEMlight5::getCoastingDecel().

Here is the caller graph for this function:

◆ getCWValue()

double PHEMlightdllV5::CEP::getCWValue ( ) const
inline

Definition at line 82 of file V5/cpp/CEP.h.

References _cWValue.

Referenced by HelpersPHEMlight5::calcWheelPower(), and HelpersPHEMlight5::getCoastingDecel().

Here is the caller graph for this function:

◆ GetEmission()

double PHEMlightdllV5::CEP::GetEmission ( const std::string & pollutant,
double power,
double speed,
Helpers * VehicleClass,
const double drivingPower,
const double ratedPower )

◆ GetfcVals()

bool PHEMlightdllV5::CEP::GetfcVals ( const std::string & _fuelTypex,
double & _fCBr,
double & _fCHC,
double & _fCCO,
double & _fCCO2,
Helpers * VehicleClass )
private

Definition at line 338 of file V5/cpp/CEP.cpp.

References getFuelType(), PHEMlightdllV5::Helpers::setErrMsg(), PHEMlightdllV5::Constants::strCNG, PHEMlightdllV5::Constants::strDiesel, PHEMlightdllV5::Constants::strGasoline, and PHEMlightdllV5::Constants::strLPG.

Referenced by CalcfCValMix(), and GetCO2Emission().

Here is the caller graph for this function:

◆ getFMot()

double PHEMlightdllV5::CEP::getFMot ( const double speed,
const double ratedPower,
const double wheelRadius )

Definition at line 370 of file V5/cpp/CEP.cpp.

References _axleRatio, _dragNormTable, _engineIdlingSpeed, _engineRatedSpeed, _gearTransmissionCurve, _nNormTable, _speedPatternRotational, FindLowerUpperInPattern(), PHEMlightdllV5::Constants::getDRIVE_TRAIN_EFFICIENCY(), Interpolate(), M_PI, and n.

Referenced by HelpersPHEMlight5::getCoastingDecel().

Here is the caller graph for this function:

◆ getFuelType()

const std::string & PHEMlightdllV5::CEP::getFuelType ( ) const

Definition at line 172 of file V5/cpp/CEP.cpp.

References privateFuelType.

Referenced by HelpersPHEMlight5::compute(), GetCO2Emission(), and GetfcVals().

Here is the caller graph for this function:

◆ getHeavyVehicle()

const bool & PHEMlightdllV5::CEP::getHeavyVehicle ( ) const

Definition at line 168 of file V5/cpp/CEP.cpp.

References privateHeavyVehicle.

Referenced by HelpersPHEMlight5::getClassByName(), and GetEmission().

Here is the caller graph for this function:

◆ GetPMaxNorm()

double PHEMlightdllV5::CEP::GetPMaxNorm ( double speed)

Definition at line 445 of file V5/cpp/CEP.cpp.

References _pNormP0, _pNormP1, _pNormV0, _pNormV1, and Interpolate().

Referenced by HelpersPHEMlight5::getModifiedAccel().

Here is the caller graph for this function:

◆ getRatedPower()

const double & PHEMlightdllV5::CEP::getRatedPower ( ) const

Definition at line 188 of file V5/cpp/CEP.cpp.

References privateRatedPower.

Referenced by HelpersPHEMlight5::compute(), getAuxPower(), HelpersPHEMlight5::getCoastingDecel(), and HelpersPHEMlight5::getModifiedAccel().

Here is the caller graph for this function:

◆ getResistance()

double PHEMlightdllV5::CEP::getResistance ( const double speed,
const double f0 ) const
inline

Definition at line 91 of file V5/cpp/CEP.h.

References _resistanceF1, _resistanceF2, _resistanceF3, and _resistanceF4.

Referenced by HelpersPHEMlight5::calcWheelPower(), and HelpersPHEMlight5::getCoastingDecel().

Here is the caller graph for this function:

◆ getResistanceF0()

double PHEMlightdllV5::CEP::getResistanceF0 ( ) const
inline

Definition at line 88 of file V5/cpp/CEP.h.

References _resistanceF0.

Referenced by HelpersPHEMlight5::calcWheelPower(), and HelpersPHEMlight5::getCoastingDecel().

Here is the caller graph for this function:

◆ GetRotationalCoeffecient()

double PHEMlightdllV5::CEP::GetRotationalCoeffecient ( double speed)

Definition at line 390 of file V5/cpp/CEP.cpp.

References _speedCurveRotational, _speedPatternRotational, FindLowerUpperInPattern(), and Interpolate().

Referenced by HelpersPHEMlight5::calcWheelPower(), HelpersPHEMlight5::getCoastingDecel(), and HelpersPHEMlight5::getModifiedAccel().

Here is the caller graph for this function:

◆ getVehicleLoading()

double PHEMlightdllV5::CEP::getVehicleLoading ( ) const
inline

Definition at line 73 of file V5/cpp/CEP.h.

References _vehicleLoading.

Referenced by HelpersPHEMlight5::calcWheelPower(), HelpersPHEMlight5::getCoastingDecel(), and HelpersPHEMlight5::getModifiedAccel().

Here is the caller graph for this function:

◆ getVehicleMass()

double PHEMlightdllV5::CEP::getVehicleMass ( ) const
inline

Definition at line 70 of file V5/cpp/CEP.h.

References _massVehicle.

Referenced by HelpersPHEMlight5::calcWheelPower(), HelpersPHEMlight5::getCoastingDecel(), and HelpersPHEMlight5::getModifiedAccel().

Here is the caller graph for this function:

◆ getVehicleMassRot()

double PHEMlightdllV5::CEP::getVehicleMassRot ( ) const
inline

Definition at line 76 of file V5/cpp/CEP.h.

References _vehicleMassRot.

Referenced by HelpersPHEMlight5::calcWheelPower(), and HelpersPHEMlight5::getModifiedAccel().

Here is the caller graph for this function:

◆ getWheelRadius()

double PHEMlightdllV5::CEP::getWheelRadius ( ) const
inline

Definition at line 85 of file V5/cpp/CEP.h.

References _effectiveWheelDiameter.

Referenced by HelpersPHEMlight5::getCoastingDecel().

Here is the caller graph for this function:

◆ InitializeInstanceFields()

void PHEMlightdllV5::CEP::InitializeInstanceFields ( )
private

Definition at line 458 of file V5/cpp/CEP.cpp.

References _auxPower, _axleRatio, _crossSectionalArea, _cWValue, _effectiveWheelDiameter, _engineIdlingSpeed, _engineRatedSpeed, _massVehicle, _pNormP0, _pNormP1, _pNormV0, _pNormV1, _resistanceF0, _resistanceF1, _resistanceF2, _resistanceF3, _resistanceF4, _vehicleLoading, and _vehicleMassRot.

Referenced by CEP().

Here is the caller graph for this function:

◆ Interpolate()

double PHEMlightdllV5::CEP::Interpolate ( double px,
double p1,
double p2,
double e1,
double e2 )
private

Definition at line 437 of file V5/cpp/CEP.cpp.

Referenced by GetEmission(), getFMot(), GetPMaxNorm(), and GetRotationalCoeffecient().

Here is the caller graph for this function:

◆ setCalcType()

void PHEMlightdllV5::CEP::setCalcType ( const std::string & value)

Definition at line 184 of file V5/cpp/CEP.cpp.

References invalid_return< std::string >::value, and privateCalcType.

Referenced by CEP().

Here is the caller graph for this function:

◆ setFuelType()

void PHEMlightdllV5::CEP::setFuelType ( const std::string & value)

Definition at line 176 of file V5/cpp/CEP.cpp.

References invalid_return< std::string >::value, and privateFuelType.

Referenced by CEP().

Here is the caller graph for this function:

◆ setRatedPower()

void PHEMlightdllV5::CEP::setRatedPower ( const double & value)

Definition at line 192 of file V5/cpp/CEP.cpp.

References invalid_return< std::string >::value, and privateRatedPower.

Referenced by CEP().

Here is the caller graph for this function:

Field Documentation

◆ _auxPower

double PHEMlightdllV5::CEP::_auxPower
protected

Definition at line 108 of file V5/cpp/CEP.h.

Referenced by CEP(), getAuxPower(), and InitializeInstanceFields().

◆ _axleRatio

double PHEMlightdllV5::CEP::_axleRatio
protected

Definition at line 107 of file V5/cpp/CEP.h.

Referenced by CEP(), getFMot(), and InitializeInstanceFields().

◆ _cepNormalizedCurvePollutants

std::map<std::string, std::vector<double> > PHEMlightdllV5::CEP::_cepNormalizedCurvePollutants
protected

Definition at line 125 of file V5/cpp/CEP.h.

Referenced by CEP(), and GetEmission().

◆ _crossSectionalArea

double PHEMlightdllV5::CEP::_crossSectionalArea
protected

Definition at line 100 of file V5/cpp/CEP.h.

Referenced by CEP(), getCrossSectionalArea(), and InitializeInstanceFields().

◆ _cWValue

double PHEMlightdllV5::CEP::_cWValue
protected

Definition at line 101 of file V5/cpp/CEP.h.

Referenced by CEP(), getCWValue(), and InitializeInstanceFields().

◆ _dragNormTable

std::vector<double> PHEMlightdllV5::CEP::_dragNormTable
protected

Definition at line 131 of file V5/cpp/CEP.h.

Referenced by CEP(), and getFMot().

◆ _effectiveWheelDiameter

double PHEMlightdllV5::CEP::_effectiveWheelDiameter
protected

Definition at line 116 of file V5/cpp/CEP.h.

Referenced by CEP(), getWheelRadius(), and InitializeInstanceFields().

◆ _engineIdlingSpeed

double PHEMlightdllV5::CEP::_engineIdlingSpeed
protected

Definition at line 115 of file V5/cpp/CEP.h.

Referenced by CEP(), getFMot(), and InitializeInstanceFields().

◆ _engineRatedSpeed

double PHEMlightdllV5::CEP::_engineRatedSpeed
protected

Definition at line 114 of file V5/cpp/CEP.h.

Referenced by CEP(), getFMot(), and InitializeInstanceFields().

◆ _FleetMix

std::map<std::string, double> PHEMlightdllV5::CEP::_FleetMix
protected

Definition at line 126 of file V5/cpp/CEP.h.

Referenced by CalcfCValMix(), and CEP().

◆ _gearTransmissionCurve

std::vector<double> PHEMlightdllV5::CEP::_gearTransmissionCurve
protected

Definition at line 123 of file V5/cpp/CEP.h.

Referenced by CEP(), and getFMot().

◆ _idlingValueFCvalues

std::map<std::string, double> PHEMlightdllV5::CEP::_idlingValueFCvalues
protected

Definition at line 127 of file V5/cpp/CEP.h.

Referenced by CEP(), and GetEmission().

◆ _idlingValuesPollutants

std::map<std::string, double> PHEMlightdllV5::CEP::_idlingValuesPollutants
protected

Definition at line 128 of file V5/cpp/CEP.h.

Referenced by CEP(), and GetEmission().

◆ _massVehicle

double PHEMlightdllV5::CEP::_massVehicle
protected

Definition at line 97 of file V5/cpp/CEP.h.

Referenced by CEP(), getVehicleMass(), and InitializeInstanceFields().

◆ _nNormTable

std::vector<double> PHEMlightdllV5::CEP::_nNormTable
protected

Definition at line 130 of file V5/cpp/CEP.h.

Referenced by CEP(), and getFMot().

◆ _normalizedPowerPatternFCvalues

std::vector<double> PHEMlightdllV5::CEP::_normalizedPowerPatternFCvalues
protected

Definition at line 119 of file V5/cpp/CEP.h.

Referenced by CalcEngPower(), CEP(), and GetEmission().

◆ _normalizedPowerPatternPollutants

std::vector<double> PHEMlightdllV5::CEP::_normalizedPowerPatternPollutants
protected

Definition at line 120 of file V5/cpp/CEP.h.

Referenced by CEP(), and GetEmission().

◆ _normedCepCurveFCvalues

std::map<std::string, std::vector<double> > PHEMlightdllV5::CEP::_normedCepCurveFCvalues
protected

Definition at line 122 of file V5/cpp/CEP.h.

Referenced by CEP(), and GetEmission().

◆ _pNormP0

double PHEMlightdllV5::CEP::_pNormP0
protected

Definition at line 110 of file V5/cpp/CEP.h.

Referenced by CEP(), GetPMaxNorm(), and InitializeInstanceFields().

◆ _pNormP1

double PHEMlightdllV5::CEP::_pNormP1
protected

Definition at line 112 of file V5/cpp/CEP.h.

Referenced by CEP(), GetPMaxNorm(), and InitializeInstanceFields().

◆ _pNormV0

double PHEMlightdllV5::CEP::_pNormV0
protected

Definition at line 109 of file V5/cpp/CEP.h.

Referenced by CEP(), GetPMaxNorm(), and InitializeInstanceFields().

◆ _pNormV1

double PHEMlightdllV5::CEP::_pNormV1
protected

Definition at line 111 of file V5/cpp/CEP.h.

Referenced by CEP(), GetPMaxNorm(), and InitializeInstanceFields().

◆ _resistanceF0

double PHEMlightdllV5::CEP::_resistanceF0
protected

Definition at line 102 of file V5/cpp/CEP.h.

Referenced by CEP(), getResistanceF0(), and InitializeInstanceFields().

◆ _resistanceF1

double PHEMlightdllV5::CEP::_resistanceF1
protected

Definition at line 103 of file V5/cpp/CEP.h.

Referenced by CEP(), getResistance(), and InitializeInstanceFields().

◆ _resistanceF2

double PHEMlightdllV5::CEP::_resistanceF2
protected

Definition at line 104 of file V5/cpp/CEP.h.

Referenced by CEP(), getResistance(), and InitializeInstanceFields().

◆ _resistanceF3

double PHEMlightdllV5::CEP::_resistanceF3
protected

Definition at line 105 of file V5/cpp/CEP.h.

Referenced by CEP(), getResistance(), and InitializeInstanceFields().

◆ _resistanceF4

double PHEMlightdllV5::CEP::_resistanceF4
protected

Definition at line 106 of file V5/cpp/CEP.h.

Referenced by CEP(), getResistance(), and InitializeInstanceFields().

◆ _speedCurveRotational

std::vector<double> PHEMlightdllV5::CEP::_speedCurveRotational
protected

Definition at line 124 of file V5/cpp/CEP.h.

Referenced by CEP(), and GetRotationalCoeffecient().

◆ _speedPatternRotational

std::vector<double> PHEMlightdllV5::CEP::_speedPatternRotational
protected

Definition at line 118 of file V5/cpp/CEP.h.

Referenced by CEP(), getFMot(), and GetRotationalCoeffecient().

◆ _vehicleLoading

double PHEMlightdllV5::CEP::_vehicleLoading
protected

Definition at line 98 of file V5/cpp/CEP.h.

Referenced by CEP(), getVehicleLoading(), and InitializeInstanceFields().

◆ _vehicleMassRot

double PHEMlightdllV5::CEP::_vehicleMassRot
protected

Definition at line 99 of file V5/cpp/CEP.h.

Referenced by CEP(), getVehicleMassRot(), and InitializeInstanceFields().

◆ privateCalcType

std::string PHEMlightdllV5::CEP::privateCalcType
private

Definition at line 51 of file V5/cpp/CEP.h.

Referenced by getCalcType(), and setCalcType().

◆ privateFuelType

std::string PHEMlightdllV5::CEP::privateFuelType
private

Definition at line 50 of file V5/cpp/CEP.h.

Referenced by getFuelType(), and setFuelType().

◆ privateHeavyVehicle

bool PHEMlightdllV5::CEP::privateHeavyVehicle
private

Definition at line 49 of file V5/cpp/CEP.h.

Referenced by CEP(), and getHeavyVehicle().

◆ privateRatedPower

double PHEMlightdllV5::CEP::privateRatedPower
private

Definition at line 52 of file V5/cpp/CEP.h.

Referenced by getRatedPower(), and setRatedPower().


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