SUMO - Simulation of Urban MObility
|
00001 /****************************************************************************/ 00008 // Helper methods for Harmonoise-based noise emission computation 00009 /****************************************************************************/ 00010 // SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/ 00011 // Copyright (C) 2001-2012 DLR (http://www.dlr.de/) and contributors 00012 /****************************************************************************/ 00013 // 00014 // This file is part of SUMO. 00015 // SUMO is free software: you can redistribute it and/or modify 00016 // it under the terms of the GNU General Public License as published by 00017 // the Free Software Foundation, either version 3 of the License, or 00018 // (at your option) any later version. 00019 // 00020 /****************************************************************************/ 00021 #ifndef HelpersHarmonoise_h 00022 #define HelpersHarmonoise_h 00023 00024 00025 // =========================================================================== 00026 // included modules 00027 // =========================================================================== 00028 #ifdef _MSC_VER 00029 #include <windows_config.h> 00030 #else 00031 #include <config.h> 00032 #endif 00033 00034 #include <vector> 00035 #include <cassert> 00036 #include "StdDefs.h" 00037 #include "SUMOVehicleClass.h" 00038 #include <limits> 00039 #include <cmath> 00040 00041 00042 // =========================================================================== 00043 // class definitions 00044 // =========================================================================== 00052 class HelpersHarmonoise { 00053 public: 00061 static SUMOReal computeNoise(SUMOEmissionClass c, double v, double a) ; 00062 00063 00069 inline static SUMOReal sum(SUMOReal val) { 00070 return SUMOReal(10. * log10(val)); 00071 } 00072 00073 00074 private: 00077 00079 static double myR_A_C1_Parameter[27]; 00080 00082 static double myR_B_C1_Parameter[27]; 00083 00085 static double myR_A_C3_Parameter[27]; 00086 00088 static double myR_B_C3_Parameter[27]; 00089 00091 static double myT_A_C1_Parameter[27]; 00092 00094 static double myT_B_C1_Parameter[27]; 00095 00097 static double myT_A_C3_Parameter[27]; 00098 00100 static double myT_B_C3_Parameter[27]; 00102 00103 00105 static double myAOctaveBandCorrection[27]; 00106 00107 00108 }; 00109 00110 00111 #endif 00112 00113 /****************************************************************************/ 00114