39 myTauDecel(myDecel * myHeadwayTime),
90 if (predSpeed == 0 && gap < 0.01) {
96 + (predSpeed * predSpeed)
MSCFModel_Daniel1(const MSVehicleType *vtype)
Constructor.
Representation of a vehicle in the micro simulation.
double myTauDecel
The precomputed value for myDecel*myTau.
MSLane * getLane() const
Returns the lane the vehicle is on.
std::mt19937 * getRNG() const
Structure representing possible vehicle parameter.
The car-following model abstraction.
static double rand(std::mt19937 *rng=0)
Returns a random real number in [0, 1)
virtual double maxNextSpeed(double speed, const MSVehicle *const veh) const
Returns the maximum speed given the current speed.
double myAccel
The vehicle's maximum acceleration [m/s^2].
double myDawdle
The vehicle's dawdle-parameter. 0 for no dawdling, 1 for max.
#define WRITE_WARNING(msg)
The car-following model and parameter.
MSAbstractLaneChangeModel & getLaneChangeModel()
virtual double patchSpeed(const double min, const double wanted, const double max, const MSCFModel &cfModel)=0
Called to adapt the speed in order to allow a lane change. It uses information on LC-related desired ...
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
virtual MSCFModel * duplicate(const MSVehicleType *vtype) const
Duplicates the car-following model.
virtual double getSpeedAfterMaxDecel(double v) const
Returns the velocity after maximum deceleration.
virtual double dawdle(double speed, std::mt19937 *rng) const
Applies driver imperfection (dawdling / sigma)
double finalizeSpeed(MSVehicle *const veh, double vPos) const
Applies interaction with stops and lane changing model influences.
double myDecel
The vehicle's maximum deceleration [m/s^2].
double processNextStop(double currentVelocity)
Processes stops, returns the velocity needed to reach the stop.
virtual double _vsafe(double gap, double predSpeed) const
Returns the "safe" velocity.
virtual double followSpeed(const MSVehicle *const veh, double speed, double gap2pred, double predSpeed, double predMaxDecel, const MSVehicle *const pred=0) const
Computes the vehicle's safe speed (no dawdling)
virtual double stopSpeed(const MSVehicle *const veh, const double speed, double gap2pred) const
Computes the vehicle's safe speed for approaching a non-moving obstacle (no dawdling) ...
double getSpeed() const
Returns the vehicle's current speed.
const std::string & getID() const
Returns the name of the vehicle.
double getVehicleMaxSpeed(const SUMOTrafficObject *const veh) const
Returns the lane's maximum speed, given a vehicle's speed limit adaptation.
~MSCFModel_Daniel1()
Destructor.