SUMO - Simulation of Urban MObility
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MSCFModel_Kerner.h
Go to the documentation of this file.
1 /****************************************************************************/
8 // car-following model by B. Kerner
9 /****************************************************************************/
10 // SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/
11 // Copyright (C) 2001-2012 DLR (http://www.dlr.de/) and contributors
12 /****************************************************************************/
13 //
14 // This file is part of SUMO.
15 // SUMO is free software: you can redistribute it and/or modify
16 // it under the terms of the GNU General Public License as published by
17 // the Free Software Foundation, either version 3 of the License, or
18 // (at your option) any later version.
19 //
20 /****************************************************************************/
21 #ifndef MSCFModel_Kerner_h
22 #define MSCFModel_Kerner_h
23 
24 // ===========================================================================
25 // included modules
26 // ===========================================================================
27 #ifdef _MSC_VER
28 #include <windows_config.h>
29 #else
30 #include <config.h>
31 #endif
32 
33 #include <microsim/MSCFModel.h>
35 
36 
37 // ===========================================================================
38 // class definitions
39 // ===========================================================================
44 class MSCFModel_Kerner : public MSCFModel {
45 public:
52  MSCFModel_Kerner(const MSVehicleType* vtype, SUMOReal accel, SUMOReal decel, SUMOReal headwayTime, SUMOReal k, SUMOReal phi);
53 
54 
57 
58 
61 
70  SUMOReal followSpeed(const MSVehicle* const veh, SUMOReal speed, SUMOReal gap2pred, SUMOReal predSpeed, SUMOReal predMaxDecel) const;
71 
72 
80  SUMOReal stopSpeed(const MSVehicle* const veh, SUMOReal gap2pred) const;
81 
82 
87  int getModelID() const {
88  return SUMO_TAG_CF_BKERNER;
89  }
91 
92 
93 
98  MSCFModel* duplicate(const MSVehicleType* vtype) const;
99 
100 
101 private:
107  SUMOReal _v(SUMOReal speed, SUMOReal vfree, SUMOReal gap, SUMOReal predSpeed) const;
108 
109 
110 
111 private:
116 
119 
123 
124 };
125 
126 #endif /* MSCFModel_Kerner_H */
127