22 #ifndef MSDriverState_h 23 #define MSDriverState_h 54 OUProcess(
double initialState,
double timeScale,
double noiseIntensity);
124 return myMinAwareness;
128 return myInitialAwareness;
132 return myErrorTimeScaleCoefficient;
136 return myErrorNoiseIntensityCoefficient;
140 return myError.getTimeScale();
144 return myError.getNoiseIntensity();
148 return mySpeedDifferenceErrorCoefficient;
152 return myHeadwayErrorCoefficient;
156 return mySpeedDifferenceChangePerceptionThreshold;
160 return myHeadwayChangePerceptionThreshold;
168 return myError.getState();
176 myMinAwareness = value;
180 myInitialAwareness = value;
184 myErrorTimeScaleCoefficient = value;
188 myErrorNoiseIntensityCoefficient = value;
192 mySpeedDifferenceErrorCoefficient = value;
196 myHeadwayErrorCoefficient = value;
200 mySpeedDifferenceChangePerceptionThreshold = value;
204 myHeadwayChangePerceptionThreshold = value;
207 void setAwareness(
const double value);
210 myError.setState(state);
214 myError.setTimeScale(value);
218 myError.setNoiseIntensity(value);
228 void updateAssumedGaps();
242 double getPerceivedSpeedDifference(
const double trueSpeedDifference,
const double trueGap,
const void* objID =
nullptr);
244 double getPerceivedHeadway(
const double trueGap,
const void* objID =
nullptr);
261 void updateStepDuration();
void setInitialAwareness(const double value)
double getState() const
Obtain the current state of the process.
double myLastUpdateTime
Time point of the last state update.
Representation of a vehicle in the micro simulation.
void setSpeedDifferenceChangePerceptionThreshold(const double value)
double getMinAwareness() const
void setMinAwareness(const double value)
void setErrorTimeScaleCoefficient(const double value)
double getAwareness() const
static double headwayChangePerceptionThreshold
void setNoiseIntensity(double noiseIntensity)
set the process' noise intensity to a new value
double myActionStepLength
action step length induced by awareness level
double myTimeScale
The time scale of the process.
double myInitialAwareness
static double minAwareness
void setState(double state)
set the process' state to a new value
static std::mt19937 * getRNG()
double myHeadwayErrorCoefficient
double getInitialAwareness() const
static double initialAwareness
void setHeadwayChangePerceptionThreshold(const double value)
MSVehicle * myVehicle
Vehicle corresponding to this driver state.
OUProcess(double initialState, double timeScale, double noiseIntensity)
constructor
static double headwayErrorCoefficient
static double errorTimeScaleCoefficient
std::map< const void *, double > myLastPerceivedSpeedDifference
The last perceived speed differences to the corresponding objects.
An Ornstein-Uhlenbeck stochastic process.
double myState
The current state of the process.
static double speedDifferenceErrorCoefficient
void setErrorNoiseIntensity(const double value)
bool myDebugLock
Used to prevent infinite loops in debugging outputs,.
void setTimeScale(double timeScale)
set the process' timescale to a new value
double getErrorNoiseIntensity() const
double getSpeedDifferenceChangePerceptionThreshold() const
void setErrorTimeScale(const double value)
double getHeadwayChangePerceptionThreshold() const
double getNoiseIntensity() const
static double speedDifferenceChangePerceptionThreshold
double getErrorState() const
void setHeadwayErrorCoefficient(const double value)
static std::mt19937 myRNG
Random generator for OUProcesses.
double getTimeScale() const
double myErrorNoiseIntensityCoefficient
Coefficient controlling the impact of awareness on the noise intensity of the error process...
double getErrorTimeScaleCoefficient() const
std::map< const void *, double > myAssumedGap
The assumed gaps to different objects.
double myNoiseIntensity
The noise intensity of the process.
double getSpeedDifferenceErrorCoefficient() const
double mySpeedDifferenceErrorCoefficient
Scaling coefficients for the magnitude of errors.
double myErrorTimeScaleCoefficient
Coefficient controlling the impact of awareness on the time scale of the error process.
void setErrorNoiseIntensityCoefficient(const double value)
double mySpeedDifferenceChangePerceptionThreshold
void setSpeedDifferenceErrorCoefficient(const double value)
void step(double dt)
evolve for a time step of length dt.
double myHeadwayChangePerceptionThreshold
Thresholds above a change in the corresponding quantity is perceived.
static double errorNoiseIntensityCoefficient
virtual ~MSSimpleDriverState()
double getErrorNoiseIntensityCoefficient() const
Provides an interface to an error whose fluctuation is controlled via the driver's 'awareness'...
void setErrorState(const double state)
double getHeadwayErrorCoefficient() const
double getErrorTimeScale() const