/****************************************************************************/1// Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.dev/sumo2// Copyright (C) 2002-2025 German Aerospace Center (DLR) and others.3// This program and the accompanying materials are made available under the4// terms of the Eclipse Public License 2.0 which is available at5// https://www.eclipse.org/legal/epl-2.0/6// This Source Code may also be made available under the following Secondary7// Licenses when the conditions for such availability set forth in the Eclipse8// Public License 2.0 are satisfied: GNU General Public License, version 29// or later which is available at10// https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html11// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later12/****************************************************************************/13/// @file HelpersMMPEVEM.h14/// @author Kevin Badalian ([email protected])15/// @date 2021-1016///17// The MMP's emission model for electric vehicles.18// If you use this model for academic research, you are highly encouraged to19// cite our paper "Accurate physics-based modeling of electric vehicle energy20// consumption in the SUMO traffic microsimulator"21// (DOI: 10.1109/ITSC48978.2021.9564463).22// Teaching and Research Area Mechatronics in Mobile Propulsion (MMP), RWTH Aachen23/****************************************************************************/242526#pragma once272829#include <utils/emissions/PollutantsInterface.h>30#include <utils/emissions/EnergyParams.h>3132#include <map>3334353637/**38* \class HelpersMMPEVEM39* \brief This helper class allows the PollutantsInterface to load and use40* different MMPEVEMs.41*/42class HelpersMMPEVEM : public PollutantsInterface::Helper {43private:44static const int MMPEVEM_BASE = 5 << 16;454647public:48/**49* \brief Constructor50*/51HelpersMMPEVEM();5253/** @brief Returns the fuel type described by this emission class as described in the Amitran interface (Gasoline, Diesel, ...)54* @param[in] c the emission class55* @return always "Electricity"56*/57std::string getFuel(const SUMOEmissionClass /* c */) const {58return "Electricity";59}6061/** @brief Returns a reference weight in kg described by this emission class62* This implementation returns the default mass for this model.63* @param[in] c the emission class64* @return a reference weight65*/66double getWeight(const SUMOEmissionClass /* c */) const {67return 1794.;68}6970/**71* \brief Compute the amount of emitted pollutants for an emission class in a72* given state.73*74* This method returns 0 for all emission types but electric power75* consumption.76*77* \param[in] c An emission class78* \param[in] e An emission type79* \param[in] v Current vehicle velocity [m/s]80* \param[in] a Current acceleration of the vehicle [m/s^2]81* \param[in] slope Slope of the road at the vehicle's current position [deg]82*83* \returns The electric power consumption [Wh/s] or 0 for all other emission84* types85*/86double compute(const SUMOEmissionClass /* c */,87const PollutantsInterface::EmissionType e, const double v,88const double a, const double slope,89const EnergyParams* ptr_energyParams) const;90};919293