77 double maxSpeed,
const bool onInsertion =
false,
const CalcReason usage = CalcReason::CURRENT)
const;
88 double predMaxDecel,
const MSVehicle*
const pred = 0,
const CalcReason usage = CalcReason::CURRENT)
const;
98 double stopSpeed(
const MSVehicle*
const veh,
const double speed,
double gap2pred,
double decel,
const CalcReason usage = CalcReason::CURRENT)
const;
108 double getSecureGap(
const MSVehicle*
const veh,
const MSVehicle*
const pred,
const double speed,
const double leaderSpeed,
const double leaderMaxDecel)
const;
173 double result =
MIN2(maxSpeed, maxSpeedLane);
231 double _v(
const MSVehicle*
const veh,
const MSVehicle*
const pred,
const double gap2pred,
const double mySpeed,
232 const double predSpeed,
const double desSpeed,
const bool respectMinGap,
const CalcReason usage = CalcReason::CURRENT)
const;
236 const double speed,
const double predSpeed,
const double desSpeed,
double vErr,
int ACC_ControlMode
The vehicle's ACC control mode. 0 for speed control and 1 for gap control.
The ACC car-following model.
CommunicationsOverrideMode CACC_CommunicationsOverrideMode
int CACC_ControlMode
The vehicle's CACC precious time step gap error.
The CACC car-following model.
MSCFModel_CACC & operator=(const MSCFModel_CACC &s)
Invalidated assignment operator.
virtual std::string getParameter(const MSVehicle *veh, const std::string &key) const
try to get the given parameter for this carFollowingModel
double getSecureGap(const MSVehicle *const veh, const MSVehicle *const pred, const double speed, const double leaderSpeed, const double leaderMaxDecel) const
Returns the a gap such that the gap mode acceleration of the follower is zero.
double freeSpeed(const MSVehicle *const veh, double speed, double seen, double maxSpeed, const bool onInsertion=false, const CalcReason usage=CalcReason::CURRENT) const
Computes the vehicle's safe speed without a leader.
double followSpeed(const MSVehicle *const veh, double speed, double gap2pred, double predSpeed, double predMaxDecel, const MSVehicle *const pred=0, const CalcReason usage=CalcReason::CURRENT) const
Computes the vehicle's safe speed (no dawdling)
MSCFModel_CACC(const MSVehicleType *vtype)
Constructor.
double myGapControlGainGap
double stopSpeed(const MSVehicle *const veh, const double speed, double gap2pred, double decel, const CalcReason usage=CalcReason::CURRENT) const
Computes the vehicle's safe speed for approaching a non-moving obstacle (no dawdling)
double myApplyDriverstate
virtual void setParameter(MSVehicle *veh, const std::string &key, const std::string &value) const
try to set the given parameter for this carFollowingModel
double myGapClosingControlGainGap
double _v(const MSVehicle *const veh, const MSVehicle *const pred, const double gap2pred, const double mySpeed, const double predSpeed, const double desSpeed, const bool respectMinGap, const CalcReason usage=CalcReason::CURRENT) const
MSCFModel * duplicate(const MSVehicleType *vtype) const
Duplicates the car-following model.
double speedSpeedControl(const double speed, double vErr, VehicleMode &vehMode) const
double myEmergencyThreshold
double insertionFollowSpeed(const MSVehicle *const v, double speed, double gap2pred, double predSpeed, double predMaxDecel, const MSVehicle *const pred=0) const
Computes the vehicle's acceptable speed at insertion.
double myGapClosingControlGainGapDot
static std::map< std::string, CommunicationsOverrideMode > CommunicationsOverrideModeMap
double maximumLaneSpeedCF(const MSVehicle *const veh, double maxSpeed, double maxSpeedLane) const
Returns the maximum velocity the CF-model wants to achieve in the next step.
double mySpeedControlGain
double myCollisionAvoidanceGainGapDot
double speedGapControl(const MSVehicle *const veh, const double gap2pred, const double speed, const double predSpeed, const double desSpeed, double vErr, const MSVehicle *const pred, VehicleMode &vehMode) const
double myGapControlGainGapDot
int getModelID() const
Returns the model's name.
~MSCFModel_CACC()
Destructor.
VehicleMode
Vehicle mode (default is CACC) Switch to ACC mode if CACC_ControlMode = 1 (gap control mode) and lead...
@ CACC_COLLISION_AVOIDANCE_MODE
double mySpeedControlMinGap
void setHeadwayTime(double headwayTime)
Sets a new value for desired headway [s].
virtual MSCFModel::VehicleVariables * createVehicleVariables() const
Returns model specific values which are stored inside a vehicle and must be used with casting.
static std::map< VehicleMode, std::string > VehicleModeNames
Vehicle mode name map.
double myCollisionAvoidanceGainGap
double interactionGap(const MSVehicle *const, double vL) const
Returns the maximum gap at which an interaction between both vehicles occurs.
CommunicationsOverrideMode
@ CACC_MODE_LEADER_NO_CAV
The car-following model abstraction.
virtual void setHeadwayTime(double headwayTime)
Sets a new value for desired headway [s].
CalcReason
What the return value of stop/follow/free-Speed is used for.
void applyOwnSpeedPerceptionError(const MSVehicle *const veh, double &speed) const
Overwrites sped by the perceived values obtained from the vehicle's driver state,.
double myHeadwayTime
The driver's desired time headway (aka reaction time tau) [s].
Representation of a vehicle in the micro simulation.
The car-following model and parameter.